Class Field


  • public class Field
    extends Object
    • Field Detail

      • buffer

        protected byte[] buffer
      • offset

        protected int offset
      • length

        protected int length
    • Constructor Detail

      • Field

        public Field​(byte[] bytes)
        ByteSegment constructor comment.
      • Field

        public Field​(byte[] bytes,
                     int length)
        ByteSegment constructor comment.
      • Field

        public Field​(byte[] bytes,
                     int offset,
                     int length)
        ByteSegment constructor comment.
      • Field

        public Field​(int length)
        Creates a new field containing an empty buffer of the given length.
    • Method Detail

      • buffer

        public byte[] buffer()
      • buffer

        public Field buffer​(byte[] buffer)
      • clear

        public Field clear()
      • clear

        protected static void clear​(byte[] buffer,
                                    int offset,
                                    int length)
      • clear

        public Field clear​(int length)
      • clear

        public Field clear​(int offset,
                           int length)
      • compare

        protected static int compare​(byte[] buffer1,
                                     int offset1,
                                     int length1,
                                     byte[] buffer2,
                                     int offset2,
                                     int length2)
      • compare

        public static int compare​(Field f1,
                                  Field f2)
      • copy

        public Field copy​(int fromOffset,
                          int toOffset,
                          int length)
      • dec

        public Field dec​(int n)
      • get

        public byte[] get()
      • get

        public byte[] get​(int offset,
                          int length)
      • getField

        public Field getField​(int offset,
                              int length)
      • getInt1

        public int getInt1()
      • getInt1

        public int getInt1​(int offset)
      • getInt2

        public int getInt2()
      • getInt2

        public int getInt2​(int offset)
      • getInt3

        public int getInt3()
      • getInt3

        public int getInt3​(int offset)
      • getInt4

        public int getInt4()
      • getInt4

        public int getInt4​(int offset)
      • getUInt1

        public int getUInt1()
      • getUInt1

        public int getUInt1​(int offset)
      • getUInt2

        public int getUInt2()
      • getUInt2

        public int getUInt2​(int offset)
      • getUInt3

        public int getUInt3()
      • getUInt3

        public int getUInt3​(int offset)
      • inc

        public Field inc​(int n)
      • length

        public int length()
      • length

        public Field length​(int length)
      • offset

        public int offset()
        Returns the offset into the underlying byte array that this field is defined over.
      • offset

        public Field offset​(int offset)
      • pointTo

        public Field pointTo​(int offset)
      • put

        public Field put​(byte[] b)
      • put

        public Field put​(int offset,
                         byte[] b)
      • put

        public Field put​(int offset,
                         Field f)
      • putInt1

        public Field putInt1​(int n)
      • putInt1

        public Field putInt1​(int offset,
                             int n)
      • putInt2

        public Field putInt2​(int n)
      • putInt2

        public Field putInt2​(int offset,
                             int n)
      • putInt3

        public Field putInt3​(int n)
      • putInt3

        public Field putInt3​(int offset,
                             int n)
      • putInt4

        public Field putInt4​(int n)
      • putInt4

        public Field putInt4​(int offset,
                             int n)
      • putUTF

        public int putUTF​(int offset,
                          char[] str)