cancel()
Cancels the current work item asynchronously.
Declaration
func cancel()Discussion
Cancellation causes future attempts to execute the work item to return immediately. Cancellation does not affect the execution of a work item that has already begun.
Release of any resources associated with the block object is delayed until execution of the block object is next attempted (or any execution already in progress completes).