|
FRODO Version 2.19.1
An open-source framework for Distributed Constraint Optimization (DCOP)
|
A message containing data that must be custom-serialized. More...

Classes | |
| interface | RawDataHandler |
| This class is responsible for handling the raw data. More... | |
Public Member Functions | |
| MessageWithRawData () | |
| Empty constructor used for externalization. | |
| void | writeExternal (ObjectOutput out) throws IOException |
| void | readExternal (ObjectInput in) throws IOException, ClassNotFoundException |
| MessageWithRawData (MessageType type) | |
| Constructor. | |
| RawDataHandler | getHandler () |
| void | setHandler (RawDataHandler handler) |
| Sets the raw data handler for this message. | |
| abstract void | serializeRawData (ObjectOutputStream stream) |
| Serializes this message's raw data into the given stream. | |
| ObjectInputStream | getRawData () |
| abstract void | deserializeRawData () |
| Deserializes the raw data by reading it from the output of MessageWithRawData.getRawData(). | |
| Public Member Functions inherited from frodo2.communication.Message | |
| Message (MessageType type) | |
| Constructor. | |
| Message () | |
| Empty constructor. | |
| MessageType | getType () |
| String | toString () |
| void | fakeSerialize () |
| Pretends to serialize the message. | |
Protected Member Functions | |
| void | finalize () throws Throwable |
| Discards the raw data. | |
Protected Attributes | |
| RawDataHandler | handler |
| The object used to handle the raw data. | |
| Protected Attributes inherited from frodo2.communication.Message | |
| MessageType | type |
| The type of this message. | |
Private Attributes | |
| transient Object | rawDataHandler_lock = new Object () |
| Object used to synchronize access to the raw data handler. | |
A message containing data that must be custom-serialized.
| frodo2.communication.MessageWithRawData.MessageWithRawData | ( | ) |
Empty constructor used for externalization.
| frodo2.communication.MessageWithRawData.MessageWithRawData | ( | MessageType | type | ) |
|
abstract |
Deserializes the raw data by reading it from the output of MessageWithRawData.getRawData().
Reimplemented in frodo2.communication.MessageSerializedSimple< T extends Serializable >.
|
protected |
| RawDataHandler frodo2.communication.MessageWithRawData.getHandler | ( | ) |
References handler, and rawDataHandler_lock.
Referenced by frodo2.communication.tcp.QueueOutputPipeTCP.run().
| ObjectInputStream frodo2.communication.MessageWithRawData.getRawData | ( | ) |
References handler.
Referenced by frodo2.communication.MessageSerializedSimple< T extends Serializable >.deserializeRawData().
| void frodo2.communication.MessageWithRawData.readExternal | ( | ObjectInput | in | ) | throws IOException, ClassNotFoundException |
Reimplemented from frodo2.communication.Message.
|
abstract |
Serializes this message's raw data into the given stream.
| stream | output stream to which the raw data should be written |
Reimplemented in frodo2.communication.MessageSerializedSimple< T extends Serializable >.
Referenced by frodo2.communication.tcp.QueueOutputPipeTCP.RawDataSender.run().
| void frodo2.communication.MessageWithRawData.setHandler | ( | RawDataHandler | handler | ) |
Sets the raw data handler for this message.
| handler | the handler to set |
References handler, and rawDataHandler_lock.
Referenced by frodo2.communication.tcp.QueueOutputPipeTCP.run().
| void frodo2.communication.MessageWithRawData.writeExternal | ( | ObjectOutput | out | ) | throws IOException |
Reimplemented from frodo2.communication.Message.
|
protected |
The object used to handle the raw data.
Referenced by finalize(), getHandler(), getRawData(), and setHandler().
|
private |
Object used to synchronize access to the raw data handler.
We cannot directly synchronize over handler because it can be null.
Referenced by getHandler(), and setHandler().