[jboss-user] [jBPM Users] - Re: how to get all tokens from processinstance
peterbasutkar@gmail.com
do-not-reply at jboss.com
Sun Nov 8 07:55:50 EST 2009
i dont want only running task............i am using following this code for getting completed and pending token(task node) as well as running token information but this is keeping track of token data(means previously completed and currenrently running task) if an only if we are performing any signaling,but i want all completed and pending token information irrespective of signaling,means it should give me information when task is started,when it is ended for that processInstance
ProcessInstance processInstance = getProcessInstance();
LoggingInstance loggingInstance = processInstance.getLoggingInstance();
List logs = loggingInstance.getLogs(SignalLog.class);
for (SignalLog signalLog : logs) {
List children = signalLog.getChildren();
if(children.get(0) != null){
if(children.get(0) instanceof TransitionLog){
TransitionLog transitionLog = (TransitionLog)children.get(0);
System.out.println("Node Name:::"+transitionLog.getSourceNode().getName());
System.out.println("Node Start Time:::");
System.out.println("Node End Time:::"+transitionLog.getDate());
System.out.println("=====================================================");
}
if(children.get(0) instanceof NodeLog){
NodeLog nodeLog = (NodeLog)children.get(0);
System.out.println("Node Name:::"+nodeLog.getNode().getName());
System.out.println("Node Start Time:::"+nodeLog.getEnter());
System.out.println("Node End Time:::"+nodeLog.getLeave());
System.out.println("=====================================================");
}
}
}
return "success";
}
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4264443#4264443
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4264443
More information about the jboss-user
mailing list