Open NorimasaNabeta opened 11 years ago
HINT13 Both the predicate and the sortDescriptors for your Recents CoreDataTableViewController’s NSFetchedResultsController’s NSFetchRequest are going to depend on knowing when a photo in the database was last viewed, so it might be a good idea to have an attribute for that in your schema and make sure it gets set properly.
HINT12 The sorting in CoreDataTableViewController-based view controllers should happen automatically as part of the NSFetchRequest you use to create your NSFetchedResultsController. Just make sure it has the right NSSortDescriptor.
HINT8 “To many” relationships are represented simply as an NSSet of NSManagedObject instances. So to set the value of a property that is a to-many relationship from the “many” side (if you need to do this), just create an NSMutableSet, add NSManagedObject instances to it, then set the property to that NSMutableSet.
HINT7 Note that if you have a two-way relationship in your model, setting one side automatically sets the other side properly for you.
The Recents tab should continue to meet all the requirements of the previous assignment. All Recents information should be stored in Core Data (i.e. do not use NSUserDefaults for Recents anymore).