1 11 package org.eclipse.core.internal.databinding; 12 13 17 public class Pair { 18 19 22 public final Object a; 23 24 27 public final Object b; 28 29 35 public Pair(Object a, Object b) { 36 this.a = a; 37 this.b = b; 38 } 39 40 43 public boolean equals(Object obj) { 44 if (obj.getClass() != Pair.class) { 45 return false; 46 } 47 Pair other = (Pair) obj; 48 return a.equals(other.a) && b.equals(other.b); 49 } 50 51 54 public int hashCode() { 55 return a.hashCode() + b.hashCode(); 56 } 57 } 58 | Popular Tags |