Overview | Package | Class | Tree | Deprecated | Index | Help
| GWT 2.0.3
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.google.gwt.http.client
Class Response

    java.lang.Object
      com.google.gwt.http.client.Response

    public abstract class Response

extends java.lang.Object

Wrapper which provides access to the components of an HTTP response.

### Required Module

Modules that use this class should inherit `com.google.gwt.http.HTTP`.

>     <module>
>       <!-- other inherited modules, such as com.google.gwt.user.User -->
>       <inherits name="com.google.gwt.http.HTTP"/>
>       <!-- additional module settings -->
>     </module>

Field Summary
`static int` | `SC_ACCEPTED`
`static int` | `SC_BAD_GATEWAY`
`static int` | `SC_BAD_REQUEST`
`static int` | `SC_CONFLICT`
`static int` | `SC_CONTINUE`
`static int` | `SC_CREATED`
`static int` | `SC_EXPECTATION_FAILED`
`static int` | `SC_FORBIDDEN`
`static int` | `SC_GATEWAY_TIMEOUT`
`static int` | `SC_GONE`
`static int` | `SC_HTTP_VERSION_NOT_SUPPORTED`
`static int` | `SC_INTERNAL_SERVER_ERROR`
`static int` | `SC_LENGTH_REQUIRED`
`static int` | `SC_METHOD_NOT_ALLOWED`
`static int` | `SC_MOVED_PERMANENTLY`
`static int` | `SC_MOVED_TEMPORARILY`
`static int` | `SC_MULTIPLE_CHOICES`
`static int` | `SC_NO_CONTENT`
`static int` | `SC_NON_AUTHORITATIVE_INFORMATION`
`static int` | `SC_NOT_ACCEPTABLE`
`static int` | `SC_NOT_FOUND`
`static int` | `SC_NOT_IMPLEMENTED`
`static int` | `SC_NOT_MODIFIED`
`static int` | `SC_OK`
`static int` | `SC_PARTIAL_CONTENT`
`static int` | `SC_PAYMENT_REQUIRED`
`static int` | `SC_PRECONDITION_FAILED`
`static int` | `SC_PROXY_AUTHENTICATION_REQUIRED`
`static int` | `SC_REQUEST_ENTITY_TOO_LARGE`
`static int` | `SC_REQUESTED_RANGE_NOT_SATISFIABLE`
`static int` | `SC_RESET_CONTENT`
`static int` | `SC_SEE_OTHER`
`static int` | `SC_SERVICE_UNAVAILABLE`
`static int` | `SC_SWITCHING_PROTOCOLS`
`static int` | `SC_TEMPORARY_REDIRECT`
`static int` | `SC_UNAUTHORIZED`
`static int` | `SC_UNSUPPORTED_MEDIA_TYPE`
`static int` | `SC_USE_PROXY`

Constructor Summary
`Response()`

Method Summary
`abstract java.lang.String` | `getHeader(java.lang.String header)` Returns the value of the requested header or null if the header was not specified.
`abstract Header[]` | `getHeaders()` Returns an array of HTTP headers associated with this response.
`abstract java.lang.String` | `getHeadersAsString()` Returns all headers as a single string.
`abstract int` | `getStatusCode()` Returns the HTTP status code that is part of this response.
`abstract java.lang.String` | `getStatusText()` Returns the HTTP status message text.
`abstract java.lang.String` | `getText()` Returns the text associated with the response.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### SC_ACCEPTED

    public static final int SC_ACCEPTED

See Also:
  Constant Field Values

### SC_BAD_GATEWAY

    public static final int SC_BAD_GATEWAY

See Also:
  Constant Field Values

### SC_BAD_REQUEST

    public static final int SC_BAD_REQUEST

See Also:
  Constant Field Values

### SC_CONFLICT

    public static final int SC_CONFLICT

See Also:
  Constant Field Values

### SC_CONTINUE

    public static final int SC_CONTINUE

See Also:
  Constant Field Values

### SC_CREATED

    public static final int SC_CREATED

See Also:
  Constant Field Values

### SC_EXPECTATION_FAILED

    public static final int SC_EXPECTATION_FAILED

See Also:
  Constant Field Values

### SC_FORBIDDEN

    public static final int SC_FORBIDDEN

See Also:
  Constant Field Values

### SC_GATEWAY_TIMEOUT

    public static final int SC_GATEWAY_TIMEOUT

See Also:
  Constant Field Values

### SC_GONE

    public static final int SC_GONE

See Also:
  Constant Field Values

### SC_HTTP_VERSION_NOT_SUPPORTED

    public static final int SC_HTTP_VERSION_NOT_SUPPORTED

See Also:
  Constant Field Values

### SC_INTERNAL_SERVER_ERROR

    public static final int SC_INTERNAL_SERVER_ERROR

See Also:
  Constant Field Values

