Since an NSSet is, by definition, unordered, the allObjects method is not guaranteed to return the same ordering of objects every time. However, once you have the array, you could easily order it yourself using sortedArrayUsing(Selector/Comparator/Descriptors):.
And I've used this code (or really similar code) in production stuff before. Dave On May 25, 2010, at 10:58 AM, Michael A. Crawford wrote: > Hey, not bad. Does the -allObjects method always return the same sequence? > Did you just cobble this up or is this running in a system somewhere? It > doesn't do everything I want but it is definitely the better part of the > 80/20 rule. > > -Michael
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com