Class MessageAttachmentContainer.Builder

java.lang.Object
com.hubspot.slack.client.models.interaction.MessageAttachmentContainer.Builder
Enclosing class:
MessageAttachmentContainer

@Generated(from="MessageAttachmentContainerIF", generator="Immutables") @NotThreadSafe public static final class MessageAttachmentContainer.Builder extends Object
Builds instances of type MessageAttachmentContainer. Initialize attributes and then invoke the build() method to create an immutable instance.

Builder is not thread-safe and generally should not be stored in a field or collection, but instead used immediately to create instances.

  • Method Details

    • from

      Fill a builder with attribute values from the provided com.hubspot.slack.client.models.interaction.MessageAttachmentContainerIF instance.
      Parameters:
      instance - The instance from which to copy values
      Returns:
      this builder for use in a chained invocation
    • from

      public final MessageAttachmentContainer.Builder from(Container instance)
      Fill a builder with attribute values from the provided com.hubspot.slack.client.models.interaction.Container instance.
      Parameters:
      instance - The instance from which to copy values
      Returns:
      this builder for use in a chained invocation
    • setType

      Initializes the value for the type attribute.
      Parameters:
      type - The value for type
      Returns:
      this builder for use in a chained invocation
    • setMessageTs

      public final MessageAttachmentContainer.Builder setMessageTs(String messageTs)
      Initializes the value for the messageTs attribute.
      Parameters:
      messageTs - The value for messageTs
      Returns:
      this builder for use in a chained invocation
    • setChannelId

      public final MessageAttachmentContainer.Builder setChannelId(String channelId)
      Initializes the value for the channelId attribute.
      Parameters:
      channelId - The value for channelId
      Returns:
      this builder for use in a chained invocation
    • setEphemeral

      public final MessageAttachmentContainer.Builder setEphemeral(boolean ephemeral)
      Initializes the value for the ephemeral attribute.
      Parameters:
      ephemeral - The value for ephemeral
      Returns:
      this builder for use in a chained invocation
    • setAppUnfurl

      public final MessageAttachmentContainer.Builder setAppUnfurl(boolean appUnfurl)
      Initializes the value for the appUnfurl attribute.
      Parameters:
      appUnfurl - The value for appUnfurl
      Returns:
      this builder for use in a chained invocation
    • setAttachmentId

      public final MessageAttachmentContainer.Builder setAttachmentId(int attachmentId)
      Initializes the value for the attachmentId attribute.
      Parameters:
      attachmentId - The value for attachmentId
      Returns:
      this builder for use in a chained invocation
    • setExternalRef

      public final MessageAttachmentContainer.Builder setExternalRef(@Nullable ExternalRef externalRef)
      Initializes the optional value externalRef to externalRef.
      Parameters:
      externalRef - The value for externalRef, null is accepted as java.util.Optional.empty()
      Returns:
      this builder for chained invocation
    • setExternalRef

      public final MessageAttachmentContainer.Builder setExternalRef(Optional<? extends ExternalRef> externalRef)
      Initializes the optional value externalRef to externalRef.
      Parameters:
      externalRef - The value for externalRef
      Returns:
      this builder for use in a chained invocation
    • setEntityUrl

      public final MessageAttachmentContainer.Builder setEntityUrl(@Nullable String entityUrl)
      Initializes the optional value entityUrl to entityUrl.
      Parameters:
      entityUrl - The value for entityUrl, null is accepted as java.util.Optional.empty()
      Returns:
      this builder for chained invocation
    • setEntityUrl

      public final MessageAttachmentContainer.Builder setEntityUrl(Optional<String> entityUrl)
      Initializes the optional value entityUrl to entityUrl.
      Parameters:
      entityUrl - The value for entityUrl
      Returns:
      this builder for use in a chained invocation
    • build

      Returns:
      An immutable instance of MessageAttachmentContainer
      Throws:
      com.hubspot.immutables.validation.InvalidImmutableStateException - if any required attributes are missing