users@jaxb.java.net

Re: adding DTD declaration to an xml file

From: Guilhem Legal <legal.g_at_hotmail.fr>
Date: Thu, 5 Jun 2008 08:46:06 -0700 (PDT)

Aleksei Valikov wrote:
>
> Hi.
>
>> I am working on standardized web-service supporting many version of the
>> same
>> service.
>> to stay compatible with older version i need to create an xml document
>> with
>> a DTD declaration such as :
>>
>> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
>> <!DOCTYPE WMT_MS_Capabilities SYSTEM
>> "pathToMyDTD\WMS_MS_Capabilities.dtd">
>> <WMT_MS_Capabilities version="1.1.1" updateSequence="0">
>>
>> ------
>> </WMT_MS_Capabilities>
>>
>> is it possible to add this property when marshalling an object?
>> and if yes how?
>
> Please try the following:
>
> marshaller.setProperty("com.sun.xml.bind.xmlHeaders",
> "<!DOCTYPE ....>\n");
>
> Bye.
> /lexi
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jaxb.dev.java.net
> For additional commands, e-mail: users-help_at_jaxb.dev.java.net
>
>
>

thank's you that was exactly what i was looking for.
I seached the javadoc on this properties specificaly before posting here but
there is only the following properties explain :

- jaxb.encoding
- jaxb.formatted.output
- jaxb.schemaLocation
- jaxb.noNamespaceSchemaLocation
- jaxb.fragment

Do you know where can i get the full list of supported properties?

Guilhem Legal
-- 
View this message in context: http://www.nabble.com/adding-DTD-declaration-to-an-xml-file-tp17646322p17673072.html
Sent from the java.net - jaxb users mailing list archive at Nabble.com.