Class ValuePair<Left,Right>

java.lang.Object
org.dmfs.jems2.pair.ValuePair<Left,Right>
All Implemented Interfaces:
Pair<Left,Right>

public final class ValuePair<Left,Right> extends Object implements Pair<Left,Right>
The most simple Pair there is. It takes two values and returns them on request.
  • Constructor Details

    • ValuePair

      public ValuePair(Left left, Right right)
  • Method Details

    • left

      public Left left()
      Description copied from interface: Pair
      The left value of the pair, i.e. the 1st value in this 2-tuple.
      Specified by:
      left in interface Pair<Left,Right>
    • right

      public Right right()
      Description copied from interface: Pair
      The right value of the pair, i.e. the 2nd value in this 2-tuple.
      Specified by:
      right in interface Pair<Left,Right>