Class EventTargetWrapper.FunctionAddProxy

  • All Implemented Interfaces:
    org.mozilla.javascript.Callable, org.mozilla.javascript.Function, org.mozilla.javascript.Scriptable
    Enclosing class:
    EventTargetWrapper

    static class EventTargetWrapper.FunctionAddProxy
    extends EventTargetWrapper.FunctionProxy
    This function proxy is delegating most of the job to the underlying NativeJavaMethod object through the FunctionProxy. However to allow user to specify "Function" or objects with an "handleEvent" method as parameter of "addEventListener" it redefines the call method to deal with these cases.
    • Field Detail

      • listenerMap

        protected java.util.Map listenerMap
    • Constructor Detail

      • FunctionAddProxy

        FunctionAddProxy​(RhinoInterpreter interpreter,
                         org.mozilla.javascript.Function delegate,
                         java.util.Map listenerMap)
    • Method Detail

      • call

        public java.lang.Object call​(org.mozilla.javascript.Context ctx,
                                     org.mozilla.javascript.Scriptable scope,
                                     org.mozilla.javascript.Scriptable thisObj,
                                     java.lang.Object[] args)