public class FloatRawIndexer extends FloatIndexer
FloatPointer
using the Raw
instance.Modifier and Type | Field and Description |
---|---|
(package private) long |
base
Base address and number of elements accessible.
|
protected FloatPointer |
pointer
The backing pointer.
|
protected static Raw |
RAW
The instance for the raw memory interface.
|
(package private) long |
size
Base address and number of elements accessible.
|
VALUE_BYTES
indexable, ONE_STRIDE, sizes, strides
Constructor and Description |
---|
FloatRawIndexer(FloatPointer pointer)
Calls
FloatRawIndexer(pointer, { pointer.limit() - pointer.position() }, { 1 }) . |
FloatRawIndexer(FloatPointer pointer,
long... sizes)
Calls
FloatRawIndexer(pointer, sizes, strides(sizes)) . |
FloatRawIndexer(FloatPointer pointer,
long[] sizes,
long[] strides)
|
Modifier and Type | Method and Description |
---|---|
float |
get(long... indices)
Returns
array/buffer[index(indices)] |
float |
get(long i)
Returns
array/buffer[i] |
FloatIndexer |
get(long[] indices,
float[] f,
int offset,
int length)
Returns
this where f[offset:offset + length] = array/buffer[index(indices)] |
FloatIndexer |
get(long i,
float[] f,
int offset,
int length)
Returns
this where f[offset:offset + length] = array/buffer[i] |
float |
get(long i,
long j)
Returns
array/buffer[i * strides[0] + j] |
FloatIndexer |
get(long i,
long j,
float[] f,
int offset,
int length)
Returns
this where f[offset:offset + length] = array/buffer[i * strides[0] + j] |
float |
get(long i,
long j,
long k)
Returns
array/buffer[i * strides[0] + j * strides[1] + k] |
Pointer |
pointer()
Returns the backing pointer, or
null if none |
FloatIndexer |
put(long[] indices,
float f)
Returns
this where array/buffer[index(indices)] = f |
FloatIndexer |
put(long[] indices,
float[] f,
int offset,
int length)
Returns
this where array/buffer[index(indices)] = f[offset:offset + length] |
FloatIndexer |
put(long i,
float f)
Returns
this where array/buffer[i] = f |
FloatIndexer |
put(long i,
float[] f,
int offset,
int length)
Returns
this where array/buffer[i] = f[offset:offset + length] |
FloatIndexer |
put(long i,
long j,
float f)
Returns
this where array/buffer[i * strides[0] + j] = f |
FloatIndexer |
put(long i,
long j,
float[] f,
int offset,
int length)
Returns
this where array/buffer[i * strides[0] + j] = f[offset:offset + length] |
FloatIndexer |
put(long i,
long j,
long k,
float f)
Returns
this where array/buffer[i * strides[0] + j * strides[1] + k] = f |
void |
release()
Makes sure changes are reflected onto the backing memory and clears any references.
|
create, create, create, create, create, create, create, create, create, create, get, get, get, getDouble, put, put, put, putDouble
protected static final Raw RAW
protected FloatPointer pointer
final long base
final long size
public FloatRawIndexer(FloatPointer pointer)
FloatRawIndexer(pointer, { pointer.limit() - pointer.position() }, { 1 })
.public FloatRawIndexer(FloatPointer pointer, long... sizes)
FloatRawIndexer(pointer, sizes, strides(sizes))
.public FloatRawIndexer(FloatPointer pointer, long[] sizes, long[] strides)
public Pointer pointer()
Indexer
null
if nonepublic float get(long i)
FloatIndexer
array/buffer[i]
get
in class FloatIndexer
public FloatIndexer get(long i, float[] f, int offset, int length)
FloatIndexer
this
where f[offset:offset + length] = array/buffer[i]
get
in class FloatIndexer
public float get(long i, long j)
FloatIndexer
array/buffer[i * strides[0] + j]
get
in class FloatIndexer
public FloatIndexer get(long i, long j, float[] f, int offset, int length)
FloatIndexer
this
where f[offset:offset + length] = array/buffer[i * strides[0] + j]
get
in class FloatIndexer
public float get(long i, long j, long k)
FloatIndexer
array/buffer[i * strides[0] + j * strides[1] + k]
get
in class FloatIndexer
public float get(long... indices)
FloatIndexer
array/buffer[index(indices)]
get
in class FloatIndexer
public FloatIndexer get(long[] indices, float[] f, int offset, int length)
FloatIndexer
this
where f[offset:offset + length] = array/buffer[index(indices)]
get
in class FloatIndexer
public FloatIndexer put(long i, float f)
FloatIndexer
this
where array/buffer[i] = f
put
in class FloatIndexer
public FloatIndexer put(long i, float[] f, int offset, int length)
FloatIndexer
this
where array/buffer[i] = f[offset:offset + length]
put
in class FloatIndexer
public FloatIndexer put(long i, long j, float f)
FloatIndexer
this
where array/buffer[i * strides[0] + j] = f
put
in class FloatIndexer
public FloatIndexer put(long i, long j, float[] f, int offset, int length)
FloatIndexer
this
where array/buffer[i * strides[0] + j] = f[offset:offset + length]
put
in class FloatIndexer
public FloatIndexer put(long i, long j, long k, float f)
FloatIndexer
this
where array/buffer[i * strides[0] + j * strides[1] + k] = f
put
in class FloatIndexer
public FloatIndexer put(long[] indices, float f)
FloatIndexer
this
where array/buffer[index(indices)] = f
put
in class FloatIndexer
public FloatIndexer put(long[] indices, float[] f, int offset, int length)
FloatIndexer
this
where array/buffer[index(indices)] = f[offset:offset + length]
put
in class FloatIndexer
Copyright © 2020. All rights reserved.