@Test public void testParseMonth() throws Exception { Date result = DateUtils.parseDate(DateIntervalType.MONTH, GroupStrategy.DYNAMIC, "2015-1"); assertThat(df.format(result)).isEqualTo("2015-01-01 00:00:00"); }
public static Date parseDate(DataColumn dateColumn, Object date) throws Exception { DateIntervalType type = DateIntervalType.getByName(dateColumn.getIntervalType()); GroupStrategy strategy = dateColumn.getColumnGroup().getStrategy(); return parseDate(type, strategy, date); }
DateUtils { public static Date parseDate(DataColumn dateColumn, Object date) throws Exception { DateIntervalType type = DateIntervalType.getByName(dateColumn.getIntervalType()); GroupStrategy strategy = dateColumn.getColumnGroup().getStrategy(); return parseDate(type, strategy, date); } }
DateUtils { public static Date parseDate(DataColumn dateColumn, Object date) throws Exception { DateIntervalType type = DateIntervalType.getByName(dateColumn.getIntervalType()); GroupStrategy strategy = dateColumn.getColumnGroup().getStrategy(); return parseDate(type, strategy, date); }  }
DateUtils { public static Date parseDate(DataColumn dateColumn, Object date) throws Exception { DateIntervalType type = DateIntervalType.getByName(dateColumn.getIntervalType()); GroupStrategy strategy = dateColumn.getColumnGroup().getStrategy(); return parseDate(type, strategy, date); }  static Date parseDate(DataColumn dateColumn, Object date); static Date parseDate(DateIntervalType type, GroupStrategy strategy, Object date); static String ensureTwoDigits(String date, DateIntervalType intervalType); static String ensureTwoDigits(String date, String symbolStart, String symbolEnd); }
DateUtils { public static Date parseDate(DataColumn dateColumn, Object date) throws Exception { DateIntervalType type = DateIntervalType.getByName(dateColumn.getIntervalType()); GroupStrategy strategy = dateColumn.getColumnGroup().getStrategy(); return parseDate(type, strategy, date); }  static Date parseDate(DataColumn dateColumn, Object date); static Date parseDate(DateIntervalType type, GroupStrategy strategy, Object date); static String ensureTwoDigits(String date, DateIntervalType intervalType); static String ensureTwoDigits(String date, String symbolStart, String symbolEnd); static final SimpleDateFormat FORMATTER_YEAR; static final SimpleDateFormat FORMATTER_MONTH; static final SimpleDateFormat FORMATTER_DAY; static final SimpleDateFormat FORMATTER_HOUR; static final SimpleDateFormat FORMATTER_MINUTE; static final SimpleDateFormat FORMATTER_SECOND; }