Package com.io7m.jregions.core.parameterized.volumes

# Class PVolumeL<S>

java.lang.Object
com.io7m.jregions.core.parameterized.volumes.PVolumeL<S>

Type Parameters:
  `S` - A phantom type parameter indicating the coordinate space of the volume

All Implemented Interfaces:
  `PVolumeLType<S>`, `VolumeSizeValuesLType`, `VolumeValuesLType`

    public final class PVolumeL<S>
    extends java.lang.Object
    implements PVolumeLType<S>

A volume with `long` coordinates.

The coordinates of the area are given in half-closed form. That is, `minimumX()` refers to the minimum inclusive value on the X axis, and `maximumX()` refers to the maximum exclusive value on the X axis. Likewise for the Y and Z axes.

- ## Nested Class Summary

  Nested Classes
  Modifier and Type | Class | Description
  --- | --- | ---
  `static class` | `PVolumeL.Builder<S>` | Builds instances of type `PVolumeL`.

- ## Method Summary

  Modifier and Type | Method | Description
  --- | --- | ---
  `static <S> PVolumeL.Builder<S>` | `builder()` | Creates a builder for `PVolumeL`.
  `static <S> PVolumeL<S>` | `copyOf​(PVolumeLType<S> instance)` | Creates an immutable copy of a `PVolumeLType` value.
  `boolean` | `equals​(java.lang.Object another)` | This instance is equal to all instances of `PVolumeL` that have equal attribute values.
  `int` | `hashCode()` | Computes a hash code from attributes: `minimumX`, `maximumX`, `minimumY`, `maximumY`, `minimumZ`, `maximumZ`.
  `long` | `maximumX()` |
  `long` | `maximumY()` |
  `long` | `maximumZ()` |
  `long` | `minimumX()` |
  `long` | `minimumY()` |
  `long` | `minimumZ()` |
  `static <S> PVolumeL<S>` | `of​(long minimumX, long maximumX, long minimumY, long maximumY, long minimumZ, long maximumZ)` | Construct a new immutable `PVolumeL` instance.
  `java.lang.String` | `toString()` | Prints the immutable value `PVolumeL` with attribute values.
  `PVolumeL<S>` | `withMaximumX​(long value)` | Copy the current immutable object by setting a value for the `maximumX` attribute.
  `PVolumeL<S>` | `withMaximumY​(long value)` | Copy the current immutable object by setting a value for the `maximumY` attribute.
  `PVolumeL<S>` | `withMaximumZ​(long value)` | Copy the current immutable object by setting a value for the `maximumZ` attribute.
  `PVolumeL<S>` | `withMinimumX​(long value)` | Copy the current immutable object by setting a value for the `minimumX` attribute.
  `PVolumeL<S>` | `withMinimumY​(long value)` | Copy the current immutable object by setting a value for the `minimumY` attribute.
  `PVolumeL<S>` | `withMinimumZ​(long value)` | Copy the current immutable object by setting a value for the `minimumZ` attribute.

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

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

  ### Methods inherited from interface com.io7m.jregions.core.parameterized.volumes.PVolumeLType

  `checkPreconditions`

  ### Methods inherited from interface com.io7m.jregions.core.unparameterized.volumes.VolumeValuesLType

  `sizeX, sizeY, sizeZ`

