Search in sources :

Example 6 with CountResultDto

use of org.camunda.bpm.engine.rest.dto.CountResultDto in project camunda-bpm-platform by camunda.

the class BatchRestServiceImpl method getBatchesCount.

public CountResultDto getBatchesCount(UriInfo uriInfo) {
    ProcessEngine processEngine = getProcessEngine();
    BatchQueryDto queryDto = new BatchQueryDto(getObjectMapper(), uriInfo.getQueryParameters());
    BatchQuery query = queryDto.toQuery(processEngine);
    long count = query.count();
    return new CountResultDto(count);
}
Also used : CountResultDto(org.camunda.bpm.engine.rest.dto.CountResultDto) BatchQuery(org.camunda.bpm.engine.batch.BatchQuery) BatchQueryDto(org.camunda.bpm.engine.rest.dto.batch.BatchQueryDto) ProcessEngine(org.camunda.bpm.engine.ProcessEngine)

Example 7 with CountResultDto

use of org.camunda.bpm.engine.rest.dto.CountResultDto in project camunda-bpm-platform by camunda.

the class ProcessInstanceRestServiceImpl method queryProcessInstancesCount.

@Override
public CountResultDto queryProcessInstancesCount(ProcessInstanceQueryDto queryDto) {
    ProcessEngine engine = getProcessEngine();
    queryDto.setObjectMapper(getObjectMapper());
    ProcessInstanceQuery query = queryDto.toQuery(engine);
    long count = query.count();
    CountResultDto result = new CountResultDto();
    result.setCount(count);
    return result;
}
Also used : HistoricProcessInstanceQuery(org.camunda.bpm.engine.history.HistoricProcessInstanceQuery) ProcessInstanceQuery(org.camunda.bpm.engine.runtime.ProcessInstanceQuery) CountResultDto(org.camunda.bpm.engine.rest.dto.CountResultDto) ProcessEngine(org.camunda.bpm.engine.ProcessEngine)

Example 8 with CountResultDto

use of org.camunda.bpm.engine.rest.dto.CountResultDto in project camunda-bpm-platform by camunda.

the class TaskRestServiceImpl method queryTasksCount.

@Override
public CountResultDto queryTasksCount(TaskQueryDto queryDto) {
    ProcessEngine engine = getProcessEngine();
    queryDto.setObjectMapper(getObjectMapper());
    TaskQuery query = queryDto.toQuery(engine);
    long count = query.count();
    CountResultDto result = new CountResultDto();
    result.setCount(count);
    return result;
}
Also used : TaskQuery(org.camunda.bpm.engine.task.TaskQuery) CountResultDto(org.camunda.bpm.engine.rest.dto.CountResultDto) ProcessEngine(org.camunda.bpm.engine.ProcessEngine)

Example 9 with CountResultDto

use of org.camunda.bpm.engine.rest.dto.CountResultDto in project camunda-bpm-platform by camunda.

the class TenantRestServiceImpl method getTenantCount.

public CountResultDto getTenantCount(UriInfo uriInfo) {
    TenantQueryDto queryDto = new TenantQueryDto(getObjectMapper(), uriInfo.getQueryParameters());
    TenantQuery query = queryDto.toQuery(getProcessEngine());
    long count = query.count();
    return new CountResultDto(count);
}
Also used : TenantQueryDto(org.camunda.bpm.engine.rest.dto.identity.TenantQueryDto) CountResultDto(org.camunda.bpm.engine.rest.dto.CountResultDto) TenantQuery(org.camunda.bpm.engine.identity.TenantQuery)

Example 10 with CountResultDto

use of org.camunda.bpm.engine.rest.dto.CountResultDto in project camunda-bpm-platform by camunda.

the class UserRestServiceImpl method getUserCount.

protected CountResultDto getUserCount(UserQueryDto queryDto) {
    UserQuery query = queryDto.toQuery(getProcessEngine());
    long count = query.count();
    return new CountResultDto(count);
}
Also used : CountResultDto(org.camunda.bpm.engine.rest.dto.CountResultDto) UserQuery(org.camunda.bpm.engine.identity.UserQuery)

Aggregations

CountResultDto (org.camunda.bpm.engine.rest.dto.CountResultDto)39 ProcessEngine (org.camunda.bpm.engine.ProcessEngine)14 HistoricProcessInstanceQuery (org.camunda.bpm.engine.history.HistoricProcessInstanceQuery)2 AuthorizationQuery (org.camunda.bpm.engine.authorization.AuthorizationQuery)1 BatchQuery (org.camunda.bpm.engine.batch.BatchQuery)1 BatchStatisticsQuery (org.camunda.bpm.engine.batch.BatchStatisticsQuery)1 HistoricBatchQuery (org.camunda.bpm.engine.batch.history.HistoricBatchQuery)1 ExternalTaskQuery (org.camunda.bpm.engine.externaltask.ExternalTaskQuery)1 CleanableHistoricBatchReport (org.camunda.bpm.engine.history.CleanableHistoricBatchReport)1 CleanableHistoricCaseInstanceReport (org.camunda.bpm.engine.history.CleanableHistoricCaseInstanceReport)1 CleanableHistoricDecisionInstanceReport (org.camunda.bpm.engine.history.CleanableHistoricDecisionInstanceReport)1 CleanableHistoricProcessInstanceReport (org.camunda.bpm.engine.history.CleanableHistoricProcessInstanceReport)1 HistoricActivityInstanceQuery (org.camunda.bpm.engine.history.HistoricActivityInstanceQuery)1 HistoricCaseActivityInstanceQuery (org.camunda.bpm.engine.history.HistoricCaseActivityInstanceQuery)1 HistoricCaseInstanceQuery (org.camunda.bpm.engine.history.HistoricCaseInstanceQuery)1 HistoricDecisionInstanceQuery (org.camunda.bpm.engine.history.HistoricDecisionInstanceQuery)1 HistoricDetailQuery (org.camunda.bpm.engine.history.HistoricDetailQuery)1 HistoricExternalTaskLogQuery (org.camunda.bpm.engine.history.HistoricExternalTaskLogQuery)1 HistoricIdentityLinkLogQuery (org.camunda.bpm.engine.history.HistoricIdentityLinkLogQuery)1 HistoricIncidentQuery (org.camunda.bpm.engine.history.HistoricIncidentQuery)1