add a description to CPSortDescriptor

This commit is contained in:
Klaas Pieter Annema
2011-01-05 12:47:36 +01:00
parent c87cb4bacd
commit f7bc2b6d06
+6
View File
@@ -129,6 +129,12 @@
return [[[self class] alloc] initWithKey:_key ascending:!_ascending selector:_selector];
}
- (CPString)description
{
return [CPString stringWithFormat:@"(%@, %@, %@)",
[self key], [self ascending] ? @"ascending": @"descending", CPStringFromSelector([self selector])];
}
@end
var CPSortDescriptorKeyKey = @"CPSortDescriptorKeyKey", // Don't you just love naming schemes ;)