src/aria/core/JsObject.js
function (itf, interceptor) {
                // get the interface constructor:
                var itfCstr = this.$interfaces[itf];
                if (!itfCstr) {
                    this.$logError(this.INTERFACE_NOT_SUPPORTED, [itf, this.$classpath]);
                    return;
                }
                var allInterceptors = this.__$interceptors;
                if (allInterceptors == null) {
                    allInterceptors = {};
                    this.__$interceptors = allInterceptors;
                }
                var interceptMethods = ((require("../utils/Type")).isCallback(interceptor))
                        ? __interceptCallback
                        : __interceptObject;

                var itfs = itfCstr.prototype.$interfaces;
                for (var i in itfs) {
                    if (itfs.hasOwnProperty(i)) {
                        var interceptedMethods = interceptMethods(itfs[i].interfaceDefinition.$interface, interceptor, allInterceptors[i]);
                        allInterceptors[i] = interceptedMethods;
                    }
                }
            }
function (itf, interceptor) {
                // get the interface constructor:
                var itfCstr = this.$interfaces[itf];
                if (!itfCstr) {
                    this.$logError(this.INTERFACE_NOT_SUPPORTED, [itf, this.$classpath]);
                    return;
                }
                var allInterceptors = this.__$interceptors;
                if (allInterceptors == null) {
                    allInterceptors = {};
                    this.__$interceptors = allInterceptors;
                }
                var interceptMethods = ((require("../utils/Type")).isCallback(interceptor))
                        ? __interceptCallback
                        : __interceptObject;

                var itfs = itfCstr.prototype.$interfaces;
                for (var i in itfs) {
                    if (itfs.hasOwnProperty(i)) {
                        var interceptedMethods = interceptMethods(itfs[i].interfaceDefinition.$interface, interceptor, allInterceptors[i]);
                        allInterceptors[i] = interceptedMethods;
                    }
                }
            }
function ( itf , interceptor ) { // get the interface constructor: var itfCstr = this . $interfaces [ itf ] ; if ( ! itfCstr ) { this . $logError ( this . INTERFACE_NOT_SUPPORTED , [ itf , this . $classpath ] ) ; return ; } var allInterceptors = this . __$interceptors ; if ( allInterceptors == null ) { allInterceptors = { } ; this . __$interceptors = allInterceptors ; } var interceptMethods = ( ( require ( "../utils/Type" ) ) . isCallback ( interceptor ) ) ? __interceptCallback : __interceptObject ; var itfs = itfCstr . prototype . $interfaces ; for ( var i in itfs ) { if ( itfs . hasOwnProperty ( i ) ) { var interceptedMethods = interceptMethods ( itfs [ i ] . interfaceDefinition . $interface , interceptor , allInterceptors [ i ] ) ; allInterceptors [ i ] = interceptedMethods ; } } }
Add an interceptor callback on an interface specified by its classpath.
@param {String} itf [mandatory] interface which will be intercepted
@param {Object|aria.core.CfgBeans:Callback} interceptor either a callback or an object/class which will
receive notifications
Add an interceptor callback on an interface specified by its classpath .