Package io.dialob.api.form
Class ImmutableFormValueSet
- java.lang.Object
-
- io.dialob.api.form.ImmutableFormValueSet
-
- All Implemented Interfaces:
FormValueSet,Serializable
@ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable public final class ImmutableFormValueSet extends Object implements FormValueSet
Immutable implementation ofFormValueSet.Use the builder to create immutable instances:
ImmutableFormValueSet.builder().- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classImmutableFormValueSet.BuilderBuilds instances of typeImmutableFormValueSet.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ImmutableFormValueSet.Builderbuilder()Creates a builder forImmutableFormValueSet.static ImmutableFormValueSetcopyOf(FormValueSet instance)Creates an immutable copy of aFormValueSetvalue.booleanequals(Object another)This instance is equal to all instances ofImmutableFormValueSetthat have equal attribute values.Map<String,Object>getAdditionalProperties()List<FormValueSetEntry>getEntries()StringgetId()inthashCode()Computes a hash code from attributes:id,entries,additionalProperties.StringtoString()Prints the immutable valueFormValueSetwith attribute values.ImmutableFormValueSetwithAdditionalProperties(Map<String,? extends Object> entries)Copy the current immutable object by replacing theadditionalPropertiesmap with the specified map.ImmutableFormValueSetwithEntries(FormValueSetEntry... elements)Copy the current immutable object with elements that replace the content ofentries.ImmutableFormValueSetwithEntries(Iterable<? extends FormValueSetEntry> elements)Copy the current immutable object with elements that replace the content ofentries.ImmutableFormValueSetwithId(String value)Copy the current immutable object by setting a value for theidattribute.
-
-
-
Method Detail
-
getId
public String getId()
- Specified by:
getIdin interfaceFormValueSet- Returns:
- The value of the
idattribute
-
getEntries
public List<FormValueSetEntry> getEntries()
- Specified by:
getEntriesin interfaceFormValueSet- Returns:
- The value of the
entriesattribute
-
getAdditionalProperties
public Map<String,Object> getAdditionalProperties()
- Specified by:
getAdditionalPropertiesin interfaceFormValueSet- Returns:
- The value of the
additionalPropertiesattribute
-
withId
public final ImmutableFormValueSet withId(String value)
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 (can benull)- Returns:
- A modified copy of the
thisobject
-
withEntries
public final ImmutableFormValueSet withEntries(FormValueSetEntry... elements)
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
public final ImmutableFormValueSet withEntries(Iterable<? extends FormValueSetEntry> elements)
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 of
thisobject
-
withAdditionalProperties
public final ImmutableFormValueSet withAdditionalProperties(Map<String,? extends Object> entries)
Copy the current immutable object by replacing theadditionalPropertiesmap with the specified map. Nulls are not permitted as keys or values. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
entries- The entries to be added to the additionalProperties map- Returns:
- A modified copy of
thisobject
-
equals
public boolean equals(@Nullable Object another)This instance is equal to all instances ofImmutableFormValueSetthat have equal attribute values.
-
hashCode
public int hashCode()
Computes a hash code from attributes:id,entries,additionalProperties.
-
toString
public String toString()
Prints the immutable valueFormValueSetwith attribute values.
-
copyOf
public static ImmutableFormValueSet copyOf(FormValueSet instance)
Creates an immutable copy of aFormValueSetvalue. 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 FormValueSet instance
-
builder
public static ImmutableFormValueSet.Builder builder()
Creates a builder forImmutableFormValueSet.ImmutableFormValueSet.builder() .id(String | null) // nullableid.addEntries|addAllEntries(io.dialob.api.form.FormValueSetEntry) //entrieselements .putAdditionalProperties|putAllAdditionalProperties(String => Object) //additionalPropertiesmappings .build();- Returns:
- A new ImmutableFormValueSet builder
-
-