Class SlingWrapFactory
- java.lang.Object
-
- org.mozilla.javascript.WrapFactory
-
- org.apache.sling.scripting.javascript.helper.SlingWrapFactory
-
public class SlingWrapFactory extends org.mozilla.javascript.WrapFactory
-
-
Constructor Summary
Constructors Constructor Description SlingWrapFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidregisterWrapper(Class<?> javaClass, String hostObjectName)voidunregisterWrapper(Class<?> javaClass)org.mozilla.javascript.ScriptablewrapAsJavaObject(org.mozilla.javascript.Context cx, org.mozilla.javascript.Scriptable scope, Object javaObject, Class staticType)
-
-
-
Method Detail
-
wrapAsJavaObject
public org.mozilla.javascript.Scriptable wrapAsJavaObject(org.mozilla.javascript.Context cx, org.mozilla.javascript.Scriptable scope, Object javaObject, Class staticType)- Overrides:
wrapAsJavaObjectin classorg.mozilla.javascript.WrapFactory- Parameters:
cx- the current Context for this threadscope- the scope of the executing scriptjavaObject- the object to be wrappedstaticType- type hint. If security restrictions prevent to wrap object based on its class, staticType will be used instead.- Returns:
- the wrapped value which shall not be null
-
unregisterWrapper
public void unregisterWrapper(Class<?> javaClass)
-
-