Class TemporalType<T>

    • Method Detail

      • now

        public java.nio.ByteBuffer now()
        Returns the current temporal value.
        Returns:
        the current temporal value.
      • toTimeInMillis

        public long toTimeInMillis​(java.nio.ByteBuffer value)
        Converts this temporal in UNIX timestamp.
        Parameters:
        value - the temporal value.
        Returns:
        the UNIX timestamp corresponding to this temporal.
      • fromTimeInMillis

        public java.nio.ByteBuffer fromTimeInMillis​(long timeInMillis)
        Returns the temporal value corresponding to the specified UNIX timestamp.
        Parameters:
        timeInMillis - the UNIX timestamp to convert
        Returns:
        the temporal value corresponding to the specified UNIX timestamp
      • addDuration

        public java.nio.ByteBuffer addDuration​(java.nio.ByteBuffer temporal,
                                               java.nio.ByteBuffer duration)
        Adds the duration to the specified value.
        Parameters:
        temporal - the value to add to
        duration - the duration to add
        Returns:
        the addition result
      • substractDuration

        public java.nio.ByteBuffer substractDuration​(java.nio.ByteBuffer temporal,
                                                     java.nio.ByteBuffer duration)
        Substract the duration from the specified value.
        Parameters:
        temporal - the value to substract from
        duration - the duration to substract
        Returns:
        the substracion result
      • validateDuration

        protected void validateDuration​(Duration duration)
        Validates that the duration has the correct precision.
        Parameters:
        duration - the duration to validate.