Displaying two different sub-entities in one table view
Displaying two different sub-entities in one table view
- Subject: Displaying two different sub-entities in one table view
- From: Jean-Henri Duteau <email@hidden>
- Date: Fri, 5 Mar 2010 10:04:18 -0800
I have a CoreData project and I'm trying to figure out how to display multiple entity types in one table view.
I have a Team that has Skaters and Goalies. Skaters and Goalies have Player as a parent. Team has a to-many relationship to Player. I have a TableView that displays all of the players of a selected team. Everything works just fine as long as I restrict myself to attributes that are only on the Player object. But I want to display Skater attributes and Goalie attributes. There is an additional wrinkle that the attributes are located off a Ratings object attached to each Player. A Skater has a SkaterRatings object while a Goalie has a GoalieRatings object.
I've tried a number of different ways to make this happen. I *think* that I may need to produce a custom TableViewDataSource and I tried to do this with the content backed by an NSArrayController, but I couldn't make that work.
Has anyone else tried to do this?
Jean
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden