org.apache.mahout.text
Class LuceneSegmentRecordReader
java.lang.Object
org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.Text,org.apache.hadoop.io.NullWritable>
org.apache.mahout.text.LuceneSegmentRecordReader
- All Implemented Interfaces:
- Closeable
public class LuceneSegmentRecordReader
- extends org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.Text,org.apache.hadoop.io.NullWritable>
RecordReader
implementation for Lucene segments. Each InputSplit
contains a separate Lucene segment.
Emits records consisting of a Text
document ID and a null key.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
USE_TERM_INFO
public static final int USE_TERM_INFO
- See Also:
- Constant Field Values
LuceneSegmentRecordReader
public LuceneSegmentRecordReader()
initialize
public void initialize(org.apache.hadoop.mapreduce.InputSplit split,
org.apache.hadoop.mapreduce.TaskAttemptContext context)
throws IOException,
InterruptedException
- Specified by:
initialize
in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.Text,org.apache.hadoop.io.NullWritable>
- Throws:
IOException
InterruptedException
nextKeyValue
public boolean nextKeyValue()
throws IOException,
InterruptedException
- Specified by:
nextKeyValue
in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.Text,org.apache.hadoop.io.NullWritable>
- Throws:
IOException
InterruptedException
getCurrentKey
public org.apache.hadoop.io.Text getCurrentKey()
throws IOException,
InterruptedException
- Specified by:
getCurrentKey
in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.Text,org.apache.hadoop.io.NullWritable>
- Throws:
IOException
InterruptedException
getCurrentValue
public org.apache.hadoop.io.NullWritable getCurrentValue()
throws IOException,
InterruptedException
- Specified by:
getCurrentValue
in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.Text,org.apache.hadoop.io.NullWritable>
- Throws:
IOException
InterruptedException
getProgress
public float getProgress()
throws IOException,
InterruptedException
- Specified by:
getProgress
in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.Text,org.apache.hadoop.io.NullWritable>
- Throws:
IOException
InterruptedException
close
public void close()
throws IOException
- Specified by:
close
in interface Closeable
- Specified by:
close
in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.Text,org.apache.hadoop.io.NullWritable>
- Throws:
IOException
Copyright © 2008–2014 The Apache Software Foundation. All rights reserved.