Package org.openl.rules.dt.element
Class Condition
- java.lang.Object
-
- org.openl.rules.dt.element.FunctionalRow
-
- org.openl.rules.dt.element.Condition
-
- All Implemented Interfaces:
ICondition,IDecisionRow,IBaseCondition,IBaseDecisionRow
public class Condition extends FunctionalRow implements ICondition
-
-
Field Summary
-
Fields inherited from class org.openl.rules.dt.element.FunctionalRow
expr, method, paramInitialized, params, paramsUniqueNames, ruleExecutionType, storage
-
Fields inherited from interface org.openl.rules.dt.IBaseCondition
EMPTY
-
-
Constructor Summary
Constructors Constructor Description Condition(String name, int row, ILogicalTable table, DTScale.RowScale scale)
-
Method Summary
-
Methods inherited from class org.openl.rules.dt.element.FunctionalRow
clearExprs, clearParamValues, getCodeTable, getDecisionTable, getExpr, getExprValue, getInfoTable, getMethod, getName, getNumberOfParams, getNumberOfRules, getParamPresentation, getParamsTable, getParamValue, getSourceCodeModule, getStorage, getStorageValue, getValueCell, hasDeclaredParams, hasFormula, hasFormulas, isEmpty, isEqual, loadValue, loadValues, nValues, prepare, prepareParams, prepareParams, removeDebugInformation, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.openl.rules.dt.IBaseDecisionRow
getDecisionTable, getExprValue, getMethod, getName, getNumberOfParams, getNumberOfRules, getValueCell, isEmpty, removeDebugInformation
-
Methods inherited from interface org.openl.rules.dt.element.IDecisionRow
clearExprs, clearParamValues, getExpr, getInfoTable, getParamPresentation, getParamValue, getSourceCodeModule, hasDeclaredParams, hasFormula, hasFormulas, isEqual, loadValue, loadValues, prepare, prepareParams
-
-
-
-
Constructor Detail
-
Condition
public Condition(String name, int row, ILogicalTable table, DTScale.RowScale scale)
-
-
Method Detail
-
getParams
public IParameterDeclaration[] getParams()
- Specified by:
getParamsin interfaceIBaseDecisionRow- Overrides:
getParamsin classFunctionalRow
-
getConditionEvaluator
public IConditionEvaluator getConditionEvaluator()
- Specified by:
getConditionEvaluatorin interfaceIBaseCondition
-
setConditionEvaluator
public void setConditionEvaluator(IConditionEvaluator conditionEvaluator)
- Specified by:
setConditionEvaluatorin interfaceICondition
-
isAction
public boolean isAction()
- Specified by:
isActionin interfaceIDecisionRow
-
isCondition
public boolean isCondition()
- Specified by:
isConditionin interfaceIDecisionRow
-
getEvaluator
public IMethodCaller getEvaluator()
- Specified by:
getEvaluatorin interfaceIBaseCondition
-
setEvaluator
public void setEvaluator(IMethodCaller evaluator)
- Specified by:
setEvaluatorin interfaceICondition
-
calculateCondition
public DecisionValue calculateCondition(int ruleN, Object target, Object[] dtParams, IRuntimeEnv env)
- Specified by:
calculateConditionin interfaceICondition
-
setComparisonCast
public void setComparisonCast(IOpenCast comparisonCast)
- Specified by:
setComparisonCastin interfaceICondition
-
getLocalField
public static IOpenField getLocalField(IOpenField f)
-
isDependentOnInputParams
public boolean isDependentOnInputParams()
- Specified by:
isDependentOnInputParamsin interfaceICondition
-
getUserDefinedExpressionSource
public IOpenSourceCodeModule getUserDefinedExpressionSource()
- Specified by:
getUserDefinedExpressionSourcein interfaceICondition
-
getExpressionSource
protected IOpenSourceCodeModule getExpressionSource(TableSyntaxNode tableSyntaxNode, IMethodSignature signature, IOpenClass methodParamType, IOpenClass declaringClass, OpenL openl, IBindingContext bindingContext) throws Exception
- Overrides:
getExpressionSourcein classFunctionalRow- Throws:
Exception
-
getNumberOfEmptyRules
public int getNumberOfEmptyRules(int paramIndex)
- Specified by:
getNumberOfEmptyRulesin interfaceICondition
-
setConditionParametersUsed
public void setConditionParametersUsed(boolean conditionParametersUsed)
Description copied from interface:IConditionIdentifier to detect whatever condition parameter is used in expression- Specified by:
setConditionParametersUsedin interfaceICondition- Parameters:
conditionParametersUsed-truewhen it's used, otherwise false
-
isRuleIdOrRuleNameUsed
public boolean isRuleIdOrRuleNameUsed()
- Specified by:
isRuleIdOrRuleNameUsedin interfaceICondition
-
setRuleIdOrRuleNameUsed
public void setRuleIdOrRuleNameUsed(boolean ruleIdOrRuleNameUsed)
- Specified by:
setRuleIdOrRuleNameUsedin interfaceICondition
-
isDependentOnOtherColumnsParams
public boolean isDependentOnOtherColumnsParams()
- Specified by:
isDependentOnOtherColumnsParamsin interfaceICondition
-
setDependentOnOtherColumnsParams
public void setDependentOnOtherColumnsParams(boolean dependentOnOtherColumnsParams)
- Specified by:
setDependentOnOtherColumnsParamsin interfaceICondition
-
-