Can a fetchedResultsController return an Array of Arrays? Or An array of NSSets?
Code below is an example, of what I'm trying to do. Is it possible?
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
//...
NSSet *objects = [_fetchedResultsController objectAtIndexPath:indexPath];
//...
}
The reason I'm doing this, is: if the user swipes the cell, and deletes it. I need all objects from that row deleted. And I also need to display data on that Cell, from calculation made on all the clocks for that Day/Row.
Here's my Core Data Model:
Each row must contain all Clock objects, for a given day, based on it's clockIn property. clockIn is a NSDate object. One row should represent one day.
Could I get help figuring out a predicate for this? Is it even possible?
Also, I'm already using sections in my Table View. So these are out of the question. There is one solution that I rather no go for, which is to create Year, Month and Day, Entities. This would fix. But it seems odd that I need to do that, considering the my clockIn property should give me everything I need.