| Package | Description |
|---|---|
| java.nio |
| Modifier and Type | Method and Description |
|---|---|
static ShortBuffer |
ShortBuffer.allocate(int capacity)
Creates a short buffer based on a newly allocated short array.
|
ShortBuffer |
ByteBuffer.asShortBuffer()
Returns a short buffer which is based on the remaining content of this byte buffer.
|
ShortBuffer |
ShortBuffer.compact()
Compacts this short buffer.
|
ShortBuffer |
ShortBuffer.duplicate()
Returns a duplicated buffer that shares its content with this buffer.
|
ShortBuffer |
ShortBuffer.get(short[] dest)
Reads shorts from the current position into the specified short array and increases the
position by the number of shorts read.
|
ShortBuffer |
ShortBuffer.get(short[] dest,
int off,
int len)
Reads shorts from the current position into the specified short array, starting from the
specified offset, and increases the position by the number of shorts read.
|
ShortBuffer |
ShortBuffer.put(int index,
short c)
Writes a short to the specified index of this buffer; the position is not changed.
|
ShortBuffer |
ShortBuffer.put(short c)
Writes the given short to the current position and increases the position by 1.
|
ShortBuffer |
ShortBuffer.put(short[] src)
Writes shorts from the given short array to the current position and increases the position
by the number of shorts written.
|
ShortBuffer |
ShortBuffer.put(short[] src,
int off,
int len)
Writes shorts from the given short array, starting from the specified offset, to the
current position and increases the position by the number of shorts written.
|
ShortBuffer |
ShortBuffer.put(ShortBuffer src)
Writes all the remaining shorts of the
src short buffer to this buffer's current
position, and increases both buffers' position by the number of shorts copied. |
ShortBuffer |
ShortBuffer.slice()
Returns a sliced buffer that shares its content with this buffer.
|
| Modifier and Type | Method and Description |
|---|---|
int |
ShortBuffer.compareTo(ShortBuffer otherBuffer)
Compare the remaining shorts of this buffer to another short buffer's remaining shorts.
|
ShortBuffer |
ShortBuffer.put(ShortBuffer src)
Writes all the remaining shorts of the
src short buffer to this buffer's current
position, and increases both buffers' position by the number of shorts copied. |
Copyright © 2019–2020. All rights reserved.