checkStatus method

Future<bool> checkStatus()

Initiates a request to check the server status.

The task contains a bool indicating if the check was successful. The task completes after the status has been checked. If the job is polling the server for status and is in a time gap, then calling this method will ensure a request is sent right away. The result can be false if the job is not checking server status for example if the job status is paused or uploading.

Return Value: a task containing bool which indicates if the status was successfully checked.

Implementation

Future<bool> checkStatus() {
  final taskHandle = _withThrowingErrorHandler((errorHandler) {
    return runtimecore.RT_Job_checkStatusAsync(_handle, errorHandler);
  });
  return taskHandle.toFuture((element) => element.getValueAsBool()!);
}