Interface AsyncBody
-
public interface AsyncBody
A simplified java.util.concurrent.Flow.Subscription and a future tracking done.
The body should be consumed until the end or cancelled.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interface
AsyncBody.Consumer<T>
A functional interface for consuming async result bodies
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
cancel()
void
consume()
Called to deliver results to theAsyncBody.Consumer
CompletableFuture<Void>
done()
Tracks the completion of the body.
-
-
-
Method Detail
-
consume
void consume()
Called to deliver results to theAsyncBody.Consumer
-
done
CompletableFuture<Void> done()
Tracks the completion of the body.- Returns:
- the future
-
cancel
void cancel()
-
-