Package io.thestencil.client.api
Class ImmutableWorkflowMutator
- java.lang.Object
-
- io.thestencil.client.api.ImmutableWorkflowMutator
-
- All Implemented Interfaces:
UpdateBuilder.WorkflowMutator
@ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable @CheckReturnValue public final class ImmutableWorkflowMutator extends Object implements UpdateBuilder.WorkflowMutator
Immutable implementation ofUpdateBuilder.WorkflowMutator.Use the builder to create immutable instances:
ImmutableWorkflowMutator.builder().
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classImmutableWorkflowMutator.BuilderBuilds instances of typeImmutableWorkflowMutator.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ImmutableWorkflowMutator.Builderbuilder()Creates a builder forImmutableWorkflowMutator.static ImmutableWorkflowMutatorcopyOf(UpdateBuilder.WorkflowMutator instance)Creates an immutable copy of aUpdateBuilder.WorkflowMutatorvalue.booleanequals(Object another)This instance is equal to all instances ofImmutableWorkflowMutatorthat have equal attribute values.com.google.common.collect.ImmutableList<String>getArticles()BooleangetDevMode()com.google.common.collect.ImmutableList<StencilClient.LocaleLabel>getLabels()StringgetValue()StringgetWorkflowId()inthashCode()Computes a hash code from attributes:workflowId,value,labels,articles,devMode.StringtoString()Prints the immutable valueWorkflowMutatorwith attribute values.ImmutableWorkflowMutatorwithArticles(Iterable<String> elements)Copy the current immutable object with elements that replace the content ofarticles.ImmutableWorkflowMutatorwithArticles(String... elements)Copy the current immutable object with elements that replace the content ofarticles.ImmutableWorkflowMutatorwithDevMode(Boolean value)Copy the current immutable object by setting a value for thedevModeattribute.ImmutableWorkflowMutatorwithLabels(StencilClient.LocaleLabel... elements)Copy the current immutable object with elements that replace the content oflabels.ImmutableWorkflowMutatorwithLabels(Iterable<? extends StencilClient.LocaleLabel> elements)Copy the current immutable object with elements that replace the content oflabels.ImmutableWorkflowMutatorwithValue(String value)Copy the current immutable object by setting a value for thevalueattribute.ImmutableWorkflowMutatorwithWorkflowId(String value)Copy the current immutable object by setting a value for theworkflowIdattribute.
-
-
-
Method Detail
-
getWorkflowId
public String getWorkflowId()
- Specified by:
getWorkflowIdin interfaceUpdateBuilder.WorkflowMutator- Returns:
- The value of the
workflowIdattribute
-
getValue
public String getValue()
- Specified by:
getValuein interfaceUpdateBuilder.WorkflowMutator- Returns:
- The value of the
valueattribute
-
getLabels
@Nullable public com.google.common.collect.ImmutableList<StencilClient.LocaleLabel> getLabels()
- Specified by:
getLabelsin interfaceUpdateBuilder.WorkflowMutator- Returns:
- The value of the
labelsattribute
-
getArticles
@Nullable public com.google.common.collect.ImmutableList<String> getArticles()
- Specified by:
getArticlesin interfaceUpdateBuilder.WorkflowMutator- Returns:
- The value of the
articlesattribute
-
getDevMode
@Nullable public Boolean getDevMode()
- Specified by:
getDevModein interfaceUpdateBuilder.WorkflowMutator- Returns:
- The value of the
devModeattribute
-
withWorkflowId
public final ImmutableWorkflowMutator withWorkflowId(String value)
Copy the current immutable object by setting a value for theworkflowIdattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for workflowId- Returns:
- A modified copy of the
thisobject
-
withValue
public final ImmutableWorkflowMutator withValue(String value)
Copy the current immutable object by setting a value for thevalueattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for value- Returns:
- A modified copy of the
thisobject
-
withLabels
public final ImmutableWorkflowMutator withLabels(@Nullable StencilClient.LocaleLabel... elements)
Copy the current immutable object with elements that replace the content oflabels.- Parameters:
elements- The elements to set- Returns:
- A modified copy of
thisobject
-
withLabels
public final ImmutableWorkflowMutator withLabels(@Nullable Iterable<? extends StencilClient.LocaleLabel> elements)
Copy the current immutable object with elements that replace the content oflabels. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
elements- An iterable of labels elements to set- Returns:
- A modified copy of
thisobject
-
withArticles
public final ImmutableWorkflowMutator withArticles(@Nullable String... elements)
Copy the current immutable object with elements that replace the content ofarticles.- Parameters:
elements- The elements to set- Returns:
- A modified copy of
thisobject
-
withArticles
public final ImmutableWorkflowMutator withArticles(@Nullable Iterable<String> elements)
Copy the current immutable object with elements that replace the content ofarticles. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
elements- An iterable of articles elements to set- Returns:
- A modified copy of
thisobject
-
withDevMode
public final ImmutableWorkflowMutator withDevMode(@Nullable Boolean value)
Copy the current immutable object by setting a value for thedevModeattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for devMode (can benull)- Returns:
- A modified copy of the
thisobject
-
equals
public boolean equals(@Nullable Object another)This instance is equal to all instances ofImmutableWorkflowMutatorthat have equal attribute values.
-
hashCode
public int hashCode()
Computes a hash code from attributes:workflowId,value,labels,articles,devMode.
-
toString
public String toString()
Prints the immutable valueWorkflowMutatorwith attribute values.
-
copyOf
public static ImmutableWorkflowMutator copyOf(UpdateBuilder.WorkflowMutator instance)
Creates an immutable copy of aUpdateBuilder.WorkflowMutatorvalue. 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 WorkflowMutator instance
-
builder
public static ImmutableWorkflowMutator.Builder builder()
Creates a builder forImmutableWorkflowMutator.ImmutableWorkflowMutator.builder() .workflowId(String) // requiredworkflowId.value(String) // requiredvalue.labels(List<io.thestencil.client.api.StencilClient.LocaleLabel> | null) // nullablelabels.articles(List<String> | null) // nullablearticles.devMode(Boolean | null) // nullabledevMode.build();- Returns:
- A new ImmutableWorkflowMutator builder
-
-