public abstract class PortableAbstractInputStream extends PortableAbstractStream implements PortableInputStream
| Modifier and Type | Field and Description |
|---|---|
protected int |
len
Length of data inside array.
|
BOOLEAN_ARR_OFF, BYTE_ARR_OFF, BYTE_ONE, BYTE_ZERO, CHAR_ARR_OFF, DOUBLE_ARR_OFF, FLOAT_ARR_OFF, INT_ARR_OFF, LITTLE_ENDIAN, LONG_ARR_OFF, pos, SHORT_ARR_OFF, UNSAFE| Constructor and Description |
|---|
PortableAbstractInputStream() |
| Modifier and Type | Method and Description |
|---|---|
protected abstract void |
copyAndShift(Object target,
long off,
int len)
Copy data to target object shift position afterwards.
|
protected void |
ensureEnoughData(int cnt)
Ensure that there is enough data.
|
long |
offheapPointer() |
void |
position(int pos) |
int |
read(byte[] arr,
int off,
int len)
Reads
cnt of bytes into byte array. |
boolean |
readBoolean()
Read boolean value.
|
boolean[] |
readBooleanArray(int cnt)
Read boolean array.
|
byte |
readByte()
Read byte value.
|
protected abstract byte |
readByteAndShift()
Read next byte from the stream and perform shift.
|
byte[] |
readByteArray(int cnt)
Read byte array.
|
char |
readChar()
Read char value.
|
char[] |
readCharArray(int cnt)
Read char array.
|
protected abstract char |
readCharFast()
Read char value (fast path).
|
double |
readDouble()
Read double value.
|
double[] |
readDoubleArray(int cnt)
Read double array.
|
float |
readFloat()
Read float value.
|
float[] |
readFloatArray(int cnt)
Read float array.
|
int |
readInt()
Read int value.
|
int |
readInt(int pos)
Read int value at the given position.
|
int[] |
readIntArray(int cnt)
Read int array.
|
protected abstract int |
readIntFast()
Read int value (fast path).
|
protected abstract int |
readIntPositioned(int pos)
Internal routine for positioned int value read.
|
long |
readLong()
Read long value.
|
long[] |
readLongArray(int cnt)
Read long array.
|
protected abstract long |
readLongFast()
Read long value (fast path).
|
short |
readShort()
Read short value.
|
short[] |
readShortArray(int cnt)
Read short array.
|
protected abstract short |
readShortFast()
Read short value (fast path).
|
position, shiftclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitremainingarray, arrayCopy, hasArray, positionpublic byte readByte()
readByte in interface PortableInputStreampublic byte[] readByteArray(int cnt)
readByteArray in interface PortableInputStreamcnt - Expected item count.public boolean readBoolean()
readBoolean in interface PortableInputStreampublic boolean[] readBooleanArray(int cnt)
readBooleanArray in interface PortableInputStreamcnt - Expected item count.public short readShort()
readShort in interface PortableInputStreampublic short[] readShortArray(int cnt)
readShortArray in interface PortableInputStreamcnt - Expected item count.public char readChar()
readChar in interface PortableInputStreampublic char[] readCharArray(int cnt)
readCharArray in interface PortableInputStreamcnt - Expected item count.public int readInt()
readInt in interface PortableInputStreampublic int[] readIntArray(int cnt)
readIntArray in interface PortableInputStreamcnt - Expected item count.public int readInt(int pos)
readInt in interface PortableInputStreampos - Position.public float readFloat()
readFloat in interface PortableInputStreampublic float[] readFloatArray(int cnt)
readFloatArray in interface PortableInputStreamcnt - Expected item count.public long readLong()
readLong in interface PortableInputStreampublic long[] readLongArray(int cnt)
readLongArray in interface PortableInputStreamcnt - Expected item count.public double readDouble()
readDouble in interface PortableInputStreampublic double[] readDoubleArray(int cnt)
readDoubleArray in interface PortableInputStreamcnt - Expected item count.public int read(byte[] arr,
int off,
int len)
cnt of bytes into byte array.read in interface PortableInputStreamarr - Expected item count.off - offsetlen - number of bytes to read.public void position(int pos)
position in interface PortableStreampos - Position.public long offheapPointer()
offheapPointer in interface PortableStream0.protected void ensureEnoughData(int cnt)
cnt - Length.protected abstract byte readByteAndShift()
protected abstract void copyAndShift(Object target, long off, int len)
target - Target.off - Offset.len - Length.protected abstract short readShortFast()
protected abstract char readCharFast()
protected abstract int readIntFast()
protected abstract long readLongFast()
protected abstract int readIntPositioned(int pos)
pos - Position.
Follow @ApacheIgnite
Ignite Fabric : ver. 1.4.0 Release Date : September 24 2015