test_class.file: modules/flowable-rest/src/test/java/org/flowable/rest/service/api/history/HistoricVariableInstanceQueryResourceTest.java
test_class.identifier: HistoricVariableInstanceQueryResourceTest
test_class.superclass: extends BaseSpringRestTestCase
test_case.body: @Test
      @Deployment
      public void testQueryVariableInstances() throws Exception {
          HashMap<String, Object> processVariables = new HashMap<>();
          processVariables.put("stringVar", "Azerty");
          processVariables.put("intVar", 67890);
          processVariables.put("booleanVar", false);
  
          ProcessInstance processInstance = runtimeService.startProcessInstanceByKey("oneTaskProcess", processVariables);
          Task task = taskService.createTaskQuery().processInstanceId(processInstance.getId()).singleResult();
          taskService.complete(task.getId());
          task = taskService.createTaskQuery().processInstanceId(processInstance.getId()).singleResult();
          taskService.setVariableLocal(task.getId(), "taskVariable", "test");
  
          ProcessInstance processInstance2 = runtimeService.startProcessInstanceByKey("oneTaskProcess", processVariables);
  
          String url = RestUrls.createRelativeResourceUrl(RestUrls.URL_HISTORIC_VARIABLE_INSTANCE_QUERY);
  
          ObjectNode requestNode = objectMapper.createObjectNode();
          requestNode.put("variableName", "stringVar");
          assertResultsPresentInDataResponse(url, requestNode, 2, "stringVar", "Azerty");
  
          requestNode = objectMapper.createObjectNode();
          requestNode.put("variableName", "booleanVar");
          assertResultsPresentInDataResponse(url, requestNode, 2, "booleanVar", false);
  
          requestNode = objectMapper.createObjectNode();
          requestNode.put("variableName", "booleanVar2");
          assertResultsPresentInDataResponse(url, requestNode, 0, null, null);
  
          requestNode = objectMapper.createObjectNode();
          requestNode.put("processInstanceId", processInstance.getId());
          assertResultsPresentInDataResponse(url, requestNode, 4, "taskVariable", "test");
  
          requestNode = objectMapper.createObjectNode();
          requestNode.put("processInstanceId", processInstance.getId());
          requestNode.put("excludeTaskVariables", true);
          assertResultsPresentInDataResponse(url, requestNode, 3, "intVar", 67890);
  
          requestNode = objectMapper.createObjectNode();
          requestNode.put("processInstanceId", processInstance2.getId());
          assertResultsPresentInDataResponse(url, requestNode, 3, "stringVar", "Azerty");
  
          requestNode = objectMapper.createObjectNode();
          requestNode.put("taskId", task.getId());
          assertResultsPresentInDataResponse(url, requestNode, 1, "taskVariable", "test");
  
          requestNode = objectMapper.createObjectNode();
          requestNode.put("taskId", task.getId());
          requestNode.put("variableName", "booleanVar");
          assertResultsPresentInDataResponse(url, requestNode, 0, null, null);
  
          requestNode = objectMapper.createObjectNode();
          requestNode.put("variableNameLike", "%Var");
          assertResultsPresentInDataResponse(url, requestNode, 6, "stringVar", "Azerty");
  
          requestNode = objectMapper.createObjectNode();
          requestNode.put("variableNameLike", "%Var2");
          assertResultsPresentInDataResponse(url, requestNode, 0, null, null);
  
          requestNode = objectMapper.createObjectNode();
          ArrayNode variableArray = objectMapper.createArrayNode();
          ObjectNode variableNode = objectMapper.createObjectNode();
          variableArray.add(variableNode);
          requestNode.set("variables", variableArray);
          variableNode.put("name", "stringVar");
          variableNode.put("value", "Azerty");
          variableNode.put("operation", "equals");
          assertResultsPresentInDataResponse(url, requestNode, 2, "stringVar", "Azerty");
  
          variableNode.removeAll();
          requestNode.set("variables", variableArray);
          variableNode.put("name", "taskVariable");
          variableNode.put("value", "test");
          variableNode.put("operation", "equals");
          assertResultsPresentInDataResponse(url, requestNode, 1, "taskVariable", "test");
  
          variableNode.removeAll();
          requestNode.set("variables", variableArray);
          variableNode.put("name", "taskVariable");
          variableNode.put("value", "test");
          variableNode.put("operation", "notEquals");
          assertErrorResult(url, requestNode, HttpStatus.SC_BAD_REQUEST);
      }
