Class LongObjTuple2<T>

    • Method Detail

      • of

        public static <T> LongObjTuple2<T> of​(long t1,
                                              T t2)
        Create a LongObjTuple2 with the given objects.
        Type Parameters:
        T - The type of the second value.
        Parameters:
        t1 - The first value in the tuple. Not null.
        t2 - The second value in the tuple. Not null.
        Returns:
        The new LongObjTuple2.
      • from

        public static <T> LongObjTuple2<T> from​(reactor.util.function.Tuple2<Long,​T> tuple2)
        Converts a Tuple2 to a LongObjTuple2.
        Type Parameters:
        T - The type of the second value.
        Parameters:
        tuple2 - The Tuple2 to convert.
        Returns:
        The new converted LongObjTuple2.
      • convert

        public static <T> reactor.util.function.Tuple2<Long,​T> convert​(LongObjTuple2<T> tuple)
        Converts a LongObjTuple2 to a Tuple2.
        Type Parameters:
        T - The type of the second value.
        Parameters:
        tuple - The LongObjTuple2 to convert.
        Returns:
        The new converted Tuple2.
      • getT1

        public long getT1()
        Type-safe way to get the fist object of this Tuples.
        Returns:
        The first object
      • getT2

        public T getT2()
        Type-safe way to get the second object of this Tuples.
        Returns:
        The second object
      • get

        @Nullable
        public Object get​(int index)
        Get the object at the given index.
        Parameters:
        index - The index of the object to retrieve. Starts at 0.
        Returns:
        The object or null if out of bounds.
      • toList

        public List<Object> toList()
        Turn this Tuples into a plain Object list.
        Returns:
        A new Object list.
      • toArray

        public Object[] toArray()
        Turn this Tuples into a plain Object array.
        Returns:
        A new Object array.
      • equals

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

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

        public int size()
        Return the number of elements in this Tuples.
        Returns:
        The size of this Tuples.
      • toString

        public final String toString()
        A Tuple String representation is the comma separated list of values, enclosed in square brackets.
        Overrides:
        toString in class Object
        Returns:
        the Tuple String representation