public final class PolyglotAccess.Builder extends Object
Modifier and Type | Method and Description |
---|---|
PolyglotAccess.Builder |
allowBindingsAccess(String language)
Allows access to polyglot bindings for a language.
|
PolyglotAccess.Builder |
allowEval(String from,
String to)
Allows evaluation of code by one language of another.
|
PolyglotAccess.Builder |
allowEvalBetween(String... languages)
Allows bidirectional evaluation of code between the given languages.
|
PolyglotAccess |
build()
Creates an instance of the custom polyglot access configuration.
|
PolyglotAccess.Builder |
denyBindingsAccess(String language)
Denies access to polyglot bindings for a language.
|
PolyglotAccess.Builder |
denyEval(String from,
String to)
Denies evaluation of code by one language of another.
|
PolyglotAccess.Builder |
denyEvalBetween(String... languages)
Denies bidirectional evaluation of code between the given languages.
|
public PolyglotAccess.Builder allowEvalBetween(String... languages)
"A"
and language "B"
, this is equivalent to calling
allowEval("A", "B")
and
allowEval("B", "A")
. If called with
more than two then all language evaluation combinations will be allowed. This method
potentially overrides already configured access rights with
PolyglotAccess.Builder.allowEval(String, String)
or PolyglotAccess.Builder.denyEval(String, String)
. The given
language array must be null
and individual languages must not be
null
.PolyglotAccess.Builder.allowEval(String, String)
public PolyglotAccess.Builder denyEvalBetween(String... languages)
"A"
and language "B"
, this is equivalent to calling
denyEval("A", "B")
and
denyEval("B", "A")
. If called with
more than two then all language access combinations will be denied. This method
potentially overrides already configured access rights with
PolyglotAccess.Builder.allowEval(String, String)
or PolyglotAccess.Builder.denyEval(String, String)
. The given
language array must be null
and individual languages must not be
null
.PolyglotAccess.Builder.denyEval(String, String)
public PolyglotAccess.Builder allowEval(String from, String to)
PolyglotAccess.Builder.allowEvalBetween(String...)
public PolyglotAccess.Builder denyEval(String from, String to)
PolyglotAccess.Builder.denyEvalBetween(String...)
public PolyglotAccess.Builder allowBindingsAccess(String language)
Polyglot.import
and Polyglot.export
.PolyglotAccess.Builder.denyBindingsAccess(String)
public PolyglotAccess.Builder denyBindingsAccess(String language)
null
.PolyglotAccess.Builder.allowBindingsAccess(String)
public PolyglotAccess build()