Class Encap

    • Constructor Detail

      • Encap

        protected Encap()
      • Encap

        public Encap​(short cmd,
                     int sess,
                     int stat,
                     int opt)
    • Method Detail

      • decode

        public static Encap decode​(java.nio.ByteBuffer source)
      • decode

        public static Encap decode​(io.netty.buffer.ByteBuf source)
      • isValid

        public boolean isValid()
      • setBytes

        public final void setBytes​(java.nio.ByteBuffer source)
      • putBytes

        public void putBytes​(java.nio.ByteBuffer dest)
        Nio Support to deliver the whole packet
        Specified by:
        putBytes in interface CpfWrapper
      • writeBytes

        public io.netty.buffer.ByteBuf writeBytes​(io.netty.buffer.ByteBuf dest)
        Netty Support to deliver the entire packet
      • getCommand

        public short getCommand()
      • getExtralen

        public int getExtralen()
      • getSession

        public int getSession()
      • setSession

        public void setSession​(int session)
      • getStatus

        public int getStatus()
      • setStatus

        public void setStatus​(int status)
      • getContext

        public long getContext()
      • setContext

        public void setContext​(long context)
      • getOptions

        public int getOptions()
      • setPayload

        public void setPayload​(java.nio.ByteBuffer source)
      • putPayload

        public void putPayload​(java.nio.ByteBuffer dest)
      • writePayload

        public io.netty.buffer.ByteBuf writePayload​(io.netty.buffer.ByteBuf dest)
      • getError

        public java.lang.Throwable getError()
      • setError

        public void setError​(java.lang.Throwable error)
      • getAddressItem

        public CpfAddress getAddressItem()
        Description copied from interface: CpfWrapper
        Obtain the packet's Address CPF item, if present and in the first position.
        Specified by:
        getAddressItem in interface CpfWrapper
        Returns:
      • getDataItem

        public DataCPF getDataItem()
        Description copied from interface: CpfWrapper
        Obtain the packet's Data CPF item, if present and in the first or second position.
        Specified by:
        getDataItem in interface CpfWrapper
        Returns:
      • getItemCount

        public int getItemCount()
        Description copied from interface: CpfWrapper
        Obtain the number of CPF items wrapped in this packet.
        Specified by:
        getItemCount in interface CpfWrapper
        Returns:
      • getItem

        public CommonPacketFormat getItem​(int idx)
        Description copied from interface: CpfWrapper
        Given the index of an item in this packet's list of CPF items, return that item.
        Specified by:
        getItem in interface CpfWrapper
        Returns:
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object