public class DelegatingReadableData<S,T> extends Object implements ReadableData<T>
ReadableData<T> interface by delegating to an ReadableData<S> instance
and passing its contents through a DoFn<S, T>.| Constructor and Description |
|---|
DelegatingReadableData(ReadableData<S> delegate,
DoFn<S,T> fn) |
| Modifier and Type | Method and Description |
|---|---|
void |
configure(org.apache.hadoop.conf.Configuration conf)
Allows this instance to specify any additional configuration settings that may
be needed by the job that it is launched in.
|
Set<SourceTarget<?>> |
getSourceTargets() |
Iterable<T> |
read(org.apache.hadoop.mapreduce.TaskInputOutputContext<?,?,?,?> context)
Read the data referenced by this instance within the given context.
|
public DelegatingReadableData(ReadableData<S> delegate, DoFn<S,T> fn)
public Set<SourceTarget<?>> getSourceTargets()
getSourceTargets in interface ReadableData<T>SourceTarget instances that must exist before the data in
this instance can be read. Used by the planner in sequencing job processing.public void configure(org.apache.hadoop.conf.Configuration conf)
ReadableDataconfigure in interface ReadableData<T>conf - The Configuration object for the jobpublic Iterable<T> read(org.apache.hadoop.mapreduce.TaskInputOutputContext<?,?,?,?> context) throws IOException
ReadableDataread in interface ReadableData<T>context - The context of the task that is reading the dataIOException - If the data cannot be readCopyright © 2016 The Apache Software Foundation. All rights reserved.