public class OutputCollector<T> extends Object implements Collector<T>
RecordWriters.
The OutputCollector tracks to which writers a deep-copy must be given and which not.| Constructor and Description |
|---|
OutputCollector(List<RecordWriter<SerializationDelegate<T>>> writers,
TypeSerializer<T> serializer)
Initializes the output collector with a set of writers.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
void |
collect(T record)
Collects a record and emits it to all writers.
|
List<RecordWriter<SerializationDelegate<T>>> |
getWriters()
List of writers that are associated with this output collector
|
public OutputCollector(List<RecordWriter<SerializationDelegate<T>>> writers, TypeSerializer<T> serializer)
List.writers - List of all writers.public void collect(T record)
public List<RecordWriter<SerializationDelegate<T>>> getWriters()
Copyright © 2014–2017 The Apache Software Foundation. All rights reserved.