Class CommonTimeUtil


  • public final class CommonTimeUtil
    extends Object
    Utility methods for dates and times.
    • Method Detail

      • timeToBucket

        public static long timeToBucket​(long time,
                                        CommonTimeUtil.TimeBucket bucket)
        Place a time value (a Java Long representing the number of milliseconds since the start of the Unix epoch) in a CommonTimeUtil.TimeBucket.
        Parameters:
        time - the time, in milliseconds since the start of the Unix epoch
        bucket - the time bucket to place the time value into
        Returns:
        the value of the time bucket