Package io.camunda.client.impl.command
Class EvaluateExpressionCommandImpl
java.lang.Object
io.camunda.client.impl.command.CommandWithVariables<EvaluateExpressionCommandStep1.EvaluateExpressionCommandStep2>
io.camunda.client.impl.command.EvaluateExpressionCommandImpl
- All Implemented Interfaces:
CommandWithTenantStep<EvaluateExpressionCommandStep1.EvaluateExpressionCommandStep2>,CommandWithVariables<EvaluateExpressionCommandStep1.EvaluateExpressionCommandStep2>,EvaluateExpressionCommandStep1,EvaluateExpressionCommandStep1.EvaluateExpressionCommandStep2,FinalCommandStep<EvaluateExpressionResponse>
public class EvaluateExpressionCommandImpl
extends CommandWithVariables<EvaluateExpressionCommandStep1.EvaluateExpressionCommandStep2>
implements EvaluateExpressionCommandStep1, EvaluateExpressionCommandStep1.EvaluateExpressionCommandStep2
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.camunda.client.api.command.EvaluateExpressionCommandStep1
EvaluateExpressionCommandStep1.EvaluateExpressionCommandStep2 -
Field Summary
Fields inherited from class io.camunda.client.impl.command.CommandWithVariables
objectMapperFields inherited from interface io.camunda.client.api.command.CommandWithTenantStep
DEFAULT_TENANT_IDENTIFIER -
Constructor Summary
ConstructorsConstructorDescriptionEvaluateExpressionCommandImpl(CamundaClientConfiguration config, HttpClient httpClient, JsonMapper jsonMapper) -
Method Summary
Modifier and TypeMethodDescriptionexpression(String expression) Sets the expression to evaluate.requestTimeout(Duration requestTimeout) Sets the request timeout for the command.scopeKey(long scopeKey) Evaluate the expression in the variable scope of the given process or element instance.send()Sends the command to the Camunda gateway.setVariablesInternal(String variables) Specifies the tenant that will own any entities (e.g. process definition, process instances, etc.) resulting from this command, or that owns any entities (e.g. jobs) referred to from this command.Methods inherited from class io.camunda.client.impl.command.CommandWithVariables
variable, variables, variables, variables, variablesMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.camunda.client.api.command.EvaluateExpressionCommandStep1.EvaluateExpressionCommandStep2
variable, variables, variables, variables, variablesMethods inherited from interface io.camunda.client.api.command.FinalCommandStep
execute
-
Constructor Details
-
EvaluateExpressionCommandImpl
public EvaluateExpressionCommandImpl(CamundaClientConfiguration config, HttpClient httpClient, JsonMapper jsonMapper)
-
-
Method Details
-
expression
Description copied from interface:EvaluateExpressionCommandStep1Sets the expression to evaluate.- Specified by:
expressionin interfaceEvaluateExpressionCommandStep1- Parameters:
expression- the expression to evaluate (e.g., "=x + y")- Returns:
- the builder for this command
-
tenantId
Description copied from interface:CommandWithTenantStepSpecifies the tenant that will own any entities (e.g. process definition, process instances, etc.) resulting from this command, or that owns any entities (e.g. jobs) referred to from this command.Multi-tenancy
Multiple tenants can share a Camunda cluster. Entities can be assigned to a specific tenant using an identifier. Only that tenant can access these entities.
Any entities created before multi-tenancy has been enabled in the Camunda cluster, are assigned to the
CommandWithTenantStep.DEFAULT_TENANT_IDENTIFIER.If no tenant is explicitly specified, then the command is rejected.
- Specified by:
tenantIdin interfaceCommandWithTenantStep<EvaluateExpressionCommandStep1.EvaluateExpressionCommandStep2>- Parameters:
tenantId- the identifier of the tenant to specify for this command, e.g."ACME"- Returns:
- the builder for this command with the tenant specified
-
setVariablesInternal
protected EvaluateExpressionCommandStep1.EvaluateExpressionCommandStep2 setVariablesInternal(String variables) - Specified by:
setVariablesInternalin classCommandWithVariables<EvaluateExpressionCommandStep1.EvaluateExpressionCommandStep2>
-
scopeKey
Description copied from interface:EvaluateExpressionCommandStep1.EvaluateExpressionCommandStep2Evaluate the expression in the variable scope of the given process or element instance. Engine variables visible at this scope are exposed to the expression in addition to the request-body variables and tenant-scoped cluster variables.When a key is present both in the request-body
variablesand in the engine variable scope, the value fromvariablestakes precedence for this evaluation only.- Specified by:
scopeKeyin interfaceEvaluateExpressionCommandStep1.EvaluateExpressionCommandStep2- Parameters:
scopeKey- the key of the process or element instance scope whose variables are exposed to the expression- Returns:
- the builder for this command. Call
FinalCommandStep.send()to complete the command and send it to the broker.
-
requestTimeout
Description copied from interface:FinalCommandStepSets the request timeout for the command. The default request timeout can be configured usingCamundaClientBuilder.defaultRequestTimeout(Duration).- Specified by:
requestTimeoutin interfaceFinalCommandStep<EvaluateExpressionResponse>- Parameters:
requestTimeout- the request timeout- Returns:
- the configured command
-
send
Description copied from interface:FinalCommandStepSends the command to the Camunda gateway. This operation is asynchronous. In case of success, the future returns the event that was generated by the Camunda gateway in response to the command.Call
CamundaFuture.join()to wait until the response is available.Future<JobEventinvalid input: '>' future = command.send(); JobEvent event = future.join();- Specified by:
sendin interfaceFinalCommandStep<EvaluateExpressionResponse>- Returns:
- a future tracking state of success/failure of the command.
-