Class EntityPayloadAttributesCustomField

java.lang.Object
com.hubspot.slack.client.methods.params.chat.workobject.entity.EntityPayloadAttributesCustomField
All Implemented Interfaces:
EntityPayloadAttributesCustomFieldIF

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

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

  • Method Details

    • getKey

      public String getKey()
      Specified by:
      getKey in interface EntityPayloadAttributesCustomFieldIF
      Returns:
      The value of the key attribute
    • getLabel

      public String getLabel()
      Specified by:
      getLabel in interface EntityPayloadAttributesCustomFieldIF
      Returns:
      The value of the label attribute
    • getValue

      public String getValue()
      Specified by:
      getValue in interface EntityPayloadAttributesCustomFieldIF
      Returns:
      The value of the value attribute
    • getType

      public FieldDataType getType()
      Specified by:
      getType in interface EntityPayloadAttributesCustomFieldIF
      Returns:
      The value of the type attribute
    • getIcon

      public Optional<Icon> getIcon()
      Specified by:
      getIcon in interface EntityPayloadAttributesCustomFieldIF
      Returns:
      The value of the icon attribute
    • getLink

      public Optional<String> getLink()
      Specified by:
      getLink in interface EntityPayloadAttributesCustomFieldIF
      Returns:
      The value of the link attribute
    • getTagColor

      public Optional<TagColor> getTagColor()
      Specified by:
      getTagColor in interface EntityPayloadAttributesCustomFieldIF
      Returns:
      The value of the tagColor attribute
    • getFormat

      public Optional<String> getFormat()
      Specified by:
      getFormat in interface EntityPayloadAttributesCustomFieldIF
      Returns:
      The value of the format attribute
    • isLong

      public Optional<Boolean> isLong()
      Specified by:
      isLong in interface EntityPayloadAttributesCustomFieldIF
      Returns:
      The value of the isLong attribute
    • getImageUrl

      public Optional<String> getImageUrl()
      Specified by:
      getImageUrl in interface EntityPayloadAttributesCustomFieldIF
      Returns:
      The value of the imageUrl attribute
    • getSlackFile

      public Optional<String> getSlackFile()
      Specified by:
      getSlackFile in interface EntityPayloadAttributesCustomFieldIF
      Returns:
      The value of the slackFile attribute
    • getAltText

      public Optional<String> getAltText()
      Specified by:
      getAltText in interface EntityPayloadAttributesCustomFieldIF
      Returns:
      The value of the altText attribute
    • withKey

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

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

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

      public final EntityPayloadAttributesCustomField withType(FieldDataType 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
    • withIcon

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

      public final EntityPayloadAttributesCustomField withIcon(Optional<? extends Icon> optional)
      Copy the current immutable object by setting an optional value for the icon 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 icon
      Returns:
      A modified copy or this if not changed
    • withLink

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

      public final EntityPayloadAttributesCustomField withLink(Optional<String> optional)
      Copy the current immutable object by setting an optional value for the link 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 link
      Returns:
      A modified copy or this if not changed
    • withTagColor

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

      public final EntityPayloadAttributesCustomField withTagColor(Optional<? extends TagColor> optional)
      Copy the current immutable object by setting an optional value for the tagColor 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 tagColor
      Returns:
      A modified copy or this if not changed
    • withFormat

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

      public final EntityPayloadAttributesCustomField withFormat(Optional<String> optional)
      Copy the current immutable object by setting an optional value for the format 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 format
      Returns:
      A modified copy or this if not changed
    • withLong

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

      public final EntityPayloadAttributesCustomField withLong(Optional<Boolean> optional)
      Copy the current immutable object by setting an optional value for the long 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 isLong
      Returns:
      A modified copy or this if not changed
    • withImageUrl

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

      public final EntityPayloadAttributesCustomField withImageUrl(Optional<String> optional)
      Copy the current immutable object by setting an optional value for the imageUrl 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 imageUrl
      Returns:
      A modified copy or this if not changed
    • withSlackFile

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

      public final EntityPayloadAttributesCustomField withSlackFile(Optional<String> optional)
      Copy the current immutable object by setting an optional value for the slackFile 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 slackFile
      Returns:
      A modified copy or this if not changed
    • withAltText

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

      public final EntityPayloadAttributesCustomField withAltText(Optional<String> optional)
      Copy the current immutable object by setting an optional value for the altText 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 altText
      Returns:
      A modified copy or this if not changed
    • equals

      public boolean equals(@Nullable Object another)
      This instance is equal to all instances of EntityPayloadAttributesCustomField 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: key, label, value, type, icon, link, tagColor, format, isLong, imageUrl, slackFile, altText.
      Overrides:
      hashCode in class Object
      Returns:
      hashCode value
    • toString

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

      Creates an immutable copy of a EntityPayloadAttributesCustomFieldIF 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 EntityPayloadAttributesCustomField instance
    • builder

      Creates a builder for EntityPayloadAttributesCustomField.
       EntityPayloadAttributesCustomField.builder()
          .setKey(String) // required key
          .setLabel(String) // required label
          .setValue(String) // required value
          .setType(com.hubspot.slack.client.methods.params.chat.workobject.entity.FieldDataType) // required type
          .setIcon(Optional<Icon>) // optional icon
          .setLink(Optional<String>) // optional link
          .setTagColor(Optional<com.hubspot.slack.client.methods.params.chat.workobject.entity.fields.TagColor>) // optional tagColor
          .setFormat(Optional<String>) // optional format
          .setLong(Optional<Boolean>) // optional long
          .setImageUrl(Optional<String>) // optional imageUrl
          .setSlackFile(Optional<String>) // optional slackFile
          .setAltText(Optional<String>) // optional altText
          .build();
       
      Returns:
      A new EntityPayloadAttributesCustomField builder