|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectp2pMapReduce.mapreduceModule.input.RecordReader<java.lang.Long,java.lang.String>
p2pMapReduce.mapreduceModule.input.LineRecordReader
public class LineRecordReader
Treats line number in the file as key and the line itself as value
Constructor Summary | |
---|---|
LineRecordReader()
|
Method Summary | |
---|---|
void |
close()
Close the record reader. |
java.lang.Long |
getCurrentKey()
Get the current key |
java.lang.String |
getCurrentValue()
Get the current value. |
float |
getProgress()
Not correctly implemented yet |
void |
initialize(InputSplit split,
TaskAttemptContext context)
Called once at initialization. |
boolean |
nextKeyValue()
Read the next key, value pair. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public LineRecordReader()
Method Detail |
---|
public void initialize(InputSplit split, TaskAttemptContext context) throws java.io.IOException, java.lang.InterruptedException
RecordReader
initialize
in class RecordReader<java.lang.Long,java.lang.String>
split
- the split that defines the range of records to readcontext
- the information about the task
java.io.IOException
java.lang.InterruptedException
public boolean nextKeyValue() throws java.io.IOException, java.lang.InterruptedException
RecordReader
nextKeyValue
in class RecordReader<java.lang.Long,java.lang.String>
java.io.IOException
java.lang.InterruptedException
public java.lang.Long getCurrentKey() throws java.io.IOException, java.lang.InterruptedException
RecordReader
getCurrentKey
in class RecordReader<java.lang.Long,java.lang.String>
java.io.IOException
java.lang.InterruptedException
public java.lang.String getCurrentValue() throws java.io.IOException, java.lang.InterruptedException
RecordReader
getCurrentValue
in class RecordReader<java.lang.Long,java.lang.String>
java.io.IOException
java.lang.InterruptedException
public float getProgress() throws java.io.IOException, java.lang.InterruptedException
getProgress
in class RecordReader<java.lang.Long,java.lang.String>
java.io.IOException
java.lang.InterruptedException
public void close() throws java.io.IOException
RecordReader
close
in interface java.io.Closeable
close
in class RecordReader<java.lang.Long,java.lang.String>
java.io.IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |