T
- Value typepublic class MinReduce<T extends org.apache.hadoop.io.WritableComparable> extends ReduceSameTypeOperation<T>
Modifier and Type | Field and Description |
---|---|
static MinReduce<org.apache.hadoop.io.DoubleWritable> |
DOUBLE
DoubleWritable specialization
|
static MinReduce<org.apache.hadoop.io.IntWritable> |
INT
IntWritable specialization
|
static MinReduce<org.apache.hadoop.io.LongWritable> |
LONG
LongWritable specialization
|
Constructor and Description |
---|
MinReduce()
Constructor used for deserialization only
|
MinReduce(NumericTypeOps<T> typeOps)
Constructor
|
Modifier and Type | Method and Description |
---|---|
T |
createInitialValue()
Return new reduced value which is neutral to reduce operation.
|
void |
readFields(DataInput in) |
T |
reduce(T curValue,
T valueToReduce)
Add a new value.
|
void |
write(DataOutput out) |
reduceMerge
public static final MinReduce<org.apache.hadoop.io.DoubleWritable> DOUBLE
public static final MinReduce<org.apache.hadoop.io.LongWritable> LONG
public static final MinReduce<org.apache.hadoop.io.IntWritable> INT
public MinReduce()
public MinReduce(NumericTypeOps<T> typeOps)
typeOps
- Value type operationspublic T createInitialValue()
ReduceOperation
public T reduce(T curValue, T valueToReduce)
ReduceOperation
curValue
- Partial value into which to reduce and store the resultvalueToReduce
- Single value to be reducedpublic void write(DataOutput out) throws IOException
IOException
public void readFields(DataInput in) throws IOException
IOException
Copyright © 2011-2020 The Apache Software Foundation. All Rights Reserved.