users@jaxb.java.net

Re: I: Jaxb binding problem

From: Kohsuke Kawaguchi <kohsuke.kawaguchi_at_sun.com>
Date: Mon, 18 Apr 2005 09:15:49 -0700

Dott. Ing. Francesca Merighi wrote:
> Obviously unmarshall method requires xmlns="" tag too.
>
> I'd like that jaxb gives me an object class without xmlns="" during
> marshalling/unmarshalling.
>
> Can you help me?

 From the schema, it seems to me that the JAXB RI is producing a
'correct' document (in the sense that all elements belong to the correct
namespace URI.) So I'm curious why you don't like this.

If you'd like the "hw_namespace" URI to be bound to a prefix, you can do
so by using the NamespacePrefixMapper interface (see the archive and a
sample for more details.)

Or maybe it could be that you are not writing the schema you intended
and perfhaps forgot to have @elementFormDefault="qualified" on the
<schema> element.

-- 
Kohsuke Kawaguchi
Sun Microsystems                   kohsuke.kawaguchi_at_sun.com