er.extensions.foundation
Class ERXEqualator
java.lang.Object
er.extensions.foundation.ERXEqualator
public abstract class ERXEqualator
- extends java.lang.Object
This class is an abstract class that defines an API for determining if two objects are equal.
This is useful if you'd like to have a custom definition of what it means for two objects to
be equal in one context (within an array, for example) while not changing the meaning of
equality in another (by overriding equals()). This is especially useful for doing
non-editing-context-sensitive equality checks between EOs.
Method Summary |
abstract boolean |
objectIsEqualToObject(java.lang.Object o1,
java.lang.Object o2)
Performs the equality check between o1 and o2. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SafeEqualsEqualator
public static final ERXEqualator SafeEqualsEqualator
- Provides a safe equality check that won't throw if one or both of the objects is null.
- See Also:
ERXExtensions#safeEquals(Object, Object)
EOEqualsEqualator
public static final ERXEqualator EOEqualsEqualator
- Provides EO equality checks regardless of the editing context the objects are registered in.
- See Also:
ERXEOControlUtilities#eoEquals(EOEnterpriseObject, EOEnterpriseObject)
ERXEqualator
public ERXEqualator()
objectIsEqualToObject
public abstract boolean objectIsEqualToObject(java.lang.Object o1,
java.lang.Object o2)
- Performs the equality check between o1 and o2. What the equality check means between the
objects and when either object is null or when objects are of different classes is
the subclass's responsibility.
- Parameters:
o1
- first object to compare.o2
- second object to compare.
- Returns:
- true if o1 and o2 are to be considered equal, false otherwise.
Copyright © 2002 – 2007 Project Wonder.