Package io.trino.plugin.base.type
Record Class DecodedTimestamp
java.lang.Object
java.lang.Record
io.trino.plugin.base.type.DecodedTimestamp
-
Constructor Summary
ConstructorsConstructorDescriptionDecodedTimestamp(long epochSeconds, int nanosOfSecond) Creates an instance of aDecodedTimestamprecord class. -
Method Summary
Modifier and TypeMethodDescriptionlongReturns the value of theepochSecondsrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intReturns the value of thenanosOfSecondrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
DecodedTimestamp
public DecodedTimestamp(long epochSeconds, int nanosOfSecond) Creates an instance of aDecodedTimestamprecord class.- Parameters:
epochSeconds- the value for theepochSecondsrecord componentnanosOfSecond- the value for thenanosOfSecondrecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with '=='. -
epochSeconds
public long epochSeconds()Returns the value of theepochSecondsrecord component.- Returns:
- the value of the
epochSecondsrecord component
-
nanosOfSecond
public int nanosOfSecond()Returns the value of thenanosOfSecondrecord component.- Returns:
- the value of the
nanosOfSecondrecord component
-