Contents

init(keyName:)

Returns a new custom attribute key with the specified name.

Declaration

convenience init?(keyName: String)

Parameters

  • keyName:

    The name of the custom attribute for use as a key in a Cssearchableitemattributeset. The key name must be a string that contains only ASCII characters and no punctuation other than the underscore (that is “_”). The prefix kMD is reserved.

Return Value

A new custom attribute key.

Discussion

To create custom attribute key names, use a reverse DNS format that includes your company name and does not include the period character (”.”). For example, a key name of the form com_mycompany_myapp_mykeyname works well.

See Also

Creating a custom attribute