test_case.class_method_signature: HistoricVariableInstanceQueryResourceTest.testQueryVariableInstances()
test_case.full_signature: @Test @Deployment public void testQueryVariableInstances()
test_case.identifier: testQueryVariableInstances
test_case.invocations: put put put startProcessInstanceByKey singleResult processInstanceId createTaskQuery getId complete getId singleResult processInstanceId createTaskQuery getId setVariableLocal getId startProcessInstanceByKey createRelativeResourceUrl createObjectNode put assertResultsPresentInDataResponse createObjectNode put assertResultsPresentInDataResponse createObjectNode put assertResultsPresentInDataResponse createObjectNode put getId assertResultsPresentInDataResponse createObjectNode put getId put assertResultsPresentInDataResponse createObjectNode put getId assertResultsPresentInDataResponse createObjectNode put getId assertResultsPresentInDataResponse createObjectNode put getId put assertResultsPresentInDataResponse createObjectNode put assertResultsPresentInDataResponse createObjectNode put assertResultsPresentInDataResponse createObjectNode createArrayNode createObjectNode add set put put put assertResultsPresentInDataResponse removeAll set put put put assertResultsPresentInDataResponse removeAll set put put put assertErrorResult
test_case.modifiers: @Test @Deployment public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testQueryVariableInstances()
focal_class.file: modules/flowable-rest/src/main/java/org/flowable/rest/service/api/history/HistoricVariableInstanceQueryResource.java
focal_class.identifier: HistoricVariableInstanceQueryResource
focal_class.class_method_signature: HistoricVariableInstanceQueryResource.queryVariableInstances(@RequestBody HistoricVariableInstanceQueryRequest queryRequest, @ApiParam(hidden = true) @RequestParam Map<String, String> allRequestParams,
              HttpServletRequest request)
focal_class.full_signature: @ApiOperation(value = "Query for historic variable instances", tags = { "History", "Query" }, notes = "All supported JSON parameter fields allowed are exactly the same as the parameters found for getting a collection of historic process instances," + " but passed in as JSON-body arguments rather than URL-parameters to allow for more advanced querying and preventing errors with request-uri’s that are too long. " + "On top of that, the query allows for filtering based on process variables. " + "The variables property is a JSON-array containing objects with the format as described here.") @ApiResponses(value = { @ApiResponse(code = 200, message = "Indicates request was successful and the tasks are returned"), @ApiResponse(code = 400, message = "Indicates an parameter was passed in the wrong format. The status-message contains additional information.") }) @PostMapping(value = "/query/historic-variable-instances", produces = "application/json") public DataResponse<HistoricVariableInstanceResponse> queryVariableInstances(@RequestBody HistoricVariableInstanceQueryRequest queryRequest, @ApiParam(hidden = true) @RequestParam Map<String, String> allRequestParams,
              HttpServletRequest request)
focal_class.identifier: queryVariableInstances
focal_class.modifiers: @ApiOperation(value = "Query for historic variable instances", tags = { "History", "Query" }, notes = "All supported JSON parameter fields allowed are exactly the same as the parameters found for getting a collection of historic process instances," + " but passed in as JSON-body arguments rather than URL-parameters to allow for more advanced querying and preventing errors with request-uri’s that are too long. " + "On top of that, the query allows for filtering based on process variables. " + "The variables property is a JSON-array containing objects with the format as described here.") @ApiResponses(value = { @ApiResponse(code = 200, message = "Indicates request was successful and the tasks are returned"), @ApiResponse(code = 400, message = "Indicates an parameter was passed in the wrong format. The status-message contains additional information.") }) @PostMapping(value = "/query/historic-variable-instances", produces = "application/json") public
focal_class.parameters: (@RequestBody HistoricVariableInstanceQueryRequest queryRequest, @ApiParam(hidden = true) @RequestParam Map<String, String> allRequestParams,
              HttpServletRequest request)
