net.nutch.mapReduce
Interface RecordReader


public interface RecordReader

Reads key/value pairs from an input file InputFormat.Split. Implemented by InputFormat implementations.


Method Summary
 Writable createKey()
          Constructs a key suitable to pass as the first parameter to next(Writable,Writable).
 Writable createValue()
          Constructs a value suitable to pass as the second parameter to next(Writable,Writable).
 boolean next(Writable key, Writable value)
          Reads the next key/value pair.
 

Method Detail

createKey

public Writable createKey()
Constructs a key suitable to pass as the first parameter to next(Writable,Writable).


createValue

public Writable createValue()
Constructs a value suitable to pass as the second parameter to next(Writable,Writable).


next

public boolean next(Writable key,
                    Writable value)
             throws IOException
Reads the next key/value pair.

Parameters:
key - the key to read data into
value - the value to read data into
Returns:
true iff a key/value was read, false if at EOF
Throws:
IOException
See Also:
Writable.readFields(DataInput)


Copyright © 2005 The Nutch Organization.