javax.script
12 classes of the module java.scripting.
Load them with:
using {
"javax.script"
}
AbstractScriptEngine#
abstract · extends Object · javax.script.AbstractScriptEngine
Implements: ScriptEngine
Fields
| Name | Type | Access | In Ring |
|---|---|---|---|
ARGV | String | constant · static | o.ARGV |
FILENAME | String | constant · static | o.FILENAME |
ENGINE | String | constant · static | o.ENGINE |
ENGINE_VERSION | String | constant · static | o.ENGINE_VERSION |
NAME | String | constant · static | o.NAME |
LANGUAGE | String | constant · static | o.LANGUAGE |
LANGUAGE_VERSION | String | constant · static | o.LANGUAGE_VERSION |
Methods
| Method | Ring call | Java overloads |
|---|---|---|
@get | @get(key) | Object get(String key) |
@put | @put(key,value) | void put(String key, Object value) |
createBindings | createBindings() | Bindings createBindings() |
eval | eval(reader)eval([script,bindings])eval([ :script = v, :bindings = v ]) | Object eval(Reader reader)Object eval(String script)Object eval(String script, Bindings bindings)Object eval(Reader reader, Bindings bindings)Object eval(Reader reader, ScriptContext context)Object eval(String script, ScriptContext context) |
getBindings | getBindings(scope) | Bindings getBindings(int scope) |
getContext | getContext() | ScriptContext getContext() |
getFactory | getFactory() | ScriptEngineFactory getFactory() |
setBindings | setBindings(bindings,scope) | void setBindings(Bindings bindings, int scope) |
setContext | setContext(ctxt) | void setContext(ScriptContext ctxt) |
The methods and fields of Object are inherited.
Bindings#
interface · javax.script.Bindings
Extends: Map
Methods
| Method | Ring call | Java overloads |
|---|---|---|
@forEach | @forEach(action) | void forEach(BiConsumer action) |
@get | @get(key) | Object get(Object key) |
@put | @put(name,value) | Object put(String name, Object value) |
clear | clear() | void clear() |
compute | compute(key,remappingFunction) | Object compute(Object key, BiFunction remappingFunction) |
computeIfAbsent | computeIfAbsent(key,mappingFunction) | Object computeIfAbsent(Object key, Function mappingFunction) |
computeIfPresent | computeIfPresent(key,remappingFunction) | Object computeIfPresent(Object key, BiFunction remappingFunction) |
containsKey | containsKey(key) | boolean containsKey(Object key) |
containsValue | containsValue(value) | boolean containsValue(Object value) |
entrySet | entrySet() | Set entrySet() |
equals | equals(o) | boolean equals(Object o) |
getOrDefault | getOrDefault(key,defaultValue) | Object getOrDefault(Object key, Object defaultValue) |
hashCode | hashCode() | int hashCode() |
isEmpty | isEmpty() | boolean isEmpty() |
keySet | keySet() | Set keySet() |
merge | merge(key,value,remappingFunction) | Object merge(Object key, Object value, BiFunction remappingFunction) |
putAll | putAll(toMerge) | void putAll(Map toMerge) |
putIfAbsent | putIfAbsent(key,value) | Object putIfAbsent(Object key, Object value) |
remove | remove(key)remove([key,value])remove([ :key = v, :value = v ]) | Object remove(Object key)boolean remove(Object key, Object value) |
replace | replace([key,value])replace([ :key = v, :value = v ])replace([key,oldValue,newValue])replace([ :key = v, :oldValue = v, :newValue = v ]) | Object replace(Object key, Object value)boolean replace(Object key, Object oldValue, Object newValue) |
replaceAll | replaceAll(function) | void replaceAll(BiFunction function) |
size | size() | int size() |
values | values() | Collection values() |
Compilable#
interface · javax.script.Compilable
Methods
| Method | Ring call | Java overloads |
|---|---|---|
compile | compile(script) | CompiledScript compile(String script)CompiledScript compile(Reader script) |
CompiledScript#
abstract · extends Object · javax.script.CompiledScript
Methods
| Method | Ring call | Java overloads |
|---|---|---|
@eval | @eval(bindings) | Object eval(Bindings bindings)Object eval(ScriptContext context) |
eval | eval() | Object eval() |
getEngine | getEngine() | ScriptEngine getEngine() |
The methods and fields of Object are inherited.
Invocable#
interface · javax.script.Invocable
Methods
| Method | Ring call | Java overloads |
|---|---|---|
getInterface | getInterface(clasz)getInterface([thiz,clasz])getInterface([ :thiz = v, :clasz = v ]) | Object getInterface(Class clasz)Object getInterface(Object thiz, Class clasz) |
invokeFunction | invokeFunction(name,args) | Object invokeFunction(String name, Object[] args) |
invokeMethod | invokeMethod(thiz,name,args) | Object invokeMethod(Object thiz, String name, Object[] args) |
ScriptContext#
interface · javax.script.ScriptContext
Fields
| Name | Type | Access | In Ring |
|---|---|---|---|
ENGINE_SCOPE | int | constant · static | o.ENGINE_SCOPE |
GLOBAL_SCOPE | int | constant · static | o.GLOBAL_SCOPE |
Methods
| Method | Ring call | Java overloads |
|---|---|---|
getAttribute | getAttribute(name)getAttribute([name,scope])getAttribute([ :name = v, :scope = v ]) | Object getAttribute(String name)Object getAttribute(String name, int scope) |
getAttributesScope | getAttributesScope(name) | int getAttributesScope(String name) |
getBindings | getBindings(scope) | Bindings getBindings(int scope) |
getErrorWriter | getErrorWriter() | Writer getErrorWriter() |
getReader | getReader() | Reader getReader() |
getScopes | getScopes() | List getScopes() |
getWriter | getWriter() | Writer getWriter() |
removeAttribute | removeAttribute(name,scope) | Object removeAttribute(String name, int scope) |
setAttribute | setAttribute(name,value,scope) | void setAttribute(String name, Object value, int scope) |
setBindings | setBindings(bindings,scope) | void setBindings(Bindings bindings, int scope) |
setErrorWriter | setErrorWriter(writer) | void setErrorWriter(Writer writer) |
setReader | setReader(reader) | void setReader(Reader reader) |
setWriter | setWriter(writer) | void setWriter(Writer writer) |
ScriptEngine#
interface · javax.script.ScriptEngine
Fields
| Name | Type | Access | In Ring |
|---|---|---|---|
ARGV | String | constant · static | o.ARGV |
FILENAME | String | constant · static | o.FILENAME |
ENGINE | String | constant · static | o.ENGINE |
ENGINE_VERSION | String | constant · static | o.ENGINE_VERSION |
NAME | String | constant · static | o.NAME |
LANGUAGE | String | constant · static | o.LANGUAGE |
LANGUAGE_VERSION | String | constant · static | o.LANGUAGE_VERSION |
Methods
| Method | Ring call | Java overloads |
|---|---|---|
@get | @get(key) | Object get(String key) |
@put | @put(key,value) | void put(String key, Object value) |
createBindings | createBindings() | Bindings createBindings() |
eval | eval(reader)eval([reader,context])eval([ :reader = v, :context = v ]) | Object eval(Reader reader)Object eval(String script)Object eval(Reader reader, ScriptContext context)Object eval(String script, ScriptContext context)Object eval(String script, Bindings n)Object eval(Reader reader, Bindings n) |
getBindings | getBindings(scope) | Bindings getBindings(int scope) |
getContext | getContext() | ScriptContext getContext() |
getFactory | getFactory() | ScriptEngineFactory getFactory() |
setBindings | setBindings(bindings,scope) | void setBindings(Bindings bindings, int scope) |
setContext | setContext(context) | void setContext(ScriptContext context) |
ScriptEngineFactory#
interface · javax.script.ScriptEngineFactory
Methods
| Method | Ring call | Java overloads |
|---|---|---|
getEngineName | getEngineName() | String getEngineName() |
getEngineVersion | getEngineVersion() | String getEngineVersion() |
getExtensions | getExtensions() | List getExtensions() |
getLanguageName | getLanguageName() | String getLanguageName() |
getLanguageVersion | getLanguageVersion() | String getLanguageVersion() |
getMethodCallSyntax | getMethodCallSyntax(obj,m,args) | String getMethodCallSyntax(String obj, String m, String[] args) |
getMimeTypes | getMimeTypes() | List getMimeTypes() |
getNames | getNames() | List getNames() |
getOutputStatement | getOutputStatement(toDisplay) | String getOutputStatement(String toDisplay) |
getParameter | getParameter(key) | Object getParameter(String key) |
getProgram | getProgram(statements) | String getProgram(String[] statements) |
getScriptEngine | getScriptEngine() | ScriptEngine getScriptEngine() |
ScriptEngineManager#
class · extends Object · javax.script.ScriptEngineManager
Constructors
new ScriptEngineManager() |
new ScriptEngineManager(ClassLoader loader) |
Ring: new ScriptEngineManager(args) uses the constructor with the fewest parameters (at least one); new ScriptEngineManager makes the object with the constructor without parameters; the others: (new ScriptEngineManager).@New([ :param = value ]) or .@New([v1,v2]).
Methods
| Method | Ring call | Java overloads |
|---|---|---|
@get | @get(key) | Object get(String key) |
@put | @put(key,value) | void put(String key, Object value) |
getBindings | getBindings() | Bindings getBindings() |
getEngineByExtension | getEngineByExtension(extension) | ScriptEngine getEngineByExtension(String extension) |
getEngineByMimeType | getEngineByMimeType(mimeType) | ScriptEngine getEngineByMimeType(String mimeType) |
getEngineByName | getEngineByName(shortName) | ScriptEngine getEngineByName(String shortName) |
getEngineFactories | getEngineFactories() | List getEngineFactories() |
registerEngineExtension | registerEngineExtension(extension,factory) | void registerEngineExtension(String extension, ScriptEngineFactory factory) |
registerEngineMimeType | registerEngineMimeType(type,factory) | void registerEngineMimeType(String type, ScriptEngineFactory factory) |
registerEngineName | registerEngineName(name,factory) | void registerEngineName(String name, ScriptEngineFactory factory) |
setBindings | setBindings(bindings) | void setBindings(Bindings bindings) |
The methods and fields of Object are inherited.
ScriptException#
class · extends Exception · javax.script.ScriptException
Constructors
new ScriptException(Exception e) |
new ScriptException(String s) |
new ScriptException(String message, String fileName, int lineNumber) |
new ScriptException(String message, String fileName, int lineNumber, int columnNumber) |
Ring: new ScriptException(args) uses the constructor with the fewest parameters (at least one); new ScriptException makes the object with the constructor without parameters; the others: (new ScriptException).@New([ :param = value ]) or .@New([v1,v2]).
Methods
| Method | Ring call | Java overloads |
|---|---|---|
getColumnNumber | getColumnNumber() | int getColumnNumber() |
getFileName | getFileName() | String getFileName() |
getLineNumber | getLineNumber() | int getLineNumber() |
The methods and fields of Exception are inherited.
SimpleBindings#
class · extends Object · javax.script.SimpleBindings
Implements: Bindings
Constructors
new SimpleBindings() |
new SimpleBindings(Map m) |
Ring: new SimpleBindings(args) uses the constructor with the fewest parameters (at least one); new SimpleBindings makes the object with the constructor without parameters; the others: (new SimpleBindings).@New([ :param = value ]) or .@New([v1,v2]).
Methods
| Method | Ring call | Java overloads |
|---|---|---|
@forEach | @forEach(action) | void forEach(BiConsumer action) |
@get | @get(key) | Object get(Object key) |
@put | @put(name,value) | Object put(String name, Object value) |
clear | clear() | void clear() |
compute | compute(key,remappingFunction) | Object compute(Object key, BiFunction remappingFunction) |
computeIfAbsent | computeIfAbsent(key,mappingFunction) | Object computeIfAbsent(Object key, Function mappingFunction) |
computeIfPresent | computeIfPresent(key,remappingFunction) | Object computeIfPresent(Object key, BiFunction remappingFunction) |
containsKey | containsKey(key) | boolean containsKey(Object key) |
containsValue | containsValue(value) | boolean containsValue(Object value) |
entrySet | entrySet() | Set entrySet() |
getOrDefault | getOrDefault(key,defaultValue) | Object getOrDefault(Object key, Object defaultValue) |
isEmpty | isEmpty() | boolean isEmpty() |
keySet | keySet() | Set keySet() |
merge | merge(key,value,remappingFunction) | Object merge(Object key, Object value, BiFunction remappingFunction) |
putAll | putAll(toMerge) | void putAll(Map toMerge) |
putIfAbsent | putIfAbsent(key,value) | Object putIfAbsent(Object key, Object value) |
remove | remove(key)remove([key,value])remove([ :key = v, :value = v ]) | Object remove(Object key)boolean remove(Object key, Object value) |
replace | replace([key,value])replace([ :key = v, :value = v ])replace([key,oldValue,newValue])replace([ :key = v, :oldValue = v, :newValue = v ]) | Object replace(Object key, Object value)boolean replace(Object key, Object oldValue, Object newValue) |
replaceAll | replaceAll(function) | void replaceAll(BiFunction function) |
size | size() | int size() |
values | values() | Collection values() |
The methods and fields of Object are inherited.
SimpleScriptContext#
class · extends Object · javax.script.SimpleScriptContext
Implements: ScriptContext
Constructors
new SimpleScriptContext() |
Ring: new SimpleScriptContext(args) uses the constructor with the fewest parameters (at least one); new SimpleScriptContext makes the object with the constructor without parameters; the others: (new SimpleScriptContext).@New([ :param = value ]) or .@New([v1,v2]).
Fields
| Name | Type | Access | In Ring |
|---|---|---|---|
ENGINE_SCOPE | int | constant · static | o.ENGINE_SCOPE |
GLOBAL_SCOPE | int | constant · static | o.GLOBAL_SCOPE |
Methods
| Method | Ring call | Java overloads |
|---|---|---|
getAttribute | getAttribute(name)getAttribute([name,scope])getAttribute([ :name = v, :scope = v ]) | Object getAttribute(String name)Object getAttribute(String name, int scope) |
getAttributesScope | getAttributesScope(name) | int getAttributesScope(String name) |
getBindings | getBindings(scope) | Bindings getBindings(int scope) |
getErrorWriter | getErrorWriter() | Writer getErrorWriter() |
getReader | getReader() | Reader getReader() |
getScopes | getScopes() | List getScopes() |
getWriter | getWriter() | Writer getWriter() |
removeAttribute | removeAttribute(name,scope) | Object removeAttribute(String name, int scope) |
setAttribute | setAttribute(name,value,scope) | void setAttribute(String name, Object value, int scope) |
setBindings | setBindings(bindings,scope) | void setBindings(Bindings bindings, int scope) |
setErrorWriter | setErrorWriter(writer) | void setErrorWriter(Writer writer) |
setReader | setReader(reader) | void setReader(Reader reader) |
setWriter | setWriter(writer) | void setWriter(Writer writer) |
The methods and fields of Object are inherited.