Package io.dialob.api.proto
Class ImmutableValueSetEntry
java.lang.Object
io.dialob.api.proto.ImmutableValueSetEntry
- All Implemented Interfaces:
ValueSetEntry,Serializable
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
public final class ImmutableValueSetEntry
extends Object
implements ValueSetEntry
Immutable implementation of
ValueSetEntry.
Use the builder to create immutable instances:
ImmutableValueSetEntry.builder().
Use the static factory method to create immutable instances:
ImmutableValueSetEntry.of().
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilds instances of typeImmutableValueSetEntry. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Creates a builder forImmutableValueSetEntry.static ImmutableValueSetEntrycopyOf(ValueSetEntry instance) Creates an immutable copy of aValueSetEntryvalue.booleanThis instance is equal to all instances ofImmutableValueSetEntrythat have equal attribute values.getKey()getValue()inthashCode()Computes a hash code from attributes:key,value.static ImmutableValueSetEntryConstruct a new immutableValueSetEntryinstance.toString()Prints the immutable valueValueSetEntrywith attribute values.final ImmutableValueSetEntryCopy the current immutable object by setting a value for thekeyattribute.final ImmutableValueSetEntryCopy the current immutable object by setting a value for thevalueattribute.
-
Method Details
-
getKey
- Specified by:
getKeyin interfaceValueSetEntry- Returns:
- The value of the
keyattribute
-
getValue
- Specified by:
getValuein interfaceValueSetEntry- Returns:
- The value of the
valueattribute
-
withKey
Copy the current immutable object by setting a value for thekeyattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for key- Returns:
- A modified copy of the
thisobject
-
withValue
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 (can benull)- Returns:
- A modified copy of the
thisobject
-
equals
This instance is equal to all instances ofImmutableValueSetEntrythat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:key,value. -
toString
Prints the immutable valueValueSetEntrywith attribute values. -
of
Construct a new immutableValueSetEntryinstance.- Parameters:
key- The value for thekeyattributevalue- The value for thevalueattribute- Returns:
- An immutable ValueSetEntry instance
-
copyOf
Creates an immutable copy of aValueSetEntryvalue. 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 ValueSetEntry instance
-
builder
Creates a builder forImmutableValueSetEntry.ImmutableValueSetEntry.builder() .key(String) // requiredkey.value(String | null) // nullablevalue.build();- Returns:
- A new ImmutableValueSetEntry builder
-