1this.DDC=this.DDC||{},this.DDC.pubsub=function(){"use strict";function e(e,i){for(var n=0;n<i.length;n++){var r=i[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,t(r.key),r)}}function t(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}return new(function(){return t=function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.listeners={},this.tokenId=-1},(i=[{key:"_listenerHasTopic",value:function(e){for(var t in this.listeners)if(this.listeners.hasOwnProperty(e))return!0}},{key:"_showListeners",value:function(e){return e?this.listeners[e]||[]:this.listeners}},{key:"publish",value:function(e){for(var t=this,i=arguments.length,n=new Array(i>1?i-1:0),r=1;r<i;r++)n[r-1]=arguments[r];this._listenerHasTopic(e)&&this.listeners[e].length&&this.listeners[e].forEach((function(i){var r=i.callback,s=i.once,o=i.token;"function"==typeof r&&(r.apply(void 0,n),s&&t.unsubscribe(e,o))}))}},{key:"publishDelayed",value:function(e,t){var i,n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:200,s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:5e3,o=setTimeout((function(){clearInterval(i)}),s),u=function(){n._listenerHasTopic(e)&&(clearTimeout(o),clearInterval(i),n.publish(e,t))};i=setInterval(u,r)}},{key:"subscribe",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];this._listenerHasTopic(e)||(this.listeners[e]=[]);var n=String(++this.tokenId);return this.listeners[e].push({token:n,callback:t,once:i}),{unsubscribe:this.unsubscribe.bind(this,e,n)}}},{key:"subscribeOnce",value:function(e,t){return this.subscribe(e,t,!0)}},{key:"unsubscribe",value:function(e,t){t||!this._listenerHasTopic(e)?this.listeners[e]=this.listeners[e].filter((function(e){return e.token!==t})):delete this.listeners[e]}}])&&e(t.prototype,i),n&&e(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,i,n}())}(); 2//# sourceMappingURL=pubsub.min.js.map
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.