AbstractAttributeCapabilities |
Ancestor for capabilities-based conditions.
|
AbstractBooleanCondition |
Ancestor for conditions that get evaluated in, e.g., the IfThenElse control
actor, deciding which branch to take.
|
AbstractBooleanDatabaseCondition |
Ancestor for conditions that operate on a database.
|
AbstractExpression |
Ancestor for conditions that use a boolean expression.
|
AbstractMultiCondition |
Ancestor for conditions that use multiple sub-conditions.
|
AbstractScript |
Ancestor for boolean script conditions.
|
AbstractScriptedCondition |
Abstract ancestor for actors that execute scripts.
|
AdamsInstanceCapabilities |
Filters adams.data.instance.Instance based on defined capabilities.
|
And |
Performs a logical AND over all its sub-conditions, i.e., it only evaluates to 'true' if all of the sub-conditions evaluate to 'true' as well.
|
BinaryFile |
Evaluates to 'true' if the file exists and is a binary file.
A heuristic is used to determine whether a file is binary, based on the first 1024 bytes.
|
BooleanReportValue |
Returns 'true' if the boolean field in the report is present and is 'true'.
|
BytesComplete |
Evaluates to 'true' if the bytes from the token are considered a 'complete' file.
|
Counting |
Counts the tokens passing through and returns 'true' if min/max/interval are met.
|
DirectoriesMatch |
Evaluates to 'true' if at least one sub-directory matches the regular expression in the specified directory.
|
DirectoryExists |
Evaluates to 'true' if the directory exists.
|
Expression |
Evaluates to 'true' if the expression evaluates to 'true'.
In case of java.lang.Number tokens that arrive at the input, these can be accessed in the expression via 'X'; string tokens can be accessed via expression '"X"' (surrounding double quotes are required).
If the incoming token is either a Report or a ReportHandler, the contents of the report get added as values as well (boolean, numeric or string) and you can access them via their name instead of 'X'.
The following grammar is used for evaluating the boolean expressions:
expr_list ::= '=' expr_list expr_part | expr_part ;
expr_part ::= expr ;
expr ::= ( expr )
# data types
| number
| string
| boolean
| date
# constants
| true
| false
| pi
| e
| now()
| today()
# negating numeric value
| -expr
# comparisons
| expr < expr
| expr <= expr
| expr > expr
| expr >= expr
| expr = expr
| expr != expr (or: expr <> expr)
# boolean operations
| ! expr (or: not expr)
| expr & expr (or: expr and expr)
| expr | expr (or: expr or expr)
| if[else] ( expr , expr (if true) , expr (if false) )
| ifmissing ( variable , expr (default value if variable is missing) )
| isNaN ( expr )
# arithmetics
| expr + expr
| expr - expr
| expr * expr
| expr / expr
| expr ^ expr (power of)
| expr % expr (modulo)
;
# numeric functions
| abs ( expr )
| sqrt ( expr )
| cbrt ( expr )
| log ( expr )
| log10 ( expr )
| exp ( expr )
| sin ( expr )
| sinh ( expr )
| cos ( expr )
| cosh ( expr )
| tan ( expr )
| tanh ( expr )
| atan ( expr )
| atan2 ( exprY , exprX )
| hypot ( exprX , exprY )
| signum ( expr )
| rint ( expr )
| floor ( expr )
| pow[er] ( expr , expr )
| ceil ( expr )
| min ( expr1 , expr2 )
| max ( expr1 , expr2 )
| year ( expr )
| month ( expr )
| day ( expr )
| hour ( expr )
| minute ( expr )
| second ( expr )
| weekday ( expr )
| weeknum ( expr )
# string functions
| substr ( expr , start [, end] )
| left ( expr , len )
| mid ( expr , start , len )
| right ( expr , len )
| rept ( expr , count )
| concatenate ( expr1 , expr2 [, expr3-5] )
| lower[case] ( expr )
| upper[case] ( expr )
| trim ( expr )
| matches ( expr , regexp )
| trim ( expr )
| len[gth] ( str )
| find ( search , expr [, pos] )
| replace ( str , pos , len , newstr )
| substitute ( str , find , replace [, occurrences] )
# array functions
| len[gth] ( array )
| get ( array , index )
;
Notes:
- Variables are either all upper case letters (e.g., "ABC") or any character apart from "]" enclosed by "[" and "]" (e.g., "[Hello World]").
- 'start' and 'end' for function 'substr' are indices that start at 1.
- 'index' for function 'get' starts at 1.
- Index 'end' for function 'substr' is excluded (like Java's 'String.substring(int,int)' method)
- Line comments start with '#'
- Semi-colons (';') or commas (',') can be used as separator in the formulas,
e.g., 'pow(2,2)' is equivalent to 'pow(2;2)'
- dates have to be of format 'yyyy-MM-dd' or 'yyyy-MM-dd HH:mm:ss'
- times have to be of format 'HH:mm:ss' or 'yyyy-MM-dd HH:mm:ss'
- the characters in square brackets in function names are optional:
e.g.
|
False |
Always evaluates to 'false'.
|
FileComplete |
Evaluates to 'true' if the file (from option or token) is considered complete.
|
FileExists |
Evaluates to 'true' if the file exists.
If a filename generator other than adams.core.io.NullFilenameGenerator is specified, then this takes precedence over the supplied filename (uses the token passing through).
|
FileInUse |
Evaluates to 'true' if the file is currently being used by another process.
If a filename generator other than adams.core.io.NullFilenameGenerator is specified, then this takes precedence over the supplied filename (uses the token passing through).
|
FilesMatch |
Evaluates to 'true' if at least one file matches the regular expression in the specified directory.
|
Groovy |
A boolean condition that uses the condition defined in a Groovy script.
|
HasClass |
Evaluates to 'true' if the specified class is available on the classpath.
|
HasColumn |
Checks whether the spreadsheet passing through has a certain column.
|
HasElements |
Checks whether the array passing through has a at least the specified number of elements.
|
HasExifTag |
Checks whether the specified EXIF tag is present.
|
HashSet |
Evaluates to true if the payload of the current token or the specified string (if non-empty) is present in the specified hashset.
The value gets transformed using the specified conversion.
See also:
adams.flow.standalone.HashSetInit
adams.flow.transformer.HashSetInit
|
HasInterface |
Evaluates to 'true' if the objects implement the specified interface.
|
HasLength |
Checks whether the array passing through has the required number of elements.
|
HasMapValue |
Evaluates to true if the specified java.util.Map object is available in storage and a value is associated with the supplied key.
|
HasProperty |
Evaluates to 'true' if the objects have the specified property path.
|
HasQueue |
Evaluates to true if the specified queue is available in storage.
|
HasRows |
Checks whether the spreadsheet passing through has the required number of rows.
|
HasSize |
Checks whether the collection passing through has the required number of elements.
|
HasStorageValue |
Evaluates to true if the specified storage value is present.
|
HasVariable |
Evaluates to true if the specified variable is set.
|
HasVariableValue |
Evaluates to true if the specified variable is present and its value is the same as the specified one.
|
InList |
Checks whether the incoming string is among the specified items.
|
IsAndroid |
Evaluates to 'true' if the operating system is Android.
|
IsArm64 |
Evaluates to 'true' if the system architecture is Arm64.
|
IsArray |
Evaluates to 'true' if the object passing through represents an array.
|
IsBoolean |
Evaluates to 'true' if the payload of the token is a boolean string (true|false).
|
IsByte |
Evaluates to 'true' if the payload of the token is a byte number/string.
|
IsBzip2Compressed |
Checks whether the file or byte array is Bzip2 compressed.
|
IsDouble |
Evaluates to 'true' if the payload of the token is a double number/string.
|
IsFloat |
Evaluates to 'true' if the payload of the token is a float number/string.
|
IsGzipCompressed |
Checks whether the file or byte array is Gzip compressed.
|
IsInteger |
Evaluates to 'true' if the payload of the token is an integer number/string.
|
IsLinux |
Evaluates to 'true' if the operating system is Linux.
|
IsLong |
Evaluates to 'true' if the payload of the token is a long number/string.
|
IsMac |
Evaluates to 'true' if the operating system is a Mac.
|
IsMat5Array |
Checks whether the object represents a Matlab array.
|
IsMat5Matrix |
Checks whether the object represents a Matlab matrix.
|
IsMat5Struct |
Checks whether the object represents a Matlab struct data structure.
|
IsNull |
Evaluates to 'true' if the payload of the token passing through is null.
|
IsNumeric |
Evaluates to 'true' if the payload of the token is a number or a numeric string.
|
IsRarCompressed |
Checks whether the file or byte array is Rar compressed.
|
IsShort |
Evaluates to 'true' if the payload of the token is a short number/string.
|
IsSubClass |
Evaluates to 'true' if the objects are derived from the specified superclass.
|
IsWindows |
Evaluates to 'true' if the operating system is a Windows variant.
|
IsXzCompressed |
Checks whether the file or byte array is Xz compressed.
|
IsZipCompressed |
Checks whether the file or byte array is Zip compressed.
|
IsZstdCompressed |
Checks whether the file or byte array is Zstd compressed.
|
Not |
Negates the output of the specified condition.
|
NotesErrors |
Evaluates to true if the notes handler passing through has any errors recorded.
|
Or |
Performs a logical OR over all its sub-conditions, i.e., it evaluates to 'true' if any of the sub-conditions evaluates to 'true' as well.
|
PromptUser |
Prompts the user to click on 'positive' or 'negative' button (negative button can be omitted).
The actor's name can be used in the message using the following placeholders:
{SHORT} - the short name
{FULL} - the full name (incl path)
Variables get expanded as well.
Can be used in a headless environment as well.
|
RegExp |
Returns the result of the regular expression matching the incoming string.
|
ReportValueExists |
Returns 'true' if the field in the report is present.
|
Scripted |
A boolean condition that uses the condition defined in an external script.
|
StorageFlagSet |
Evaluates to true if the specified storage value is present, a boolean and true.
|
TableExists |
Checks whether table(s) exist that match the given regular expression.
|
True |
Always evaluates to 'true'.
|
VariableFlagSet |
Evaluates to true if the specified variable is present, a boolean and true.
|
WekaCapabilities |
Filters weka.core.Instance and weka.core.Instances objects based on defined capabilities.
|
WekaClassification |
Uses the index of the classification, i.e., the predicted label, as index of the switch
|