Class RubyScript

  • All Implemented Interfaces:
    Script

    public class RubyScript
    extends AbstractScript
    A Ruby script.
    Author:
    harald
    • Constructor Detail

      • RubyScript

        public RubyScript​(RubyLanguage language,
                          org.jruby.embed.ScriptingContainer container,
                          String code,
                          boolean cached,
                          boolean threadSafe)
        Creates a ruby script.
        Parameters:
        language - the language
        code - the scripting code
        cached - true if cached
        threadSafe - true if threadsafety required
    • Method Detail

      • validate

        public void validate()
      • getCompiledScript

        protected CompiledRubyScript getCompiledScript()
        Gets the compiled script.
        Will be parsed if not done yet.
        Returns:
        the compiled script
      • compileScript

        protected CompiledRubyScript compileScript​(String code)
        Compiles script code.
        Parameters:
        code - the scripting source code
        Returns:
        the compiled script