Class Tuples


  • public final class Tuples
    extends Object
    Utilies for working with tuples.
    • Method Detail

      • ofMap

        public static final <T1,​T2> Stream<Tuple<T1,​T2>> ofMap​(Map<T1,​T2> map)
        Convert a Java Collections Map to a Stream of tuples.
        Type Parameters:
        T1 - The key type of the Map, becoming the type of the first tuple value.
        T2 - The value type of the Map, becoming the type of the second tuple value.
        Parameters:
        map - The map to convert.
        Returns:
        The resulting Stream of tuples.