Class SlackFormTextareaElement.Builder

java.lang.Object
com.hubspot.slack.client.models.dialog.form.elements.SlackFormTextareaElement.Builder
Enclosing class:
SlackFormTextareaElement

@Generated(from="AbstractSlackFormTextareaElement", generator="Immutables") @NotThreadSafe public static final class SlackFormTextareaElement.Builder extends Object
Builds instances of type SlackFormTextareaElement. 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 SlackFormTextareaElement.Builder from(HasLabel instance)
      Fill a builder with attribute values from the provided com.hubspot.slack.client.models.dialog.form.elements.HasLabel 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.models.dialog.form.elements.SlackDialogFormElement 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.models.dialog.form.elements.AbstractSlackFormTextareaElement 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.models.dialog.form.elements.AbstractSlackDialogFormTextElement instance.
      Parameters:
      instance - The instance from which to copy values
      Returns:
      this builder for use in a chained invocation
    • setLabel

      public final SlackFormTextareaElement.Builder setLabel(String label)
      Initializes the value for the label attribute.
      Parameters:
      label - The value for label
      Returns:
      this builder for use in a chained invocation
    • setName

      public final SlackFormTextareaElement.Builder setName(String name)
      Initializes the value for the name attribute.
      Parameters:
      name - The value for name
      Returns:
      this builder for use in a chained invocation
    • setPlaceholder

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

      public final SlackFormTextareaElement.Builder setPlaceholder(Optional<String> placeholder)
      Initializes the optional value placeholder to placeholder.
      Parameters:
      placeholder - The value for placeholder
      Returns:
      this builder for use in a chained invocation
    • setOptional

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

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

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

      public final SlackFormTextareaElement.Builder setSubtype(Optional<? extends SlackFormElementSubtypes> subtype)
      Initializes the optional value subtype to subtype.
      Parameters:
      subtype - The value for subtype
      Returns:
      this builder for use in a chained invocation
    • setHint

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

      public final SlackFormTextareaElement.Builder setHint(Optional<String> hint)
      Initializes the optional value hint to hint.
      Parameters:
      hint - The value for hint
      Returns:
      this builder for use in a chained invocation
    • setMinLength

      public final SlackFormTextareaElement.Builder setMinLength(int minLength)
      Initializes the value for the minLength attribute.

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

      Parameters:
      minLength - The value for minLength
      Returns:
      this builder for use in a chained invocation
    • setMaxLength

      public final SlackFormTextareaElement.Builder setMaxLength(int maxLength)
      Initializes the value for the maxLength attribute.

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

      Parameters:
      maxLength - The value for maxLength
      Returns:
      this builder for use in a chained invocation
    • setValue

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

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

      Initializes the value for the type attribute.

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

      Parameters:
      type - The value for type
      Returns:
      this builder for use in a chained invocation
    • build

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