Constructor and Description |
---|
FSMerger(long maxBytesInMemory,
long maxRecsInMemory,
java.lang.String dir,
java.lang.String opName,
MessageType vType) |
Modifier and Type | Method and Description |
---|---|
void |
add(byte[] data,
int length)
Add the data to the file
|
void |
clean()
Cleanup the directories
|
ResettableIterator<java.lang.Object> |
readIterator()
This method gives the values
|
void |
run()
This method saves the data to file system
|
void |
switchToReading()
Switch to reading, we cannot add after this
|
public FSMerger(long maxBytesInMemory, long maxRecsInMemory, java.lang.String dir, java.lang.String opName, MessageType vType)
public void add(byte[] data, int length)
public void switchToReading()
Shuffle
switchToReading
in interface Shuffle
public void run()
public ResettableIterator<java.lang.Object> readIterator()
readIterator
in interface Shuffle