org.neo4j.server.scripting.javascript
Class GlobalJavascriptInitializer
java.lang.Object
org.neo4j.server.scripting.javascript.GlobalJavascriptInitializer
public class GlobalJavascriptInitializer
- extends Object
Forgive me Kent Beck, for I have sinned.
Rhino's security model means we need to globally define it, so that horridness
has been delegated to this class.
It allows initializing the global javascript context as either sandboxed or unsafe.
If you initialize it twice and ask for different modes, an exception will be thrown
as the mode cannot be changed after initialization.
We could do some crazy stuff and build a context factory that can be hooked into after
the fact and modified, but the plan is to get rid of the ability to switch between unsafe
and sandboxed modes, and only allow sandboxed. Unsafe exists for backwards compatibility.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
GlobalJavascriptInitializer
public GlobalJavascriptInitializer()
initialize
public static void initialize(GlobalJavascriptInitializer.Mode requestedMode)
Copyright © 2002-2013 The Neo4j Graph Database Project. All Rights Reserved.