Dear all,
I have looked at many examples about Marshalling but all examples do a
Marshalling
on a FileWriter stream. Is it possible to Marshal an XML directly to a
String ?
P.s. I have tried also with :

StringWriter st = new StringWriter();
marshaller.marshal(object , st);

String xml = st.toString();

but then a strange thing happens....my attribute are turned into nodes!
f.e. instead of this: 

<node1 id="10" session="20">

I get as result:

<node1>
  <id>10</id>
  <session>20</session>
</node1>

Any help !
joshua
-- 
View this message in context: 
http://www.nabble.com/How-to-Marshal-XML-to-a-String---tp20090707p20090707.html
Sent from the Castor - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to