public final class IlrStatementHelper
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
static IlrSimpleBindingStatement |
getBinding(IlrRuleStatement rule,
IlrConcept concept)
Searches the first binding of the specified rule, which binds an object with a concept
concept. |
static IlrSimpleBindingStatement |
getBinding(IlrRuleStatement rule,
IlrSyntaxTree.Node node)
Searches the binding corresponding to the specified syntax tree node.
|
static IlrSimpleBindingStatement |
getBinding(IlrRuleStatement rule,
java.lang.String varName)
Searches the binding named
name in the list of variables
used in a rule statement. |
static IlrNamedStatement |
getNamedStatement(IlrRuleStatement rule,
java.lang.String name)
Gets the named statement with name
name. |
static IlrSimpleBindingStatement |
getPreviousBinding(IlrRuleStatement rule,
IlrConditionStatement from,
IlrConcept concept)
Searches the last binding of the specified rule, which binds an object with a concept
concept. |
static IlrSimpleActionStatement |
getUpdate(IlrRuleStatement rule,
java.lang.String varName,
boolean inActions)
Gets the update statement with the specified name, if any.
|
static IlrSimpleActionStatement |
getUpdateContext(IlrRuleStatement rule,
boolean inActions)
Gets the update context statement, if any.
|
static boolean |
hasElsePart(IlrRuleStatement rule)
Tests if a rule statement has an else part.
|
public static IlrSimpleBindingStatement getBinding(IlrRuleStatement rule, java.lang.String varName)
name in the list of variables
used in a rule statement.rule - The rule statement.varName - The name of the variable to look for.IlrSimpleBindingStatement or null.public static IlrSimpleBindingStatement getBinding(IlrRuleStatement rule, IlrConcept concept)
concept.rule - The rule statement.concept - The concept.IlrSimpleBindingStatement or null.public static IlrSimpleBindingStatement getPreviousBinding(IlrRuleStatement rule, IlrConditionStatement from, IlrConcept concept)
concept.rule - The rule statement.concept - The concept.IlrSimpleBindingStatement or null.public static IlrSimpleBindingStatement getBinding(IlrRuleStatement rule, IlrSyntaxTree.Node node)
rule - The rule statement.node - The syntax tree node to look for.name or null if not found.public static IlrSimpleActionStatement getUpdateContext(IlrRuleStatement rule, boolean inActions)
rule - The rule.inActions - if true, look in 'actions'. Look in 'else actions' otherwise.public static IlrSimpleActionStatement getUpdate(IlrRuleStatement rule, java.lang.String varName, boolean inActions)
varName - inActions - If true, look in 'actions'. Look in 'else actions' otherwise.public static boolean hasElsePart(IlrRuleStatement rule)
true if the provided rule statement contains else-actions.public static IlrNamedStatement getNamedStatement(IlrRuleStatement rule, java.lang.String name)
name.rule - The rule statement from which to retrieve the named statement.name - The name of the named statement.null.© Copyright IBM Corp. 1987, 2017