Instance Method

resolveTaskList(for:with:)

Resolves the task list from which to delete tasks.

Declaration

optional func resolveTaskList(for intent: INDeleteTasksIntent, with completion: @escaping (INDeleteTasksTaskListResolutionResult) -> Void)

Parameters

intent

The intent object that contains 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 while implementing this method. This handler has no return value and takes the following parameter:

resolutionResult

The object that contains the details of your proposed resolution. For a successful resolution, create a resolution object with the INTaskList object that represents the task list you intend to use.

Discussion

This method resolves the task list from which to delete tasks. Use the intent object to obtain the task list, if any, suggested by the user. If the intent doesn’t specify a task list, choose the most appropriate resolution for your app. If you can select a default task list, return a result of success with that task list. If you can’t select a default task list, ask the user to provide a value or choose from among a few likely candidates.

See Also