code: public void decode(byte[] header, ByteBuffer buffer) throws IOException
     {
        DataInputStream in = new DataInputStream(new ByteBufferInputStream(buffer));
  
        // byte 0
        int b0 = in.readUnsignedByte();
        this.setPeripheralQualifier(b0 >>> 5);
        this.setPeripheralDeviceType(b0 & 0x1F);
  
        // byte 1
        int b1 = in.readUnsignedByte();
  
        if (b1 != PAGE_CODE)
        {
           throw new IOException("invalid page code: " + Integer.toHexString(b1));
        }
  
        this.setPageCode(b1);
  
        // byte 2
        in.readUnsignedByte();
  
        // byte 3
        int b3 = in.readUnsignedByte();
  
        // supported codes list
        for (int i = b3; i > 0; i--)
        {
           this.supportedCodes.add(in.readUnsignedByte());
        }
     }
docs: constructors