Class DoubleArrayIndexer
java.lang.Object
org.bytedeco.javacpp.indexer.Indexer
org.bytedeco.javacpp.indexer.DoubleIndexer
org.bytedeco.javacpp.indexer.DoubleArrayIndexer
- All Implemented Interfaces:
AutoCloseable
An indexer for a
double[] array.-
Field Summary
FieldsFields inherited from class DoubleIndexer
VALUE_BYTES -
Constructor Summary
ConstructorsConstructorDescriptionDoubleArrayIndexer(double[] array) CallsDoubleArrayIndexer(array, Index.create(array.length)).DoubleArrayIndexer(double[] array, long... sizes) CallsDoubleArrayIndexer(array, Index.create(sizes)).DoubleArrayIndexer(double[] array, long[] sizes, long[] strides) CallsDoubleArrayIndexer(array, Index.create(sizes, strides)).DoubleArrayIndexer(double[] array, Index index) Constructor to set thearrayandIndexer.index. -
Method Summary
Modifier and TypeMethodDescriptiondouble[]array()Returns the backing array, ornullif nonedoubleget(long i) Returnsarray/buffer[index(i)]doubleget(long... indices) Returnsarray/buffer[index(indices)]get(long[] indices, double[] d, int offset, int length) Returnsthiswhered[offset:offset + length] = array/buffer[index(indices)]get(long i, double[] d, int offset, int length) Returnsthiswhered[offset:offset + length] = array/buffer[index(i)]doubleget(long i, long j) Returnsarray/buffer[index(i, j)]get(long i, long j, double[] d, int offset, int length) Returnsthiswhered[offset:offset + length] = array/buffer[index(i, j)]doubleget(long i, long j, long k) Returnsarray/buffer[index(i, j, k)]put(long[] indices, double d) Returnsthiswherearray/buffer[index(indices)] = dput(long[] indices, double[] d, int offset, int length) Returnsthiswherearray/buffer[index(indices)] = d[offset:offset + length]put(long i, double d) Returnsthiswherearray/buffer[index(i)] = dput(long i, double[] d, int offset, int length) Returnsthiswherearray/buffer[index(i)] = d[offset:offset + length]put(long i, long j, double d) Returnsthiswherearray/buffer[index(i, j)] = dput(long i, long j, double[] d, int offset, int length) Returnsthiswherearray/buffer[index(i, j)] = d[offset:offset + length]put(long i, long j, long k, double d) Returnsthiswherearray/buffer[index(i, j, k)] = dReturns a new Indexer using the same data, but with a different Index.voidrelease()Makes sure changes are reflected onto the backing memory and clears any references.Methods inherited from class DoubleIndexer
create, create, create, create, create, create, create, create, create, create, create, create, create, create, get, get, get, getDouble, put, put, put, putDouble
-
Field Details
-
array
protected double[] arrayThe backing array.
-
-
Constructor Details
-
DoubleArrayIndexer
public DoubleArrayIndexer(double[] array) CallsDoubleArrayIndexer(array, Index.create(array.length)). -
DoubleArrayIndexer
public DoubleArrayIndexer(double[] array, long... sizes) CallsDoubleArrayIndexer(array, Index.create(sizes)). -
DoubleArrayIndexer
public DoubleArrayIndexer(double[] array, long[] sizes, long[] strides) CallsDoubleArrayIndexer(array, Index.create(sizes, strides)). -
DoubleArrayIndexer
Constructor to set thearrayandIndexer.index.
-
-
Method Details
-
array
-
reindex
Description copied from class:IndexerReturns a new Indexer using the same data, but with a different Index. -
get
public double get(long i) Description copied from class:DoubleIndexerReturnsarray/buffer[index(i)]- Specified by:
getin classDoubleIndexer
-
get
Description copied from class:DoubleIndexerReturnsthiswhered[offset:offset + length] = array/buffer[index(i)]- Specified by:
getin classDoubleIndexer
-
get
public double get(long i, long j) Description copied from class:DoubleIndexerReturnsarray/buffer[index(i, j)]- Specified by:
getin classDoubleIndexer
-
get
Description copied from class:DoubleIndexerReturnsthiswhered[offset:offset + length] = array/buffer[index(i, j)]- Specified by:
getin classDoubleIndexer
-
get
public double get(long i, long j, long k) Description copied from class:DoubleIndexerReturnsarray/buffer[index(i, j, k)]- Specified by:
getin classDoubleIndexer
-
get
public double get(long... indices) Description copied from class:DoubleIndexerReturnsarray/buffer[index(indices)]- Specified by:
getin classDoubleIndexer
-
get
Description copied from class:DoubleIndexerReturnsthiswhered[offset:offset + length] = array/buffer[index(indices)]- Specified by:
getin classDoubleIndexer
-
put
Description copied from class:DoubleIndexerReturnsthiswherearray/buffer[index(i)] = d- Specified by:
putin classDoubleIndexer
-
put
Description copied from class:DoubleIndexerReturnsthiswherearray/buffer[index(i)] = d[offset:offset + length]- Specified by:
putin classDoubleIndexer
-
put
Description copied from class:DoubleIndexerReturnsthiswherearray/buffer[index(i, j)] = d- Specified by:
putin classDoubleIndexer
-
put
Description copied from class:DoubleIndexerReturnsthiswherearray/buffer[index(i, j)] = d[offset:offset + length]- Specified by:
putin classDoubleIndexer
-
put
Description copied from class:DoubleIndexerReturnsthiswherearray/buffer[index(i, j, k)] = d- Specified by:
putin classDoubleIndexer
-
put
Description copied from class:DoubleIndexerReturnsthiswherearray/buffer[index(indices)] = d- Specified by:
putin classDoubleIndexer
-
put
Description copied from class:DoubleIndexerReturnsthiswherearray/buffer[index(indices)] = d[offset:offset + length]- Specified by:
putin classDoubleIndexer
-
release
-