Package org.codehaus.groovy.jsr223
Class GroovyScriptEngineFactory
java.lang.Object
org.codehaus.groovy.jsr223.GroovyScriptEngineFactory
- All Implemented Interfaces:
ScriptEngineFactory
A factory class conforming to JSR-223 which is used to instantiate
Groovy
ScriptEngines
and also exposes metadata describing
Groovy's engine class.
Adapted from original by Mike Grogan and A. Sundararajan-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionNote that the scripting.dev.java.net engine had this backwards.This is also different from scripting.dev.java.net which used an initial lowercase.getMethodCallSyntax
(String obj, String method, String... args) getNames()
getOutputStatement
(String toDisplay) getParameter
(String key) getProgram
(String... statements)
-
Constructor Details
-
GroovyScriptEngineFactory
public GroovyScriptEngineFactory()
-
-
Method Details
-
getEngineName
- Specified by:
getEngineName
in interfaceScriptEngineFactory
-
getEngineVersion
Note that the scripting.dev.java.net engine had this backwards. The engine version refers to this engine implementation. Whereas language version refers to the groovy implementation (which is obtained from the runtime).- Specified by:
getEngineVersion
in interfaceScriptEngineFactory
-
getLanguageName
This is also different from scripting.dev.java.net which used an initial lowercase. But these are proper names and should be capitalized.- Specified by:
getLanguageName
in interfaceScriptEngineFactory
-
getLanguageVersion
- Specified by:
getLanguageVersion
in interfaceScriptEngineFactory
-
getExtensions
- Specified by:
getExtensions
in interfaceScriptEngineFactory
-
getMimeTypes
- Specified by:
getMimeTypes
in interfaceScriptEngineFactory
-
getNames
- Specified by:
getNames
in interfaceScriptEngineFactory
-
getParameter
- Specified by:
getParameter
in interfaceScriptEngineFactory
-
getScriptEngine
- Specified by:
getScriptEngine
in interfaceScriptEngineFactory
-
getMethodCallSyntax
- Specified by:
getMethodCallSyntax
in interfaceScriptEngineFactory
-
getOutputStatement
- Specified by:
getOutputStatement
in interfaceScriptEngineFactory
-
getProgram
- Specified by:
getProgram
in interfaceScriptEngineFactory
-