[jbpm-commits] JBoss JBPM SVN: r6368 - in jbpm4/trunk/modules: pvm/src/main/java/org/jbpm/pvm/internal/cmd and 1 other directories.
do-not-reply at jboss.org
do-not-reply at jboss.org
Fri May 21 02:18:23 EDT 2010
Author: rebody
Date: 2010-05-21 02:18:22 -0400 (Fri, 21 May 2010)
New Revision: 6368
Modified:
jbpm4/trunk/modules/api/src/main/java/org/jbpm/api/ExecutionService.java
jbpm4/trunk/modules/api/src/main/java/org/jbpm/api/TaskService.java
jbpm4/trunk/modules/pvm/src/main/java/org/jbpm/pvm/internal/cmd/StartProcessInstanceCmd.java
jbpm4/trunk/modules/pvm/src/main/java/org/jbpm/pvm/internal/svc/ExecutionServiceImpl.java
jbpm4/trunk/modules/pvm/src/main/java/org/jbpm/pvm/internal/svc/TaskServiceImpl.java
Log:
JBPM-2760 fix generics specification in ExecutionService and TaskService.
Modified: jbpm4/trunk/modules/api/src/main/java/org/jbpm/api/ExecutionService.java
===================================================================
--- jbpm4/trunk/modules/api/src/main/java/org/jbpm/api/ExecutionService.java 2010-05-21 06:10:39 UTC (rev 6367)
+++ jbpm4/trunk/modules/api/src/main/java/org/jbpm/api/ExecutionService.java 2010-05-21 06:18:22 UTC (rev 6368)
@@ -44,14 +44,14 @@
/** starts a new process instance for the ProcessDefinition with the given processDefinitionDbid.
* @param processDefinitionId the {@link ProcessDefinition#getId() unique id} of the process definition.
* @param variables are the initial values of the process variables that will be set before the execution starts. */
- ProcessInstance startProcessInstanceById(String processDefinitionId, Map<String, Object> variables);
+ ProcessInstance startProcessInstanceById(String processDefinitionId, Map<String, ?> variables);
/** starts a new process instance for the ProcessDefinition with the given processDefinitionDbid.
* @param processDefinitionId the {@link ProcessDefinition#getId() unique id} of the process definition.
* @param variables are the initial values of the process variables that will be set before the execution starts.
* @param processInstanceKey is a user provided reference for the new process instance that must be unique over all
* process versions with the same name. */
- ProcessInstance startProcessInstanceById(String processDefinitionId, Map<String, Object> variables, String processInstanceKey);
+ ProcessInstance startProcessInstanceById(String processDefinitionId, Map<String, ?> variables, String processInstanceKey);
/** starts a new process instance in the latest version of the given process definition.
* @param processDefinitionKey is the key of the process definition for which the latest version will be taken. */
Modified: jbpm4/trunk/modules/api/src/main/java/org/jbpm/api/TaskService.java
===================================================================
--- jbpm4/trunk/modules/api/src/main/java/org/jbpm/api/TaskService.java 2010-05-21 06:10:39 UTC (rev 6367)
+++ jbpm4/trunk/modules/api/src/main/java/org/jbpm/api/TaskService.java 2010-05-21 06:18:22 UTC (rev 6368)
@@ -31,7 +31,7 @@
import java.util.Set;
/** task management.
- *
+ *
* @author Tom Baeyens
* @author Alejandro Guizar
* @author Heiko Braun <heiko.braun at jboss.com>
@@ -40,42 +40,42 @@
/** Creates a task.
* The returned task will be transient.
- * Use {@link #saveTask(Task)} to persist the task. Only
- * after the invocation of {@link #saveTask(Task)}, the
+ * Use {@link #saveTask(Task)} to persist the task. Only
+ * after the invocation of {@link #saveTask(Task)}, the
* {@link Task#getId()} property will be initialized. */
Task newTask();
/** Creates a new subtask for the given task.
- * Make sure that the parent task is saved before the
+ * Make sure that the parent task is saved before the
* {@link Task#getId() Id} is taken.
* The returned task will be transient.
* Use {@link #saveTask(Task)} to persist the task. */
Task newTask(String parentTaskId);
- /** Saves the given task to persistent storage.
+ /** Saves the given task to persistent storage.
* @return the taskId */
String saveTask(Task task);
- /** Retrieves the task with the given identifier from persistent storage.
- * If no task with the given identifier exists,
+ /** Retrieves the task with the given identifier from persistent storage.
+ * If no task with the given identifier exists,
* the call returns <code>null</code>. */
Task getTask(String taskId);
/** assigns this task to the given assignee. */
void assignTask(String taskId, String userId);
- /** taking this task will prevent all other candidates from
- * taking and working on this task.
+ /** taking this task will prevent all other candidates from
+ * taking and working on this task.
* The inverse operation of putting the task back into the group
- * for someone else to take it, can be done by providing a null value
+ * for someone else to take it, can be done by providing a null value
* for userId in the {@link #assignTask(String, String)} method:
* <code>taskService.assignTask(taskId, null);</code>
* @throws JbpmException if this task already has been taken. */
void takeTask(String taskId, String userId);
/** Deletes this task, marks the related history task as completed.
- * If the task was created in the context
- * of a process execution, this operation may result in a process instance
+ * If the task was created in the context
+ * of a process execution, this operation may result in a process instance
* being triggered. */
void completeTask(String taskId);
@@ -84,62 +84,62 @@
* variables. If the task was created in the context of a process execution,
* this operation may result in a process instance being triggered to
* continue.*/
- void completeTask(String taskId, Map<String, Object> variables);
-
- /** Deletes this task, marks the related history task as completed
- * with the specified outcome. If the task was created in the context
- * of a process execution, this operation may result in a process instance
- * being triggered. The outcome in that case corresponds to an outgoing
+ void completeTask(String taskId, Map<String, ?> variables);
+
+ /** Deletes this task, marks the related history task as completed
+ * with the specified outcome. If the task was created in the context
+ * of a process execution, this operation may result in a process instance
+ * being triggered. The outcome in that case corresponds to an outgoing
* transition in the process. */
void completeTask(String taskId, String outcome);
-
+
/** Deletes this task, marks the related history task as completed with the
* specified outcome. The given variables are created (or they overwrite
* existing values) as task variables. If the task was created in the context
* of a process execution, this operation may result in a process instance
* being triggered. The outcome in that case corresponds to an outgoing
* transition in the process. */
- void completeTask(String taskId, String outcome, Map<String, Object> variables);
+ void completeTask(String taskId, String outcome, Map<String, ?> variables);
/** Deletes the task without completing it.
* The history information is kept in the DB.
- * If this task was created in the context of a process execution,
- * the execution remains active and the {@link ExecutionService#signalExecutionById(String)}
- * is to be given explicitly. */
+ * If this task was created in the context of a process execution,
+ * the execution remains active and the {@link ExecutionService#signalExecutionById(String)}
+ * is to be given explicitly. */
void deleteTask(String taskId);
/** deletes this task, including all history information */
void deleteTaskCascade(String taskId);
- /** Deletes the task without completing indicating the reason. Example reasons
+ /** Deletes the task without completing indicating the reason. Example reasons
* could be: "failed", "error", "exited", "obsolete" or "deleted".
* The history information is kept in the DB.
- * The reason ends up as the state in the {@link HistoryActivityInstance}.
- * If this task was created in the context of a process execution,
- * the execution remains active and the {@link ExecutionService#signalExecutionById(String)}
- * is to be given explicitly. */
+ * The reason ends up as the state in the {@link HistoryActivityInstance}.
+ * If this task was created in the context of a process execution,
+ * the execution remains active and the {@link ExecutionService#signalExecutionById(String)}
+ * is to be given explicitly. */
void deleteTask(String taskId, String reason);
/** add a role to a given task.
* @param participationType specifies the kind of involvement of the participatingUser
* in this task. see {@link Participation} for default constants. */
void addTaskParticipatingUser(String taskId, String userId, String participationType);
-
+
/** add a role to a given task.
* @param participationType specifies the kind of involvement of the participatingUser
* in this task. see {@link Participation} for default constants. */
void addTaskParticipatingGroup(String taskId, String groupId, String participationType);
-
+
/** get roles related to a given task. */
List<Participation> getTaskParticipations(String taskId);
-
- /** removes a role to a given task. Nothing happens (no exception) if
+
+ /** removes a role to a given task. Nothing happens (no exception) if
* the role does not exist.
* @param participationType specifies the kind of involvement of the participatingUser
* in this task. see {@link Participation} for default constants. */
void removeTaskParticipatingUser(String taskId, String userId, String participationType);
-
- /** removes a role to a given task. Nothing happens (no exception) if
+
+ /** removes a role to a given task. Nothing happens (no exception) if
* the role does not exist.
* @param participationType specifies the kind of involvement of the participatingUser
* in this task. see {@link Participation} for default constants. */
@@ -148,7 +148,7 @@
/** create a new query for tasks */
TaskQuery createTaskQuery();
- /** list of tasks that are assigned to the given user.
+ /** list of tasks that are assigned to the given user.
* Returns an empty list in case no such tasks exist. */
List<Task> findPersonalTasks(String userId);
@@ -162,8 +162,8 @@
/** add a comment to a task */
HistoryComment addTaskComment(String taskId, String message);
- /** get the list of comments made to a task. this will
- * fetch all the comments and recursively all replies to those
+ /** get the list of comments made to a task. this will
+ * fetch all the comments and recursively all replies to those
* comments. */
List<HistoryComment> getTaskComments(String taskId);
@@ -175,7 +175,7 @@
void deleteComment(String commentId);
/** creates or overwrites the variable values on the given task */
- void setVariables(String taskId, Map<String, Object> variables);
+ void setVariables(String taskId, Map<String, ?> variables);
/** retrieves a variable */
Object getVariable(String taskId, String variableName);
@@ -185,8 +185,8 @@
/** retrieves a map of variables */
Map<String, Object> getVariables(String taskId, Set<String> variableNames);
-
+
/** the set of possible valid outcomes for this task.
- * An empty set means that any value is possible. */
+ * An empty set means that any value is possible. */
Set<String> getOutcomes(String taskId);
}
Modified: jbpm4/trunk/modules/pvm/src/main/java/org/jbpm/pvm/internal/cmd/StartProcessInstanceCmd.java
===================================================================
--- jbpm4/trunk/modules/pvm/src/main/java/org/jbpm/pvm/internal/cmd/StartProcessInstanceCmd.java 2010-05-21 06:10:39 UTC (rev 6367)
+++ jbpm4/trunk/modules/pvm/src/main/java/org/jbpm/pvm/internal/cmd/StartProcessInstanceCmd.java 2010-05-21 06:18:22 UTC (rev 6368)
@@ -41,7 +41,7 @@
protected String processDefinitionId;
protected String executionKey;
- public StartProcessInstanceCmd(String processDefinitionId, Map<String, Object> variables, String executionKey) {
+ public StartProcessInstanceCmd(String processDefinitionId, Map<String, ?> variables, String executionKey) {
this.processDefinitionId = processDefinitionId;
this.variables = variables;
this.executionKey = executionKey;
Modified: jbpm4/trunk/modules/pvm/src/main/java/org/jbpm/pvm/internal/svc/ExecutionServiceImpl.java
===================================================================
--- jbpm4/trunk/modules/pvm/src/main/java/org/jbpm/pvm/internal/svc/ExecutionServiceImpl.java 2010-05-21 06:10:39 UTC (rev 6367)
+++ jbpm4/trunk/modules/pvm/src/main/java/org/jbpm/pvm/internal/svc/ExecutionServiceImpl.java 2010-05-21 06:18:22 UTC (rev 6368)
@@ -54,11 +54,11 @@
return commandService.execute(new StartProcessInstanceCmd(processDefinitionId, null, executionKey));
}
- public ProcessInstance startProcessInstanceById(String processDefinitionId, Map<String, Object> variables){
+ public ProcessInstance startProcessInstanceById(String processDefinitionId, Map<String, ?> variables){
return commandService.execute(new StartProcessInstanceCmd(processDefinitionId, variables, null));
}
- public ProcessInstance startProcessInstanceById(String processDefinitionId, Map<String, Object> variables, String executionKey){
+ public ProcessInstance startProcessInstanceById(String processDefinitionId, Map<String, ?> variables, String executionKey){
return commandService.execute(new StartProcessInstanceCmd(processDefinitionId, variables, executionKey));
}
Modified: jbpm4/trunk/modules/pvm/src/main/java/org/jbpm/pvm/internal/svc/TaskServiceImpl.java
===================================================================
--- jbpm4/trunk/modules/pvm/src/main/java/org/jbpm/pvm/internal/svc/TaskServiceImpl.java 2010-05-21 06:10:39 UTC (rev 6367)
+++ jbpm4/trunk/modules/pvm/src/main/java/org/jbpm/pvm/internal/svc/TaskServiceImpl.java 2010-05-21 06:18:22 UTC (rev 6368)
@@ -88,7 +88,7 @@
commandService.execute(new CompleteTaskCmd(taskId));
}
- public void completeTask(String taskId, Map<String, Object> variables) {
+ public void completeTask(String taskId, Map<String, ?> variables) {
completeTask(taskId, null, variables);
}
@@ -96,7 +96,7 @@
commandService.execute(new CompleteTaskCmd(taskId, outcome));
}
- public void completeTask(String taskId, String outcome, Map<String, Object> variables) {
+ public void completeTask(String taskId, String outcome, Map<String, ?> variables) {
SetTaskVariablesCmd setTaskVariablesCmd = new SetTaskVariablesCmd(taskId);
setTaskVariablesCmd.setVariables(variables);
CompositeCmd compositeCmd = new CompositeCmd();
@@ -194,7 +194,7 @@
return commandService.execute(new GetTaskVariablesCmd(taskDbid, variableNames));
}
- public void setVariables(String taskDbid, Map<String, Object> variables) {
+ public void setVariables(String taskDbid, Map<String, ?> variables) {
SetTaskVariablesCmd cmd = new SetTaskVariablesCmd(taskDbid);
cmd.setVariables(variables);
commandService.execute(cmd);
More information about the jbpm-commits
mailing list