Class ImmutableMessageSubscriptionRecordValue.Builder
java.lang.Object
io.camunda.zeebe.protocol.record.value.ImmutableMessageSubscriptionRecordValue.Builder
- Enclosing class:
ImmutableMessageSubscriptionRecordValue
Builds instances of type
ImmutableMessageSubscriptionRecordValue.
Initialize attributes and then invoke the build() method to create an
immutable instance.
Builder is not thread-safe and generally should not be stored in a field or collection,
but instead used immediately to create instances.
-
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds a newImmutableMessageSubscriptionRecordValue.clear()Clear the builder to the initial state.from(RecordValueWithVariables instance) Fill a builder with attribute values from the providedio.camunda.zeebe.protocol.record.RecordValueWithVariablesinstance.from(MessageSubscriptionRecordValue instance) Fill a builder with attribute values from the providedio.camunda.zeebe.protocol.record.value.MessageSubscriptionRecordValueinstance.from(ProcessInstanceRelated instance) Fill a builder with attribute values from the providedio.camunda.zeebe.protocol.record.value.ProcessInstanceRelatedinstance.from(TenantOwned instance) Fill a builder with attribute values from the providedio.camunda.zeebe.protocol.record.value.TenantOwnedinstance.putAllVariables(Map<String, ? extends Object> entries) Put all mappings from the specified map as entries tovariablesmap.putVariable(String key, Object value) Put one entry to thevariablesmap.putVariable(Map.Entry<String, ? extends Object> entry) Put one entry to thevariablesmap.withBpmnProcessId(String bpmnProcessId) Initializes the value for thebpmnProcessIdattribute.withCorrelationKey(String correlationKey) Initializes the value for thecorrelationKeyattribute.withElementInstanceKey(long elementInstanceKey) Initializes the value for theelementInstanceKeyattribute.withInterrupting(boolean interrupting) Initializes the value for theinterruptingattribute.withMessageKey(long messageKey) Initializes the value for themessageKeyattribute.withMessageName(String messageName) Initializes the value for themessageNameattribute.withProcessInstanceKey(long processInstanceKey) Initializes the value for theprocessInstanceKeyattribute.withTenantId(String tenantId) Initializes the value for thetenantIdattribute.withVariables(Map<String, ? extends Object> entries) Sets or replaces all mappings from the specified map as entries for thevariablesmap.
-
Method Details
-
from
Fill a builder with attribute values from the providedio.camunda.zeebe.protocol.record.value.ProcessInstanceRelatedinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
from
Fill a builder with attribute values from the providedio.camunda.zeebe.protocol.record.value.TenantOwnedinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
from
public final ImmutableMessageSubscriptionRecordValue.Builder from(RecordValueWithVariables instance) Fill a builder with attribute values from the providedio.camunda.zeebe.protocol.record.RecordValueWithVariablesinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
from
public final ImmutableMessageSubscriptionRecordValue.Builder from(MessageSubscriptionRecordValue instance) Fill a builder with attribute values from the providedio.camunda.zeebe.protocol.record.value.MessageSubscriptionRecordValueinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
putVariable
Put one entry to thevariablesmap.- Parameters:
key- The key in the variables mapvalue- The associated value in the variables map- Returns:
thisbuilder for use in a chained invocation
-
putVariable
public final ImmutableMessageSubscriptionRecordValue.Builder putVariable(Map.Entry<String, ? extends Object> entry) Put one entry to thevariablesmap. Nulls are not permitted- Parameters:
entry- The key and value entry- Returns:
thisbuilder for use in a chained invocation
-
withVariables
public final ImmutableMessageSubscriptionRecordValue.Builder withVariables(Map<String, ? extends Object> entries) Sets or replaces all mappings from the specified map as entries for thevariablesmap. Nulls are not permitted- Parameters:
entries- The entries that will be added to the variables map- Returns:
thisbuilder for use in a chained invocation
-
putAllVariables
public final ImmutableMessageSubscriptionRecordValue.Builder putAllVariables(Map<String, ? extends Object> entries) Put all mappings from the specified map as entries tovariablesmap. Nulls are not permitted- Parameters:
entries- The entries that will be added to the variables map- Returns:
thisbuilder for use in a chained invocation
-
withTenantId
Initializes the value for thetenantIdattribute.- Parameters:
tenantId- The value for tenantId (can benull)- Returns:
thisbuilder for use in a chained invocation
-
withProcessInstanceKey
public final ImmutableMessageSubscriptionRecordValue.Builder withProcessInstanceKey(long processInstanceKey) Initializes the value for theprocessInstanceKeyattribute.- Parameters:
processInstanceKey- The value for processInstanceKey- Returns:
thisbuilder for use in a chained invocation
-
withElementInstanceKey
public final ImmutableMessageSubscriptionRecordValue.Builder withElementInstanceKey(long elementInstanceKey) Initializes the value for theelementInstanceKeyattribute.- Parameters:
elementInstanceKey- The value for elementInstanceKey- Returns:
thisbuilder for use in a chained invocation
-
withBpmnProcessId
public final ImmutableMessageSubscriptionRecordValue.Builder withBpmnProcessId(String bpmnProcessId) Initializes the value for thebpmnProcessIdattribute.- Parameters:
bpmnProcessId- The value for bpmnProcessId (can benull)- Returns:
thisbuilder for use in a chained invocation
-
withMessageName
Initializes the value for themessageNameattribute.- Parameters:
messageName- The value for messageName (can benull)- Returns:
thisbuilder for use in a chained invocation
-
withCorrelationKey
public final ImmutableMessageSubscriptionRecordValue.Builder withCorrelationKey(String correlationKey) Initializes the value for thecorrelationKeyattribute.- Parameters:
correlationKey- The value for correlationKey (can benull)- Returns:
thisbuilder for use in a chained invocation
-
withMessageKey
Initializes the value for themessageKeyattribute.- Parameters:
messageKey- The value for messageKey- Returns:
thisbuilder for use in a chained invocation
-
withInterrupting
Initializes the value for theinterruptingattribute.- Parameters:
interrupting- The value for interrupting- Returns:
thisbuilder for use in a chained invocation
-
clear
Clear the builder to the initial state.- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newImmutableMessageSubscriptionRecordValue.- Returns:
- An immutable instance of MessageSubscriptionRecordValue
- Throws:
IllegalStateException- if any required attributes are missing
-