Class EntityDetailContainer

java.lang.Object
com.hubspot.slack.client.models.interaction.EntityDetailContainer
All Implemented Interfaces:
Container, EntityDetailContainerIF

@Generated(from="EntityDetailContainerIF", generator="Immutables") @ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable public final class EntityDetailContainer extends Object implements EntityDetailContainerIF
Immutable implementation of EntityDetailContainerIF.

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

  • Method Details

    • getType

      public ContainerType getType()
      Specified by:
      getType in interface Container
      Returns:
      The value of the type attribute
    • getMessageTs

      public String getMessageTs()
      Specified by:
      getMessageTs in interface EntityDetailContainerIF
      Returns:
      The value of the messageTs attribute
    • getChannelId

      public String getChannelId()
      Specified by:
      getChannelId in interface EntityDetailContainerIF
      Returns:
      The value of the channelId attribute
    • getExternalRef

      public Optional<ExternalRef> getExternalRef()
      Specified by:
      getExternalRef in interface EntityDetailContainerIF
      Returns:
      The value of the externalRef attribute
    • getEntityUrl

      public Optional<String> getEntityUrl()
      Specified by:
      getEntityUrl in interface EntityDetailContainerIF
      Returns:
      The value of the entityUrl attribute
    • getAppUnfurlUrl

      public Optional<String> getAppUnfurlUrl()
      Specified by:
      getAppUnfurlUrl in interface EntityDetailContainerIF
      Returns:
      The value of the appUnfurlUrl attribute
    • withType

      public final EntityDetailContainer withType(ContainerType value)
      Copy the current immutable object by setting a value for the type attribute. A value equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for type
      Returns:
      A modified copy or the this object
    • withMessageTs

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

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

      public final EntityDetailContainer withExternalRef(@Nullable ExternalRef value)
      Copy the current immutable object by setting a present value for the optional externalRef attribute.
      Parameters:
      value - The value for externalRef, null is accepted as java.util.Optional.empty()
      Returns:
      A modified copy or this if not changed
    • withExternalRef

      public final EntityDetailContainer withExternalRef(Optional<? extends ExternalRef> optional)
      Copy the current immutable object by setting an optional value for the externalRef attribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returning this.
      Parameters:
      optional - An optional value for externalRef
      Returns:
      A modified copy or this if not changed
    • withEntityUrl

      public final EntityDetailContainer withEntityUrl(@Nullable String value)
      Copy the current immutable object by setting a present value for the optional entityUrl attribute.
      Parameters:
      value - The value for entityUrl, null is accepted as java.util.Optional.empty()
      Returns:
      A modified copy or this if not changed
    • withEntityUrl

      public final EntityDetailContainer withEntityUrl(Optional<String> optional)
      Copy the current immutable object by setting an optional value for the entityUrl attribute. An equality check is used on inner value to prevent copying of the same value by returning this.
      Parameters:
      optional - An optional value for entityUrl
      Returns:
      A modified copy or this if not changed
    • withAppUnfurlUrl

      public final EntityDetailContainer withAppUnfurlUrl(@Nullable String value)
      Copy the current immutable object by setting a present value for the optional appUnfurlUrl attribute.
      Parameters:
      value - The value for appUnfurlUrl, null is accepted as java.util.Optional.empty()
      Returns:
      A modified copy or this if not changed
    • withAppUnfurlUrl

      public final EntityDetailContainer withAppUnfurlUrl(Optional<String> optional)
      Copy the current immutable object by setting an optional value for the appUnfurlUrl attribute. An equality check is used on inner value to prevent copying of the same value by returning this.
      Parameters:
      optional - An optional value for appUnfurlUrl
      Returns:
      A modified copy or this if not changed
    • equals

      public boolean equals(@Nullable Object another)
      This instance is equal to all instances of EntityDetailContainer 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: type, messageTs, channelId, externalRef, entityUrl, appUnfurlUrl.
      Overrides:
      hashCode in class Object
      Returns:
      hashCode value
    • toString

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

      public static EntityDetailContainer copyOf(EntityDetailContainerIF instance)
      Creates an immutable copy of a EntityDetailContainerIF 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 EntityDetailContainer instance
    • builder

      public static EntityDetailContainer.Builder builder()
      Creates a builder for EntityDetailContainer.
       EntityDetailContainer.builder()
          .setType(com.hubspot.slack.client.models.interaction.ContainerType) // required type
          .setMessageTs(String) // required messageTs
          .setChannelId(String) // required channelId
          .setExternalRef(Optional<com.hubspot.slack.client.methods.params.chat.workobject.ExternalRef>) // optional externalRef
          .setEntityUrl(Optional<String>) // optional entityUrl
          .setAppUnfurlUrl(Optional<String>) // optional appUnfurlUrl
          .build();
       
      Returns:
      A new EntityDetailContainer builder