Class Couple

java.lang.Object
org.opentcs.data.model.Couple
All Implemented Interfaces:
Serializable

public class Couple extends Object implements Serializable
A generic 2-tuple of long integer values, usable for 2D coordinates and vectors, for instance.
See Also:
  • Constructor Details

    • Couple

      public Couple(long x, long y)
      Creates a new instance.
      Parameters:
      x - The X coordinate.
      y - The Y coordinate.
  • Method Details

    • getX

      public long getX()
      Returns the x coordinate.
      Returns:
      x
    • getY

      public long getY()
      Returns the y coordinate.
      Returns:
      y
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object