[jdom-interest] Ampersand question

tsasala at hifusion.com tsasala at hifusion.com
Thu Jul 13 04:34:28 PDT 2000

	I guess rather than discuss the appropriateness of getSerializedForm, 
should we instead discuss what people *need* in terms of output?  Ignoring
whitespace issues, we need our output to be a very good approximation of the
input.  Our input is a combination of XML and relatively well formed HTML.
I say relatively because things like nbsp, ampersands, and other non-closed
tags are giving us some issues.

	  Also, we are throwing around a combination of strings and JDOM 
documents.  We are persisting our JDOM documents in our database for long
term storage.  The outputter must output a string for it to really useful 
to us.  We now have a large assortment of utility methods for converting
between docs, elements, attributes and strings.  I sure would be nice if 
toString and new XXXXX(string) were part of the API in a very usable
(i.e., persistable) way.  I like to say doc.toString to save the JDOM
document and use new Document(String) to create a new one.

	We are using the CVS version (for all those interested ;)).


James Davies wrote:
> Hi Alex,
> I'm sure you're right architecturally.  I think we should keep
> 'getSerializedForm' just for debugging, and (additionally) putting it in
> separate debugging interface(s) would probably be cleaner.
>     Regards,
>     Jim

More information about the jdom-interest mailing list