Hi Antonio,
from your question I assume you are using one of the static marshal
methods. How about trying something like this:
Marshaller marshaller = new Marshaller(<your outputstream>);
marshaller.setMapping(<your mapping>);
marshaller.setNoNamespaceSchemaLocation("MyXsd.xsd");
marshaller.setSuppressXSIType(true);
marshaller.marshal(<your object>);
Hope that helps.
Leander
SH SERVICE WEB schrieb:
which is the point to call this functions?
In the marshal metod it's not possible.
thank's
----- Original Message ----- From: "M.-Leander Reimer"
<[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Friday, November 24, 2006 10:34 AM
Subject: Re: [castor-user] setup root attibutes
Hi,
the Marshaller class has the methods
void setNoNamespaceSchemaLocation(java.lang.String schemaLocation)
void setSuppressXSIType(boolean suppressXSIType)
So using these will probably do what you want.
Regars,
Leander
SH SERVICE WEB schrieb:
hi,
the question is:
Why when I marshal, the root element don't have the same root
attributes such .xsd file?
example:
xsd:
< MyClass xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="MyXsd.xsd">
castor:
<MyClass xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:type="MyClass">
How I can obtain the same element attributes?
Thank's
Antonio Donia
---------------------------------------------------------------------
To unsubscribe from this list please visit:
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
To unsubscribe from this list please visit:
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
To unsubscribe from this list please visit:
http://xircles.codehaus.org/manage_email