Karelia Software's Cocoa Open Source

A random collection of useful bits of Cocoa, as found in Watson and in other sundry Karelia applications and testbeds. Feel free to adapt these for use in your Cocoa applications.


"Flatten" a string of HTML, removing all HTML tags /Foundation_Categories/NSString
Simple checksum of a string /Foundation_Categories/NSString
Return the range of a substring, searching between a starting and ending delimeters /Foundation_Categories/NSString
Split a string into an array of lines; unicode-aware /Foundation_Categories/NSString
General search-and-replace mechanism to convert given substrings /Foundation_Categories/NSString
Strip out anything in the string that is not a digit /Foundation_Categories/NSString
Return the range of a substring, inclusively from starting to ending delimeters /Foundation_Categories/NSString
Remove lines from a text file that start with # /Foundation_Categories/NSString
Parse a TSV string into an array of dictionaries /Foundation_Categories/NSString
Encode a string legally so it can be turned into an NSURL /Foundation_Categories/NSString
General search and replace, replacing strings found between starting and ending delimeters. /Foundation_Categories/NSString
Return an NSString composed of the given single unicode character /Foundation_Categories/NSString
Convert a string into an attributed string that looks like a hyperlink -- blue and underlined. /Foundation_Categories/NSString

· Karelia Home