public class FloatFieldMetrics extends FieldMetrics
Parquet/ORC keeps track of most metrics in file statistics, and only NaN counter is actually tracked by writers. This wrapper ensures that metrics not being updated by those writers will not be incorrectly used, by throwing exceptions when they are accessed.
Constructor and Description |
---|
FloatFieldMetrics(int id,
long nanValueCount)
Constructor for creating a FieldMetrics with only NaN counter.
|
Modifier and Type | Method and Description |
---|---|
java.nio.ByteBuffer |
lowerBound()
Returns the lower bound value of this field.
|
long |
nullValueCount()
Returns the number of null values for this field.
|
java.nio.ByteBuffer |
upperBound()
Returns the upper bound value of this field.
|
long |
valueCount()
Returns the number of all values, including nulls, NaN and repeated, for the given field.
|
id, nanValueCount
public FloatFieldMetrics(int id, long nanValueCount)
id
- field id being tracked by the writernanValueCount
- number of NaN values, will only be non-0 for double or float field.public long valueCount()
FieldMetrics
valueCount
in class FieldMetrics
public long nullValueCount()
FieldMetrics
nullValueCount
in class FieldMetrics
public java.nio.ByteBuffer lowerBound()
FieldMetrics
lowerBound
in class FieldMetrics
public java.nio.ByteBuffer upperBound()
FieldMetrics
upperBound
in class FieldMetrics