aboutsummaryrefslogtreecommitdiff
path: root/mapreduce/Mapper.java
blob: c2da326a80f38e736b5ff02041a7bc99e3b1fa75 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
package mapreduce;

import java.util.Map;
import java.util.concurrent.RecursiveTask;

/**
 *
 * @author mph
 * @param <IN> input type
 * @param <K>  key type
 * @param <V>  accumulator type
 */
public abstract class Mapper<IN, K, V> extends RecursiveTask<Map<K, V>> {
  protected IN input;

  /**
   * @param anInput list of input items
   */
  public void setInput(IN anInput) {
    input = anInput;
  }
}