Interface CancellationTokenSource

    • Method Detail

      • cancel

        void cancel()
        Initiates cancel request. All operations that have been associated with this token will be cancelled.

        It is assumed that the implementation will do 'best-effort' attempt to perform cancellation. This method returns immediately and if the cancellation is successful the cancelled operation will notify its ResultHandler.onFailure(GradleConnectionException) with a BuildCancelledException describing how it was cancelled.

      • token

        CancellationToken token()
        Returns a token associated with this CancellationTokenSource. Always returns the same instance.
        Returns:
        The cancellation token.