use of org.knime.base.node.rules.engine.RuleEngineSettings in project knime-core by knime.
the class PMMLRuleEditorNodeModel method validateSettings.
/**
* {@inheritDoc}
*/
@Override
protected void validateSettings(final NodeSettingsRO settings) throws InvalidSettingsException {
RuleEngineSettings res = new RuleEngineSettings();
res.loadSettings(settings);
RuleFactory ruleFactory = RuleFactory.getInstance(RuleNodeSettings.PMMLRule).cloned();
ruleFactory.disableColumnChecks();
ruleFactory.disableFlowVariableChecks();
Map<String, FlowVariable> flowVars = getAvailableInputFlowVariables();
for (String rule : res.rules()) {
try {
ruleFactory.parse(rule, null, flowVars);
} catch (ParseException e) {
throw new InvalidSettingsException(e.getMessage(), e);
}
}
}
Aggregations