@Test void testGetDateTime() { assertThat(this.callog.getDateTime(LocalDateTime.of(2018, 9, 20, 12, 00), 0), is(new DateTime(ZonedDateTime.of(2018, 9, 20, 0, 0, 0, 0, ZoneId.systemDefault()) .toInstant().toEpochMilli()))); }
public DateTime getDateTime(LocalDateTime ldt, int plusDays) { LocalDate nextDay = ldt.plusDays(plusDays).toLocalDate(); LocalDateTime endOfDay = LocalDateTime.of(nextDay, this.zero); ZonedDateTime zdt = endOfDay.atZone(ZoneId.systemDefault()); return new DateTime(zdt.toInstant().toEpochMilli()); }
CalendarLogic { public DateTime getDateTime(LocalDateTime ldt, int plusDays) { LocalDate nextDay = ldt.plusDays(plusDays).toLocalDate(); LocalDateTime endOfDay = LocalDateTime.of(nextDay, this.zero); ZonedDateTime zdt = endOfDay.atZone(ZoneId.systemDefault()); return new DateTime(zdt.toInstant().toEpochMilli()); } }
CalendarLogic { public DateTime getDateTime(LocalDateTime ldt, int plusDays) { LocalDate nextDay = ldt.plusDays(plusDays).toLocalDate(); LocalDateTime endOfDay = LocalDateTime.of(nextDay, this.zero); ZonedDateTime zdt = endOfDay.atZone(ZoneId.systemDefault()); return new DateTime(zdt.toInstant().toEpochMilli()); }  }
CalendarLogic { public DateTime getDateTime(LocalDateTime ldt, int plusDays) { LocalDate nextDay = ldt.plusDays(plusDays).toLocalDate(); LocalDateTime endOfDay = LocalDateTime.of(nextDay, this.zero); ZonedDateTime zdt = endOfDay.atZone(ZoneId.systemDefault()); return new DateTime(zdt.toInstant().toEpochMilli()); }  void setEvent(CalendarEvent calendarEvent); List<CalendarEvent> getEvents(int number); List<CalendarEvent> getEventsAt(LocalDateTime chosenDay); DateTime getDateTime(LocalDateTime ldt, int plusDays); static boolean isAllDay(Event event); LocalDateTime getLocalDateTimeStart(Event event); LocalDateTime getLocalDateTimeEnd(Event event); }
CalendarLogic { public DateTime getDateTime(LocalDateTime ldt, int plusDays) { LocalDate nextDay = ldt.plusDays(plusDays).toLocalDate(); LocalDateTime endOfDay = LocalDateTime.of(nextDay, this.zero); ZonedDateTime zdt = endOfDay.atZone(ZoneId.systemDefault()); return new DateTime(zdt.toInstant().toEpochMilli()); }  void setEvent(CalendarEvent calendarEvent); List<CalendarEvent> getEvents(int number); List<CalendarEvent> getEventsAt(LocalDateTime chosenDay); DateTime getDateTime(LocalDateTime ldt, int plusDays); static boolean isAllDay(Event event); LocalDateTime getLocalDateTimeStart(Event event); LocalDateTime getLocalDateTimeEnd(Event event);  }