vle.domain.webservice.http
Class HttpPostRequest
java.lang.Object
vle.domain.webservice.http.AbstractHttpRequest
vle.domain.webservice.http.HttpPostRequest
public final class HttpPostRequest
- extends AbstractHttpRequest
Immutable and thread-safe class to encapsulate data required for a post
request (headers, parameters, body, relativeUrl and expected response).
- Version:
- $Id$
- Author:
- Cynick Young
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
HttpPostRequest
public HttpPostRequest(Map<String,String> requestHeaders,
Map<String,String> requestParameters,
String bodyData,
String relativeUrl,
int expectedResponseStatusCode)
throws BadHeaderException
- Creates an HttpPostRequest object with all of the data required.
- Parameters:
requestHeaders - is a map of HTTP request headersrequestParameters - is a map of HTTP request parametersbodyData - is the serialized string of the body of a POST requestrelativeUrl - is the target relative URL for this requestexpectedResponseStatusCode - is the HTTP status code that is expected to be returned by the
server
- Throws:
BadHeaderException - if the request headers contain any illegal characters either
in the request field name or the request field value
getBodyData
public String getBodyData()
- Returns the body data for this request.
- Returns:
- the bodyData
Copyright © 2012. All Rights Reserved.