org.jbpm.services.task.impl

## Class TaskQueryServiceImpl

- java.lang.Object
- - org.jbpm.services.task.impl.TaskQueryServiceImpl

- All Implemented Interfaces:
    org.kie.internal.task.api.TaskQueryService

      public class TaskQueryServiceImpl
      extends Object
      implements org.kie.internal.task.api.TaskQueryService

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `TaskQueryServiceImpl()`
    `TaskQueryServiceImpl(org.kie.internal.task.api.TaskPersistenceContext persistenceContext, org.kie.api.task.UserGroupCallback userGroupCallback)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods Deprecated Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected List<?>` | `adoptList(List<?> source, List<?> values)`
    `protected void` | `applyQueryContext(Map<String,Object> params, org.kie.internal.query.QueryContext queryContext)`
    `protected void` | `applyQueryFilter(Map<String,Object> params, org.kie.internal.query.QueryFilter queryFilter)`
    `protected List<org.kie.api.task.model.TaskSummary>` | `collectTasksByPotentialOwners(List<Object[]> tasksByGroups)`
    `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<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, org.kie.internal.query.QueryFilter filter)`
    `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>` | `getTasksAssignedAsPotentialOwnerByExpirationDate(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>` | `getTasksAssignedAsPotentialOwnerByExpirationDateOptional(String userId, List<String> groupIds, 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> groupIds)`
    `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<org.kie.api.task.model.TaskSummary>` | `getTasksByGroup(List<String> groupIds)`
    `List<Long>` | `getTasksByProcessInstanceId(long processInstanceId)`
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksByStatusByProcessInstanceId(long processInstanceId, List<org.kie.api.task.model.Status> status)`
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksByStatusByProcessInstanceIdByTaskName(long processInstanceId, List<org.kie.api.task.model.Status> status, String taskName)`
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksByVariousFields(String userId, List<Long> workItemIds, List<Long> taskIds, List<Long> procInstIds, List<String> busAdmins, List<String> potOwners, List<String> taskOwners, List<org.kie.api.task.model.Status> status, boolean union, Integer maxResults)` Deprecated.
    `List<org.kie.api.task.model.TaskSummary>` | `getTasksByVariousFields(String userId, Map<String,List<?>> parameters, boolean union)` Deprecated.
    `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, org.kie.internal.query.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 queryObj)`
    `void` | `setPersistenceContext(org.kie.internal.task.api.TaskPersistenceContext persistenceContext)`
    `void` | `setUserGroupCallback(org.kie.api.task.UserGroupCallback userGroupCallback)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### TaskQueryServiceImpl

          public TaskQueryServiceImpl()

    - #### TaskQueryServiceImpl

          public TaskQueryServiceImpl(org.kie.internal.task.api.TaskPersistenceContext persistenceContext,
                                      org.kie.api.task.UserGroupCallback userGroupCallback)

  - ### Method Detail

    - #### adoptList

          protected List<?> adoptList(List<?> source,
                                      List<?> values)

    - #### applyQueryFilter

          protected void applyQueryFilter(Map<String,Object> params,
                                          org.kie.internal.query.QueryFilter queryFilter)

    - #### applyQueryContext

          protected void applyQueryContext(Map<String,Object> params,
                                           org.kie.internal.query.QueryContext queryContext)

    - #### setPersistenceContext

          public void setPersistenceContext(org.kie.internal.task.api.TaskPersistenceContext persistenceContext)

    - #### setUserGroupCallback

          public void setUserGroupCallback(org.kie.api.task.UserGroupCallback userGroupCallback)

    - #### getTasksAssignedAsBusinessAdministrator

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

      Specified by:
        `getTasksAssignedAsBusinessAdministrator` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedAsExcludedOwner

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

      Specified by:
        `getTasksAssignedAsExcludedOwner` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedAsPotentialOwner

          public List<org.kie.api.task.model.TaskSummary> getTasksAssignedAsPotentialOwner(String userId)

    - #### getTasksAssignedAsPotentialOwner

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

      Specified by:
        `getTasksAssignedAsPotentialOwner` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedByGroup

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

      Specified by:
        `getTasksAssignedByGroup` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedByGroupsByExpirationDateOptional

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

      Specified by:
        `getTasksAssignedByGroupsByExpirationDateOptional` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### collectTasksByPotentialOwners

          protected List<org.kie.api.task.model.TaskSummary> collectTasksByPotentialOwners(List<Object[]> tasksByGroups)

    - #### getTasksAssignedByGroupsByExpirationDate

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

      Specified by:
        `getTasksAssignedByGroupsByExpirationDate` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedByGroups

          public List<org.kie.api.task.model.TaskSummary> getTasksAssignedByGroups(List<String> groupIds)

      Specified by:
        `getTasksAssignedByGroups` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getPotentialOwnersForTaskIds

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

      Specified by:
        `getPotentialOwnersForTaskIds` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedAsPotentialOwner

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

      Specified by:
        `getTasksAssignedAsPotentialOwner` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedAsRecipient

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

      Specified by:
        `getTasksAssignedAsRecipient` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedAsTaskInitiator

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

      Specified by:
        `getTasksAssignedAsTaskInitiator` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedAsTaskStakeholder

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

      Specified by:
        `getTasksAssignedAsTaskStakeholder` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksOwned

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

      Specified by:
        `getTasksOwned` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksOwnedByStatus

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

      Specified by:
        `getTasksOwnedByStatus` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedAsPotentialOwnerByStatus

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

      Specified by:
        `getTasksAssignedAsPotentialOwnerByStatus` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedAsPotentialOwner

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

      Specified by:
        `getTasksAssignedAsPotentialOwner` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksOwned

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

      Specified by:
        `getTasksOwned` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getSubTasksAssignedAsPotentialOwner

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

      Specified by:
        `getSubTasksAssignedAsPotentialOwner` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getSubTasksByParent

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

      Specified by:
        `getSubTasksByParent` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getPendingSubTasksByParent

          public int getPendingSubTasksByParent(long parentId)

      Specified by:
        `getPendingSubTasksByParent` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTaskInstanceById

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

      Specified by:
        `getTaskInstanceById` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTaskByWorkItemId

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

      Specified by:
        `getTaskByWorkItemId` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedAsPotentialOwnerByExpirationDate

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

      Specified by:
        `getTasksAssignedAsPotentialOwnerByExpirationDate` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedAsPotentialOwnerByExpirationDateOptional

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

      Specified by:
        `getTasksAssignedAsPotentialOwnerByExpirationDateOptional` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksOwnedByExpirationDate

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

      Specified by:
        `getTasksOwnedByExpirationDate` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksOwnedByExpirationDateOptional

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

      Specified by:
        `getTasksOwnedByExpirationDateOptional` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksOwnedByExpirationDateBeforeSpecifiedDate

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

      Specified by:
        `getTasksOwnedByExpirationDateBeforeSpecifiedDate` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksByStatusByProcessInstanceId

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

      Specified by:
        `getTasksByStatusByProcessInstanceId` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksByStatusByProcessInstanceIdByTaskName

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

      Specified by:
        `getTasksByStatusByProcessInstanceIdByTaskName` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksByProcessInstanceId

          public List<Long> getTasksByProcessInstanceId(long processInstanceId)

      Specified by:
        `getTasksByProcessInstanceId` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedAsPotentialOwnerByExpirationDate

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

      Specified by:
        `getTasksAssignedAsPotentialOwnerByExpirationDate` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedAsPotentialOwnerByExpirationDateOptional

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

      Specified by:
        `getTasksAssignedAsPotentialOwnerByExpirationDateOptional` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksByVariousFields

          @Deprecated
          public List<org.kie.api.task.model.TaskSummary> getTasksByVariousFields(String userId,
                                                                                              List<Long> workItemIds,
                                                                                              List<Long> taskIds,
                                                                                              List<Long> procInstIds,
                                                                                              List<String> busAdmins,
                                                                                              List<String> potOwners,
                                                                                              List<String> taskOwners,
                                                                                              List<org.kie.api.task.model.Status> status,
                                                                                              boolean union,
                                                                                              Integer maxResults)

      Deprecated.

    - #### getTasksByVariousFields

          @Deprecated
          public List<org.kie.api.task.model.TaskSummary> getTasksByVariousFields(String userId,
                                                                                              Map<String,List<?>> parameters,
                                                                                              boolean union)

      Deprecated.
      Specified by:
        `getTasksByVariousFields` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getCompletedTaskByUserId

          public int getCompletedTaskByUserId(String userId)

      Specified by:
        `getCompletedTaskByUserId` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getPendingTaskByUserId

          public int getPendingTaskByUserId(String userId)

      Specified by:
        `getPendingTaskByUserId` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedAsPotentialOwnerByStatusByGroup

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

      Specified by:
        `getTasksAssignedAsPotentialOwnerByStatusByGroup` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksAssignedAsBusinessAdministratorByStatus

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

      Specified by:
        `getTasksAssignedAsBusinessAdministratorByStatus` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### getTasksByGroup

          public List<org.kie.api.task.model.TaskSummary> getTasksByGroup(List<String> groupIds)

      Specified by:
        `getTasksByGroup` in interface `org.kie.internal.task.api.TaskQueryService`

    - #### query

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

      Specified by:
        `query` in interface `org.kie.internal.task.api.TaskQueryService`

Copyright © 2001–2016 JBoss by Red Hat. All rights reserved.