Class ImmutableFormTaggedEvent

java.lang.Object
io.dialob.integration.api.event.ImmutableFormTaggedEvent
All Implemented Interfaces:
DistributedEvent, Event, FormEvent, FormTaggedEvent, TenantScopedEvent, Serializable

@ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable public final class ImmutableFormTaggedEvent extends Object implements FormTaggedEvent
Immutable implementation of FormTaggedEvent.

Use the builder to create immutable instances: ImmutableFormTaggedEvent.builder().

See Also:
  • Method Details

    • getTenant

      public Tenant getTenant()
      Specified by:
      getTenant in interface TenantScopedEvent
      Returns:
      The value of the tenant attribute
    • getFormId

      public String getFormId()
      Specified by:
      getFormId in interface FormEvent
      Returns:
      The value of the formId attribute
    • getSource

      public String getSource()
      Specified by:
      getSource in interface DistributedEvent
      Returns:
      The value of the source attribute
    • getFormName

      public String getFormName()
      Specified by:
      getFormName in interface FormTaggedEvent
      Returns:
      The value of the formName attribute
    • getTagName

      public String getTagName()
      Specified by:
      getTagName in interface FormTaggedEvent
      Returns:
      The value of the tagName attribute
    • getRefName

      @Nullable public String getRefName()
      Specified by:
      getRefName in interface FormTaggedEvent
      Returns:
      The value of the refName attribute
    • withTenant

      public final ImmutableFormTaggedEvent withTenant(Tenant value)
      Copy the current immutable object by setting a value for the tenant attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for tenant
      Returns:
      A modified copy of the this object
    • withFormId

      public final ImmutableFormTaggedEvent withFormId(String value)
      Copy the current immutable object by setting a value for the formId attribute. An equals check used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for formId
      Returns:
      A modified copy of the this object
    • withSource

      public final ImmutableFormTaggedEvent withSource(String value)
      Copy the current immutable object by setting a value for the source attribute. An equals check used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for source
      Returns:
      A modified copy of the this object
    • withFormName

      public final ImmutableFormTaggedEvent withFormName(String value)
      Copy the current immutable object by setting a value for the formName attribute. An equals check used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for formName
      Returns:
      A modified copy of the this object
    • withTagName

      public final ImmutableFormTaggedEvent withTagName(String value)
      Copy the current immutable object by setting a value for the tagName attribute. An equals check used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for tagName
      Returns:
      A modified copy of the this object
    • withRefName

      public final ImmutableFormTaggedEvent withRefName(@Nullable String value)
      Copy the current immutable object by setting a value for the refName attribute. An equals check used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for refName (can be null)
      Returns:
      A modified copy of the this object
    • equals

      public boolean equals(@Nullable Object another)
      This instance is equal to all instances of ImmutableFormTaggedEvent that have equal attribute values.
      Overrides:
      equals in class Object
      Returns:
      true if this is equal to another instance
    • hashCode

      public int hashCode()
      Computes a hash code from attributes: tenant, formId, source, formName, tagName, refName.
      Overrides:
      hashCode in class Object
      Returns:
      hashCode value
    • toString

      public String toString()
      Prints the immutable value FormTaggedEvent with attribute values.
      Overrides:
      toString in class Object
      Returns:
      A string representation of the value
    • copyOf

      public static ImmutableFormTaggedEvent copyOf(FormTaggedEvent instance)
      Creates an immutable copy of a FormTaggedEvent value. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.
      Parameters:
      instance - The instance to copy
      Returns:
      A copied immutable FormTaggedEvent instance
    • builder

      public static ImmutableFormTaggedEvent.Builder builder()
      Creates a builder for ImmutableFormTaggedEvent.
       ImmutableFormTaggedEvent.builder()
          .tenant(io.dialob.security.tenant.Tenant) // required tenant
          .formId(String) // required formId
          .source(String) // required source
          .formName(String) // required formName
          .tagName(String) // required tagName
          .refName(String | null) // nullable refName
          .build();
       
      Returns:
      A new ImmutableFormTaggedEvent builder