Handles deleting a task.
Required.
SDKs
- iOS 13.0+
- Mac Catalyst 13.0+
- watchOS 6.0+
Framework
- Intents
Declaration
- (void)handleDeleteTasks:(INDelete Tasks Intent *)intent completion:(void (^)(INDelete Tasks Intent Response *response))completion;
Parameters
intent
The intent object that contains details about the user's request. this object’s information has already been resolved and confirmed by your handler object.
completion
The handler block to execute with your response. You must execute this handler while implementing this method. This handler has no return value and takes the following parameter:
- response
The
INDelete
object that contains the status of the request. This parameter must not beTasks Intent Response nil
.
Discussion
Use this method to transfer control of deleting the task to your app. Delete the task based on the information in the intent parameter, create a response object with the relevant details, and call the provided completion handler.