Class ImmutableValueSet
java.lang.Object
io.dialob.session.engine.program.model.ImmutableValueSet
- All Implemented Interfaces:
ProgramNode,ValueSet,Serializable
@Generated(from="ValueSet",
generator="Immutables")
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
@CheckReturnValue
public final class ImmutableValueSet
extends Object
implements ValueSet
Immutable implementation of
ValueSet.
Use the builder to create immutable instances:
ImmutableValueSet.builder().
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilds instances of typeImmutableValueSet.static final classImmutable implementation ofValueSet.Entry. -
Method Summary
Modifier and TypeMethodDescriptionstatic ImmutableValueSet.Builderbuilder()Creates a builder forImmutableValueSet.static ImmutableValueSetCreates an immutable copy of aValueSetvalue.booleanThis instance is equal to all instances ofImmutableValueSetthat have equal attribute values.com.google.common.collect.ImmutableList<Value<ValueSet.Entry>> getId()inthashCode()Computes a hash code from attributes:id,entries.toString()Prints the immutable valueValueSetwith attribute values.final ImmutableValueSetwithEntries(Value<ValueSet.Entry>... elements) Copy the current immutable object with elements that replace the content ofentries.final ImmutableValueSetwithEntries(Iterable<? extends Value<ValueSet.Entry>> elements) Copy the current immutable object with elements that replace the content ofentries.final ImmutableValueSetCopy the current immutable object by setting a value for theidattribute.
-
Method Details
-
getId
-
getEntries
- Specified by:
getEntriesin interfaceValueSet- Returns:
- The value of the
entriesattribute
-
withId
Copy the current immutable object by setting a value for theidattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for id- Returns:
- A modified copy or the
thisobject
-
withEntries
Copy the current immutable object with elements that replace the content ofentries.- Parameters:
elements- The elements to set- Returns:
- A modified copy of
thisobject
-
withEntries
Copy the current immutable object with elements that replace the content ofentries. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
elements- An iterable of entries elements to set- Returns:
- A modified copy or
thisif not changed
-
equals
This instance is equal to all instances ofImmutableValueSetthat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:id,entries. -
toString
Prints the immutable valueValueSetwith attribute values. -
copyOf
Creates an immutable copy of aValueSetvalue. 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 ValueSet instance
-
builder
Creates a builder forImmutableValueSet.ImmutableValueSet.builder() .id(String) // requiredid.addEntries|addAllEntries(io.dialob.session.engine.program.model.Value<io.dialob.session.engine.program.model.ValueSet.Entry>) //entrieselements .build();- Returns:
- A new ImmutableValueSet builder
-