I am new to Hadoop, and this is my first Hadoop program.
I am trying to create a Mapper class called WordMapper, but it throws be the below error.
The type WordMapper must implement the inherited abstract method Mapper.map(Object, Object, OutputCollector, Reporter)
public class WordMapper extends MapReduceBase implements Mapper
{
public void map(WritableComparable key, Writable values, OutputCollector output, Reporter reporter) throws IOException
{
String line=values.toString();
StringTokenizer tok=new StringTokenizer(line);
while(tok.hasMoreTokens())
{
String t=tok.nextToken();
output.collect(new Text(t), new IntWritable(1));
}
}
}
Can someone please tell me where i am going wrong and suggest to overcome the problem