Re: [xml] python xpath
- From: Stefan Seefeld <seefeld sympatico ca>
- To: xml gnome org
- Subject: Re: [xml] python xpath
- Date: Wed, 14 Jul 2004 16:50:19 -0400
Daniel Veillard wrote:
>>Daniel: it might indeed be convenient to return the content in the __str__
>>attribute
>>(for text nodes only, of course), thus returning the actual text if 'print
>>node'
>>is called.
>
>
> would you feel like making a small patch to python/libxml.py
> there is also the serialize() method but which is both more generic and more
> complex than a simple text node dump.
right. Well, given that this is just a tiny convenience, I'd suggest just to
add
__str__ = get_content
at line 264
What do you think ?
Stefan
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]