users@jaxb.java.net

Re: how to marshal an object to document fragment

From: Kohsuke Kawaguchi <Kohsuke.Kawaguchi_at_Sun.COM>
Date: Tue, 28 Jan 2003 08:07:05 -0800

> At the risk of sounding ungrateful... isn't there a JAXP-only solution to this?

AFAIK, no. It's very unfortunate that JAXP doesn't come with readily
available XmlWriter class. I'm afraid you have to pick one
implementation and stick with it.


Ah, then I realized that perhaps you can use XSLT processor as a poor
man's XmlWriter. You can write an identity transformation with
<xsl:output> to control your output format.

This is probably much less efficient, but it should work with any
JAXP-compatible implementations.


regards,
--
Kohsuke KAWAGUCHI                  408-276-7063 (x17063)
Sun Microsystems                   kohsuke.kawaguchi_at_sun.com