@Test public void testSkip() { try (ContiguousVirtualMemory mem = new ContiguousVirtualMemory(11, Integer.MAX_VALUE)) { mem.putByte((byte) 1); int n = 999; for (int i = n; i > 0; i--) { mem.putLong(i); mem.skip(3); } long o = 1; assertEquals(1, mem.getByte(0)); for (int i = n; i > 0; i--) { assertEquals(i, mem.getLong(o)); o += 11; } assertEquals(10990, mem.getAppendOffset()); } }
public void skip(long bytes) { checkLimits(bytes); appendAddress += bytes; }
ContiguousVirtualMemory implements Closeable { public void skip(long bytes) { checkLimits(bytes); appendAddress += bytes; } }
ContiguousVirtualMemory implements Closeable { public void skip(long bytes) { checkLimits(bytes); appendAddress += bytes; } ContiguousVirtualMemory(long pageSize, int maxPages); }
ContiguousVirtualMemory implements Closeable { public void skip(long bytes) { checkLimits(bytes); appendAddress += bytes; } ContiguousVirtualMemory(long pageSize, int maxPages); static int getStorageLength(CharSequence s); long addressOf(long offset); @Override void close(); final long getAppendOffset(); final BinarySequence getBin(long offset); final long getBinLen(long offset); boolean getBool(long offset); final byte getByte(long offset); final char getChar(long offset); final double getDouble(long offset); final float getFloat(long offset); final int getInt(long offset); long getLong(long offset); void getLong256(long offset, CharSink sink); void getLong256(long offset, Long256Sink sink); Long256 getLong256A(long offset); Long256 getLong256B(long offset); final short getShort(long offset); final CharSequence getStr(long offset); final CharSequence getStr0(long offset, CharSequenceView view); final CharSequence getStr2(long offset); final int getStrLen(long offset); long hash(long offset, long size); void jumpTo(long offset); final long putBin(BinarySequence value); final long putBin(long from, long len); void putBool(boolean value); void putBool(long offset, boolean value); final void putByte(long offset, byte value); void putByte(byte b); void putChar(long offset, char value); final void putChar(char value); void putDouble(long offset, double value); final void putDouble(double value); void putFloat(long offset, float value); final void putFloat(float value); void putInt(long offset, int value); final void putInt(int value); void putLong(long offset, long value); final void putLong(long value); final void putLong128(long l1, long l2); void putLong256(long offset, Long256 value); void putLong256(long offset, long l0, long l1, long l2, long l3); final void putLong256(long l0, long l1, long l2, long l3); final void putLong256(Long256 value); final void putLong256(CharSequence hexString); final void putLong256(@NotNull CharSequence hexString, int start, int end); final long putNullBin(); final long putNullStr(); final void putNullStr(long offset); void putShort(long offset, short value); final void putShort(short value); final long putStr(CharSequence value); final long putStr(char value); final long putStr(CharSequence value, int pos, int len); void putStr(long offset, CharSequence value); void putStr(long offset, CharSequence value, int pos, int len); void skip(long bytes); void zero(); }
ContiguousVirtualMemory implements Closeable { public void skip(long bytes) { checkLimits(bytes); appendAddress += bytes; } ContiguousVirtualMemory(long pageSize, int maxPages); static int getStorageLength(CharSequence s); long addressOf(long offset); @Override void close(); final long getAppendOffset(); final BinarySequence getBin(long offset); final long getBinLen(long offset); boolean getBool(long offset); final byte getByte(long offset); final char getChar(long offset); final double getDouble(long offset); final float getFloat(long offset); final int getInt(long offset); long getLong(long offset); void getLong256(long offset, CharSink sink); void getLong256(long offset, Long256Sink sink); Long256 getLong256A(long offset); Long256 getLong256B(long offset); final short getShort(long offset); final CharSequence getStr(long offset); final CharSequence getStr0(long offset, CharSequenceView view); final CharSequence getStr2(long offset); final int getStrLen(long offset); long hash(long offset, long size); void jumpTo(long offset); final long putBin(BinarySequence value); final long putBin(long from, long len); void putBool(boolean value); void putBool(long offset, boolean value); final void putByte(long offset, byte value); void putByte(byte b); void putChar(long offset, char value); final void putChar(char value); void putDouble(long offset, double value); final void putDouble(double value); void putFloat(long offset, float value); final void putFloat(float value); void putInt(long offset, int value); final void putInt(int value); void putLong(long offset, long value); final void putLong(long value); final void putLong128(long l1, long l2); void putLong256(long offset, Long256 value); void putLong256(long offset, long l0, long l1, long l2, long l3); final void putLong256(long l0, long l1, long l2, long l3); final void putLong256(Long256 value); final void putLong256(CharSequence hexString); final void putLong256(@NotNull CharSequence hexString, int start, int end); final long putNullBin(); final long putNullStr(); final void putNullStr(long offset); void putShort(long offset, short value); final void putShort(short value); final long putStr(CharSequence value); final long putStr(char value); final long putStr(CharSequence value, int pos, int len); void putStr(long offset, CharSequence value); void putStr(long offset, CharSequence value, int pos, int len); void skip(long bytes); void zero();  }