invalidate
TypeScriptinvalidate(): Promise<void>Swift declarationfunc invalidate() async throwsRequests that the extension terminate. This calls ``ContactProviderExtension/invalidate()`` on the extension.
class · iOS 18.0+ · SDK 27.1
class ContactProviderManagerAn interface for the app to control its extension.
invalidate(): Promise<void>Swift declarationfunc invalidate() async throwsRequests that the extension terminate. This calls ``ContactProviderExtension/invalidate()`` on the extension.
static init(domainIdentifier?: string): ContactProviderManagerSwift declarationinit(domainIdentifier: String = DefaultContactProviderDomain.identifier) throwsCreates a provider manager. If needed, the manager registers the ``DefaultContactProviderDomain`` for the extension. - Parameter domainIdentifier: A string to identify a domain of contacts to provide. Defaults to ``DefaultContactProviderDomain/identifier-swift.type.property``. - Throws: ``ContactProviderError/extensionNotFound`` if discovering the extension fails. - Throws: ``ContactProviderError/featureNotAvailable`` when running on an unsupported platform.
signalEnumerator(collection?: ContactItem_Identifier): Promise<void>Swift declarationfunc signalEnumerator(for collection: ContactItem.Identifier = .rootContainer) async throwsRequests that the extension enumerate its contacts for the domain. You typically call this when you need to invoke the app extension on demand. One example is when the app receives a push notification informing it that updated contact data is available. - Parameter collection: The collection to enumerate; defaults to ``ContactItem/Identifier/rootContainer``.
reset(): Promise<void>Swift declarationfunc reset() async throwsResets the extension domain. You typically call this when you need to delete all previously-provided contacts for the domain. The next invocation of the app extension restarts content enumeration for the domain.
get domain(): SDKHandleSwift declarationvar domain: any ContactProviderDomain { get }The domain that this instance manages. This value defaults to ``DefaultContactProviderDomain``.
enable(): Promise<void>Swift declarationfunc enable() async throwsRequests the person using the app to enable the extension domain. If necessary, this call waits for the person using the app to explicitly approve or deny using the extension domain. - Throws: `ContactProviderError.deniedByUser` if the person dismisses the prompt without enabling the extension domain.
disable(): Promise<void>Swift declarationfunc disable() async throwsDisables the extension domain. Disabling the extension deletes all previously-provided contacts for the domain.
get isEnabled(): booleanSwift declarationvar isEnabled: Bool { get }A Boolean value that indicates whether the person using the app enabled the extension domain.
No declarations were skipped in this snapshot.