Class Pair<F,​S>


  • public class Pair<F,​S>
    extends Object
    An immutable pair of objects. This implements equals and hashCode by delegating to the pair objects.
    Author:
    bratseth
    • Constructor Detail

      • Pair

        public Pair​(F first,
                    S second)
        Creates a pair. Each member may be set to null.
    • Method Detail

      • getFirst

        public F getFirst()
        Returns the first member. This may be null.
      • getSecond

        public S getSecond()
        Returns the second member. This may be null.
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object