Package jadex.rules.rulesystem
Class RuleSystemExecutor
- java.lang.Object
- 
- jadex.rules.rulesystem.RuleSystemExecutor
 
- 
- All Implemented Interfaces:
- ISteppable
 
 public class RuleSystemExecutor extends java.lang.Object implements ISteppable A rule system executor can execute rule systems on a separate thread.
- 
- 
Field SummaryFields Modifier and Type Field Description protected ICommand[]breakpointcommandsThe breakpoint commands.protected java.util.SetbreakpointsThe breakpoints (i.e.protected booleandostepFlag indicating that a single step should be performed.protected ExecutorexecutorThe executor.protected RuleSystemrulesystemThe agenda.protected booleanstepmodeThe stepmode flag.
 - 
Constructor SummaryConstructors Constructor Description RuleSystemExecutor(RuleSystem rulesystem, boolean stepmode)Executor for rule systems.RuleSystemExecutor(RuleSystem rulesystem, boolean stepmode, IThreadPool threadpool)Executor for rule systems.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddBreakpoint(java.lang.Object rule)Add a breakpoint to the interpreter.voidaddBreakpointCommand(ICommand command)Add a command to be executed, when a breakpoint is reached.voiddoStep()Execute a step.RuleSystemgetRulesystem()Get the rule system.booleanisBreakpoint(java.lang.Object rule)Check if a rule is a breakpoint for the interpreter.booleanisStepmode()Test if in stepmode.voidremoveBreakpoint(java.lang.Object rule)Remove a breakpoint from the interpreter.voidsetStepmode(boolean stepmode)Set the stepmode.
 
- 
- 
- 
Field Detail- 
stepmodeprotected boolean stepmode The stepmode flag.
 - 
dostepprotected boolean dostep Flag indicating that a single step should be performed.
 - 
rulesystemprotected RuleSystem rulesystem The agenda.
 - 
executorprotected Executor executor The executor.
 - 
breakpointsprotected java.util.Set breakpoints The breakpoints (i.e. rules that set the interpreter to step mode, when activated).
 - 
breakpointcommandsprotected ICommand[] breakpointcommands The breakpoint commands.
 
- 
 - 
Constructor Detail- 
RuleSystemExecutorpublic RuleSystemExecutor(RuleSystem rulesystem, boolean stepmode) Executor for rule systems.
 - 
RuleSystemExecutorpublic RuleSystemExecutor(RuleSystem rulesystem, boolean stepmode, IThreadPool threadpool) Executor for rule systems.
 
- 
 - 
Method Detail- 
doSteppublic void doStep() Execute a step.- Specified by:
- doStepin interface- ISteppable
 
 - 
setStepmodepublic void setStepmode(boolean stepmode) Set the stepmode.- Specified by:
- setStepmodein interface- ISteppable
- Parameters:
- stepmode- True for stepmode.
 
 - 
isStepmodepublic boolean isStepmode() Test if in stepmode.- Specified by:
- isStepmodein interface- ISteppable
- Returns:
- True, if in stepmode.
 
 - 
addBreakpointpublic void addBreakpoint(java.lang.Object rule) Add a breakpoint to the interpreter.- Specified by:
- addBreakpointin interface- ISteppable
 
 - 
removeBreakpointpublic void removeBreakpoint(java.lang.Object rule) Remove a breakpoint from the interpreter.- Specified by:
- removeBreakpointin interface- ISteppable
 
 - 
isBreakpointpublic boolean isBreakpoint(java.lang.Object rule) Check if a rule is a breakpoint for the interpreter.- Specified by:
- isBreakpointin interface- ISteppable
 
 - 
addBreakpointCommandpublic void addBreakpointCommand(ICommand command) Add a command to be executed, when a breakpoint is reached.- Specified by:
- addBreakpointCommandin interface- ISteppable
 
 - 
getRulesystempublic RuleSystem getRulesystem() Get the rule system.- Returns:
- The rule system.
 
 
- 
 
-