Class AmqpSequenceTypeEncoder
java.lang.Object
org.apache.qpid.protonj2.codec.encoders.AbstractDescribedTypeEncoder<AmqpSequence>
org.apache.qpid.protonj2.codec.encoders.messaging.AmqpSequenceTypeEncoder
- All Implemented Interfaces:
DescribedTypeEncoder<AmqpSequence>
,TypeEncoder<AmqpSequence>
Encoder of AMQP AmqpSequence type values to a byte stream.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
writeArray
(ProtonBuffer buffer, EncoderState state, Object[] values) Write an array elements of the AMQP type to the given byte buffer.void
writeRawArray
(ProtonBuffer buffer, EncoderState state, Object[] values) Write an array elements of the AMQP type to the given byte buffer.void
writeType
(ProtonBuffer buffer, EncoderState state, AmqpSequence value) Write the full AMQP type data to the given byte buffer.Methods inherited from class org.apache.qpid.protonj2.codec.encoders.AbstractDescribedTypeEncoder
isArrayType
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.apache.qpid.protonj2.codec.DescribedTypeEncoder
encoderRegistered
-
Constructor Details
-
AmqpSequenceTypeEncoder
public AmqpSequenceTypeEncoder()
-
-
Method Details
-
getTypeClass
- Returns:
- the Class type that this encoder handles.
-
getDescriptorCode
- Returns:
- the UnsignedLong value to use as the Descriptor for this type.
-
getDescriptorSymbol
- Returns:
- the Symbol value to use as the Descriptor for this type.
-
writeType
Description copied from interface:TypeEncoder
Write the full AMQP type data to the given byte buffer.This can consist of writing both a type constructor value and the bytes that make up the value of the type being written.
- Parameters:
buffer
- The buffer to write the AMQP type tostate
- The current encoder statevalue
- The value that is to be written.
-
writeArray
Description copied from interface:TypeEncoder
Write an array elements of the AMQP type to the given byte buffer.This method writes the full Array type definition of an array of the type this encoder manages.
- Parameters:
buffer
- The buffer to write the AMQP array elements tostate
- The current encoder statevalues
- The array of values that is to be written.
-
writeRawArray
Description copied from interface:TypeEncoder
Write an array elements of the AMQP type to the given byte buffer.This method writes only the body portion of an AMQP array of this type, the array encoding, size and element count should be assumed to be managed by the caller.
- Parameters:
buffer
- The buffer to write the AMQP array elements tostate
- The current encoder statevalues
- The array of values that is to be written.
-