Package org.openhab.model.rule.rules

Examples of org.openhab.model.rule.rules.RuleModel.eResource()


        try {
            Object initialValue = var.getRight()==null ? null : scriptEngine.newScriptFromXExpression(var.getRight()).execute();
          evaluationContext.newValue(QualifiedName.create(var.getName()), initialValue);
        } catch (ScriptExecutionException e) {
          logger.warn("Variable '{}' on rule file '{}' cannot be initialized with value '{}': {}",
              new String[] { var.getName(), ruleModel.eResource().getURI().path(), var.getRight().toString(), e.getMessage() });
        }
      }
      }
      ruleModel.eAdapters().add(new RuleContextAdapter(evaluationContext));
    return evaluationContext;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.