private void onEndRelease() { final CRelease r = this.release_builder.build(); this.changelog_builder.putReleases(r.version(), r); }
private void onEndTicketSystem() { final CTicketSystem ts = this.ticket_system_builder.build(); this.changelog_builder.putTicketSystems(ts.id(), ts); }
private void onEndChange() { final CChange c = this.change_builder.build(); this.release_builder.addChanges(c); }
/** * Copy the current immutable object with elements that replace the content of {@link CReleaseType#items() items}. * A shallow reference equality check is used to prevent copying of the same value by returning {@code this}. * @param elements An iterable of items elements to set * @return A modified copy of {@code this} object */ public final CRelease withItems(Iterable<? extends CItem> elements) { if (this.items == elements) return this; List<CItem> newValue = createUnmodifiableList(false, createSafeList(elements, true, false)); return new CRelease(this, this.date, newValue, this.ticketSystemID, this.version); }
/** * Copy the current immutable object by replacing the {@link CChangelogType#ticketSystems() ticketSystems} map with the specified map. * Nulls are not permitted as keys or values. * A shallow reference equality check is used to prevent copying of the same value by returning {@code this}. * @param entries The entries to be added to the ticketSystems map * @return A modified copy of {@code this} object */ public final CChangelog withTicketSystems(Map<String, ? extends URI> entries) { if (this.ticketSystems == entries) return this; Map<String, URI> newValue = createUnmodifiableMap(true, false, entries); return new CChangelog(this, this.project, this.releases, newValue); }
@Override default <A> A versionAccept(final CVersionVisitorType<A> v) throws Exception { return v.text(this); }
/** * Creates a builder for {@link CVersionText CVersionText}. * @return A new CVersionText builder */ public static CVersionText.Builder builder() { return new CVersionText.Builder(); }
/** * This instance is equal to all instances of {@code CItem} that have equal attribute values. * @return {@code true} if {@code this} is equal to {@code another} instance */ @Override public boolean equals(Object another) { if (this == another) return true; return another instanceof CItem && equalTo((CItem) another); }
/** * Construct a new immutable {@code CRelease} instance. * @param date The value for the {@code date} attribute * @param items The value for the {@code items} attribute * @param ticketSystemID The value for the {@code ticketSystemID} attribute * @param version The value for the {@code version} attribute * @return An immutable CRelease instance */ public static CRelease of(LocalDate date, List<CItem> items, String ticketSystemID, CVersionType version) { return of(date, (Iterable<? extends CItem>) items, ticketSystemID, version); }
/** * Construct a new immutable {@code CRelease} instance. * @param date The value for the {@code date} attribute * @param items The value for the {@code items} attribute * @param ticketSystemID The value for the {@code ticketSystemID} attribute * @param version The value for the {@code version} attribute * @return An immutable CRelease instance */ public static CRelease of(LocalDate date, Iterable<? extends CItem> items, String ticketSystemID, CVersionType version) { return new CRelease(date, items, ticketSystemID, version); }
/** * Construct a new immutable {@code CChangelog} instance. * @param project The value for the {@code project} attribute * @param releases The value for the {@code releases} attribute * @param ticketSystems The value for the {@code ticketSystems} attribute * @return An immutable CChangelog instance */ public static CChangelog of(String project, List<CRelease> releases, Map<String, URI> ticketSystems) { return of(project, (Iterable<? extends CRelease>) releases, ticketSystems); }
/** * Construct a new immutable {@code CVersionText} instance. * @param text The value for the {@code text} attribute * @return An immutable CVersionText instance */ public static CVersionText of(String text) { return new CVersionText(text); }
/** * This instance is equal to all instances of {@code CTicketSystem} that have equal attribute values. * @return {@code true} if {@code this} is equal to {@code another} instance */ @Override public boolean equals(Object another) { if (this == another) return true; return another instanceof CTicketSystem && equalTo((CTicketSystem) another); }
/** * Construct a new immutable {@code CTicketSystem} instance. * @param id The value for the {@code id} attribute * @param uris The value for the {@code uris} attribute * @return An immutable CTicketSystem instance */ public static CTicketSystem of(String id, Iterable<? extends URI> uris) { return new CTicketSystem(id, uris); }
/** * Creates a builder for {@link CTicketSystem CTicketSystem}. * @return A new CTicketSystem builder */ public static CTicketSystem.Builder builder() { return new CTicketSystem.Builder(); }
@Override default String toVersionString() { return this.text(); }
/** * This instance is equal to all instances of {@code CRelease} that have equal attribute values. * @return {@code true} if {@code this} is equal to {@code another} instance */ @Override public boolean equals(Object another) { if (this == another) return true; return another instanceof CRelease && equalTo((CRelease) another); }
/** * Construct a new immutable {@code CItem} instance. * @param date The value for the {@code date} attribute * @param summary The value for the {@code summary} attribute * @param tickets The value for the {@code tickets} attribute * @param type The value for the {@code type} attribute * @return An immutable CItem instance */ public static CItem of(LocalDate date, String summary, Iterable<String> tickets, CChangeType type) { return new CItem(date, summary, tickets, type); }
/** * Copy the current immutable object with elements that replace the content of {@link CReleaseType#items() items}. * A shallow reference equality check is used to prevent copying of the same value by returning {@code this}. * @param elements An iterable of items elements to set * @return A modified copy of {@code this} object */ public final CRelease withItems(Iterable<? extends CItem> elements) { if (this.items == elements) return this; List<CItem> newValue = createUnmodifiableList(false, createSafeList(elements, true, false)); return new CRelease(this, this.date, newValue, this.ticketSystemID, this.version); }
@Override default <A> A versionAccept(final CVersionVisitorType<A> v) throws Exception { return v.text(this); }