Reputation: 38401
When binding a NSArrayController, I see the following bindings available under controller content tab
However, I couldn't find those options inside the Apple reference for NSArrayController
, nor inside the actual NSArrayController.h
itself. Where do they come from? And how do they differ from the arrangedObject
property?
Screenshot Below
Upvotes: 2
Views: 625
Reputation: 96353
They're documented in the Cocoa Bindings Reference, and they're not publicly declared in any header file. Xcode's knowledge of them is baked into Xcode, probably in some plug-in somewhere that comes with it.
And how do they differ from the
arrangedObject
property?
arrangedObjects
(plural) is an output. The array controller arranges its content objects, and the result of that is its arranged objects.
The bindings are inputs:
contentArray
is the main one, since it is an array controller.contentSet
is an alternative for binding to Core Data to-many relationships, which are sets. I'm not sure whether it works with ordered sets; when the set isn't ordered, the order used by arrangeObjects:
and manifest in arrangedObjects
is determined by the array controller's sort descriptors.contentArrayForMultipleSelection
, you don't normally need. The case in which you do need it is described quite well in the Cocoa Bindings Reference.contentObject
is, as the CBR says, another array controller. Again, see the docs for its description of when you'd need it.Content comes from one (or more) of the content bindings, is arranged (according to any sort descriptors the array controller may have) by arrangeObjects:
, and is then available in the appointed order under arrangedObjects
.
Upvotes: 2