org.apache.mahout.classifier.bayes
Class MultipleTextOutputFormat<K,V>

java.lang.Object
  extended by org.apache.hadoop.mapreduce.OutputFormat<K,V>
      extended by org.apache.hadoop.mapreduce.lib.output.FileOutputFormat<K,V>
          extended by org.apache.mahout.classifier.bayes.MultipleOutputFormat<K,V>
              extended by org.apache.mahout.classifier.bayes.MultipleTextOutputFormat<K,V>

public class MultipleTextOutputFormat<K,V>
extends MultipleOutputFormat<K,V>

This class extends the MultipleOutputFormat, allowing to write the output data to different output files in Text output format.


Constructor Summary
MultipleTextOutputFormat()
           
 
Method Summary
protected  org.apache.hadoop.mapreduce.RecordWriter<K,V> getBaseRecordWriter(org.apache.hadoop.fs.FileSystem fs, org.apache.hadoop.conf.Configuration conf, java.lang.String name, org.apache.hadoop.util.Progressable arg3)
           
 org.apache.hadoop.mapreduce.RecordWriter<K,V> getRecordWriter(org.apache.hadoop.mapreduce.TaskAttemptContext job)
           
 
Methods inherited from class org.apache.mahout.classifier.bayes.MultipleOutputFormat
generateActualKey, generateActualValue, generateFileNameForKeyValue, generateLeafFileName, getInputFileBasedOutputFileName, getRecordWriter
 
Methods inherited from class org.apache.hadoop.mapreduce.lib.output.FileOutputFormat
checkOutputSpecs, getCompressOutput, getDefaultWorkFile, getOutputCommitter, getOutputCompressorClass, getOutputPath, getPathForWorkFile, getUniqueFile, getWorkOutputPath, setCompressOutput, setOutputCompressorClass, setOutputPath
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MultipleTextOutputFormat

public MultipleTextOutputFormat()
Method Detail

getBaseRecordWriter

protected org.apache.hadoop.mapreduce.RecordWriter<K,V> getBaseRecordWriter(org.apache.hadoop.fs.FileSystem fs,
                                                                            org.apache.hadoop.conf.Configuration conf,
                                                                            java.lang.String name,
                                                                            org.apache.hadoop.util.Progressable arg3)
                                                                     throws java.io.IOException
Specified by:
getBaseRecordWriter in class MultipleOutputFormat<K,V>
Parameters:
fs - the file system to use
conf - a job conf object
name - the name of the file over which a record writer object will be constructed
arg3 - a progressable object
Returns:
A RecordWriter object over the given file
Throws:
java.io.IOException

getRecordWriter

public org.apache.hadoop.mapreduce.RecordWriter<K,V> getRecordWriter(org.apache.hadoop.mapreduce.TaskAttemptContext job)
                                                              throws java.io.IOException,
                                                                     java.lang.InterruptedException
Specified by:
getRecordWriter in class org.apache.hadoop.mapreduce.lib.output.FileOutputFormat<K,V>
Throws:
java.io.IOException
java.lang.InterruptedException


Copyright © 2008-2010 The Apache Software Foundation. All Rights Reserved.