001
014
015 package com.liferay.portal.kernel.workflow;
016
017 import com.liferay.portal.kernel.messaging.proxy.MessagingProxy;
018 import com.liferay.portal.kernel.messaging.proxy.ProxyMode;
019 import com.liferay.portal.kernel.util.OrderByComparator;
020
021 import java.io.Serializable;
022
023 import java.util.Date;
024 import java.util.List;
025 import java.util.Map;
026
027
033 @MessagingProxy(mode = ProxyMode.SYNC)
034 public interface WorkflowTaskManager {
035
036 public WorkflowTask assignWorkflowTaskToRole(
037 long companyId, long userId, long workflowTaskId, long roleId,
038 String comment, Date dueDate,
039 Map<String, Serializable> workflowContext)
040 throws WorkflowException;
041
042 public WorkflowTask assignWorkflowTaskToUser(
043 long companyId, long userId, long workflowTaskId,
044 long assigneeUserId, String comment, Date dueDate,
045 Map<String, Serializable> workflowContext)
046 throws WorkflowException;
047
048 public WorkflowTask completeWorkflowTask(
049 long companyId, long userId, long workflowTaskId,
050 String transitionName, String comment,
051 Map<String, Serializable> workflowContext)
052 throws WorkflowException;
053
054 public WorkflowTask fetchWorkflowTask(
055 long companyId, long workflowTaskInstanceId)
056 throws WorkflowException;
057
058 public List<String> getNextTransitionNames(
059 long companyId, long userId, long workflowTaskId)
060 throws WorkflowException;
061
062 public long[] getPooledActorsIds(long companyId, long workflowTaskId)
063 throws WorkflowException;
064
065 public WorkflowTask getWorkflowTask(long companyId, long workflowTaskId)
066 throws WorkflowException;
067
068 public int getWorkflowTaskCount(long companyId, Boolean completed)
069 throws WorkflowException;
070
071 public int getWorkflowTaskCountByRole(
072 long companyId, long roleId, Boolean completed)
073 throws WorkflowException;
074
075 public int getWorkflowTaskCountBySubmittingUser(
076 long companyId, long userId, Boolean completed)
077 throws WorkflowException;
078
079 public int getWorkflowTaskCountByUser(
080 long companyId, long userId, Boolean completed)
081 throws WorkflowException;
082
083 public int getWorkflowTaskCountByUserRoles(
084 long companyId, long userId, Boolean completed)
085 throws WorkflowException;
086
087 public int getWorkflowTaskCountByWorkflowInstance(
088 long companyId, Long userId, long workflowInstanceId,
089 Boolean completed)
090 throws WorkflowException;
091
092 public List<WorkflowTask> getWorkflowTasks(
093 long companyId, Boolean completed, int start, int end,
094 OrderByComparator<WorkflowTask> orderByComparator)
095 throws WorkflowException;
096
097 public List<WorkflowTask> getWorkflowTasksByRole(
098 long companyId, long roleId, Boolean completed, int start, int end,
099 OrderByComparator<WorkflowTask> orderByComparator)
100 throws WorkflowException;
101
102 public List<WorkflowTask> getWorkflowTasksBySubmittingUser(
103 long companyId, long userId, Boolean completed, int start, int end,
104 OrderByComparator<WorkflowTask> orderByComparator)
105 throws WorkflowException;
106
107 public List<WorkflowTask> getWorkflowTasksByUser(
108 long companyId, long userId, Boolean completed, int start, int end,
109 OrderByComparator<WorkflowTask> orderByComparator)
110 throws WorkflowException;
111
112 public List<WorkflowTask> getWorkflowTasksByUserRoles(
113 long companyId, long userId, Boolean completed, int start, int end,
114 OrderByComparator<WorkflowTask> orderByComparator)
115 throws WorkflowException;
116
117 public List<WorkflowTask> getWorkflowTasksByWorkflowInstance(
118 long companyId, Long userId, long workflowInstanceId,
119 Boolean completed, int start, int end,
120 OrderByComparator<WorkflowTask> orderByComparator)
121 throws WorkflowException;
122
123 public List<WorkflowTask> search(
124 long companyId, long userId, String keywords, Boolean completed,
125 Boolean searchByUserRoles, int start, int end,
126 OrderByComparator<WorkflowTask> orderByComparator)
127 throws WorkflowException;
128
129 public List<WorkflowTask> search(
130 long companyId, long userId, String taskName, String assetTitle,
131 String assetType, Long[] assetPrimaryKey, Date dueDateGT,
132 Date dueDateLT, Boolean completed, Boolean searchByUserRoles,
133 boolean andOperator, int start, int end,
134 OrderByComparator<WorkflowTask> orderByComparator)
135 throws WorkflowException;
136
137 public List<WorkflowTask> search(
138 long companyId, long userId, String keywords, String assetTitle,
139 String[] assetTypes, Boolean completed, Boolean searchByUserRoles,
140 int start, int end,
141 OrderByComparator<WorkflowTask> orderByComparator)
142 throws WorkflowException;
143
144 public int searchCount(
145 long companyId, long userId, String keywords, Boolean completed,
146 Boolean searchByUserRoles)
147 throws WorkflowException;
148
149 public int searchCount(
150 long companyId, long userId, String taskName, String assetTitle,
151 String assetType, Long[] assetPrimaryKey, Date dueDateGT,
152 Date dueDateLT, Boolean completed, Boolean searchByUserRoles,
153 boolean andOperator)
154 throws WorkflowException;
155
156 public int searchCount(
157 long companyId, long userId, String keywords, String assetTitle,
158 String[] assetTypes, Boolean completed, Boolean searchByUserRoles)
159 throws WorkflowException;
160
161 public WorkflowTask updateDueDate(
162 long companyId, long userId, long workflowTaskId, String comment,
163 Date dueDate)
164 throws WorkflowException;
165
166 }