Class Pair.PairAdapter<L,​R>

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<Pair<L,​R>>, java.util.Map.Entry<L,​R>
    Enclosing class:
    Pair<L,​R>

    private static final class Pair.PairAdapter<L,​R>
    extends Pair<L,​R>
    • Constructor Detail

      • PairAdapter

        private PairAdapter()
    • Method Detail

      • getLeft

        public L getLeft()
        Description copied from class: Pair

        Gets the left element from this pair.

        When treated as a key-value pair, this is the key.

        Specified by:
        getLeft in class Pair<L,​R>
        Returns:
        the left element, may be null
      • getRight

        public R getRight()
        Description copied from class: Pair

        Gets the right element from this pair.

        When treated as a key-value pair, this is the value.

        Specified by:
        getRight in class Pair<L,​R>
        Returns:
        the right element, may be null
      • setValue

        public R setValue​(R value)