| java.lang.Object com.healthmarketscience.jackcess.TempBufferHolder
TempBufferHolder | abstract public class TempBufferHolder (Code) | | Manages a reference to a ByteBuffer.
author: James Ahlborn |
Inner Class :public enum Type | |
Method Summary | |
abstract public void | clear() Releases any referenced memory. | final public ByteBuffer | getBuffer(PageChannel pageChannel, int size) Returns a ByteBuffer of at least the given size, with the limit set to
the given size, and the predefined byteOrder. | abstract public ByteBuffer | getExistingBuffer() | public int | getModCount() | final public ByteBuffer | getPageBuffer(PageChannel pageChannel) Returns a ByteBuffer of at least the defined page size, with the limit
set to the page size, and the predefined byteOrder. | public static TempBufferHolder | newHolder(Type type, boolean autoRewind) Creates a new TempBufferHolder. | public static TempBufferHolder | newHolder(Type type, boolean autoRewind, ByteOrder order) Creates a new TempBufferHolder. | abstract protected void | setNewBuffer(ByteBuffer newBuffer) Sets a new buffer for this holder. |
TempBufferHolder | protected TempBufferHolder(boolean autoRewind, ByteOrder order)(Code) | | |
clear | abstract public void clear()(Code) | | Releases any referenced memory.
|
getBuffer | final public ByteBuffer getBuffer(PageChannel pageChannel, int size)(Code) | | Returns a ByteBuffer of at least the given size, with the limit set to
the given size, and the predefined byteOrder. Will be rewound iff
autoRewind is enabled for this buffer.
|
getExistingBuffer | abstract public ByteBuffer getExistingBuffer()(Code) | | null |
getModCount | public int getModCount()(Code) | | the modification count of the current buffer (this count ischanged every time the buffer is reallocated) |
getPageBuffer | final public ByteBuffer getPageBuffer(PageChannel pageChannel)(Code) | | Returns a ByteBuffer of at least the defined page size, with the limit
set to the page size, and the predefined byteOrder. Will be rewound iff
autoRewind is enabled for this buffer.
|
newHolder | public static TempBufferHolder newHolder(Type type, boolean autoRewind)(Code) | | Creates a new TempBufferHolder.
Parameters: type - the type of reference desired for any created buffer Parameters: autoRewind - whether or not every get automatically rewinds thebuffer |
newHolder | public static TempBufferHolder newHolder(Type type, boolean autoRewind, ByteOrder order)(Code) | | Creates a new TempBufferHolder.
Parameters: type - the type of reference desired for any created buffer Parameters: autoRewind - whether or not every get automatically rewinds thebuffer Parameters: order - byte order for all allocated buffers |
setNewBuffer | abstract protected void setNewBuffer(ByteBuffer newBuffer)(Code) | | Sets a new buffer for this holder.
|
|
|