public BusinessRuleTaskActivityBehavior createBusinessRuleTaskActivityBehavior(
      BusinessRuleTask businessRuleTask) {
    BusinessRuleTaskActivityBehavior ruleActivity = null;
    if (StringUtils.isNotEmpty(businessRuleTask.getClassName())) {
      try {
        Class<?> clazz = Class.forName(businessRuleTask.getClassName());
        ruleActivity = (BusinessRuleTaskActivityBehavior) clazz.newInstance();
      } catch (Exception e) {
        throw new ActivitiException("Could not instiate businessRuleTask class: ", e);
      }
    } else {
      ruleActivity = new BusinessRuleTaskActivityBehavior();
    }

    for (String ruleVariableInputObject : businessRuleTask.getInputVariables()) {
      ruleActivity.addRuleVariableInputIdExpression(
          expressionManager.createExpression(ruleVariableInputObject.trim()));
    }

    for (String rule : businessRuleTask.getRuleNames()) {
      ruleActivity.addRuleIdExpression(expressionManager.createExpression(rule.trim()));
    }

    ruleActivity.setExclude(businessRuleTask.isExclude());

    if (businessRuleTask.getResultVariableName() != null
        && businessRuleTask.getResultVariableName().length() > 0) {
      ruleActivity.setResultVariable(businessRuleTask.getResultVariableName());
    } else {
      ruleActivity.setResultVariable("org.activiti.engine.rules.OUTPUT");
    }

    return ruleActivity;
  }
 @Override
 protected void performUpdates(Object valueObject, Object targetObject) {
   ((BusinessRuleTask) targetObject).setValues(((BusinessRuleTask) valueObject));
 }