Package VASSAL.script
Class BeanShell
java.lang.Object
VASSAL.script.BeanShell
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
protected ScriptInterpreter
protected static final String
static final String
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
executeActionScript
(String scriptName) Execute a Script named in a component DoAction or trait DoAction.bsh.NameSpace
Return the Vassal shared NameSpacestatic BeanShell
void
init()
static boolean
validateExpression
(String expression) Parse and validate a single expression or script.static Object
Convert a String value into a wrapped primitive object if possible.
-
Field Details
-
TRUE
- See Also:
-
FALSE
- See Also:
-
INIT_SCRIPT
- See Also:
-
globalInterpreter
-
-
Constructor Details
-
BeanShell
public BeanShell()
-
-
Method Details
-
getInstance
-
init
public void init() -
compile
-
getGlobalNameSpace
public bsh.NameSpace getGlobalNameSpace()Return the Vassal shared NameSpace- Returns:
- Global NameSpace
-
executeActionScript
Execute a Script named in a component DoAction or trait DoAction. Action Scripts take no parameters and return no value.- Parameters:
scriptName
- Script name
-
validateExpression
Parse and validate a single expression or script. No evaluation or checking for undefined variables- Parameters:
expression
- Expression to validate
-
wrap
-