init(name:protectionClass:)
Returns an on-device index with the specified name and data protection class.
Declaration
init(name: String, protectionClass: FileProtectionType?)Parameters
- name:
A name that pertains to your custom organization.
- protectionClass:
The file protection class. Acceptable values are None, Complete, Completeunlessopen, or Completeuntilfirstuserauthentication.
Mentioned in
Return Value
An index that can handle items within the specified protection class.
Discussion
Use this method to specify a protection class for an index. You can specify a default protection class for index items in the entitlements for your app.