|
Oracle Fusion Middleware Java API Reference for Oracle Business Rules 11g Release 1 (11.1.1.7) E10663-11 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectoracle.rules.sdk2.dictionary.DictionaryObject
oracle.rules.sdk2.dictionary.DictionaryComponent
oracle.rules.sdk2.ruleset.RuleComponent
oracle.rules.sdk2.ruleset.UnnamedRuleComponent
oracle.rules.sdk2.ruleset.Action
public class Action
An action, such as assert, assign, call, or retract.
When using this interface, selecting the Form property first will fix the options for target, which in turn will fix the number of expressions and the option list for each. The expressions cannot be added to the table; this is done automatically when the form or target is selected.
Actions are described using a combination of properties, dictated by the Form property:
Form | SimpleTestTable | ExpressionTable | ActionTable | Variable | Target |
---|---|---|---|---|---|
rl | - | - | - | - | RL |
call | - | arguments | - | - | function or method |
assert | - | object to assert | - | - | object to assert |
assert tree | - | tree to assert | - | - | tree to assert |
assert new | - | property values | - | - | fact type |
retract | - | fact to retract | - | - | fact to retract |
assign | - | RHS | - | - | LHS |
assign new | - | initial value | - | name | fact type |
expression | - | expression | - | - | - |
modify | - | property values | - | - | fact to modify |
synchronized | - | lock object | - | - | lock object |
if | - | boolean expression | if actions | - | - |
else if | - | boolean expression | if actions | - | - |
if test | test | - | if actions | - | - |
else if test | test | - | if actions | - | - |
else | - | - | else actions | - | - |
for | - | List expression | loop actions | loop var | list content type |
while | - | boolean expression | loop actions | - | - |
while test | test | - | loop actions | - | - |
return | - | return expression | - | - | - |
throw | - | throw expression | - | - | - |
try | - | - | try actions | - | - |
catch | - | - | catch actions | excep name | excep type |
finally | - | - | final actions | - | - |
The for action supports both for (i = 0; i < 10; i = i + 1) and for (Foo f : listFoo). The first form is deprecated. The UI should support the second form as follows: for (<type> <var> : <collection>) { The type is bound to Action.target, the var is bound to Action.variable, and collection is bound to Action.expression(0).value
Nested Class Summary | |
---|---|
class |
Action.FormProperty
|
class |
Action.TargetProperty
A target property can get and set its translated value using its expression parser. |
Nested classes/interfaces inherited from class oracle.rules.sdk2.dictionary.DictionaryComponent |
---|
DictionaryComponent.Diff, DictionaryComponent.DiffType |
Nested classes/interfaces inherited from interface java.util.Map |
---|
java.util.Map.Entry<K,V> |
Field Summary | |
---|---|
static java.lang.String |
FORM_ADVANCED
|
static java.lang.String |
FORM_ASSERT
|
static java.lang.String |
FORM_ASSERT_NEW
|
static java.lang.String |
FORM_ASSERT_TREE
|
static java.lang.String |
FORM_ASSIGN
|
static java.lang.String |
FORM_ASSIGN_NEW
|
static java.lang.String |
FORM_BASIC
|
static java.lang.String |
FORM_CALL
|
static java.lang.String |
FORM_CATCH
|
static java.lang.String |
FORM_DEFAULT
|
static java.lang.String |
FORM_ELSE
|
static java.lang.String |
FORM_ELSE_IF
|
static java.lang.String |
FORM_ELSE_IF_TEST
|
static java.lang.String |
FORM_EXPRESSION
|
static java.lang.String |
FORM_FINALLY
|
static java.lang.String |
FORM_FOR
|
static java.lang.String |
FORM_IF
|
static java.lang.String |
FORM_IF_TEST
|
static java.lang.String |
FORM_MODIFY
|
static java.lang.String |
FORM_RETRACT
|
static java.lang.String |
FORM_RETURN
|
static java.lang.String |
FORM_RL
|
static java.lang.String |
FORM_SYNCHRONIZED
|
static java.lang.String |
FORM_TEST
|
static java.lang.String |
FORM_THROW
|
static java.lang.String |
FORM_TRY
|
static java.lang.String |
FORM_WHILE
|
static java.lang.String |
FORM_WHILE_TEST
|
static java.lang.String |
KEYWORD_DO
|
static java.lang.String |
KEYWORD_THEN
|
Method Summary | |
---|---|
void |
desurround()
|
ActionTable |
getActionTable()
|
TableProperty<Action> |
getActionTableProperty()
Get ActionTable Property. |
java.util.List<DOID> |
getAEReferences()
Get the DOIDs referenced by all directly or indirectly contained actions and expressions |
java.lang.String |
getAlias()
Even though we extend UnnamedComponent, we need the variable name to translate expressions from persistent format (`ID`) to user format (name) |
java.lang.String |
getAlias(boolean translate)
Get alias of DictionaryComponent. |
java.util.List<DOID> |
getAllReferences()
Get the DOIDs referenced by this component or contained components |
Expression |
getExpression(int i)
Shorthand for getExpressionTable.getExpression(i) |
Expression |
getExpressionByParameterAlias(java.lang.String parameterAlias)
Get Expression from this action's expression table by parameter alias. |
Expression |
getExpressionByParameterName(java.lang.String parameterName)
Get Expression from this action's expression table by parameter name. |
ExpressionTable |
getExpressionTable()
|
TableProperty<Expression> |
getExpressionTableProperty()
Get ExpressionTable Property. |
DOID |
getFactTypeID()
|
java.lang.String |
getForm()
Get What kind of action. |
java.lang.String[] |
getFormOptions()
|
Action.FormProperty |
getFormProperty()
Get Form Property. |
int |
getFormSelected()
|
java.util.List<DOID> |
getReferences()
Get the DOIDs referenced by this component (but not the contained components) |
SimpleTestTable |
getSimpleTestTable()
|
TableProperty<SimpleTest> |
getSimpleTestTableProperty()
Get SimpleTestTable Property. |
static java.util.List<Choice> |
getSurroundingFormChoices(java.util.List<Action> actions)
|
static java.lang.String[] |
getSurroundingFormOptions(java.util.List<Action> actions)
|
static java.lang.String[] |
getSurroundingFormOptions(java.util.List<Action> actions,
boolean translate)
|
java.lang.String |
getTarget()
|
DOID |
getTargetID()
|
java.lang.String[] |
getTargetOptions()
|
Action.TargetProperty |
getTargetProperty()
Get Target Property. |
int |
getTargetSelected()
|
java.lang.String |
getVariable()
|
SettableProperty<java.lang.String> |
getVariableProperty()
Get Variable Property. |
boolean |
hasNestedActions()
can this action's actionTable contain actions? |
boolean |
hasTarget()
Does this form of action have a target? |
boolean |
isValueRequired(Expression e)
|
void |
setForm(java.lang.String form)
Set What kind of action. |
void |
setTarget(java.lang.String target)
|
void |
setVariable(java.lang.String v)
|
Action |
surround(java.lang.String form)
|
static Action |
surround(java.lang.String form,
java.util.List<Action> actions)
|
Methods inherited from class oracle.rules.sdk2.ruleset.UnnamedRuleComponent |
---|
init, isAliasDistinct, isNameDistinct |
Methods inherited from class oracle.rules.sdk2.ruleset.RuleComponent |
---|
get, getParent, getParentTable, parentAction, parentActionContext, parentFunction, parentPattern, parentRule, parentRuleCommon, parentRuleSheet, parentVariable, RHSRuleVariables |
Methods inherited from class oracle.rules.sdk2.dictionary.DictionaryObject |
---|
equals, exists, getCombinedDataModel, getContainedIDs, getContainedIDs, getDataModel, getDictionary, getID, getIndent, getLevel, getObjectType, getParentByClass, getParentComponent, getParentComponentTable, getParentObject, getRuleSet, getState, getWarnings, hashCode, isModified, validate |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface oracle.rules.sdk2.dictionary.UnnamedComponent |
---|
getName, getPropertyNames, setAlias, setName |
Methods inherited from interface java.util.Map |
---|
equals, hashCode |
Field Detail |
---|
public static final java.lang.String FORM_DEFAULT
public static final java.lang.String FORM_ASSERT
public static final java.lang.String FORM_ASSERT_TREE
public static final java.lang.String FORM_ASSERT_NEW
public static final java.lang.String FORM_ASSIGN
public static final java.lang.String FORM_CALL
public static final java.lang.String FORM_RETRACT
public static final java.lang.String FORM_RL
public static final java.lang.String FORM_ASSIGN_NEW
public static final java.lang.String FORM_EXPRESSION
public static final java.lang.String FORM_IF
public static final java.lang.String FORM_ELSE
public static final java.lang.String FORM_ELSE_IF
public static final java.lang.String FORM_THROW
public static final java.lang.String FORM_CATCH
public static final java.lang.String FORM_TRY
public static final java.lang.String FORM_FINALLY
public static final java.lang.String FORM_FOR
public static final java.lang.String FORM_MODIFY
public static final java.lang.String FORM_WHILE
public static final java.lang.String FORM_RETURN
public static final java.lang.String FORM_SYNCHRONIZED
public static final java.lang.String FORM_IF_TEST
public static final java.lang.String FORM_ELSE_IF_TEST
public static final java.lang.String FORM_WHILE_TEST
public static final java.lang.String FORM_BASIC
public static final java.lang.String FORM_TEST
public static final java.lang.String FORM_ADVANCED
public static final java.lang.String KEYWORD_THEN
public static final java.lang.String KEYWORD_DO
Method Detail |
---|
public void desurround()
public Action surround(java.lang.String form)
public static Action surround(java.lang.String form, java.util.List<Action> actions)
public static java.lang.String[] getSurroundingFormOptions(java.util.List<Action> actions)
public static java.lang.String[] getSurroundingFormOptions(java.util.List<Action> actions, boolean translate)
public static java.util.List<Choice> getSurroundingFormChoices(java.util.List<Action> actions)
public boolean isValueRequired(Expression e)
public boolean hasNestedActions()
public Expression getExpression(int i)
i
- ordinal of SimpleTest to retrieve from SimpleTestTable
java.lang.IndexOutOfBoundsException
public Expression getExpressionByParameterName(java.lang.String parameterName)
parameterName
- name of parameter
public Expression getExpressionByParameterAlias(java.lang.String parameterAlias)
parameterAlias
- alias of parameter
public Action.FormProperty getFormProperty()
public java.lang.String getForm()
see FORM_ above
public void setForm(java.lang.String form)
see FORM_ above
public java.lang.String[] getFormOptions()
public int getFormSelected()
public Action.TargetProperty getTargetProperty()
public java.lang.String getTarget()
public void setTarget(java.lang.String target)
public java.lang.String[] getTargetOptions()
public int getTargetSelected()
public TableProperty<Expression> getExpressionTableProperty()
public ExpressionTable getExpressionTable()
public TableProperty<Action> getActionTableProperty()
public ActionTable getActionTable()
public SettableProperty<java.lang.String> getVariableProperty()
public java.lang.String getVariable()
public void setVariable(java.lang.String v)
public TableProperty<SimpleTest> getSimpleTestTableProperty()
public SimpleTestTable getSimpleTestTable()
public java.lang.String getAlias()
getAlias
in interface UnnamedComponent
getAlias
in class DictionaryComponent
public java.lang.String getAlias(boolean translate)
DictionaryComponent
getAlias
in class DictionaryComponent
translate
- whether to get the translated alias
public DOID getFactTypeID()
public DOID getTargetID()
public boolean hasTarget()
public java.util.List<DOID> getReferences()
DictionaryComponent
getReferences
in class DictionaryComponent
public java.util.List<DOID> getAEReferences()
DictionaryComponent
getAEReferences
in class DictionaryComponent
public java.util.List<DOID> getAllReferences()
DictionaryComponent
getAllReferences
in class DictionaryComponent
|
Oracle Fusion Middleware Java API Reference for Oracle Business Rules 11g Release 1 (11.1.1.7) E10663-11 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |