public static CalendarEntryBean createCalendarEntryBeanToCreateEntry(
      AcademicCalendarRootEntry rootEntry,
      AcademicCalendarEntry parentEntry,
      Partial begin,
      Partial end) {

    CalendarEntryBean bean = new CalendarEntryBean();
    bean.setRootEntry(rootEntry);
    bean.setEntry(parentEntry);
    bean.setBeginDateToDisplay(begin);
    bean.setEndDateToDisplay(end);
    return bean;
  }
  public static CalendarEntryBean createCalendarEntryBeanToEditEntry(
      AcademicCalendarRootEntry rootEntry,
      AcademicCalendarEntry entry,
      Partial begin,
      Partial end) {

    CalendarEntryBean bean = new CalendarEntryBean();

    bean.setRootEntry(rootEntry);
    bean.setEntry(entry);
    bean.setBeginDateToDisplay(begin);
    bean.setEndDateToDisplay(end);

    bean.setTemplateEntry(entry.getTemplateEntry());
    bean.setType(entry.getClass());
    bean.setTitle(entry.getTitle());
    bean.setDescription(entry.getDescription());
    bean.setBegin(entry.getBegin());
    bean.setEnd(entry.getEnd());

    return bean;
  }