Class StateBlock.Builder
java.lang.Object
com.hubspot.slack.client.models.response.views.StateBlock.Builder
- Enclosing class:
StateBlock
@Generated(from="StateBlockIF",
generator="Immutables")
@NotThreadSafe
public static final class StateBlock.Builder
extends Object
Builds instances of type
StateBlock.
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 TypeMethodDescriptionbuild()Builds a newStateBlock.final StateBlock.Builderfrom(StateBlockIF instance) Fill a builder with attribute values from the providedStateBlockIFinstance.final StateBlock.BuilderputActions(String key, StateAction value) Put one entry to theactionsmap.final StateBlock.BuilderputActions(Map.Entry<String, ? extends StateAction> entry) Put one entry to theactionsmap.final StateBlock.BuilderputAllActions(Map<String, ? extends StateAction> entries) Put all mappings from the specified map as entries toactionsmap.final StateBlock.BuildersetActions(Map<String, ? extends StateAction> entries) Sets or replaces all mappings from the specified map as entries for theactionsmap.
-
Method Details
-
from
Fill a builder with attribute values from the providedStateBlockIFinstance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values. Collection elements and entries will be added, not replaced.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
putActions
Put one entry to theactionsmap.- Parameters:
key- The key in the actions mapvalue- The associated value in the actions map- Returns:
thisbuilder for use in a chained invocation
-
putActions
Put one entry to theactionsmap. Nulls are not permitted- Parameters:
entry- The key and value entry- Returns:
thisbuilder for use in a chained invocation
-
setActions
Sets or replaces all mappings from the specified map as entries for theactionsmap. Nulls are not permitted- Parameters:
entries- The entries that will be added to the actions map- Returns:
thisbuilder for use in a chained invocation
-
putAllActions
Put all mappings from the specified map as entries toactionsmap. Nulls are not permitted- Parameters:
entries- The entries that will be added to the actions map- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newStateBlock.- Returns:
- An immutable instance of StateBlock
- Throws:
com.hubspot.immutables.validation.InvalidImmutableStateException- if any required attributes are missing
-