org.apache.sling.testing.tools.http

## Class Request

- java.lang.Object
- - org.apache.sling.testing.tools.http.Request

    public class Request
    extends Object

Request class with convenience with... methods to add headers, parameters etc.

### Method Summary

All Methods Instance Methods Concrete Methods
`RequestCustomizer` `getCustomizer()`
`String` `getPassword()`
`boolean` `getRedirects()`
`org.apache.http.client.methods.HttpUriRequest` `getRequest()`
`String` `getUsername()`
`String` `toString()`
`Request` `withContent(String content)`
`Request` `withCredentials(String username, String password)`
`Request` `withCustomizer(RequestCustomizer c)`
`Request` `withEntity(org.apache.http.HttpEntity e)`
`Request` `withHeader(String name, String value)`
`Request` `withRedirects(boolean followRedirectsAutomatically)`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Method Detail

#### getRequest

    public org.apache.http.client.methods.HttpUriRequest getRequest()

#### toString

    public String toString()

Overrides:
  `toString` in class `Object`

#### withHeader

    public Request withHeader(String name,
                              String value)

#### withCredentials

    public Request withCredentials(String username,
                                   String password)

#### withRedirects

    public Request withRedirects(boolean followRedirectsAutomatically)

#### withContent

    public Request withContent(String content)
                        throws UnsupportedEncodingException

Throws:
  `UnsupportedEncodingException`

#### withEntity

    public Request withEntity(org.apache.http.HttpEntity e)
                       throws UnsupportedEncodingException

Throws:
  `UnsupportedEncodingException`

#### withCustomizer

    public Request withCustomizer(RequestCustomizer c)

#### getUsername

    public String getUsername()

#### getPassword

    public String getPassword()

#### getRedirects

    public boolean getRedirects()

#### getCustomizer

    public RequestCustomizer getCustomizer()