com.acsinet_solutions.cetia4.data
Class CompositeIntKey

java.lang.Object
  extended by com.acsinet_solutions.cetia4.data.CompositeIntKey
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable

public final class CompositeIntKey
extends java.lang.Object
implements java.io.Serializable, java.lang.Comparable

A simple convenience immutable composite key of two int values

Author:
Santiago Arriaga - santiago.arriaga@acsinet-solutions.com
See Also:
Serialized Form

Constructor Summary
CompositeIntKey(int id1, int id2)
           
 
Method Summary
 int compareTo(java.lang.Object obj)
           
 boolean equals(java.lang.Object obj)
           
 int getId1()
          Get the first id value
 int getId2()
          Get the second id value
 int hashCode()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CompositeIntKey

public CompositeIntKey(int id1,
                       int id2)
Method Detail

getId1

public int getId1()
Get the first id value


getId2

public int getId2()
Get the second id value


compareTo

public final int compareTo(java.lang.Object obj)
Specified by:
compareTo in interface java.lang.Comparable
See Also:
Comparable.compareTo(java.lang.Object)

equals

public final boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object
See Also:
Object.equals(java.lang.Object)

hashCode

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

toString

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