OUT
- Output type@PublicEvolving public interface AsyncCollector<OUT>
AsyncCollector
collects data / error in user codes while processing async i/o.Modifier and Type | Method and Description |
---|---|
void |
collect(Collection<OUT> result)
Set result.
|
void |
collect(Throwable error)
Set error.
|
void collect(Collection<OUT> result)
Note that it should be called for exactly one time in the user code. Calling this function for multiple times will cause data lose.
Put all results in a Collection
and then emit output.
result
- A list of results.void collect(Throwable error)
error
- A Throwable object.Copyright © 2014–2018 The Apache Software Foundation. All rights reserved.