Methods Summary |
---|
public void | dispose()
// Need revisit
this.disposed = true;
|
public int | get()
if (position >= limit) {
throw new BufferUnderflowException();
}
return get(position++);
|
public int | get(int index)
if (index < 0 || index >= limit) {
throw new IndexOutOfBoundsException();
}
int bytePtr = arrayOffset + (index << 2);
if (isDirect) {
return ByteBufferImpl._getInt(bytePtr);
} else if (array != null) {
return array[arrayOffset + index];
} else {
return parent.getInt(bytePtr);
}
|
public boolean | isDirect()
return isDirect;
|
public int | nativeAddress()
return arrayOffset;
|
public java.nio.IntBuffer | put(int i)
if (position >= limit) {
throw new BufferOverflowException();
}
return put(position++, i);
|
public java.nio.IntBuffer | put(int index, int i)
if (index < 0 || index >= limit) {
throw new IndexOutOfBoundsException();
}
int bytePtr = arrayOffset + (index << 2);
if (isDirect) {
ByteBufferImpl._putInt(bytePtr, i);
} else if (array != null) {
array[arrayOffset + index] = i;
} else {
parent.putInt(bytePtr, i);
}
return this;
|
public java.nio.IntBuffer | slice()
int pos = position;
if (isDirect) {
pos <<= 2;
}
return new IntBufferImpl(parent, limit - position, array,
arrayOffset + pos,
isDirect);
|