Package org.yamcs.yarch
Class ParameterValueColumnSerializer
java.lang.Object
org.yamcs.yarch.ParameterValueColumnSerializer
- All Implemented Interfaces:
ColumnSerializer<ParameterValue>
public class ParameterValueColumnSerializer
extends Object
implements ColumnSerializer<ParameterValue>
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiondeserialize
(ByteBuffer byteBuf, ColumnDefinition cd) Same as above but read the data from a ByteBuffer.deserialize
(ByteArray byteArray, ColumnDefinition cd) Read one column value (i.e. a cell from the stream) The enums are deserialized as shorts (it is converted to the actual type in theTableDefinition.deserialize(byte[], byte[])
)void
serialize
(ByteBuffer byteBuf, ParameterValue pv) Same as above but serialize into a bytebuffer.void
serialize
(ByteArray byteArray, ParameterValue pv) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.yamcs.yarch.ColumnSerializer
fromByteArray, toByteArray
-
Constructor Details
-
ParameterValueColumnSerializer
public ParameterValueColumnSerializer()
-
-
Method Details
-
deserialize
Description copied from interface:ColumnSerializer
Read one column value (i.e. a cell from the stream) The enums are deserialized as shorts (it is converted to the actual type in theTableDefinition.deserialize(byte[], byte[])
)- Specified by:
deserialize
in interfaceColumnSerializer<ParameterValue>
- Parameters:
byteArray
- - array used for the inputcd
- the column definition for the involved column (can be used to look up column name or other properties to help in deserialization)- Returns:
- the deserialized value
-
deserialize
Description copied from interface:ColumnSerializer
Same as above but read the data from a ByteBuffer.If the buffer is not long enough, it throws an
BufferUnderflowException
.- Specified by:
deserialize
in interfaceColumnSerializer<ParameterValue>
- Returns:
-
serialize
- Specified by:
serialize
in interfaceColumnSerializer<ParameterValue>
-
serialize
Description copied from interface:ColumnSerializer
Same as above but serialize into a bytebuffer. If the ByteBuffer is not large enough, aBufferOverflowException
will be thrown.- Specified by:
serialize
in interfaceColumnSerializer<ParameterValue>
-
toProto
-