@Test void buildShouldThrowOnCalendarWithoutUid() throws Exception { byte[] ics = ClassLoaderUtils.getSystemResourceAsByteArray("ics/meeting_without_uid.ics"); Calendar calendar = new CalendarBuilder().build(new ByteArrayInputStream(ics)); MailAddress recipient = MailAddressFixture.ANY_AT_JAMES; MailAddress sender = MailAddressFixture.OTHER_AT_JAMES; assertThatThrownBy(() -> ICALAttributeDTO.builder() .from(calendar, ics) .sender(sender) .recipient(recipient) .replyTo(sender)) .isInstanceOf(IllegalStateException.class); }
public static Builder builder() { return new Builder(); }
ICALAttributeDTO { public static Builder builder() { return new Builder(); } }
ICALAttributeDTO { public static Builder builder() { return new Builder(); } private  ICALAttributeDTO(String ical, String uid, String sender, String recipient, String replyTo, String dtstamp,
                             String method, Optional<String> sequence, Optional<String> recurrenceId); }
ICALAttributeDTO { public static Builder builder() { return new Builder(); } private  ICALAttributeDTO(String ical, String uid, String sender, String recipient, String replyTo, String dtstamp,
                             String method, Optional<String> sequence, Optional<String> recurrenceId); static Builder builder(); String getIcal(); String getSender(); String getRecipient(); String getReplyTo(); String getUid(); String getDtstamp(); String getMethod(); String getSequence(); @JsonProperty("recurrence-id") Optional<String> getRecurrenceId(); @Override final boolean equals(Object o); @Override final int hashCode(); }
ICALAttributeDTO { public static Builder builder() { return new Builder(); } private  ICALAttributeDTO(String ical, String uid, String sender, String recipient, String replyTo, String dtstamp,
                             String method, Optional<String> sequence, Optional<String> recurrenceId); static Builder builder(); String getIcal(); String getSender(); String getRecipient(); String getReplyTo(); String getUid(); String getDtstamp(); String getMethod(); String getSequence(); @JsonProperty("recurrence-id") Optional<String> getRecurrenceId(); @Override final boolean equals(Object o); @Override final int hashCode(); static final String DEFAULT_SEQUENCE_VALUE; }