|
EAF 7.6 Implementation | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.lutris.appserver.server.httpPresentation.HttpSerialized
public class HttpSerialized
This class provides two utility methods for presentation objects that want to read and/or write Java serialized objects.
Reading is accomplished by having the client issue a POST request, with the serialized data as the body of the request.
Writing is accomplished by simply sending out the serialized bytes.
Serializable
Field Summary | |
---|---|
static java.lang.String |
serializedMimeType
The mime type used to send and recieve Java serialized objects. |
Constructor Summary | |
---|---|
HttpSerialized()
|
Method Summary | |
---|---|
static java.lang.Object |
readSerializedObject(HttpPresentationComms comms)
Read in a Java object from a POST request. |
static java.lang.Object |
readSerializedObject(com.lutris.appserver.server.httpPresentation.HttpPresentationRequest request)
Read in a Java object from a POST request. |
static void |
writeSerializedObject(HttpPresentationComms comms,
java.io.Serializable object)
Return a serialized Java object to the client. |
static void |
writeSerializedObject(com.lutris.appserver.server.httpPresentation.HttpPresentationResponse response,
java.io.Serializable object)
Return a serialized Java object to the client. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String serializedMimeType
Constructor Detail |
---|
public HttpSerialized()
Method Detail |
---|
public static java.lang.Object readSerializedObject(com.lutris.appserver.server.httpPresentation.HttpPresentationRequest request) throws com.lutris.appserver.server.httpPresentation.HttpPresentationException
request
- HTTP communication request.
HttpPresentationException
- If the request is not of type POST, or the content type is not
correct, or there is an IO or serialization error.public static java.lang.Object readSerializedObject(HttpPresentationComms comms) throws com.lutris.appserver.server.httpPresentation.HttpPresentationException
comms
- HTTP communications object. Contains objects and interfaces to read
the request and send a response.
HttpPresentationException
- If the request is not of type POST, or the content type is not
correct, or there is an IO or serialization error.public static void writeSerializedObject(com.lutris.appserver.server.httpPresentation.HttpPresentationResponse response, java.io.Serializable object) throws com.lutris.appserver.server.httpPresentation.HttpPresentationException
comms
- HTTP Response object. interface to send a response.object
- The object to return to the client.
HttpPresentationException
- If there is an error serializing the object, or an error in the
underlying calls to response.public static void writeSerializedObject(HttpPresentationComms comms, java.io.Serializable object) throws com.lutris.appserver.server.httpPresentation.HttpPresentationException
comms
- HTTP communications object. Contains objects and interfaces to read
the request and send a response.object
- The object to return to the client.
HttpPresentationException
- If there is an error serializing the object, or an error in the
underlying calls to response.
|
EAF 7.6 Implementation | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |