Package org.nustaq.offheap.bytez
Interface BasicBytez
- All Superinterfaces:
ByteSink
,ByteSource
- All Known Subinterfaces:
Bytez
- All Known Implementing Classes:
ByteBufferBasicBytez
,HeapBytez
,MallocBytez
,MemoryBytez
,MMFBytez
Created by ruedi on 08.11.2014.
basic memory abstraction
-
Method Summary
Modifier and TypeMethodDescriptionvoid
copyTo
(BasicBytez other, long otherByteIndex, long myByteIndex, long lenBytes) byte
get
(long byteIndex) void
getArr
(long byteIndex, byte[] target, int elemoff, int numElems) copy to a byte arrayboolean
getBool
(long byteIndex) void
getBooleanArr
(long byteIndex, boolean[] target, int elemoff, int numElems) see getArrchar
getChar
(long byteIndex) void
getCharArr
(long byteIndex, char[] target, int elemoff, int numElems) see getArrdouble
getDouble
(long byteIndex) void
getDoubleArr
(long byteIndex, double[] target, int elemoff, int numElems) see getArrfloat
getFloat
(long byteIndex) void
getFloatArr
(long byteIndex, float[] target, int elemoff, int numElems) see getArrint
getInt
(long byteIndex) void
getIntArr
(long byteIndex, int[] target, int elemoff, int numElems) see getArrlong
getLong
(long byteIndex) void
getLongArr
(long byteIndex, long[] target, int elemoff, int numElems) see getArrshort
getShort
(long byteIndex) void
getShortArr
(long byteIndex, short[] target, int elemoff, int numElems) see getArrlong
length()
newInstance
(long size) void
put
(long byteIndex, byte value) void
putBool
(long byteIndex, boolean val) void
putChar
(long byteIndex, char c) void
putDouble
(long byteIndex, double d) void
putFloat
(long byteIndex, float f) void
putInt
(long byteIndex, int i) void
putLong
(long byteIndex, long l) void
putShort
(long byteIndex, short s) void
set
(long byteIndex, byte[] source, int elemoff, int numElems) void
setBoolean
(long byteIndex, boolean[] o, int i, int siz) void
setChar
(long byteIndex, char[] source, int elemoff, int numElems) void
setDouble
(long byteIndex, double[] source, int elemoff, int numElems) void
setFloat
(long byteIndex, float[] source, int elemoff, int numElems) void
setInt
(long byteIndex, int[] source, int elemoff, int numElems) void
setLong
(long byteIndex, long[] source, int elemoff, int numElems) void
setShort
(long byteIndex, short[] source, int elemoff, int numElems)
-
Method Details
-
get
byte get(long byteIndex) - Specified by:
get
in interfaceByteSource
-
getBool
boolean getBool(long byteIndex) -
getChar
char getChar(long byteIndex) -
getShort
short getShort(long byteIndex) -
getInt
int getInt(long byteIndex) -
getLong
long getLong(long byteIndex) -
getFloat
float getFloat(long byteIndex) -
getDouble
double getDouble(long byteIndex) -
put
void put(long byteIndex, byte value) -
putBool
void putBool(long byteIndex, boolean val) -
putChar
void putChar(long byteIndex, char c) -
putShort
void putShort(long byteIndex, short s) -
putInt
void putInt(long byteIndex, int i) -
putLong
void putLong(long byteIndex, long l) -
putFloat
void putFloat(long byteIndex, float f) -
putDouble
void putDouble(long byteIndex, double d) -
length
long length()- Specified by:
length
in interfaceByteSink
- Specified by:
length
in interfaceByteSource
-
getArr
void getArr(long byteIndex, byte[] target, int elemoff, int numElems) copy to a byte array- Parameters:
byteIndex
- - offset index in this buffer to start copyingtarget
- - array to copy toelemoff
- - offset in target arraynumElems
- - length to copy to
-
getCharArr
void getCharArr(long byteIndex, char[] target, int elemoff, int numElems) see getArr -
getShortArr
void getShortArr(long byteIndex, short[] target, int elemoff, int numElems) see getArr -
getIntArr
void getIntArr(long byteIndex, int[] target, int elemoff, int numElems) see getArr -
getLongArr
void getLongArr(long byteIndex, long[] target, int elemoff, int numElems) see getArr -
getFloatArr
void getFloatArr(long byteIndex, float[] target, int elemoff, int numElems) see getArr -
getDoubleArr
void getDoubleArr(long byteIndex, double[] target, int elemoff, int numElems) see getArr -
getBooleanArr
void getBooleanArr(long byteIndex, boolean[] target, int elemoff, int numElems) see getArr -
set
void set(long byteIndex, byte[] source, int elemoff, int numElems) -
setChar
void setChar(long byteIndex, char[] source, int elemoff, int numElems) -
setShort
void setShort(long byteIndex, short[] source, int elemoff, int numElems) -
setInt
void setInt(long byteIndex, int[] source, int elemoff, int numElems) -
setLong
void setLong(long byteIndex, long[] source, int elemoff, int numElems) -
setFloat
void setFloat(long byteIndex, float[] source, int elemoff, int numElems) -
setDouble
void setDouble(long byteIndex, double[] source, int elemoff, int numElems) -
setBoolean
void setBoolean(long byteIndex, boolean[] o, int i, int siz) -
copyTo
-
newInstance
-