Thanks Javier,

In fact, I tried that :

 StringReader reader = new StringReader(theXML.toString());
 InputSource is = new InputSource(reader);
 DOMParser parser = new DOMParser();
 parser.parse(is);
 Document doc = parser.getDocument();

But it seams that the document is empty.
Any idea ??

Herv�


----- Original Message -----
From: Javier Keller <[EMAIL PROTECTED]>
To: 'ECS' <[EMAIL PROTECTED]>
Sent: Tuesday, December 05, 2000 3:10 PM
Subject: AW: How to transform XML to org.w3c.Document


> Hi Herv�,
>
> Just an idea:
>
> - create a java.io.PipedReader and a PipedWriter connected to it
> - write to your PipedWriter using the output method of
org.apache.ecs.xml.XML
> - read from PipedReader and pass the result as an InputSource to your xml
parser.
> - use then the getDocument() method of your parser.
>
> Hope it works!
>
>
> -----Urspr�ngliche Nachricht-----
> Von: Herv� Guidetti [mailto:[EMAIL PROTECTED]]
> Gesendet am: Dienstag, 5. Dezember 2000 12:03
> An: [EMAIL PROTECTED]
> Betreff: How to transform XML to org.w3c.Document
>
> Hi,
>
> I want to use ecs to create an XML tree (using the XML class).
> After creating this tree, I want to parse it.
>
> In fact, I need to transfom the org.apache.ecs.xml.XML to a
org.w3c.Document.
>
> Do you have an idea how to do this ?
>
> Thanks,
>
> Herv�
>
>
>
>
>
> --
> ------------------------------------------------------------
> To subscribe:        [EMAIL PROTECTED]
> To unsubscribe:      [EMAIL PROTECTED]
> Archives and Other:  <http://java.apache.org/main/mail.html>
> Problems?:           [EMAIL PROTECTED]
>



--
------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Archives and Other:  <http://java.apache.org/main/mail.html>
Problems?:           [EMAIL PROTECTED]

Reply via email to