MySQL 5.6.14 Source Code Document
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
com.mysql.clusterj.tie.DbImpl.BufferManager Class Reference
Collaboration diagram for com.mysql.clusterj.tie.DbImpl.BufferManager:

Public Member Functions

void guaranteeStringStorageBufferSize (int sizeNeeded)
ByteBuffer copyStringToByteBuffer (CharSequence value)
void clearStringStorageBuffer ()
ByteBuffer getStringStorageBuffer (int sizeNeeded)
ByteBuffer getStringByteBuffer (int sizeNeeded)
CharBuffer getStringCharBuffer ()
ByteBuffer getResultDataBuffer (int sizeNeeded)

Static Public Attributes

static final int STRING_BYTE_BUFFER_INITIAL_SIZE = 1000
static final int STRING_STORAGE_BUFFER_INITIAL_SIZE = 500

Protected Member Functions

void guaranteeStringByteBufferSize (int sizeNeeded)

Detailed Description

Definition at line 248 of file DbImpl.java.

Member Function Documentation

void com.mysql.clusterj.tie.DbImpl.BufferManager.clearStringStorageBuffer ( )
inline

Reset the string storage buffer so it can be used for another operation.

Definition at line 308 of file DbImpl.java.

ByteBuffer com.mysql.clusterj.tie.DbImpl.BufferManager.copyStringToByteBuffer ( CharSequence  value)
inline

Copy the contents of the parameter String into a reused string buffer. The ByteBuffer can subsequently be encoded into a ByteBuffer.

Parameters
valuethe string
Returns
the byte buffer with the String in it

Definition at line 292 of file DbImpl.java.

Here is the call graph for this function:

ByteBuffer com.mysql.clusterj.tie.DbImpl.BufferManager.getResultDataBuffer ( int  sizeNeeded)
inline

Get the result data buffer. This buffer is used to hold the result of a key or scan operation.

Parameters
sizeNeededthe size that the buffer must be able to hold
Returns
the result data buffer

Definition at line 355 of file DbImpl.java.

CharBuffer com.mysql.clusterj.tie.DbImpl.BufferManager.getStringCharBuffer ( )
inline

Get the string char buffer. This buffer is paired with the string byte buffer. They share the same data but have independent position and limit.

Returns
the string char buffer

Definition at line 346 of file DbImpl.java.

void com.mysql.clusterj.tie.DbImpl.BufferManager.guaranteeStringByteBufferSize ( int  sizeNeeded)
inlineprotected

Guarantee the size of the string byte buffer to be a minimum size. If the current string byte buffer is not big enough, allocate a bigger one. The current buffer will be garbage collected.

Parameters
sizethe minimum size required

Definition at line 327 of file DbImpl.java.

Here is the caller graph for this function:

void com.mysql.clusterj.tie.DbImpl.BufferManager.guaranteeStringStorageBufferSize ( int  sizeNeeded)
inline

Guarantee the size of the string storage buffer to be a minimum size. If the current string storage buffer is not big enough, allocate a bigger one. The current buffer will be garbage collected.

Parameters
sizethe minimum size required

Definition at line 277 of file DbImpl.java.

Member Data Documentation

final int com.mysql.clusterj.tie.DbImpl.BufferManager.STRING_BYTE_BUFFER_INITIAL_SIZE = 1000
static

String byte buffer initial size

Definition at line 250 of file DbImpl.java.

final int com.mysql.clusterj.tie.DbImpl.BufferManager.STRING_STORAGE_BUFFER_INITIAL_SIZE = 500
static

String storage buffer initial size (used for non-primitive output data)

Definition at line 261 of file DbImpl.java.


The documentation for this class was generated from the following file: