?? moneycheckdecisionhandler.java
字號:
/**
*
*/
package com.firstflow.decision;
import org.jbpm.context.exe.ContextInstance;
import org.jbpm.graph.exe.ExecutionContext;
import org.jbpm.graph.node.DecisionHandler;
/**
* @author linly
* com.firstflow.decision.MoneyCheckDecisionHandler
* Mar 24, 2008
*/
public class MoneyCheckDecisionHandler implements DecisionHandler {
/**
*
*/
private static final long serialVersionUID = -6006030520398243985L;
/* (non-Javadoc)
* @see org.jbpm.graph.node.DecisionHandler#decide(org.jbpm.graph.exe.ExecutionContext)
*/
//@Override
public String decide(ExecutionContext executionContext) throws Exception {
/*
* 根據業務邏輯,選者流程方向
*/
ContextInstance ci = executionContext.getContextInstance();
Integer money = (Integer)ci.getVariable("money");
if(money > 5000){
//返回中文的流程轉向名稱
return ">5000元總經理審批";
}else{
return "<5000元 財務撥款";
}
}
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -