Class ChatUnfurlParams
java.lang.Object
com.hubspot.slack.client.methods.params.chat.ChatUnfurlParams
- All Implemented Interfaces:
HasChannel,ChatUnfurlParamsIF
@Generated(from="ChatUnfurlParamsIF",
generator="Immutables")
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
public final class ChatUnfurlParams
extends Object
implements ChatUnfurlParamsIF
Immutable implementation of
ChatUnfurlParamsIF.
Use the builder to create immutable instances:
ChatUnfurlParams.builder().
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic ChatUnfurlParams.Builderbuilder()Creates a builder forChatUnfurlParams.static ChatUnfurlParamscopyOf(ChatUnfurlParamsIF instance) Creates an immutable copy of aChatUnfurlParamsIFvalue.booleanThis instance is equal to all instances ofChatUnfurlParamsthat have equal attribute values.getTs()inthashCode()Computes a hash code from attributes:channelId,ts,unfurls,isUserAuthRequired,userAuthMessage,userAuthUrl,metadata.toString()Prints the immutable valueChatUnfurlParamswith attribute values.final ChatUnfurlParamswithChannelId(String value) Copy the current immutable object by setting a value for thechannelIdattribute.final ChatUnfurlParamswithIsUserAuthRequired(Boolean value) Copy the current immutable object by setting a present value for the optionalisUserAuthRequiredattribute.final ChatUnfurlParamswithIsUserAuthRequired(Optional<Boolean> optional) Copy the current immutable object by setting an optional value for theisUserAuthRequiredattribute.final ChatUnfurlParamswithMetadata(Metadata value) Copy the current immutable object by setting a present value for the optionalmetadataattribute.final ChatUnfurlParamswithMetadata(Optional<? extends Metadata> optional) Copy the current immutable object by setting an optional value for themetadataattribute.final ChatUnfurlParamsCopy the current immutable object by setting a value for thetsattribute.final ChatUnfurlParamswithUnfurls(Map<String, ? extends ChatUnfurlBlocksOrAttachment> entries) Copy the current immutable object by replacing theunfurlsmap with the specified map.final ChatUnfurlParamswithUserAuthMessage(String value) Copy the current immutable object by setting a present value for the optionaluserAuthMessageattribute.final ChatUnfurlParamswithUserAuthMessage(Optional<String> optional) Copy the current immutable object by setting an optional value for theuserAuthMessageattribute.final ChatUnfurlParamswithUserAuthUrl(URI value) Copy the current immutable object by setting a present value for the optionaluserAuthUrlattribute.final ChatUnfurlParamswithUserAuthUrl(Optional<? extends URI> optional) Copy the current immutable object by setting an optional value for theuserAuthUrlattribute.
-
Method Details
-
getChannelId
- Specified by:
getChannelIdin interfaceChatUnfurlParamsIF- Specified by:
getChannelIdin interfaceHasChannel- Returns:
- The value of the
channelIdattribute
-
getTs
- Specified by:
getTsin interfaceChatUnfurlParamsIF- Returns:
- The value of the
tsattribute
-
getUnfurls
- Specified by:
getUnfurlsin interfaceChatUnfurlParamsIF- Returns:
- The value of the
unfurlsattribute
-
getIsUserAuthRequired
- Specified by:
getIsUserAuthRequiredin interfaceChatUnfurlParamsIF- Returns:
- The value of the
isUserAuthRequiredattribute
-
getUserAuthMessage
- Specified by:
getUserAuthMessagein interfaceChatUnfurlParamsIF- Returns:
- The value of the
userAuthMessageattribute
-
getUserAuthUrl
- Specified by:
getUserAuthUrlin interfaceChatUnfurlParamsIF- Returns:
- The value of the
userAuthUrlattribute
-
getMetadata
- Specified by:
getMetadatain interfaceChatUnfurlParamsIF- Returns:
- The value of the
metadataattribute
-
withChannelId
Copy the current immutable object by setting a value for thechannelIdattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for channelId- Returns:
- A modified copy or the
thisobject
-
withTs
Copy the current immutable object by setting a value for thetsattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for ts- Returns:
- A modified copy or the
thisobject
-
withUnfurls
public final ChatUnfurlParams withUnfurls(Map<String, ? extends ChatUnfurlBlocksOrAttachment> entries) Copy the current immutable object by replacing theunfurlsmap with the specified map. Nulls are not permitted as keys or values. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
entries- The entries to replace the unfurls map- Returns:
- A modified copy or
thisif not changed
-
withIsUserAuthRequired
Copy the current immutable object by setting a present value for the optionalisUserAuthRequiredattribute.- Parameters:
value- The value for isUserAuthRequired,nullis accepted asjava.util.Optional.empty()- Returns:
- A modified copy or
thisif not changed
-
withIsUserAuthRequired
Copy the current immutable object by setting an optional value for theisUserAuthRequiredattribute. An equality check is used on inner value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for isUserAuthRequired- Returns:
- A modified copy or
thisif not changed
-
withUserAuthMessage
Copy the current immutable object by setting a present value for the optionaluserAuthMessageattribute.- Parameters:
value- The value for userAuthMessage,nullis accepted asjava.util.Optional.empty()- Returns:
- A modified copy or
thisif not changed
-
withUserAuthMessage
Copy the current immutable object by setting an optional value for theuserAuthMessageattribute. An equality check is used on inner value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for userAuthMessage- Returns:
- A modified copy or
thisif not changed
-
withUserAuthUrl
Copy the current immutable object by setting a present value for the optionaluserAuthUrlattribute.- Parameters:
value- The value for userAuthUrl,nullis accepted asjava.util.Optional.empty()- Returns:
- A modified copy or
thisif not changed
-
withUserAuthUrl
Copy the current immutable object by setting an optional value for theuserAuthUrlattribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for userAuthUrl- Returns:
- A modified copy or
thisif not changed
-
withMetadata
Copy the current immutable object by setting a present value for the optionalmetadataattribute.- Parameters:
value- The value for metadata,nullis accepted asjava.util.Optional.empty()- Returns:
- A modified copy or
thisif not changed
-
withMetadata
Copy the current immutable object by setting an optional value for themetadataattribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for metadata- Returns:
- A modified copy or
thisif not changed
-
equals
This instance is equal to all instances ofChatUnfurlParamsthat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:channelId,ts,unfurls,isUserAuthRequired,userAuthMessage,userAuthUrl,metadata. -
toString
Prints the immutable valueChatUnfurlParamswith attribute values. -
copyOf
Creates an immutable copy of aChatUnfurlParamsIFvalue. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.- Parameters:
instance- The instance to copy- Returns:
- A copied immutable ChatUnfurlParams instance
-
builder
Creates a builder forChatUnfurlParams.ChatUnfurlParams.builder() .setChannelId(String) // requiredchannelId.setTs(String) // requiredts.putUnfurls|putAllUnfurls(String => com.hubspot.slack.client.models.ChatUnfurlBlocksOrAttachment) //unfurlsmappings .setIsUserAuthRequired(Optional<Boolean>) // optionalisUserAuthRequired.setUserAuthMessage(Optional<String>) // optionaluserAuthMessage.setUserAuthUrl(Optional<java.net.URI>) // optionaluserAuthUrl.setMetadata(Optional<com.hubspot.slack.client.methods.params.chat.workobject.Metadata>) // optionalmetadata.build();- Returns:
- A new ChatUnfurlParams builder
-