/** * 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); }
/** * 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); }
/** * Copy the current immutable object by setting a value for the {@link CTicketSystemType#id() id} attribute. * An equals check used to prevent copying of the same value by returning {@code this}. * @param value A new value for id * @return A modified copy of the {@code this} object */ public final CTicketSystem withId(String value) { if (this.id.equals(value)) return this; String newValue = Objects.requireNonNull(value, "id"); return new CTicketSystem(this, newValue, this.uris); }
/** * Copy the current immutable object by setting a value for the {@link CTicketSystemType#id() id} attribute. * An equals check used to prevent copying of the same value by returning {@code this}. * @param value A new value for id * @return A modified copy of the {@code this} object */ public final CTicketSystem withId(String value) { if (this.id.equals(value)) return this; String newValue = Objects.requireNonNull(value, "id"); return new CTicketSystem(this, newValue, this.uris); }
/** * Builds a new {@link CTicketSystem CTicketSystem}. * @return An immutable instance of CTicketSystem * @throws java.lang.IllegalStateException if any required attributes are missing */ public CTicketSystem build() { if (initBits != 0) { throw new IllegalStateException(formatRequiredAttributesMessage()); } return new CTicketSystem(null, id, createUnmodifiableList(true, uris)); }
/** * Builds a new {@link CTicketSystem CTicketSystem}. * @return An immutable instance of CTicketSystem * @throws java.lang.IllegalStateException if any required attributes are missing */ public CTicketSystem build() { if (initBits != 0) { throw new IllegalStateException(formatRequiredAttributesMessage()); } return new CTicketSystem(null, id, createUnmodifiableList(true, uris)); }
/** * Copy the current immutable object with elements that replace the content of {@link CTicketSystemType#uris() uris}. * @param elements The elements to set * @return A modified copy of {@code this} object */ public final CTicketSystem withUris(URI... elements) { List<URI> newValue = createUnmodifiableList(false, createSafeList(Arrays.asList(elements), true, false)); return new CTicketSystem(this, this.id, newValue); }
/** * Copy the current immutable object with elements that replace the content of {@link CTicketSystemType#uris() uris}. * @param elements The elements to set * @return A modified copy of {@code this} object */ public final CTicketSystem withUris(URI... elements) { List<URI> newValue = createUnmodifiableList(false, createSafeList(Arrays.asList(elements), true, false)); return new CTicketSystem(this, this.id, newValue); }
/** * Copy the current immutable object with elements that replace the content of {@link CTicketSystemType#uris() uris}. * A shallow reference equality check is used to prevent copying of the same value by returning {@code this}. * @param elements An iterable of uris elements to set * @return A modified copy of {@code this} object */ public final CTicketSystem withUris(Iterable<? extends URI> elements) { if (this.uris == elements) return this; List<URI> newValue = createUnmodifiableList(false, createSafeList(elements, true, false)); return new CTicketSystem(this, this.id, newValue); }
/** * Copy the current immutable object with elements that replace the content of {@link CTicketSystemType#uris() uris}. * A shallow reference equality check is used to prevent copying of the same value by returning {@code this}. * @param elements An iterable of uris elements to set * @return A modified copy of {@code this} object */ public final CTicketSystem withUris(Iterable<? extends URI> elements) { if (this.uris == elements) return this; List<URI> newValue = createUnmodifiableList(false, createSafeList(elements, true, false)); return new CTicketSystem(this, this.id, newValue); }