protected void addSuspensionStateField(JsonObject jsonObject, SuspensionState suspensionState) { if (suspensionState != null) { if (suspensionState.equals(SuspensionState.ACTIVE)) { JsonUtil.addField(jsonObject, ACTIVE, true); } else if (suspensionState.equals(SuspensionState.SUSPENDED)) { JsonUtil.addField(jsonObject, SUSPENDED, true); } } }
public JsonObject toJsonObject(TaskQueryVariableValue variable) { JsonObject jsonObject = JsonUtil.createObject(); JsonUtil.addField(jsonObject, "name", variable.getName()); JsonUtil.addFieldRawValue(jsonObject, "value", variable.getValue()); JsonUtil.addField(jsonObject, "operator", variable.getOperator().name()); return jsonObject; }
@Override public String toCanonicalString() { JsonObject json = JsonUtil.createObject(); JsonUtil.addField(json, JOB_CONFIG_COUNT_EMPTY_RUNS, countEmptyRuns); JsonUtil.addField(json, JOB_CONFIG_EXECUTE_AT_ONCE, immediatelyDue); JsonUtil.addField(json, JOB_CONFIG_MINUTE_FROM, minuteFrom); JsonUtil.addField(json, JOB_CONFIG_MINUTE_TO, minuteTo); return json.toString(); }
public JsonObject toJsonObject(TaskQueryVariableValue variable) { JsonObject jsonObject = JsonUtil.createObject(); JsonUtil.addField(jsonObject, "name", variable.getName()); JsonUtil.addFieldRawValue(jsonObject, "value", variable.getValue()); JsonUtil.addField(jsonObject, "operator", variable.getOperator().name()); return jsonObject; }
@Override public String toCanonicalString() { JsonObject json = JsonUtil.createObject(); JsonUtil.addField(json, JOB_CONFIG_COUNT_EMPTY_RUNS, countEmptyRuns); JsonUtil.addField(json, JOB_CONFIG_EXECUTE_AT_ONCE, immediatelyDue); JsonUtil.addField(json, JOB_CONFIG_MINUTE_FROM, minuteFrom); JsonUtil.addField(json, JOB_CONFIG_MINUTE_TO, minuteTo); return json.toString(); }
protected void addVariable(JsonObject jsonObject, String variableType, TaskQueryVariableValue variable) { JsonArray variables = JsonUtil.getArray(jsonObject, variableType); JsonUtil.addElement(variables, variableValueConverter, variable); JsonUtil.addField(jsonObject, variableType, variables); }
public JsonObject toJsonObject(DeleteProcessInstanceBatchConfiguration configuration) { JsonObject json = JsonUtil.createObject(); JsonUtil.addField(json, DELETE_REASON, configuration.getDeleteReason()); JsonUtil.addListField(json, PROCESS_INSTANCE_IDS, configuration.getIds()); JsonUtil.addField(json, SKIP_CUSTOM_LISTENERS, configuration.isSkipCustomListeners()); JsonUtil.addField(json, SKIP_SUBPROCESSES, configuration.isSkipSubprocesses()); return json; }
@Override public JsonObject toJsonObject(RestartProcessInstancesBatchConfiguration configuration) { JsonObject json = JsonUtil.createObject(); JsonUtil.addListField(json, PROCESS_INSTANCE_IDS, configuration.getIds()); JsonUtil.addField(json, PROCESS_DEFINITION_ID, configuration.getProcessDefinitionId()); JsonUtil.addListField(json, INSTRUCTIONS, ModificationCmdJsonConverter.INSTANCE, configuration.getInstructions()); JsonUtil.addField(json, INITIAL_VARIABLES, configuration.isInitialVariables()); JsonUtil.addField(json, SKIP_CUSTOM_LISTENERS, configuration.isSkipCustomListeners()); JsonUtil.addField(json, SKIP_IO_MAPPINGS, configuration.isSkipIoMappings()); JsonUtil.addField(json, WITHOUT_BUSINESS_KEY, configuration.isWithoutBusinessKey()); return json; }
protected void addVariable(JsonObject jsonObject, String variableType, TaskQueryVariableValue variable) { JsonArray variables = JsonUtil.getArray(jsonObject, variableType); JsonUtil.addElement(variables, variableValueConverter, variable); JsonUtil.addField(jsonObject, variableType, variables); }
public JsonObject toJsonObject(MigrationBatchConfiguration configuration) { JsonObject json = JsonUtil.createObject(); JsonUtil.addField(json, MIGRATION_PLAN, MigrationPlanJsonConverter.INSTANCE, configuration.getMigrationPlan()); JsonUtil.addListField(json, PROCESS_INSTANCE_IDS, configuration.getIds()); JsonUtil.addField(json, SKIP_LISTENERS, configuration.isSkipCustomListeners()); JsonUtil.addField(json, SKIP_IO_MAPPINGS, configuration.isSkipIoMappings()); return json; }
@Override public JsonObject toJsonObject(RestartProcessInstancesBatchConfiguration configuration) { JsonObject json = JsonUtil.createObject(); JsonUtil.addListField(json, PROCESS_INSTANCE_IDS, configuration.getIds()); JsonUtil.addField(json, PROCESS_DEFINITION_ID, configuration.getProcessDefinitionId()); JsonUtil.addListField(json, INSTRUCTIONS, ModificationCmdJsonConverter.INSTANCE, configuration.getInstructions()); JsonUtil.addField(json, INITIAL_VARIABLES, configuration.isInitialVariables()); JsonUtil.addField(json, SKIP_CUSTOM_LISTENERS, configuration.isSkipCustomListeners()); JsonUtil.addField(json, SKIP_IO_MAPPINGS, configuration.isSkipIoMappings()); JsonUtil.addField(json, WITHOUT_BUSINESS_KEY, configuration.isWithoutBusinessKey()); return json; }
public JsonObject toJsonObject(MigrationPlan migrationPlan) { JsonObject json = JsonUtil.createObject(); JsonUtil.addField(json, SOURCE_PROCESS_DEFINITION_ID, migrationPlan.getSourceProcessDefinitionId()); JsonUtil.addField(json, TARGET_PROCESS_DEFINITION_ID, migrationPlan.getTargetProcessDefinitionId()); JsonUtil.addListField(json, INSTRUCTIONS, MigrationInstructionJsonConverter.INSTANCE, migrationPlan.getInstructions()); return json; }
@Override public JsonObject toJsonObject(SetRetriesBatchConfiguration configuration) { JsonObject json = JsonUtil.createObject(); JsonUtil.addListField(json, EXTERNAL_TASK_IDS, configuration.getIds()); JsonUtil.addField(json, RETRIES, configuration.getRetries()); return json; }
protected void addTenantIdFields(JsonObject jsonObject, TaskQueryImpl query) { if (query.isTenantIdSet()) { if (query.getTenantIds() != null) { JsonUtil.addArrayField(jsonObject, TENANT_IDS, query.getTenantIds()); } else { JsonUtil.addField(jsonObject, WITHOUT_TENANT_ID, true); } } }
protected void addTenantIdFields(JsonObject jsonObject, TaskQueryImpl query) { if (query.isTenantIdSet()) { if (query.getTenantIds() != null) { JsonUtil.addArrayField(jsonObject, TENANT_IDS, query.getTenantIds()); } else { JsonUtil.addField(jsonObject, WITHOUT_TENANT_ID, true); } } }
public JsonObject toJsonObject(UpdateProcessInstancesSuspendStateBatchConfiguration configuration) { JsonObject json = JsonUtil.createObject(); JsonUtil.addListField(json, PROCESS_INSTANCE_IDS, configuration.getIds()); JsonUtil.addField(json, SUSPENDING, configuration.getSuspended()); return json; }
public JsonObject toJsonObject(SetRetriesBatchConfiguration configuration) { JsonObject json = JsonUtil.createObject(); JsonUtil.addListField(json, JOB_IDS, configuration.getIds()); JsonUtil.addField(json, RETRIES, configuration.getRetries()); return json; }
public JsonObject toJsonObject(UpdateProcessInstancesSuspendStateBatchConfiguration configuration) { JsonObject json = JsonUtil.createObject(); JsonUtil.addListField(json, PROCESS_INSTANCE_IDS, configuration.getIds()); JsonUtil.addField(json, SUSPENDING, configuration.getSuspended()); return json; }
@Override public JsonObject toJsonObject(SetRetriesBatchConfiguration configuration) { JsonObject json = JsonUtil.createObject(); JsonUtil.addListField(json, EXTERNAL_TASK_IDS, configuration.getIds()); JsonUtil.addField(json, RETRIES, configuration.getRetries()); return json; }
public JsonObject toJsonObject(MigrationInstruction instruction) { JsonObject json = JsonUtil.createObject(); JsonUtil.addArrayField(json, SOURCE_ACTIVITY_IDS, new String[]{instruction.getSourceActivityId()}); JsonUtil.addArrayField(json, TARGET_ACTIVITY_IDS, new String[]{instruction.getTargetActivityId()}); JsonUtil.addField(json, UPDATE_EVENT_TRIGGER, instruction.isUpdateEventTrigger()); return json; }