Hosanna UI API v1.30.2-next
    Preparing search index...

    Interface CancellationToken

    Interface representing a cancellation token. Used to signal and handle cancellation of asynchronous operations.

    interface CancellationToken {
        isCancellationRequested(): boolean;
        throwIfCancellationRequested(): void;
    }

    Implemented by

    Index

    Methods

    • Checks if a cancellation has been requested.

      Returns boolean

      True if cancellation is requested, false otherwise.

    • Throws an exception if cancellation has been requested.

      Returns void

      OperationCanceledException if isCancellationRequested is true.