|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.hadoop.io.SequenceFile.Sorter
Sorts key/value pairs in a sequence-format file.
For best performance, applications should make sure that the Writable.readFields(DataInput)
implementation of their keys is
very efficient. In particular, it should avoid allocating memory.
Constructor Summary | |
SequenceFile.Sorter(FileSystem fs,
Class keyClass,
Class valClass,
Configuration conf)
Sort and merge files containing the named classes. |
|
SequenceFile.Sorter(FileSystem fs,
WritableComparator comparator,
Class valClass,
Configuration conf)
Sort and merge using an arbitrary WritableComparator . |
Method Summary | |
int |
getFactor()
Get the number of streams to merge at once. |
int |
getMemory()
Get the total amount of buffer memory, in bytes. |
void |
merge(Path[] inFiles,
Path outFile)
Merge the provided files. |
void |
setFactor(int factor)
Set the number of streams to merge at once. |
void |
setMemory(int memory)
Set the total amount of buffer memory, in bytes. |
void |
sort(Path inFile,
Path outFile)
Perform a file sort. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public SequenceFile.Sorter(FileSystem fs, Class keyClass, Class valClass, Configuration conf)
public SequenceFile.Sorter(FileSystem fs, WritableComparator comparator, Class valClass, Configuration conf)
WritableComparator
.
Method Detail |
public void setFactor(int factor)
public int getFactor()
public void setMemory(int memory)
public int getMemory()
public void sort(Path inFile, Path outFile) throws IOException
IOException
public void merge(Path[] inFiles, Path outFile) throws IOException
IOException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |