Package groovy.lang

Class Tuple1<T1>

All Implemented Interfaces:
Serializable, Cloneable, Comparable, Iterable, Collection, List, RandomAccess

public final class Tuple1<T1> extends Tuple
Represents a list of 1 typed Object.
Since:
2.5.0
See Also:
  • Constructor Details

    • Tuple1

      public Tuple1(T1 t1)
      Creates a tuple containing the supplied elements.
      Parameters:
      t1 - the first element
    • Tuple1

      public Tuple1(Tuple1<T1> tuple)
      Creates a tuple from the supplied tuple.
      Parameters:
      tuple - the source tuple
  • Method Details

    • getFirst

      @Deprecated public T1 getFirst()
      Deprecated.
      Returns the first element.
      Returns:
      the first element
    • getV1

      public T1 getV1()
      Returns the first element.
      Returns:
      the first element
    • clone

      public Tuple1<T1> clone()
      Overrides:
      clone in class Tuple