Class TaskUpdateChunk.Builder
java.lang.Object
com.hubspot.slack.client.methods.params.stream.chunks.TaskUpdateChunk.Builder
- Enclosing class:
TaskUpdateChunk
@Generated(from="TaskUpdateChunkIF",
generator="Immutables")
@NotThreadSafe
public static final class TaskUpdateChunk.Builder
extends Object
Builds instances of type
TaskUpdateChunk.
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 Summary
Modifier and TypeMethodDescriptionfinal TaskUpdateChunk.BuilderaddAllSources(Iterable<? extends UrlSource> elements) Adds elements tosourceslist.final TaskUpdateChunk.BuilderaddSources(UrlSource element) Adds one element tosourceslist.final TaskUpdateChunk.BuilderaddSources(UrlSource... elements) Adds elements tosourceslist.build()Builds a newTaskUpdateChunk.final TaskUpdateChunk.Builderfrom(TaskUpdateChunkIF instance) Fill a builder with attribute values from the providedTaskUpdateChunkIFinstance.final TaskUpdateChunk.BuildersetDetails(String details) Initializes the optional valuedetailsto details.final TaskUpdateChunk.BuildersetDetails(Optional<String> details) Initializes the optional valuedetailsto details.final TaskUpdateChunk.BuilderInitializes the value for theidattribute.final TaskUpdateChunk.BuilderInitializes the optional valueoutputto output.final TaskUpdateChunk.BuilderInitializes the optional valueoutputto output.final TaskUpdateChunk.BuildersetSources(Iterable<? extends UrlSource> elements) Sets or replaces all elements forsourceslist.final TaskUpdateChunk.BuildersetStatus(TaskCardBlockStatus status) Initializes the optional valuestatusto status.final TaskUpdateChunk.BuildersetStatus(Optional<? extends TaskCardBlockStatus> status) Initializes the optional valuestatusto status.final TaskUpdateChunk.BuilderInitializes the value for thetitleattribute.
-
Method Details
-
from
Fill a builder with attribute values from the providedTaskUpdateChunkIFinstance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values. Collection elements and entries will be added, not replaced.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
setId
Initializes the value for theidattribute.- Parameters:
id- The value for id- Returns:
thisbuilder for use in a chained invocation
-
setTitle
Initializes the value for thetitleattribute.- Parameters:
title- The value for title- Returns:
thisbuilder for use in a chained invocation
-
setStatus
Initializes the optional valuestatusto status.- Parameters:
status- The value for status,nullis accepted asjava.util.Optional.empty()- Returns:
thisbuilder for chained invocation
-
setStatus
Initializes the optional valuestatusto status.- Parameters:
status- The value for status- Returns:
thisbuilder for use in a chained invocation
-
setDetails
Initializes the optional valuedetailsto details.- Parameters:
details- The value for details,nullis accepted asjava.util.Optional.empty()- Returns:
thisbuilder for chained invocation
-
setDetails
Initializes the optional valuedetailsto details.- Parameters:
details- The value for details- Returns:
thisbuilder for use in a chained invocation
-
setOutput
Initializes the optional valueoutputto output.- Parameters:
output- The value for output,nullis accepted asjava.util.Optional.empty()- Returns:
thisbuilder for chained invocation
-
setOutput
Initializes the optional valueoutputto output.- Parameters:
output- The value for output- Returns:
thisbuilder for use in a chained invocation
-
addSources
Adds one element tosourceslist.- Parameters:
element- A sources element- Returns:
thisbuilder for use in a chained invocation
-
addSources
Adds elements tosourceslist.- Parameters:
elements- An array of sources elements- Returns:
thisbuilder for use in a chained invocation
-
setSources
Sets or replaces all elements forsourceslist.- Parameters:
elements- An iterable of sources elements- Returns:
thisbuilder for use in a chained invocation
-
addAllSources
Adds elements tosourceslist.- Parameters:
elements- An iterable of sources elements- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newTaskUpdateChunk.- Returns:
- An immutable instance of TaskUpdateChunk
- Throws:
com.hubspot.immutables.validation.InvalidImmutableStateException- if any required attributes are missing
-