JbpmBusinessCalendar implements BusinessCalendar { @Override public Date apply(Date date, String duration) { return add(date, new JbpmDuration(duration)); } JbpmBusinessCalendar(); Date add(Date date, JbpmDuration duration); Date findStartOfNextDay(Date date); Date findEndOfPrevDay(Date date); JbpmDay findDay(Date date); @Override boolean isHoliday(Calendar calendar); static Calendar getCalendar(); @Override Date apply(Date date, String duration); @Override Date apply(Date date, BusinessDuration duration);  }
@Test(dataProvider = "getDurations") public void testBusinessTime(String durationString) { Date date = new Date(); Date date2 = bc.apply(date, durationString); System.out.println(durationString + ": " + CalendarUtil.formatDateTime(date) + " -> " + CalendarUtil.formatDateTime(date2)); }
@Test public void testBusinessTime2() { Date date = new Date(); Date date2 = bc.apply(date, "1 business months"); System.out.println(CalendarUtil.formatDateTime(date) + " -> " + CalendarUtil.formatDateTime(date2)); }