public class GraalRuntime extends EventEmitterImpl implements Runtime
| Constructor and Description |
|---|
GraalRuntime(io.vertx.core.Vertx vertx,
org.graalvm.polyglot.Context context) |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
close the current runtime and shutdown all the engine related resources.
|
void |
config(io.vertx.core.json.JsonObject config)
passes the given configuration to the runtime.
|
void |
enter()
explicitly enter the script engine scope.
|
org.graalvm.polyglot.Value |
eval(java.lang.String script,
java.lang.String name,
java.lang.String contentType,
boolean interactive)
Evals a given sript string.
|
void |
leave()
explicitly leave the script engine scope.
|
org.graalvm.polyglot.Value |
main(java.lang.String main)
Requires the main module as a commonjs module, the
module returned will be flagged as a main module.
|
void |
put(java.lang.String name,
java.lang.Object value)
Puts a value to the global scope.
|
org.graalvm.polyglot.Value |
require(java.lang.String main)
Require a module following the commonjs spec
|
org.graalvm.polyglot.Value |
worker(java.lang.String main,
java.lang.String address)
Loads a JS Worker, meaning it will become a Vert.x Worker.
|
emit, onclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitemit, onpublic GraalRuntime(io.vertx.core.Vertx vertx,
org.graalvm.polyglot.Context context)
public void config(io.vertx.core.json.JsonObject config)
Runtimepublic org.graalvm.polyglot.Value require(java.lang.String main)
Runtimepublic org.graalvm.polyglot.Value main(java.lang.String main)
Runtimepublic org.graalvm.polyglot.Value worker(java.lang.String main,
java.lang.String address)
Runtimepublic org.graalvm.polyglot.Value eval(java.lang.String script,
java.lang.String name,
java.lang.String contentType,
boolean interactive)
Runtimepublic void put(java.lang.String name,
java.lang.Object value)
Runtimepublic void close()
Runtimepublic void enter()
RuntimeCopyright © 2019. All Rights Reserved.