org.restlet.engine.adapter
Class HttpResponse

java.lang.Object
  extended by org.restlet.Message
      extended by org.restlet.Response
          extended by org.restlet.engine.adapter.HttpResponse

public class HttpResponse
extends Response

Response wrapper for server HTTP calls.

Author:
Jerome Louvel

Constructor Summary
HttpResponse(ServerCall httpCall, Request request)
          Constructor.
 
Method Summary
static void addHeader(Response response, String headerName, String headerValue)
          Adds a new header to the given request.
 Series<Header> getHeaders()
          Returns the HTTP headers.
 ServerCall getHttpCall()
          Returns the low-level HTTP call.
 ServerInfo getServerInfo()
          Returns the server-specific information.
 
Methods inherited from class org.restlet.Response
abort, commit, getAge, getAllowedMethods, getAuthenticationInfo, getChallengeRequests, getCookieSettings, getCurrent, getDimensions, getLocationRef, getProxyChallengeRequests, getRequest, getRetryAfter, getStatus, isAutoCommitting, isCommitted, isConfidential, isFinal, isProvisional, redirectPermanent, redirectPermanent, redirectSeeOther, redirectSeeOther, redirectTemporary, redirectTemporary, setAge, setAllowedMethods, setAuthenticationInfo, setAutoCommitting, setChallengeRequests, setCommitted, setCookieSettings, setCurrent, setDimensions, setLocationRef, setLocationRef, setProxyChallengeRequests, setRequest, setRetryAfter, setServerInfo, setStatus, setStatus, setStatus, setStatus, toString
 
Methods inherited from class org.restlet.Message
getAttributes, getCacheDirectives, getDate, getEntity, getEntityAsText, getOnError, getOnSent, getRecipientsInfo, getWarnings, isEntityAvailable, release, setAttributes, setCacheDirectives, setDate, setEntity, setEntity, setOnError, setOnSent, setRecipientsInfo, setWarnings
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

HttpResponse

public HttpResponse(ServerCall httpCall,
                    Request request)
Constructor.

Parameters:
httpCall - The low-level HTTP server call.
request - The associated high-level request.
Method Detail

addHeader

public static void addHeader(Response response,
                             String headerName,
                             String headerValue)
Adds a new header to the given request.

Parameters:
response - The response to update.
headerName - The header name to add.
headerValue - The header value to add.

getHeaders

public Series<Header> getHeaders()
Returns the HTTP headers.

Returns:
The HTTP headers.

getHttpCall

public ServerCall getHttpCall()
Returns the low-level HTTP call.

Returns:
The low-level HTTP call.

getServerInfo

public ServerInfo getServerInfo()
Returns the server-specific information.

Overrides:
getServerInfo in class Response
Returns:
The server-specific information.


Copyright © 2005-2013 Restlet.