Package adams.flow.condition.bool
Interface BooleanCondition
-
- All Superinterfaces:
QuickInfoSupporter
,ShallowCopySupporter<BooleanCondition>
,Stoppable
- All Known Subinterfaces:
IndexedBooleanCondition
- All Known Implementing Classes:
AbstractAttributeCapabilities
,AbstractBooleanCondition
,AbstractBooleanDatabaseCondition
,AbstractExpression
,AbstractMultiCondition
,AbstractScript
,AbstractScriptedCondition
,AdamsInstanceCapabilities
,And
,BinaryFile
,BooleanReportValue
,BytesComplete
,Counting
,DirectoriesMatch
,DirectoryExists
,Expression
,False
,FileComplete
,FileExists
,FileInUse
,FilesMatch
,Groovy
,HasClass
,HasColumn
,HasElements
,HasExifTag
,HashSet
,HasInterface
,HasLength
,HasMapValue
,HasProperty
,HasQueue
,HasRows
,HasSize
,HasStorageValue
,HasVariable
,HasVariableValue
,InList
,IsAndroid
,IsArm64
,IsArray
,IsBoolean
,IsByte
,IsBzip2Compressed
,IsDouble
,IsFloat
,IsGzipCompressed
,IsInteger
,IsLinux
,IsLong
,IsMac
,IsMat5Array
,IsMat5Matrix
,IsMat5Struct
,IsNull
,IsNumeric
,IsRarCompressed
,IsShort
,IsSubClass
,IsWindows
,IsXzCompressed
,IsZipCompressed
,IsZstdCompressed
,Not
,NotesErrors
,Or
,PromptUser
,RegExp
,ReportValueExists
,Scripted
,StorageFlagSet
,TableExists
,True
,VariableFlagSet
,WekaCapabilities
,WekaClassification
public interface BooleanCondition extends ShallowCopySupporter<BooleanCondition>, QuickInfoSupporter, Stoppable
Ancestor for conditions that get evaluated in, e.g., the IfThenElse control actor, deciding which branch to take.- Version:
- $Revision$
- Author:
- fracpete (fracpete at waikato dot ac dot nz)
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Class[]
accepts()
Returns the class that the consumer accepts.boolean
evaluate(Actor owner, Token token)
Evaluates whether to executed the "then" or "else" branch.String
getQuickInfo()
Returns the quick info string to be displayed in the flow editor.String
setUp(Actor owner)
Configures the condition.BooleanCondition
shallowCopy()
Returns a shallow copy of itself, i.e., based on the commandline options.BooleanCondition
shallowCopy(boolean expand)
Returns a shallow copy of itself, i.e., based on the commandline options.void
stopExecution()
Stops the execution.
-
-
-
Method Detail
-
getQuickInfo
String getQuickInfo()
Returns the quick info string to be displayed in the flow editor.- Specified by:
getQuickInfo
in interfaceQuickInfoSupporter
- Returns:
- the info or null if no info to be displayed
-
accepts
Class[] accepts()
Returns the class that the consumer accepts.- Returns:
- the accepted class
-
setUp
String setUp(Actor owner)
Configures the condition.- Parameters:
owner
- the actor this condition belongs to- Returns:
- null if everything is fine, otherwise error message
-
evaluate
boolean evaluate(Actor owner, Token token)
Evaluates whether to executed the "then" or "else" branch.- Parameters:
owner
- the owning actortoken
- the current token passing through the actor- Returns:
- true if the condition applies
-
shallowCopy
BooleanCondition shallowCopy()
Returns a shallow copy of itself, i.e., based on the commandline options.- Specified by:
shallowCopy
in interfaceShallowCopySupporter<BooleanCondition>
- Returns:
- the shallow copy
-
shallowCopy
BooleanCondition shallowCopy(boolean expand)
Returns a shallow copy of itself, i.e., based on the commandline options.- Specified by:
shallowCopy
in interfaceShallowCopySupporter<BooleanCondition>
- Parameters:
expand
- whether to expand variables to their current values- Returns:
- the shallow copy
-
stopExecution
void stopExecution()
Stops the execution.- Specified by:
stopExecution
in interfaceStoppable
-
-