public class LazyBindingsCustomizer extends Object implements BindingsCustomizer
GremlinScriptEngine. If this customizer is applied
directly to a GremlinScriptEngine it will not apply GLOBAL_SCOPE bindings. Those can only be applied
if the customizer is applied via the GremlinScriptEngineManager (which would do so through the
BindingsGremlinPlugin.| Constructor and Description |
|---|
LazyBindingsCustomizer(Supplier<Bindings> bindingsSupplier)
Creates a new object with
ScriptContext.ENGINE_SCOPE. |
LazyBindingsCustomizer(Supplier<Bindings> bindingsSupplier,
int scope) |
| Modifier and Type | Method and Description |
|---|---|
Bindings |
getBindings()
Gets the bindings to add to a
GremlinScriptEngine. |
int |
getScope()
Gets the scope to which the bindings apply.
|
public LazyBindingsCustomizer(Supplier<Bindings> bindingsSupplier)
ScriptContext.ENGINE_SCOPE.public Bindings getBindings()
BindingsCustomizerGremlinScriptEngine.getBindings in interface BindingsCustomizerpublic int getScope()
BindingsCustomizerScriptContext values where
"100" is EngineScope (bindings apply to the current GremlinScriptEngine) and "200" is
GlobalScope (bindings apply to the engines created by the current GremlinScriptEngineManager.getScope in interface BindingsCustomizerCopyright © 2013–2017 Apache Software Foundation. All rights reserved.