Hi Chuck, All standard HTTP headers have an equivalent class/property in the Restlet API. It was a deliberate choice to not expose those headers as first-class citizens, because we consider them as lower-level artifacts and because we want to support multiple protocols via the same API.
However, you do have access to those raw headers via the request.attributes property. You can also add non standard HTTP headers if required. See the Javadocs for details: http://www.restlet.org/docs/api/org/restlet/data/Message.html#getAttributes( ) Best regards, Jerome > -----Message d'origine----- > De : Chuck Hinson [mailto:[EMAIL PROTECTED] > Envoyé : lundi 12 février 2007 06:36 > À : [email protected] > Objet : RE: Re: Response Headers > > Umm. OK, thanks. Not was I was expecting, but I'll take it. > > However, the more generic question is then how do I set an arbitrary > HTTP header (entity or response) on a response? > > --Chuck > > -----Original Message----- > From: news [mailto:[EMAIL PROTECTED] On Behalf Of Vincent > Sent: Sunday, February 11, 2007 8:51 PM > To: [email protected] > Subject: Re: Response Headers > > > > > Maybe I'm blind, but I don't see how to set a header in a response. > > > > I need to set the Location header on a response to a POST, > but I can't > > > seem to find the right place to do that. What am I missing? > > > response.setStatus(Status.SUCCESS_CREATED); > response.setRedirectRef(request.getRootRef() + <uri>); > > -Vincent.

