ccc.client.core
Class Request

java.lang.Object
  extended by ccc.client.core.Request

public class Request
extends java.lang.Object

A HTTP request.

Author:
Civic Computing Ltd.

Constructor Summary
Request(HttpMethod method, java.lang.String path, java.lang.String body, ResponseHandler callback)
          Constructor.
 
Method Summary
 java.lang.String getBody()
          Accessor.
 ResponseHandler getCallback()
          Accessor.
 HttpMethod getMethod()
          Accessor.
 java.lang.String getPath()
          Accessor.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Request

public Request(HttpMethod method,
               java.lang.String path,
               java.lang.String body,
               ResponseHandler callback)
Constructor.

Parameters:
method - The request's HTTP method.
path - The request's path.
body - The request's body.
callback - The callback fired when the request completes.
Method Detail

getMethod

public HttpMethod getMethod()
Accessor.

Returns:
Returns the request method.

getBody

public java.lang.String getBody()
Accessor.

Returns:
The request body, as a string.

getPath

public java.lang.String getPath()
Accessor.

Returns:
The request path.

getCallback

public ResponseHandler getCallback()
Accessor.

Returns:
The callback to be invoked when the request completes.


Copyright © 2010. All Rights Reserved.