Interface SortedPair<K extends java.lang.Comparable<K>>

    • Method Detail

      • of

        static <K extends java.lang.Comparable<K>> SortedPair<K> of​(K l,
                                                                    K r)
        Returns a new immutable SortedPair with given left and right value.

        Note that if left and right are in the wrong order, they will be exchanged.

        Parameters:
        l - the left value.
        r - the right value.
        Implementation Notes:
        This factory method delegates to ObjectObjectImmutablePair.of(Object, Object).