PATH  WebObjects 4.0 Documentation > EOControl Reference



EOQualifier.ComparisonSupport

Inherits From:
java.lang.Object

Package:
com.apple.client.eocontrol (Siva)

Class Description

Siva's class EOQualifier.ComparisonSupport provides default implementations of the EOQualifierComparison interface. It is for use in client-side enterprise object classes only; there is no equivalent Yellow Box class for server-side enterprise objects.

Siva's EOCustomObject uses EOQualifier.ComparisonSupport's default implementations. Typically your custom enterprise object classes inherit from EOCustomObject and inherit the default implementations. If your custom enterprise object class doesn't inherit from EOCustomObject, you should implement the EOQualifierComparison interface directly.

Method Types

Setting up automatic support
setSupportForClass
supportForClass
Comparing two objects
compareValues
EOQualifierComparison methods
compareValues
setSupportForClass
supportForClass
EOQualifier.ComparisonSupport
doesContain
isCaseInsensitiveLike
isEqualTo
isGreaterThan
isGreaterThanOrEqualTo
isLessThan
isLessThanOrEqualTo
isLike
isNotEqualTo

Static Methods


compareValues

public static int compareValues (java.lang.Object anObject, java.lang.Object anotherObject, com.apple.client.foundation.NSSelector selector)

Compares the two objects using selector. You should use this method to compare value objects instead of calling selector directly. This method is the entry point for the comparison support, and calls methods in support classes if appropriate.

See also: setSupportForClass , supportForClass


setSupportForClass

public static void setSupportForClass (EOSortOrdering. ComparisonSupport supportClass, java.lang.Class aClass)

Sets supportClass as the support class to be used for comparing instances of aClass. When compareValues is called, the methods in supportClass will be used to do the comparison for instances of aClass.

See also: compareValues


supportForClass

public static EOSortOrdering. ComparisonSupport supportForClass (java.lang.Class aClass)

Returns the support class used for doing sort ordering comparisons for instances of aClass.

See also: compareValues , setSupportForClass

Instance Methods


doesContain

public boolean doesContain (java.lang.Object receiver, java.lang.Object anObject)

Returns YES if receiver contains anObject, NO if it doesn't. NSObject's implementation of this method returns YES only if receiver is a kind of NSArray and contains anObject. In all other cases it returns NO. This method is used in the Framework only by EOQualifier for in-memory evaluation.


isCaseInsensitiveLike

public boolean isCaseInsensitiveLike (java.lang.Object receiver, java.lang.Object anObject)

Returns YES if receiver is a case-insensitive match for aString, NO if it isn't. See "Using Wildcards" in the EOQualifier class specification for the wildcard characters allowed. NSObject's implementation returns NO; NSString's performs a proper case-insensitive comparison. This method is used in the Framework only by EOQualifier for in-memory evaluation.

See also: isLike , doesContain , isEqualTo , isGreaterThan , isGreaterThanOrEqualTo , isLessThan , isLessThanOrEqualTo ,isNotEqualTo


isEqualTo

public boolean isEqualTo (java.lang.Object receiver, java.lang.Object anObject)

Invokes isEqual: and returns the result. This method is used in the Framework only by EOQualifier for in-memory evaluation.

See also: doesContain , isGreaterThan , isGreaterThanOrEqualTo , isLessThan , isLessThanOrEqualTo , isLike , isCaseInsensitiveLike , isNotEqualTo


isGreaterThan

public boolean isGreaterThan (java.lang.Object receiver, java.lang.Object anObject)

Invokes compare: and returns YES if the result is NSOrderedDescending. This method is used in the Framework only by EOQualifier for in-memory evaluation.

See also: doesContain , isEqualTo , isGreaterThanOrEqualTo , isLessThan , isLessThanOrEqualTo , isLike , isCaseInsensitiveLike , isNotEqualTo


isGreaterThanOrEqualTo

public boolean isGreaterThanOrEqualTo (java.lang.Object receiver, java.lang.Object anObject)

Invokes compare: and returns YES if the result is NSOrderedDescending or NSOrderedSame. This method is used in the Framework only by EOQualifier for in-memory evaluation.

See also: doesContain , isEqualTo , isGreaterThan , isLessThan , isLessThanOrEqualTo , isLike , isCaseInsensitiveLike , isNotEqualTo


isLessThan

public boolean isLessThan (java.lang.Object receiver, java.lang.Object anObject)

Invokes compare: and returns YES if the result is NSOrderedAscending. This method is used in the Framework only by EOQualifier for in-memory evaluation.

See also: doesContain , isEqualTo , isGreaterThan , isGreaterThanOrEqualTo , isLessThanOrEqualTo , isLike , isCaseInsensitiveLike , isNotEqualTo


isLessThanOrEqualTo

public boolean isLessThanOrEqualTo (java.lang.Object receiver, java.lang.Object anObject)

Invokes compare: and returns YES if the result is NSOrderedAscending or NSOrderedSame. This method is used in the Framework only by EOQualifier for in-memory evaluation.

See also: doesContain , isEqualTo , isGreaterThan , isGreaterThanOrEqualTo , isLessThan , isLike , isCaseInsensitiveLike , isNotEqualTo


isLike

public boolean isLike (java.lang.Object receiver, java.lang.Object anObject)

Returns YES if receiver matches aString according to the semantics of the SQL like comparison operator, NO if it doesn't. See "Using Wildcards" in the EOQualifier class specification for the wildcard characters allowed. NSObject's implementation returns NO; NSString's performs a proper comparison. This method is used in the Framework only by EOQualifier for in-memory evaluation.

See also: isCaseInsensitiveLike , doesContain , isEqualTo , isGreaterThan , isGreaterThanOrEqualTo , isLessThan , isLessThanOrEqualTo , isNotEqualTo


isNotEqualTo

public boolean isNotEqualTo (java.lang.Object receiver, java.lang.Object anObject)

Invokes isEqual: , inverts the result, and returns it. This method is used in the Framework only by EOQualifier for in-memory evaluation.

See also: doesContain , isEqualTo , isGreaterThan , isGreaterThanOrEqualTo , isLessThan , isLessThanOrEqualTo , isLike , isCaseInsensitiveLike





Copyright © 1998, Apple Computer, Inc. All rights reserved.