com.io7m.jtensors.bytebuffered.parameterized

## Class PVectorByteBufferedM4L<T>

- java.lang.Object
- - com.io7m.jtensors.bytebuffered.ByteBuffered
  - - com.io7m.jtensors.bytebuffered.parameterized.PVectorByteBufferedM4L<T>

- Type Parameters:
    `T` - A phantom type parameter
  All Implemented Interfaces:
    ByteBufferedType, PVectorByteBuffered2LType<T>, PVectorByteBuffered3LType<T>, PVectorByteBuffered4LType<T>, PVector2LType<T>, PVector3LType<T>, PVector4LType<T>, PVectorReadable2LType<T>, PVectorReadable3LType<T>, PVectorReadable4LType<T>, PVectorWritable2LType<T>, PVectorWritable3LType<T>, PVectorWritable4LType<T>, Vector2LType, Vector3LType, Vector4LType, VectorReadable2LType, VectorReadable3LType, VectorReadable4LType, VectorWritable2LType, VectorWritable3LType, VectorWritable4LType

      public final class PVectorByteBufferedM4L<T>
      extends ByteBuffered
      implements PVectorByteBuffered4LType<T>

  A four-element vector type with `long` elements, packed into a `ByteBuffer`.

  Values of this type cannot be accessed safely from multiple threads without explicit synchronization.

- - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `copyFrom2L(VectorReadable2LType in_v)` Set the current vector to the contents of the input vector.
    `void` | `copyFrom3L(VectorReadable3LType in_v)` Set the current vector to the contents of the input vector.
    `void` | `copyFrom4L(VectorReadable4LType in_v)` Set the current vector to the contents of the input vector.
    `void` | `copyFromTyped2L(PVectorReadable2LType<T> in_v)` Set the current vector to the contents of the input vector.
    `void` | `copyFromTyped3L(PVectorReadable3LType<T> in_v)` Set the current vector to the contents of the input vector.
    `void` | `copyFromTyped4L(PVectorReadable4LType<T> in_v)` Set the current vector to the contents of the input vector.
    `boolean` | `equals(Object obj)`
    `long` | `getWL()`
    `long` | `getXL()`
    `long` | `getYL()`
    `long` | `getZL()`
    `int` | `hashCode()`
    `static <T> PVectorByteBuffered4LType<T>` | `newVectorFromByteBuffer(ByteBuffer b, long byte_offset)` Return a new vector that is backed by whatever data is at byte offset `byte_offset` in the byte buffer .
    `static <T> PVectorByteBuffered4LType<T>` | `newVectorFromByteBufferAndBase(ByteBuffer b, AtomicLong base, int offset)` Return a new vector that is backed by the given byte buffer `b`
    `void` | `set2L(long x, long y)` Set the current `x` and `y` values of the current vector.
    `void` | `set3L(long x, long y, long z)` Set the current `x`, `y` and `z` values of the current vector.
    `void` | `set4L(long x, long y, long z, long w)` Set the current `x`, `y`, `z` and `w` values of the current vector.
    `void` | `setWL(long w)` Set the current `w` value of the current vector.
    `void` | `setXL(long x)` Set the current `x` value of the current vector.
    `void` | `setYL(long y)` Set the current `y` value of the current vector.
    `void` | `setZL(long z)` Set the current `z` value of the current vector.
    `String` | `toString()`

    - ### Methods inherited from class com.io7m.jtensors.bytebuffered.ByteBuffered

      `getByteOffset, getIndex, getOffset, setBase, setByteOffset`

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

    - ### Methods inherited from interface com.io7m.jtensors.bytebuffered.ByteBufferedType

      `getByteOffset, setByteOffset`

- - ### Method Detail

    - #### newVectorFromByteBuffer

          public static <T> PVectorByteBuffered4LType<T> newVectorFromByteBuffer(ByteBuffer b,
                                                                                 long byte_offset)

      Return a new vector that is backed by whatever data is at byte offset `byte_offset` in the byte buffer .

      No initialization of the data is performed.

      Type Parameters:
        `T` - A phantom type parameter
      Parameters:
        `b` - The byte buffer
        `byte_offset` - A byte offset
      Returns:
        A new buffered vector

    - #### newVectorFromByteBufferAndBase

          public static <T> PVectorByteBuffered4LType<T> newVectorFromByteBufferAndBase(ByteBuffer b,
                                                                                        AtomicLong base,
                                                                                        int offset)

      Return a new vector that is backed by the given byte buffer `b`

      The data for the instance will be taken from the data at the current value of `base.get() + offset`, each time a field is requested or set.

      No initialization of the data is performed.

      Type Parameters:
        `T` - A phantom type parameter
      Parameters:
        `b` - The byte buffer
        `base` - The base address
        `offset` - A constant offset
      Returns:
        A new buffered vector

    - #### getWL

          public long getWL()

      Specified by:
        `getWL` in interface `VectorReadable4LType`
      Returns:
        The W value of the given vector.

    - #### setWL

          public void setWL(long w)

      Description copied from interface: `VectorWritable4LType`
      Set the current `w` value of the current vector.
      Specified by:
        `setWL` in interface `VectorWritable4LType`
      Parameters:
        `w` - The new `w` value.

    - #### getZL

          public long getZL()

      Specified by:
        `getZL` in interface `VectorReadable3LType`
      Returns:
        The Z value of the given vector.

    - #### setZL

          public void setZL(long z)

      Description copied from interface: `VectorWritable3LType`
      Set the current `z` value of the current vector.
      Specified by:
        `setZL` in interface `VectorWritable3LType`
      Parameters:
        `z` - The new `z` value.

    - #### getXL

          public long getXL()

      Specified by:
        `getXL` in interface `VectorReadable2LType`
      Returns:
        The X value of the given vector.

    - #### setXL

          public void setXL(long x)

      Description copied from interface: `VectorWritable2LType`
      Set the current `x` value of the current vector.
      Specified by:
        `setXL` in interface `VectorWritable2LType`
      Parameters:
        `x` - The new `x` value.

    - #### getYL

          public long getYL()

      Specified by:
        `getYL` in interface `VectorReadable2LType`
      Returns:
        The Y value of the given vector.

    - #### setYL

          public void setYL(long y)

      Description copied from interface: `VectorWritable2LType`
      Set the current `y` value of the current vector.
      Specified by:
        `setYL` in interface `VectorWritable2LType`
      Parameters:
        `y` - The new `y` value.

    - #### copyFrom4L

          public void copyFrom4L(VectorReadable4LType in_v)

      Description copied from interface: `VectorWritable4LType`
      Set the current vector to the contents of the input vector.
      Specified by:
        `copyFrom4L` in interface `VectorWritable4LType`
      Parameters:
        `in_v` - The input vector

    - #### set4L

          public void set4L(long x,
                            long y,
                            long z,
                            long w)

      Description copied from interface: `VectorWritable4LType`
      Set the current `x`, `y`, `z` and `w` values of the current vector.
      Specified by:
        `set4L` in interface `VectorWritable4LType`
      Parameters:
        `x` - The new `x` value.
        `y` - The new `y` value.
        `z` - The new `z` value.
        `w` - The new `w` value.

    - #### copyFrom3L

          public void copyFrom3L(VectorReadable3LType in_v)

      Description copied from interface: `VectorWritable3LType`
      Set the current vector to the contents of the input vector.
      Specified by:
        `copyFrom3L` in interface `VectorWritable3LType`
      Parameters:
        `in_v` - The input vector

    - #### set3L

          public void set3L(long x,
                            long y,
                            long z)

      Description copied from interface: `VectorWritable3LType`
      Set the current `x`, `y` and `z` values of the current vector.
      Specified by:
        `set3L` in interface `VectorWritable3LType`
      Parameters:
        `x` - The new `x` value.
        `y` - The new `y` value.
        `z` - The new `z` value.

    - #### copyFrom2L

          public void copyFrom2L(VectorReadable2LType in_v)

      Description copied from interface: `VectorWritable2LType`
      Set the current vector to the contents of the input vector.
      Specified by:
        `copyFrom2L` in interface `VectorWritable2LType`
      Parameters:
        `in_v` - The input vector

    - #### set2L

          public void set2L(long x,
                            long y)

      Description copied from interface: `VectorWritable2LType`
      Set the current `x` and `y` values of the current vector.
      Specified by:
        `set2L` in interface `VectorWritable2LType`
      Parameters:
        `x` - The new `x` value.
        `y` - The new `y` value.

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `Object`

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

    - #### equals

          public boolean equals(@Nullable
                                Object obj)

      Overrides:
        `equals` in class `Object`

    - #### copyFromTyped4L

          public void copyFromTyped4L(PVectorReadable4LType<T> in_v)

      Description copied from interface: `PVectorWritable4LType`
      Set the current vector to the contents of the input vector.
      Specified by:
        `copyFromTyped4L` in interface `PVectorWritable4LType<T>`
      Parameters:
        `in_v` - The input vector

    - #### copyFromTyped3L

          public void copyFromTyped3L(PVectorReadable3LType<T> in_v)

      Description copied from interface: `PVectorWritable3LType`
      Set the current vector to the contents of the input vector.
      Specified by:
        `copyFromTyped3L` in interface `PVectorWritable3LType<T>`
      Parameters:
        `in_v` - The input vector

    - #### copyFromTyped2L

          public void copyFromTyped2L(PVectorReadable2LType<T> in_v)

      Description copied from interface: `PVectorWritable2LType`
      Set the current vector to the contents of the input vector.
      Specified by:
        `copyFromTyped2L` in interface `PVectorWritable2LType<T>`
      Parameters:
        `in_v` - The input vector

Copyright © 2015 <code@io7m.com> http://io7m.com