|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.oddjob.beancmpr.comparers.EqualityComparer
public class EqualityComparer
A comparer that uses the equals method of an object.
If either or both of the objects are null the result of the compare will be null.
Constructor Summary | |
---|---|
EqualityComparer()
|
Method Summary | |
---|---|
Comparison<Object> |
compare(Object x,
Object y)
Compare two things. |
Class<Object> |
getType()
The type of the things. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public EqualityComparer()
Method Detail |
---|
public Comparison<Object> compare(Object x, Object y)
Comparer
compare
in interface Comparer<Object>
x
- One thing.y
- The other thing.
public Class<Object> getType()
Comparer
Note that we would have liked the return type
to be Class<T>
but we could not then have had a
Comparer<Iterable<MatchableGroup>>
because it's not possible to
return a type of Class<Iterable<MatchableGroup>>
in Java.
If there is a solution to this then please let us know.
getType
in interface Comparer<Object>
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |