-
- All Implemented Interfaces:
-
it.unibo.alchemist.loader.variables.DependentVariable
,java.io.Serializable
public final class JSR223Variable<R extends Object> implements DependentVariable<R>
This variable loads any JSR-233 language available in the classpath.
-
-
Constructor Summary
Constructors Constructor Description JSR223Variable(String language, String formula)
builds a new JSR223Variable given a language name and a script.
-
Method Summary
Modifier and Type Method Description R
getWith(Map<String, Object> variables)
Given the current controlled variables, computes the current values for this variable. final String
component1()
final String
component2()
final JSR223Variable<R>
copy(String language, String formula)
final String
getLanguage()
final String
getFormula()
-
-
Method Detail
-
getWith
R getWith(Map<String, Object> variables)
Given the current controlled variables, computes the current values for this variable.
- Parameters:
variables
- a mapping between variable names and values
-
component1
final String component1()
-
component2
final String component2()
-
copy
final JSR223Variable<R> copy(String language, String formula)
- Parameters:
language
- can be the name of the language, the file extension, or its mime typeformula
- the script that will get interpreted
-
getLanguage
final String getLanguage()
-
getFormula
final String getFormula()
-
-
-
-