cancel
Showing results for 
Search instead for 
Did you mean: 

Command Class for Task Assignment?

chrisx_212
Champ in-the-making
Champ in-the-making
Hello, all.

In the package org.activiti.engine.impl.cmd, we have a lot of classes that is called when certain events happen. Such as claiming task, we have ClaimTaskCmd.java.

I'd like to know which one is the class for assigning task within that package? From what I know, the class for that is org.activiti.engine.impl.history.handler.UserTaskAssignmentHandler but it's not of the same package. Or it's the only way? Regardless of the Activiti versions?

Thanks.
3 REPLIES 3

martin_grofcik
Confirmed Champ
Confirmed Champ
Hi Chris,

e.g. activiti6:


  public void setAssignee(String taskId, String userId) {
    commandExecutor.execute(new AddIdentityLinkCmd(taskId, userId, AddIdentityLinkCmd.IDENTITY_USER, IdentityLinkType.ASSIGNEE));
  }

Regards
Martin

chrisx_212
Champ in-the-making
Champ in-the-making
Thanks… though that didn't quite hit the mark (but it's near). If I use that class' execute method, the taskId will be about the old task. I want to see which class deals with similar thing, except the taskId is about the new task. May I know which class?

Thanks.

jbarrez
Star Contributor
Star Contributor
Not sure I'm following? Can't you trace the event back to where it's being thrown in your IDE?