Class JSR223Variable

  • All Implemented Interfaces:
    it.unibo.alchemist.boundary.DependentVariable , java.io.Serializable

    
    public final class JSR223Variable
     implements DependentVariable<Any>
                        

    This variable loads any JSR-233 language available in the classpath.

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Constructor Summary

      Constructors 
      Constructor Description
      JSR223Variable(String language, String formula, Long timeout) builds a new JSR223Variable given a language name and a script.
      JSR223Variable(String language, String formula) builds a new JSR223Variable given a language name and a script.
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      final String getLanguage()
      final String getFormula()
      final Long getTimeout()
      Object getWith(Map<String, Object> variables) Given the current controlled variables, computes the current values for this variable.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • JSR223Variable

        JSR223Variable(String language, String formula, Long timeout)
        builds a new JSR223Variable given a language name and a script.
        Parameters:
        language - can be the name of the language, the file extension, or its mime type
        formula - the script that will get interpreted
        timeout - how long should the interpreter be allowed to compute before giving up, in ms.
      • JSR223Variable

        JSR223Variable(String language, String formula)
        builds a new JSR223Variable given a language name and a script.
        Parameters:
        language - can be the name of the language, the file extension, or its mime type
        formula - the script that will get interpreted