Class UShortIndexer

java.lang.Object
org.bytedeco.javacpp.indexer.Indexer
org.bytedeco.javacpp.indexer.UShortIndexer
All Implemented Interfaces:
AutoCloseable
Direct Known Subclasses:
UShortArrayIndexer, UShortBufferIndexer, UShortRawIndexer

public abstract class UShortIndexer extends Indexer
Abstract indexer for the short primitive type, treated as unsigned.
  • Field Details

    • VALUE_BYTES

      public static final int VALUE_BYTES
      The number of bytes used to represent a short.
      See Also:
  • Constructor Details

    • UShortIndexer

      protected UShortIndexer(Index index)
    • UShortIndexer

      protected UShortIndexer(long[] sizes, long[] strides)
  • Method Details

    • create

      public static UShortIndexer create(short[] array)
      Returns new UShortArrayIndexer(array)
    • create

      public static UShortIndexer create(ShortBuffer buffer)
      Returns new UShortBufferIndexer(buffer)
    • create

      public static UShortIndexer create(ShortPointer pointer)
      Returns new UShortRawIndexer(pointer)
    • create

      public static UShortIndexer create(short[] array, Index index)
      Returns new UShortArrayIndexer(array, index)
    • create

      public static UShortIndexer create(ShortBuffer buffer, Index index)
      Returns new UShortBufferIndexer(buffer, index)
    • create

      public static UShortIndexer create(ShortPointer pointer, Index index)
      Returns new UShortRawIndexer(pointer, index)
    • create

      public static UShortIndexer create(short[] array, long... sizes)
      Returns new UShortArrayIndexer(array, sizes)
    • create

      public static UShortIndexer create(ShortBuffer buffer, long... sizes)
      Returns new UShortBufferIndexer(buffer, sizes)
    • create

      public static UShortIndexer create(ShortPointer pointer, long... sizes)
      Returns new UShortRawIndexer(pointer, sizes)
    • create

      public static UShortIndexer create(short[] array, long[] sizes, long[] strides)
      Returns new UShortArrayIndexer(array, sizes, strides)
    • create

      public static UShortIndexer create(ShortBuffer buffer, long[] sizes, long[] strides)
      Returns new UShortBufferIndexer(buffer, sizes, strides)
    • create

      public static UShortIndexer create(ShortPointer pointer, long[] sizes, long[] strides)
      Returns new UShortRawIndexer(pointer, sizes, strides)
    • create

      public static UShortIndexer create(ShortPointer pointer, long[] sizes, long[] strides, boolean direct)
      Returns create(pointer, Index.create(sizes, strides), direct)
    • create

      public static UShortIndexer create(ShortPointer pointer, Index index, boolean direct)
      Creates a short indexer to access efficiently the data of a pointer.
      Parameters:
      pointer - data to access via a buffer or to copy to an array
      index - to use
      direct - true to use a direct buffer, see Indexer for details
      Returns:
      the new short indexer backed by the raw memory interface, a buffer, or an array
    • get

      public abstract int get(long i)
      Returns array/buffer[index(i)]
    • get

      public UShortIndexer get(long i, int[] s)
      Returns this where s = array/buffer[index(i)]
    • get

      public abstract UShortIndexer get(long i, int[] s, int offset, int length)
      Returns this where s[offset:offset + length] = array/buffer[index(i)]
    • get

      public abstract int get(long i, long j)
      Returns array/buffer[index(i, j)]
    • get

      public UShortIndexer get(long i, long j, int[] s)
      Returns this where s = array/buffer[index(i, j)]
    • get

      public abstract UShortIndexer get(long i, long j, int[] s, int offset, int length)
      Returns this where s[offset:offset + length] = array/buffer[index(i, j)]
    • get

      public abstract int get(long i, long j, long k)
      Returns array/buffer[index(i, j, k)]
    • get

      public abstract int get(long... indices)
      Returns array/buffer[index(indices)]
    • get

      public UShortIndexer get(long[] indices, int[] s)
      Returns this where s = array/buffer[index(indices)]
    • get

      public abstract UShortIndexer get(long[] indices, int[] s, int offset, int length)
      Returns this where s[offset:offset + length] = array/buffer[index(indices)]
    • put

      public abstract UShortIndexer put(long i, int s)
      Returns this where array/buffer[index(i)] = s
    • put

      public UShortIndexer put(long i, int... s)
      Returns this where array/buffer[index(i)] = s
    • put

      public abstract UShortIndexer put(long i, int[] s, int offset, int length)
      Returns this where array/buffer[index(i)] = s[offset:offset + length]
    • put

      public abstract UShortIndexer put(long i, long j, int s)
      Returns this where array/buffer[index(i, j)] = s
    • put

      public UShortIndexer put(long i, long j, int... s)
      Returns this where array/buffer[index(i, j)] = s
    • put

      public abstract UShortIndexer put(long i, long j, int[] s, int offset, int length)
      Returns this where array/buffer[index(i, j)] = s[offset:offset + length]
    • put

      public abstract UShortIndexer put(long i, long j, long k, int s)
      Returns this where array/buffer[index(i, j, k)] = s
    • put

      public abstract UShortIndexer put(long[] indices, int s)
      Returns this where array/buffer[index(indices)] = s
    • put

      public UShortIndexer put(long[] indices, int... s)
      Returns this where array/buffer[index(indices)] = s
    • put

      public abstract UShortIndexer put(long[] indices, int[] s, int offset, int length)
      Returns this where array/buffer[index(indices)] = s[offset:offset + length]
    • getDouble

      public double getDouble(long... indices)
      Description copied from class: Indexer
      Calls get(int...indices) and returns the value as a double.
      Specified by:
      getDouble in class Indexer
    • putDouble

      public UShortIndexer putDouble(long[] indices, double s)
      Description copied from class: Indexer
      Casts value to primitive type and calls put(long[] indices, <type> value).
      Specified by:
      putDouble in class Indexer