|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.nutch.mapReduce.InputFormatBase
A base class for InputFormat
.
Constructor Summary | |
InputFormatBase()
|
Method Summary | |
abstract String |
getName()
The name of this input format. |
abstract RecordReader |
getRecordReader(NutchFileSystem fs,
FileSplit split,
JobConf job)
Construct a RecordReader for a FileSplit . |
FileSplit[] |
getSplits(NutchFileSystem fs,
JobConf job,
int numSplits)
Splits files returned by {#listFiles(NutchFileSystem,JobConf) when they're too big. |
protected File[] |
listFiles(NutchFileSystem fs,
JobConf job)
Subclasses may override to, e.g., select only files matching a regular expression. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public InputFormatBase()
Method Detail |
public abstract String getName()
InputFormat
getName
in interface InputFormat
InputFormats
public abstract RecordReader getRecordReader(NutchFileSystem fs, FileSplit split, JobConf job) throws IOException
InputFormat
RecordReader
for a FileSplit
.
getRecordReader
in interface InputFormat
fs
- the NutchFileSystem
split
- the FileSplit
job
- the job that this split belongs to
RecordReader
IOException
protected File[] listFiles(NutchFileSystem fs, JobConf job) throws IOException
IOException
public FileSplit[] getSplits(NutchFileSystem fs, JobConf job, int numSplits) throws IOException
getSplits
in interface InputFormat
fs
- the filesystem containing the files to be splitjob
- the job whose input files are to be splitnumSplits
- the desired number of splits
IOException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |