|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.spicefactory.cinnamon.io.netconnection.NetConnectionIoHandler
public class NetConnectionIoHandler
Cinnamons default IoHandler implementation that should be used in conjunction
with the client-side NetConnectionServiceChannel. The AS3 NetConnection
class may wrap multiple requests in a single "envelope" and this implementation knows how to
decode that envelope before decoding the AMF3 payloads of the request.
| Field Summary | |
|---|---|
static String |
ERROR_CALLBACK
|
static String |
RESULT_CALLBACK
|
| Constructor Summary | |
|---|---|
NetConnectionIoHandler()
|
|
| Method Summary | |
|---|---|
Envelope |
createResponseEnvelope(Envelope requestEnvelope)
Creates a new Envelope to be used for the response sent to the client |
MessageHolder |
createResponseMessage(MessageHolder requestMessage,
Object message,
boolean isError)
Creates a new response messages for the specified request message and result object. |
Envelope |
decodeAMF(AMFInput input)
Reads and returns the AMF envelope containing all AMF request messages from the specified input. |
void |
encodeAMF(AMFOutput output,
Envelope envelope)
Encodes and writes the specified envelope containing all response messages to the output. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String RESULT_CALLBACK
public static final String ERROR_CALLBACK
| Constructor Detail |
|---|
public NetConnectionIoHandler()
| Method Detail |
|---|
public Envelope decodeAMF(AMFInput input)
IoHandler
decodeAMF in interface IoHandlerinput - the AMF input to read from
public void encodeAMF(AMFOutput output,
Envelope envelope)
IoHandler
encodeAMF in interface IoHandleroutput - the AMF output to write toenvelope - the envelope containing all AMF response messagespublic Envelope createResponseEnvelope(Envelope requestEnvelope)
IoHandler
createResponseEnvelope in interface IoHandlerrequestEnvelope - the corresponding request envelope
public MessageHolder createResponseMessage(MessageHolder requestMessage,
Object message,
boolean isError)
IoHandler
createResponseMessage in interface IoHandlerrequestMessage - the request message that was processedmessage - the message to sent as a responseisError - whether the response message represents an error
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||