Package: groovy.lang

## [Java] Class Tuple1<T1>

- groovy.lang.Tuple1

-     public final class Tuple1<T1>
      extends Tuple

  Represents a list of 1 typed Object.

  Since:
    2.5.0

- - ### Constructor Summary

    Constructors
    Constructor and description
    `Tuple1(T1 t1)` Creates a tuple containing the supplied elements.
    `Tuple1(Tuple1<T1> tuple)` Creates a tuple from the supplied tuple.

  - ### Methods Summary

    Methods
    Type Params | Return Type | Name and description
    --- | --- | ---
    `` | `public Tuple1<T1>` | `clone()` {@inheritDoc}
    `` | `public T1` | `getFirst()` Returns the first element.
    `` | `public T1` | `getV1()` Returns the first element.

  - ### Inherited Methods Summary

    Inherited Methods
    Methods inherited from class | Name
    --- | ---
    `class Tuple` | `clone, compareTo, equals, get, hashCode, size, subList, subTuple, toArray, toArray, tuple, tuple, tuple, tuple, tuple, tuple, tuple, tuple, tuple, tuple, tuple, tuple, tuple, tuple, tuple, tuple, tuple`

- - ### Constructor Detail

    - #### public Tuple1(T1 t1)

      Creates a tuple containing the supplied elements.

      Parameters:
        `t1` - the first element

    - #### public Tuple1(Tuple1<T1> tuple)

      Creates a tuple from the supplied tuple.

      Parameters:
        `tuple` - the source tuple

  - ### Method Detail

    - #### public Tuple1<T1> clone()

      {@inheritDoc}

    - #### @Deprecated
      public T1 getFirst()

      Returns the first element.

      Returns:
        the first element

    - #### public T1 getV1()

      Returns the first element.

      Returns:
        the first element