My apologies for the confusion, HttpHeadersImpl,getLanguage() does indeed return the value of the Content-Language header, the latest version of HttpHeaders (starting from 0.8 api) actually has the method you're suggesting [1].

So looks like the simpliest way with 0.6 api to get to the Accept-Language is 
to do

@HeaderParam("Accept-Language") String headerValue

in a method signature and then do the custom processing of this value,

or may be do something like

@Context HttpHeaders headers

and then

List<String> values = headers.getRequestHeaders().get("Accept-Language");

Cheers, Sergey

[1] https://jsr311.dev.java.net/nonav/releases/0.8/index.html



----- Original Message ----- From: "Coder One" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Friday, June 13, 2008 11:45 PM
Subject: Re: Rest Service & Local


It seems like the CXF HttpHeadersImpl actually returns Content-Language and not 
Accept-Language.

This seems like an standard JAX-RS API miss. If the response needs to be formatted by a locale, the rest code needs to extract and parses accept-language by itself.


----------------------------
IONA Technologies PLC (registered in Ireland)
Registered Number: 171387
Registered Address: The IONA Building, Shelbourne Road, Dublin 4, Ireland

Reply via email to