RE: [xml] python xmlReader remains in previous attribute
- From: "William M. Brack" <wbrack mmm com hk>
- To: Stéphane Bidoul <stephane bidoul softwareag com>
- Cc: xml gnome org, veillard redhat com
- Subject: RE: [xml] python xmlReader remains in previous attribute
- Date: Fri, 23 Jul 2004 00:18:52 +0800 (HKT)
Stéphane Bidoul said:
--- Daniel Veillard <veillard redhat com> wrote:
On Tue, Jul 20, 2004 at 11:08:14AM +0100, Sitsofe Wheeler wrote:
The right number of node names are printed but after
reading the attributes all node names have the value
of the last read attribute.
Looks like a stupid bug, is that in bugzilla ? If no, please
add it,
Ok, filed as http://bugzilla.gnome.org/show_bug.cgi?id=147993
Someone kindly pointed out to me off the list that I can use
MoveToElement() to workaround this problem. I am aware of
MoveToElement() (see my previous post
http://mail.gnome.org/archives/xml/2004-July/msg00035.html ) but
since the current behaviour of staying stuck on that attribute
while
underneath actually moving on is not documented I think it
should be changed.
Sorry, I forgot to cc the list.
Actually it is documented, in the .NET documentation.
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/
frlrfsystemxmlxmltextreaderclassmovetoelementtopic.asp
I haven't checked recently but according to their example and my
memories it's the expected behaviour, so I don't think
it should be changed, since the libxml2 XmlReader is supposed
to work like the .NET one.
-sbi
Hmm... now I'm a bit confused. I was just in the midst of debugging
the problem (which is within the library itself, and not just a
python interface problem) when Stéphane's post arrived. I have read
the data from the posted link (which describes how to use the
MoveToElement method), but I can't see from there why the Read
method should *not* return the proper node name. Could someone
elaborate whether Read should return the proper name, or not?
Bill
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]