Package org.apache.flink.util
Class Utils.ChecksumHashCode
- java.lang.Object
-
- org.apache.flink.util.Utils.ChecksumHashCode
-
- All Implemented Interfaces:
Serializable
,Cloneable
,Accumulator<Utils.ChecksumHashCode,Utils.ChecksumHashCode>
,SimpleAccumulator<Utils.ChecksumHashCode>
- Enclosing class:
- Utils
public static class Utils.ChecksumHashCode extends Object implements SimpleAccumulator<Utils.ChecksumHashCode>
Accumulator ofUtils.ChecksumHashCode
.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description ChecksumHashCode()
ChecksumHashCode(long count, long checksum)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(Utils.ChecksumHashCode value)
Utils.ChecksumHashCode
clone()
Duplicates the accumulator.boolean
equals(Object obj)
long
getChecksum()
long
getCount()
Utils.ChecksumHashCode
getLocalValue()
int
hashCode()
void
merge(Accumulator<Utils.ChecksumHashCode,Utils.ChecksumHashCode> other)
Used by system internally to merge the collected parts of an accumulator at the end of the job.void
resetLocal()
Reset the local value.String
toString()
-
-
-
Method Detail
-
getCount
public long getCount()
-
getChecksum
public long getChecksum()
-
add
public void add(Utils.ChecksumHashCode value)
- Specified by:
add
in interfaceAccumulator<Utils.ChecksumHashCode,Utils.ChecksumHashCode>
- Parameters:
value
- The value to add to the accumulator object
-
getLocalValue
public Utils.ChecksumHashCode getLocalValue()
- Specified by:
getLocalValue
in interfaceAccumulator<Utils.ChecksumHashCode,Utils.ChecksumHashCode>
- Returns:
- local The local value from the current UDF context
-
resetLocal
public void resetLocal()
Description copied from interface:Accumulator
Reset the local value. This only affects the current UDF context.- Specified by:
resetLocal
in interfaceAccumulator<Utils.ChecksumHashCode,Utils.ChecksumHashCode>
-
merge
public void merge(Accumulator<Utils.ChecksumHashCode,Utils.ChecksumHashCode> other)
Description copied from interface:Accumulator
Used by system internally to merge the collected parts of an accumulator at the end of the job.- Specified by:
merge
in interfaceAccumulator<Utils.ChecksumHashCode,Utils.ChecksumHashCode>
- Parameters:
other
- Reference to accumulator to merge in.
-
clone
public Utils.ChecksumHashCode clone()
Description copied from interface:Accumulator
Duplicates the accumulator. All subclasses need to properly implement cloning and cannot throw aCloneNotSupportedException
- Specified by:
clone
in interfaceAccumulator<Utils.ChecksumHashCode,Utils.ChecksumHashCode>
- Overrides:
clone
in classObject
- Returns:
- The duplicated accumulator.
-
-