code: public ArrayList<Entry<Text, Text>> generateKeyValPairs(Object key,
                                                            Object val) {
      ArrayList<Entry<Text, Text>> retv = new ArrayList<Entry<Text, Text>>();
      String countType = LONG_VALUE_SUM;
      String id = "record_count";
      Entry<Text, Text> e = generateEntry(countType, id, ONE);
      if (e != null) {
        retv.add(e);
      }
      if (this.inputFile != null) {
        e = generateEntry(countType, this.inputFile, ONE);
        if (e != null) {
          retv.add(e);
        }
      }
      return retv;
    }
docs: Generate 1 or 2 aggregation-id/value pairs for the given key/value pair.
  The first id will be of type LONG_VALUE_SUM, with "record_count" as
  its aggregation id. If the input is a file split,
  the second id of the same type will be generated too, with the file name
  as its aggregation id. This achieves the behavior of counting the total number
  of records in the input data, and the number of records in each input file.
  
  @param key
  input key
  @param val
  input value
  @return a list of aggregation id/value pairs. An aggregation id encodes an
  aggregation type which is used to guide the way to aggregate the
  value in the reduce/combiner phrase of an Aggregate based job.