Package com.founder.fix.fixflow.core.impl

Examples of com.founder.fix.fixflow.core.impl.ProcessEngineConfigurationImpl


   * 获取配置的列信息,有序,且逗号分开,用户select或insert的字段字符串
   * @param tableId
   * @return
   */
  public static String getColumnString(String tableId){
    ProcessEngineConfigurationImpl processEngineConfigurationImpl = ProcessEngineManagement.getDefaultProcessEngine().getProcessEngineConfiguration();
    DataBaseTable dataBaseTable = processEngineConfigurationImpl.getDataBaseTable(tableId);
    if(dataBaseTable == null){
      throw new FixFlowException("未找到id为"+tableId+"的table配置");
    }
    return getColumnString(dataBaseTable);
  }
View Full Code Here


    String columnString = sbColumn.toString().substring(0,sbColumn.toString().length()-1);
    return columnString;
  }
 
  public static String getColumnStringWithOutArchiveTime(String tableId){
    ProcessEngineConfigurationImpl processEngineConfigurationImpl = ProcessEngineManagement.getDefaultProcessEngine().getProcessEngineConfiguration();
    DataBaseTable dataBaseTable = processEngineConfigurationImpl.getDataBaseTable(tableId);
    if(dataBaseTable == null){
      throw new FixFlowException("未找到id为"+tableId+"的table配置");
    }
    StringBuilder sbColumn = new StringBuilder();
    for(Column column :dataBaseTable.getColumn()){
View Full Code Here

    return executeBusinessRules(ruleId,parameter,null);
  }

  @Override
  public Object executeBusinessRules(String ruleId, Object parameter, Map<String, Object> configMap) {
    ProcessEngineConfigurationImpl processEngineConfiguration=Context.getProcessEngineConfiguration();
    groovyShell.setVariable("sysRulesConfig", Context.getProcessEngineConfiguration());
    groovyShell.setVariable("parameter", parameter);
    groovyShell.setVariable("sqlCommand", new SqlCommand(Context.getDbConnection()));
    if(configMap!=null){
     
      for (String mapKey : configMap.keySet()) {
        groovyShell.setVariable(mapKey, configMap.get(mapKey));
      }
     
    }
    Rule rule = processEngineConfiguration.getRule(ruleId);
    Object returnObj =  groovyShell.evaluate(rule.getSqlValue());
    return returnObj;
  }
View Full Code Here

  @Override
  public <T> T executeBusinessRules(String ruleId, Object parameter,T classReturn, Map<String, Object> configMap) {
   
   
    try {
      ProcessEngineConfigurationImpl processEngineConfiguration=Context.getProcessEngineConfiguration();
      interpreter.set("sysRulesConfig", Context.getProcessEngineConfiguration());
      interpreter.set("parameter", parameter);
      interpreter.set("sqlCommand", new SqlCommand(Context.getDbConnection()));
      if(configMap!=null){
       
        for (String mapKey : configMap.keySet()) {
          interpreter.set(mapKey, configMap.get(mapKey));
        }
       
      }
      Rule rule = processEngineConfiguration.getRule(ruleId);
      T returnObj =  (T)interpreter.eval(rule.getSqlValue());
      return returnObj;
    } catch (EvalError e) {
      // TODO Auto-generated catch block
      e.printStackTrace();
View Full Code Here

  }

  @Override
  public Object executeBusinessRules(String ruleId, Object parameter, Map<String, Object> configMap) {
    try {
      ProcessEngineConfigurationImpl processEngineConfiguration=Context.getProcessEngineConfiguration();
      interpreter.set("sysRulesConfig", Context.getProcessEngineConfiguration());
      interpreter.set("parameter", parameter);
      interpreter.set("sqlCommand", new SqlCommand(Context.getDbConnection()));
      if(configMap!=null){
       
        for (String mapKey : configMap.keySet()) {
          interpreter.set(mapKey, configMap.get(mapKey));
        }
       
      }
      Rule rule = processEngineConfiguration.getRule(ruleId);
      Object returnObj =  (Object)interpreter.eval(rule.getSqlValue());
      return returnObj;
    } catch (EvalError e) {
      // TODO Auto-generated catch block
      e.printStackTrace();
View Full Code Here

  @SuppressWarnings("unchecked")
  @Override
  public <T> T executeBusinessRules(String ruleId, Object parameter,T classReturn, Map<String, Object> configMap) {
   
    ProcessEngineConfigurationImpl processEngineConfiguration=Context.getProcessEngineConfiguration();
    groovyShell.setVariable("sysRulesConfig", Context.getProcessEngineConfiguration());
    groovyShell.setVariable("parameter", parameter);
    groovyShell.setVariable("sqlCommand", new SqlCommand(Context.getDbConnection()));
    if(configMap!=null){
     
      for (String mapKey : configMap.keySet()) {
        groovyShell.setVariable(mapKey, configMap.get(mapKey));
      }
     
    }
    Rule rule = processEngineConfiguration.getRule(ruleId);
    T returnObj =  (T)groovyShell.evaluate(rule.getSqlValue());
    return returnObj;
  }
View Full Code Here

      return commandMessage;

    }

    // 国际化处理
    ProcessEngineConfigurationImpl processEngineConfiguration = ProcessEngineManagement.getDefaultProcessEngine().getProcessEngineConfiguration();
    Boolean booleanTemp = StringUtil.getBoolean(processEngineConfiguration.getInternationalizationConfig().getIsEnable());

    if (booleanTemp) {
      String processId = this.getProcessDefinitionId();
      String cType = processEngineConfiguration.getTaskCommandDefMap().get(this.getCommandType()).getType();
      String nameTemp = null;
      if (cType.equals("system")) {
        nameTemp = ResourcesUtil.getResourcesValue(FixFlowResources.TaskComandResource,
            "System_" + commandId);
View Full Code Here

TOP

Related Classes of com.founder.fix.fixflow.core.impl.ProcessEngineConfigurationImpl

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.