|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectrestart.server.ServiceOutput
public class ServiceOutput
Class to describe the output of a service.
Field Summary | |
---|---|
static java.lang.String |
HTTP_VER
|
Constructor Summary | |
---|---|
ServiceOutput(ErrorCode errcode)
Default constructor |
|
ServiceOutput(RestException re)
|
Method Summary | |
---|---|
java.lang.String |
getContentEncoding()
Get the content encoding |
java.lang.String |
getContentType()
Get the content type (MIME) |
byte[] |
getData()
Get the data |
ErrorCode |
getErrCode()
Get the error code |
long |
getLength()
Get the length of the data |
java.lang.String |
getTransferEncoding()
Get the transfer encoding |
void |
setContentEncoding(java.lang.String contentEncoding)
Set the content encoding |
void |
setData(long length,
java.lang.String contentType,
byte[] data)
Set the data to be returned |
void |
setTransferEncoding(java.lang.String transferEncoding)
Set the transfer encoding |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String HTTP_VER
Constructor Detail |
---|
public ServiceOutput(ErrorCode errcode)
errcode
- the returned error code (one of HTTP's error codes)public ServiceOutput(RestException re)
Method Detail |
---|
public void setData(long length, java.lang.String contentType, byte[] data)
length
- lehgth of the datacontentType
- content type of the data (see MIME types)data
- the datapublic ErrorCode getErrCode()
public byte[] getData()
public long getLength()
public java.lang.String getContentType()
public java.lang.String getContentEncoding()
public void setContentEncoding(java.lang.String contentEncoding)
contentEncoding
- public java.lang.String getTransferEncoding()
public void setTransferEncoding(java.lang.String transferEncoding)
contentEncoding
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |