All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.thestencil.iam.spi.integrations.ImmutableProcessesInit Maven / Gradle / Ivy

There is a newer version: 1.148.40
Show newest version
package io.thestencil.iam.spi.integrations;

import com.google.common.base.MoreObjects;
import com.google.errorprone.annotations.CanIgnoreReturnValue;
import com.google.errorprone.annotations.Var;
import java.util.ArrayList;
import java.util.List;
import java.util.Objects;
import javax.annotation.CheckReturnValue;
import javax.annotation.Nullable;
import javax.annotation.ParametersAreNonnullByDefault;
import javax.annotation.concurrent.Immutable;
import javax.annotation.concurrent.NotThreadSafe;
import org.immutables.value.Generated;

/**
 * Immutable implementation of {@link UserActionBuilderDefault.ProcessesInit}.
 * 

* Use the builder to create immutable instances: * {@code ImmutableProcessesInit.builder()}. */ @Generated(from = "UserActionBuilderDefault.ProcessesInit", generator = "Immutables") @SuppressWarnings({"all"}) @ParametersAreNonnullByDefault @javax.annotation.processing.Generated("org.immutables.processor.ProxyProcessor") @Immutable @CheckReturnValue public final class ImmutableProcessesInit implements UserActionBuilderDefault.ProcessesInit { private final String identity; private final String workflowName; private final Boolean protectionOrder; private final @Nullable String inputContextId; private final @Nullable String inputParentContextId; private final @Nullable String lastName; private final @Nullable String firstName; private final @Nullable String companyName; private final @Nullable String email; private final @Nullable String address; private final @Nullable String language; private final @Nullable String representativeFirstName; private final @Nullable String representativeLastName; private final @Nullable String representativeIdentity; private ImmutableProcessesInit( String identity, String workflowName, Boolean protectionOrder, @Nullable String inputContextId, @Nullable String inputParentContextId, @Nullable String lastName, @Nullable String firstName, @Nullable String companyName, @Nullable String email, @Nullable String address, @Nullable String language, @Nullable String representativeFirstName, @Nullable String representativeLastName, @Nullable String representativeIdentity) { this.identity = identity; this.workflowName = workflowName; this.protectionOrder = protectionOrder; this.inputContextId = inputContextId; this.inputParentContextId = inputParentContextId; this.lastName = lastName; this.firstName = firstName; this.companyName = companyName; this.email = email; this.address = address; this.language = language; this.representativeFirstName = representativeFirstName; this.representativeLastName = representativeLastName; this.representativeIdentity = representativeIdentity; } /** * @return The value of the {@code identity} attribute */ @Override public String getIdentity() { return identity; } /** * @return The value of the {@code workflowName} attribute */ @Override public String getWorkflowName() { return workflowName; } /** * @return The value of the {@code protectionOrder} attribute */ @Override public Boolean getProtectionOrder() { return protectionOrder; } /** * @return The value of the {@code inputContextId} attribute */ @Override public @Nullable String getInputContextId() { return inputContextId; } /** * @return The value of the {@code inputParentContextId} attribute */ @Override public @Nullable String getInputParentContextId() { return inputParentContextId; } /** * @return The value of the {@code lastName} attribute */ @Override public @Nullable String getLastName() { return lastName; } /** * @return The value of the {@code firstName} attribute */ @Override public @Nullable String getFirstName() { return firstName; } /** * @return The value of the {@code companyName} attribute */ @Override public @Nullable String getCompanyName() { return companyName; } /** * @return The value of the {@code email} attribute */ @Override public @Nullable String getEmail() { return email; } /** * @return The value of the {@code address} attribute */ @Override public @Nullable String getAddress() { return address; } /** * @return The value of the {@code language} attribute */ @Override public @Nullable String getLanguage() { return language; } /** * @return The value of the {@code representativeFirstName} attribute */ @Override public @Nullable String getRepresentativeFirstName() { return representativeFirstName; } /** * @return The value of the {@code representativeLastName} attribute */ @Override public @Nullable String getRepresentativeLastName() { return representativeLastName; } /** * @return The value of the {@code representativeIdentity} attribute */ @Override public @Nullable String getRepresentativeIdentity() { return representativeIdentity; } /** * Copy the current immutable object by setting a value for the {@link UserActionBuilderDefault.ProcessesInit#getIdentity() identity} attribute. * An equals check used to prevent copying of the same value by returning {@code this}. * @param value A new value for identity * @return A modified copy of the {@code this} object */ public final ImmutableProcessesInit withIdentity(String value) { String newValue = Objects.requireNonNull(value, "identity"); if (this.identity.equals(newValue)) return this; return new ImmutableProcessesInit( newValue, this.workflowName, this.protectionOrder, this.inputContextId, this.inputParentContextId, this.lastName, this.firstName, this.companyName, this.email, this.address, this.language, this.representativeFirstName, this.representativeLastName, this.representativeIdentity); } /** * Copy the current immutable object by setting a value for the {@link UserActionBuilderDefault.ProcessesInit#getWorkflowName() workflowName} attribute. * An equals check used to prevent copying of the same value by returning {@code this}. * @param value A new value for workflowName * @return A modified copy of the {@code this} object */ public final ImmutableProcessesInit withWorkflowName(String value) { String newValue = Objects.requireNonNull(value, "workflowName"); if (this.workflowName.equals(newValue)) return this; return new ImmutableProcessesInit( this.identity, newValue, this.protectionOrder, this.inputContextId, this.inputParentContextId, this.lastName, this.firstName, this.companyName, this.email, this.address, this.language, this.representativeFirstName, this.representativeLastName, this.representativeIdentity); } /** * Copy the current immutable object by setting a value for the {@link UserActionBuilderDefault.ProcessesInit#getProtectionOrder() protectionOrder} attribute. * An equals check used to prevent copying of the same value by returning {@code this}. * @param value A new value for protectionOrder * @return A modified copy of the {@code this} object */ public final ImmutableProcessesInit withProtectionOrder(Boolean value) { Boolean newValue = Objects.requireNonNull(value, "protectionOrder"); if (this.protectionOrder.equals(newValue)) return this; return new ImmutableProcessesInit( this.identity, this.workflowName, newValue, this.inputContextId, this.inputParentContextId, this.lastName, this.firstName, this.companyName, this.email, this.address, this.language, this.representativeFirstName, this.representativeLastName, this.representativeIdentity); } /** * Copy the current immutable object by setting a value for the {@link UserActionBuilderDefault.ProcessesInit#getInputContextId() inputContextId} attribute. * An equals check used to prevent copying of the same value by returning {@code this}. * @param value A new value for inputContextId (can be {@code null}) * @return A modified copy of the {@code this} object */ public final ImmutableProcessesInit withInputContextId(@Nullable String value) { if (Objects.equals(this.inputContextId, value)) return this; return new ImmutableProcessesInit( this.identity, this.workflowName, this.protectionOrder, value, this.inputParentContextId, this.lastName, this.firstName, this.companyName, this.email, this.address, this.language, this.representativeFirstName, this.representativeLastName, this.representativeIdentity); } /** * Copy the current immutable object by setting a value for the {@link UserActionBuilderDefault.ProcessesInit#getInputParentContextId() inputParentContextId} attribute. * An equals check used to prevent copying of the same value by returning {@code this}. * @param value A new value for inputParentContextId (can be {@code null}) * @return A modified copy of the {@code this} object */ public final ImmutableProcessesInit withInputParentContextId(@Nullable String value) { if (Objects.equals(this.inputParentContextId, value)) return this; return new ImmutableProcessesInit( this.identity, this.workflowName, this.protectionOrder, this.inputContextId, value, this.lastName, this.firstName, this.companyName, this.email, this.address, this.language, this.representativeFirstName, this.representativeLastName, this.representativeIdentity); } /** * Copy the current immutable object by setting a value for the {@link UserActionBuilderDefault.ProcessesInit#getLastName() lastName} attribute. * An equals check used to prevent copying of the same value by returning {@code this}. * @param value A new value for lastName (can be {@code null}) * @return A modified copy of the {@code this} object */ public final ImmutableProcessesInit withLastName(@Nullable String value) { if (Objects.equals(this.lastName, value)) return this; return new ImmutableProcessesInit( this.identity, this.workflowName, this.protectionOrder, this.inputContextId, this.inputParentContextId, value, this.firstName, this.companyName, this.email, this.address, this.language, this.representativeFirstName, this.representativeLastName, this.representativeIdentity); } /** * Copy the current immutable object by setting a value for the {@link UserActionBuilderDefault.ProcessesInit#getFirstName() firstName} attribute. * An equals check used to prevent copying of the same value by returning {@code this}. * @param value A new value for firstName (can be {@code null}) * @return A modified copy of the {@code this} object */ public final ImmutableProcessesInit withFirstName(@Nullable String value) { if (Objects.equals(this.firstName, value)) return this; return new ImmutableProcessesInit( this.identity, this.workflowName, this.protectionOrder, this.inputContextId, this.inputParentContextId, this.lastName, value, this.companyName, this.email, this.address, this.language, this.representativeFirstName, this.representativeLastName, this.representativeIdentity); } /** * Copy the current immutable object by setting a value for the {@link UserActionBuilderDefault.ProcessesInit#getCompanyName() companyName} attribute. * An equals check used to prevent copying of the same value by returning {@code this}. * @param value A new value for companyName (can be {@code null}) * @return A modified copy of the {@code this} object */ public final ImmutableProcessesInit withCompanyName(@Nullable String value) { if (Objects.equals(this.companyName, value)) return this; return new ImmutableProcessesInit( this.identity, this.workflowName, this.protectionOrder, this.inputContextId, this.inputParentContextId, this.lastName, this.firstName, value, this.email, this.address, this.language, this.representativeFirstName, this.representativeLastName, this.representativeIdentity); } /** * Copy the current immutable object by setting a value for the {@link UserActionBuilderDefault.ProcessesInit#getEmail() email} attribute. * An equals check used to prevent copying of the same value by returning {@code this}. * @param value A new value for email (can be {@code null}) * @return A modified copy of the {@code this} object */ public final ImmutableProcessesInit withEmail(@Nullable String value) { if (Objects.equals(this.email, value)) return this; return new ImmutableProcessesInit( this.identity, this.workflowName, this.protectionOrder, this.inputContextId, this.inputParentContextId, this.lastName, this.firstName, this.companyName, value, this.address, this.language, this.representativeFirstName, this.representativeLastName, this.representativeIdentity); } /** * Copy the current immutable object by setting a value for the {@link UserActionBuilderDefault.ProcessesInit#getAddress() address} attribute. * An equals check used to prevent copying of the same value by returning {@code this}. * @param value A new value for address (can be {@code null}) * @return A modified copy of the {@code this} object */ public final ImmutableProcessesInit withAddress(@Nullable String value) { if (Objects.equals(this.address, value)) return this; return new ImmutableProcessesInit( this.identity, this.workflowName, this.protectionOrder, this.inputContextId, this.inputParentContextId, this.lastName, this.firstName, this.companyName, this.email, value, this.language, this.representativeFirstName, this.representativeLastName, this.representativeIdentity); } /** * Copy the current immutable object by setting a value for the {@link UserActionBuilderDefault.ProcessesInit#getLanguage() language} attribute. * An equals check used to prevent copying of the same value by returning {@code this}. * @param value A new value for language (can be {@code null}) * @return A modified copy of the {@code this} object */ public final ImmutableProcessesInit withLanguage(@Nullable String value) { if (Objects.equals(this.language, value)) return this; return new ImmutableProcessesInit( this.identity, this.workflowName, this.protectionOrder, this.inputContextId, this.inputParentContextId, this.lastName, this.firstName, this.companyName, this.email, this.address, value, this.representativeFirstName, this.representativeLastName, this.representativeIdentity); } /** * Copy the current immutable object by setting a value for the {@link UserActionBuilderDefault.ProcessesInit#getRepresentativeFirstName() representativeFirstName} attribute. * An equals check used to prevent copying of the same value by returning {@code this}. * @param value A new value for representativeFirstName (can be {@code null}) * @return A modified copy of the {@code this} object */ public final ImmutableProcessesInit withRepresentativeFirstName(@Nullable String value) { if (Objects.equals(this.representativeFirstName, value)) return this; return new ImmutableProcessesInit( this.identity, this.workflowName, this.protectionOrder, this.inputContextId, this.inputParentContextId, this.lastName, this.firstName, this.companyName, this.email, this.address, this.language, value, this.representativeLastName, this.representativeIdentity); } /** * Copy the current immutable object by setting a value for the {@link UserActionBuilderDefault.ProcessesInit#getRepresentativeLastName() representativeLastName} attribute. * An equals check used to prevent copying of the same value by returning {@code this}. * @param value A new value for representativeLastName (can be {@code null}) * @return A modified copy of the {@code this} object */ public final ImmutableProcessesInit withRepresentativeLastName(@Nullable String value) { if (Objects.equals(this.representativeLastName, value)) return this; return new ImmutableProcessesInit( this.identity, this.workflowName, this.protectionOrder, this.inputContextId, this.inputParentContextId, this.lastName, this.firstName, this.companyName, this.email, this.address, this.language, this.representativeFirstName, value, this.representativeIdentity); } /** * Copy the current immutable object by setting a value for the {@link UserActionBuilderDefault.ProcessesInit#getRepresentativeIdentity() representativeIdentity} attribute. * An equals check used to prevent copying of the same value by returning {@code this}. * @param value A new value for representativeIdentity (can be {@code null}) * @return A modified copy of the {@code this} object */ public final ImmutableProcessesInit withRepresentativeIdentity(@Nullable String value) { if (Objects.equals(this.representativeIdentity, value)) return this; return new ImmutableProcessesInit( this.identity, this.workflowName, this.protectionOrder, this.inputContextId, this.inputParentContextId, this.lastName, this.firstName, this.companyName, this.email, this.address, this.language, this.representativeFirstName, this.representativeLastName, value); } /** * This instance is equal to all instances of {@code ImmutableProcessesInit} that have equal attribute values. * @return {@code true} if {@code this} is equal to {@code another} instance */ @Override public boolean equals(@Nullable Object another) { if (this == another) return true; return another instanceof ImmutableProcessesInit && equalTo((ImmutableProcessesInit) another); } private boolean equalTo(ImmutableProcessesInit another) { return identity.equals(another.identity) && workflowName.equals(another.workflowName) && protectionOrder.equals(another.protectionOrder) && Objects.equals(inputContextId, another.inputContextId) && Objects.equals(inputParentContextId, another.inputParentContextId) && Objects.equals(lastName, another.lastName) && Objects.equals(firstName, another.firstName) && Objects.equals(companyName, another.companyName) && Objects.equals(email, another.email) && Objects.equals(address, another.address) && Objects.equals(language, another.language) && Objects.equals(representativeFirstName, another.representativeFirstName) && Objects.equals(representativeLastName, another.representativeLastName) && Objects.equals(representativeIdentity, another.representativeIdentity); } /** * Computes a hash code from attributes: {@code identity}, {@code workflowName}, {@code protectionOrder}, {@code inputContextId}, {@code inputParentContextId}, {@code lastName}, {@code firstName}, {@code companyName}, {@code email}, {@code address}, {@code language}, {@code representativeFirstName}, {@code representativeLastName}, {@code representativeIdentity}. * @return hashCode value */ @Override public int hashCode() { @Var int h = 5381; h += (h << 5) + identity.hashCode(); h += (h << 5) + workflowName.hashCode(); h += (h << 5) + protectionOrder.hashCode(); h += (h << 5) + Objects.hashCode(inputContextId); h += (h << 5) + Objects.hashCode(inputParentContextId); h += (h << 5) + Objects.hashCode(lastName); h += (h << 5) + Objects.hashCode(firstName); h += (h << 5) + Objects.hashCode(companyName); h += (h << 5) + Objects.hashCode(email); h += (h << 5) + Objects.hashCode(address); h += (h << 5) + Objects.hashCode(language); h += (h << 5) + Objects.hashCode(representativeFirstName); h += (h << 5) + Objects.hashCode(representativeLastName); h += (h << 5) + Objects.hashCode(representativeIdentity); return h; } /** * Prints the immutable value {@code ProcessesInit} with attribute values. * @return A string representation of the value */ @Override public String toString() { return MoreObjects.toStringHelper("ProcessesInit") .omitNullValues() .add("identity", identity) .add("workflowName", workflowName) .add("protectionOrder", protectionOrder) .add("inputContextId", inputContextId) .add("inputParentContextId", inputParentContextId) .add("lastName", lastName) .add("firstName", firstName) .add("companyName", companyName) .add("email", email) .add("address", address) .add("language", language) .add("representativeFirstName", representativeFirstName) .add("representativeLastName", representativeLastName) .add("representativeIdentity", representativeIdentity) .toString(); } /** * Creates an immutable copy of a {@link UserActionBuilderDefault.ProcessesInit} value. * Uses accessors to get values to initialize the new immutable instance. * If an instance is already immutable, it is returned as is. * @param instance The instance to copy * @return A copied immutable ProcessesInit instance */ public static ImmutableProcessesInit copyOf(UserActionBuilderDefault.ProcessesInit instance) { if (instance instanceof ImmutableProcessesInit) { return (ImmutableProcessesInit) instance; } return ImmutableProcessesInit.builder() .from(instance) .build(); } /** * Creates a builder for {@link ImmutableProcessesInit ImmutableProcessesInit}. *

   * ImmutableProcessesInit.builder()
   *    .identity(String) // required {@link UserActionBuilderDefault.ProcessesInit#getIdentity() identity}
   *    .workflowName(String) // required {@link UserActionBuilderDefault.ProcessesInit#getWorkflowName() workflowName}
   *    .protectionOrder(Boolean) // required {@link UserActionBuilderDefault.ProcessesInit#getProtectionOrder() protectionOrder}
   *    .inputContextId(String | null) // nullable {@link UserActionBuilderDefault.ProcessesInit#getInputContextId() inputContextId}
   *    .inputParentContextId(String | null) // nullable {@link UserActionBuilderDefault.ProcessesInit#getInputParentContextId() inputParentContextId}
   *    .lastName(String | null) // nullable {@link UserActionBuilderDefault.ProcessesInit#getLastName() lastName}
   *    .firstName(String | null) // nullable {@link UserActionBuilderDefault.ProcessesInit#getFirstName() firstName}
   *    .companyName(String | null) // nullable {@link UserActionBuilderDefault.ProcessesInit#getCompanyName() companyName}
   *    .email(String | null) // nullable {@link UserActionBuilderDefault.ProcessesInit#getEmail() email}
   *    .address(String | null) // nullable {@link UserActionBuilderDefault.ProcessesInit#getAddress() address}
   *    .language(String | null) // nullable {@link UserActionBuilderDefault.ProcessesInit#getLanguage() language}
   *    .representativeFirstName(String | null) // nullable {@link UserActionBuilderDefault.ProcessesInit#getRepresentativeFirstName() representativeFirstName}
   *    .representativeLastName(String | null) // nullable {@link UserActionBuilderDefault.ProcessesInit#getRepresentativeLastName() representativeLastName}
   *    .representativeIdentity(String | null) // nullable {@link UserActionBuilderDefault.ProcessesInit#getRepresentativeIdentity() representativeIdentity}
   *    .build();
   * 
* @return A new ImmutableProcessesInit builder */ public static ImmutableProcessesInit.Builder builder() { return new ImmutableProcessesInit.Builder(); } /** * Builds instances of type {@link ImmutableProcessesInit ImmutableProcessesInit}. * Initialize attributes and then invoke the {@link #build()} method to create an * immutable instance. *

{@code Builder} is not thread-safe and generally should not be stored in a field or collection, * but instead used immediately to create instances. */ @Generated(from = "UserActionBuilderDefault.ProcessesInit", generator = "Immutables") @NotThreadSafe public static final class Builder { private static final long INIT_BIT_IDENTITY = 0x1L; private static final long INIT_BIT_WORKFLOW_NAME = 0x2L; private static final long INIT_BIT_PROTECTION_ORDER = 0x4L; private long initBits = 0x7L; private @Nullable String identity; private @Nullable String workflowName; private @Nullable Boolean protectionOrder; private @Nullable String inputContextId; private @Nullable String inputParentContextId; private @Nullable String lastName; private @Nullable String firstName; private @Nullable String companyName; private @Nullable String email; private @Nullable String address; private @Nullable String language; private @Nullable String representativeFirstName; private @Nullable String representativeLastName; private @Nullable String representativeIdentity; private Builder() { } /** * Fill a builder with attribute values from the provided {@code ProcessesInit} instance. * Regular attribute values will be replaced with those from the given instance. * Absent optional values will not replace present values. * @param instance The instance from which to copy values * @return {@code this} builder for use in a chained invocation */ @CanIgnoreReturnValue public final Builder from(UserActionBuilderDefault.ProcessesInit instance) { Objects.requireNonNull(instance, "instance"); identity(instance.getIdentity()); workflowName(instance.getWorkflowName()); protectionOrder(instance.getProtectionOrder()); @Nullable String inputContextIdValue = instance.getInputContextId(); if (inputContextIdValue != null) { inputContextId(inputContextIdValue); } @Nullable String inputParentContextIdValue = instance.getInputParentContextId(); if (inputParentContextIdValue != null) { inputParentContextId(inputParentContextIdValue); } @Nullable String lastNameValue = instance.getLastName(); if (lastNameValue != null) { lastName(lastNameValue); } @Nullable String firstNameValue = instance.getFirstName(); if (firstNameValue != null) { firstName(firstNameValue); } @Nullable String companyNameValue = instance.getCompanyName(); if (companyNameValue != null) { companyName(companyNameValue); } @Nullable String emailValue = instance.getEmail(); if (emailValue != null) { email(emailValue); } @Nullable String addressValue = instance.getAddress(); if (addressValue != null) { address(addressValue); } @Nullable String languageValue = instance.getLanguage(); if (languageValue != null) { language(languageValue); } @Nullable String representativeFirstNameValue = instance.getRepresentativeFirstName(); if (representativeFirstNameValue != null) { representativeFirstName(representativeFirstNameValue); } @Nullable String representativeLastNameValue = instance.getRepresentativeLastName(); if (representativeLastNameValue != null) { representativeLastName(representativeLastNameValue); } @Nullable String representativeIdentityValue = instance.getRepresentativeIdentity(); if (representativeIdentityValue != null) { representativeIdentity(representativeIdentityValue); } return this; } /** * Initializes the value for the {@link UserActionBuilderDefault.ProcessesInit#getIdentity() identity} attribute. * @param identity The value for identity * @return {@code this} builder for use in a chained invocation */ @CanIgnoreReturnValue public final Builder identity(String identity) { this.identity = Objects.requireNonNull(identity, "identity"); initBits &= ~INIT_BIT_IDENTITY; return this; } /** * Initializes the value for the {@link UserActionBuilderDefault.ProcessesInit#getWorkflowName() workflowName} attribute. * @param workflowName The value for workflowName * @return {@code this} builder for use in a chained invocation */ @CanIgnoreReturnValue public final Builder workflowName(String workflowName) { this.workflowName = Objects.requireNonNull(workflowName, "workflowName"); initBits &= ~INIT_BIT_WORKFLOW_NAME; return this; } /** * Initializes the value for the {@link UserActionBuilderDefault.ProcessesInit#getProtectionOrder() protectionOrder} attribute. * @param protectionOrder The value for protectionOrder * @return {@code this} builder for use in a chained invocation */ @CanIgnoreReturnValue public final Builder protectionOrder(Boolean protectionOrder) { this.protectionOrder = Objects.requireNonNull(protectionOrder, "protectionOrder"); initBits &= ~INIT_BIT_PROTECTION_ORDER; return this; } /** * Initializes the value for the {@link UserActionBuilderDefault.ProcessesInit#getInputContextId() inputContextId} attribute. * @param inputContextId The value for inputContextId (can be {@code null}) * @return {@code this} builder for use in a chained invocation */ @CanIgnoreReturnValue public final Builder inputContextId(@Nullable String inputContextId) { this.inputContextId = inputContextId; return this; } /** * Initializes the value for the {@link UserActionBuilderDefault.ProcessesInit#getInputParentContextId() inputParentContextId} attribute. * @param inputParentContextId The value for inputParentContextId (can be {@code null}) * @return {@code this} builder for use in a chained invocation */ @CanIgnoreReturnValue public final Builder inputParentContextId(@Nullable String inputParentContextId) { this.inputParentContextId = inputParentContextId; return this; } /** * Initializes the value for the {@link UserActionBuilderDefault.ProcessesInit#getLastName() lastName} attribute. * @param lastName The value for lastName (can be {@code null}) * @return {@code this} builder for use in a chained invocation */ @CanIgnoreReturnValue public final Builder lastName(@Nullable String lastName) { this.lastName = lastName; return this; } /** * Initializes the value for the {@link UserActionBuilderDefault.ProcessesInit#getFirstName() firstName} attribute. * @param firstName The value for firstName (can be {@code null}) * @return {@code this} builder for use in a chained invocation */ @CanIgnoreReturnValue public final Builder firstName(@Nullable String firstName) { this.firstName = firstName; return this; } /** * Initializes the value for the {@link UserActionBuilderDefault.ProcessesInit#getCompanyName() companyName} attribute. * @param companyName The value for companyName (can be {@code null}) * @return {@code this} builder for use in a chained invocation */ @CanIgnoreReturnValue public final Builder companyName(@Nullable String companyName) { this.companyName = companyName; return this; } /** * Initializes the value for the {@link UserActionBuilderDefault.ProcessesInit#getEmail() email} attribute. * @param email The value for email (can be {@code null}) * @return {@code this} builder for use in a chained invocation */ @CanIgnoreReturnValue public final Builder email(@Nullable String email) { this.email = email; return this; } /** * Initializes the value for the {@link UserActionBuilderDefault.ProcessesInit#getAddress() address} attribute. * @param address The value for address (can be {@code null}) * @return {@code this} builder for use in a chained invocation */ @CanIgnoreReturnValue public final Builder address(@Nullable String address) { this.address = address; return this; } /** * Initializes the value for the {@link UserActionBuilderDefault.ProcessesInit#getLanguage() language} attribute. * @param language The value for language (can be {@code null}) * @return {@code this} builder for use in a chained invocation */ @CanIgnoreReturnValue public final Builder language(@Nullable String language) { this.language = language; return this; } /** * Initializes the value for the {@link UserActionBuilderDefault.ProcessesInit#getRepresentativeFirstName() representativeFirstName} attribute. * @param representativeFirstName The value for representativeFirstName (can be {@code null}) * @return {@code this} builder for use in a chained invocation */ @CanIgnoreReturnValue public final Builder representativeFirstName(@Nullable String representativeFirstName) { this.representativeFirstName = representativeFirstName; return this; } /** * Initializes the value for the {@link UserActionBuilderDefault.ProcessesInit#getRepresentativeLastName() representativeLastName} attribute. * @param representativeLastName The value for representativeLastName (can be {@code null}) * @return {@code this} builder for use in a chained invocation */ @CanIgnoreReturnValue public final Builder representativeLastName(@Nullable String representativeLastName) { this.representativeLastName = representativeLastName; return this; } /** * Initializes the value for the {@link UserActionBuilderDefault.ProcessesInit#getRepresentativeIdentity() representativeIdentity} attribute. * @param representativeIdentity The value for representativeIdentity (can be {@code null}) * @return {@code this} builder for use in a chained invocation */ @CanIgnoreReturnValue public final Builder representativeIdentity(@Nullable String representativeIdentity) { this.representativeIdentity = representativeIdentity; return this; } /** * Builds a new {@link ImmutableProcessesInit ImmutableProcessesInit}. * @return An immutable instance of ProcessesInit * @throws java.lang.IllegalStateException if any required attributes are missing */ public ImmutableProcessesInit build() { if (initBits != 0) { throw new IllegalStateException(formatRequiredAttributesMessage()); } return new ImmutableProcessesInit( identity, workflowName, protectionOrder, inputContextId, inputParentContextId, lastName, firstName, companyName, email, address, language, representativeFirstName, representativeLastName, representativeIdentity); } private String formatRequiredAttributesMessage() { List attributes = new ArrayList<>(); if ((initBits & INIT_BIT_IDENTITY) != 0) attributes.add("identity"); if ((initBits & INIT_BIT_WORKFLOW_NAME) != 0) attributes.add("workflowName"); if ((initBits & INIT_BIT_PROTECTION_ORDER) != 0) attributes.add("protectionOrder"); return "Cannot build ProcessesInit, some of required attributes are not set " + attributes; } } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy