@Test public void testSkipBitsNonByteAligned() { testArray.skipBits(5); assertReadBitsToEnd(5); }
public void skipBits(int numBits) { int numBytes = numBits / 8; byteOffset += numBytes; bitOffset += numBits - (numBytes * 8); if (bitOffset > 7) { byteOffset++; bitOffset -= 8; } assertValidOffset(); }
ParsableBitArray { public void skipBits(int numBits) { int numBytes = numBits / 8; byteOffset += numBytes; bitOffset += numBits - (numBytes * 8); if (bitOffset > 7) { byteOffset++; bitOffset -= 8; } assertValidOffset(); } }
ParsableBitArray { public void skipBits(int numBits) { int numBytes = numBits / 8; byteOffset += numBytes; bitOffset += numBits - (numBytes * 8); if (bitOffset > 7) { byteOffset++; bitOffset -= 8; } assertValidOffset(); } ParsableBitArray();  ParsableBitArray(byte[] data);  ParsableBitArray(byte[] data, int limit); }
ParsableBitArray { public void skipBits(int numBits) { int numBytes = numBits / 8; byteOffset += numBytes; bitOffset += numBits - (numBytes * 8); if (bitOffset > 7) { byteOffset++; bitOffset -= 8; } assertValidOffset(); } ParsableBitArray();  ParsableBitArray(byte[] data);  ParsableBitArray(byte[] data, int limit); void reset(byte[] data); void reset(ParsableByteArray parsableByteArray); void reset(byte[] data, int limit); int bitsLeft(); int getPosition(); int getBytePosition(); void setPosition(int position); void skipBit(); void skipBits(int numBits); boolean readBit(); int readBits(int numBits); void readBits(byte[] buffer, int offset, int numBits); void byteAlign(); void readBytes(byte[] buffer, int offset, int length); void skipBytes(int length); void putInt(int value, int numBits); }
ParsableBitArray { public void skipBits(int numBits) { int numBytes = numBits / 8; byteOffset += numBytes; bitOffset += numBits - (numBytes * 8); if (bitOffset > 7) { byteOffset++; bitOffset -= 8; } assertValidOffset(); } ParsableBitArray();  ParsableBitArray(byte[] data);  ParsableBitArray(byte[] data, int limit); void reset(byte[] data); void reset(ParsableByteArray parsableByteArray); void reset(byte[] data, int limit); int bitsLeft(); int getPosition(); int getBytePosition(); void setPosition(int position); void skipBit(); void skipBits(int numBits); boolean readBit(); int readBits(int numBits); void readBits(byte[] buffer, int offset, int numBits); void byteAlign(); void readBytes(byte[] buffer, int offset, int length); void skipBytes(int length); void putInt(int value, int numBits); public byte[] data; }