Class Asn1Buffer2

    • Constructor Detail

      • Asn1Buffer2

        public Asn1Buffer2()
        Create a new instance of Asn1Buffer2
    • Method Detail

      • getPos

        public int getPos()
        Returns:
        The current position in the buffer
      • put

        public void put​(byte b)
        Store a byte at the current position in the buffer
        Parameters:
        b - The byte to store
      • put

        public void put​(byte[] bytes)
        Store some bytes at the current position in the buffer
        Parameters:
        bytes - The bytes to store
      • getBytes

        public byte[] getBytes()
        Returns:
        The stored encoded PDU.
      • getSize

        public int getSize()
        Returns:
        The buffer size (ie the maximum number of bytes that can be added to this buffer before it gets extended).
      • clear

        public void clear()
        Clear the position, emptying the buffer. If it has grown, reallocate it to its initial size.