|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.kuali.rice.core.api.util.EqualsAndHashCodeUtils
public final class EqualsAndHashCodeUtils
Class of static utility methods used to aid in the generation of hashcode values and equals comparisons of objects for corner cases that EqualsBuilder and HashCodeBuilder of commons-lang cannot cover.
Method Summary | ||
---|---|---|
static
|
equalsUsingCompareToOnFields(T o1,
T o2,
String... fieldNames)
This method provides an equals comparison of two objects by evaluating the results of compareTo across specified internal fields of the class of the two objects being compared. |
|
static int |
hashCodeForCalendars(Calendar... calendars)
Generates an int hashcode from all calendars passed in. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static <T> boolean equalsUsingCompareToOnFields(T o1, T o2, String... fieldNames)
T
- Type of both o1 and o2 parameters. Guarantees both o1 and o2 are the same reference type.o1
- The first object used in an equality operation using compareToo2
- The second object used in an equality operation using compareTofieldNames
- All field names within type T that should be determined equal or not using compareTo
public static int hashCodeForCalendars(Calendar... calendars)
calendars
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |