axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Hrastnik <Peter.Hrast...@sonydadc.com>
Subject Re: Get HTTP ContentType
Date Thu, 15 Nov 2007 13:29:59 GMT
Hi!

If you want to retrieve the Content-Type HTTP header of the current call, 
you could do: 

MessageContext context = MessageContext.getCurrentMessageContext();
HttpServletRequest req = (HttpServletRequest) 
context.getProperty(HTTPConstants.MC_HTTP_SERVLETREQUEST); 
String contentType = req.getHeader(HTTPConstants.HEADER_CONTENT_TYPE));


Bye,
        Peter.


juliocest <juliocest@gmail.com> schrieb am 15.11.2007 13:54:24:

> 
> Hi!
> 
> I would like to read the content of HTTP header, in my service provider 
with
> encapsulate some XML.  I am trying to do:
> 
>            String httpconstant = HTTPConstants.HTTP_CONTENT_TYPE;
> 
>  But I just receive: 
> 
>    Content-Type
> 
> Thanks.
> 
> JĂșlio
> -- 
> View this message in context: http://www.nabble.com/Get-HTTP-
> ContentType-tf4811689.html#a13767057
> Sent from the Axis - User mailing list archive at Nabble.com.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Mime
View raw message