Class Tuple1<T1>

java.lang.Object
org.hawaiiframework.util.tuple.Tuple1<T1>
Type Parameters:
T1 - the type of the 1st element
All Implemented Interfaces:
Tuple
Direct Known Subclasses:
Tuple2

public class Tuple1<T1> extends Object implements Tuple
A Tuple of 1 element.
Since:
2.0.0
  • Constructor Details

    • Tuple1

      public Tuple1(T1 element1)
      Constructs a new Tuple with the supplied elements.
  • Method Details

    • getElement1

      public T1 getElement1()
      Returns the 1st element of this tuple.
      Returns:
      the 1st element of this tuple
    • setElement1

      public void setElement1(T1 element1)
      Sets the 1st element of this tuple.
    • size

      public int size()
      Description copied from interface: Tuple
      Returns the number of elements of this tuple.
      Specified by:
      size in interface Tuple
      Returns:
      the number of elements of this tuple
    • equals

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

      public int hashCode()
      Overrides:
      hashCode in class Object