Readonly
stateCurrent state of the transfer task.
Cancel an ongoing transfer(upload/download) task. This will reject the result
promise with an AbortError
by
default. You can use isCancelError
to check if the error is caused by cancellation.
Optional
message: stringOptional error message to overwrite the default canceled
message thrown when the task is
canceled. If provided, the result
promise will be rejected with a CanceledError with supplied error
message instead.
Promise that resolves when the transfer task is completed. The promise will be rejected if the task is canceled.