Package org.bytedeco.javacpp.indexer
Class IntRawIndexer
- java.lang.Object
-
- org.bytedeco.javacpp.indexer.Indexer
-
- org.bytedeco.javacpp.indexer.IntIndexer
-
- org.bytedeco.javacpp.indexer.IntRawIndexer
-
- All Implemented Interfaces:
java.lang.AutoCloseable
public class IntRawIndexer extends IntIndexer
An indexer for anIntPointer
using theRaw
instance.
-
-
Field Summary
Fields Modifier and Type Field Description (package private) long
base
Base address and number of elements accessible.protected IntPointer
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.-
Fields inherited from class org.bytedeco.javacpp.indexer.IntIndexer
VALUE_BYTES
-
-
Constructor Summary
Constructors Constructor Description IntRawIndexer(IntPointer pointer)
CallsIntRawIndexer(pointer, Index.create(pointer.limit() - pointer.position()))
.IntRawIndexer(IntPointer pointer, long... sizes)
CallsIntRawIndexer(pointer, Index.create(sizes))
.IntRawIndexer(IntPointer pointer, long[] sizes, long[] strides)
CallsIntRawIndexer(pointer, Index.create(sizes, strides))
.IntRawIndexer(IntPointer pointer, Index index)
Constructor to set thepointer
andIndexer.index
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
get(long i)
Returnsarray/buffer[index(i)]
int
get(long... indices)
Returnsarray/buffer[index(indices)]
IntIndexer
get(long[] indices, int[] m, int offset, int length)
Returnsthis
wheren[offset:offset + length] = array/buffer[index(indices)]
IntIndexer
get(long i, int[] m, int offset, int length)
Returnsthis
wheren[offset:offset + length] = array/buffer[index(i)]
int
get(long i, long j)
Returnsarray/buffer[index(i, j)]
IntIndexer
get(long i, long j, int[] m, int offset, int length)
Returnsthis
wheren[offset:offset + length] = array/buffer[index(i, j)]
int
get(long i, long j, long k)
Returnsarray/buffer[index(i, j, k)]
int
getRaw(long i)
Pointer
pointer()
Returns the backing pointer, ornull
if noneIntIndexer
put(long[] indices, int n)
Returnsthis
wherearray/buffer[index(indices)] = n
IntIndexer
put(long[] indices, int[] m, int offset, int length)
Returnsthis
wherearray/buffer[index(indices)] = n[offset:offset + length]
IntIndexer
put(long i, int n)
Returnsthis
wherearray/buffer[index(i)] = n
IntIndexer
put(long i, int[] m, int offset, int length)
Returnsthis
wherearray/buffer[index(i)] = n[offset:offset + length]
IntIndexer
put(long i, long j, int n)
Returnsthis
wherearray/buffer[index(i, j)] = n
IntIndexer
put(long i, long j, int[] m, int offset, int length)
Returnsthis
wherearray/buffer[index(i, j)] = n[offset:offset + length]
IntIndexer
put(long i, long j, long k, int n)
Returnsthis
wherearray/buffer[index(i, j, k)] = n
IntIndexer
putRaw(long i, int n)
IntIndexer
reindex(Index index)
Returns a new Indexer using the same data, but with a different Index.void
release()
Makes sure changes are reflected onto the backing memory and clears any references.-
Methods inherited from class org.bytedeco.javacpp.indexer.IntIndexer
create, create, create, create, create, create, create, create, create, create, create, create, create, create, get, get, get, getDouble, put, put, put, putDouble
-
-
-
-
Field Detail
-
RAW
protected static final Raw RAW
The instance for the raw memory interface.
-
pointer
protected IntPointer pointer
The backing pointer.
-
base
final long base
Base address and number of elements accessible.
-
size
final long size
Base address and number of elements accessible.
-
-
Constructor Detail
-
IntRawIndexer
public IntRawIndexer(IntPointer pointer)
CallsIntRawIndexer(pointer, Index.create(pointer.limit() - pointer.position()))
.
-
IntRawIndexer
public IntRawIndexer(IntPointer pointer, long... sizes)
CallsIntRawIndexer(pointer, Index.create(sizes))
.
-
IntRawIndexer
public IntRawIndexer(IntPointer pointer, long[] sizes, long[] strides)
CallsIntRawIndexer(pointer, Index.create(sizes, strides))
.
-
IntRawIndexer
public IntRawIndexer(IntPointer pointer, Index index)
Constructor to set thepointer
andIndexer.index
.
-
-
Method Detail
-
pointer
public Pointer pointer()
Description copied from class:Indexer
Returns the backing pointer, ornull
if none
-
reindex
public IntIndexer reindex(Index index)
Description copied from class:Indexer
Returns a new Indexer using the same data, but with a different Index.
-
getRaw
public int getRaw(long i)
-
get
public int get(long i)
Description copied from class:IntIndexer
Returnsarray/buffer[index(i)]
- Specified by:
get
in classIntIndexer
-
get
public IntIndexer get(long i, int[] m, int offset, int length)
Description copied from class:IntIndexer
Returnsthis
wheren[offset:offset + length] = array/buffer[index(i)]
- Specified by:
get
in classIntIndexer
-
get
public int get(long i, long j)
Description copied from class:IntIndexer
Returnsarray/buffer[index(i, j)]
- Specified by:
get
in classIntIndexer
-
get
public IntIndexer get(long i, long j, int[] m, int offset, int length)
Description copied from class:IntIndexer
Returnsthis
wheren[offset:offset + length] = array/buffer[index(i, j)]
- Specified by:
get
in classIntIndexer
-
get
public int get(long i, long j, long k)
Description copied from class:IntIndexer
Returnsarray/buffer[index(i, j, k)]
- Specified by:
get
in classIntIndexer
-
get
public int get(long... indices)
Description copied from class:IntIndexer
Returnsarray/buffer[index(indices)]
- Specified by:
get
in classIntIndexer
-
get
public IntIndexer get(long[] indices, int[] m, int offset, int length)
Description copied from class:IntIndexer
Returnsthis
wheren[offset:offset + length] = array/buffer[index(indices)]
- Specified by:
get
in classIntIndexer
-
putRaw
public IntIndexer putRaw(long i, int n)
-
put
public IntIndexer put(long i, int n)
Description copied from class:IntIndexer
Returnsthis
wherearray/buffer[index(i)] = n
- Specified by:
put
in classIntIndexer
-
put
public IntIndexer put(long i, int[] m, int offset, int length)
Description copied from class:IntIndexer
Returnsthis
wherearray/buffer[index(i)] = n[offset:offset + length]
- Specified by:
put
in classIntIndexer
-
put
public IntIndexer put(long i, long j, int n)
Description copied from class:IntIndexer
Returnsthis
wherearray/buffer[index(i, j)] = n
- Specified by:
put
in classIntIndexer
-
put
public IntIndexer put(long i, long j, int[] m, int offset, int length)
Description copied from class:IntIndexer
Returnsthis
wherearray/buffer[index(i, j)] = n[offset:offset + length]
- Specified by:
put
in classIntIndexer
-
put
public IntIndexer put(long i, long j, long k, int n)
Description copied from class:IntIndexer
Returnsthis
wherearray/buffer[index(i, j, k)] = n
- Specified by:
put
in classIntIndexer
-
put
public IntIndexer put(long[] indices, int n)
Description copied from class:IntIndexer
Returnsthis
wherearray/buffer[index(indices)] = n
- Specified by:
put
in classIntIndexer
-
put
public IntIndexer put(long[] indices, int[] m, int offset, int length)
Description copied from class:IntIndexer
Returnsthis
wherearray/buffer[index(indices)] = n[offset:offset + length]
- Specified by:
put
in classIntIndexer
-
-