componentsSeparatedByCharactersInSet for pre-OS X 10.5

Mac OS X 10.5 added many convenient methods to existing Cocoa framework. However, whenever you want to write codes which should be also targeted to pre-OS X 10.5, you cannot but write your own version of the methods provided by 10.5.

Recently I had to use componentsSeparatedByCharactersInSet, and compiler complaint that NSString may not have the method. Umm.. I looked up the document, and Ah!!! it is only supported from 10.5!

So, I had to write the method for pre-10.5 OS X. However, fortunately I found existing implementation from a project hosted at Google. ( Thanks, Google code!!! )

It saved a handful of minutes!!


Leave a Reply

Please log in using one of these methods to post your comment: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: