org.daisy.pipeline.client
Class Pipeline2WSResponse
java.lang.Object
org.daisy.pipeline.client.Pipeline2WSResponse
public class Pipeline2WSResponse
- extends java.lang.Object
Constructor Summary |
Pipeline2WSResponse(int status,
java.lang.String statusName,
java.lang.String statusDescription,
java.io.InputStream bodyStream)
Creates a new Pipeline2WSResponse with the given HTTP status code, status name, status description and content body. |
Method Summary |
java.io.InputStream |
asStream()
Returns the response body as a InputStream. |
java.lang.String |
asText()
Returns the response body as a String. |
org.w3c.dom.Document |
asXml()
Returns the response body as an XML Document. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
status
public int status
statusName
public java.lang.String statusName
statusDescription
public java.lang.String statusDescription
Pipeline2WSResponse
public Pipeline2WSResponse(int status,
java.lang.String statusName,
java.lang.String statusDescription,
java.io.InputStream bodyStream)
- Creates a new Pipeline2WSResponse with the given HTTP status code, status name, status description and content body.
- Parameters:
status
- statusName
- statusDescription
- bodyStream
-
asStream
public java.io.InputStream asStream()
throws Pipeline2WSException
- Returns the response body as a InputStream.
- Returns:
-
- Throws:
Pipeline2WSException
asText
public java.lang.String asText()
throws Pipeline2WSException
- Returns the response body as a String.
- Returns:
-
- Throws:
Pipeline2WSException
asXml
public org.w3c.dom.Document asXml()
throws Pipeline2WSException
- Returns the response body as an XML Document.
- Returns:
-
- Throws:
Pipeline2WSException