Interface WriteStreamSubscriber<T>

    • Method Detail

      • onFailure

        WriteStreamSubscriber<T> onFailure​(Consumer<? super Throwable> callback)
        Sets the handler to invoke on failure events.

        The underlying WriteStream.end() method is not invoked in this case.

        Parameters:
        callback - the callback invoked with the failure
        Returns:
        a reference to this, so the API can be used fluently
      • onComplete

        WriteStreamSubscriber<T> onComplete​(Runnable callback)
        Sets the handler to invoke on completion events.

        The underlying WriteStream.end() method is invoked before the given callback.

        Parameters:
        callback - the callback invoked when the completion event is received
        Returns:
        a reference to this, so the API can be used fluently
      • onWriteStreamError

        WriteStreamSubscriber<T> onWriteStreamError​(Consumer<? super Throwable> callback)
        Sets the handler to invoke if the adapted WriteStream fails.

        The underlying WriteStream.end() method is not invoked in this case.

        Parameters:
        callback - the callback invoked with the failure
        Returns:
        a reference to this, so the API can be used fluently