users@jersey.java.net

Re: [Jersey] xml-stylesheet

From: Paul Sandoz <Paul.Sandoz_at_Sun.COM>
Date: Mon, 05 Jan 2009 11:01:42 +0100

Hi,

To do this you need to implement ContextResolver<Marshaller> and
return an instance of a Marshaller that has the property set on it:

https://jaxb.dev.java.net/nonav/2.1.9/docs/
vendorProperties.html#xmlheader

Paul.

On Dec 23, 2008, at 2:01 AM, Mehdi Ben Haj Abbes wrote:

> Hi,
>
> I am using the JAXBContextResolver of the storage service sample to
> have an xml represnetation of the returned POJO of my resource
> class. I want to know what to do to change the xml declaration so it
> will have <?xml-stylesheet type='text/xsl' href='smth.xsl' ?> rather
> than the only <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
>
> thanks
>
> --
> Mehdi BEN HAJ ABBES
>