Package io.datarouter.bytes
Class ByteReader
java.lang.Object
io.datarouter.bytes.ByteReader
public class ByteReader extends Object
-
Constructor Summary
Constructors Constructor Description ByteReader(byte[] bytes)ByteReader(byte[] bytes, int cursor) -
Method Summary
Modifier and Type Method Description voidassertFinished()booleanbooleanByte()byte[]bytes(int num)longcomparableLong()StringcomparableUtf8()booleanhasMore()intposition()intrawInt()int[]rawInts(int count)longrawLong()long[]rawLongs(int count)intskip(int numBytes)intskipInts(int num)intskipLongs(int num)byte[]varBytes()intvarInt()int[]varInts(int count)longvarLong()StringvarUtf8()
-
Constructor Details
-
ByteReader
public ByteReader(byte[] bytes, int cursor) -
ByteReader
public ByteReader(byte[] bytes)
-
-
Method Details
-
position
public int position() -
skip
public int skip(int numBytes) -
hasMore
public boolean hasMore() -
assertFinished
public void assertFinished() -
booleanByte
public boolean booleanByte() -
skipInts
public int skipInts(int num) -
rawInt
public int rawInt() -
rawInts
public int[] rawInts(int count) -
varInt
public int varInt() -
varInts
public int[] varInts(int count) -
skipLongs
public int skipLongs(int num) -
comparableLong
public long comparableLong() -
rawLong
public long rawLong() -
rawLongs
public long[] rawLongs(int count) -
varLong
public long varLong() -
bytes
public byte[] bytes(int num) -
varBytes
public byte[] varBytes() -
comparableUtf8
-
varUtf8
-