Class AbstractMessageSerializer<T extends OfHeader>
java.lang.Object
org.opendaylight.openflowplugin.impl.protocol.serialization.messages.AbstractMessageSerializer<T>
- All Implemented Interfaces:
HeaderSerializer<T>
,OFGeneralSerializer
,OFSerializer<T>
- Direct Known Subclasses:
AsyncConfigMessageSerializer
,FlowMessageSerializer
,GroupMessageSerializer
,MeterMessageSerializer
,MultipartRequestMessageSerializer
,PortMessageSerializer
public abstract class AbstractMessageSerializer<T extends OfHeader>
extends Object
implements OFSerializer<T>, HeaderSerializer<T>
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected abstract byte
Message type getter.void
Transforms POJO/DTO into byte message (ByteBuf).void
serializeHeader
(T message, io.netty.buffer.ByteBuf outBuffer) Serializes object headers (e.g.
-
Constructor Details
-
AbstractMessageSerializer
public AbstractMessageSerializer()
-
-
Method Details
-
serialize
Description copied from interface:OFSerializer
Transforms POJO/DTO into byte message (ByteBuf).- Specified by:
serialize
in interfaceOFSerializer<T extends OfHeader>
- Parameters:
message
- object to be serializedoutBuffer
- output buffer
-
serializeHeader
Description copied from interface:HeaderSerializer
Serializes object headers (e.g. for Multipart message - Table Features).- Specified by:
serializeHeader
in interfaceHeaderSerializer<T extends OfHeader>
- Parameters:
message
- object whose headers should be serializedoutBuffer
- output buffer
-
getMessageType
protected abstract byte getMessageType()Message type getter.- Returns:
- of message type
-