Changeset 1294 for trunk/autoquest-core-tasktrees/src/main/java/de/ugoe/cs/autoquest/tasktrees/temporalrelation/TemporalRelationshipRuleManager.java
- Timestamp:
- 08/14/13 17:04:42 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/autoquest-core-tasktrees/src/main/java/de/ugoe/cs/autoquest/tasktrees/temporalrelation/TemporalRelationshipRuleManager.java
r1189 r1294 26 26 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskFactory; 27 27 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskInstance; 28 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskInstanceList;29 28 import de.ugoe.cs.autoquest.tasktrees.treeifc.IUserSession; 30 29 import de.ugoe.cs.util.console.Console; … … 38 37 * between tasks which are not only a major sequence. I.e. through the application of the 39 38 * rules iterations and selections of tasks are detected. Which kind of temporal relations 40 * between tasks are detected depends on the {@link ITaskInstance ListScopeRule}s known to39 * between tasks are detected depends on the {@link ITaskInstanceScopeRule}s known to 41 40 * this class. 42 41 * </p> 43 * <p>The class holds references to the appropriate {@link ITaskInstance ListScopeRule}s and calls44 * their {@link ITaskInstance ListScopeRule#apply(ITask, ITaskBuilder, ITaskFactory, boolean)}42 * <p>The class holds references to the appropriate {@link ITaskInstanceScopeRule}s and calls 43 * their {@link ITaskInstanceScopeRule#apply(ITask, ITaskBuilder, ITaskFactory, boolean)} 45 44 * method for each task in the task tree it is needed for. The general behavior of this class is 46 45 * the following: … … 56 55 * <li> 57 56 * the class iterates its internal list of rules and calls their 58 * {@link ITaskInstance ListScopeRule#apply(ITask, ITaskBuilder, ITaskFactory, boolean)}57 * {@link ITaskInstanceScopeRule#apply(ITask, ITaskBuilder, ITaskFactory, boolean)} 59 58 * method. 60 59 * </li> … … 115 114 * </p> 116 115 */ 117 private ITaskInstance ListScopeRule[] taskScopeRules;116 private ITaskInstanceScopeRule[] taskScopeRules; 118 117 119 118 /** … … 166 165 //treeScopeRules.add(new DefaultGuiElementSequenceDetectionRule(frameFilter)); 167 166 168 taskScopeRules = new ITaskInstance ListScopeRule[] {167 taskScopeRules = new ITaskInstanceScopeRule[] { 169 168 //new SequenceOnGuiElementDetectionRule(taskFactory, taskTreeBuilder), 170 169 //new EventSequenceOnSameTargetDetectionRule(taskFactory, taskTreeBuilder), … … 262 261 * on the recursion depth of calling this method. 263 262 */ 264 private int applyRules(ITaskInstance ListScopeRule[] rules,265 ITaskInstance List taskInstances,263 private int applyRules(ITaskInstanceScopeRule[] rules, 264 ITaskInstance taskInstance, 266 265 String logIndent) 267 266 { 268 Console.traceln(Level.FINER, logIndent + "applying rules for " + taskInstances.size() + 269 " task instances"); 267 Console.traceln(Level.FINER, logIndent + "applying rules on " + taskInstance); 270 268 271 269 int noOfRuleApplications = 0; 272 270 273 for (ITaskInstance ListScopeRule rule : rules) {271 for (ITaskInstanceScopeRule rule : rules) { 274 272 RuleApplicationResult result; 275 273 do { 276 274 Console.traceln 277 (Level.FINER, logIndent + "trying rule " + rule + " on " + taskInstance s);278 result = rule.apply(taskInstance s);275 (Level.FINER, logIndent + "trying rule " + rule + " on " + taskInstance); 276 result = rule.apply(taskInstance); 279 277 280 278 if ((result != null) && … … 282 280 { 283 281 Console.traceln 284 (Level.FINE, logIndent + "applied rule " + rule + " on " + taskInstance s);282 (Level.FINE, logIndent + "applied rule " + rule + " on " + taskInstance); 285 283 noOfRuleApplications++; 286 284
Note: See TracChangeset
for help on using the changeset viewer.