Class UserSelectMenu
java.lang.Object
com.hubspot.slack.client.models.blocks.elements.UserSelectMenu
- All Implemented Interfaces:
BlockElement,HasActionId,UserSelectMenuIF
@Generated(from="UserSelectMenuIF",
generator="Immutables")
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
public final class UserSelectMenu
extends Object
implements UserSelectMenuIF
Immutable implementation of
UserSelectMenuIF.
Use the builder to create immutable instances:
UserSelectMenu.builder().
Use the static factory method to create immutable instances:
UserSelectMenu.of().
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from interface com.hubspot.slack.client.models.blocks.elements.UserSelectMenuIF
TYPE -
Method Summary
Modifier and TypeMethodDescriptionstatic UserSelectMenu.Builderbuilder()Creates a builder forUserSelectMenu.static UserSelectMenucopyOf(UserSelectMenuIF instance) Creates an immutable copy of aUserSelectMenuIFvalue.booleanThis instance is equal to all instances ofUserSelectMenuthat have equal attribute values.getType()inthashCode()Computes a hash code from attributes:type,placeholder,actionId,initialUserId,confirmationDialog.static UserSelectMenuConstruct a new immutableUserSelectMenuinstance.toString()Prints the immutable valueUserSelectMenuwith attribute values.final UserSelectMenuwithActionId(String value) Copy the current immutable object by setting a value for theactionIdattribute.final UserSelectMenuCopy the current immutable object by setting a present value for the optionalconfirmationDialogattribute.final UserSelectMenuwithConfirmationDialog(Optional<? extends ConfirmationDialog> optional) Copy the current immutable object by setting an optional value for theconfirmationDialogattribute.final UserSelectMenuwithInitialUserId(String value) Copy the current immutable object by setting a present value for the optionalinitialUserIdattribute.final UserSelectMenuwithInitialUserId(Optional<String> optional) Copy the current immutable object by setting an optional value for theinitialUserIdattribute.final UserSelectMenuwithPlaceholder(Text value) Copy the current immutable object by setting a value for theplaceholderattribute.
-
Method Details
-
getType
- Specified by:
getTypein interfaceBlockElement- Specified by:
getTypein interfaceUserSelectMenuIF- Returns:
- The computed-at-construction value of the
typeattribute
-
getPlaceholder
- Specified by:
getPlaceholderin interfaceUserSelectMenuIF- Returns:
- The value of the
placeholderattribute
-
getActionId
- Specified by:
getActionIdin interfaceHasActionId- Specified by:
getActionIdin interfaceUserSelectMenuIF- Returns:
- The value of the
actionIdattribute
-
getInitialUserId
- Specified by:
getInitialUserIdin interfaceUserSelectMenuIF- Returns:
- The value of the
initialUserIdattribute
-
getConfirmationDialog
- Specified by:
getConfirmationDialogin interfaceUserSelectMenuIF- Returns:
- The value of the
confirmationDialogattribute
-
withPlaceholder
Copy the current immutable object by setting a value for theplaceholderattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for placeholder- Returns:
- A modified copy or the
thisobject
-
withActionId
Copy the current immutable object by setting a value for theactionIdattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for actionId- Returns:
- A modified copy or the
thisobject
-
withInitialUserId
Copy the current immutable object by setting a present value for the optionalinitialUserIdattribute.- Parameters:
value- The value for initialUserId,nullis accepted asjava.util.Optional.empty()- Returns:
- A modified copy or
thisif not changed
-
withInitialUserId
Copy the current immutable object by setting an optional value for theinitialUserIdattribute. An equality check is used on inner value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for initialUserId- Returns:
- A modified copy or
thisif not changed
-
withConfirmationDialog
Copy the current immutable object by setting a present value for the optionalconfirmationDialogattribute.- Parameters:
value- The value for confirmationDialog,nullis accepted asjava.util.Optional.empty()- Returns:
- A modified copy or
thisif not changed
-
withConfirmationDialog
Copy the current immutable object by setting an optional value for theconfirmationDialogattribute. 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 confirmationDialog- Returns:
- A modified copy or
thisif not changed
-
equals
This instance is equal to all instances ofUserSelectMenuthat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:type,placeholder,actionId,initialUserId,confirmationDialog. -
toString
Prints the immutable valueUserSelectMenuwith attribute values. -
of
Construct a new immutableUserSelectMenuinstance.- Parameters:
placeholder- The value for theplaceholderattributeactionId- The value for theactionIdattribute- Returns:
- An immutable UserSelectMenu instance
-
copyOf
Creates an immutable copy of aUserSelectMenuIFvalue. 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 UserSelectMenu instance
-
builder
Creates a builder forUserSelectMenu.UserSelectMenu.builder() .setPlaceholder(com.hubspot.slack.client.models.blocks.objects.Text) // requiredplaceholder.setActionId(String) // requiredactionId.setInitialUserId(Optional<String>) // optionalinitialUserId.setConfirmationDialog(Optional<com.hubspot.slack.client.models.blocks.objects.ConfirmationDialog>) // optionalconfirmationDialog.build();- Returns:
- A new UserSelectMenu builder
-