Class ViewCheckboxes
java.lang.Object
com.hubspot.slack.client.models.interaction.views.ViewCheckboxes
- All Implemented Interfaces:
ViewCheckboxesIF,ViewInput
@Generated(from="ViewCheckboxesIF",
generator="Immutables")
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
public final class ViewCheckboxes
extends Object
implements ViewCheckboxesIF
Immutable implementation of
ViewCheckboxesIF.
Use the builder to create immutable instances:
ViewCheckboxes.builder().
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic ViewCheckboxes.Builderbuilder()Creates a builder forViewCheckboxes.static ViewCheckboxescopyOf(ViewCheckboxesIF instance) Creates an immutable copy of aViewCheckboxesIFvalue.booleanThis instance is equal to all instances ofViewCheckboxesthat have equal attribute values.getType()inthashCode()Computes a hash code from attributes:type,stringValue,selectedOptions.toString()Prints the immutable valueViewCheckboxeswith attribute values.final ViewCheckboxeswithSelectedOptions(Option... elements) Copy the current immutable object with elements that replace the content ofselectedOptions.final ViewCheckboxeswithSelectedOptions(Iterable<? extends Option> elements) Copy the current immutable object with elements that replace the content ofselectedOptions.final ViewCheckboxeswithStringValue(String value) Copy the current immutable object by setting a present value for the optionalstringValueattribute.final ViewCheckboxeswithStringValue(Optional<String> optional) Copy the current immutable object by setting an optional value for thestringValueattribute.final ViewCheckboxeswithType(ViewInputType value) Copy the current immutable object by setting a value for thetypeattribute.
-
Method Details
-
getType
-
getStringValue
- Specified by:
getStringValuein interfaceViewInput- Returns:
- The value of the
stringValueattribute
-
getSelectedOptions
- Specified by:
getSelectedOptionsin interfaceViewCheckboxesIF- Returns:
- The value of the
selectedOptionsattribute
-
withType
Copy the current immutable object by setting a value for thetypeattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for type- Returns:
- A modified copy or the
thisobject
-
withStringValue
Copy the current immutable object by setting a present value for the optionalstringValueattribute.- Parameters:
value- The value for stringValue,nullis accepted asjava.util.Optional.empty()- Returns:
- A modified copy or
thisif not changed
-
withStringValue
Copy the current immutable object by setting an optional value for thestringValueattribute. An equality check is used on inner value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for stringValue- Returns:
- A modified copy or
thisif not changed
-
withSelectedOptions
Copy the current immutable object with elements that replace the content ofselectedOptions.- Parameters:
elements- The elements to set- Returns:
- A modified copy of
thisobject
-
withSelectedOptions
Copy the current immutable object with elements that replace the content ofselectedOptions. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
elements- An iterable of selectedOptions elements to set- Returns:
- A modified copy or
thisif not changed
-
equals
This instance is equal to all instances ofViewCheckboxesthat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:type,stringValue,selectedOptions. -
toString
Prints the immutable valueViewCheckboxeswith attribute values. -
copyOf
Creates an immutable copy of aViewCheckboxesIFvalue. 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 ViewCheckboxes instance
-
builder
Creates a builder forViewCheckboxes.ViewCheckboxes.builder() .setType(com.hubspot.slack.client.models.interaction.views.ViewInputType) // requiredtype.setStringValue(Optional<String>) // optionalstringValue.addSelectedOptions|addAllSelectedOptions(com.hubspot.slack.client.models.blocks.objects.Option) //selectedOptionselements .build();- Returns:
- A new ViewCheckboxes builder
-