Class ImmutableXYZD

All Implemented Interfaces:
Cloneable, ConfigurationSerializable

public class ImmutableXYZD extends XYZD
Extends XYZD and forbids any modifications done to it
  • Constructor Details

    • ImmutableXYZD

      public ImmutableXYZD(Location loc)
    • ImmutableXYZD

      public ImmutableXYZD(Vector vec)
    • ImmutableXYZD

      public ImmutableXYZD(XYZ xyz)
    • ImmutableXYZD

      public ImmutableXYZD(XYZD xyz)
    • ImmutableXYZD

      public ImmutableXYZD()
    • ImmutableXYZD

      public ImmutableXYZD(double x, double y, double z)
    • ImmutableXYZD

      public ImmutableXYZD(double x, double y, double z, XYZD.Direction dir)
  • Method Details

    • setX

      public XYZD setX(double x)
      Description copied from class: XYZ
      Sets the x-coordinate
      Overrides:
      setX in class XYZD
      Parameters:
      x - The new x-coordinate
      Returns:
      This XYZ instance
    • setY

      public XYZD setY(double y)
      Description copied from class: XYZ
      Sets the y-coordinate
      Overrides:
      setY in class XYZD
      Parameters:
      y - The new y-coordinate
      Returns:
      This XYZ instance
    • setZ

      public XYZD setZ(double z)
      Description copied from class: XYZ
      Sets the z-coordinate
      Overrides:
      setZ in class XYZD
      Parameters:
      z - The new z-coordinate
      Returns:
      This XYZ instance
    • set

      public XYZD set(double x, double y, double z)
      Description copied from class: XYZ
      Sets the new coordinates
      Overrides:
      set in class XYZD
      Parameters:
      x - The new x-coordinate
      y - The new y-coordinate
      z - The new z-coordinate
      Returns:
      This XYZ instance
    • set

      public XYZD set(XYZ xyz)
      Description copied from class: XYZ
      Copies and sets the xyz coordinates from the given object
      Overrides:
      set in class XYZD
      Parameters:
      xyz - The object from which it shall be taken from
      Returns:
      This XYZ instance
    • set

      public XYZD set(Location loc)
      Description copied from class: XYZ
      Copies and sets the xyz coordinates from the given object
      Overrides:
      set in class XYZD
      Parameters:
      loc - The object from which it shall be taken from
      Returns:
      This XYZ instance
    • add

      public XYZD add(double x, double y, double z)
      Description copied from class: XYZ
      Adds the x-coordinates
      Overrides:
      add in class XYZD
      Parameters:
      x - The added x-coordinate
      y - The added y-coordinate
      z - The added z-coordinate
      Returns:
      This XYZ instance
    • add

      public XYZD add(XYZ xyz)
      Overrides:
      add in class XYZD
    • add

      public XYZD add(Location loc)
      Overrides:
      add in class XYZD
    • add

      public XYZD add(Vector vec)
      Overrides:
      add in class XYZD
    • subtract

      public XYZD subtract(double x, double y, double z)
      Overrides:
      subtract in class XYZD
    • subtract

      public XYZD subtract(XYZ xyz)
      Overrides:
      subtract in class XYZD
    • subtract

      public XYZD subtract(Location loc)
      Overrides:
      subtract in class XYZD
    • subtract

      public XYZD subtract(Vector vec)
      Overrides:
      subtract in class XYZD
    • multiply

      public XYZD multiply(double amount)
      Overrides:
      multiply in class XYZD
    • multiply

      public XYZD multiply(double x, double y, double z)
      Overrides:
      multiply in class XYZD
    • zero

      public XYZD zero()
      Description copied from class: XYZ
      Sets all coordinates to 0
      Overrides:
      zero in class XYZD
      Returns:
      This XYZ instance
    • setDirection

      public XYZD setDirection(XYZD.Direction dir)
      Overrides:
      setDirection in class XYZD