Class FilesUploadParams.Builder
java.lang.Object
com.hubspot.slack.client.methods.params.files.FilesUploadParams.Builder
- Enclosing class:
FilesUploadParams
@Generated(from="FilesUploadParamsIF",
generator="Immutables")
@NotThreadSafe
public static final class FilesUploadParams.Builder
extends Object
Builds instances of type
FilesUploadParams.
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 TypeMethodDescriptionaddAllChannels(Iterable<String> elements) Adds elements tochannelslist.addChannels(String element) Adds one element tochannelslist.addChannels(String... elements) Adds elements tochannelslist.build()Builds a newFilesUploadParams.from(FilesUploadParamsIF instance) Fill a builder with attribute values from the providedFilesUploadParamsIFinstance.setChannels(Iterable<String> elements) Sets or replaces all elements forchannelslist.setContent(String content) Initializes the optional valuecontentto content.setContent(Optional<String> content) Initializes the optional valuecontentto content.Initializes the optional valuefileto file.Initializes the optional valuefileto file.setFilename(String filename) Initializes the optional valuefilenameto filename.setFilename(Optional<String> filename) Initializes the optional valuefilenameto filename.setFiletype(SlackFileType filetype) Initializes the optional valuefiletypeto filetype.setFiletype(Optional<? extends SlackFileType> filetype) Initializes the optional valuefiletypeto filetype.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.Initializes the optional valuetitleto title.Initializes the optional valuetitleto title.
-
Method Details
-
from
Fill a builder with attribute values from the providedFilesUploadParamsIFinstance. 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
-
addChannels
Adds one element tochannelslist.- Parameters:
element- A channels element- Returns:
thisbuilder for use in a chained invocation
-
addChannels
Adds elements tochannelslist.- Parameters:
elements- An array of channels elements- Returns:
thisbuilder for use in a chained invocation
-
setChannels
Sets or replaces all elements forchannelslist.- Parameters:
elements- An iterable of channels elements- Returns:
thisbuilder for use in a chained invocation
-
addAllChannels
Adds elements tochannelslist.- Parameters:
elements- An iterable of channels elements- Returns:
thisbuilder for use in a chained invocation
-
setContent
Initializes the optional valuecontentto content.- Parameters:
content- The value for content,nullis accepted asjava.util.Optional.empty()- Returns:
thisbuilder for chained invocation
-
setContent
Initializes the optional valuecontentto content.- Parameters:
content- The value for content- Returns:
thisbuilder for use in a chained invocation
-
setFile
Initializes the optional valuefileto file.- Parameters:
file- The value for file,nullis accepted asjava.util.Optional.empty()- Returns:
thisbuilder for chained invocation
-
setFile
Initializes the optional valuefileto file.- Parameters:
file- The value for file- Returns:
thisbuilder for use in a chained invocation
-
setFilename
Initializes the optional valuefilenameto filename.- Parameters:
filename- The value for filename,nullis accepted asjava.util.Optional.empty()- Returns:
thisbuilder for chained invocation
-
setFilename
Initializes the optional valuefilenameto filename.- Parameters:
filename- The value for filename- Returns:
thisbuilder for use in a chained invocation
-
setFiletype
Initializes the optional valuefiletypeto filetype.- Parameters:
filetype- The value for filetype,nullis accepted asjava.util.Optional.empty()- Returns:
thisbuilder for chained invocation
-
setFiletype
Initializes the optional valuefiletypeto filetype.- Parameters:
filetype- The value for filetype- Returns:
thisbuilder for use in a chained invocation
-
setInitialComment
Initializes the optional valueinitialCommentto initialComment.- Parameters:
initialComment- The value for initialComment,nullis accepted asjava.util.Optional.empty()- Returns:
thisbuilder for chained invocation
-
setInitialComment
Initializes the optional valueinitialCommentto initialComment.- Parameters:
initialComment- The value for initialComment- 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
-
setTitle
Initializes the optional valuetitleto title.- Parameters:
title- The value for title,nullis accepted asjava.util.Optional.empty()- Returns:
thisbuilder for chained invocation
-
setTitle
Initializes the optional valuetitleto title.- Parameters:
title- The value for title- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newFilesUploadParams.- Returns:
- An immutable instance of FilesUploadParams
- Throws:
com.hubspot.immutables.validation.InvalidImmutableStateException- if any required attributes are missing
-