|
Oracle Business Rules Java API Reference 10g (10.1.3.1.0) B28966-01 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
java.util.AbstractMap
java.util.HashMap
oracle.rules.sdk.editor.ruleset.RuleComponent
oracle.rules.sdk.editor.ruleset.AdvancedExpression
An AdvancedExpression is a String consisting of variables, calls, literals, and operators. AdvancedExpression parses the input String and returns information about the location and source of errors. It also provides option choices for operators and expression terms.
The rules expression language supported by the rule SDK is the same as RL with the following exceptions:
An AdvancedExpresson can be used either as a Pattern test or as an Action parameter.
Field Summary | |
static java.lang.String |
PROP_CONSTANT |
static java.lang.String |
PROP_CONSTRUCTOR |
static java.lang.String |
PROP_CURSOR_POSITION |
static java.lang.String |
PROP_FUNCTION |
static java.lang.String |
PROP_OPERATOR |
static java.lang.String |
PROP_TOKEN_UNDER_CURSOR |
static java.lang.String |
PROP_VALUE |
static java.lang.String |
PROP_VARIABLE |
Constructor Summary | |
AdvancedExpression(oracle.rules.sdk.datamodel.DataModel dataModel) |
|
AdvancedExpression(oracle.rules.sdk.datamodel.DataModel dataModel, java.lang.String varDefID) This constructor is for internal use by the DataModel editor. |
Method Summary | |
java.lang.String |
append(java.lang.String str) Append the given string to the end of the existing Value Behavior is the same as the append method of java.lang.StringBuffer, except that a null value of str inserts the String "null". |
int[][] |
balanced() Matches up operators which come in pairs, such as ( ), then returns an array of ordered pairs of the matches. |
void |
checkUse(java.lang.String factType, java.lang.String op) |
java.lang.Object |
get(java.lang.Object key) Generic property getter inheirited from RuleComponent . |
java.lang.String |
getConstant() |
java.lang.String |
getConstantConstraint() |
java.lang.String[] |
getConstantOptions() |
int |
getConstantSelected() |
java.lang.String |
getConstructor() |
java.lang.String |
getConstructorConstraint() |
java.lang.String[] |
getConstructorOptions() |
int |
getConstructorSelected() |
int |
getCursorPosition() |
java.lang.String |
getFunction() |
java.lang.String |
getFunctionConstraint() |
java.lang.String[] |
getFunctionOptions() |
int |
getFunctionSelected() |
java.lang.String |
getOperator() |
java.lang.String |
getOperatorConstraint() |
java.lang.String[] |
getOperatorOptions() |
int |
getOperatorSelected() |
java.lang.String[] |
getPropertyNames() |
java.lang.String |
getResultType() |
Token |
getTokenUnderCursor() If the cursor is in a token or white space preceeding the token, returns a description of the token. |
java.lang.String |
getValue() |
java.lang.String |
getValueConstraint() |
java.lang.String[] |
getValueOptions() |
int |
getValueSelected() |
java.lang.String |
getVariable() |
java.lang.String |
getVariableConstraint() |
java.lang.String[] |
getVariableOptions() |
int |
getVariableSelected() |
java.lang.String |
insert(int offset, java.lang.String str) Insert the given string at the given position of the Value. |
java.lang.Object |
put(java.lang.Object key, java.lang.Object value) Generic property setter. |
java.lang.String |
replace(int start, int end, java.lang.String str) Insert the given string at the given position of the Value String. |
void |
setConstant(java.lang.String constant) |
void |
setConstantConstraint(java.lang.String constantConstraint) |
void |
setConstantOptions(java.lang.String[] constantOptions) |
void |
setConstructor(java.lang.String constructor) |
void |
setConstructorConstraint(java.lang.String constructorConstraint) |
void |
setConstructorOptions(java.lang.String[] constructorOptions) |
void |
setCursorPosition(int cursorPosition) |
void |
setFunction(java.lang.String function) |
void |
setFunctionConstraint(java.lang.String functionConstraint) |
void |
setFunctionOptions(java.lang.String[] functionOptions) |
void |
setOperator(java.lang.String operator) |
void |
setOperatorConstraint(java.lang.String operatorConstraint) |
void |
setOperatorOptions(java.lang.String[] operatorOptions) |
void |
setShowConstructorsWithFunctions(boolean b) Include Constructors in the Function options list |
void |
setValue(java.lang.String value) |
void |
setValueConstraint(java.lang.String valueConstraint) |
void |
setValueOptions(java.lang.String[] valueOptions) |
void |
setVariable(java.lang.String variable) |
void |
setVariableConstraint(java.lang.String variableConstraint) |
void |
setVariableOptions(java.lang.String[] variableOptions) |
int[] |
unbalanced() Matches up operators which come in pairs, such as ( ), then returns an array of integers indicating unmatched grouping operators. |
void |
validate() Validate the expression. |
Methods inherited from class oracle.rules.sdk.editor.ruleset.RuleComponent |
clear, discardCopy, get, getConstraint, getConstraintList, getCustom, getDescription, getID, getOptions, getParent, getParentTable, getRange, getRuleDictionary, getSelected, remove, restoreCopy, saveCopy, setCustom, setDescription, setRuleDictionary, toString |
Methods inherited from class java.util.HashMap |
clone, containsKey, containsValue, entrySet, isEmpty, keySet, putAll, size, values |
Methods inherited from class java.util.AbstractMap |
equals, hashCode |
Methods inherited from class java.lang.Object |
getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.util.Map |
equals, hashCode |
Field Detail |
public static final java.lang.String PROP_VALUE
public static final java.lang.String PROP_CURSOR_POSITION
public static final java.lang.String PROP_CONSTANT
public static final java.lang.String PROP_OPERATOR
public static final java.lang.String PROP_VARIABLE
public static final java.lang.String PROP_FUNCTION
public static final java.lang.String PROP_CONSTRUCTOR
public static final java.lang.String PROP_TOKEN_UNDER_CURSOR
Constructor Detail |
public AdvancedExpression(oracle.rules.sdk.datamodel.DataModel dataModel)
public AdvancedExpression(oracle.rules.sdk.datamodel.DataModel dataModel, java.lang.String varDefID)
dataModel
-varDefID
- - the id of the variable being defined.Method Detail |
public java.lang.Object put(java.lang.Object key, java.lang.Object value)
RuleComponent
A put() with either null key or null value throws a NullPointerException.
A put() with a key that is not a String throws a ClassCastException
A put() of a value that is not of the correct type for the key throws a ClassCastException.
Bean properties which have no set() method are read only, and cannot be modified using the put(). Attempting to do so throws a runtime IllegalArgumentException. PROP_ID, and PROP_*_SELECTED are always read only.
put
in interface java.util.Map
put
in class RuleComponent
key
- the key of the property to setvalue
- the value of the named property to setpublic java.lang.Object get(java.lang.Object key)
RuleComponent
RuleComponent
.
Please see the specific bean class for a list of properties.
get
in interface java.util.Map
get
in class RuleComponent
key
- a String containing the property name to be fetched.public void setShowConstructorsWithFunctions(boolean b)
public int[][] balanced()
public int[] unbalanced()
public void validate() throws RuleEditorException, RuleEditorSDKException
validate
in class RuleComponent
RuleEditorException,
- RuleEditorSDKException then stops further validationRuleEditorSDKException
- incorrect SDK usageRuleEditorException
- for user input errorspublic java.lang.String getResultType()
public void checkUse(java.lang.String factType, java.lang.String op) throws RuleEditorException
RuleEditorException
public java.lang.String insert(int offset, java.lang.String str)
0 <= offset <= getExpression.length()
offset
- where to insert the text, 0 basedstr
- the text to insertpublic java.lang.String replace(int start, int end, java.lang.String str)
0 <= start <= end <= getExpression.length()
start
- beginning index of substring to replace, 0 basedend
- ending index of substring to replace, 0 basedstr
- the text to insertpublic java.lang.String append(java.lang.String str)
str
- the String to appendpublic java.lang.String[] getPropertyNames()
getPropertyNames
in class RuleComponent
public java.lang.String getValue()
public void setValue(java.lang.String value)
public java.lang.String getValueConstraint()
public void setValueConstraint(java.lang.String valueConstraint)
public java.lang.String[] getValueOptions()
public void setValueOptions(java.lang.String[] valueOptions)
public int getValueSelected()
public int getCursorPosition()
public void setCursorPosition(int cursorPosition)
public java.lang.String getConstant()
public void setConstant(java.lang.String constant)
public java.lang.String getConstantConstraint()
public void setConstantConstraint(java.lang.String constantConstraint)
public java.lang.String[] getConstantOptions()
public void setConstantOptions(java.lang.String[] constantOptions)
public int getConstantSelected()
public java.lang.String getOperator()
public void setOperator(java.lang.String operator)
public java.lang.String getOperatorConstraint()
public void setOperatorConstraint(java.lang.String operatorConstraint)
public java.lang.String[] getOperatorOptions()
public void setOperatorOptions(java.lang.String[] operatorOptions)
public int getOperatorSelected()
public java.lang.String getVariable()
public void setVariable(java.lang.String variable)
public java.lang.String getVariableConstraint()
public void setVariableConstraint(java.lang.String variableConstraint)
public java.lang.String[] getVariableOptions()
public void setVariableOptions(java.lang.String[] variableOptions)
public int getVariableSelected()
public java.lang.String getFunction()
public void setFunction(java.lang.String function)
public java.lang.String getFunctionConstraint()
public void setFunctionConstraint(java.lang.String functionConstraint)
public java.lang.String[] getFunctionOptions()
public void setFunctionOptions(java.lang.String[] functionOptions)
public int getFunctionSelected()
public java.lang.String getConstructor()
public void setConstructor(java.lang.String constructor)
public java.lang.String getConstructorConstraint()
public void setConstructorConstraint(java.lang.String constructorConstraint)
public java.lang.String[] getConstructorOptions()
public void setConstructorOptions(java.lang.String[] constructorOptions)
public int getConstructorSelected()
public Token getTokenUnderCursor()
|
Oracle Business Rules Java API Reference 10g (10.1.3.1.0) B28966-01 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |