com.atlassian.jira.util.lang
Class Pair<F,S>

java.lang.Object
  extended by com.atlassian.jira.util.lang.Pair<F,S>
Type Parameters:
F - type of the first element
S - type of the second element

@ThreadSafe
public final class Pair<F,S>
extends java.lang.Object

Immutable, generic pair of non-null values. How coool is that!

Since:
v4.2

Method Summary
 boolean equals(java.lang.Object o)
           
 F first()
           
 int hashCode()
           
static
<U,V> Pair<U,V>
of(U first, V second)
           
 S second()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Method Detail

of

public static <U,V> Pair<U,V> of(U first,
                                 V second)

first

public F first()

second

public S second()

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


Copyright © 2002-2010 Atlassian. All Rights Reserved.