ClientBase (RabbIT/4)
Date: 2009-10-13

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

## rabbit.client
Class ClientBase

    java.lang.Object
      rabbit.client.ClientBase

    public class ClientBase

extends Object

A class for doing http requests.

Author:
  Robert Olofsson

Constructor Summary
`ClientBase()` Create a new ClientBase.

Method Summary
`ConnectionHandler` | `getConnectionHandler()`
`Logger` | `getLogger()`
`NioHandler` | `getNioHandler()`
`URL` | `getRedirectedURL(HttpHeader request, String location)` Create the url that the response redirected the request to.
`HttpHeader` | `getRequest(String method, String url)` Submit a new request, using the given method to the given url.
`void` | `sendRequest(HttpHeader request, ClientListener client)` Send a request and let the client be notified on response.
`void` | `shutdown()` Shutdown this client handler.

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

Constructor Detail

### ClientBase

    public ClientBase()
               throws IOException

  Create a new ClientBase.

  Throws:
    `IOException`

Method Detail

### getRequest

    public HttpHeader getRequest(String method,
                                 String url)
                          throws IOException

  Submit a new request, using the given method to the given url.

  Parameters:
    `method` - HEAD or GET or POST or ...
    `url` - the url to do the http request against.
  Throws:
    `IOException`

### getConnectionHandler

    public ConnectionHandler getConnectionHandler()

### getNioHandler

    public NioHandler getNioHandler()

### getLogger

    public Logger getLogger()

### shutdown

    public void shutdown()

  Shutdown this client handler.

### sendRequest

    public void sendRequest(HttpHeader request,
                            ClientListener client)
                     throws IOException

  Send a request and let the client be notified on response.

  Throws:
    `IOException`

### getRedirectedURL

    public URL getRedirectedURL(HttpHeader request,
                                String location)
                         throws IOException

  Create the url that the response redirected the request to.

  Throws:
    `IOException`

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