PackedLocalTime { public static int getSecondOfDay(int packedLocalTime) { if (packedLocalTime == TimeColumnType.missingValueIndicator()) { return IntColumnType.missingValueIndicator(); } int total = getHour(packedLocalTime) * 60 * 60; total += getMinute(packedLocalTime) * 60; total += getSecond(packedLocalTime); return total; }  static byte getHour(int time); static int of(int hour, int minute); static int of(int hour, int minute, int second); static int of(int hour, int minute, int second, int millis); static int truncatedTo(TemporalUnit unit, int packedTime); static int plusHours(int hoursToAdd, int packedTime); static int plusMinutes(int minutesToAdd, int packedTime); static int plusSeconds(int secondsToAdd, int packedTime); static int plusMilliseconds(int msToAdd, int packedTime); static int minusHours(int hoursToSubtract, int packedTime); static int minusMinutes(int minutesToSubtract, int packedTime); static int minusSeconds(int secondsToSubtract, int packedTime); static int minusMilliseconds(int millisToSubtract, int packedTime); static int withHour(int hour, int packedTime); static int withMinute(int minute, int packedTime); static int withSecond(int second, int packedTime); static int withMillisecond(int milliseconds, int packedTime); static char getMillisecondOfMinute(int time); static int getNano(int time); static int getMilliseconds(int time); static long toNanoOfDay(int time); static LocalTime asLocalTime(int time); static byte getMinute(int time); static int pack(LocalTime time); static byte getSecond(int packedLocalTime); static int getMinuteOfDay(int packedLocalTime); static int getSecondOfDay(int packedLocalTime); static int getMillisecondOfDay(int packedLocalTime); static String toShortTimeString(int time); static boolean isMidnight(int packedTime); static boolean isNoon(int packedTime); static boolean isAfter(int packedTime, int otherPackedTime); static boolean isOnOrAfter(int packedTime, int otherPackedTime); static boolean isBefore(int packedTime, int otherPackedTime); static boolean isOnOrBefore(int packedTime, int otherPackedTime); static boolean isEqualTo(int packedTime, int otherPackedTime); static boolean AM(int packedTime); static boolean PM(int packedTime); static int hoursUntil(int packedTimeEnd, int packedTimeStart); static int minutesUntil(int packedTimeEnd, int packedTimeStart); static int secondsUntil(int packedTimeEnd, int packedTimeStart);  }
@Test public void testGetSecondOfDay() { LocalTime now = LocalTime.now(); assertEquals(now.get(ChronoField.SECOND_OF_DAY), getSecondOfDay(pack(now)), 0.0001); }