Package io.dialob.session.engine.session
Class ImmutableAsyncFunctionCall
java.lang.Object
io.dialob.session.engine.session.ImmutableAsyncFunctionCall
- All Implemented Interfaces:
AsyncFunctionCall
@Generated(from="AsyncFunctionCall",
generator="Immutables")
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
@CheckReturnValue
public final class ImmutableAsyncFunctionCall
extends Object
implements AsyncFunctionCall
Immutable implementation of
AsyncFunctionCall.
Use the builder to create immutable instances:
ImmutableAsyncFunctionCall.builder().
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilds instances of typeImmutableAsyncFunctionCall. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Creates a builder forImmutableAsyncFunctionCall.static ImmutableAsyncFunctionCallcopyOf(AsyncFunctionCall instance) Creates an immutable copy of aAsyncFunctionCallvalue.booleanThis instance is equal to all instances ofImmutableAsyncFunctionCallthat have equal attribute values.Object[]getArgs()getId()inthashCode()Computes a hash code from attributes:id,targetId,functionName,args.toString()Prints the immutable valueAsyncFunctionCallwith attribute values.Copy the current immutable object with elements that replace the content ofargs.withFunctionName(String value) Copy the current immutable object by setting a value for thefunctionNameattribute.Copy the current immutable object by setting a present value for the optionalidattribute.Copy the current immutable object by setting an optional value for theidattribute.withTargetId(ItemId value) Copy the current immutable object by setting a present value for the optionaltargetIdattribute.withTargetId(Optional<? extends ItemId> optional) Copy the current immutable object by setting an optional value for thetargetIdattribute.
-
Method Details
-
getId
- Specified by:
getIdin interfaceAsyncFunctionCall- Returns:
- The value of the
idattribute
-
getTargetId
- Specified by:
getTargetIdin interfaceAsyncFunctionCall- Returns:
- The value of the
targetIdattribute
-
getFunctionName
- Specified by:
getFunctionNamein interfaceAsyncFunctionCall- Returns:
- The value of the
functionNameattribute
-
getArgs
- Specified by:
getArgsin interfaceAsyncFunctionCall- Returns:
- A cloned
argsarray
-
withId
Copy the current immutable object by setting a present value for the optionalidattribute.- Parameters:
value- The value for id- Returns:
- A modified copy or
thisif not changed
-
withId
Copy the current immutable object by setting an optional value for theidattribute. An equality check is used on inner value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for id- Returns:
- A modified copy or
thisif not changed
-
withTargetId
Copy the current immutable object by setting a present value for the optionaltargetIdattribute.- Parameters:
value- The value for targetId- Returns:
- A modified copy or
thisif not changed
-
withTargetId
Copy the current immutable object by setting an optional value for thetargetIdattribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for targetId- Returns:
- A modified copy or
thisif not changed
-
withFunctionName
Copy the current immutable object by setting a value for thefunctionNameattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for functionName- Returns:
- A modified copy or the
thisobject
-
withArgs
Copy the current immutable object with elements that replace the content ofargs. The array is cloned before being saved as attribute values.- Parameters:
elements- The elements for args- Returns:
- A modified copy of
thisobject
-
equals
This instance is equal to all instances ofImmutableAsyncFunctionCallthat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:id,targetId,functionName,args. -
toString
Prints the immutable valueAsyncFunctionCallwith attribute values. -
copyOf
Creates an immutable copy of aAsyncFunctionCallvalue. 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 AsyncFunctionCall instance
-
builder
Creates a builder forImmutableAsyncFunctionCall.ImmutableAsyncFunctionCall.builder() .id(Optional<String>) // optionalid.targetId(Optional<io.dialob.session.engine.session.model.ItemId>) // optionaltargetId.functionName(String) // requiredfunctionName.args(Object[]) // requiredargs.build();- Returns:
- A new ImmutableAsyncFunctionCall builder
-