Skip to content

Instantly share code, notes, and snippets.

@below
Created May 26, 2014 07:46
Show Gist options
  • Save below/c12a68772110613cbc77 to your computer and use it in GitHub Desktop.
Save below/c12a68772110613cbc77 to your computer and use it in GitHub Desktop.
I would think my question is pretty easy, as what I am trying to do seems like a very common use case.
There are two entities, "Speaker" and "Session". And the Speaker has a to-many relationship, "sessions", with an inverse in the Session entity. So a Speaker can be related to many sessions, and a Session can have many speakers.
My problem is in the UI: I have an NSArrayController, "SpeakerSessionController", its purpose is to show the sessions currently associated with the selected speaker. So the goal was to set its content array to the sessions key of the selection of my "SpeakerController". That does not work natively (neither does setting the content set), so I threw in a value transformer to transform the _NSMutableFaultingSet to an NSArray.
So far, so good. I can now add a session to the speaker it seems, putting a breakpoint into the value transformer shows me that there is an object.
But it is not shown in the table view that should be listing all the sessions for the selected speaker. Where am I going wrong?
Find the whole project at http://github.com/below/AltConfData
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment