|
Build 1.0_r1(from source) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.nio.Buffer
java.nio.IntBuffer
java.nio.IntArrayBuffer
abstract class IntArrayBuffer
IntArrayBuffer, ReadWriteIntArrayBuffer and ReadOnlyIntArrayBuffer compose the implementation of array based int buffers.
IntArrayBuffer implements all the shared readonly methods and is extended by the other two classes.
All methods are marked final for runtime performance.
| Field Summary | |
|---|---|
protected int[] |
backingArray
|
protected int |
offset
|
| Fields inherited from class java.nio.Buffer |
|---|
_elementSizeShift, capacity, limit, mark, position, UNSET_MARK |
| Constructor Summary | |
|---|---|
IntArrayBuffer(int capacity)
|
|
IntArrayBuffer(int[] array)
|
|
IntArrayBuffer(int capacity,
int[] backingArray,
int offset)
|
|
| Method Summary | |
|---|---|
int |
get()
Returns the int at the current position and increase the position by 1. |
int |
get(int index)
Returns a int at the specified index, and the position is not changed. |
IntBuffer |
get(int[] dest,
int off,
int len)
Reads ints from the current position into the specified
int array, starting from the specified offset, and increase the position
by the number of ints read. |
boolean |
isDirect()
Returns true if this buffer is direct. |
ByteOrder |
order()
Returns the byte order used by this buffer when converting ints from/to bytes. |
| Methods inherited from class java.nio.IntBuffer |
|---|
_array, _arrayOffset, allocate, array, arrayOffset, asReadOnlyBuffer, compact, compareTo, duplicate, equals, get, hasArray, hashCode, protectedArray, protectedArrayOffset, protectedHasArray, put, put, put, put, put, slice, toString, wrap, wrap |
| Methods inherited from class java.nio.Buffer |
|---|
capacity, clear, flip, hasRemaining, isReadOnly, limit, limit, mark, position, position, remaining, reset, rewind |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected final int[] backingArray
protected final int offset
| Constructor Detail |
|---|
IntArrayBuffer(int[] array)
IntArrayBuffer(int capacity)
IntArrayBuffer(int capacity,
int[] backingArray,
int offset)
| Method Detail |
|---|
public final int get()
IntBuffer
get in class IntBufferpublic final int get(int index)
IntBuffer
get in class IntBufferindex - The index, must be no less than zero and less than limit
public final IntBuffer get(int[] dest,
int off,
int len)
IntBufferints from the current position into the specified
int array, starting from the specified offset, and increase the position
by the number of ints read.
get in class IntBufferdest - The target int arrayoff - The offset of the int array, must be no less than zero and no
greater than dest.lengthlen - The number of ints to read, must be no less
than zero and no greater than dest.length - off
public final boolean isDirect()
IntBufferA int buffer is direct, if it is based on a byte buffer and the byte buffer is direct.
isDirect in class IntBufferpublic final ByteOrder order()
IntBufferints from/to bytes.
If this buffer is not based on a byte buffer, then always return the platform's native byte order.
order in class IntBufferints from/to bytes.
|
Build 1.0_r1(from source) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||