ValueAggregatorMapper (Apache Hadoop Main 3.5.0 API)
Description: declaration: package: org.apache.hadoop.mapred.lib.aggregate, class: ValueAggregatorMapper

Package org.apache.hadoop.mapred.lib.aggregate

# Class ValueAggregatorMapper<K1 extends WritableComparable,V1 extends Writable>

java.lang.Object
org.apache.hadoop.mapred.lib.aggregate.ValueAggregatorJobBase<K1,V1>
org.apache.hadoop.mapred.lib.aggregate.ValueAggregatorMapper<K1,V1>

All Implemented Interfaces:
  `Closeable`, `AutoCloseable`, `Closeable`, `JobConfigurable`, `Mapper<K1,V1,Text,Text>`, `Reducer<Text,Text,Text,Text>`

@Public @Stable public class ValueAggregatorMapper<K1 extends WritableComparable,V1 extends Writable> extends ValueAggregatorJobBase<K1,V1>
This class implements the generic mapper of Aggregate.

- ## Field Summary

  ### Fields inherited from class org.apache.hadoop.mapred.lib.aggregate.ValueAggregatorJobBase

  `aggregatorDescriptorList`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `ValueAggregatorMapper()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `map(K1 key, V1 value, OutputCollector<Text,Text> output, Reporter reporter)`
  the map function.
  `void`
  `reduce(Text arg0, Iterator<Text> arg1, OutputCollector<Text,Text> arg2, Reporter arg3)`
  Do nothing.

  ### Methods inherited from class org.apache.hadoop.mapred.lib.aggregate.ValueAggregatorJobBase

  `close, configure, logSpec`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### ValueAggregatorMapper

    public ValueAggregatorMapper()

- ## Method Details

  - ### map

    public void map(K1 key, V1 value, OutputCollector<Text,Text> output, Reporter reporter) throws IOException
    the map function. It iterates through the value aggregator descriptor list to generate aggregation id/value pairs and emit them.
    Parameters:
      `key` - the input key.
      `value` - the input value.
      `output` - collects mapped keys and values.
      `reporter` - facility to report progress.
    Throws:
      `IOException`

  - ### reduce

    public void reduce(Text arg0, Iterator<Text> arg1, OutputCollector<Text,Text> arg2, Reporter arg3) throws IOException
    Do nothing. Should not be called.
    Parameters:
      `arg0` - the key.
      `arg1` - the list of values to reduce.
      `arg2` - to collect keys and combined values.
      `arg3` - facility to report progress.
    Throws:
      `IOException`