@Test public void testNewDate() { Calendar calendar = Calendar.getInstance(); calendar.setTime(DateUtil.newDate(1970, Calendar.SEPTEMBER, 27)); assertEquals(27, calendar.get(Calendar.DAY_OF_MONTH)); assertEquals(Calendar.SEPTEMBER, calendar.get(Calendar.MONTH)); assertEquals(1970, calendar.get(Calendar.YEAR)); assertEquals(0, calendar.get(Calendar.HOUR)); assertEquals(0, calendar.get(Calendar.MINUTE)); assertEquals(0, calendar.get(Calendar.SECOND)); assertEquals(0, calendar.get(Calendar.MILLISECOND)); }
public static Date newDate(final int year, final int month, final int date) { return newDate(year, month, date, 0, 0, 0); }
DateUtil { public static Date newDate(final int year, final int month, final int date) { return newDate(year, month, date, 0, 0, 0); } }
DateUtil { public static Date newDate(final int year, final int month, final int date) { return newDate(year, month, date, 0, 0, 0); } private  DateUtil(); }
DateUtil { public static Date newDate(final int year, final int month, final int date) { return newDate(year, month, date, 0, 0, 0); } private  DateUtil(); static Date joinDateAndTime(final Date date, final Date time); static Date newDate(final int year, final int month, final int date); static Date newDate(final int year,
                               final int month,
                               final int date,
                               final int hourOfDay,
                               final int minute,
                               final int second); static Date stripDate(final Date date); static Date stripTime(final Date date); }
DateUtil { public static Date newDate(final int year, final int month, final int date) { return newDate(year, month, date, 0, 0, 0); } private  DateUtil(); static Date joinDateAndTime(final Date date, final Date time); static Date newDate(final int year, final int month, final int date); static Date newDate(final int year,
                               final int month,
                               final int date,
                               final int hourOfDay,
                               final int minute,
                               final int second); static Date stripDate(final Date date); static Date stripTime(final Date date);  }