/// <exception cref="System.IO.IOException"/> public virtual void Map(LongWritable key, Text value, OutputCollector <LongWritable , Text> output, Reporter reporter) { if (!value.ToString().Equals("a")) { output.Collect(key, value); } else { mos.GetCollector("text", reporter).Collect(key, new Text("text")); mos.GetCollector("sequence", "A", reporter).Collect(key, new Text("sequence")); mos.GetCollector("sequence", "B", reporter).Collect(key, new Text("sequence")); } }
/// <exception cref="System.IO.IOException"/> public virtual void Reduce(LongWritable key, IEnumerator <Text> values, OutputCollector <LongWritable, Text> output, Reporter reporter) { while (values.HasNext()) { Text value = values.Next(); if (!value.ToString().Equals("b")) { output.Collect(key, value); } else { mos.GetCollector("text", reporter).Collect(key, new Text("text")); mos.GetCollector("sequence", "B", reporter).Collect(key, new Text("sequence")); mos.GetCollector("sequence", "C", reporter).Collect(key, new Text("sequence")); } } }
/// <exception cref="System.IO.IOException"/> public virtual void Map(LongWritable key, Text value, OutputCollector <long, string > output, Reporter reporter) { if (!value.ToString().Equals("a")) { output.Collect(key.Get(), value.ToString()); } else { mos.GetCollector("text", reporter).Collect(key, "text"); } }
/// <exception cref="System.IO.IOException"/> public virtual void Reduce(long key, IEnumerator <string> values, OutputCollector < long, string> output, Reporter reporter) { while (values.HasNext()) { string value = values.Next(); if (!value.Equals("b")) { output.Collect(key, value); } else { mos.GetCollector("text", reporter).Collect(key, "text"); } } }