NSPlaceholders

The NSPlaceholders protocol provides an interface that allows an object to register default placeholders that will be displayed for a binding, when no other placeholder has been specified. Individual placeholder values can be specified for each of the marker objects (described in Selection Markers), as well as when the property is nil.

Overview

Placeholders are used when a property of an instance of the receiving class is accessed through a key value coding compliant method, and returns nil or a specialized marker.

Symbols

Managing default placeholders

class func setDefaultPlaceholder(Any?, forMarker: Any?, withBinding: String)

Sets placeholder as the default placeholder for the binding, when a key value coding compliant property of an instance of the receiving class returns the value specified by marker, and no other placeholder has been specified.

class func defaultPlaceholder(forMarker: Any?, withBinding: String)

Returns an object that will be used as the placeholder for the binding, when a key value coding compliant property of an instance of the receiving class returns the value specified by marker, and no other placeholder has been specified.

Constants

Selection Markers

The following constants are used to describe special cases for a controller’s selection.