Saving and loading data
To add the ability to save and reopen a task list, you need to override two methods inherited from BNRDocument’s superclass, NSDocument:
- (NSData *)dataOfType:(NSString *)typeName error:(NSError **)outError { // This method is called when our document is being saved // You are expected to hand the caller an NSData object wrapping our data // so that it can be written to disk // If there is no array, ...
Get Objective-C Programming: The Big Nerd Ranch Guide now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.