Class FlowTypeEncoder

    • Constructor Detail

      • FlowTypeEncoder

        public FlowTypeEncoder()
    • Method Detail

      • getDescriptorCode

        public UnsignedLong getDescriptorCode()
        the UnsignedLong value to use as the Descriptor for this type.
      • getDescriptorSymbol

        public Symbol getDescriptorSymbol()
        the Symbol value to use as the Descriptor for this type.
      • getTypeClass

        public java.lang.Class<Flow> getTypeClass()
        the Class type that this encoder handles.
      • getListEncoding

        public byte getListEncoding​(Flow value)
        Description copied from class: AbstractDescribedListTypeEncoder
        Determine the list type the given value can be encoded to based on the number of bytes that would be needed to hold the encoded form of the resulting list entries.

        Most encoders will return LIST32 but for cases where the type is known to be encoded to LIST8 or always encodes an empty list (LIST0) the encoder can optimize the encode step and not compute sizes.

        getListEncoding in class AbstractDescribedListTypeEncoder<Flow>
        value - The value that is to be encoded.
        the encoding code of the list type encoding needed for this object.
      • getElementCount

        public int getElementCount​(Flow flow)
        Description copied from class: AbstractDescribedListTypeEncoder
        Gets the number of elements that will result when this type is encoded into an AMQP List type.
        Specified by:
        getElementCount in class AbstractDescribedListTypeEncoder<Flow>
        flow - the value which will be encoded as a list type.
        the number of elements that should comprise the encoded list.