Class ChatUpdateMessageResponse

java.lang.Object
com.hubspot.slack.client.models.response.chat.ChatUpdateMessageResponse
All Implemented Interfaces:
ChatUpdateMessageResponseIF, SlackResponse

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

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

  • Method Details

    • isOk

      public boolean isOk()
      Specified by:
      isOk in interface SlackResponse
      Returns:
      The value of the ok attribute
    • getResponseMetadata

      public Optional<ResponseMetadata> getResponseMetadata()
      Specified by:
      getResponseMetadata in interface SlackResponse
      Returns:
      The value of the responseMetadata attribute
    • getTs

      public String getTs()
      Specified by:
      getTs in interface ChatUpdateMessageResponseIF
      Returns:
      The value of the ts attribute
    • getChannel

      public String getChannel()
      Specified by:
      getChannel in interface ChatUpdateMessageResponseIF
      Returns:
      The value of the channel attribute
    • getText

      public String getText()
      Specified by:
      getText in interface ChatUpdateMessageResponseIF
      Returns:
      The value of the text attribute
    • withOk

      public final ChatUpdateMessageResponse withOk(boolean value)
      Copy the current immutable object by setting a value for the ok attribute. A value equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for ok
      Returns:
      A modified copy or the this object
    • withResponseMetadata

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

      public final ChatUpdateMessageResponse withResponseMetadata(Optional<? extends ResponseMetadata> optional)
      Copy the current immutable object by setting an optional value for the responseMetadata 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 responseMetadata
      Returns:
      A modified copy or this if not changed
    • withTs

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

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

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

      public boolean equals(@Nullable Object another)
      This instance is equal to all instances of ChatUpdateMessageResponse 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: ok, responseMetadata, ts, channel, text.
      Overrides:
      hashCode in class Object
      Returns:
      hashCode value
    • toString

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

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

      public static ChatUpdateMessageResponse.Builder builder()
      Creates a builder for ChatUpdateMessageResponse.
       ChatUpdateMessageResponse.builder()
          .setOk(boolean) // required ok
          .setResponseMetadata(Optional<ResponseMetadata>) // optional responseMetadata
          .setTs(String) // required ts
          .setChannel(String) // required channel
          .setText(String) // required text
          .build();
       
      Returns:
      A new ChatUpdateMessageResponse builder