分类: Java
2008-06-09 17:40:04
...
//创建起始任务
TaskInstance taskInstance = processInstance.getTaskMgmtInstance.createStartTaskInstance();
.........
//完成起始任务,继续流程执行
taskInstance.end();
public class TasgMgmtIntance extends ModuleInstance()
{
……
public TaskInstance createStartTaskInstance()
{
……
taskInstance.setActorId(
SecurityHelp.getAuthenticatedActorId());
return taskInstance;
}
……
}
public abstract class SecurityHelp()
{
public static String getAuthenticatedActorId()
{
……
AuthenticationService authenticationService =
jbpmContext.getService().get AuthenticationService();
if(authenticationService != null)
actorId = authenticationService.getActorId();
……
return actorId;
}
}