DbDateUtils { public static Timestamp toSqlTimestamp(Instant instant) { ArgumentChecker.notNull(instant, "instant"); OffsetDateTime utc = OffsetDateTime.ofInstant(instant, ZoneOffset.UTC); return toSqlDateTime(utc.toLocalDateTime()); } protected  DbDateUtils(); static Timestamp toSqlTimestamp(Instant instant); static Instant fromSqlTimestamp(Timestamp timestamp); static Instant fromSqlTimestampNullFarFuture(Timestamp timestamp); @SuppressWarnings("deprecation") static Timestamp toSqlDateTime(LocalDateTime dateTime); @SuppressWarnings("deprecation") static LocalDateTime fromSqlDateTime(Timestamp timestamp); static LocalDateTime fromSqlDateTimeNullFarFuture(Timestamp timestamp); @SuppressWarnings("deprecation") static Date toSqlDate(LocalDate date); static Date toSqlDateNullFarFuture(LocalDate date); static Date toSqlDateNullFarPast(LocalDate date); @SuppressWarnings("deprecation") static LocalDate fromSqlDate(Date date); static LocalDate fromSqlDateNullFarFuture(Date date); static LocalDate fromSqlDateNullFarPast(Date date); static LocalDate fromSqlDateAllowNull(Date date); @SuppressWarnings("deprecation") static Timestamp toSqlTimestamp(LocalTime time); @SuppressWarnings("deprecation") static Time toSqlTime(LocalTime time); @SuppressWarnings("deprecation") static LocalTime fromSqlTime(Time time); @SuppressWarnings("deprecation") static LocalTime fromSqlTime(Timestamp timestamp); @SuppressWarnings("deprecation")
  static final Date MAX_SQL_DATE; @SuppressWarnings("deprecation")
  static final Date MIN_SQL_DATE; @SuppressWarnings("deprecation")
  static final Timestamp MAX_SQL_TIMESTAMP; @SuppressWarnings("deprecation")
  static final Timestamp EFFECTIVE_MAX_TIMESTAMP; static final Instant MAX_INSTANT; }
@Test(expectedExceptions = IllegalArgumentException.class) public void test_toSqlTimestamp_LocalTime_null() { DbDateUtils.toSqlTimestamp((LocalTime) null); }
@Test(expectedExceptions = IllegalArgumentException.class) public void test_toSqlTimestamp_InstantProvider_null() { DbDateUtils.toSqlTimestamp((Instant) null); }