{"size": 2681, "ext": "js", "max_stars_repo_path": "packages/emitter/lib/api.cjs.js", "max_stars_repo_name": "jasikpark/native", "max_stars_repo_stars_event_min_datetime": "2021-01-23T01:27:50.000Z", "max_stars_repo_stars_event_max_datetime": "2022-03-07T05:51:18.000Z", "max_issues_repo_path": "packages/emitter/lib/api.cjs.js", "max_issues_repo_name": "jasikpark/native", "max_issues_repo_issues_event_min_datetime": "2021-05-25T01:37:23.000Z", "max_issues_repo_issues_event_max_datetime": "2021-08-28T01:15:07.000Z", "max_forks_repo_path": "packages/emitter/lib/api.cjs.js", "max_forks_repo_name": "jasikpark/native", "max_forks_repo_forks_event_min_datetime": "2021-06-05T12:48:45.000Z", "max_forks_repo_forks_event_max_datetime": "2021-11-26T13:05:57.000Z"}
{"max_stars_count": 69, "max_issues_count": 22, "max_forks_count": 6, "avg_line_length": 1340.5, "max_line_length": 2680, "alphanum_fraction": 0.6684073107}
var y=Object.defineProperty;var g=s=>y(s,"__esModule",{value:!0});var d=(s,e)=>{g(s);for(var t in e)y(s,t,{get:e[t],enumerable:!0})};d(exports,{Event:()=>c,EventEmitter:()=>b,default:()=>E,newListener:()=>u});var o=class{constructor(e){this.map=new Map(e)}getMap(){return this.map}get(e){return this.map.get(e)}keys(){return Array.from(this.map.keys())}values(){return Array.from(this.map.values())}set(e,t){return this.map.set(e,t),this}add(e){let n=this.size;return this.set(n,e),this}get size(){return this.map.size}get length(){return this.map.size}last(e=1){let t=this.keys()[this.size-e];return this.get(t)}delete(e){return this.map.delete(e)}remove(e){return this.map.delete(e),this}clear(){return this.map.clear(),this}has(e){return this.map.has(e)}entries(){return this.map.entries()}forEach(e,t){return this.map.forEach(e,t),this}[Symbol.iterator](){return this.entries()}},f=(s,e,...t)=>{s.forEach(n=>{n[e](...t)})};var u=({callback:s=()=>{},scope:e=null,name:t="event"})=>({callback:s,scope:e,name:t}),c=class extends o{constructor(e="event"){super();this.name=e}},b=class extends o{constructor(){super()}getEvent(e){let t=this.get(e);return t instanceof c?t:(this.set(e,new c(e)),this.get(e))}newListener(e,t,n){let r=this.getEvent(e);return r.add(u({name:e,callback:t,scope:n})),r}on(e,t,n){if(typeof e=="undefined"||e==null)return this;typeof e=="string"&&(e=e.trim().split(/\s/g));let r,i,a=typeof e=="object"&&!Array.isArray(e),p=a?t:n;return a||(i=t),Object.keys(e).forEach(l=>{r=a?l:e[l],a&&(i=e[l]),this.newListener(r,i,p)},this),this}removeListener(e,t,n){let r=this.get(e);if(r instanceof c&&t){let i=u({name:e,callback:t,scope:n});r.forEach((a,p)=>{if(a.callback===i.callback&&a.scope===i.scope)return r.remove(p)})}return r}off(e,t,n){if(typeof e=="undefined"||e==null)return this;typeof e=="string"&&(e=e.trim().split(/\s/g));let r,i,a=typeof e=="object"&&!Array.isArray(e),p=a?t:n;return a||(i=t),Object.keys(e).forEach(l=>{r=a?l:e[l],a&&(i=e[l]),typeof i=="function"?this.removeListener(r,i,p):this.remove(r)},this),this}once(e,t,n){if(typeof e=="undefined"||e==null)return this;typeof e=="string"&&(e=e.trim().split(/\s/g));let r=typeof e=="object"&&!Array.isArray(e);return Object.keys(e).forEach(i=>{let a=r?i:e[i],p=r?e[i]:t,l=r?t:n,h=(...m)=>{p.apply(l,m),this.removeListener(a,h,l)};this.newListener(a,h,l)},this),this}emit(e,...t){return typeof e=="undefined"||e==null?this:(typeof e=="string"&&(e=e.trim().split(/\s/g)),e.forEach(n=>{let r=this.get(n);r instanceof c&&r.forEach(i=>{let{callback:a,scope:p}=i;a.apply(p,t)})},this),this)}clear(){return f(this,"clear"),super.clear(),this}},E=b;0&&(module.exports={Event,EventEmitter,newListener});
