String Comparison OptionsHeader: CFString.h

These constants are flags turned on in a CFOptionFlag bitfield to specify options in Core Foundation comparison routines.

enum {
    kCFCompareCaseInsensitive = 1,
    kCFCompareBackwards = 4,
    kCFCompareAnchored = 8,
    kCFCompareNonliteral = 16,
    kCFCompareLocalized = 32,
    kCFCompareNumerically = 64
};

Constant descriptions

kCFCompareCaseInsensitive

Specifies that the comparison should ignore differences in case between alphabetical characters.

kCFCompareBackwards

Specifies that the comparison should start at the last elements of the entities being compared (for example, strings or arrays).

kCFCompareAnchored

Specifies that the comparison start at the point specified by another parameter.

kCFCompareNonliteral

Specifies that loose equivalence is acceptable, especially as pertains to diacritical marks. For example, "o"-umlaut is equal to "o", umlaut and accented "a" is equal to unaccented "a".

kCFCompareLocalized

Specifies that the comparison should take into account differences related to locale, such as the thousands separator character.

kCFCompareNumerically

Specifies that represented numeric values should be used as the basis for comparison and not the actual character values. For example, "version 2" is less than "version 2.5".

These constants are flags intended for use in CFOptionFlags parameters in comparison functions such as CFStringCompare. If you want to request multiple options, OR them together.


© 1999 Apple Computer, Inc. — (Last Updated 9/15/99)