### SC_LENGTH_REQUIRED

    public static final int SC_LENGTH_REQUIRED

See Also:
  Constant Field Values

### SC_METHOD_NOT_ALLOWED

    public static final int SC_METHOD_NOT_ALLOWED

See Also:
  Constant Field Values

### SC_MOVED_PERMANENTLY

    public static final int SC_MOVED_PERMANENTLY

See Also:
  Constant Field Values

### SC_MOVED_TEMPORARILY

    public static final int SC_MOVED_TEMPORARILY

See Also:
  Constant Field Values

### SC_MULTIPLE_CHOICES

    public static final int SC_MULTIPLE_CHOICES

See Also:
  Constant Field Values

### SC_NO_CONTENT

    public static final int SC_NO_CONTENT

See Also:
  Constant Field Values

### SC_NON_AUTHORITATIVE_INFORMATION

    public static final int SC_NON_AUTHORITATIVE_INFORMATION

See Also:
  Constant Field Values

### SC_NOT_ACCEPTABLE

    public static final int SC_NOT_ACCEPTABLE

See Also:
  Constant Field Values

### SC_NOT_FOUND

    public static final int SC_NOT_FOUND

See Also:
  Constant Field Values

### SC_NOT_IMPLEMENTED

    public static final int SC_NOT_IMPLEMENTED

See Also:
  Constant Field Values

### SC_NOT_MODIFIED

    public static final int SC_NOT_MODIFIED

See Also:
  Constant Field Values

### SC_OK

    public static final int SC_OK

See Also:
  Constant Field Values

### SC_PARTIAL_CONTENT

    public static final int SC_PARTIAL_CONTENT

See Also:
  Constant Field Values

### SC_PAYMENT_REQUIRED

    public static final int SC_PAYMENT_REQUIRED

See Also:
  Constant Field Values

### SC_PRECONDITION_FAILED

    public static final int SC_PRECONDITION_FAILED

See Also:
  Constant Field Values

### SC_PROXY_AUTHENTICATION_REQUIRED

    public static final int SC_PROXY_AUTHENTICATION_REQUIRED

See Also:
  Constant Field Values

### SC_REQUEST_ENTITY_TOO_LARGE

    public static final int SC_REQUEST_ENTITY_TOO_LARGE

See Also:
  Constant Field Values

### SC_REQUESTED_RANGE_NOT_SATISFIABLE

    public static final int SC_REQUESTED_RANGE_NOT_SATISFIABLE

See Also:
  Constant Field Values

### SC_RESET_CONTENT

    public static final int SC_RESET_CONTENT

See Also:
  Constant Field Values

### SC_SEE_OTHER

    public static final int SC_SEE_OTHER

See Also:
  Constant Field Values

### SC_SERVICE_UNAVAILABLE

    public static final int SC_SERVICE_UNAVAILABLE

See Also:
  Constant Field Values

### SC_SWITCHING_PROTOCOLS

    public static final int SC_SWITCHING_PROTOCOLS

See Also:
  Constant Field Values

### SC_TEMPORARY_REDIRECT

    public static final int SC_TEMPORARY_REDIRECT

See Also:
  Constant Field Values

### SC_UNAUTHORIZED

    public static final int SC_UNAUTHORIZED

See Also:
  Constant Field Values

### SC_UNSUPPORTED_MEDIA_TYPE

    public static final int SC_UNSUPPORTED_MEDIA_TYPE

See Also:
  Constant Field Values

### SC_USE_PROXY

    public static final int SC_USE_PROXY

See Also:
  Constant Field Values

Constructor Detail

### Response

    public Response()

Method Detail

### getHeader

    public abstract java.lang.String getHeader(java.lang.String header)

  Returns the value of the requested header or null if the header was not specified.

  Parameters:
    `header` - the header to query for
  Returns:
    the value of response header
  Throws:
    `java.lang.IllegalArgumentException` - if the header name is empty
    `java.lang.NullPointerException` - if the header name is null

### getHeaders

    public abstract Header[] getHeaders()

  Returns an array of HTTP headers associated with this response.

  Returns:
    array of HTTP headers; returns zero length array if there are no headers

### getHeadersAsString

    public abstract java.lang.String getHeadersAsString()

  Returns all headers as a single string. The individual headers are delimited by a CR (U+000D) LF (U+000A) pair. An individual header is formatted according to RFC 2616.

  Returns:
    all headers as a single string delimited by CRLF pairs

### getStatusCode

    public abstract int getStatusCode()

  Returns the HTTP status code that is part of this response.

  Returns:
    the HTTP status code

### getStatusText

    public abstract java.lang.String getStatusText()

  Returns the HTTP status message text.

  Returns:
    the HTTP status message text

### getText

    public abstract java.lang.String getText()

  Returns the text associated with the response.

  Returns:
    the response text

Overview | Package | Class | Tree | Deprecated | Index | Help
| GWT 2.0.3
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD