de.caff.generics.mda

## Class ThreeDimensionalByteArray

- java.lang.Object
- - de.caff.generics.mda.ThreeDimensionalByteArray

- All Implemented Interfaces:
    MultiDimensional, MultiDimensionalAccess<java.lang.Byte>, MultiDimensionalReadAccess<java.lang.Byte>, ThreeDimensionalAccess<java.lang.Byte>, ThreeDimensionalByteAccess, ThreeDimensionalByteReadAccess, ThreeDimensionalReadAccess<java.lang.Byte>

      public class ThreeDimensionalByteArray
      extends java.lang.Object
      implements ThreeDimensionalByteAccess

  A 3-dimensional array of byte values.
  Since:
    November 11, 2019
  Author:
    Rammi

- - ### Field Summary

    - ### Fields inherited from interface de.caff.generics.mda.ThreeDimensionalByteAccess

      `EMPTY`

    - ### Fields inherited from interface de.caff.generics.mda.MultiDimensionalReadAccess

      `EMPTY0, EMPTY1, EMPTY2, EMPTY3, EMPTY4, EMPTY5, EMPTY6, EMPTY7`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `ThreeDimensionalByteArray(int ySize, int zSize, byte... values)` Constructor.
    `ThreeDimensionalByteArray(int xSize, int ySize, int zSize)` Constructor.
    `ThreeDimensionalByteArray(int xSize, int ySize, int zSize, IntToByteFunction3 filler)` Initializing constructor.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `byte` | `getValueAt(int ix, int iy, int iz)` Get the value at the given indexes.
    `void` | `setValueAt(byte value, int ix, int iy, int iz)` Set the value at the given indexes.
    `int` | `sizeX()` Get the number of elements in X direction.
    `int` | `sizeY()` Get the number of elements in Y direction
    `int` | `sizeZ()` Get the number of elements in Z direction

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

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface de.caff.generics.mda.ThreeDimensionalByteAccess

      `changeAllValues, changeValueAt, fillValuesByIndex, setElementAt, subAtX, subAtY, subAtZ`

    - ### Methods inherited from interface de.caff.generics.mda.ThreeDimensionalByteReadAccess

      `getElementAt, singleton`

    - ### Methods inherited from interface de.caff.generics.mda.ThreeDimensionalAccess

      `changeAll, changeAll, empty, fillByIndex, setElement`

    - ### Methods inherited from interface de.caff.generics.mda.ThreeDimensionalReadAccess

      `getElement, getNumDimensions, getNumElements, getSize, getSizes, view, visitAll, visitAll`

    - ### Methods inherited from interface de.caff.generics.mda.MultiDimensionalAccess

      `change, setAll, setFrom, setFrom, setFrom`

    - ### Methods inherited from interface de.caff.generics.mda.MultiDimensionalReadAccess

      `empty, linearized`

- - ### Constructor Detail

    - #### ThreeDimensionalByteArray

          public ThreeDimensionalByteArray(int xSize,
                                           int ySize,
                                           int zSize)

      Constructor. This will fill all values with `0`.
      Parameters:
        `xSize` - X size of array
        `ySize` - Y size of array
        `zSize` - Z size of array
      See Also:
        `ThreeDimensionalByteArray(int, int, int, IntToByteFunction3)`

    - #### ThreeDimensionalByteArray

          public ThreeDimensionalByteArray(int xSize,
                                           int ySize,
                                           int zSize,
                                           @NotNull
                                           IntToByteFunction3 filler)

      Initializing constructor.
      Parameters:
        `xSize` - X size of array
        `ySize` - Y size of array
        `zSize` - Z size of array
        `filler` - setter function which provides the value to set for each index combination
      See Also:
        `ThreeDimensionalByteAccess.fillValuesByIndex(de.caff.generics.function.IntToByteFunction3)`

    - #### ThreeDimensionalByteArray

          public ThreeDimensionalByteArray(int ySize,
                                           int zSize,
                                           byte... values)

      Constructor.
      Parameters:
        `ySize` - size in y direction
        `zSize` - size in z direction
        `values` - values in order, the first `zSize` values will become row 0 of plane 0, the second `zSize` values row 1, and so on until the first plane of `ySize` rows is filled. Then the next plane is filled. Needs a multiple of `ySize*zSize` values, and the multiplicator defines the X size.

  - ### Method Detail

    - #### setValueAt

          public void setValueAt(byte value,
                                 int ix,
                                 int iy,
                                 int iz)

      Description copied from interface: `ThreeDimensionalByteAccess`
      Set the value at the given indexes.
      Specified by:
        `setValueAt` in interface `ThreeDimensionalByteAccess`
      Parameters:
        `value` - value to set
        `ix` - X index
        `iy` - Y index
        `iz` - Z index

    - #### getValueAt

          public byte getValueAt(int ix,
                                 int iy,
                                 int iz)

      Description copied from interface: `ThreeDimensionalByteReadAccess`
      Get the value at the given indexes.
      Specified by:
        `getValueAt` in interface `ThreeDimensionalByteReadAccess`
      Parameters:
        `ix` - X index
        `iy` - Y index
        `iz` - Z index
      Returns:
        value at the given index

    - #### sizeX

          public int sizeX()

      Description copied from interface: `ThreeDimensionalReadAccess`
      Get the number of elements in X direction.
      Specified by:
        `sizeX` in interface `ThreeDimensionalReadAccess<java.lang.Byte>`
      Returns:
        number of elements in X direction

    - #### sizeY

          public int sizeY()

      Description copied from interface: `ThreeDimensionalReadAccess`
      Get the number of elements in Y direction
      Specified by:
        `sizeY` in interface `ThreeDimensionalReadAccess<java.lang.Byte>`
      Returns:
        number of elements in Y direction

    - #### sizeZ

          public int sizeZ()

      Description copied from interface: `ThreeDimensionalReadAccess`
      Get the number of elements in Z direction
      Specified by:
        `sizeZ` in interface `ThreeDimensionalReadAccess<java.lang.Byte>`
      Returns:
        number of elements in Z direction