Package oracle.rules.sdk2.decisiontable
Class DTRuleTable
java.lang.Object
oracle.rules.sdk2.dictionary.DictionaryObject
oracle.rules.sdk2.dictionary.DictionaryComponentTable<T>
oracle.rules.sdk2.ruleset.RuleComponentTable<T>
oracle.rules.sdk2.decisiontable.DTComponentTable<DTRule>
oracle.rules.sdk2.decisiontable.DTRuleTable
- All Implemented Interfaces:
Serializable,Cloneable,Iterable<DTRule>,Collection<DTRule>,List<DTRule>
A list of DTRules in the decision table.
RuleSheet contains a DTRuleTable, which holds multiple DTRules in this RuleSheet.
- See Also:
-
Field Summary
Fields inherited from class oracle.rules.sdk2.dictionary.DictionaryComponentTable
SORT, SORT_ASCEND, SORT_DECEND -
Method Summary
Modifier and TypeMethodDescriptionadd()Create a new DTRule with all DimensionNodes set to "?".add(int index) Add DTRule to table at given index.voidUsed to force the rule into this decision table at given indexbooleanUsed internally by subclasses.booleancanAdd()can a rule be added to the decision table?voidclear()remove all elements in the tableDimensionNode[][]Get the DimensionNodes in the sheet as an D x R matrix (D rows x R columns, D is #dimensions and R is #rules)voidmove(int fromIndex, int toIndex, boolean replace) Move the DictionaryComponent with the given id from its current location to the location of the second id.remove(int index) Remove the rule by position.booleanremove the DictionaryComponent from this tableMethods inherited from class oracle.rules.sdk2.decisiontable.DTComponentTable
addAll, addAll, parentRuleSheet, removeAll, retainAll, setMethods inherited from class oracle.rules.sdk2.ruleset.RuleComponentTable
getParentMethods inherited from class oracle.rules.sdk2.dictionary.DictionaryComponentTable
_clear, _remove, _remove, contains, containsAll, copyTo, copyTo, cut, filter, get, getAEReferences, getAllReferences, getByAlias, getByAlias, getByID, getByName, getExprParserReferences, getLast, getMarked, getProtoType, indexOf, initProtoType, isEmpty, isLocked, iterator, lastIndexOf, listIterator, listIterator, mark, move, ordering, paste, removeByAlias, removeByID, removeByName, removeMarked, removeProtoType, reorder, size, sort, sort, sort, subList, toArray, toArray, unMark, validate, validateMethods inherited from class oracle.rules.sdk2.dictionary.DictionaryObject
_clearID, equals, exists, getAEReferenceCount, getCombinedDataModel, getContainedIDs, getContainedIDs, getDataModel, getDictionary, getID, getIndent, getObjectPath, getObjectType, getParentByClass, getParentComponent, getParentComponentTable, getParentObject, getReferences, getRuleSet, getState, getWarnings, hashCode, isModified, setID, validateMethods inherited from class java.lang.Object
getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArrayMethods inherited from interface java.util.List
equals, hashCode, replaceAll, sort, spliterator
-
Method Details
-
add
Create a new DTRule with all DimensionNodes set to "?". Add it toward the end of the DTRuleTable reusing "?" DimensionNodes. If a DTRule already exists with all DimensionNodes "?", just return that rule.- Overrides:
addin classDictionaryComponentTable<DTRule>- Returns:
- DTRule with all DimensionNodes set to "?".
-
add
-
canAdd
public boolean canAdd()can a rule be added to the decision table? at most 1 rule can have Don't Cares in all dimensions. If no such rule exists, then a new rule can be added and this method returns true.- Returns:
- boolean
-
add
Add DTRule to table at given index.- Specified by:
addin classDictionaryComponentTable<DTRule>- Returns:
- new table element
-
clear
public void clear()Description copied from class:DictionaryComponentTableremove all elements in the table- Specified by:
clearin interfaceCollection<DTRule>- Specified by:
clearin interfaceList<DTRule>- Overrides:
clearin classDictionaryComponentTable<DTRule>
-
remove
Remove the rule by position. Removes corresponding DTActionNodes and DimensionNodes. Removing all rules also removes Dimensions and DTActionNodes -
remove
Description copied from class:DictionaryComponentTableremove the DictionaryComponent from this table- Specified by:
removein interfaceCollection<DTRule>- Specified by:
removein interfaceList<DTRule>- Overrides:
removein classDictionaryComponentTable<DTRule>
-
add
Used to force the rule into this decision table at given index -
move
public void move(int fromIndex, int toIndex, boolean replace) Description copied from class:DictionaryComponentTableMove the DictionaryComponent with the given id from its current location to the location of the second id. Shift the row currently at that location up, or replace it.- Overrides:
movein classDictionaryComponentTable<DTRule>- Parameters:
fromIndex- the index of the row to movetoIndex- move row to this locationreplace- if true, replace existing row at toIndex, if false move existing row to next higher index
-
getNodeMatrix
Get the DimensionNodes in the sheet as an D x R matrix (D rows x R columns, D is #dimensions and R is #rules)- Returns:
- matrix
-
add
Description copied from class:DictionaryComponentTableUsed internally by subclasses.- Specified by:
addin interfaceCollection<DTRule>- Specified by:
addin interfaceList<DTRule>- Overrides:
addin classDictionaryComponentTable<DTRule>- Parameters:
o- component to be added, must be of correct type for table.
-