com.cloudera.crunch.io.seq
Class SeqFileTableSourceTarget<K,V>
java.lang.Object
com.cloudera.crunch.io.impl.FileTargetImpl
com.cloudera.crunch.io.seq.SeqFileTarget
com.cloudera.crunch.io.seq.SeqFileTableSourceTarget<K,V>
- All Implemented Interfaces:
- MapReduceTarget, PathTarget, ReadableSource<Pair<K,V>>, ReadableSourceTarget<Pair<K,V>>, Source<Pair<K,V>>, SourceTarget<Pair<K,V>>, TableSource<K,V>, Target
public class SeqFileTableSourceTarget<K,V>
- extends SeqFileTarget
- implements TableSource<K,V>, ReadableSourceTarget<Pair<K,V>>, PathTarget
SeqFileTableSourceTarget
public SeqFileTableSourceTarget(String path,
PTableType<K,V> tableType)
SeqFileTableSourceTarget
public SeqFileTableSourceTarget(org.apache.hadoop.fs.Path path,
PTableType<K,V> tableType)
equals
public boolean equals(Object other)
- Overrides:
equals
in class FileTargetImpl
hashCode
public int hashCode()
- Overrides:
hashCode
in class FileTargetImpl
toString
public String toString()
- Overrides:
toString
in class SeqFileTarget
getPath
public org.apache.hadoop.fs.Path getPath()
- Specified by:
getPath
in interface PathTarget
- Overrides:
getPath
in class FileTargetImpl
configureSource
public void configureSource(org.apache.hadoop.mapreduce.Job job,
int inputId)
throws IOException
- Description copied from interface:
Source
- Configure the given job to use this source as an input.
- Specified by:
configureSource
in interface Source<Pair<K,V>>
- Parameters:
job
- The job to configureinputId
- For a multi-input job, an identifier for this input to the job
- Throws:
IOException
getType
public PType<Pair<K,V>> getType()
- Description copied from interface:
Source
- Returns the
PType
for this source.
- Specified by:
getType
in interface Source<Pair<K,V>>
getTableType
public PTableType<K,V> getTableType()
- Specified by:
getTableType
in interface TableSource<K,V>
getSize
public long getSize(org.apache.hadoop.conf.Configuration configuration)
- Description copied from interface:
Source
- Returns the number of bytes in this
Source
.
- Specified by:
getSize
in interface Source<Pair<K,V>>
read
public Iterable<Pair<K,V>> read(org.apache.hadoop.conf.Configuration conf)
throws IOException
- Specified by:
read
in interface ReadableSource<Pair<K,V>>
- Throws:
IOException
Copyright © 2012. All Rights Reserved.