From 78040d7b324514ebb637ae4dcf9c9f7a6e6eded9 Mon Sep 17 00:00:00 2001 From: Nick Takayama Date: Thu, 16 Oct 2008 01:03:51 +0800 Subject: [PATCH] implementing CPString compare: so that sorting will work with default selector Signed-off-by: Nick Takayama --- Foundation/CPString.j | 13 ++++++++++++- 1 files changed, 12 insertions(+), 1 deletions(-) diff --git a/Foundation/CPString.j b/Foundation/CPString.j index 70e4d74..0a2ef55 100644 --- a/Foundation/CPString.j +++ b/Foundation/CPString.j @@ -409,9 +409,20 @@ var CPStringHashes = new objj_dictionary(); @param aString the string with which to compare @return the result of the comparison */ +- (CPComparisonResult)compare:(CPString)aString +{ + return [self compare:aString options:CPLiteralSearch]; +} + + +/* + Compares the receiver to the specified string. + @param aString the string with which to compare + @return the result of the comparison +*/ - (CPComparisonResult)caseInsensitiveCompare:(CPString)aString { - return [self compare:aString options:CPCaseInsensitiveSearch] + return [self compare:aString options:CPCaseInsensitiveSearch]; } /* -- 1.5.4.5