@NotThreadSafe public static final class SlackLinkSharedEvent.Builder extends Object
SlackLinkSharedEvent.
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.
| Modifier and Type | Method and Description |
|---|---|
SlackLinkSharedEvent.Builder |
addAllLinks(Iterable<? extends Link> elements)
Adds elements to
links list. |
SlackLinkSharedEvent.Builder |
addLinks(Link... elements)
Adds elements to
links list. |
SlackLinkSharedEvent.Builder |
addLinks(Link element)
Adds one element to
links list. |
SlackLinkSharedEvent |
build()
Builds a new
SlackLinkSharedEvent. |
SlackLinkSharedEvent.Builder |
from(SlackEvent instance)
Fill a builder with attribute values from the provided
com.hubspot.slack.client.models.events.SlackEvent instance. |
SlackLinkSharedEvent.Builder |
from(SlackLinkSharedEventIF instance)
Fill a builder with attribute values from the provided
com.hubspot.slack.client.models.events.links.SlackLinkSharedEventIF instance. |
SlackLinkSharedEvent.Builder |
setChannelId(String channelId)
Initializes the value for the
channelId attribute. |
SlackLinkSharedEvent.Builder |
setLinks(Iterable<? extends Link> elements)
Sets or replaces all elements for
links list. |
SlackLinkSharedEvent.Builder |
setMessageTs(String messageTs)
Initializes the value for the
messageTs attribute. |
SlackLinkSharedEvent.Builder |
setThreadTs(Optional<String> threadTs)
Initializes the optional value
threadTs to threadTs. |
SlackLinkSharedEvent.Builder |
setThreadTs(String threadTs)
Initializes the optional value
threadTs to threadTs. |
SlackLinkSharedEvent.Builder |
setType(SlackEventType type)
Initializes the value for the
type attribute. |
SlackLinkSharedEvent.Builder |
setUserId(String userId)
Initializes the value for the
userId attribute. |
public final SlackLinkSharedEvent.Builder from(SlackLinkSharedEventIF instance)
com.hubspot.slack.client.models.events.links.SlackLinkSharedEventIF instance.instance - The instance from which to copy valuesthis builder for use in a chained invocationpublic final SlackLinkSharedEvent.Builder from(SlackEvent instance)
com.hubspot.slack.client.models.events.SlackEvent instance.instance - The instance from which to copy valuesthis builder for use in a chained invocationpublic final SlackLinkSharedEvent.Builder setChannelId(String channelId)
channelId attribute.channelId - The value for channelIdthis builder for use in a chained invocationpublic final SlackLinkSharedEvent.Builder setUserId(String userId)
userId attribute.userId - The value for userIdthis builder for use in a chained invocationpublic final SlackLinkSharedEvent.Builder setMessageTs(String messageTs)
messageTs attribute.messageTs - The value for messageTsthis builder for use in a chained invocationpublic final SlackLinkSharedEvent.Builder setThreadTs(@Nullable String threadTs)
threadTs to threadTs.threadTs - The value for threadTs, null is accepted as java.util.Optional.empty()this builder for chained invocationpublic final SlackLinkSharedEvent.Builder setThreadTs(Optional<String> threadTs)
threadTs to threadTs.threadTs - The value for threadTsthis builder for use in a chained invocationpublic final SlackLinkSharedEvent.Builder addLinks(Link element)
links list.element - A links elementthis builder for use in a chained invocationpublic final SlackLinkSharedEvent.Builder addLinks(Link... elements)
links list.elements - An array of links elementsthis builder for use in a chained invocationpublic final SlackLinkSharedEvent.Builder setLinks(Iterable<? extends Link> elements)
links list.elements - An iterable of links elementsthis builder for use in a chained invocationpublic final SlackLinkSharedEvent.Builder addAllLinks(Iterable<? extends Link> elements)
links list.elements - An iterable of links elementsthis builder for use in a chained invocationpublic final SlackLinkSharedEvent.Builder setType(SlackEventType type)
type attribute.type - The value for typethis builder for use in a chained invocationpublic SlackLinkSharedEvent build() throws com.hubspot.immutables.validation.InvalidImmutableStateException
SlackLinkSharedEvent.com.hubspot.immutables.validation.InvalidImmutableStateException - if any required attributes are missingCopyright © 2020. All rights reserved.