Class ChatScheduleMessageParams.Builder

java.lang.Object
com.hubspot.slack.client.methods.params.chat.ChatScheduleMessageParams.Builder
Enclosing class:
ChatScheduleMessageParams

@Generated(from="ChatScheduleMessageParamsIF", generator="Immutables") @NotThreadSafe public static final class ChatScheduleMessageParams.Builder extends Object
Builds instances of type ChatScheduleMessageParams. 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

      public final ChatScheduleMessageParams.Builder from(HasChannel instance)
      Fill a builder with attribute values from the provided com.hubspot.slack.client.methods.interceptor.HasChannel instance.
      Parameters:
      instance - The instance from which to copy values
      Returns:
      this builder for use in a chained invocation
    • from

      public final ChatScheduleMessageParams.Builder from(MessageParams instance)
      Fill a builder with attribute values from the provided com.hubspot.slack.client.methods.params.chat.MessageParams instance.
      Parameters:
      instance - The instance from which to copy values
      Returns:
      this builder for use in a chained invocation
    • from

      Fill a builder with attribute values from the provided com.hubspot.slack.client.methods.params.chat.ChatScheduleMessageParamsIF instance.
      Parameters:
      instance - The instance from which to copy values
      Returns:
      this builder for use in a chained invocation
    • setText

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

      public final ChatScheduleMessageParams.Builder setText(Optional<String> text)
      Initializes the optional value text to text.
      Parameters:
      text - The value for text
      Returns:
      this builder for use in a chained invocation
    • addAttachments

      public final ChatScheduleMessageParams.Builder addAttachments(Attachment element)
      Adds one element to attachments list.
      Parameters:
      element - A attachments element
      Returns:
      this builder for use in a chained invocation
    • addAttachments

      public final ChatScheduleMessageParams.Builder addAttachments(Attachment... elements)
      Adds elements to attachments list.
      Parameters:
      elements - An array of attachments elements
      Returns:
      this builder for use in a chained invocation
    • setAttachments

      public final ChatScheduleMessageParams.Builder setAttachments(Iterable<? extends Attachment> elements)
      Sets or replaces all elements for attachments list.
      Parameters:
      elements - An iterable of attachments elements
      Returns:
      this builder for use in a chained invocation
    • addAllAttachments

      public final ChatScheduleMessageParams.Builder addAllAttachments(Iterable<? extends Attachment> elements)
      Adds elements to attachments list.
      Parameters:
      elements - An iterable of attachments elements
      Returns:
      this builder for use in a chained invocation
    • addBlocks

      public final ChatScheduleMessageParams.Builder addBlocks(Block element)
      Adds one element to blocks list.
      Parameters:
      element - A blocks element
      Returns:
      this builder for use in a chained invocation
    • addBlocks

      public final ChatScheduleMessageParams.Builder addBlocks(Block... elements)
      Adds elements to blocks list.
      Parameters:
      elements - An array of blocks elements
      Returns:
      this builder for use in a chained invocation
    • setBlocks

      public final ChatScheduleMessageParams.Builder setBlocks(Iterable<? extends Block> elements)
      Sets or replaces all elements for blocks list.
      Parameters:
      elements - An iterable of blocks elements
      Returns:
      this builder for use in a chained invocation
    • addAllBlocks

      public final ChatScheduleMessageParams.Builder addAllBlocks(Iterable<? extends Block> elements)
      Adds elements to blocks list.
      Parameters:
      elements - An iterable of blocks elements
      Returns:
      this builder for use in a chained invocation
    • setChannelId

      public final ChatScheduleMessageParams.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
    • setPostAt

      public final ChatScheduleMessageParams.Builder setPostAt(long postAt)
      Initializes the value for the postAt attribute.
      Parameters:
      postAt - The value for postAt
      Returns:
      this builder for use in a chained invocation
    • setShouldLinkNames

      public final ChatScheduleMessageParams.Builder setShouldLinkNames(boolean shouldLinkNames)
      Initializes the value for the shouldLinkNames attribute.

      If not set, this attribute will have a default value as returned by the initializer of shouldLinkNames.

      Parameters:
      shouldLinkNames - The value for shouldLinkNames
      Returns:
      this builder for use in a chained invocation
    • setParseMode

      public final ChatScheduleMessageParams.Builder setParseMode(String parseMode)
      Initializes the value for the parseMode attribute.

      If not set, this attribute will have a default value as returned by the initializer of parseMode.

      Parameters:
      parseMode - The value for parseMode
      Returns:
      this builder for use in a chained invocation
    • setThreadTs

      public final ChatScheduleMessageParams.Builder setThreadTs(String threadTs)
      Initializes the value for the threadTs attribute.

      If not set, this attribute will have a default value as returned by the initializer of threadTs.

      Parameters:
      threadTs - The value for threadTs
      Returns:
      this builder for use in a chained invocation
    • setUnfurlLinks

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

      public final ChatScheduleMessageParams.Builder setUnfurlLinks(Optional<Boolean> unfurlLinks)
      Initializes the optional value unfurlLinks to unfurlLinks.
      Parameters:
      unfurlLinks - The value for unfurlLinks
      Returns:
      this builder for use in a chained invocation
    • setUnfurlMedia

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

      public final ChatScheduleMessageParams.Builder setUnfurlMedia(Optional<Boolean> unfurlMedia)
      Initializes the optional value unfurlMedia to unfurlMedia.
      Parameters:
      unfurlMedia - The value for unfurlMedia
      Returns:
      this builder for use in a chained invocation
    • build

      public ChatScheduleMessageParams build()
      Returns:
      An immutable instance of ChatScheduleMessageParams
      Throws:
      com.hubspot.immutables.validation.InvalidImmutableStateException - if any required attributes are missing