@ParametersAreNonnullByDefault @Generated(value="org.immutables.processor.ProxyProcessor") @Immutable @CheckReturnValue public final class ImmutableRelated<T,B> extends Related<T,B>
Related.
Use the builder to create immutable instances:
ImmutableRelated.builder().
Use the static factory method to create immutable instances:
ImmutableRelated.of().
| Modifier and Type | Class and Description |
|---|---|
static class |
ImmutableRelated.Builder<T,B>
Builds instances of type
ImmutableRelated. |
| Modifier and Type | Method and Description |
|---|---|
static <T,B> ImmutableRelated.Builder<T,B> |
builder()
Creates a builder for
ImmutableRelated. |
static <T,B> ImmutableRelated<T,B> |
copyOf(Related<T,B> instance)
Creates an immutable copy of a
Related value. |
protected Value<T> |
destination() |
boolean |
equals(Object another)
This instance is equal to all instances of
ImmutableRelated that have equal attribute values. |
int |
hashCode()
Computes a hash code from attributes:
destination, reference. |
static <T,B> ImmutableRelated<T,B> |
of(Value<T> destination,
B reference)
Construct a new immutable
Related instance. |
protected B |
reference() |
String |
toString()
Prints the immutable value
Related with attribute values. |
ImmutableRelated<T,B> |
withDestination(Value<T> value)
Copy the current immutable object by setting a value for the
destination attribute. |
ImmutableRelated<T,B> |
withReference(B value)
Copy the current immutable object by setting a value for the
reference attribute. |
asHumanReadable, toclone, finalize, getClass, notify, notifyAll, wait, wait, waitnamed, ofType, relatedTo, unvalidatedasHumanReadableprotected Value<T> destination()
destination in class Related<T,B>destination attributeprotected B reference()
public final ImmutableRelated<T,B> withDestination(Value<T> value)
destination attribute.
A shallow reference equality check is used to prevent copying of the same value by returning this.value - A new value for destinationthis objectpublic final ImmutableRelated<T,B> withReference(B value)
reference attribute.
A shallow reference equality check is used to prevent copying of the same value by returning this.value - A new value for referencethis objectpublic boolean equals(@Nullable Object another)
ImmutableRelated that have equal attribute values.public int hashCode()
destination, reference.public String toString()
Related with attribute values.public static <T,B> ImmutableRelated<T,B> of(Value<T> destination, B reference)
Related instance.T - generic parameter TB - generic parameter Bdestination - The value for the destination attributereference - The value for the reference attributepublic static <T,B> ImmutableRelated<T,B> copyOf(Related<T,B> instance)
Related value.
Uses accessors to get values to initialize the new immutable instance.
If an instance is already immutable, it is returned as is.T - generic parameter TB - generic parameter Binstance - The instance to copypublic static <T,B> ImmutableRelated.Builder<T,B> builder()
ImmutableRelated.
ImmutableRelated.<T, B>builder()
.destination(de.flapdoodle.formula.Value<T>) // required destination
.reference(B) // required reference
.build();
T - generic parameter TB - generic parameter BCopyright © 2023. All rights reserved.