- ## Method Details

  - ### minimumX

    public long minimumX()
    Specified by:
      `minimumX` in interface `PVolumeLType<S>`
    Specified by:
      `minimumX` in interface `VolumeValuesLType`
    Returns:
      The value of the `minimumX` attribute

  - ### maximumX

    public long maximumX()
    Specified by:
      `maximumX` in interface `PVolumeLType<S>`
    Specified by:
      `maximumX` in interface `VolumeValuesLType`
    Returns:
      The value of the `maximumX` attribute

  - ### minimumY

    public long minimumY()
    Specified by:
      `minimumY` in interface `PVolumeLType<S>`
    Specified by:
      `minimumY` in interface `VolumeValuesLType`
    Returns:
      The value of the `minimumY` attribute

  - ### maximumY

    public long maximumY()
    Specified by:
      `maximumY` in interface `PVolumeLType<S>`
    Specified by:
      `maximumY` in interface `VolumeValuesLType`
    Returns:
      The value of the `maximumY` attribute

  - ### minimumZ

    public long minimumZ()
    Specified by:
      `minimumZ` in interface `PVolumeLType<S>`
    Specified by:
      `minimumZ` in interface `VolumeValuesLType`
    Returns:
      The value of the `minimumZ` attribute

  - ### maximumZ

    public long maximumZ()
    Specified by:
      `maximumZ` in interface `PVolumeLType<S>`
    Specified by:
      `maximumZ` in interface `VolumeValuesLType`
    Returns:
      The value of the `maximumZ` attribute

  - ### withMinimumX

    public final PVolumeL<S> withMinimumX​(long value)
    Copy the current immutable object by setting a value for the `minimumX` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for minimumX
    Returns:
      A modified copy of the `this` object

  - ### withMaximumX

    public final PVolumeL<S> withMaximumX​(long value)
    Copy the current immutable object by setting a value for the `maximumX` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for maximumX
    Returns:
      A modified copy of the `this` object

  - ### withMinimumY

    public final PVolumeL<S> withMinimumY​(long value)
    Copy the current immutable object by setting a value for the `minimumY` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for minimumY
    Returns:
      A modified copy of the `this` object

  - ### withMaximumY

    public final PVolumeL<S> withMaximumY​(long value)
    Copy the current immutable object by setting a value for the `maximumY` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for maximumY
    Returns:
      A modified copy of the `this` object

  - ### withMinimumZ

    public final PVolumeL<S> withMinimumZ​(long value)
    Copy the current immutable object by setting a value for the `minimumZ` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for minimumZ
    Returns:
      A modified copy of the `this` object

  - ### withMaximumZ

    public final PVolumeL<S> withMaximumZ​(long value)
    Copy the current immutable object by setting a value for the `maximumZ` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for maximumZ
    Returns:
      A modified copy of the `this` object

  - ### equals

    public boolean equals​(java.lang.Object another)
    This instance is equal to all instances of `PVolumeL` that have equal attribute values.
    Overrides:
      `equals` in class `java.lang.Object`
    Returns:
      `true` if `this` is equal to `another` instance

  - ### hashCode

    public int hashCode()
    Computes a hash code from attributes: `minimumX`, `maximumX`, `minimumY`, `maximumY`, `minimumZ`, `maximumZ`.
    Overrides:
      `hashCode` in class `java.lang.Object`
    Returns:
      hashCode value

  - ### toString

    public java.lang.String toString()
    Prints the immutable value `PVolumeL` with attribute values.
    Overrides:
      `toString` in class `java.lang.Object`
    Returns:
      A string representation of the value

  - ### of

    public static <S> PVolumeL<S> of​(long minimumX, long maximumX, long minimumY, long maximumY, long minimumZ, long maximumZ)
    Construct a new immutable `PVolumeL` instance.
    Type Parameters:
      `S` - generic parameter S
    Parameters:
      `minimumX` - The value for the `minimumX` attribute
      `maximumX` - The value for the `maximumX` attribute
      `minimumY` - The value for the `minimumY` attribute
      `maximumY` - The value for the `maximumY` attribute
      `minimumZ` - The value for the `minimumZ` attribute
      `maximumZ` - The value for the `maximumZ` attribute
    Returns:
      An immutable PVolumeL instance

  - ### copyOf

    public static <S> PVolumeL<S> copyOf​(PVolumeLType<S> instance)
    Creates an immutable copy of a `PVolumeLType` value. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.
    Type Parameters:
      `S` - generic parameter S
    Parameters:
      `instance` - The instance to copy
    Returns:
      A copied immutable PVolumeL instance

  - ### builder

    public static <S> PVolumeL.Builder<S> builder()
    Creates a builder for `PVolumeL`.

         PVolumeL.&lt;S&gt;builder()
            .setMinimumX(long) // required minimumX
            .setMaximumX(long) // required maximumX
            .setMinimumY(long) // required minimumY
            .setMaximumY(long) // required maximumY
            .setMinimumZ(long) // required minimumZ
            .setMaximumZ(long) // required maximumZ
            .build();

    Type Parameters:
      `S` - generic parameter S
    Returns:
      A new PVolumeL builder