Class CompleteUploadExternalParams.Builder
java.lang.Object
com.hubspot.slack.client.methods.params.files.CompleteUploadExternalParams.Builder
- Enclosing class:
CompleteUploadExternalParams
@Generated(from="CompleteUploadExternalParamsIF",
generator="Immutables")
@NotThreadSafe
public static final class CompleteUploadExternalParams.Builder
extends Object
Builds instances of type
CompleteUploadExternalParams.
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 TypeMethodDescriptionaddAllFiles(Iterable<? extends FileInfo> elements) Adds elements tofileslist.Adds one element tofileslist.Adds elements tofileslist.build()Builds a newCompleteUploadExternalParams.from(CompleteUploadExternalParamsIF instance) Fill a builder with attribute values from the providedCompleteUploadExternalParamsIFinstance.setChannelId(String channelId) Initializes the optional valuechannelIdto channelId.setChannelId(Optional<String> channelId) Initializes the optional valuechannelIdto channelId.Sets or replaces all elements forfileslist.setInitialComment(String initialComment) Initializes the optional valueinitialCommentto initialComment.setInitialComment(Optional<String> initialComment) Initializes the optional valueinitialCommentto initialComment.setThreadTs(String threadTs) Initializes the optional valuethreadTsto threadTs.setThreadTs(Optional<String> threadTs) Initializes the optional valuethreadTsto threadTs.
-
Method Details
-
from
Fill a builder with attribute values from the providedCompleteUploadExternalParamsIFinstance. 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
-
addFiles
Adds one element tofileslist.- Parameters:
element- A files element- Returns:
thisbuilder for use in a chained invocation
-
addFiles
Adds elements tofileslist.- Parameters:
elements- An array of files elements- Returns:
thisbuilder for use in a chained invocation
-
setFiles
Sets or replaces all elements forfileslist.- Parameters:
elements- An iterable of files elements- Returns:
thisbuilder for use in a chained invocation
-
addAllFiles
public final CompleteUploadExternalParams.Builder addAllFiles(Iterable<? extends FileInfo> elements) Adds elements tofileslist.- Parameters:
elements- An iterable of files elements- Returns:
thisbuilder for use in a chained invocation
-
setChannelId
Initializes the optional valuechannelIdto channelId.- Parameters:
channelId- The value for channelId,nullis accepted asjava.util.Optional.empty()- Returns:
thisbuilder for chained invocation
-
setChannelId
Initializes the optional valuechannelIdto channelId.- Parameters:
channelId- The value for channelId- Returns:
thisbuilder for use in a chained invocation
-
setThreadTs
Initializes the optional valuethreadTsto threadTs.- Parameters:
threadTs- The value for threadTs,nullis accepted asjava.util.Optional.empty()- Returns:
thisbuilder for chained invocation
-
setThreadTs
Initializes the optional valuethreadTsto threadTs.- Parameters:
threadTs- The value for threadTs- Returns:
thisbuilder for use in a chained invocation
-
setInitialComment
public final CompleteUploadExternalParams.Builder setInitialComment(@Nullable String initialComment) Initializes the optional valueinitialCommentto initialComment.- Parameters:
initialComment- The value for initialComment,nullis accepted asjava.util.Optional.empty()- Returns:
thisbuilder for chained invocation
-
setInitialComment
public final CompleteUploadExternalParams.Builder setInitialComment(Optional<String> initialComment) Initializes the optional valueinitialCommentto initialComment.- Parameters:
initialComment- The value for initialComment- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newCompleteUploadExternalParams.- Returns:
- An immutable instance of CompleteUploadExternalParams
- Throws:
com.hubspot.immutables.validation.InvalidImmutableStateException- if any required attributes are missing
-