Class SlackLinkSharedEvent.Builder
java.lang.Object
com.hubspot.slack.client.models.events.links.SlackLinkSharedEvent.Builder
- Enclosing class:
SlackLinkSharedEvent
@Generated(from="SlackLinkSharedEventIF",
generator="Immutables")
@NotThreadSafe
public static final class SlackLinkSharedEvent.Builder
extends Object
Builds instances of type
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.
-
Method Summary
Modifier and TypeMethodDescriptionaddAllLinks(Iterable<? extends Link> elements) Adds elements tolinkslist.Adds one element tolinkslist.Adds elements tolinkslist.build()Builds a newSlackLinkSharedEvent.from(SlackLinkSharedEventIF instance) Fill a builder with attribute values from the providedcom.hubspot.slack.client.models.events.links.SlackLinkSharedEventIFinstance.from(SlackEvent instance) Fill a builder with attribute values from the providedcom.hubspot.slack.client.models.events.SlackEventinstance.setChannelId(String channelId) Initializes the value for thechannelIdattribute.Sets or replaces all elements forlinkslist.setMessageTs(String messageTs) Initializes the value for themessageTsattribute.setThreadTs(String threadTs) Initializes the optional valuethreadTsto threadTs.setThreadTs(Optional<String> threadTs) Initializes the optional valuethreadTsto threadTs.setType(SlackEventType type) Initializes the value for thetypeattribute.Initializes the value for theuserIdattribute.
-
Method Details
-
from
Fill a builder with attribute values from the providedcom.hubspot.slack.client.models.events.SlackEventinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
setType
Initializes the value for thetypeattribute.- Parameters:
type- The value for type- Returns:
thisbuilder for use in a chained invocation
-
setChannelId
Initializes the value for thechannelIdattribute.- Parameters:
channelId- The value for channelId- Returns:
thisbuilder for use in a chained invocation
-
setUserId
Initializes the value for theuserIdattribute.- Parameters:
userId- The value for userId- Returns:
thisbuilder for use in a chained invocation
-
setMessageTs
Initializes the value for themessageTsattribute.- Parameters:
messageTs- The value for messageTs- 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
-
addLinks
Adds one element tolinkslist.- Parameters:
element- A links element- Returns:
thisbuilder for use in a chained invocation
-
addLinks
Adds elements tolinkslist.- Parameters:
elements- An array of links elements- Returns:
thisbuilder for use in a chained invocation
-
setLinks
Sets or replaces all elements forlinkslist.- Parameters:
elements- An iterable of links elements- Returns:
thisbuilder for use in a chained invocation
-
addAllLinks
Adds elements tolinkslist.- Parameters:
elements- An iterable of links elements- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newSlackLinkSharedEvent.- Returns:
- An immutable instance of SlackLinkSharedEvent
- Throws:
com.hubspot.immutables.validation.InvalidImmutableStateException- if any required attributes are missing
-