| Package | Description |
|---|---|
| java.nio | |
| org.gwtproject.nio |
| Modifier and Type | Method and Description |
|---|---|
static ByteBuffer |
ByteBuffer.allocate(int capacity)
Creates a byte buffer based on a newly allocated byte array.
|
static ByteBuffer |
ByteBuffer.allocateDirect(int capacity)
Creates a direct byte buffer based on a newly allocated memory block.
|
ByteBuffer |
ByteBuffer.compact()
Compacts this byte buffer.
|
ByteBuffer |
ByteBuffer.duplicate()
Returns a duplicated buffer that shares its content with this buffer.
|
ByteBuffer |
ByteBuffer.get(byte[] dest)
Reads bytes from the current position into the specified byte array and increases the
position by the number of bytes read.
|
ByteBuffer |
ByteBuffer.get(byte[] dest,
int off,
int len)
Reads bytes from the current position into the specified byte array, starting at the
specified offset, and increases the position by the number of bytes read.
|
ByteBuffer |
ByteBuffer.order(ByteOrder byteOrder)
Sets the byte order of this buffer.
|
ByteBuffer |
ByteBuffer.put(byte b)
Writes the given byte to the current position and increases the position by 1.
|
ByteBuffer |
ByteBuffer.put(byte[] src)
Writes bytes in the given byte array to the current position and increases the position by
the number of bytes written.
|
ByteBuffer |
ByteBuffer.put(byte[] src,
int off,
int len)
Writes bytes in the given byte array, starting from the specified offset, to the current
position and increases the position by the number of bytes written.
|
ByteBuffer |
ByteBuffer.put(ByteBuffer src)
Writes all the remaining bytes of the
src byte buffer to this buffer's current
position, and increases both buffers' position by the number of bytes copied. |
ByteBuffer |
ByteBuffer.put(int index,
byte b)
Write a byte to the specified index of this buffer without changing the position.
|
ByteBuffer |
ByteBuffer.putChar(char value)
Writes the given char to the current position and increases the position by 2.
|
ByteBuffer |
ByteBuffer.putChar(int index,
char value)
Writes the given char to the specified index of this buffer.
|
ByteBuffer |
ByteBuffer.putDouble(double value)
Writes the given double to the current position and increases the position by 8.
|
ByteBuffer |
ByteBuffer.putDouble(int index,
double value)
Writes the given double to the specified index of this buffer.
|
ByteBuffer |
ByteBuffer.putFloat(float value)
Writes the given float to the current position and increases the position by 4.
|
ByteBuffer |
ByteBuffer.putFloat(int index,
float value)
Writes the given float to the specified index of this buffer.
|
ByteBuffer |
ByteBuffer.putInt(int value)
Writes the given int to the current position and increases the position by 4.
|
ByteBuffer |
ByteBuffer.putInt(int baseOffset,
int value)
Writes the given int to the specified index of this buffer.
|
ByteBuffer |
ByteBuffer.putLong(int baseOffset,
long value)
Writes the given long to the specified index of this buffer.
|
ByteBuffer |
ByteBuffer.putLong(long value)
Writes the given long to the current position and increases the position by 8.
|
ByteBuffer |
ByteBuffer.putShort(int baseOffset,
short value)
Writes the given short to the specified index of this buffer.
|
ByteBuffer |
ByteBuffer.putShort(short value)
Writes the given short to the current position and increases the position by 2.
|
ByteBuffer |
ByteBuffer.slice()
Returns a sliced buffer that shares its content with this buffer.
|
ByteBuffer |
ByteBuffer.wrap(elemental2.core.ArrayBuffer arrayBuffer) |
static ByteBuffer |
ByteBuffer.wrapArrayBuffer(elemental2.core.ArrayBuffer arrayBuffer) |
| Modifier and Type | Method and Description |
|---|---|
int |
ByteBuffer.compareTo(ByteBuffer otherBuffer)
Compares the remaining bytes of this buffer to another byte buffer's remaining bytes.
|
ByteBuffer |
ByteBuffer.put(ByteBuffer src)
Writes all the remaining bytes of the
src byte buffer to this buffer's current
position, and increases both buffers' position by the number of bytes copied. |
| Modifier and Type | Method and Description |
|---|---|
static ByteBuffer |
TypedArrayHelper.wrap(elemental2.core.ArrayBuffer ab) |
ByteBuffer |
TypedArrayHelper.Wrapper.wrap(elemental2.core.ArrayBuffer arrayBuffer)
Deprecated.
|
| Modifier and Type | Method and Description |
|---|---|
static elemental2.core.ArrayBufferView |
TypedArrayHelper.unwrap(ByteBuffer bb) |
Copyright © 2019–2020. All rights reserved.