tuweni / org.apache.tuweni.concurrent / AsyncCompletion / whenComplete

whenComplete

abstract fun whenComplete(consumer: Consumer<in Throwable!>!): AsyncCompletion! (source)

Returns a new completion that completes in the same manner as this completion, after executing the given function with this completion's exception (if any).

The exception supplied to the function will be null if this completion completes successfully.

Parameters

consumer - Consumer<in Throwable!>!: The action to execute.

Return
AsyncCompletion!: A new result.