edu.cmu.cs.crystal.util
Class Pair<A,B>

java.lang.Object
  extended by edu.cmu.cs.crystal.util.Pair<A,B>

public class Pair<A,B>
extends Object

Author:
Kevin Bierhoff

Constructor Summary
Pair()
           
Pair(A component1, B component2)
           
 
Method Summary
static
<A,B> Pair<A,B>
create(A component1, B component2)
           
 boolean equals(Object obj)
           
 A fst()
           
 int hashCode()
           
 void setComponent1(A component1)
           
 void setComponent2(B component2)
           
 B snd()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Pair

public Pair()

Pair

public Pair(A component1,
            B component2)
Method Detail

fst

public A fst()

setComponent1

public void setComponent1(A component1)

snd

public B snd()

setComponent2

public void setComponent2(B component2)

toString

public String toString()
Overrides:
toString in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

create

public static <A,B> Pair<A,B> create(A component1,
                                     B component2)