Class ImmutableSignalRecordValue
java.lang.Object
io.camunda.zeebe.protocol.record.value.ImmutableSignalRecordValue
- All Implemented Interfaces:
JsonSerializable,RecordValue,RecordValueWithVariables,SignalRecordValue
@ParametersAreNonnullByDefault
@Immutable
public final class ImmutableSignalRecordValue
extends Object
implements SignalRecordValue
Immutable implementation of
SignalRecordValue.
Use the builder to create immutable instances:
ImmutableSignalRecordValue.builder().
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilds instances of typeImmutableSignalRecordValue. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Creates a builder forImmutableSignalRecordValue.static ImmutableSignalRecordValuecopyOf(SignalRecordValue instance) Creates an immutable copy of aSignalRecordValuevalue.booleanThis instance is equal to all instances ofImmutableSignalRecordValuethat have equal attribute values.inthashCode()Returns a lazily computed hash code from attributes:variables,signalName.toString()Prints the immutable valueSignalRecordValuewith attribute values.withSignalName(String value) Copy the current immutable object by setting a value for thesignalNameattribute.withVariables(Map<String, ? extends Object> entries) Copy the current immutable object by replacing thevariablesmap with the specified map.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface io.camunda.zeebe.protocol.record.JsonSerializable
toJson
-
Method Details
-
getVariables
- Specified by:
getVariablesin interfaceRecordValueWithVariables- Returns:
- the variables of this record. Can be empty.
-
getSignalName
- Specified by:
getSignalNamein interfaceSignalRecordValue- Returns:
- the name of the signal
-
withVariables
Copy the current immutable object by replacing thevariablesmap 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 variables map- Returns:
- A modified copy of
thisobject
-
withSignalName
Copy the current immutable object by setting a value for thesignalNameattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for signalName (can benull)- Returns:
- A modified copy of the
thisobject
-
equals
This instance is equal to all instances ofImmutableSignalRecordValuethat have equal attribute values. -
hashCode
public int hashCode()Returns a lazily computed hash code from attributes:variables,signalName. -
toString
Prints the immutable valueSignalRecordValuewith attribute values. -
copyOf
Creates an immutable copy of aSignalRecordValuevalue. 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 SignalRecordValue instance
-
builder
Creates a builder forImmutableSignalRecordValue.ImmutableSignalRecordValue.builder() .putVariable|putAllVariables(String => Object) //variablesmappings .withSignalName(String | null) // nullablesignalName.build();- Returns:
- A new ImmutableSignalRecordValue builder
-