org.apache.nutch.indexer.field
Class CustomFields.Collector

java.lang.Object
  extended by org.apache.hadoop.conf.Configured
      extended by org.apache.nutch.indexer.field.CustomFields.Collector
All Implemented Interfaces:
Closeable, Configurable, JobConfigurable, Mapper<Text,Writable,Text,ObjectWritable>, Reducer<Text,ObjectWritable,Text,FieldWritable>
Enclosing class:
CustomFields

public static class CustomFields.Collector
extends Configured
implements Mapper<Text,Writable,Text,ObjectWritable>, Reducer<Text,ObjectWritable,Text,FieldWritable>

Aggregates FieldWritable objects by the same name for the same URL. These objects are them filtered for multiple values against configuration settings.


Constructor Summary
CustomFields.Collector()
           
 
Method Summary
 void close()
           
 void configure(JobConf conf)
           
 void map(Text key, Writable value, OutputCollector<Text,ObjectWritable> output, Reporter reporter)
           
 void reduce(Text key, Iterator<ObjectWritable> values, OutputCollector<Text,FieldWritable> output, Reporter reporter)
           
 
Methods inherited from class org.apache.hadoop.conf.Configured
getConf, setConf
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CustomFields.Collector

public CustomFields.Collector()
Method Detail

configure

public void configure(JobConf conf)
Specified by:
configure in interface JobConfigurable

close

public void close()
Specified by:
close in interface Closeable

map

public void map(Text key,
                Writable value,
                OutputCollector<Text,ObjectWritable> output,
                Reporter reporter)
         throws IOException
Specified by:
map in interface Mapper<Text,Writable,Text,ObjectWritable>
Throws:
IOException

reduce

public void reduce(Text key,
                   Iterator<ObjectWritable> values,
                   OutputCollector<Text,FieldWritable> output,
                   Reporter reporter)
            throws IOException
Specified by:
reduce in interface Reducer<Text,ObjectWritable,Text,FieldWritable>
Throws:
IOException


Copyright © 2006 The Apache Software Foundation