focal_class.return: DataResponse<HistoricVariableInstanceResponse>
focal_class.signature: DataResponse<HistoricVariableInstanceResponse> queryVariableInstances(@RequestBody HistoricVariableInstanceQueryRequest queryRequest, @ApiParam(hidden = true) @RequestParam Map<String, String> allRequestParams,
              HttpServletRequest request)
focal_class.superclass: extends HistoricVariableInstanceBaseResource
focal_method.body: @ApiOperation(value = "Query for historic variable instances", tags = { "History", "Query" },
              notes = "All supported JSON parameter fields allowed are exactly the same as the parameters found for getting a collection of historic process instances,"
              + " but passed in as JSON-body arguments rather than URL-parameters to allow for more advanced querying and preventing errors with request-uri’s that are too long. "
              + "On top of that, the query allows for filtering based on process variables. "
              + "The variables property is a JSON-array containing objects with the format as described here.")
      @ApiResponses(value = {
              @ApiResponse(code = 200, message = "Indicates request was successful and the tasks are returned"),
              @ApiResponse(code = 400, message = "Indicates an parameter was passed in the wrong format. The status-message contains additional information.") })
      @PostMapping(value = "/query/historic-variable-instances", produces = "application/json")
      public DataResponse<HistoricVariableInstanceResponse> queryVariableInstances(@RequestBody HistoricVariableInstanceQueryRequest queryRequest, @ApiParam(hidden = true) @RequestParam Map<String, String> allRequestParams,
              HttpServletRequest request) {
  
          return getQueryResponse(queryRequest, allRequestParams);
      }
focal_method.class_method_signature: HistoricVariableInstanceQueryResource.queryVariableInstances(@RequestBody HistoricVariableInstanceQueryRequest queryRequest, @ApiParam(hidden = true) @RequestParam Map<String, String> allRequestParams,
              HttpServletRequest request)
focal_method.full_signature: @ApiOperation(value = "Query for historic variable instances", tags = { "History", "Query" }, notes = "All supported JSON parameter fields allowed are exactly the same as the parameters found for getting a collection of historic process instances," + " but passed in as JSON-body arguments rather than URL-parameters to allow for more advanced querying and preventing errors with request-uri’s that are too long. " + "On top of that, the query allows for filtering based on process variables. " + "The variables property is a JSON-array containing objects with the format as described here.") @ApiResponses(value = { @ApiResponse(code = 200, message = "Indicates request was successful and the tasks are returned"), @ApiResponse(code = 400, message = "Indicates an parameter was passed in the wrong format. The status-message contains additional information.") }) @PostMapping(value = "/query/historic-variable-instances", produces = "application/json") public DataResponse<HistoricVariableInstanceResponse> queryVariableInstances(@RequestBody HistoricVariableInstanceQueryRequest queryRequest, @ApiParam(hidden = true) @RequestParam Map<String, String> allRequestParams,
              HttpServletRequest request)
focal_method.identifier: queryVariableInstances
focal_method.invocations: getQueryResponse
focal_method.modifiers: @ApiOperation(value = "Query for historic variable instances", tags = { "History", "Query" }, notes = "All supported JSON parameter fields allowed are exactly the same as the parameters found for getting a collection of historic process instances," + " but passed in as JSON-body arguments rather than URL-parameters to allow for more advanced querying and preventing errors with request-uri’s that are too long. " + "On top of that, the query allows for filtering based on process variables. " + "The variables property is a JSON-array containing objects with the format as described here.") @ApiResponses(value = { @ApiResponse(code = 200, message = "Indicates request was successful and the tasks are returned"), @ApiResponse(code = 400, message = "Indicates an parameter was passed in the wrong format. The status-message contains additional information.") }) @PostMapping(value = "/query/historic-variable-instances", produces = "application/json") public
focal_method.parameters: (@RequestBody HistoricVariableInstanceQueryRequest queryRequest, @ApiParam(hidden = true) @RequestParam Map<String, String> allRequestParams,
              HttpServletRequest request)
focal_method.return: DataResponse<HistoricVariableInstanceResponse>
focal_method.signature: DataResponse<HistoricVariableInstanceResponse> queryVariableInstances(@RequestBody HistoricVariableInstanceQueryRequest queryRequest, @ApiParam(hidden = true) @RequestParam Map<String, String> allRequestParams,
              HttpServletRequest request)