Instance Method

setValue(_:forCustomKey:)

Sets the value for a custom attribute key.

Declaration

func setValue(_ value: NSSecureCoding?, forCustomKey key: CSCustomAttributeKey)

Parameters

value

The value of the custom attribute. Values must be common property list types, such as NSString, NSNumber, NSNull, NSData, or NSDate, or an array of property list types.

key

The custom attribute key.

See Also

Working with Custom Attributes

func value(forCustomKey: CSCustomAttributeKey) -> NSSecureCoding?

Returns the value associated with the specified custom attribute key.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software