Package adams.flow.execution.debug
Class AbstractBreakpoint
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.logging.CustomLoggingLevelObject
-
- adams.core.option.AbstractOptionHandler
-
- adams.flow.execution.debug.AbstractBreakpoint
-
- All Implemented Interfaces:
Destroyable,GlobalInfoSupporter,LoggingLevelHandler,LoggingSupporter,OptionHandler,SizeOfHandler,Serializable
- Direct Known Subclasses:
AnyActorBreakpoint,ClassBreakpoint,PathBreakpoint
public abstract class AbstractBreakpoint extends AbstractOptionHandler
Ancestor for breakpoints for execution listeners.- Author:
- fracpete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected booleanm_BringToFrontwhether to bring the window to the front.protected booleanm_Disabledwhether the breakpoint is disabled.protected booleanm_OneOffwhether this is a one-off.protected booleanm_OnPostExecutebreak on postExecute.protected booleanm_OnPostInputbreak on postInput.protected booleanm_OnPostOutputbreak on postOutput.protected booleanm_OnPreExecutebreak on preExecute.protected booleanm_OnPreInputbreak on preInput.protected booleanm_OnPreOutputbreak on preOutput.protected intm_TriggerCountthe trigger counter.protected View[]m_Viewsthe views to display automatically.protected BaseString[]m_Watchesthe watch expressions.protected ExpressionWatchPanel.ExpressionType[]m_WatchTypesthe watch expression types.-
Fields inherited from class adams.core.option.AbstractOptionHandler
m_OptionManager
-
Fields inherited from class adams.core.logging.LoggingObject
m_Logger, m_LoggingIsEnabled, m_LoggingLevel
-
-
Constructor Summary
Constructors Constructor Description AbstractBreakpoint()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description StringbringToFrontTipText()Returns the tip text for this property.voiddefineOptions()Adds options to the internal list of options.StringdisabledTipText()Returns the tip text for this property.protected abstract booleanevaluatePostExecute(Actor actor)Evaluates the breakpoint at post-execute.protected abstract booleanevaluatePostInput(Actor actor)Evaluates the breakpoint at post-input.protected abstract booleanevaluatePostOutput(Actor actor, Token token)Evaluates the breakpoint at post-output.protected abstract booleanevaluatePreExecute(Actor actor)Evaluates the breakpoint at pre-execute.protected abstract booleanevaluatePreInput(Actor actor, Token token)Evaluates the breakpoint at pre-input.protected abstract booleanevaluatePreOutput(Actor actor)Evaluates the breakpoint at pre-output.booleangetBringToFront()Returns whether to bring the flow editor window to the front once the breakpoint is reached.booleangetDisabled()Returns whether this breakpoint is disabled.booleangetOneOff()Returns whether the breakpoint is just a one-off one (gets removed once reached).booleangetOnPostExecute()Returns whether the breakpoint gets evaluated on post-execute.booleangetOnPostInput()Returns whether the breakpoint gets evaluated on post-input (of token).booleangetOnPostOutput()Returns whether the breakpoint gets evaluated on post-output (of token).booleangetOnPreExecute()Returns whether the breakpoint gets evaluated on pre-execute.booleangetOnPreInput()Returns whether the breakpoint gets evaluated on pre-input (of token).booleangetOnPreOutput()Returns whether the breakpoint gets evaluated on pre-output (of token).intgetTriggerCount()Returns the number of times this breakpoint has been triggered.View[]getViews()Returns the views to display automatically.BaseString[]getWatches()Returns the watch expressions for the watch dialog.ExpressionWatchPanel.ExpressionType[]getWatchTypes()Returns the types of the watch expressions.StringoneOffTipText()Returns the tip text for this property.StringonPostExecuteTipText()Returns the tip text for this property.StringonPostInputTipText()Returns the tip text for this property.StringonPostOutputTipText()Returns the tip text for this property.StringonPreExecuteTipText()Returns the tip text for this property.StringonPreInputTipText()Returns the tip text for this property.StringonPreOutputTipText()Returns the tip text for this property.protected voidreset()Resets the scheme.voidsetBringToFront(boolean value)Sets whether to bring the flow editor window to the front once the breakpoint is reached.voidsetDisabled(boolean value)Sets whether to disable this breakpoint.voidsetOneOff(boolean value)Sets whether the breakpoint is just a one-off one (gets removed once reached).voidsetOnPostExecute(boolean value)Sets whether to evaluate the breakpoing on post-execute.voidsetOnPostInput(boolean value)Sets whether to evaluate the breakpoing on post-input (of token).voidsetOnPostOutput(boolean value)Sets whether to evaluate the breakpoing on post-output (of token).voidsetOnPreExecute(boolean value)Sets whether to evaluate the breakpoing on pre-execute.voidsetOnPreInput(boolean value)Sets whether to evaluate the breakpoing on pre-input (of token).voidsetOnPreOutput(boolean value)Sets whether to evaluate the breakpoing on pre-output (of token).voidsetViews(View[] value)Sets the views to display automatically.voidsetWatches(BaseString[] value)Sets the watch expressions for the watch dialog.voidsetWatchTypes(ExpressionWatchPanel.ExpressionType[] value)Sets the types of the watch expressions.voidtriggered()To be called when triggered (increments counter).booleantriggersPostExecute(Actor actor)Checks whether the breakpoint gets triggered in post-execute.booleantriggersPostInput(Actor actor)Checks whether the breakpoint gets triggered in post-input.booleantriggersPostOutput(Actor actor, Token token)Checks whether the breakpoint gets triggered in post-output.booleantriggersPreExecute(Actor actor)Checks whether the breakpoint gets triggered in pre-execute.booleantriggersPreInput(Actor actor, Token token)Checks whether the breakpoint gets triggered in pre-input.booleantriggersPreOutput(Actor actor)Checks whether the breakpoint gets triggered in pre-output.StringviewsTipText()Returns the tip text for this property.StringwatchesTipText()Returns the tip text for this property.StringwatchTypesTipText()Returns the tip text for this property.-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, destroy, finishInit, getDefaultLoggingLevel, getOptionManager, globalInfo, initialize, loggingLevelTipText, newOptionManager, setLoggingLevel, toCommandLine, toString
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface adams.core.logging.LoggingLevelHandler
getLoggingLevel
-
-
-
-
Field Detail
-
m_Disabled
protected boolean m_Disabled
whether the breakpoint is disabled.
-
m_OnPreInput
protected boolean m_OnPreInput
break on preInput.
-
m_OnPostInput
protected boolean m_OnPostInput
break on postInput.
-
m_OnPreExecute
protected boolean m_OnPreExecute
break on preExecute.
-
m_OnPostExecute
protected boolean m_OnPostExecute
break on postExecute.
-
m_OnPreOutput
protected boolean m_OnPreOutput
break on preOutput.
-
m_OnPostOutput
protected boolean m_OnPostOutput
break on postOutput.
-
m_Views
protected View[] m_Views
the views to display automatically.
-
m_Watches
protected BaseString[] m_Watches
the watch expressions.
-
m_WatchTypes
protected ExpressionWatchPanel.ExpressionType[] m_WatchTypes
the watch expression types.
-
m_OneOff
protected boolean m_OneOff
whether this is a one-off.
-
m_BringToFront
protected boolean m_BringToFront
whether to bring the window to the front.
-
m_TriggerCount
protected int m_TriggerCount
the trigger counter.
-
-
Method Detail
-
defineOptions
public void defineOptions()
Adds options to the internal list of options.- Specified by:
defineOptionsin interfaceOptionHandler- Overrides:
defineOptionsin classAbstractOptionHandler
-
reset
protected void reset()
Resets the scheme.- Overrides:
resetin classAbstractOptionHandler
-
setDisabled
public void setDisabled(boolean value)
Sets whether to disable this breakpoint.- Parameters:
value- true if to disable
-
getDisabled
public boolean getDisabled()
Returns whether this breakpoint is disabled.- Returns:
- true if disabled
-
disabledTipText
public String disabledTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setOnPreInput
public void setOnPreInput(boolean value)
Sets whether to evaluate the breakpoing on pre-input (of token).- Parameters:
value- true if evaluated
-
getOnPreInput
public boolean getOnPreInput()
Returns whether the breakpoint gets evaluated on pre-input (of token).- Returns:
- true if evaluated
-
onPreInputTipText
public String onPreInputTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setOnPostInput
public void setOnPostInput(boolean value)
Sets whether to evaluate the breakpoing on post-input (of token).- Parameters:
value- true if evaluated
-
getOnPostInput
public boolean getOnPostInput()
Returns whether the breakpoint gets evaluated on post-input (of token).- Returns:
- true if evaluated
-
onPostInputTipText
public String onPostInputTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setOnPreExecute
public void setOnPreExecute(boolean value)
Sets whether to evaluate the breakpoing on pre-execute.- Parameters:
value- true if evaluated
-
getOnPreExecute
public boolean getOnPreExecute()
Returns whether the breakpoint gets evaluated on pre-execute.- Returns:
- true if evaluated
-
onPreExecuteTipText
public String onPreExecuteTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setOnPostExecute
public void setOnPostExecute(boolean value)
Sets whether to evaluate the breakpoing on post-execute.- Parameters:
value- true if evaluated
-
getOnPostExecute
public boolean getOnPostExecute()
Returns whether the breakpoint gets evaluated on post-execute.- Returns:
- true if evaluated
-
onPostExecuteTipText
public String onPostExecuteTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setOnPreOutput
public void setOnPreOutput(boolean value)
Sets whether to evaluate the breakpoing on pre-output (of token).- Parameters:
value- true if evaluated
-
getOnPreOutput
public boolean getOnPreOutput()
Returns whether the breakpoint gets evaluated on pre-output (of token).- Returns:
- true if evaluated
-
onPreOutputTipText
public String onPreOutputTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setOnPostOutput
public void setOnPostOutput(boolean value)
Sets whether to evaluate the breakpoing on post-output (of token).- Parameters:
value- true if evaluated
-
getOnPostOutput
public boolean getOnPostOutput()
Returns whether the breakpoint gets evaluated on post-output (of token).- Returns:
- true if evaluated
-
onPostOutputTipText
public String onPostOutputTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setWatches
public void setWatches(BaseString[] value)
Sets the watch expressions for the watch dialog.- Parameters:
value- the expressions
-
getWatches
public BaseString[] getWatches()
Returns the watch expressions for the watch dialog.- Returns:
- the expressions
-
watchesTipText
public String watchesTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setWatchTypes
public void setWatchTypes(ExpressionWatchPanel.ExpressionType[] value)
Sets the types of the watch expressions.- Parameters:
value- the types
-
getWatchTypes
public ExpressionWatchPanel.ExpressionType[] getWatchTypes()
Returns the types of the watch expressions.- Returns:
- the types
-
watchTypesTipText
public String watchTypesTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setViews
public void setViews(View[] value)
Sets the views to display automatically.- Parameters:
value- the views
-
getViews
public View[] getViews()
Returns the views to display automatically.- Returns:
- the views
-
viewsTipText
public String viewsTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setOneOff
public void setOneOff(boolean value)
Sets whether the breakpoint is just a one-off one (gets removed once reached).- Parameters:
value- true if a one-off breakpoint
-
getOneOff
public boolean getOneOff()
Returns whether the breakpoint is just a one-off one (gets removed once reached).- Returns:
- true if a one-off breakpoint
-
oneOffTipText
public String oneOffTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setBringToFront
public void setBringToFront(boolean value)
Sets whether to bring the flow editor window to the front once the breakpoint is reached.- Parameters:
value- true if to bring to front
-
getBringToFront
public boolean getBringToFront()
Returns whether to bring the flow editor window to the front once the breakpoint is reached.- Returns:
- true if to bring to front
-
bringToFrontTipText
public String bringToFrontTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
evaluatePreInput
protected abstract boolean evaluatePreInput(Actor actor, Token token)
Evaluates the breakpoint at pre-input.- Parameters:
actor- the current actortoken- the token available for input- Returns:
- true if breakpoint triggers
-
evaluatePostInput
protected abstract boolean evaluatePostInput(Actor actor)
Evaluates the breakpoint at post-input.- Parameters:
actor- the current actor- Returns:
- true if breakpoint triggers
-
evaluatePreExecute
protected abstract boolean evaluatePreExecute(Actor actor)
Evaluates the breakpoint at pre-execute.- Parameters:
actor- the current actor- Returns:
- true if breakpoint triggers
-
evaluatePostExecute
protected abstract boolean evaluatePostExecute(Actor actor)
Evaluates the breakpoint at post-execute.- Parameters:
actor- the current actor- Returns:
- true if breakpoint triggers
-
evaluatePreOutput
protected abstract boolean evaluatePreOutput(Actor actor)
Evaluates the breakpoint at pre-output.- Parameters:
actor- the current actor- Returns:
- true if breakpoint triggers
-
evaluatePostOutput
protected abstract boolean evaluatePostOutput(Actor actor, Token token)
Evaluates the breakpoint at post-output.- Parameters:
actor- the current actortoken- the token available for output- Returns:
- true if breakpoint triggers
-
triggersPreInput
public boolean triggersPreInput(Actor actor, Token token)
Checks whether the breakpoint gets triggered in pre-input.- Parameters:
actor- the current actortoken- the token available for input- Returns:
- true if triggered
-
triggersPostInput
public boolean triggersPostInput(Actor actor)
Checks whether the breakpoint gets triggered in post-input.- Parameters:
actor- the current actor- Returns:
- true if triggered
-
triggersPreExecute
public boolean triggersPreExecute(Actor actor)
Checks whether the breakpoint gets triggered in pre-execute.- Parameters:
actor- the current actor- Returns:
- true if triggered
-
triggersPostExecute
public boolean triggersPostExecute(Actor actor)
Checks whether the breakpoint gets triggered in post-execute.- Parameters:
actor- the current actor- Returns:
- true if triggered
-
triggersPreOutput
public boolean triggersPreOutput(Actor actor)
Checks whether the breakpoint gets triggered in pre-output.- Parameters:
actor- the current actor- Returns:
- true if triggered
-
triggersPostOutput
public boolean triggersPostOutput(Actor actor, Token token)
Checks whether the breakpoint gets triggered in post-output.- Parameters:
actor- the current actortoken- the token available for output- Returns:
- true if triggered
-
triggered
public void triggered()
To be called when triggered (increments counter).
-
getTriggerCount
public int getTriggerCount()
Returns the number of times this breakpoint has been triggered.- Returns:
- the count
-
-