Contents

resolveSpatialEventTrigger(for:with:)

Resolves the location-based trigger to apply to the task.

Declaration

optional func resolveSpatialEventTrigger(for intent: INSetTaskAttributeIntent, with completion: @escaping  @Sendable (INSpatialEventTriggerResolutionResult) -> Void)
optional func resolveSpatialEventTrigger(for intent: INSetTaskAttributeIntent) async -> INSpatialEventTriggerResolutionResult

Parameters

  • intent:

    The intent object containing details about the user’s request. Use this object to get the initial information, if any, provided by the user.

  • completion:

    The handler block to execute with the resolution. You must execute this handler at some point during your implementation of this method. This handler has no return value and takes the following parameter:

    resolutionResult

    The object containing the details of your proposed resolution. For successful resolutions, create a resolution object with the Inspatialeventtrigger object that you intend to apply to the task.

Discussion

Implement this method to resolve the location-based trigger to apply to the task. For apps that support reminders based on the user’s proximity to a location, use this method to resolve the trigger information. If location-based reminders are optional, return a successful resolution when the user provided trigger information or return a not required resolution when there is no trigger information. If the intent includes some trigger information, but not enough for a successful resolution, you can ask the user to confirm or disambiguate from among the possible values.

See Also

Resolving the Intent Parameters