org.apache.hadoop.tools.rumen
Class DefaultOutputter<T>
java.lang.Object
org.apache.hadoop.tools.rumen.DefaultOutputter<T>
- All Implemented Interfaces:
- Closeable, Outputter<T>
public class DefaultOutputter<T>
- extends Object
- implements Outputter<T>
The default Outputter
that outputs to a plain file. Compression
will be applied if the path has the right suffix.
Method Summary |
void |
close()
|
void |
init(org.apache.hadoop.fs.Path path,
org.apache.hadoop.conf.Configuration conf)
Initialize the Outputter to a specific path. |
void |
output(T object)
Output an object. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DefaultOutputter
public DefaultOutputter()
init
public void init(org.apache.hadoop.fs.Path path,
org.apache.hadoop.conf.Configuration conf)
throws IOException
- Description copied from interface:
Outputter
- Initialize the
Outputter
to a specific path.
- Specified by:
init
in interface Outputter<T>
- Parameters:
path
- The Path
to the output file.conf
- Configuration
- Throws:
IOException
output
public void output(T object)
throws IOException
- Description copied from interface:
Outputter
- Output an object.
- Specified by:
output
in interface Outputter<T>
- Parameters:
object
- The objecte.
- Throws:
IOException
close
public void close()
throws IOException
- Specified by:
close
in interface Closeable
- Throws:
IOException
Copyright © 2009 The Apache Software Foundation