Class SqlJetDirectByteBuffer
- java.lang.Object
-
- org.tmatesoft.sqljet.core.internal.memory.SqlJetByteBuffer
-
- org.tmatesoft.sqljet.core.internal.memory.SqlJetDirectByteBuffer
-
- All Implemented Interfaces:
ISqlJetMemoryBuffer
public class SqlJetDirectByteBuffer extends SqlJetByteBuffer
- Author:
- TMate Software Ltd., Sergey Scherbina (sergey.scherbina@gmail.com)
-
-
Field Summary
-
Fields inherited from class org.tmatesoft.sqljet.core.internal.memory.SqlJetByteBuffer
buffer
-
-
Constructor Summary
Constructors Constructor Description SqlJetDirectByteBuffer()
SqlJetDirectByteBuffer(java.nio.ByteBuffer buffer)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
allocate(int size)
Allocate chunk of memory.byte[]
asArray()
void
fill(int from, int count, byte value)
void
getBytes(int pointer, byte[] bytes, int to, int count)
void
putBytes(int pointer, byte[] bytes, int from, int count)
-
Methods inherited from class org.tmatesoft.sqljet.core.internal.memory.SqlJetByteBuffer
compareTo, copyFrom, free, getByte, getByteUnsigned, getInt, getIntUnsigned, getLong, getPointer, getShort, getShortUnsigned, getSize, isAllocated, putByte, putByteUnsigned, putInt, putIntUnsigned, putLong, putShort, putShortUnsigned, readFromFile, writeToFile
-
-
-
-
Method Detail
-
allocate
public void allocate(int size)
Description copied from interface:ISqlJetMemoryBuffer
Allocate chunk of memory. If memory already has allocated then fries current chunk and allocates new.- Specified by:
allocate
in interfaceISqlJetMemoryBuffer
- Overrides:
allocate
in classSqlJetByteBuffer
- Parameters:
size
- size of chunk in bytes
-
asArray
public byte[] asArray()
- Specified by:
asArray
in interfaceISqlJetMemoryBuffer
- Overrides:
asArray
in classSqlJetByteBuffer
- Returns:
-
fill
public void fill(int from, int count, byte value)
- Specified by:
fill
in interfaceISqlJetMemoryBuffer
- Overrides:
fill
in classSqlJetByteBuffer
-
getBytes
public void getBytes(int pointer, byte[] bytes, int to, int count)
- Specified by:
getBytes
in interfaceISqlJetMemoryBuffer
- Overrides:
getBytes
in classSqlJetByteBuffer
-
putBytes
public void putBytes(int pointer, byte[] bytes, int from, int count)
- Specified by:
putBytes
in interfaceISqlJetMemoryBuffer
- Overrides:
putBytes
in classSqlJetByteBuffer
-
-