Package org.kie.internal.task.api

## Interface TaskQueryService

-     public interface TaskQueryService

  The Task Query Service will contain all the methods to get information about the current Task Instances. Most of the times these methods will be used to build User Interfaces, and we should not include any method related with Task Statistics here.

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `int` | `getCompletedTaskByUserId​(String userId)` |
    `int` | `getPendingSubTasksByParent​(long parentId)` |
    `int` | `getPendingTaskByUserId​(String userId)` |
    `Map<Long,​List<org.kie.api.task.model.OrganizationalEntity>>` | `getPotentialOwnersForTaskIds​(List<Long> taskIds)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getSubTasksAssignedAsPotentialOwner​(long parentId, String userId)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getSubTasksByParent​(long parentId)` |
    `org.kie.api.task.model.Task` | `getTaskByWorkItemId​(long workItemId)` |
    `org.kie.api.task.model.Task` | `getTaskInstanceById​(long taskId)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedAsBusinessAdministrator​(String userId, List<String> groupIds)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedAsBusinessAdministratorByStatus​(String userId, List<String> groupIds, List<org.kie.api.task.model.Status> status)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedAsExcludedOwner​(String userId)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedAsPotentialOwner​(String userId, List<String> groupIds)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedAsPotentialOwner​(String userId, List<String> groupIds, int firstResult, int maxResults)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedAsPotentialOwner​(String userId, List<String> groupIds, List<org.kie.api.task.model.Status> status, QueryFilter filter)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedAsPotentialOwnerByExpirationDate​(String userId, List<String> groupIds, List<org.kie.api.task.model.Status> status, Date expirationDate)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedAsPotentialOwnerByExpirationDate​(String userId, List<org.kie.api.task.model.Status> status, Date expirationDate)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedAsPotentialOwnerByExpirationDateOptional​(String userId, List<String> groupIds, List<org.kie.api.task.model.Status> status, Date expirationDate)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedAsPotentialOwnerByExpirationDateOptional​(String userId, List<org.kie.api.task.model.Status> status, Date expirationDate)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedAsPotentialOwnerByStatus​(String userId, List<org.kie.api.task.model.Status> status)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedAsPotentialOwnerByStatusByGroup​(String userId, List<String> groupIds, List<org.kie.api.task.model.Status> status)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedAsRecipient​(String userId)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedAsTaskInitiator​(String userId)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedAsTaskStakeholder​(String userId)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedByGroup​(String groupId)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedByGroups​(List<String> groupsId)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedByGroupsByExpirationDate​(List<String> groupIds, Date expirationDate)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksAssignedByGroupsByExpirationDateOptional​(List<String> groupIds, Date expirationDate)` |
    `List<Long>` | `getTasksByProcessInstanceId​(String processInstanceId)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksByStatusByProcessInstanceId​(String processInstanceId, List<org.kie.api.task.model.Status> status)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksByStatusByProcessInstanceIdByTaskName​(String processInstanceId, List<org.kie.api.task.model.Status> status, String taskName)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksOwned​(String userId)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksOwned​(String userId, List<org.kie.api.task.model.Status> status, QueryFilter filter)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksOwnedByExpirationDate​(String userId, List<org.kie.api.task.model.Status> status, Date expirationDate)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksOwnedByExpirationDateBeforeSpecifiedDate​(String userId, List<org.kie.api.task.model.Status> status, Date date)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksOwnedByExpirationDateOptional​(String userId, List<org.kie.api.task.model.Status> status, Date expirationDate)` |
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksOwnedByStatus​(String userId, List<org.kie.api.task.model.Status> status)` |
    `List<org.kie.api.task.model.TaskSummary>` | `query​(String userId, Object queryWhere)` |

- - ### Method Detail

    - #### getTasksAssignedAsPotentialOwner

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedAsPotentialOwner​(String userId,
                                                                                    List<String> groupIds,
                                                                                    List<org.kie.api.task.model.Status> status,
                                                                                    QueryFilter filter)

    - #### getTasksOwned

          List<org.kie.api.task.model.TaskSummary> getTasksOwned​(String userId,
                                                                 List<org.kie.api.task.model.Status> status,
                                                                 QueryFilter filter)

    - #### getTasksAssignedAsPotentialOwner

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedAsPotentialOwner​(String userId,
                                                                                    List<String> groupIds)

    - #### getTasksAssignedAsBusinessAdministrator

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedAsBusinessAdministrator​(String userId,
                                                                                           List<String> groupIds)

    - #### getTasksAssignedAsBusinessAdministratorByStatus

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedAsBusinessAdministratorByStatus​(String userId,
                                                                                                   List<String> groupIds,
                                                                                                   List<org.kie.api.task.model.Status> status)

    - #### getTasksAssignedAsExcludedOwner

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedAsExcludedOwner​(String userId)

    - #### getTasksAssignedAsPotentialOwnerByExpirationDate

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedAsPotentialOwnerByExpirationDate​(String userId,
                                                                                                    List<String> groupIds,
                                                                                                    List<org.kie.api.task.model.Status> status,
                                                                                                    Date expirationDate)

    - #### getTasksAssignedAsPotentialOwnerByExpirationDateOptional

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedAsPotentialOwnerByExpirationDateOptional​(String userId,
                                                                                                            List<String> groupIds,
                                                                                                            List<org.kie.api.task.model.Status> status,
                                                                                                            Date expirationDate)

    - #### getTasksAssignedAsPotentialOwnerByExpirationDate

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedAsPotentialOwnerByExpirationDate​(String userId,
                                                                                                    List<org.kie.api.task.model.Status> status,
                                                                                                    Date expirationDate)

    - #### getTasksAssignedAsPotentialOwnerByExpirationDateOptional

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedAsPotentialOwnerByExpirationDateOptional​(String userId,
                                                                                                            List<org.kie.api.task.model.Status> status,
                                                                                                            Date expirationDate)

    - #### getTasksAssignedAsPotentialOwner

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedAsPotentialOwner​(String userId,
                                                                                    List<String> groupIds,
                                                                                    int firstResult,
                                                                                    int maxResults)

    - #### getTasksAssignedAsPotentialOwnerByStatus

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedAsPotentialOwnerByStatus​(String userId,
                                                                                            List<org.kie.api.task.model.Status> status)

    - #### getTasksAssignedAsPotentialOwnerByStatusByGroup

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedAsPotentialOwnerByStatusByGroup​(String userId,
                                                                                                   List<String> groupIds,
                                                                                                   List<org.kie.api.task.model.Status> status)

    - #### getTasksAssignedAsRecipient

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedAsRecipient​(String userId)

    - #### getTasksAssignedAsTaskInitiator

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedAsTaskInitiator​(String userId)

    - #### getTasksAssignedAsTaskStakeholder

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedAsTaskStakeholder​(String userId)

    - #### getTasksAssignedByGroup

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedByGroup​(String groupId)

    - #### getTasksAssignedByGroups

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedByGroups​(List<String> groupsId)

    - #### getTasksAssignedByGroupsByExpirationDate

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedByGroupsByExpirationDate​(List<String> groupIds,
                                                                                            Date expirationDate)

    - #### getTasksAssignedByGroupsByExpirationDateOptional

          List<org.kie.api.task.model.TaskSummary> getTasksAssignedByGroupsByExpirationDateOptional​(List<String> groupIds,
                                                                                                    Date expirationDate)

    - #### getTasksOwned

          List<org.kie.api.task.model.TaskSummary> getTasksOwned​(String userId)

    - #### getTasksOwnedByStatus

          List<org.kie.api.task.model.TaskSummary> getTasksOwnedByStatus​(String userId,
                                                                         List<org.kie.api.task.model.Status> status)

    - #### getTasksOwnedByExpirationDate

          List<org.kie.api.task.model.TaskSummary> getTasksOwnedByExpirationDate​(String userId,
                                                                                 List<org.kie.api.task.model.Status> status,
                                                                                 Date expirationDate)

    - #### getTasksOwnedByExpirationDateOptional

          List<org.kie.api.task.model.TaskSummary> getTasksOwnedByExpirationDateOptional​(String userId,
                                                                                         List<org.kie.api.task.model.Status> status,
                                                                                         Date expirationDate)

    - #### getTasksOwnedByExpirationDateBeforeSpecifiedDate

          List<org.kie.api.task.model.TaskSummary> getTasksOwnedByExpirationDateBeforeSpecifiedDate​(String userId,
                                                                                                    List<org.kie.api.task.model.Status> status,
                                                                                                    Date date)

    - #### getSubTasksAssignedAsPotentialOwner

          List<org.kie.api.task.model.TaskSummary> getSubTasksAssignedAsPotentialOwner​(long parentId,
                                                                                       String userId)

    - #### getSubTasksByParent

          List<org.kie.api.task.model.TaskSummary> getSubTasksByParent​(long parentId)

    - #### getTasksByStatusByProcessInstanceId

          List<org.kie.api.task.model.TaskSummary> getTasksByStatusByProcessInstanceId​(String processInstanceId,
                                                                                       List<org.kie.api.task.model.Status> status)

    - #### getTasksByStatusByProcessInstanceIdByTaskName

          List<org.kie.api.task.model.TaskSummary> getTasksByStatusByProcessInstanceIdByTaskName​(String processInstanceId,
                                                                                                 List<org.kie.api.task.model.Status> status,
                                                                                                 String taskName)

    - #### getPendingSubTasksByParent

          int getPendingSubTasksByParent​(long parentId)

    - #### getTaskByWorkItemId

          org.kie.api.task.model.Task getTaskByWorkItemId​(long workItemId)

    - #### getTaskInstanceById

          org.kie.api.task.model.Task getTaskInstanceById​(long taskId)

    - #### getTasksByProcessInstanceId

          List<Long> getTasksByProcessInstanceId​(String processInstanceId)

    - #### getPotentialOwnersForTaskIds

          Map<Long,​List<org.kie.api.task.model.OrganizationalEntity>> getPotentialOwnersForTaskIds​(List<Long> taskIds)

    - #### getCompletedTaskByUserId

          int getCompletedTaskByUserId​(String userId)

    - #### getPendingTaskByUserId

          int getPendingTaskByUserId​(String userId)

    - #### query

          List<org.kie.api.task.model.TaskSummary> query​(String userId,
                                                         Object queryWhere)

      Parameters:
        `queryWhere` -
      Returns: