# Uses of Interface
org.flowable.batch.api.BatchQuery

Packages that use BatchQuery
Package
Description
org.flowable.batch.api
org.flowable.cmmn.api
org.flowable.engine
Public API of the Flowable engine.
Typical usage of the API starts by the creation of a `ProcessEngineConfiguration` (typically based on a configuration file), from which a `ProcessEngine` can be obtained.
Through the services obtained from such a `ProcessEngine`, BPM and workflow operation can be executed:
`RepositoryService`: Manages `Deployment`s.
`RuntimeService`: For starting and searching `ProcessInstance`s.
`TaskService`: Exposes operations to manage human (standalone) tasks, such as claiming, completing and assigning tasks.
`IdentityService`: Used for managing users, groups and the relations between them.
`ManagementService`: Exposes engine administration and maintenance operations, which have no relation to the runtime exection of business processes.
`HistoryService`: Exposes information about ongoing and past process instances.
`FormService`: Access to form data and rendered forms for starting new process instances and completing tasks.

- ## Uses of BatchQuery in org.flowable.batch.api

  Methods in org.flowable.batch.api that return BatchQuery
  Modifier and Type
  Method
  Description
  `BatchQuery`
  BatchQuery.`batchId(String batchId)`
  Only select batches with the given id
  `BatchQuery`
  BatchQuery.`batchType(String batchType)`
  Only select batches which exist for the given type.
  `BatchQuery`
  BatchQuery.`batchTypes(Collection<String> batchTypes)`
  Only select batches which exist for the given types.
  `BatchQuery`
  BatchQuery.`completeTimeHigherThan(Date date)`
  Only select batches where the complete time is higher then the given date.
  `BatchQuery`
  BatchQuery.`completeTimeLowerThan(Date date)`
  Only select batches where the complete time is lower than the given date.
  `BatchQuery`
  BatchQuery.`createTimeHigherThan(Date date)`
  Only select batches where the create time is higher then the given date.
  `BatchQuery`
  BatchQuery.`createTimeLowerThan(Date date)`
  Only select batches where the create time is lower than the given date.
  `BatchQuery`
  BatchQuery.`orderByBatchCreateTime()`
  Order by batch create time (needs to be followed by `Query.asc()` or `Query.desc()`).
  `BatchQuery`
  BatchQuery.`orderByBatchId()`
  Order by batch id (needs to be followed by `Query.asc()` or `Query.desc()`).
  `BatchQuery`
  BatchQuery.`orderByBatchTenantId()`
  Order by batch create time (needs to be followed by `Query.asc()` or `Query.desc()`).
  `BatchQuery`
  BatchQuery.`searchKey(String searchKey)`
  Only select batches which exist for the given search key.
  `BatchQuery`
  BatchQuery.`searchKey2(String searchKey2)`
  Only select batches which exist for the given search key.
  `BatchQuery`
  BatchQuery.`status(String status)`
  Only select batches which exist for the given status.
  `BatchQuery`
  BatchQuery.`tenantId(String tenantId)`
  Only select batches which exist for the given tenant id.
  `BatchQuery`
  BatchQuery.`tenantIdLike(String tenantIdLike)`
  Only select batches with a tenant id like the given one.
  `BatchQuery`
  BatchQuery.`withoutTenantId()`
  Only select batches that do not have a tenant id.
  Methods in org.flowable.batch.api with parameters of type BatchQuery
  Modifier and Type
  Method
  Description
  `long`
  BatchService.`findBatchCountByQueryCriteria(BatchQuery batchQuery)`
  `List<Batch>`
  BatchService.`findBatchesByQueryCriteria(BatchQuery batchQuery)`

- ## Uses of BatchQuery in org.flowable.cmmn.api

  Methods in org.flowable.cmmn.api that return BatchQuery
  Modifier and Type
  Method
  Description
  `BatchQuery`
  CmmnHistoryCleaningManager.`createBatchCleaningQuery()`
  `BatchQuery`
  CmmnManagementService.`createBatchQuery()`
  Returns a new BatchQuery implementation, that can be used to dynamically query the batches.

- ## Uses of BatchQuery in org.flowable.engine

  Methods in org.flowable.engine that return BatchQuery
  Modifier and Type
  Method
  Description
  `BatchQuery`
  DefaultHistoryCleaningManager.`createBatchCleaningQuery()`
  `BatchQuery`
  HistoryCleaningManager.`createBatchCleaningQuery()`
  `BatchQuery`
  ManagementService.`createBatchQuery()`
  Returns a new BatchQuery implementation, that can be used to dynamically query the batches.