java.lang.Object
com.hubspot.slack.client.methods.params.stream.chunks.TaskUpdateChunk
All Implemented Interfaces:
StreamChunk, TaskUpdateChunkIF

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

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

  • Method Details

    • getType

      public String getType()
      Specified by:
      getType in interface StreamChunk
      Specified by:
      getType in interface TaskUpdateChunkIF
      Returns:
      The computed-at-construction value of the type attribute
    • getId

      public String getId()
      Specified by:
      getId in interface TaskUpdateChunkIF
      Returns:
      The value of the id attribute
    • getTitle

      public String getTitle()
      Specified by:
      getTitle in interface TaskUpdateChunkIF
      Returns:
      The value of the title attribute
    • getStatus

      public Optional<TaskCardBlockStatus> getStatus()
      Specified by:
      getStatus in interface TaskUpdateChunkIF
      Returns:
      The value of the status attribute
    • getDetails

      public Optional<String> getDetails()
      Specified by:
      getDetails in interface TaskUpdateChunkIF
      Returns:
      The value of the details attribute
    • getOutput

      public Optional<String> getOutput()
      Specified by:
      getOutput in interface TaskUpdateChunkIF
      Returns:
      The value of the output attribute
    • getSources

      public com.google.common.collect.ImmutableList<UrlSource> getSources()
      Specified by:
      getSources in interface TaskUpdateChunkIF
      Returns:
      The value of the sources attribute
    • withId

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

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

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

      public final TaskUpdateChunk withStatus(Optional<? extends TaskCardBlockStatus> optional)
      Copy the current immutable object by setting an optional value for the status 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 status
      Returns:
      A modified copy or this if not changed
    • withDetails

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

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

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

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

      public final TaskUpdateChunk withSources(UrlSource... elements)
      Copy the current immutable object with elements that replace the content of sources.
      Parameters:
      elements - The elements to set
      Returns:
      A modified copy of this object
    • withSources

      public final TaskUpdateChunk withSources(Iterable<? extends UrlSource> elements)
      Copy the current immutable object with elements that replace the content of sources. A shallow reference equality check is used to prevent copying of the same value by returning this.
      Parameters:
      elements - An iterable of sources elements to set
      Returns:
      A modified copy or this if not changed
    • equals

      public boolean equals(@Nullable Object another)
      This instance is equal to all instances of TaskUpdateChunk 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: type, id, title, status, details, output, sources.
      Overrides:
      hashCode in class Object
      Returns:
      hashCode value
    • toString

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

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

      public static TaskUpdateChunk.Builder builder()
      Creates a builder for TaskUpdateChunk.
       TaskUpdateChunk.builder()
          .setId(String) // required id
          .setTitle(String) // required title
          .setStatus(Optional<com.hubspot.slack.client.models.blocks.TaskCardBlockStatus>) // optional status
          .setDetails(Optional<String>) // optional details
          .setOutput(Optional<String>) // optional output
          .addSources|addAllSources(com.hubspot.slack.client.models.blocks.elements.UrlSource) // sources elements
          .build();
       
      Returns:
      A new TaskUpdateChunk builder