Package org.apache.orc.impl
Class ColumnStatisticsImpl
java.lang.Object
org.apache.orc.impl.ColumnStatisticsImpl
- All Implemented Interfaces:
ColumnStatistics
- Direct Known Subclasses:
ColumnStatisticsImpl.BinaryStatisticsImpl,ColumnStatisticsImpl.StringStatisticsImpl
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static final classprotected static final class -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic ColumnStatisticsImplcreate(TypeDescription schema) static ColumnStatisticsImplcreate(TypeDescription schema, boolean convertToProleptic) static ColumnStatisticsImpldeserialize(TypeDescription schema, OrcProto.ColumnStatistics stats) static ColumnStatisticsImpldeserialize(TypeDescription schema, OrcProto.ColumnStatistics stats, boolean writerUsedProlepticGregorian, boolean convertToProlepticGregorian) booleanlongGet the number of bytes for this column.longGet the number of values in this column.inthashCode()booleanhasNull()Returns true if there are nulls in the scope of column statistics.voidvoidincrement(int count) booleanvoidmerge(ColumnStatisticsImpl stats) voidreset()voidsetNull()toString()voidupdateBinary(byte[] bytes, int offset, int length, int repetitions) voidupdateBinary(BytesWritable value) voidupdateBoolean(boolean value, int repetitions) voidupdateByteCount(long size) voidupdateCollectionLength(long value) Update the collection length for Map and List type.voidupdateDate(int value) voidupdateDate(org.apache.hadoop.hive.serde2.io.DateWritable value) voidupdateDecimal(org.apache.hadoop.hive.serde2.io.HiveDecimalWritable value) voidupdateDecimal64(long value, int scale) voidupdateDouble(double value) voidupdateGeometry(byte[] bytes, int offset, int length) voidupdateGeometry(BytesWritable value) voidupdateInteger(long value, int repetitions) voidupdateString(byte[] bytes, int offset, int length, int repetitions) voidupdateString(Text value) voidupdateTimestamp(long value, int nanos) voidupdateTimestamp(Timestamp value)
-
Field Details
-
count
protected long count
-
-
Method Details
-
equals
-
hashCode
public int hashCode() -
increment
public void increment() -
increment
public void increment(int count) -
updateByteCount
public void updateByteCount(long size) -
setNull
public void setNull() -
updateCollectionLength
public void updateCollectionLength(long value) Update the collection length for Map and List type.- Parameters:
value- length of collection
-
updateBoolean
public void updateBoolean(boolean value, int repetitions) -
updateInteger
public void updateInteger(long value, int repetitions) -
updateDouble
public void updateDouble(double value) -
updateString
-
updateString
public void updateString(byte[] bytes, int offset, int length, int repetitions) -
updateBinary
-
updateBinary
public void updateBinary(byte[] bytes, int offset, int length, int repetitions) -
updateDecimal
public void updateDecimal(org.apache.hadoop.hive.serde2.io.HiveDecimalWritable value) -
updateDecimal64
public void updateDecimal64(long value, int scale) -
updateDate
public void updateDate(org.apache.hadoop.hive.serde2.io.DateWritable value) -
updateDate
public void updateDate(int value) -
updateTimestamp
-
updateTimestamp
public void updateTimestamp(long value, int nanos) -
updateGeometry
-
updateGeometry
public void updateGeometry(byte[] bytes, int offset, int length) -
isStatsExists
public boolean isStatsExists() -
merge
-
reset
public void reset() -
getNumberOfValues
public long getNumberOfValues()Description copied from interface:ColumnStatisticsGet the number of values in this column. It will differ from the number of rows because of NULL values and repeated values.- Specified by:
getNumberOfValuesin interfaceColumnStatistics- Returns:
- the number of values
-
hasNull
public boolean hasNull()Description copied from interface:ColumnStatisticsReturns true if there are nulls in the scope of column statistics.- Specified by:
hasNullin interfaceColumnStatistics- Returns:
- true if null present else false
-
getBytesOnDisk
public long getBytesOnDisk()Get the number of bytes for this column.- Specified by:
getBytesOnDiskin interfaceColumnStatistics- Returns:
- the number of bytes
-
toString
-
serialize
-
create
-
create
-
deserialize
public static ColumnStatisticsImpl deserialize(TypeDescription schema, OrcProto.ColumnStatistics stats) -
deserialize
public static ColumnStatisticsImpl deserialize(TypeDescription schema, OrcProto.ColumnStatistics stats, boolean writerUsedProlepticGregorian, boolean convertToProlepticGregorian)
-