NSTreeController Bindings
Availability Bindings
editable
A multiple-value binding that determines if the NSTreeController
is editable in the user interface.
When editable
is bound, a new binding, editable2
, is exposed and can be bound. Binding to editable2
causes editable3
to be exposed, and so on.
The contents of the NSTreeController
are editable if a logical AND operation on all the editable
bindings results in a Boolean value of YES
.
Controller Content Bindings
contentArray
An indexed collection that specifies the content of the NSTreeController
.
The indexed collection is an NSArray instance or subclass, a property that is accessible using the key-value-coding indexed accessor methods, or is accessible through mutableArrayValueForKey:
.
You should use the contentSet
binding for Core Data to-many relationships.
contentArrayForMultipleSelection
An indexed collection specifying the items that the NSTreeController
treats as its content objects when the contentArray
or contentObject
binding returns the multiple selection marker.
The indexed collection is an NSArray instance or subclass, a property that is accessible using the key-value-coding indexed accessor methods, or is accessible through mutableArrayValueForKey:
.
This binding is used when the NSTreeController
displays the detail objects in a master-detail relationship, and the master controller allows multiple selection. Typically when multiple items are selected in the master controller, the detail controller bindings return the values set as the multiple values placeholder. When contentArrayForMultipleSelection
is bound, the items in that array are used instead.
This binding is useful when combined with array operators. For example, contentArray
is bound to the "selection.employees' keypath of companyArrayController
and, contentArrayForMultipleSelection
is bound to the "selection.@distinctUnionOfArrays.employees" keypath of companyArrayController
. When a single company is selected in companyArrayController
, the employees of that company are used as the content. When multiple companies are selected, the employees from all the selected companies are used as content.
contentObject
An object that the NSTreeController
treats as its content.
This is bound when the object is the detail controller in a master-detail configuration. The binding is typically created with the selection key path in the master array controller that represents an attribute or to-one relationship. When the master array controller's selection returns the multiple selection marker, the contentArrayForMultipleSelection
binding is used as the content of the NSTreeController
.
contentSet
An NSSet that specifies the content of the NSTreeController
.
Controller Content Parameters Bindings
selectionIndexPaths
An array of NSIndexPath instances that specify the current selection in the NSTreeController
.
sortDescriptors
An indexed collection of NSSortDescriptor instances that specify the sort ordering of the contents of the NSTreeController
.
The indexed collection is an NSArray instance or subclass, or a property that is accessible using the key-value-coding indexed accessor methods.
Parameters Bindings
managedObjectContext
The NSManagedObjectContext instance that the NSTreeController
is registered with.
Copyright © 2004, 2014 Apple Inc. All Rights Reserved. Terms of Use | Privacy Policy | Updated: 2014-07-15