p2pMapReduce.mapreduceModule.output
Class TextFileOutputFormat<K,V>
java.lang.Object
p2pMapReduce.mapreduceModule.output.OutputFormat<K,V>
p2pMapReduce.mapreduceModule.output.TextFileOutputFormat<K,V>
public class TextFileOutputFormat<K,V>
- extends OutputFormat<K,V>
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
OUTPUT_PATH
public static final java.lang.String OUTPUT_PATH
- See Also:
- Constant Field Values
TextFileOutputFormat
public TextFileOutputFormat()
addOutputPath
public static void addOutputPath(Job job,
java.lang.String string)
checkOutputSpecs
public void checkOutputSpecs(JobContext context)
throws java.io.IOException,
java.lang.InterruptedException
- Description copied from class:
OutputFormat
- Check for validity of the output-specification for the job.
This is to validate the output specification for the job when it is
a job is submitted. Typically checks that it does not already exist,
throwing an exception when it already exists, so that output is not
overwritten.
- Specified by:
checkOutputSpecs
in class OutputFormat<K,V>
- Parameters:
context
- information about the job
- Throws:
java.io.IOException
- when output should not be attempted
java.lang.InterruptedException
getRecordWriter
public RecordWriter<K,V> getRecordWriter(TaskAttemptContext context)
throws java.io.IOException,
java.lang.InterruptedException
- Description copied from class:
OutputFormat
- Get the
RecordWriter
for the given task.
- Specified by:
getRecordWriter
in class OutputFormat<K,V>
- Parameters:
context
- the information about the current task.
- Returns:
- a
RecordWriter
to write the output for the job.
- Throws:
java.io.IOException
java.lang.InterruptedException
getOutputCommitter
public OutputCommitter getOutputCommitter(TaskAttemptContext context)
throws java.io.IOException,
java.lang.InterruptedException
- Description copied from class:
OutputFormat
- Get the output committer for this output format. This is responsible
for ensuring the output is committed correctly.
- Specified by:
getOutputCommitter
in class OutputFormat<K,V>
- Parameters:
context
- the task context
- Returns:
- an output committer
- Throws:
java.io.IOException
java.lang.InterruptedException