- All Implemented Interfaces:
- java.io.Closeable, java.lang.AutoCloseable, org.apache.hadoop.mapred.JobConfigurable, org.apache.hadoop.mapred.Mapper<org.apache.hadoop.io.LongWritable,org.apache.hadoop.io.Text,InvertedIndex.InvertedIndexKey,InvertedIndex.InvertedIndexValue>
- Enclosing class:
- InvertedIndexMapred
public static class InvertedIndexMapred.InvertedIndexMapper
extends org.apache.hadoop.mapred.MapReduceBase
implements org.apache.hadoop.mapred.Mapper<org.apache.hadoop.io.LongWritable,org.apache.hadoop.io.Text,InvertedIndex.InvertedIndexKey,InvertedIndex.InvertedIndexValue>
Inverted Index mapper class for TextInputFormat
and FileSplit
This class uses the file name obtained from FileSplit
as the location of the word, and the value of the LongWritable key of TextInputFormat
as the offset of the word in that file.