Hi, 

 

That's what i have done :

 

XmlCursor cursor = textDescription.newCursor();

String text = cursor.getTextValue().trim();

cursor.dispose();

 

where textDescription is the <Description> node.

 

But in the variable "text" i am recupering: "Title text    How do I acces here 
?? http://google.com <http://google.com/> ".

 

So, there is not an easy form to extract the text i want :-(

 

Do you know any other way to do it ??

 

Anyway, thanks for the answer.

 

 

Ezequiel.

 

 

-----Message d'origine-----
De : Vinh Nguyen (vinguye2) [mailto:[EMAIL PROTECTED] 
Envoyé : mercredi 8 août 2007 20:56
À : dev@xmlbeans.apache.org
Objet : RE: How to get the info

 

I think using XmlCursor, you can call getTextValue() on the <Descriptions> 
node.  This will basically get you all the text values that are dangling 
between this node's child nodes.

 

  _____  

From: Ezequiel Puig [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, August 08, 2007 8:15 AM
To: dev@xmlbeans.apache.org
Subject: How to get the info

Hi,

 

I am really new in XMLBeans, so probably this is an easy question:

 

I have the following piece of XML:

 

<Descriptions>

        <Description Role="Summary">

          <Title>Title text</Title>

          How do I acces here ??

          <Media>

            <URL>http://www.google.com</URL>

          </Media>

        </Description>

<Descriptions>

 

XMLBeans has created for me methods like getDescription(), gerRole, getTitle, 
getMedia, etc. But my prolem is that i don't know how to get the piece of text 
"How do I acces here ??" ??



Reply via email to