GlueGen v2.6.0-rc-20250712
GlueGen, Native Binding Generator for Java™ (public API).
com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer > Class Template Referenceabstract
Inheritance diagram for com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >:
Collaboration diagram for com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >:

Public Member Functions

final int elementSize ()
 
final int limit ()
 
final B limit (final int newLim)
 
final int capacity ()
 
final int position ()
 
final B position (final int newPos)
 
final int remaining ()
 
final boolean hasRemaining ()
 
final B clear ()
 
final B flip ()
 
final B rewind ()
 
final Buffer getBuffer ()
 
final boolean isDirect ()
 
long getDirectBufferAddress ()
 
void storeDirectAddress (final ByteBuffer directDest)
 
void storeDirectAddress (final ByteBuffer directDest, final int destBytePos)
 
final boolean hasArray ()
 
final int arrayOffset ()
 
Object array () throws UnsupportedOperationException
 
String toString ()
 
- Public Member Functions inherited from com.jogamp.common.nio.NativeBuffer< B >
int elementSize ()
 Returns byte size of one element. More...
 
int limit ()
 Returns this buffer's element limit. More...
 
limit (int newLim)
 Sets this buffer's element limit. More...
 
int capacity ()
 Returns this buffer's element capacity. More...
 
int position ()
 Returns this buffer's element position. More...
 
position (int newPos)
 Sets this buffer's element position. More...
 
int remaining ()
 Returns this buffer's remaining element, i.e. More...
 
boolean hasRemaining ()
 Returns remaining() > 0. More...
 
clear ()
 Sets the limit to the capacity and the position to zero. More...
 
flip ()
 Sets the limit to the current position and the position to zero. More...
 
rewind ()
 Sets the position to zero. More...
 
boolean hasArray ()
 
int arrayOffset ()
 
Object array () throws UnsupportedOperationException
 
Buffer getBuffer ()
 Returns the underlying buffer object. More...
 
boolean isDirect ()
 Return true if the underlying buffer is NIO direct, otherwise false. More...
 
long getDirectBufferAddress ()
 Returns the native address of the underlying buffer if isDirect(), otherwise 0. More...
 
void storeDirectAddress (final ByteBuffer directDest)
 Store the getDirectBufferAddress() into the given ByteBuffer using relative put. More...
 
void storeDirectAddress (final ByteBuffer directDest, final int destOffset)
 Store the getDirectBufferAddress() into the given ByteBuffer using absolute put. More...
 
put (B src)
 Relative bulk get method. More...
 

Static Public Attributes

static final int POINTER_SIZE
 Platform dependent pointer size in bytes, i.e. More...
 

Protected Member Functions

 AbstractBuffer (final Buffer buffer, final int elementSize, final int capacity)
 capacity and elementSize should be match the equation w/ target buffer type More...
 
String toSubString ()
 

Protected Attributes

final Buffer buffer
 
final int elementSize
 
final int capacity
 
int limit
 
int position
 

Detailed Description

Author
Sven Gothel
Michael Bien

Definition at line 44 of file AbstractBuffer.java.

Constructor & Destructor Documentation

◆ AbstractBuffer()

com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.AbstractBuffer ( final Buffer  buffer,
final int  elementSize,
final int  capacity 
)
protected

capacity and elementSize should be match the equation w/ target buffer type

   capacity = elementSizeInBytes(buffer) * buffer.capacity() ) / elementSize
Parameters
buffershall be in target format.
elementSizethe target element size in bytes.
capacitythe target capacity in elements of size elementSize.

Definition at line 68 of file AbstractBuffer.java.

Member Function Documentation

◆ array()

Object com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.array ( ) throws UnsupportedOperationException

Definition at line 208 of file AbstractBuffer.java.

◆ arrayOffset()

final int com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.arrayOffset ( )

Definition at line 199 of file AbstractBuffer.java.

◆ capacity()

final int com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.capacity ( )

Definition at line 98 of file AbstractBuffer.java.

◆ clear()

final B com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.clear ( )

Definition at line 129 of file AbstractBuffer.java.

◆ elementSize()

final int com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.elementSize ( )

Definition at line 78 of file AbstractBuffer.java.

◆ flip()

Definition at line 137 of file AbstractBuffer.java.

◆ getBuffer()

final Buffer com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.getBuffer ( )

Definition at line 151 of file AbstractBuffer.java.

Here is the caller graph for this function:

◆ getDirectBufferAddress()

long com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.getDirectBufferAddress ( )

Definition at line 159 of file AbstractBuffer.java.

◆ hasArray()

final boolean com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.hasArray ( )

Definition at line 194 of file AbstractBuffer.java.

◆ hasRemaining()

final boolean com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.hasRemaining ( )

Definition at line 123 of file AbstractBuffer.java.

Here is the caller graph for this function:

◆ isDirect()

final boolean com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.isDirect ( )

Definition at line 155 of file AbstractBuffer.java.

◆ limit() [1/2]

final int com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.limit ( )

Definition at line 83 of file AbstractBuffer.java.

◆ limit() [2/2]

final B com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.limit ( final int  newLim)

Definition at line 89 of file AbstractBuffer.java.

◆ position() [1/2]

final int com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.position ( )

Definition at line 103 of file AbstractBuffer.java.

◆ position() [2/2]

final B com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.position ( final int  newPos)

Definition at line 109 of file AbstractBuffer.java.

◆ remaining()

final int com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.remaining ( )

Definition at line 118 of file AbstractBuffer.java.

Here is the caller graph for this function:

◆ rewind()

final B com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.rewind ( )

Definition at line 145 of file AbstractBuffer.java.

Here is the caller graph for this function:

◆ storeDirectAddress() [1/2]

void com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.storeDirectAddress ( final ByteBuffer  directDest)

Definition at line 167 of file AbstractBuffer.java.

◆ storeDirectAddress() [2/2]

void com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.storeDirectAddress ( final ByteBuffer  directDest,
final int  destBytePos 
)

Definition at line 181 of file AbstractBuffer.java.

◆ toString()

String com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.toString ( )

Definition at line 216 of file AbstractBuffer.java.

◆ toSubString()

String com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.toSubString ( )
protected

Definition at line 212 of file AbstractBuffer.java.

Member Data Documentation

◆ buffer

final Buffer com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.buffer
protected

Definition at line 48 of file AbstractBuffer.java.

◆ capacity

final int com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.capacity
protected

Definition at line 50 of file AbstractBuffer.java.

◆ elementSize

final int com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.elementSize
protected

Definition at line 49 of file AbstractBuffer.java.

◆ limit

int com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.limit
protected

Definition at line 51 of file AbstractBuffer.java.

◆ POINTER_SIZE

final int com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.POINTER_SIZE
static

Platform dependent pointer size in bytes, i.e.

32bit or 64bit wide, depending of the CPU pointer width.

Definition at line 46 of file AbstractBuffer.java.

◆ position

int com.jogamp.common.nio.AbstractBuffer< B extends AbstractBuffer >.position
protected

Definition at line 52 of file AbstractBuffer.java.


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