Socket
Socket
Sign inDemoInstall

@blackglory/structures

Package Overview
Dependencies
Maintainers
1
Versions
101
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@blackglory/structures - npm Package Compare versions

Comparing version 0.2.2 to 0.2.3

lib/es2015/hash-map.d.ts

7

CHANGELOG.md

@@ -5,2 +5,9 @@ # Changelog

### [0.2.3](https://github.com/BlackGlory/structures/compare/v0.2.2...v0.2.3) (2021-07-28)
### Features
* add HashMap ([f605460](https://github.com/BlackGlory/structures/commit/f605460e766c4117cb64bd2be552cfc300281aa8))
### [0.2.2](https://github.com/BlackGlory/structures/compare/v0.2.1...v0.2.2) (2021-07-04)

@@ -7,0 +14,0 @@

2

dist/es2015/index.umd.min.js

@@ -16,3 +16,3 @@ !function(t,n){"object"==typeof exports&&"undefined"!=typeof module?n(exports):"function"==typeof define&&define.amd?define(["exports"],n):n((t="undefined"!=typeof globalThis?globalThis:t||self).Structures={})}(this,(function(t){"use strict";

***************************************************************************** */
function n(t,n,e,r){if("a"===e&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof n?t!==n||!r:!n.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===e?r:"a"===e?r.call(t):r?r.value:n.get(t)}var e,r,o;class i{constructor(){e.set(this,new Map)}get[(e=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}on(t,r){n(this,e,"f").has(t)||n(this,e,"f").set(t,new Set);n(this,e,"f").get(t).add(r)}off(t,r){if(!n(this,e,"f").has(t))return;const o=n(this,e,"f").get(t);o.delete(r),0===o.size&&n(this,e,"f").delete(t)}emit(t,r){if(!n(this,e,"f").has(t))return;n(this,e,"f").get(t).forEach((t=>t(r)))}}class s{constructor(t){this.hash=t,r.set(this,new Map)}get[(r=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}get size(){return n(this,r,"f").size}[Symbol.iterator](){return n(this,r,"f").values()}add(t){return n(this,r,"f").set(this.hash(t),t),this}delete(t){return n(this,r,"f").delete(this.hash(t))}has(t){return n(this,r,"f").has(this.hash(t))}clear(){n(this,r,"f").clear()}values(){return n(this,r,"f").values()}}class a{constructor(){o.set(this,[])}get[(o=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}get size(){return n(this,o,"f").length}empty(){n(this,o,"f").length=0}enqueue(...t){n(this,o,"f").push(...t)}dequeue(){return n(this,o,"f").shift()}remove(t){let e;for(;(e=n(this,o,"f").indexOf(t))>=0;)n(this,o,"f").splice(e,1)}}var c="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},u={},f={CustomError:void 0};class l extends Error{get name(){return this.constructor.name}}f.CustomError=l;var d={ExpectedError:void 0};const y=f;class h extends y.CustomError{}d.ExpectedError=h;var v={AssertionError:void 0};const p=f;class m extends p.CustomError{}v.AssertionError=m;var b={};b.normalize=void 0,b.normalize=function(t){var n;return{name:t.name,message:t.message,stack:null!==(n=t.stack)&&void 0!==n?n:null}};var g={refute:void 0};const w=d;g.refute=function(t,n){if(t)throw new w.ExpectedError(n)};var A={assert:void 0};const S=v;var I,T;A.assert=function(t,n){if(!t)throw new S.AssertionError(n)},function(t){var n=c&&c.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=c&&c.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(f,t),e(d,t),e(v,t),e(b,t),e(g,t),e(A,t)}(u);class O{constructor(t){I.set(this,void 0),T.set(this,new Map),u.assert(Number.isInteger(t),"The parameter limit must be an integer"),u.assert(t>0,"The parameter limit must be a positive value"),function(t,n,e,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof n?t!==n||!o:!n.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");"a"===r?o.call(t,e):o?o.value=e:n.set(t,e)}(this,I,t,"f")}get[(I=new WeakMap,T=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}get size(){return n(this,T,"f").size}set(t,e){return n(this,T,"f").has(t)?this.updateItem(t,e):(n(this,T,"f").size===n(this,I,"f")&&n(this,T,"f").delete(this.getColdestKey()),n(this,T,"f").set(t,e)),this}has(t){return n(this,T,"f").has(t)}get(t){if(!this.has(t))return;const e=n(this,T,"f").get(t);return this.updateItem(t,e),e}delete(t){return n(this,T,"f").delete(t)}clear(){n(this,T,"f").clear()}updateItem(t,e){n(this,T,"f").delete(t),n(this,T,"f").set(t,e)}getColdestKey(){return n(this,T,"f").keys().next().value}}var j={},k={},x={},E={},R={};R.go=void 0,R.go=function(t){return t()},function(t){var n=c&&c.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]});(c&&c.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)})(R,t)}(E),x.chunkAsync=void 0;const N=E,q=u;x.chunkAsync=function(t,n){return q.assert(Number.isInteger(n),"The parameter size must be an integer"),q.assert(n>0,"The parameter size must be greater than 0"),N.go((async function*(){let e=[];for await(const r of t)e.push(r),e.length>=n&&(yield e,e=[]);e.length&&(yield e)}))};var B={},_={},C={};function P(t){return Array.isArray(t)}C.isntEmptyArray=C.isEmptyArray=C.isntArray=C.isArray=void 0,C.isArray=P,C.isntArray=function(t){return!P(t)},C.isEmptyArray=function(t){return 0===t.length},C.isntEmptyArray=function(t){return 0!==t.length};var U={},J={};function z(t){return null===t}J.isntNull=J.isNull=void 0,J.isNull=z,J.isntNull=function(t){return!z(t)};var D={};function M(t){return void 0===t}D.isntUndefined=D.isUndefined=void 0,D.isUndefined=M,D.isntUndefined=function(t){return!M(t)},U.isntAsyncIterable=U.isAsyncIterable=void 0;const F=J,W=D;function L(t){return F.isntNull(t)&&W.isntUndefined(t)&&"function"==typeof t[Symbol.asyncIterator]}U.isAsyncIterable=L,U.isntAsyncIterable=function(t){return!L(t)};var K={};function V(t){return"boolean"==typeof t}K.isntBoolean=K.isBoolean=void 0,K.isBoolean=V,K.isntBoolean=function(t){return!V(t)};var H={},Q={};function G(t){return X(t)||Y(t)}function X(t){return"string"==typeof t}function Y(t){return"object"==typeof t&&t instanceof String}Q.isntStringObject=Q.isStringObject=Q.isntStringPrimitive=Q.isStringPrimitive=Q.isntString=Q.isString=void 0,Q.isString=G,Q.isntString=function(t){return!G(t)},Q.isStringPrimitive=X,Q.isntStringPrimitive=function(t){return!X(t)},Q.isStringObject=Y,Q.isntStringObject=function(t){return!Y(t)},H.isntCharObject=H.isCharObject=H.isntCharPrimitive=H.isCharPrimitive=H.isntChar=H.isChar=void 0;const Z=Q;function $(t){return(Z.isString(t)||Z.isStringObject(t))&&1===t.length}function tt(t){return Z.isString(t)&&1===t.length}function nt(t){return Z.isStringObject(t)&&1===t.length}H.isChar=$,H.isntChar=function(t){return!$(t)},H.isCharPrimitive=tt,H.isntCharPrimitive=function(t){return!tt(t)},H.isCharObject=nt,H.isntCharObject=function(t){return!nt(t)};var et={};function rt(t){return t instanceof Date}et.isntDate=et.isDate=void 0,et.isDate=rt,et.isntDate=function(t){return!rt(t)};var ot={};ot.inEnum=void 0,ot.inEnum=function(t,n){return Object.values(n).includes(t)};var it={};function st(t){return!t}it.isntFalsy=it.isFalsy=void 0,it.isFalsy=st,it.isntFalsy=function(t){return!st(t)};var at={};function ct(t){return"function"==typeof t}at.isntFunction=at.isFunction=void 0,at.isFunction=ct,at.isntFunction=function(t){return!ct(t)};var ut={};ut.isntIterable=ut.isIterable=void 0;const ft=J,lt=D;function dt(t){return ft.isntNull(t)&&lt.isntUndefined(t)&&"function"==typeof t[Symbol.iterator]}ut.isIterable=dt,ut.isntIterable=function(t){return!dt(t)};var yt={},ht={};function vt(t){return null!==t&&"object"==typeof t}ht.isntEmptyObject=ht.isEmptyObject=ht.isRecord=ht.isntObject=ht.isObject=void 0,ht.isObject=vt,ht.isntObject=function(t){return!vt(t)},ht.isRecord=function(t){return vt(t)},ht.isEmptyObject=function(t){return 0===Object.keys(t).length},ht.isntEmptyObject=function(t){return 0!==Object.keys(t).length};var pt={};function mt(t){return"number"==typeof t}pt.isntNumber=pt.isNumber=void 0,pt.isNumber=mt,pt.isntNumber=function(t){return!mt(t)},yt.isntJsonRpcError=yt.isJsonRpcError=yt.isntJsonRpcSuccess=yt.isJsonRpcSuccess=yt.isntJsonRpcRequest=yt.isJsonRpcRequest=yt.isntJsonRpcNotification=yt.isJsonRpcNotification=void 0;const bt=C,gt=ht,wt=Q,At=pt,St=D;function It(t){return wt.isString(t)||At.isNumber(t)}function Tt(t){return bt.isArray(t)||gt.isObject(t)}function Ot(t){return gt.isRecord(t)&&wt.isString(t.jsonrpc)&&wt.isString(t.method)&&St.isUndefined(t.id)&&Tt(t.params)}function jt(t){return gt.isRecord(t)&&wt.isString(t.jsonrpc)&&wt.isString(t.method)&&It(t.id)&&Tt(t.params)}function kt(t){return gt.isRecord(t)&&wt.isString(t.jsonrpc)&&wt.isString(t.id)&&St.isntUndefined(t.result)}function xt(t){return gt.isRecord(t)&&wt.isString(t.jsonrpc)&&It(t.id)&&function(t){return gt.isRecord(t)&&At.isNumber(t.code)&&wt.isString(t.message)&&(St.isUndefined(t.data)||gt.isObject(t.data))}(t.error)}yt.isJsonRpcNotification=Ot,yt.isntJsonRpcNotification=function(t){return!Ot(t)},yt.isJsonRpcRequest=jt,yt.isntJsonRpcRequest=function(t){return!jt(t)},yt.isJsonRpcSuccess=kt,yt.isntJsonRpcSuccess=function(t){return!kt(t)},yt.isJsonRpcError=xt,yt.isntJsonRpcError=function(t){return!xt(t)};var Et={};Et.isntJson=Et.isJson=void 0,Et.isJson=function(t){try{return JSON.stringify(t),!0}catch(t){return!1}},Et.isntJson=function t(n){return!t()};var Rt={};Rt.isAbsoluteURL=void 0,Rt.isAbsoluteURL=function(t){try{return new URL(t),!0}catch(t){return!1}},function(t){var n=c&&c.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=c&&c.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(C,t),e(U,t),e(K,t),e(H,t),e(et,t),e(ot,t),e(it,t),e(at,t),e(ut,t),e(yt,t),e(Et,t),e(J,t),e(pt,t),e(ht,t),e(Q,t),e(D,t),e(Rt,t)}(_),B.chunkByAsync=void 0;const Nt=_;B.chunkByAsync=function(t,n){return Nt.isAsyncIterable(t)?async function*(t){let e=[],r=0;for await(const o of t)e.push(o),await n(o,r)&&(yield e,e=[]),r++;e.length&&(yield e)}(t):async function*(t){let e=[],r=0;for(const o of t)e.push(o),await n(o,r)&&(yield e,e=[]),r++;e.length&&(yield e)}(t)};var qt={};qt.chunkBy=void 0,qt.chunkBy=function*(t,n){let e=[],r=0;for(const o of t)e.push(o),n(o,r)&&(yield e,e=[]),r++;e.length&&(yield e)};var Bt={chunk:void 0};const _t=E,Ct=u;Bt.chunk=function(t,n){return Ct.assert(Number.isInteger(n),"The parameter size must be an integer"),Ct.assert(n>0,"The parameter size must be greater than 0"),_t.go((function*(){let e=[];for(const r of t)e.push(r),e.length>=n&&(yield e,e=[]);e.length&&(yield e)}))};var Pt={concatAsync:void 0};const Ut=_,Jt=E;Pt.concatAsync=function(t,...n){return Jt.go((async function*(){for(const e of[t,...n])if(Ut.isAsyncIterable(e))for await(const t of e)yield t;else for(const t of e)yield t}))};var zt={concat:void 0};const Dt=E;zt.concat=function(t,...n){return Dt.go((function*(){for(const e of[t,...n])yield*e}))};var Mt={},Ft={};Ft.copyIterable=Ft.copyAsyncIterable=void 0,Ft.copyAsyncIterable=async function*(t){for await(const n of t)yield n},Ft.copyIterable=function*(t){for(const n of t)yield n},Mt.dropAsync=void 0;const Wt=E,Lt=Ft,Kt=u;Mt.dropAsync=function(t,n){return Kt.assert(Number.isInteger(n),"The parameter count must be an integer"),Kt.assert(n>=0,"The parameter count must be greater than or equal to 0"),0===n?Lt.copyAsyncIterable(t):Wt.go((async function*(){const e=t[Symbol.asyncIterator]();let r;for(;!(r=await e.next(),r.done||n<=0);)n--;for(;!r.done;)yield r.value,r=await e.next()}))};var Vt={dropRightAsync:void 0};const Ht=E,Qt=Ft,Gt=u;Vt.dropRightAsync=function(t,n){return Gt.assert(Number.isInteger(n),"The parameter count must be an integer"),Gt.assert(n>=0,"The parameter count must be greater than or equal to 0"),0===n?Qt.copyAsyncIterable(t):Ht.go((async function*(){const e=(await async function(t){const n=[];for await(const e of t)n.push(e);return n}(t)).slice(0,-n);for(const t of e)yield t}))};var Xt={dropRight:void 0};const Yt=E,Zt=Ft,$t=u;Xt.dropRight=function(t,n){return $t.assert(Number.isInteger(n),"The parameter count must be an integer"),$t.assert(n>=0,"The parameter count must be greater than or equal to 0"),0===n?Zt.copyIterable(t):Yt.go((function*(){const e=Array.from(t);yield*e.slice(0,-n)}))};var tn={dropUntilAsync:void 0};const nn=_;tn.dropUntilAsync=function(t,n){return nn.isAsyncIterable(t)?async function*(t){const e=t[Symbol.asyncIterator]();let r,o=0;for(;!(r=await e.next(),r.done||await n(r.value,o++)););for(;!r.done;)yield r.value,r=await e.next()}(t):async function*(t){const e=t[Symbol.iterator]();let r,o=0;for(;!(r=e.next(),r.done||await n(r.value,o++)););for(;!r.done;)yield r.value,r=e.next()}(t)};var en={};en.dropUntil=void 0,en.dropUntil=function*(t,n){const e=t[Symbol.iterator]();let r,o=0;for(;!(r=e.next(),r.done||n(r.value,o++)););for(;!r.done;)yield r.value,r=e.next()};var rn={drop:void 0};const on=E,sn=Ft,an=u;rn.drop=function(t,n){return an.assert(Number.isInteger(n),"The parameter count must be an integer"),an.assert(n>=0,"The parameter count must be greater than or equal to 0"),0===n?sn.copyIterable(t):on.go((function*(){const e=t[Symbol.iterator]();let r;for(;!(r=e.next(),r.done||n<=0);)n--;for(;!r.done;)yield r.value,r=e.next()}))};var cn={filterAsync:void 0};const un=_;cn.filterAsync=function(t,n){return un.isAsyncIterable(t)?async function*(t){let e=0;for await(const r of t)await n(r,e)&&(yield r),e++}(t):async function*(t){let e=0;for(const r of t)await n(r,e)&&(yield r),e++}(t)};var fn={};fn.filter=void 0,fn.filter=function*(t,n){let e=0;for(const r of t)n(r,e)&&(yield r),e++};var ln={},dn={},yn={flattenByAsync:void 0};const hn=_;function vn(t){return hn.isIterable(t)&&hn.isntChar(t)}yn.flattenByAsync=function(t,n){return hn.isAsyncIterable(t)?async function*(t){const r=1;for await(const o of t)vn(o)&&await n(o,r)?yield*e(o,r+1):yield o}(t):function(t){return e(t,1)}(t);async function*e(t,r){for(const o of t)vn(o)&&await n(o,r)?yield*e(o,r+1):yield o}},dn.flattenDeepAsync=void 0;const pn=yn,mn=u;dn.flattenDeepAsync=function(t,n=1/0){return mn.assert(n===1/0||Number.isInteger(n),"The parameter depth must be an integer"),mn.assert(n>=0,"The parameter depth must be greater than or equal to 0"),pn.flattenByAsync(t,((t,e)=>e<=n))},ln.flattenAsync=void 0;const bn=dn;ln.flattenAsync=function(t){return bn.flattenDeepAsync(t,1)};var gn={flattenBy:void 0};const wn=_;gn.flattenBy=function(t,n){return function*t(e,r){for(const i of e)o=i,wn.isIterable(o)&&wn.isntChar(o)&&n(i,r)?yield*t(i,r+1):yield i;var o}(t,1)};var An={flattenDeep:void 0};const Sn=gn,In=u;An.flattenDeep=function(t,n=1/0){return In.assert(n===1/0||Number.isInteger(n),"The parameter depth must be an integer"),In.assert(n>=0,"The parameter depth must be greater than or equal to 0"),Sn.flattenBy(t,((t,e)=>e<=n))};var Tn={flatten:void 0};const On=An;Tn.flatten=function(t){return On.flattenDeep(t,1)};var jn={mapAsync:void 0};const kn=_;jn.mapAsync=function(t,n){return kn.isAsyncIterable(t)?async function*(t){let e=0;for await(const r of t)yield await n(r,e),e++}(t):async function*(t){let e=0;for(const r of t)yield await n(r,e),e++}(t)};var xn={};xn.map=void 0,xn.map=function*(t,n){let e=0;for(const r of t)yield n(r,e),e++};var En={repeatAsync:void 0};const Rn=E,Nn=u;En.repeatAsync=function(t,n){return Nn.assert(n===1/0||Number.isInteger(n),"The parameter times must be an integer"),Nn.assert(n>=0,"The parameter times must be greater than or equal to 0"),n===1/0&&function(){if("production"===process.env.NODE_ENV)return;console.warn("When iterable has no elements and times is Infinity, repeat() will be in dead loop")}(),Rn.go((async function*(){const e=[];if(n>0){for await(const n of t)yield n,e.push(n);n--}for(;n>0;)yield*e,n--}))};var qn={repeat:void 0};const Bn=E,_n=u;qn.repeat=function(t,n){return _n.assert(n===1/0||Number.isInteger(n),"The parameter times must be an integer"),_n.assert(n>=0,"The parameter times must be greater than or equal to 0"),n===1/0&&function(){if("production"===process.env.NODE_ENV)return;console.warn("When iterable has no elements and times is Infinity, repeat() will be in dead loop")}(),Bn.go((function*(){const e=[];if(n>0){for(const n of t)yield n,e.push(n);n--}for(;n>0;)yield*e,n--}))};var Cn={sliceAsync:void 0};const Pn=E,Un=u;Cn.sliceAsync=function(t,n,e=1/0){return Un.assert(Number.isInteger(n),"The parameter start must be an integer"),Un.assert(n>=0,"The parameter start must be greater than or equal to 0"),Un.assert(Number.isInteger(e),"The parameter end must be an integer"),Un.assert(e>=n,"The parameter end must be greater than or equal to start"),Pn.go((async function*(){let r=0;for await(const o of t){if(r>=e)break;r>=n&&(yield o),r++}}))};var Jn={slice:void 0};const zn=E,Dn=u;Jn.slice=function(t,n,e=1/0){return Dn.assert(Number.isInteger(n),"The parameter start must be an integer"),Dn.assert(n>=0,"The parameter start must be greater than or equal to 0"),Dn.assert(Number.isInteger(e),"The parameter end must be an integer"),Dn.assert(e>=n,"The parameter end must be greater than or equal to start"),zn.go((function*(){let r=0;for(const o of t){if(r>=e)break;r>=n&&(yield o),r++}}))};var Mn={};Mn.splitAsync=void 0,Mn.splitAsync=async function*(t,n){let e=[];for await(const r of t)r===n?(yield e,e=[]):e.push(r);yield e};var Fn={splitByAsync:void 0};const Wn=_;Fn.splitByAsync=function(t,n){return Wn.isAsyncIterable(t)?async function*(t){let e=[],r=0;for await(const o of t)await n(o,r)?(yield e,e=[]):e.push(o),r++;yield e}(t):async function*(t){let e=[],r=0;for(const o of t)await n(o,r)?(yield e,e=[]):e.push(o),r++;yield e}(t)};var Ln={};Ln.splitBy=void 0,Ln.splitBy=function*(t,n){let e=[],r=0;for(const o of t)n(o,r)?(yield e,e=[]):e.push(o),r++;yield e};var Kn={};Kn.split=void 0,Kn.split=function*(t,n){let e=[];for(const r of t)r===n?(yield e,e=[]):e.push(r);yield e};var Vn={takeAsync:void 0};const Hn=E,Qn=u;Vn.takeAsync=function(t,n){return Qn.assert(Number.isInteger(n),"The parameter count must be an integer"),Qn.assert(n>=0,"The parameter count must be greater than or equal to 0"),Hn.go((async function*(){if(0!==n)for await(const e of t)if(yield e,0===--n)break}))};var Gn={takeRightAsync:void 0};const Xn=E,Yn=u;Gn.takeRightAsync=function(t,n){return Yn.assert(Number.isInteger(n),"The parameter count must be an integer"),Yn.assert(n>=0,"The parameter count must be greater than or equal to 0"),Xn.go((async function*(){const e=t[Symbol.asyncIterator](),r=[];let o;for(;o=await e.next(),!o.done;)r.push(o.value),r.length>n&&r.shift();yield*r}))};var Zn={takeRight:void 0};const $n=E,te=u;Zn.takeRight=function(t,n){return te.assert(Number.isInteger(n),"The parameter count must be an integer"),te.assert(n>=0,"The parameter count must be greater than or equal to 0"),$n.go((function*(){const e=t[Symbol.iterator](),r=[];let o;for(;o=e.next(),!o.done;)r.push(o.value),r.length>n&&r.shift();yield*r}))};var ne={takeUntilAsync:void 0};const ee=_;ne.takeUntilAsync=function(t,n){return ee.isAsyncIterable(t)?async function*(t){let e=0;for await(const r of t){if(await n(r,e))break;yield r,e++}}(t):async function*(t){let e=0;for(const r of t){if(await n(r,e))break;yield r,e++}}(t)};var re={};re.takeUntil=void 0,re.takeUntil=function*(t,n){let e=0;for(const r of t){if(n(r,e))break;yield r,e++}};var oe={take:void 0};const ie=E,se=u;oe.take=function(t,n){return se.assert(Number.isInteger(n),"The parameter count must be an integer"),se.assert(n>=0,"The parameter count must be greater than or equal to 0"),ie.go((function*(){if(0!==n)for(const e of t)if(yield e,0===--n)break}))};var ae={tapAsync:void 0};const ce=_;ae.tapAsync=function(t,n){return ce.isAsyncIterable(t)?async function*(t){let e=0;for await(const r of t)await n(r,e),yield r,e++}(t):async function*(t){let e=0;for(const r of t)await n(r,e),yield r,e++}(t)};var ue={};ue.tap=void 0,ue.tap=function*(t,n){let e=0;for(const r of t)n(r,e),yield r,e++};var fe={};fe.toAsyncIterable=void 0,fe.toAsyncIterable=async function*(t){for(const n of t)yield n};var le={};le.transformAsync=void 0,le.transformAsync=async function*(t,n){yield*n(t)};var de={};de.transform=void 0,de.transform=function*(t,n){yield*n(t)};var ye={};ye.uniqAsync=void 0,ye.uniqAsync=async function*(t){const n=new Set;for await(const e of t)n.has(e)||(yield e,n.add(e))};var he={uniqByAsync:void 0};const ve=_;he.uniqByAsync=function(t,n){return ve.isAsyncIterable(t)?async function*(t){const e=new Set;let r=0;for await(const o of t){const t=await n(o,r);e.has(t)||(yield o,e.add(t)),r++}}(t):async function*(t){const e=new Set;let r=0;for(const o of t){const t=await n(o,r);e.has(t)||(yield o,e.add(t)),r++}}(t)};var pe={};pe.uniqBy=void 0,pe.uniqBy=function*(t,n){const e=new Set;let r=0;for(const o of t){const t=n(o,r);e.has(t)||(yield o,e.add(t)),r++}};var me={};me.uniq=void 0,me.uniq=function*(t){const n=new Set;for(const e of t)n.has(e)||(yield e,n.add(e))};var be={zipAsync:void 0};const ge=_;be.zipAsync=function(t,...n){return async function*(...t){const n=t.length,e=t.map((t=>ge.isAsyncIterable(t)?[Symbol.asyncIterator,t[Symbol.asyncIterator]()]:[Symbol.iterator,t[Symbol.iterator]()]));for(;;){const t=new Array(n);for(let r=0;r<n;r++){const[n,o]=e[r];let i;if(i=n===Symbol.asyncIterator?await o.next():o.next(),i.done)return;t[r]=i.value}yield t}}(t,...n)};var we={};we.zip=void 0,we.zip=function(t,...n){return function*(...t){const n=t.length,e=t.map((t=>t[Symbol.iterator]()));for(;;){const t=new Array(n);for(let r=0;r<n;r++){const{value:n,done:o}=e[r].next();if(o)return;t[r]=n}yield t}}(t,...n)},function(t){var n=c&&c.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=c&&c.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(x,t),e(B,t),e(qt,t),e(Bt,t),e(Pt,t),e(zt,t),e(Mt,t),e(Vt,t),e(Xt,t),e(tn,t),e(en,t),e(rn,t),e(cn,t),e(fn,t),e(ln,t),e(yn,t),e(gn,t),e(dn,t),e(An,t),e(Tn,t),e(jn,t),e(xn,t),e(En,t),e(qn,t),e(Cn,t),e(Jn,t),e(Mn,t),e(Fn,t),e(Ln,t),e(Kn,t),e(Vn,t),e(Gn,t),e(Zn,t),e(ne,t),e(re,t),e(oe,t),e(ae,t),e(ue,t),e(fe,t),e(le,t),e(de,t),e(ye,t),e(he,t),e(pe,t),e(me,t),e(be,t),e(we,t)}(k);var Ae={},Se={};Se.consume=void 0,Se.consume=function(t,n){return n(t)};var Ie={eachAsync:void 0};const Te=_;Ie.eachAsync=function(t,n){return Te.isAsyncIterable(t)?async function(t){let e=0;for await(const r of t)await n(r,e),e++}(t):async function(t){let e=0;for(const r of t)await n(r,e),e++}(t)};var Oe={};Oe.each=void 0,Oe.each=function(t,n){let e=0;for(const r of t)n(r,e),e++};var je={everyAsync:void 0};const ke=_;je.everyAsync=function(t,n){return ke.isAsyncIterable(t)?async function(t){let e=0;for await(const r of t){if(!await n(r,e))return!1;e++}return!0}(t):async function(t){let e=0;for(const r of t){if(!await n(r,e))return!1;e++}return!0}(t)};var xe={};xe.every=void 0,xe.every=function(t,n){let e=0;for(const r of t){if(!n(r,e))return!1;e++}return!0};var Ee={findAsync:void 0};const Re=_;Ee.findAsync=function(t,n){return Re.isAsyncIterable(t)?async function(t){let e=0;for await(const r of t){if(await n(r,e))return r;e++}return}(t):async function(t){let e=0;for(const r of t){if(await n(r,e))return r;e++}return}(t)};var Ne={};Ne.find=void 0,Ne.find=function(t,n){let e=0;for(const r of t){if(n(r,e))return r;e++}};var qe={};qe.firstAsync=void 0,qe.firstAsync=async function(t){for await(const n of t)return n};var Be={};Be.first=void 0,Be.first=function(t){for(const n of t)return n};var _e={};_e.includesAsync=void 0,_e.includesAsync=async function(t,n){for await(const e of t)if(e===n)return!0;return!1};var Ce={};Ce.includes=void 0,Ce.includes=function(t,n){for(const e of t)if(e===n)return!0;return!1};var Pe={};Pe.matchAsync=void 0,Pe.matchAsync=async function(t,n){const e=n.length;let r=0;for await(const o of t)if(o===n[r]&&r++,r===e)return!0;return!1};var Ue={};Ue.match=void 0,Ue.match=function(t,n){const e=n.length;let r=0;for(const o of t)if(o===n[r]&&r++,r===e)return!0;return!1};var Je={reduceAsync:void 0};const ze=_;Je.reduceAsync=function(t,n,e){return ze.isUndefined(e)?function(t,n){return ze.isAsyncIterable(t)?e(t):r(t);async function e(t){const[e,r]=await s(t);let o=e,i=1;for(;;){const t=await r.next();if(t.done)break;const e=t.value;o=await n(o,e,i++)}return o;async function s(t){const n=t[Symbol.asyncIterator](),e=await n.next();if(e.done)throw new Error("Reduce of empty iterable with no initial value");return[e.value,n]}}async function r(t){const[e,r]=s(t);let o=e,i=1;for(;;){const t=r.next();if(t.done)break;const e=t.value;o=await n(o,e,i++)}return o;function s(t){const n=t[Symbol.iterator](),e=n.next();if(e.done)throw new Error("Reduce of empty iterable with no initial value");return[e.value,n]}}}(t,n):function(t,n,e){return ze.isAsyncIterable(t)?o(t):r(t);async function r(t){let r=e,o=0;for(const e of t)r=await n(r,e,o++);return r}async function o(t){let r=e,o=0;for await(const e of t)r=await n(r,e,o++);return r}}(t,n,e)};var De={reduce:void 0};const Me=_;De.reduce=function(t,n,e){return Me.isUndefined(e)?function(t,n){const[e,r]=s(t);let o=e,i=1;for(;;){const t=r.next();if(t.done)break;o=n(o,t.value,i++)}return o;function s(t){const n=t[Symbol.iterator](),e=n.next();if(e.done)throw new Error("Reduce of empty iterable with no initial value");return[e.value,n]}}(t,n):function(t,n,e){let r=e,o=0;for(const e of t)r=n(r,e,o++);return r}(t,n,e)};var Fe={someAsync:void 0};const We=_;Fe.someAsync=function(t,n){return We.isAsyncIterable(t)?async function(t){let e=0;for await(const r of t){if(await n(r,e))return!0;e++}return!1}(t):async function(t){let e=0;for(const r of t){if(await n(r,e))return!0;e++}return!1}(t)};var Le={};Le.some=void 0,Le.some=function(t,n){let e=0;for(const r of t){if(n(r,e))return!0;e++}return!1};var Ke={};Ke.lastAsync=void 0,Ke.lastAsync=async function(t){const n=t[Symbol.asyncIterator]();let{value:e,done:r}=await n.next();if(r)return;let o=e;for(;({value:e,done:r}=await n.next()),!r;)o=e;return o};var Ve={};Ve.last=void 0,Ve.last=function(t){const n=t[Symbol.iterator]();let{value:e,done:r}=n.next();if(r)return;let o=e;for(;({value:e,done:r}=n.next()),!r;)o=e;return o};var He={toArrayAsync:void 0};const Qe=Se;He.toArrayAsync=function(t){return Qe.consume(t,(async t=>{const n=[];for await(const e of t)n.push(e);return n}))};var Ge={toArray:void 0};const Xe=Se;Ge.toArray=function(t){return Xe.consume(t,(t=>Array.from(t)))};var Ye={toSetAsync:void 0};const Ze=Se;Ye.toSetAsync=function(t){return Ze.consume(t,(async t=>{const n=new Set;for await(const e of t)n.add(e);return n}))};var $e={toSet:void 0};const tr=Se;var nr;$e.toSet=function(t){return tr.consume(t,(t=>new Set(t)))},function(t){var n=c&&c.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=c&&c.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(Se,t),e(Ie,t),e(Oe,t),e(je,t),e(xe,t),e(Ee,t),e(Ne,t),e(qe,t),e(Be,t),e(_e,t),e(Ce,t),e(Pe,t),e(Ue,t),e(Je,t),e(De,t),e(Fe,t),e(Le,t),e(Ke,t),e(Ve,t),e(He,t),e(Ge,t),e(Ye,t),e($e,t)}(Ae),function(t){var n=c&&c.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=c&&c.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(k,t),e(Ae,t)}(j);class er{constructor(t){this.value=t,this.children=new Map}}class rr{constructor(){nr.set(this,new er)}get[(nr=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}set(t,e){let r=n(this,nr,"f");for(const n of t)r.children.has(n)||r.children.set(n,new er),r=r.children.get(n);return r.value=e,this}has(t){let e=n(this,nr,"f");for(const n of t){if(!e.children.has(n))return!1;e=e.children.get(n)}return void 0!==e.value}get(t){let e=n(this,nr,"f");for(const n of t){if(!e.children.has(n))return;e=e.children.get(n)}return e.value}delete(t){const e=[];let r=n(this,nr,"f");for(const n of t){if(!r.children.has(n))return!1;e.push(r),r=r.children.get(n)}if(delete r.value,0===r.children.size)for(const[n,r]of j.toArray(j.zip(t,e)).reverse())if(r.children.delete(n),0!==r.children.size)break;return!0}}t.Emitter=i,t.HashSet=s,t.LRUMap=O,t.Queue=a,t.TrieMap=rr,t.convertArrayToCons=function t([n,...e]){return[n,e.length?t(e):null]},t.convertConsToArray=function t([n,e]){return null===e?[n]:[n,...t(e)]},Object.defineProperty(t,"__esModule",{value:!0})}));
function n(t,n,e,r){if("a"===e&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof n?t!==n||!r:!n.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===e?r:"a"===e?r.call(t):r?r.value:n.get(t)}var e,r,i,o;class s{constructor(){e.set(this,new Map)}get[(e=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}on(t,r){n(this,e,"f").has(t)||n(this,e,"f").set(t,new Set);n(this,e,"f").get(t).add(r)}off(t,r){if(!n(this,e,"f").has(t))return;const i=n(this,e,"f").get(t);i.delete(r),0===i.size&&n(this,e,"f").delete(t)}emit(t,r){if(!n(this,e,"f").has(t))return;n(this,e,"f").get(t).forEach((t=>t(r)))}}class a{constructor(t){this.hash=t,r.set(this,new Map)}get[(r=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}get size(){return n(this,r,"f").size}set(t,e){return n(this,r,"f").set(this.hash(t),e),this}has(t){return n(this,r,"f").has(this.hash(t))}get(t){return n(this,r,"f").get(this.hash(t))}delete(t){return n(this,r,"f").delete(this.hash(t))}clear(){n(this,r,"f").clear()}}class c{constructor(t){this.hash=t,i.set(this,new Map)}get[(i=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}get size(){return n(this,i,"f").size}[Symbol.iterator](){return n(this,i,"f").values()}add(t){return n(this,i,"f").set(this.hash(t),t),this}delete(t){return n(this,i,"f").delete(this.hash(t))}has(t){return n(this,i,"f").has(this.hash(t))}clear(){n(this,i,"f").clear()}values(){return n(this,i,"f").values()}}class u{constructor(){o.set(this,[])}get[(o=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}get size(){return n(this,o,"f").length}empty(){n(this,o,"f").length=0}enqueue(...t){n(this,o,"f").push(...t)}dequeue(){return n(this,o,"f").shift()}remove(t){let e;for(;(e=n(this,o,"f").indexOf(t))>=0;)n(this,o,"f").splice(e,1)}}var f="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},l={},d={CustomError:void 0};class y extends Error{get name(){return this.constructor.name}}d.CustomError=y;var v={ExpectedError:void 0};const h=d;class p extends h.CustomError{}v.ExpectedError=p;var m={AssertionError:void 0};const b=d;class g extends b.CustomError{}m.AssertionError=g;var w={};w.normalize=void 0,w.normalize=function(t){var n;return{name:t.name,message:t.message,stack:null!==(n=t.stack)&&void 0!==n?n:null}};var A={refute:void 0};const S=v;A.refute=function(t,n){if(t)throw new S.ExpectedError(n)};var I={assert:void 0};const T=m;var O,j;I.assert=function(t,n){if(!t)throw new T.AssertionError(n)},function(t){var n=f&&f.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=f&&f.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(d,t),e(v,t),e(m,t),e(w,t),e(A,t),e(I,t)}(l);class E{constructor(t){O.set(this,void 0),j.set(this,new Map),l.assert(Number.isInteger(t),"The parameter limit must be an integer"),l.assert(t>0,"The parameter limit must be a positive value"),function(t,n,e,r,i){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!i)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof n?t!==n||!i:!n.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");"a"===r?i.call(t,e):i?i.value=e:n.set(t,e)}(this,O,t,"f")}get[(O=new WeakMap,j=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}get size(){return n(this,j,"f").size}set(t,e){return n(this,j,"f").has(t)?this.updateItem(t,e):(n(this,j,"f").size===n(this,O,"f")&&n(this,j,"f").delete(this.getColdestKey()),n(this,j,"f").set(t,e)),this}has(t){return n(this,j,"f").has(t)}get(t){if(!this.has(t))return;const e=n(this,j,"f").get(t);return this.updateItem(t,e),e}delete(t){return n(this,j,"f").delete(t)}clear(){n(this,j,"f").clear()}updateItem(t,e){n(this,j,"f").delete(t),n(this,j,"f").set(t,e)}getColdestKey(){return n(this,j,"f").keys().next().value}}var R={},k={},x={},N={},B={};B.go=void 0,B.go=function(t){return t()},function(t){var n=f&&f.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]});(f&&f.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)})(B,t)}(N),x.chunkAsync=void 0;const q=N,_=l;x.chunkAsync=function(t,n){return _.assert(Number.isInteger(n),"The parameter size must be an integer"),_.assert(n>0,"The parameter size must be greater than 0"),q.go((async function*(){let e=[];for await(const r of t)e.push(r),e.length>=n&&(yield e,e=[]);e.length&&(yield e)}))};var C={},P={},U={};function z(t){return Array.isArray(t)}U.isntEmptyArray=U.isEmptyArray=U.isntArray=U.isArray=void 0,U.isArray=z,U.isntArray=function(t){return!z(t)},U.isEmptyArray=function(t){return 0===t.length},U.isntEmptyArray=function(t){return 0!==t.length};var J={},M={};function D(t){return null===t}M.isntNull=M.isNull=void 0,M.isNull=D,M.isntNull=function(t){return!D(t)};var W={};function F(t){return void 0===t}W.isntUndefined=W.isUndefined=void 0,W.isUndefined=F,W.isntUndefined=function(t){return!F(t)},J.isntAsyncIterable=J.isAsyncIterable=void 0;const L=M,H=W;function K(t){return L.isntNull(t)&&H.isntUndefined(t)&&"function"==typeof t[Symbol.asyncIterator]}J.isAsyncIterable=K,J.isntAsyncIterable=function(t){return!K(t)};var V={};function Q(t){return"bigint"==typeof t}V.isntBigInt=V.isBigInt=void 0,V.isBigInt=Q,V.isntBigInt=function(t){return!Q(t)};var G={};function X(t){return"boolean"==typeof t}G.isntBoolean=G.isBoolean=void 0,G.isBoolean=X,G.isntBoolean=function(t){return!X(t)};var Y={},Z={};function $(t){return tt(t)||nt(t)}function tt(t){return"string"==typeof t}function nt(t){return"object"==typeof t&&t instanceof String}Z.isntStringObject=Z.isStringObject=Z.isntStringPrimitive=Z.isStringPrimitive=Z.isntString=Z.isString=void 0,Z.isString=$,Z.isntString=function(t){return!$(t)},Z.isStringPrimitive=tt,Z.isntStringPrimitive=function(t){return!tt(t)},Z.isStringObject=nt,Z.isntStringObject=function(t){return!nt(t)},Y.isntCharObject=Y.isCharObject=Y.isntCharPrimitive=Y.isCharPrimitive=Y.isntChar=Y.isChar=void 0;const et=Z;function rt(t){return(et.isString(t)||et.isStringObject(t))&&1===t.length}function it(t){return et.isString(t)&&1===t.length}function ot(t){return et.isStringObject(t)&&1===t.length}Y.isChar=rt,Y.isntChar=function(t){return!rt(t)},Y.isCharPrimitive=it,Y.isntCharPrimitive=function(t){return!it(t)},Y.isCharObject=ot,Y.isntCharObject=function(t){return!ot(t)};var st={};function at(t){return t instanceof Date}st.isntDate=st.isDate=void 0,st.isDate=at,st.isntDate=function(t){return!at(t)};var ct={};ct.inEnum=void 0,ct.inEnum=function(t,n){return Object.values(n).includes(t)};var ut={};function ft(t){return!t}ut.isntFalsy=ut.isFalsy=void 0,ut.isFalsy=ft,ut.isntFalsy=function(t){return!ft(t)};var lt={};function dt(t){return"function"==typeof t}lt.isntFunction=lt.isFunction=void 0,lt.isFunction=dt,lt.isntFunction=function(t){return!dt(t)};var yt={};yt.isntIterable=yt.isIterable=void 0;const vt=M,ht=W;function pt(t){return vt.isntNull(t)&&ht.isntUndefined(t)&&"function"==typeof t[Symbol.iterator]}yt.isIterable=pt,yt.isntIterable=function(t){return!pt(t)};var mt={},bt={};function gt(t){return null!==t&&"object"==typeof t}bt.isntEmptyObject=bt.isEmptyObject=bt.isRecord=bt.isntObject=bt.isObject=void 0,bt.isObject=gt,bt.isntObject=function(t){return!gt(t)},bt.isRecord=function(t){return gt(t)},bt.isEmptyObject=function(t){return 0===Object.keys(t).length},bt.isntEmptyObject=function(t){return 0!==Object.keys(t).length};var wt={};function At(t){return"number"==typeof t}wt.isntNumber=wt.isNumber=void 0,wt.isNumber=At,wt.isntNumber=function(t){return!At(t)},mt.isntJsonRpcError=mt.isJsonRpcError=mt.isntJsonRpcSuccess=mt.isJsonRpcSuccess=mt.isntJsonRpcRequest=mt.isJsonRpcRequest=mt.isntJsonRpcNotification=mt.isJsonRpcNotification=void 0;const St=U,It=bt,Tt=Z,Ot=wt,jt=W;function Et(t){return Tt.isString(t)||Ot.isNumber(t)}function Rt(t){return St.isArray(t)||It.isObject(t)}function kt(t){return It.isRecord(t)&&Tt.isString(t.jsonrpc)&&Tt.isString(t.method)&&jt.isUndefined(t.id)&&Rt(t.params)}function xt(t){return It.isRecord(t)&&Tt.isString(t.jsonrpc)&&Tt.isString(t.method)&&Et(t.id)&&Rt(t.params)}function Nt(t){return It.isRecord(t)&&Tt.isString(t.jsonrpc)&&Tt.isString(t.id)&&jt.isntUndefined(t.result)}function Bt(t){return It.isRecord(t)&&Tt.isString(t.jsonrpc)&&Et(t.id)&&function(t){return It.isRecord(t)&&Ot.isNumber(t.code)&&Tt.isString(t.message)&&(jt.isUndefined(t.data)||It.isObject(t.data))}(t.error)}mt.isJsonRpcNotification=kt,mt.isntJsonRpcNotification=function(t){return!kt(t)},mt.isJsonRpcRequest=xt,mt.isntJsonRpcRequest=function(t){return!xt(t)},mt.isJsonRpcSuccess=Nt,mt.isntJsonRpcSuccess=function(t){return!Nt(t)},mt.isJsonRpcError=Bt,mt.isntJsonRpcError=function(t){return!Bt(t)};var qt={};qt.isntJson=qt.isJson=void 0,qt.isJson=function(t){try{return JSON.stringify(t),!0}catch(t){return!1}},qt.isntJson=function t(n){return!t()};var _t={};_t.isAbsoluteURL=void 0,_t.isAbsoluteURL=function(t){try{return new URL(t),!0}catch(t){return!1}},function(t){var n=f&&f.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=f&&f.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(U,t),e(J,t),e(V,t),e(G,t),e(Y,t),e(st,t),e(ct,t),e(ut,t),e(lt,t),e(yt,t),e(mt,t),e(qt,t),e(M,t),e(wt,t),e(bt,t),e(Z,t),e(W,t),e(_t,t)}(P),C.chunkByAsync=void 0;const Ct=P;C.chunkByAsync=function(t,n){return Ct.isAsyncIterable(t)?async function*(t){let e=[],r=0;for await(const i of t)e.push(i),await n(i,r)&&(yield e,e=[]),r++;e.length&&(yield e)}(t):async function*(t){let e=[],r=0;for(const i of t)e.push(i),await n(i,r)&&(yield e,e=[]),r++;e.length&&(yield e)}(t)};var Pt={};Pt.chunkBy=void 0,Pt.chunkBy=function*(t,n){let e=[],r=0;for(const i of t)e.push(i),n(i,r)&&(yield e,e=[]),r++;e.length&&(yield e)};var Ut={chunk:void 0};const zt=N,Jt=l;Ut.chunk=function(t,n){return Jt.assert(Number.isInteger(n),"The parameter size must be an integer"),Jt.assert(n>0,"The parameter size must be greater than 0"),zt.go((function*(){let e=[];for(const r of t)e.push(r),e.length>=n&&(yield e,e=[]);e.length&&(yield e)}))};var Mt={concatAsync:void 0};const Dt=P,Wt=N;Mt.concatAsync=function(t,...n){return Wt.go((async function*(){for(const e of[t,...n])if(Dt.isAsyncIterable(e))for await(const t of e)yield t;else for(const t of e)yield t}))};var Ft={concat:void 0};const Lt=N;Ft.concat=function(t,...n){return Lt.go((function*(){for(const e of[t,...n])yield*e}))};var Ht={},Kt={};Kt.copyIterable=Kt.copyAsyncIterable=void 0,Kt.copyAsyncIterable=async function*(t){for await(const n of t)yield n},Kt.copyIterable=function*(t){for(const n of t)yield n},Ht.dropAsync=void 0;const Vt=N,Qt=Kt,Gt=l;Ht.dropAsync=function(t,n){return Gt.assert(Number.isInteger(n),"The parameter count must be an integer"),Gt.assert(n>=0,"The parameter count must be greater than or equal to 0"),0===n?Qt.copyAsyncIterable(t):Vt.go((async function*(){var e;const r=t[Symbol.asyncIterator]();let i;try{let t;for(;!(({value:t,done:i}=await r.next()),i||n<=0);)n--;for(;!i;)yield t,({value:t,done:i}=await r.next())}finally{i||await(null===(e=r.return)||void 0===e?void 0:e.call(r))}}))};var Xt={dropRightAsync:void 0};const Yt=N,Zt=Kt,$t=l;Xt.dropRightAsync=function(t,n){return $t.assert(Number.isInteger(n),"The parameter count must be an integer"),$t.assert(n>=0,"The parameter count must be greater than or equal to 0"),0===n?Zt.copyAsyncIterable(t):Yt.go((async function*(){const e=(await async function(t){const n=[];for await(const e of t)n.push(e);return n}(t)).slice(0,-n);for(const t of e)yield t}))};var tn={dropRight:void 0};const nn=N,en=Kt,rn=l;tn.dropRight=function(t,n){return rn.assert(Number.isInteger(n),"The parameter count must be an integer"),rn.assert(n>=0,"The parameter count must be greater than or equal to 0"),0===n?en.copyIterable(t):nn.go((function*(){const e=Array.from(t);yield*e.slice(0,-n)}))};var on={dropUntilAsync:void 0};const sn=P;on.dropUntilAsync=function(t,n){return sn.isAsyncIterable(t)?async function*(t){var e;const r=t[Symbol.asyncIterator]();let i;try{let t,o=0;for(;!(({value:t,done:i}=await r.next()),i||await n(t,o++)););for(;!i;)yield t,({value:t,done:i}=await r.next())}finally{i||await(null===(e=r.return)||void 0===e?void 0:e.call(r))}}(t):async function*(t){var e;const r=t[Symbol.iterator]();let i;try{let t,o=0;for(;!(({value:t,done:i}=r.next()),i||await n(t,o++)););for(;!i;)yield t,({value:t,done:i}=r.next())}finally{i||null===(e=r.return)||void 0===e||e.call(r)}}(t)};var an={};an.dropUntil=void 0,an.dropUntil=function*(t,n){var e;const r=t[Symbol.iterator]();let i;try{let t,o=0;for(;!(({value:t,done:i}=r.next()),i||n(t,o++)););for(;!i;)yield t,({value:t,done:i}=r.next())}finally{i||null===(e=r.return)||void 0===e||e.call(r)}};var cn={drop:void 0};const un=N,fn=Kt,ln=l;cn.drop=function(t,n){return ln.assert(Number.isInteger(n),"The parameter count must be an integer"),ln.assert(n>=0,"The parameter count must be greater than or equal to 0"),0===n?fn.copyIterable(t):un.go((function*(){var e;const r=t[Symbol.iterator]();let i;try{let t;for(;!(({value:t,done:i}=r.next()),i||n<=0);)n--;for(;!i;)yield t,({value:t,done:i}=r.next())}finally{i||null===(e=r.return)||void 0===e||e.call(r)}}))};var dn={filterAsync:void 0};const yn=P;dn.filterAsync=function(t,n){return yn.isAsyncIterable(t)?async function*(t){let e=0;for await(const r of t)await n(r,e)&&(yield r),e++}(t):async function*(t){let e=0;for(const r of t)await n(r,e)&&(yield r),e++}(t)};var vn={};vn.filter=void 0,vn.filter=function*(t,n){let e=0;for(const r of t)n(r,e)&&(yield r),e++};var hn={},pn={},mn={flattenByAsync:void 0};const bn=P;function gn(t){return bn.isIterable(t)&&bn.isntChar(t)}mn.flattenByAsync=function(t,n){return bn.isAsyncIterable(t)?async function*(t){const r=1;for await(const i of t)gn(i)&&await n(i,r)?yield*e(i,r+1):yield i}(t):function(t){return e(t,1)}(t);async function*e(t,r){for(const i of t)gn(i)&&await n(i,r)?yield*e(i,r+1):yield i}},pn.flattenDeepAsync=void 0;const wn=mn,An=l;pn.flattenDeepAsync=function(t,n=1/0){return An.assert(n===1/0||Number.isInteger(n),"The parameter depth must be an integer"),An.assert(n>=0,"The parameter depth must be greater than or equal to 0"),wn.flattenByAsync(t,((t,e)=>e<=n))},hn.flattenAsync=void 0;const Sn=pn;hn.flattenAsync=function(t){return Sn.flattenDeepAsync(t,1)};var In={flattenBy:void 0};const Tn=P;In.flattenBy=function(t,n){return function*t(e,r){for(const o of e)i=o,Tn.isIterable(i)&&Tn.isntChar(i)&&n(o,r)?yield*t(o,r+1):yield o;var i}(t,1)};var On={flattenDeep:void 0};const jn=In,En=l;On.flattenDeep=function(t,n=1/0){return En.assert(n===1/0||Number.isInteger(n),"The parameter depth must be an integer"),En.assert(n>=0,"The parameter depth must be greater than or equal to 0"),jn.flattenBy(t,((t,e)=>e<=n))};var Rn={flatten:void 0};const kn=On;Rn.flatten=function(t){return kn.flattenDeep(t,1)};var xn={mapAsync:void 0};const Nn=P;xn.mapAsync=function(t,n){return Nn.isAsyncIterable(t)?async function*(t){let e=0;for await(const r of t)yield await n(r,e),e++}(t):async function*(t){let e=0;for(const r of t)yield await n(r,e),e++}(t)};var Bn={};Bn.map=void 0,Bn.map=function*(t,n){let e=0;for(const r of t)yield n(r,e),e++};var qn={repeatAsync:void 0};const _n=N,Cn=l;qn.repeatAsync=function(t,n){return Cn.assert(n===1/0||Number.isInteger(n),"The parameter times must be an integer"),Cn.assert(n>=0,"The parameter times must be greater than or equal to 0"),n===1/0&&function(){if("production"===process.env.NODE_ENV)return;console.warn("When iterable has no elements and times is Infinity, repeat() will be in dead loop")}(),_n.go((async function*(){const e=[];if(n>0){for await(const n of t)yield n,e.push(n);n--}for(;n>0;)yield*e,n--}))};var Pn={repeat:void 0};const Un=N,zn=l;Pn.repeat=function(t,n){return zn.assert(n===1/0||Number.isInteger(n),"The parameter times must be an integer"),zn.assert(n>=0,"The parameter times must be greater than or equal to 0"),n===1/0&&function(){if("production"===process.env.NODE_ENV)return;console.warn("When iterable has no elements and times is Infinity, repeat() will be in dead loop")}(),Un.go((function*(){const e=[];if(n>0){for(const n of t)yield n,e.push(n);n--}for(;n>0;)yield*e,n--}))};var Jn={sliceAsync:void 0};const Mn=N,Dn=l;Jn.sliceAsync=function(t,n,e=1/0){return Dn.assert(Number.isInteger(n),"The parameter start must be an integer"),Dn.assert(n>=0,"The parameter start must be greater than or equal to 0"),Dn.assert(Number.isInteger(e),"The parameter end must be an integer"),Dn.assert(e>=n,"The parameter end must be greater than or equal to start"),Mn.go((async function*(){let r=0;for await(const i of t){if(r>=e)break;r>=n&&(yield i),r++}}))};var Wn={slice:void 0};const Fn=N,Ln=l;Wn.slice=function(t,n,e=1/0){return Ln.assert(Number.isInteger(n),"The parameter start must be an integer"),Ln.assert(n>=0,"The parameter start must be greater than or equal to 0"),Ln.assert(Number.isInteger(e),"The parameter end must be an integer"),Ln.assert(e>=n,"The parameter end must be greater than or equal to start"),Fn.go((function*(){let r=0;for(const i of t){if(r>=e)break;r>=n&&(yield i),r++}}))};var Hn={};Hn.splitAsync=void 0,Hn.splitAsync=async function*(t,n){let e=[];for await(const r of t)r===n?(yield e,e=[]):e.push(r);yield e};var Kn={splitByAsync:void 0};const Vn=P;Kn.splitByAsync=function(t,n){return Vn.isAsyncIterable(t)?async function*(t){let e=[],r=0;for await(const i of t)await n(i,r)?(yield e,e=[]):e.push(i),r++;yield e}(t):async function*(t){let e=[],r=0;for(const i of t)await n(i,r)?(yield e,e=[]):e.push(i),r++;yield e}(t)};var Qn={};Qn.splitBy=void 0,Qn.splitBy=function*(t,n){let e=[],r=0;for(const i of t)n(i,r)?(yield e,e=[]):e.push(i),r++;yield e};var Gn={};Gn.split=void 0,Gn.split=function*(t,n){let e=[];for(const r of t)r===n?(yield e,e=[]):e.push(r);yield e};var Xn={takeAsync:void 0};const Yn=N,Zn=l;Xn.takeAsync=function(t,n){return Zn.assert(Number.isInteger(n),"The parameter count must be an integer"),Zn.assert(n>=0,"The parameter count must be greater than or equal to 0"),Yn.go((async function*(){if(0!==n)for await(const e of t)if(yield e,0===--n)break}))};var $n={takeRightAsync:void 0};const te=N,ne=l;$n.takeRightAsync=function(t,n){return ne.assert(Number.isInteger(n),"The parameter count must be an integer"),ne.assert(n>=0,"The parameter count must be greater than or equal to 0"),te.go((async function*(){var e;const r=t[Symbol.asyncIterator]();let i;try{const t=[];let o;for(;({value:o,done:i}=await r.next()),!i;)t.push(o),t.length>n&&t.shift();yield*t}finally{i||await(null===(e=r.return)||void 0===e?void 0:e.call(r))}}))};var ee={takeRight:void 0};const re=N,ie=l;ee.takeRight=function(t,n){return ie.assert(Number.isInteger(n),"The parameter count must be an integer"),ie.assert(n>=0,"The parameter count must be greater than or equal to 0"),re.go((function*(){var e;const r=t[Symbol.iterator]();let i;try{const t=[];let o;for(;({value:o,done:i}=r.next()),!i;)t.push(o),t.length>n&&t.shift();yield*t}finally{i||null===(e=r.return)||void 0===e||e.call(r)}}))};var oe={takeUntilAsync:void 0};const se=P;oe.takeUntilAsync=function(t,n){return se.isAsyncIterable(t)?async function*(t){let e=0;for await(const r of t){if(await n(r,e))break;yield r,e++}}(t):async function*(t){let e=0;for(const r of t){if(await n(r,e))break;yield r,e++}}(t)};var ae={};ae.takeUntil=void 0,ae.takeUntil=function*(t,n){let e=0;for(const r of t){if(n(r,e))break;yield r,e++}};var ce={take:void 0};const ue=N,fe=l;ce.take=function(t,n){return fe.assert(Number.isInteger(n),"The parameter count must be an integer"),fe.assert(n>=0,"The parameter count must be greater than or equal to 0"),ue.go((function*(){if(0!==n)for(const e of t)if(yield e,0===--n)break}))};var le={tapAsync:void 0};const de=P;le.tapAsync=function(t,n){return de.isAsyncIterable(t)?async function*(t){let e=0;for await(const r of t)await n(r,e),yield r,e++}(t):async function*(t){let e=0;for(const r of t)await n(r,e),yield r,e++}(t)};var ye={};ye.tap=void 0,ye.tap=function*(t,n){let e=0;for(const r of t)n(r,e),yield r,e++};var ve={};ve.toAsyncIterable=void 0,ve.toAsyncIterable=async function*(t){for(const n of t)yield n};var he={};he.transformAsync=void 0,he.transformAsync=async function*(t,n){yield*n(t)};var pe={};pe.transform=void 0,pe.transform=function*(t,n){yield*n(t)};var me={};me.uniqAsync=void 0,me.uniqAsync=async function*(t){const n=new Set;for await(const e of t)n.has(e)||(yield e,n.add(e))};var be={uniqByAsync:void 0};const ge=P;be.uniqByAsync=function(t,n){return ge.isAsyncIterable(t)?async function*(t){const e=new Set;let r=0;for await(const i of t){const t=await n(i,r);e.has(t)||(yield i,e.add(t)),r++}}(t):async function*(t){const e=new Set;let r=0;for(const i of t){const t=await n(i,r);e.has(t)||(yield i,e.add(t)),r++}}(t)};var we={};we.uniqBy=void 0,we.uniqBy=function*(t,n){const e=new Set;let r=0;for(const i of t){const t=n(i,r);e.has(t)||(yield i,e.add(t)),r++}};var Ae={};Ae.uniq=void 0,Ae.uniq=function*(t){const n=new Set;for(const e of t)n.has(e)||(yield e,n.add(e))};var Se={zipAsync:void 0};const Ie=P;var Te;!function(t){t[t.Sync=0]="Sync",t[t.Async=1]="Async"}(Te||(Te={})),Se.zipAsync=function(t,...n){return async function*(...t){var n,e,r,i;const o=t.length,s=t.map((t=>Ie.isAsyncIterable(t)?[Te.Async,t[Symbol.asyncIterator]()]:[Te.Sync,t[Symbol.iterator]()])),a=s.map((()=>!1));try{for(;;){const t=new Array(o);for(let n=0;n<o;n++){const[e,r]=s[n];let i;if(i=e===Te.Async?await r.next():r.next(),i.done)return void(a[n]=!0);t[n]=i.value}yield t}}finally{const t=s.filter(((t,n)=>!a[n]));for(const[o,s]of t)o===Te.Async?await(null===(e=(n=s).return)||void 0===e?void 0:e.call(n)):null===(i=(r=s).return)||void 0===i||i.call(r)}}(t,...n)};var Oe={};Oe.zip=void 0,Oe.zip=function(t,...n){return function*(...t){const n=t.length,e=t.map((t=>t[Symbol.iterator]())),r=e.map((()=>!1));try{for(;;){const t=new Array(n);for(let i=0;i<n;i++){const{value:n,done:o}=e[i].next();if(o)return void(r[i]=!0);t[i]=n}yield t}}finally{e.filter(((t,n)=>!r[n])).forEach((t=>{var n;return null===(n=t.return)||void 0===n?void 0:n.call(t)}))}}(t,...n)},function(t){var n=f&&f.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=f&&f.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(x,t),e(C,t),e(Pt,t),e(Ut,t),e(Mt,t),e(Ft,t),e(Ht,t),e(Xt,t),e(tn,t),e(on,t),e(an,t),e(cn,t),e(dn,t),e(vn,t),e(hn,t),e(mn,t),e(In,t),e(pn,t),e(On,t),e(Rn,t),e(xn,t),e(Bn,t),e(qn,t),e(Pn,t),e(Jn,t),e(Wn,t),e(Hn,t),e(Kn,t),e(Qn,t),e(Gn,t),e(Xn,t),e($n,t),e(ee,t),e(oe,t),e(ae,t),e(ce,t),e(le,t),e(ye,t),e(ve,t),e(he,t),e(pe,t),e(me,t),e(be,t),e(we,t),e(Ae,t),e(Se,t),e(Oe,t)}(k);var je={},Ee={};Ee.consume=void 0,Ee.consume=function(t,n){return n(t)};var Re={eachAsync:void 0};const ke=P;Re.eachAsync=function(t,n){return ke.isAsyncIterable(t)?async function(t){let e=0;for await(const r of t)await n(r,e),e++}(t):async function(t){let e=0;for(const r of t)await n(r,e),e++}(t)};var xe={};xe.each=void 0,xe.each=function(t,n){let e=0;for(const r of t)n(r,e),e++};var Ne={everyAsync:void 0};const Be=P;Ne.everyAsync=function(t,n){return Be.isAsyncIterable(t)?async function(t){let e=0;for await(const r of t){if(!await n(r,e))return!1;e++}return!0}(t):async function(t){let e=0;for(const r of t){if(!await n(r,e))return!1;e++}return!0}(t)};var qe={};qe.every=void 0,qe.every=function(t,n){let e=0;for(const r of t){if(!n(r,e))return!1;e++}return!0};var _e={findAsync:void 0};const Ce=P;_e.findAsync=function(t,n){return Ce.isAsyncIterable(t)?async function(t){let e=0;for await(const r of t){if(await n(r,e))return r;e++}return}(t):async function(t){let e=0;for(const r of t){if(await n(r,e))return r;e++}return}(t)};var Pe={};Pe.find=void 0,Pe.find=function(t,n){let e=0;for(const r of t){if(n(r,e))return r;e++}};var Ue={};Ue.firstAsync=void 0,Ue.firstAsync=async function(t){for await(const n of t)return n};var ze={};ze.first=void 0,ze.first=function(t){for(const n of t)return n};var Je={};Je.includesAsync=void 0,Je.includesAsync=async function(t,n){for await(const e of t)if(e===n)return!0;return!1};var Me={};Me.includes=void 0,Me.includes=function(t,n){for(const e of t)if(e===n)return!0;return!1};var De={};De.matchAsync=void 0,De.matchAsync=async function(t,n){const e=n.length;let r=0;for await(const i of t)if(i===n[r]&&r++,r===e)return!0;return!1};var We={};We.match=void 0,We.match=function(t,n){const e=n.length;let r=0;for(const i of t)if(i===n[r]&&r++,r===e)return!0;return!1};var Fe={reduceAsync:void 0};const Le=P;Fe.reduceAsync=function(t,n,e){return Le.isUndefined(e)?function(t,n){return Le.isAsyncIterable(t)?e(t):r(t);async function e(t){var e;const r=t[Symbol.asyncIterator]();let i;try{let t,s=await o(r),a=1;for(;({value:t,done:i}=await r.next()),!i;)s=await n(s,t,a++);return s}finally{i||await(null===(e=r.return)||void 0===e?void 0:e.call(r))}async function o(t){const n=await t.next();if(n.done)throw i=!0,new Error("Reduce of empty iterable with no initial value");return n.value}}async function r(t){var e;const r=t[Symbol.iterator]();let i;try{let t,s=o(r),a=1;for(;({value:t,done:i}=r.next()),!i;)s=await n(s,t,a++);return s}finally{i||null===(e=r.return)||void 0===e||e.call(r)}function o(t){const n=t.next();if(n.done)throw i=!0,new Error("Reduce of empty iterable with no initial value");return n.value}}}(t,n):function(t,n,e){return Le.isAsyncIterable(t)?i(t):r(t);async function r(t){let r=e,i=0;for(const e of t)r=await n(r,e,i++);return r}async function i(t){let r=e,i=0;for await(const e of t)r=await n(r,e,i++);return r}}(t,n,e)};var He={reduce:void 0};const Ke=P;He.reduce=function(t,n,e){return Ke.isUndefined(e)?function(t,n){var e;const r=t[Symbol.iterator]();let i;try{let t,s=o(r),a=1;for(;({value:t,done:i}=r.next()),!i;)s=n(s,t,a++);return s}finally{i||null===(e=r.return)||void 0===e||e.call(r)}function o(t){const n=t.next();if(n.done)throw i=!0,new Error("Reduce of empty iterable with no initial value");return n.value}}(t,n):function(t,n,e){let r=e,i=0;for(const e of t)r=n(r,e,i++);return r}(t,n,e)};var Ve={someAsync:void 0};const Qe=P;Ve.someAsync=function(t,n){return Qe.isAsyncIterable(t)?async function(t){let e=0;for await(const r of t){if(await n(r,e))return!0;e++}return!1}(t):async function(t){let e=0;for(const r of t){if(await n(r,e))return!0;e++}return!1}(t)};var Ge={};Ge.some=void 0,Ge.some=function(t,n){let e=0;for(const r of t){if(n(r,e))return!0;e++}return!1};var Xe={};Xe.lastAsync=void 0,Xe.lastAsync=async function(t){var n;const e=t[Symbol.asyncIterator]();let r;try{let t,i;for(;({value:t,done:r}=await e.next()),!r;)i=t;return i}finally{r||await(null===(n=e.return)||void 0===n?void 0:n.call(e))}};var Ye={};Ye.last=void 0,Ye.last=function(t){var n;const e=t[Symbol.iterator]();let r;try{let t,i;for(;({value:t,done:r}=e.next()),!r;)i=t;return i}finally{r||null===(n=e.return)||void 0===n||n.call(e)}};var Ze={toArrayAsync:void 0};const $e=Ee;Ze.toArrayAsync=function(t){return $e.consume(t,(async t=>{const n=[];for await(const e of t)n.push(e);return n}))};var tr={toArray:void 0};const nr=Ee;tr.toArray=function(t){return nr.consume(t,(t=>Array.from(t)))};var er={toSetAsync:void 0};const rr=Ee;er.toSetAsync=function(t){return rr.consume(t,(async t=>{const n=new Set;for await(const e of t)n.add(e);return n}))};var ir={toSet:void 0};const or=Ee;var sr;ir.toSet=function(t){return or.consume(t,(t=>new Set(t)))},function(t){var n=f&&f.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=f&&f.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(Ee,t),e(Re,t),e(xe,t),e(Ne,t),e(qe,t),e(_e,t),e(Pe,t),e(Ue,t),e(ze,t),e(Je,t),e(Me,t),e(De,t),e(We,t),e(Fe,t),e(He,t),e(Ve,t),e(Ge,t),e(Xe,t),e(Ye,t),e(Ze,t),e(tr,t),e(er,t),e(ir,t)}(je),function(t){var n=f&&f.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=f&&f.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(k,t),e(je,t)}(R);class ar{constructor(t){this.value=t,this.children=new Map}}class cr{constructor(){sr.set(this,new ar)}get[(sr=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}set(t,e){let r=n(this,sr,"f");for(const n of t)r.children.has(n)||r.children.set(n,new ar),r=r.children.get(n);return r.value=e,this}has(t){let e=n(this,sr,"f");for(const n of t){if(!e.children.has(n))return!1;e=e.children.get(n)}return void 0!==e.value}get(t){let e=n(this,sr,"f");for(const n of t){if(!e.children.has(n))return;e=e.children.get(n)}return e.value}delete(t){const e=[];let r=n(this,sr,"f");for(const n of t){if(!r.children.has(n))return!1;e.push(r),r=r.children.get(n)}if(delete r.value,0===r.children.size)for(const[n,r]of R.toArray(R.zip(t,e)).reverse())if(r.children.delete(n),0!==r.children.size)break;return!0}}t.Emitter=s,t.HashMap=a,t.HashSet=c,t.LRUMap=E,t.Queue=u,t.TrieMap=cr,t.convertArrayToCons=function t([n,...e]){return[n,e.length?t(e):null]},t.convertConsToArray=function t([n,e]){return null===e?[n]:[n,...t(e)]},Object.defineProperty(t,"__esModule",{value:!0})}));
//# sourceMappingURL=index.umd.min.js.map

@@ -16,3 +16,3 @@ !function(t,n){"object"==typeof exports&&"undefined"!=typeof module?n(exports):"function"==typeof define&&define.amd?define(["exports"],n):n((t="undefined"!=typeof globalThis?globalThis:t||self).Structures={})}(this,(function(t){"use strict";

***************************************************************************** */
function n(t,n,e,r){if("a"===e&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof n?t!==n||!r:!n.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===e?r:"a"===e?r.call(t):r?r.value:n.get(t)}var e,r,o;class i{constructor(){e.set(this,new Map)}get[(e=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}on(t,r){n(this,e,"f").has(t)||n(this,e,"f").set(t,new Set);n(this,e,"f").get(t).add(r)}off(t,r){if(!n(this,e,"f").has(t))return;const o=n(this,e,"f").get(t);o.delete(r),0===o.size&&n(this,e,"f").delete(t)}emit(t,r){if(!n(this,e,"f").has(t))return;n(this,e,"f").get(t).forEach((t=>t(r)))}}class s{constructor(t){this.hash=t,r.set(this,new Map)}get[(r=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}get size(){return n(this,r,"f").size}[Symbol.iterator](){return n(this,r,"f").values()}add(t){return n(this,r,"f").set(this.hash(t),t),this}delete(t){return n(this,r,"f").delete(this.hash(t))}has(t){return n(this,r,"f").has(this.hash(t))}clear(){n(this,r,"f").clear()}values(){return n(this,r,"f").values()}}class a{constructor(){o.set(this,[])}get[(o=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}get size(){return n(this,o,"f").length}empty(){n(this,o,"f").length=0}enqueue(...t){n(this,o,"f").push(...t)}dequeue(){return n(this,o,"f").shift()}remove(t){let e;for(;(e=n(this,o,"f").indexOf(t))>=0;)n(this,o,"f").splice(e,1)}}var c="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},u={},f={CustomError:void 0};class l extends Error{get name(){return this.constructor.name}}f.CustomError=l;var d={ExpectedError:void 0};const y=f;class h extends y.CustomError{}d.ExpectedError=h;var v={AssertionError:void 0};const p=f;class m extends p.CustomError{}v.AssertionError=m;var b={};b.normalize=void 0,b.normalize=function(t){var n;return{name:t.name,message:t.message,stack:null!==(n=t.stack)&&void 0!==n?n:null}};var g={refute:void 0};const w=d;g.refute=function(t,n){if(t)throw new w.ExpectedError(n)};var A={assert:void 0};const S=v;var I,T;A.assert=function(t,n){if(!t)throw new S.AssertionError(n)},function(t){var n=c&&c.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=c&&c.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(f,t),e(d,t),e(v,t),e(b,t),e(g,t),e(A,t)}(u);class O{constructor(t){I.set(this,void 0),T.set(this,new Map),u.assert(Number.isInteger(t),"The parameter limit must be an integer"),u.assert(t>0,"The parameter limit must be a positive value"),function(t,n,e,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof n?t!==n||!o:!n.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");"a"===r?o.call(t,e):o?o.value=e:n.set(t,e)}(this,I,t,"f")}get[(I=new WeakMap,T=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}get size(){return n(this,T,"f").size}set(t,e){return n(this,T,"f").has(t)?this.updateItem(t,e):(n(this,T,"f").size===n(this,I,"f")&&n(this,T,"f").delete(this.getColdestKey()),n(this,T,"f").set(t,e)),this}has(t){return n(this,T,"f").has(t)}get(t){if(!this.has(t))return;const e=n(this,T,"f").get(t);return this.updateItem(t,e),e}delete(t){return n(this,T,"f").delete(t)}clear(){n(this,T,"f").clear()}updateItem(t,e){n(this,T,"f").delete(t),n(this,T,"f").set(t,e)}getColdestKey(){return n(this,T,"f").keys().next().value}}var j={},k={},x={},E={},R={};R.go=void 0,R.go=function(t){return t()},function(t){var n=c&&c.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]});(c&&c.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)})(R,t)}(E),x.chunkAsync=void 0;const N=E,q=u;x.chunkAsync=function(t,n){return q.assert(Number.isInteger(n),"The parameter size must be an integer"),q.assert(n>0,"The parameter size must be greater than 0"),N.go((async function*(){let e=[];for await(const r of t)e.push(r),e.length>=n&&(yield e,e=[]);e.length&&(yield e)}))};var B={},_={},C={};function P(t){return Array.isArray(t)}C.isntEmptyArray=C.isEmptyArray=C.isntArray=C.isArray=void 0,C.isArray=P,C.isntArray=function(t){return!P(t)},C.isEmptyArray=function(t){return 0===t.length},C.isntEmptyArray=function(t){return 0!==t.length};var U={},J={};function z(t){return null===t}J.isntNull=J.isNull=void 0,J.isNull=z,J.isntNull=function(t){return!z(t)};var D={};function M(t){return void 0===t}D.isntUndefined=D.isUndefined=void 0,D.isUndefined=M,D.isntUndefined=function(t){return!M(t)},U.isntAsyncIterable=U.isAsyncIterable=void 0;const F=J,W=D;function L(t){return F.isntNull(t)&&W.isntUndefined(t)&&"function"==typeof t[Symbol.asyncIterator]}U.isAsyncIterable=L,U.isntAsyncIterable=function(t){return!L(t)};var K={};function V(t){return"boolean"==typeof t}K.isntBoolean=K.isBoolean=void 0,K.isBoolean=V,K.isntBoolean=function(t){return!V(t)};var H={},Q={};function G(t){return X(t)||Y(t)}function X(t){return"string"==typeof t}function Y(t){return"object"==typeof t&&t instanceof String}Q.isntStringObject=Q.isStringObject=Q.isntStringPrimitive=Q.isStringPrimitive=Q.isntString=Q.isString=void 0,Q.isString=G,Q.isntString=function(t){return!G(t)},Q.isStringPrimitive=X,Q.isntStringPrimitive=function(t){return!X(t)},Q.isStringObject=Y,Q.isntStringObject=function(t){return!Y(t)},H.isntCharObject=H.isCharObject=H.isntCharPrimitive=H.isCharPrimitive=H.isntChar=H.isChar=void 0;const Z=Q;function $(t){return(Z.isString(t)||Z.isStringObject(t))&&1===t.length}function tt(t){return Z.isString(t)&&1===t.length}function nt(t){return Z.isStringObject(t)&&1===t.length}H.isChar=$,H.isntChar=function(t){return!$(t)},H.isCharPrimitive=tt,H.isntCharPrimitive=function(t){return!tt(t)},H.isCharObject=nt,H.isntCharObject=function(t){return!nt(t)};var et={};function rt(t){return t instanceof Date}et.isntDate=et.isDate=void 0,et.isDate=rt,et.isntDate=function(t){return!rt(t)};var ot={};ot.inEnum=void 0,ot.inEnum=function(t,n){return Object.values(n).includes(t)};var it={};function st(t){return!t}it.isntFalsy=it.isFalsy=void 0,it.isFalsy=st,it.isntFalsy=function(t){return!st(t)};var at={};function ct(t){return"function"==typeof t}at.isntFunction=at.isFunction=void 0,at.isFunction=ct,at.isntFunction=function(t){return!ct(t)};var ut={};ut.isntIterable=ut.isIterable=void 0;const ft=J,lt=D;function dt(t){return ft.isntNull(t)&&lt.isntUndefined(t)&&"function"==typeof t[Symbol.iterator]}ut.isIterable=dt,ut.isntIterable=function(t){return!dt(t)};var yt={},ht={};function vt(t){return null!==t&&"object"==typeof t}ht.isntEmptyObject=ht.isEmptyObject=ht.isRecord=ht.isntObject=ht.isObject=void 0,ht.isObject=vt,ht.isntObject=function(t){return!vt(t)},ht.isRecord=function(t){return vt(t)},ht.isEmptyObject=function(t){return 0===Object.keys(t).length},ht.isntEmptyObject=function(t){return 0!==Object.keys(t).length};var pt={};function mt(t){return"number"==typeof t}pt.isntNumber=pt.isNumber=void 0,pt.isNumber=mt,pt.isntNumber=function(t){return!mt(t)},yt.isntJsonRpcError=yt.isJsonRpcError=yt.isntJsonRpcSuccess=yt.isJsonRpcSuccess=yt.isntJsonRpcRequest=yt.isJsonRpcRequest=yt.isntJsonRpcNotification=yt.isJsonRpcNotification=void 0;const bt=C,gt=ht,wt=Q,At=pt,St=D;function It(t){return wt.isString(t)||At.isNumber(t)}function Tt(t){return bt.isArray(t)||gt.isObject(t)}function Ot(t){return gt.isRecord(t)&&wt.isString(t.jsonrpc)&&wt.isString(t.method)&&St.isUndefined(t.id)&&Tt(t.params)}function jt(t){return gt.isRecord(t)&&wt.isString(t.jsonrpc)&&wt.isString(t.method)&&It(t.id)&&Tt(t.params)}function kt(t){return gt.isRecord(t)&&wt.isString(t.jsonrpc)&&wt.isString(t.id)&&St.isntUndefined(t.result)}function xt(t){return gt.isRecord(t)&&wt.isString(t.jsonrpc)&&It(t.id)&&function(t){return gt.isRecord(t)&&At.isNumber(t.code)&&wt.isString(t.message)&&(St.isUndefined(t.data)||gt.isObject(t.data))}(t.error)}yt.isJsonRpcNotification=Ot,yt.isntJsonRpcNotification=function(t){return!Ot(t)},yt.isJsonRpcRequest=jt,yt.isntJsonRpcRequest=function(t){return!jt(t)},yt.isJsonRpcSuccess=kt,yt.isntJsonRpcSuccess=function(t){return!kt(t)},yt.isJsonRpcError=xt,yt.isntJsonRpcError=function(t){return!xt(t)};var Et={};Et.isntJson=Et.isJson=void 0,Et.isJson=function(t){try{return JSON.stringify(t),!0}catch(t){return!1}},Et.isntJson=function t(n){return!t()};var Rt={};Rt.isAbsoluteURL=void 0,Rt.isAbsoluteURL=function(t){try{return new URL(t),!0}catch(t){return!1}},function(t){var n=c&&c.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=c&&c.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(C,t),e(U,t),e(K,t),e(H,t),e(et,t),e(ot,t),e(it,t),e(at,t),e(ut,t),e(yt,t),e(Et,t),e(J,t),e(pt,t),e(ht,t),e(Q,t),e(D,t),e(Rt,t)}(_),B.chunkByAsync=void 0;const Nt=_;B.chunkByAsync=function(t,n){return Nt.isAsyncIterable(t)?async function*(t){let e=[],r=0;for await(const o of t)e.push(o),await n(o,r)&&(yield e,e=[]),r++;e.length&&(yield e)}(t):async function*(t){let e=[],r=0;for(const o of t)e.push(o),await n(o,r)&&(yield e,e=[]),r++;e.length&&(yield e)}(t)};var qt={};qt.chunkBy=void 0,qt.chunkBy=function*(t,n){let e=[],r=0;for(const o of t)e.push(o),n(o,r)&&(yield e,e=[]),r++;e.length&&(yield e)};var Bt={chunk:void 0};const _t=E,Ct=u;Bt.chunk=function(t,n){return Ct.assert(Number.isInteger(n),"The parameter size must be an integer"),Ct.assert(n>0,"The parameter size must be greater than 0"),_t.go((function*(){let e=[];for(const r of t)e.push(r),e.length>=n&&(yield e,e=[]);e.length&&(yield e)}))};var Pt={concatAsync:void 0};const Ut=_,Jt=E;Pt.concatAsync=function(t,...n){return Jt.go((async function*(){for(const e of[t,...n])if(Ut.isAsyncIterable(e))for await(const t of e)yield t;else for(const t of e)yield t}))};var zt={concat:void 0};const Dt=E;zt.concat=function(t,...n){return Dt.go((function*(){for(const e of[t,...n])yield*e}))};var Mt={},Ft={};Ft.copyIterable=Ft.copyAsyncIterable=void 0,Ft.copyAsyncIterable=async function*(t){for await(const n of t)yield n},Ft.copyIterable=function*(t){for(const n of t)yield n},Mt.dropAsync=void 0;const Wt=E,Lt=Ft,Kt=u;Mt.dropAsync=function(t,n){return Kt.assert(Number.isInteger(n),"The parameter count must be an integer"),Kt.assert(n>=0,"The parameter count must be greater than or equal to 0"),0===n?Lt.copyAsyncIterable(t):Wt.go((async function*(){const e=t[Symbol.asyncIterator]();let r;for(;!(r=await e.next(),r.done||n<=0);)n--;for(;!r.done;)yield r.value,r=await e.next()}))};var Vt={dropRightAsync:void 0};const Ht=E,Qt=Ft,Gt=u;Vt.dropRightAsync=function(t,n){return Gt.assert(Number.isInteger(n),"The parameter count must be an integer"),Gt.assert(n>=0,"The parameter count must be greater than or equal to 0"),0===n?Qt.copyAsyncIterable(t):Ht.go((async function*(){const e=(await async function(t){const n=[];for await(const e of t)n.push(e);return n}(t)).slice(0,-n);for(const t of e)yield t}))};var Xt={dropRight:void 0};const Yt=E,Zt=Ft,$t=u;Xt.dropRight=function(t,n){return $t.assert(Number.isInteger(n),"The parameter count must be an integer"),$t.assert(n>=0,"The parameter count must be greater than or equal to 0"),0===n?Zt.copyIterable(t):Yt.go((function*(){const e=Array.from(t);yield*e.slice(0,-n)}))};var tn={dropUntilAsync:void 0};const nn=_;tn.dropUntilAsync=function(t,n){return nn.isAsyncIterable(t)?async function*(t){const e=t[Symbol.asyncIterator]();let r,o=0;for(;!(r=await e.next(),r.done||await n(r.value,o++)););for(;!r.done;)yield r.value,r=await e.next()}(t):async function*(t){const e=t[Symbol.iterator]();let r,o=0;for(;!(r=e.next(),r.done||await n(r.value,o++)););for(;!r.done;)yield r.value,r=e.next()}(t)};var en={};en.dropUntil=void 0,en.dropUntil=function*(t,n){const e=t[Symbol.iterator]();let r,o=0;for(;!(r=e.next(),r.done||n(r.value,o++)););for(;!r.done;)yield r.value,r=e.next()};var rn={drop:void 0};const on=E,sn=Ft,an=u;rn.drop=function(t,n){return an.assert(Number.isInteger(n),"The parameter count must be an integer"),an.assert(n>=0,"The parameter count must be greater than or equal to 0"),0===n?sn.copyIterable(t):on.go((function*(){const e=t[Symbol.iterator]();let r;for(;!(r=e.next(),r.done||n<=0);)n--;for(;!r.done;)yield r.value,r=e.next()}))};var cn={filterAsync:void 0};const un=_;cn.filterAsync=function(t,n){return un.isAsyncIterable(t)?async function*(t){let e=0;for await(const r of t)await n(r,e)&&(yield r),e++}(t):async function*(t){let e=0;for(const r of t)await n(r,e)&&(yield r),e++}(t)};var fn={};fn.filter=void 0,fn.filter=function*(t,n){let e=0;for(const r of t)n(r,e)&&(yield r),e++};var ln={},dn={},yn={flattenByAsync:void 0};const hn=_;function vn(t){return hn.isIterable(t)&&hn.isntChar(t)}yn.flattenByAsync=function(t,n){return hn.isAsyncIterable(t)?async function*(t){const r=1;for await(const o of t)vn(o)&&await n(o,r)?yield*e(o,r+1):yield o}(t):function(t){return e(t,1)}(t);async function*e(t,r){for(const o of t)vn(o)&&await n(o,r)?yield*e(o,r+1):yield o}},dn.flattenDeepAsync=void 0;const pn=yn,mn=u;dn.flattenDeepAsync=function(t,n=1/0){return mn.assert(n===1/0||Number.isInteger(n),"The parameter depth must be an integer"),mn.assert(n>=0,"The parameter depth must be greater than or equal to 0"),pn.flattenByAsync(t,((t,e)=>e<=n))},ln.flattenAsync=void 0;const bn=dn;ln.flattenAsync=function(t){return bn.flattenDeepAsync(t,1)};var gn={flattenBy:void 0};const wn=_;gn.flattenBy=function(t,n){return function*t(e,r){for(const i of e)o=i,wn.isIterable(o)&&wn.isntChar(o)&&n(i,r)?yield*t(i,r+1):yield i;var o}(t,1)};var An={flattenDeep:void 0};const Sn=gn,In=u;An.flattenDeep=function(t,n=1/0){return In.assert(n===1/0||Number.isInteger(n),"The parameter depth must be an integer"),In.assert(n>=0,"The parameter depth must be greater than or equal to 0"),Sn.flattenBy(t,((t,e)=>e<=n))};var Tn={flatten:void 0};const On=An;Tn.flatten=function(t){return On.flattenDeep(t,1)};var jn={mapAsync:void 0};const kn=_;jn.mapAsync=function(t,n){return kn.isAsyncIterable(t)?async function*(t){let e=0;for await(const r of t)yield await n(r,e),e++}(t):async function*(t){let e=0;for(const r of t)yield await n(r,e),e++}(t)};var xn={};xn.map=void 0,xn.map=function*(t,n){let e=0;for(const r of t)yield n(r,e),e++};var En={repeatAsync:void 0};const Rn=E,Nn=u;En.repeatAsync=function(t,n){return Nn.assert(n===1/0||Number.isInteger(n),"The parameter times must be an integer"),Nn.assert(n>=0,"The parameter times must be greater than or equal to 0"),n===1/0&&function(){if("production"===process.env.NODE_ENV)return;console.warn("When iterable has no elements and times is Infinity, repeat() will be in dead loop")}(),Rn.go((async function*(){const e=[];if(n>0){for await(const n of t)yield n,e.push(n);n--}for(;n>0;)yield*e,n--}))};var qn={repeat:void 0};const Bn=E,_n=u;qn.repeat=function(t,n){return _n.assert(n===1/0||Number.isInteger(n),"The parameter times must be an integer"),_n.assert(n>=0,"The parameter times must be greater than or equal to 0"),n===1/0&&function(){if("production"===process.env.NODE_ENV)return;console.warn("When iterable has no elements and times is Infinity, repeat() will be in dead loop")}(),Bn.go((function*(){const e=[];if(n>0){for(const n of t)yield n,e.push(n);n--}for(;n>0;)yield*e,n--}))};var Cn={sliceAsync:void 0};const Pn=E,Un=u;Cn.sliceAsync=function(t,n,e=1/0){return Un.assert(Number.isInteger(n),"The parameter start must be an integer"),Un.assert(n>=0,"The parameter start must be greater than or equal to 0"),Un.assert(Number.isInteger(e),"The parameter end must be an integer"),Un.assert(e>=n,"The parameter end must be greater than or equal to start"),Pn.go((async function*(){let r=0;for await(const o of t){if(r>=e)break;r>=n&&(yield o),r++}}))};var Jn={slice:void 0};const zn=E,Dn=u;Jn.slice=function(t,n,e=1/0){return Dn.assert(Number.isInteger(n),"The parameter start must be an integer"),Dn.assert(n>=0,"The parameter start must be greater than or equal to 0"),Dn.assert(Number.isInteger(e),"The parameter end must be an integer"),Dn.assert(e>=n,"The parameter end must be greater than or equal to start"),zn.go((function*(){let r=0;for(const o of t){if(r>=e)break;r>=n&&(yield o),r++}}))};var Mn={};Mn.splitAsync=void 0,Mn.splitAsync=async function*(t,n){let e=[];for await(const r of t)r===n?(yield e,e=[]):e.push(r);yield e};var Fn={splitByAsync:void 0};const Wn=_;Fn.splitByAsync=function(t,n){return Wn.isAsyncIterable(t)?async function*(t){let e=[],r=0;for await(const o of t)await n(o,r)?(yield e,e=[]):e.push(o),r++;yield e}(t):async function*(t){let e=[],r=0;for(const o of t)await n(o,r)?(yield e,e=[]):e.push(o),r++;yield e}(t)};var Ln={};Ln.splitBy=void 0,Ln.splitBy=function*(t,n){let e=[],r=0;for(const o of t)n(o,r)?(yield e,e=[]):e.push(o),r++;yield e};var Kn={};Kn.split=void 0,Kn.split=function*(t,n){let e=[];for(const r of t)r===n?(yield e,e=[]):e.push(r);yield e};var Vn={takeAsync:void 0};const Hn=E,Qn=u;Vn.takeAsync=function(t,n){return Qn.assert(Number.isInteger(n),"The parameter count must be an integer"),Qn.assert(n>=0,"The parameter count must be greater than or equal to 0"),Hn.go((async function*(){if(0!==n)for await(const e of t)if(yield e,0===--n)break}))};var Gn={takeRightAsync:void 0};const Xn=E,Yn=u;Gn.takeRightAsync=function(t,n){return Yn.assert(Number.isInteger(n),"The parameter count must be an integer"),Yn.assert(n>=0,"The parameter count must be greater than or equal to 0"),Xn.go((async function*(){const e=t[Symbol.asyncIterator](),r=[];let o;for(;o=await e.next(),!o.done;)r.push(o.value),r.length>n&&r.shift();yield*r}))};var Zn={takeRight:void 0};const $n=E,te=u;Zn.takeRight=function(t,n){return te.assert(Number.isInteger(n),"The parameter count must be an integer"),te.assert(n>=0,"The parameter count must be greater than or equal to 0"),$n.go((function*(){const e=t[Symbol.iterator](),r=[];let o;for(;o=e.next(),!o.done;)r.push(o.value),r.length>n&&r.shift();yield*r}))};var ne={takeUntilAsync:void 0};const ee=_;ne.takeUntilAsync=function(t,n){return ee.isAsyncIterable(t)?async function*(t){let e=0;for await(const r of t){if(await n(r,e))break;yield r,e++}}(t):async function*(t){let e=0;for(const r of t){if(await n(r,e))break;yield r,e++}}(t)};var re={};re.takeUntil=void 0,re.takeUntil=function*(t,n){let e=0;for(const r of t){if(n(r,e))break;yield r,e++}};var oe={take:void 0};const ie=E,se=u;oe.take=function(t,n){return se.assert(Number.isInteger(n),"The parameter count must be an integer"),se.assert(n>=0,"The parameter count must be greater than or equal to 0"),ie.go((function*(){if(0!==n)for(const e of t)if(yield e,0===--n)break}))};var ae={tapAsync:void 0};const ce=_;ae.tapAsync=function(t,n){return ce.isAsyncIterable(t)?async function*(t){let e=0;for await(const r of t)await n(r,e),yield r,e++}(t):async function*(t){let e=0;for(const r of t)await n(r,e),yield r,e++}(t)};var ue={};ue.tap=void 0,ue.tap=function*(t,n){let e=0;for(const r of t)n(r,e),yield r,e++};var fe={};fe.toAsyncIterable=void 0,fe.toAsyncIterable=async function*(t){for(const n of t)yield n};var le={};le.transformAsync=void 0,le.transformAsync=async function*(t,n){yield*n(t)};var de={};de.transform=void 0,de.transform=function*(t,n){yield*n(t)};var ye={};ye.uniqAsync=void 0,ye.uniqAsync=async function*(t){const n=new Set;for await(const e of t)n.has(e)||(yield e,n.add(e))};var he={uniqByAsync:void 0};const ve=_;he.uniqByAsync=function(t,n){return ve.isAsyncIterable(t)?async function*(t){const e=new Set;let r=0;for await(const o of t){const t=await n(o,r);e.has(t)||(yield o,e.add(t)),r++}}(t):async function*(t){const e=new Set;let r=0;for(const o of t){const t=await n(o,r);e.has(t)||(yield o,e.add(t)),r++}}(t)};var pe={};pe.uniqBy=void 0,pe.uniqBy=function*(t,n){const e=new Set;let r=0;for(const o of t){const t=n(o,r);e.has(t)||(yield o,e.add(t)),r++}};var me={};me.uniq=void 0,me.uniq=function*(t){const n=new Set;for(const e of t)n.has(e)||(yield e,n.add(e))};var be={zipAsync:void 0};const ge=_;be.zipAsync=function(t,...n){return async function*(...t){const n=t.length,e=t.map((t=>ge.isAsyncIterable(t)?[Symbol.asyncIterator,t[Symbol.asyncIterator]()]:[Symbol.iterator,t[Symbol.iterator]()]));for(;;){const t=new Array(n);for(let r=0;r<n;r++){const[n,o]=e[r];let i;if(i=n===Symbol.asyncIterator?await o.next():o.next(),i.done)return;t[r]=i.value}yield t}}(t,...n)};var we={};we.zip=void 0,we.zip=function(t,...n){return function*(...t){const n=t.length,e=t.map((t=>t[Symbol.iterator]()));for(;;){const t=new Array(n);for(let r=0;r<n;r++){const{value:n,done:o}=e[r].next();if(o)return;t[r]=n}yield t}}(t,...n)},function(t){var n=c&&c.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=c&&c.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(x,t),e(B,t),e(qt,t),e(Bt,t),e(Pt,t),e(zt,t),e(Mt,t),e(Vt,t),e(Xt,t),e(tn,t),e(en,t),e(rn,t),e(cn,t),e(fn,t),e(ln,t),e(yn,t),e(gn,t),e(dn,t),e(An,t),e(Tn,t),e(jn,t),e(xn,t),e(En,t),e(qn,t),e(Cn,t),e(Jn,t),e(Mn,t),e(Fn,t),e(Ln,t),e(Kn,t),e(Vn,t),e(Gn,t),e(Zn,t),e(ne,t),e(re,t),e(oe,t),e(ae,t),e(ue,t),e(fe,t),e(le,t),e(de,t),e(ye,t),e(he,t),e(pe,t),e(me,t),e(be,t),e(we,t)}(k);var Ae={},Se={};Se.consume=void 0,Se.consume=function(t,n){return n(t)};var Ie={eachAsync:void 0};const Te=_;Ie.eachAsync=function(t,n){return Te.isAsyncIterable(t)?async function(t){let e=0;for await(const r of t)await n(r,e),e++}(t):async function(t){let e=0;for(const r of t)await n(r,e),e++}(t)};var Oe={};Oe.each=void 0,Oe.each=function(t,n){let e=0;for(const r of t)n(r,e),e++};var je={everyAsync:void 0};const ke=_;je.everyAsync=function(t,n){return ke.isAsyncIterable(t)?async function(t){let e=0;for await(const r of t){if(!await n(r,e))return!1;e++}return!0}(t):async function(t){let e=0;for(const r of t){if(!await n(r,e))return!1;e++}return!0}(t)};var xe={};xe.every=void 0,xe.every=function(t,n){let e=0;for(const r of t){if(!n(r,e))return!1;e++}return!0};var Ee={findAsync:void 0};const Re=_;Ee.findAsync=function(t,n){return Re.isAsyncIterable(t)?async function(t){let e=0;for await(const r of t){if(await n(r,e))return r;e++}return}(t):async function(t){let e=0;for(const r of t){if(await n(r,e))return r;e++}return}(t)};var Ne={};Ne.find=void 0,Ne.find=function(t,n){let e=0;for(const r of t){if(n(r,e))return r;e++}};var qe={};qe.firstAsync=void 0,qe.firstAsync=async function(t){for await(const n of t)return n};var Be={};Be.first=void 0,Be.first=function(t){for(const n of t)return n};var _e={};_e.includesAsync=void 0,_e.includesAsync=async function(t,n){for await(const e of t)if(e===n)return!0;return!1};var Ce={};Ce.includes=void 0,Ce.includes=function(t,n){for(const e of t)if(e===n)return!0;return!1};var Pe={};Pe.matchAsync=void 0,Pe.matchAsync=async function(t,n){const e=n.length;let r=0;for await(const o of t)if(o===n[r]&&r++,r===e)return!0;return!1};var Ue={};Ue.match=void 0,Ue.match=function(t,n){const e=n.length;let r=0;for(const o of t)if(o===n[r]&&r++,r===e)return!0;return!1};var Je={reduceAsync:void 0};const ze=_;Je.reduceAsync=function(t,n,e){return ze.isUndefined(e)?function(t,n){return ze.isAsyncIterable(t)?e(t):r(t);async function e(t){const[e,r]=await s(t);let o=e,i=1;for(;;){const t=await r.next();if(t.done)break;const e=t.value;o=await n(o,e,i++)}return o;async function s(t){const n=t[Symbol.asyncIterator](),e=await n.next();if(e.done)throw new Error("Reduce of empty iterable with no initial value");return[e.value,n]}}async function r(t){const[e,r]=s(t);let o=e,i=1;for(;;){const t=r.next();if(t.done)break;const e=t.value;o=await n(o,e,i++)}return o;function s(t){const n=t[Symbol.iterator](),e=n.next();if(e.done)throw new Error("Reduce of empty iterable with no initial value");return[e.value,n]}}}(t,n):function(t,n,e){return ze.isAsyncIterable(t)?o(t):r(t);async function r(t){let r=e,o=0;for(const e of t)r=await n(r,e,o++);return r}async function o(t){let r=e,o=0;for await(const e of t)r=await n(r,e,o++);return r}}(t,n,e)};var De={reduce:void 0};const Me=_;De.reduce=function(t,n,e){return Me.isUndefined(e)?function(t,n){const[e,r]=s(t);let o=e,i=1;for(;;){const t=r.next();if(t.done)break;o=n(o,t.value,i++)}return o;function s(t){const n=t[Symbol.iterator](),e=n.next();if(e.done)throw new Error("Reduce of empty iterable with no initial value");return[e.value,n]}}(t,n):function(t,n,e){let r=e,o=0;for(const e of t)r=n(r,e,o++);return r}(t,n,e)};var Fe={someAsync:void 0};const We=_;Fe.someAsync=function(t,n){return We.isAsyncIterable(t)?async function(t){let e=0;for await(const r of t){if(await n(r,e))return!0;e++}return!1}(t):async function(t){let e=0;for(const r of t){if(await n(r,e))return!0;e++}return!1}(t)};var Le={};Le.some=void 0,Le.some=function(t,n){let e=0;for(const r of t){if(n(r,e))return!0;e++}return!1};var Ke={};Ke.lastAsync=void 0,Ke.lastAsync=async function(t){const n=t[Symbol.asyncIterator]();let{value:e,done:r}=await n.next();if(r)return;let o=e;for(;({value:e,done:r}=await n.next()),!r;)o=e;return o};var Ve={};Ve.last=void 0,Ve.last=function(t){const n=t[Symbol.iterator]();let{value:e,done:r}=n.next();if(r)return;let o=e;for(;({value:e,done:r}=n.next()),!r;)o=e;return o};var He={toArrayAsync:void 0};const Qe=Se;He.toArrayAsync=function(t){return Qe.consume(t,(async t=>{const n=[];for await(const e of t)n.push(e);return n}))};var Ge={toArray:void 0};const Xe=Se;Ge.toArray=function(t){return Xe.consume(t,(t=>Array.from(t)))};var Ye={toSetAsync:void 0};const Ze=Se;Ye.toSetAsync=function(t){return Ze.consume(t,(async t=>{const n=new Set;for await(const e of t)n.add(e);return n}))};var $e={toSet:void 0};const tr=Se;var nr;$e.toSet=function(t){return tr.consume(t,(t=>new Set(t)))},function(t){var n=c&&c.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=c&&c.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(Se,t),e(Ie,t),e(Oe,t),e(je,t),e(xe,t),e(Ee,t),e(Ne,t),e(qe,t),e(Be,t),e(_e,t),e(Ce,t),e(Pe,t),e(Ue,t),e(Je,t),e(De,t),e(Fe,t),e(Le,t),e(Ke,t),e(Ve,t),e(He,t),e(Ge,t),e(Ye,t),e($e,t)}(Ae),function(t){var n=c&&c.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=c&&c.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(k,t),e(Ae,t)}(j);class er{constructor(t){this.value=t,this.children=new Map}}class rr{constructor(){nr.set(this,new er)}get[(nr=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}set(t,e){let r=n(this,nr,"f");for(const n of t)r.children.has(n)||r.children.set(n,new er),r=r.children.get(n);return r.value=e,this}has(t){let e=n(this,nr,"f");for(const n of t){if(!e.children.has(n))return!1;e=e.children.get(n)}return void 0!==e.value}get(t){let e=n(this,nr,"f");for(const n of t){if(!e.children.has(n))return;e=e.children.get(n)}return e.value}delete(t){const e=[];let r=n(this,nr,"f");for(const n of t){if(!r.children.has(n))return!1;e.push(r),r=r.children.get(n)}if(delete r.value,0===r.children.size)for(const[n,r]of j.toArray(j.zip(t,e)).reverse())if(r.children.delete(n),0!==r.children.size)break;return!0}}t.Emitter=i,t.HashSet=s,t.LRUMap=O,t.Queue=a,t.TrieMap=rr,t.convertArrayToCons=function t([n,...e]){return[n,e.length?t(e):null]},t.convertConsToArray=function t([n,e]){return null===e?[n]:[n,...t(e)]},Object.defineProperty(t,"__esModule",{value:!0})}));
function n(t,n,e,r){if("a"===e&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof n?t!==n||!r:!n.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===e?r:"a"===e?r.call(t):r?r.value:n.get(t)}var e,r,i,o;class s{constructor(){e.set(this,new Map)}get[(e=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}on(t,r){n(this,e,"f").has(t)||n(this,e,"f").set(t,new Set);n(this,e,"f").get(t).add(r)}off(t,r){if(!n(this,e,"f").has(t))return;const i=n(this,e,"f").get(t);i.delete(r),0===i.size&&n(this,e,"f").delete(t)}emit(t,r){if(!n(this,e,"f").has(t))return;n(this,e,"f").get(t).forEach((t=>t(r)))}}class a{constructor(t){this.hash=t,r.set(this,new Map)}get[(r=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}get size(){return n(this,r,"f").size}set(t,e){return n(this,r,"f").set(this.hash(t),e),this}has(t){return n(this,r,"f").has(this.hash(t))}get(t){return n(this,r,"f").get(this.hash(t))}delete(t){return n(this,r,"f").delete(this.hash(t))}clear(){n(this,r,"f").clear()}}class c{constructor(t){this.hash=t,i.set(this,new Map)}get[(i=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}get size(){return n(this,i,"f").size}[Symbol.iterator](){return n(this,i,"f").values()}add(t){return n(this,i,"f").set(this.hash(t),t),this}delete(t){return n(this,i,"f").delete(this.hash(t))}has(t){return n(this,i,"f").has(this.hash(t))}clear(){n(this,i,"f").clear()}values(){return n(this,i,"f").values()}}class u{constructor(){o.set(this,[])}get[(o=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}get size(){return n(this,o,"f").length}empty(){n(this,o,"f").length=0}enqueue(...t){n(this,o,"f").push(...t)}dequeue(){return n(this,o,"f").shift()}remove(t){let e;for(;(e=n(this,o,"f").indexOf(t))>=0;)n(this,o,"f").splice(e,1)}}var f="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},l={},d={CustomError:void 0};class y extends Error{get name(){return this.constructor.name}}d.CustomError=y;var v={ExpectedError:void 0};const h=d;class p extends h.CustomError{}v.ExpectedError=p;var m={AssertionError:void 0};const b=d;class g extends b.CustomError{}m.AssertionError=g;var w={};w.normalize=void 0,w.normalize=function(t){var n;return{name:t.name,message:t.message,stack:null!==(n=t.stack)&&void 0!==n?n:null}};var A={refute:void 0};const S=v;A.refute=function(t,n){if(t)throw new S.ExpectedError(n)};var I={assert:void 0};const T=m;var O,j;I.assert=function(t,n){if(!t)throw new T.AssertionError(n)},function(t){var n=f&&f.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=f&&f.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(d,t),e(v,t),e(m,t),e(w,t),e(A,t),e(I,t)}(l);class E{constructor(t){O.set(this,void 0),j.set(this,new Map),l.assert(Number.isInteger(t),"The parameter limit must be an integer"),l.assert(t>0,"The parameter limit must be a positive value"),function(t,n,e,r,i){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!i)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof n?t!==n||!i:!n.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");"a"===r?i.call(t,e):i?i.value=e:n.set(t,e)}(this,O,t,"f")}get[(O=new WeakMap,j=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}get size(){return n(this,j,"f").size}set(t,e){return n(this,j,"f").has(t)?this.updateItem(t,e):(n(this,j,"f").size===n(this,O,"f")&&n(this,j,"f").delete(this.getColdestKey()),n(this,j,"f").set(t,e)),this}has(t){return n(this,j,"f").has(t)}get(t){if(!this.has(t))return;const e=n(this,j,"f").get(t);return this.updateItem(t,e),e}delete(t){return n(this,j,"f").delete(t)}clear(){n(this,j,"f").clear()}updateItem(t,e){n(this,j,"f").delete(t),n(this,j,"f").set(t,e)}getColdestKey(){return n(this,j,"f").keys().next().value}}var R={},k={},x={},N={},B={};B.go=void 0,B.go=function(t){return t()},function(t){var n=f&&f.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]});(f&&f.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)})(B,t)}(N),x.chunkAsync=void 0;const q=N,_=l;x.chunkAsync=function(t,n){return _.assert(Number.isInteger(n),"The parameter size must be an integer"),_.assert(n>0,"The parameter size must be greater than 0"),q.go((async function*(){let e=[];for await(const r of t)e.push(r),e.length>=n&&(yield e,e=[]);e.length&&(yield e)}))};var C={},P={},U={};function z(t){return Array.isArray(t)}U.isntEmptyArray=U.isEmptyArray=U.isntArray=U.isArray=void 0,U.isArray=z,U.isntArray=function(t){return!z(t)},U.isEmptyArray=function(t){return 0===t.length},U.isntEmptyArray=function(t){return 0!==t.length};var J={},M={};function D(t){return null===t}M.isntNull=M.isNull=void 0,M.isNull=D,M.isntNull=function(t){return!D(t)};var W={};function F(t){return void 0===t}W.isntUndefined=W.isUndefined=void 0,W.isUndefined=F,W.isntUndefined=function(t){return!F(t)},J.isntAsyncIterable=J.isAsyncIterable=void 0;const L=M,H=W;function K(t){return L.isntNull(t)&&H.isntUndefined(t)&&"function"==typeof t[Symbol.asyncIterator]}J.isAsyncIterable=K,J.isntAsyncIterable=function(t){return!K(t)};var V={};function Q(t){return"bigint"==typeof t}V.isntBigInt=V.isBigInt=void 0,V.isBigInt=Q,V.isntBigInt=function(t){return!Q(t)};var G={};function X(t){return"boolean"==typeof t}G.isntBoolean=G.isBoolean=void 0,G.isBoolean=X,G.isntBoolean=function(t){return!X(t)};var Y={},Z={};function $(t){return tt(t)||nt(t)}function tt(t){return"string"==typeof t}function nt(t){return"object"==typeof t&&t instanceof String}Z.isntStringObject=Z.isStringObject=Z.isntStringPrimitive=Z.isStringPrimitive=Z.isntString=Z.isString=void 0,Z.isString=$,Z.isntString=function(t){return!$(t)},Z.isStringPrimitive=tt,Z.isntStringPrimitive=function(t){return!tt(t)},Z.isStringObject=nt,Z.isntStringObject=function(t){return!nt(t)},Y.isntCharObject=Y.isCharObject=Y.isntCharPrimitive=Y.isCharPrimitive=Y.isntChar=Y.isChar=void 0;const et=Z;function rt(t){return(et.isString(t)||et.isStringObject(t))&&1===t.length}function it(t){return et.isString(t)&&1===t.length}function ot(t){return et.isStringObject(t)&&1===t.length}Y.isChar=rt,Y.isntChar=function(t){return!rt(t)},Y.isCharPrimitive=it,Y.isntCharPrimitive=function(t){return!it(t)},Y.isCharObject=ot,Y.isntCharObject=function(t){return!ot(t)};var st={};function at(t){return t instanceof Date}st.isntDate=st.isDate=void 0,st.isDate=at,st.isntDate=function(t){return!at(t)};var ct={};ct.inEnum=void 0,ct.inEnum=function(t,n){return Object.values(n).includes(t)};var ut={};function ft(t){return!t}ut.isntFalsy=ut.isFalsy=void 0,ut.isFalsy=ft,ut.isntFalsy=function(t){return!ft(t)};var lt={};function dt(t){return"function"==typeof t}lt.isntFunction=lt.isFunction=void 0,lt.isFunction=dt,lt.isntFunction=function(t){return!dt(t)};var yt={};yt.isntIterable=yt.isIterable=void 0;const vt=M,ht=W;function pt(t){return vt.isntNull(t)&&ht.isntUndefined(t)&&"function"==typeof t[Symbol.iterator]}yt.isIterable=pt,yt.isntIterable=function(t){return!pt(t)};var mt={},bt={};function gt(t){return null!==t&&"object"==typeof t}bt.isntEmptyObject=bt.isEmptyObject=bt.isRecord=bt.isntObject=bt.isObject=void 0,bt.isObject=gt,bt.isntObject=function(t){return!gt(t)},bt.isRecord=function(t){return gt(t)},bt.isEmptyObject=function(t){return 0===Object.keys(t).length},bt.isntEmptyObject=function(t){return 0!==Object.keys(t).length};var wt={};function At(t){return"number"==typeof t}wt.isntNumber=wt.isNumber=void 0,wt.isNumber=At,wt.isntNumber=function(t){return!At(t)},mt.isntJsonRpcError=mt.isJsonRpcError=mt.isntJsonRpcSuccess=mt.isJsonRpcSuccess=mt.isntJsonRpcRequest=mt.isJsonRpcRequest=mt.isntJsonRpcNotification=mt.isJsonRpcNotification=void 0;const St=U,It=bt,Tt=Z,Ot=wt,jt=W;function Et(t){return Tt.isString(t)||Ot.isNumber(t)}function Rt(t){return St.isArray(t)||It.isObject(t)}function kt(t){return It.isRecord(t)&&Tt.isString(t.jsonrpc)&&Tt.isString(t.method)&&jt.isUndefined(t.id)&&Rt(t.params)}function xt(t){return It.isRecord(t)&&Tt.isString(t.jsonrpc)&&Tt.isString(t.method)&&Et(t.id)&&Rt(t.params)}function Nt(t){return It.isRecord(t)&&Tt.isString(t.jsonrpc)&&Tt.isString(t.id)&&jt.isntUndefined(t.result)}function Bt(t){return It.isRecord(t)&&Tt.isString(t.jsonrpc)&&Et(t.id)&&function(t){return It.isRecord(t)&&Ot.isNumber(t.code)&&Tt.isString(t.message)&&(jt.isUndefined(t.data)||It.isObject(t.data))}(t.error)}mt.isJsonRpcNotification=kt,mt.isntJsonRpcNotification=function(t){return!kt(t)},mt.isJsonRpcRequest=xt,mt.isntJsonRpcRequest=function(t){return!xt(t)},mt.isJsonRpcSuccess=Nt,mt.isntJsonRpcSuccess=function(t){return!Nt(t)},mt.isJsonRpcError=Bt,mt.isntJsonRpcError=function(t){return!Bt(t)};var qt={};qt.isntJson=qt.isJson=void 0,qt.isJson=function(t){try{return JSON.stringify(t),!0}catch(t){return!1}},qt.isntJson=function t(n){return!t()};var _t={};_t.isAbsoluteURL=void 0,_t.isAbsoluteURL=function(t){try{return new URL(t),!0}catch(t){return!1}},function(t){var n=f&&f.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=f&&f.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(U,t),e(J,t),e(V,t),e(G,t),e(Y,t),e(st,t),e(ct,t),e(ut,t),e(lt,t),e(yt,t),e(mt,t),e(qt,t),e(M,t),e(wt,t),e(bt,t),e(Z,t),e(W,t),e(_t,t)}(P),C.chunkByAsync=void 0;const Ct=P;C.chunkByAsync=function(t,n){return Ct.isAsyncIterable(t)?async function*(t){let e=[],r=0;for await(const i of t)e.push(i),await n(i,r)&&(yield e,e=[]),r++;e.length&&(yield e)}(t):async function*(t){let e=[],r=0;for(const i of t)e.push(i),await n(i,r)&&(yield e,e=[]),r++;e.length&&(yield e)}(t)};var Pt={};Pt.chunkBy=void 0,Pt.chunkBy=function*(t,n){let e=[],r=0;for(const i of t)e.push(i),n(i,r)&&(yield e,e=[]),r++;e.length&&(yield e)};var Ut={chunk:void 0};const zt=N,Jt=l;Ut.chunk=function(t,n){return Jt.assert(Number.isInteger(n),"The parameter size must be an integer"),Jt.assert(n>0,"The parameter size must be greater than 0"),zt.go((function*(){let e=[];for(const r of t)e.push(r),e.length>=n&&(yield e,e=[]);e.length&&(yield e)}))};var Mt={concatAsync:void 0};const Dt=P,Wt=N;Mt.concatAsync=function(t,...n){return Wt.go((async function*(){for(const e of[t,...n])if(Dt.isAsyncIterable(e))for await(const t of e)yield t;else for(const t of e)yield t}))};var Ft={concat:void 0};const Lt=N;Ft.concat=function(t,...n){return Lt.go((function*(){for(const e of[t,...n])yield*e}))};var Ht={},Kt={};Kt.copyIterable=Kt.copyAsyncIterable=void 0,Kt.copyAsyncIterable=async function*(t){for await(const n of t)yield n},Kt.copyIterable=function*(t){for(const n of t)yield n},Ht.dropAsync=void 0;const Vt=N,Qt=Kt,Gt=l;Ht.dropAsync=function(t,n){return Gt.assert(Number.isInteger(n),"The parameter count must be an integer"),Gt.assert(n>=0,"The parameter count must be greater than or equal to 0"),0===n?Qt.copyAsyncIterable(t):Vt.go((async function*(){var e;const r=t[Symbol.asyncIterator]();let i;try{let t;for(;!(({value:t,done:i}=await r.next()),i||n<=0);)n--;for(;!i;)yield t,({value:t,done:i}=await r.next())}finally{i||await(null===(e=r.return)||void 0===e?void 0:e.call(r))}}))};var Xt={dropRightAsync:void 0};const Yt=N,Zt=Kt,$t=l;Xt.dropRightAsync=function(t,n){return $t.assert(Number.isInteger(n),"The parameter count must be an integer"),$t.assert(n>=0,"The parameter count must be greater than or equal to 0"),0===n?Zt.copyAsyncIterable(t):Yt.go((async function*(){const e=(await async function(t){const n=[];for await(const e of t)n.push(e);return n}(t)).slice(0,-n);for(const t of e)yield t}))};var tn={dropRight:void 0};const nn=N,en=Kt,rn=l;tn.dropRight=function(t,n){return rn.assert(Number.isInteger(n),"The parameter count must be an integer"),rn.assert(n>=0,"The parameter count must be greater than or equal to 0"),0===n?en.copyIterable(t):nn.go((function*(){const e=Array.from(t);yield*e.slice(0,-n)}))};var on={dropUntilAsync:void 0};const sn=P;on.dropUntilAsync=function(t,n){return sn.isAsyncIterable(t)?async function*(t){var e;const r=t[Symbol.asyncIterator]();let i;try{let t,o=0;for(;!(({value:t,done:i}=await r.next()),i||await n(t,o++)););for(;!i;)yield t,({value:t,done:i}=await r.next())}finally{i||await(null===(e=r.return)||void 0===e?void 0:e.call(r))}}(t):async function*(t){var e;const r=t[Symbol.iterator]();let i;try{let t,o=0;for(;!(({value:t,done:i}=r.next()),i||await n(t,o++)););for(;!i;)yield t,({value:t,done:i}=r.next())}finally{i||null===(e=r.return)||void 0===e||e.call(r)}}(t)};var an={};an.dropUntil=void 0,an.dropUntil=function*(t,n){var e;const r=t[Symbol.iterator]();let i;try{let t,o=0;for(;!(({value:t,done:i}=r.next()),i||n(t,o++)););for(;!i;)yield t,({value:t,done:i}=r.next())}finally{i||null===(e=r.return)||void 0===e||e.call(r)}};var cn={drop:void 0};const un=N,fn=Kt,ln=l;cn.drop=function(t,n){return ln.assert(Number.isInteger(n),"The parameter count must be an integer"),ln.assert(n>=0,"The parameter count must be greater than or equal to 0"),0===n?fn.copyIterable(t):un.go((function*(){var e;const r=t[Symbol.iterator]();let i;try{let t;for(;!(({value:t,done:i}=r.next()),i||n<=0);)n--;for(;!i;)yield t,({value:t,done:i}=r.next())}finally{i||null===(e=r.return)||void 0===e||e.call(r)}}))};var dn={filterAsync:void 0};const yn=P;dn.filterAsync=function(t,n){return yn.isAsyncIterable(t)?async function*(t){let e=0;for await(const r of t)await n(r,e)&&(yield r),e++}(t):async function*(t){let e=0;for(const r of t)await n(r,e)&&(yield r),e++}(t)};var vn={};vn.filter=void 0,vn.filter=function*(t,n){let e=0;for(const r of t)n(r,e)&&(yield r),e++};var hn={},pn={},mn={flattenByAsync:void 0};const bn=P;function gn(t){return bn.isIterable(t)&&bn.isntChar(t)}mn.flattenByAsync=function(t,n){return bn.isAsyncIterable(t)?async function*(t){const r=1;for await(const i of t)gn(i)&&await n(i,r)?yield*e(i,r+1):yield i}(t):function(t){return e(t,1)}(t);async function*e(t,r){for(const i of t)gn(i)&&await n(i,r)?yield*e(i,r+1):yield i}},pn.flattenDeepAsync=void 0;const wn=mn,An=l;pn.flattenDeepAsync=function(t,n=1/0){return An.assert(n===1/0||Number.isInteger(n),"The parameter depth must be an integer"),An.assert(n>=0,"The parameter depth must be greater than or equal to 0"),wn.flattenByAsync(t,((t,e)=>e<=n))},hn.flattenAsync=void 0;const Sn=pn;hn.flattenAsync=function(t){return Sn.flattenDeepAsync(t,1)};var In={flattenBy:void 0};const Tn=P;In.flattenBy=function(t,n){return function*t(e,r){for(const o of e)i=o,Tn.isIterable(i)&&Tn.isntChar(i)&&n(o,r)?yield*t(o,r+1):yield o;var i}(t,1)};var On={flattenDeep:void 0};const jn=In,En=l;On.flattenDeep=function(t,n=1/0){return En.assert(n===1/0||Number.isInteger(n),"The parameter depth must be an integer"),En.assert(n>=0,"The parameter depth must be greater than or equal to 0"),jn.flattenBy(t,((t,e)=>e<=n))};var Rn={flatten:void 0};const kn=On;Rn.flatten=function(t){return kn.flattenDeep(t,1)};var xn={mapAsync:void 0};const Nn=P;xn.mapAsync=function(t,n){return Nn.isAsyncIterable(t)?async function*(t){let e=0;for await(const r of t)yield await n(r,e),e++}(t):async function*(t){let e=0;for(const r of t)yield await n(r,e),e++}(t)};var Bn={};Bn.map=void 0,Bn.map=function*(t,n){let e=0;for(const r of t)yield n(r,e),e++};var qn={repeatAsync:void 0};const _n=N,Cn=l;qn.repeatAsync=function(t,n){return Cn.assert(n===1/0||Number.isInteger(n),"The parameter times must be an integer"),Cn.assert(n>=0,"The parameter times must be greater than or equal to 0"),n===1/0&&function(){if("production"===process.env.NODE_ENV)return;console.warn("When iterable has no elements and times is Infinity, repeat() will be in dead loop")}(),_n.go((async function*(){const e=[];if(n>0){for await(const n of t)yield n,e.push(n);n--}for(;n>0;)yield*e,n--}))};var Pn={repeat:void 0};const Un=N,zn=l;Pn.repeat=function(t,n){return zn.assert(n===1/0||Number.isInteger(n),"The parameter times must be an integer"),zn.assert(n>=0,"The parameter times must be greater than or equal to 0"),n===1/0&&function(){if("production"===process.env.NODE_ENV)return;console.warn("When iterable has no elements and times is Infinity, repeat() will be in dead loop")}(),Un.go((function*(){const e=[];if(n>0){for(const n of t)yield n,e.push(n);n--}for(;n>0;)yield*e,n--}))};var Jn={sliceAsync:void 0};const Mn=N,Dn=l;Jn.sliceAsync=function(t,n,e=1/0){return Dn.assert(Number.isInteger(n),"The parameter start must be an integer"),Dn.assert(n>=0,"The parameter start must be greater than or equal to 0"),Dn.assert(Number.isInteger(e),"The parameter end must be an integer"),Dn.assert(e>=n,"The parameter end must be greater than or equal to start"),Mn.go((async function*(){let r=0;for await(const i of t){if(r>=e)break;r>=n&&(yield i),r++}}))};var Wn={slice:void 0};const Fn=N,Ln=l;Wn.slice=function(t,n,e=1/0){return Ln.assert(Number.isInteger(n),"The parameter start must be an integer"),Ln.assert(n>=0,"The parameter start must be greater than or equal to 0"),Ln.assert(Number.isInteger(e),"The parameter end must be an integer"),Ln.assert(e>=n,"The parameter end must be greater than or equal to start"),Fn.go((function*(){let r=0;for(const i of t){if(r>=e)break;r>=n&&(yield i),r++}}))};var Hn={};Hn.splitAsync=void 0,Hn.splitAsync=async function*(t,n){let e=[];for await(const r of t)r===n?(yield e,e=[]):e.push(r);yield e};var Kn={splitByAsync:void 0};const Vn=P;Kn.splitByAsync=function(t,n){return Vn.isAsyncIterable(t)?async function*(t){let e=[],r=0;for await(const i of t)await n(i,r)?(yield e,e=[]):e.push(i),r++;yield e}(t):async function*(t){let e=[],r=0;for(const i of t)await n(i,r)?(yield e,e=[]):e.push(i),r++;yield e}(t)};var Qn={};Qn.splitBy=void 0,Qn.splitBy=function*(t,n){let e=[],r=0;for(const i of t)n(i,r)?(yield e,e=[]):e.push(i),r++;yield e};var Gn={};Gn.split=void 0,Gn.split=function*(t,n){let e=[];for(const r of t)r===n?(yield e,e=[]):e.push(r);yield e};var Xn={takeAsync:void 0};const Yn=N,Zn=l;Xn.takeAsync=function(t,n){return Zn.assert(Number.isInteger(n),"The parameter count must be an integer"),Zn.assert(n>=0,"The parameter count must be greater than or equal to 0"),Yn.go((async function*(){if(0!==n)for await(const e of t)if(yield e,0===--n)break}))};var $n={takeRightAsync:void 0};const te=N,ne=l;$n.takeRightAsync=function(t,n){return ne.assert(Number.isInteger(n),"The parameter count must be an integer"),ne.assert(n>=0,"The parameter count must be greater than or equal to 0"),te.go((async function*(){var e;const r=t[Symbol.asyncIterator]();let i;try{const t=[];let o;for(;({value:o,done:i}=await r.next()),!i;)t.push(o),t.length>n&&t.shift();yield*t}finally{i||await(null===(e=r.return)||void 0===e?void 0:e.call(r))}}))};var ee={takeRight:void 0};const re=N,ie=l;ee.takeRight=function(t,n){return ie.assert(Number.isInteger(n),"The parameter count must be an integer"),ie.assert(n>=0,"The parameter count must be greater than or equal to 0"),re.go((function*(){var e;const r=t[Symbol.iterator]();let i;try{const t=[];let o;for(;({value:o,done:i}=r.next()),!i;)t.push(o),t.length>n&&t.shift();yield*t}finally{i||null===(e=r.return)||void 0===e||e.call(r)}}))};var oe={takeUntilAsync:void 0};const se=P;oe.takeUntilAsync=function(t,n){return se.isAsyncIterable(t)?async function*(t){let e=0;for await(const r of t){if(await n(r,e))break;yield r,e++}}(t):async function*(t){let e=0;for(const r of t){if(await n(r,e))break;yield r,e++}}(t)};var ae={};ae.takeUntil=void 0,ae.takeUntil=function*(t,n){let e=0;for(const r of t){if(n(r,e))break;yield r,e++}};var ce={take:void 0};const ue=N,fe=l;ce.take=function(t,n){return fe.assert(Number.isInteger(n),"The parameter count must be an integer"),fe.assert(n>=0,"The parameter count must be greater than or equal to 0"),ue.go((function*(){if(0!==n)for(const e of t)if(yield e,0===--n)break}))};var le={tapAsync:void 0};const de=P;le.tapAsync=function(t,n){return de.isAsyncIterable(t)?async function*(t){let e=0;for await(const r of t)await n(r,e),yield r,e++}(t):async function*(t){let e=0;for(const r of t)await n(r,e),yield r,e++}(t)};var ye={};ye.tap=void 0,ye.tap=function*(t,n){let e=0;for(const r of t)n(r,e),yield r,e++};var ve={};ve.toAsyncIterable=void 0,ve.toAsyncIterable=async function*(t){for(const n of t)yield n};var he={};he.transformAsync=void 0,he.transformAsync=async function*(t,n){yield*n(t)};var pe={};pe.transform=void 0,pe.transform=function*(t,n){yield*n(t)};var me={};me.uniqAsync=void 0,me.uniqAsync=async function*(t){const n=new Set;for await(const e of t)n.has(e)||(yield e,n.add(e))};var be={uniqByAsync:void 0};const ge=P;be.uniqByAsync=function(t,n){return ge.isAsyncIterable(t)?async function*(t){const e=new Set;let r=0;for await(const i of t){const t=await n(i,r);e.has(t)||(yield i,e.add(t)),r++}}(t):async function*(t){const e=new Set;let r=0;for(const i of t){const t=await n(i,r);e.has(t)||(yield i,e.add(t)),r++}}(t)};var we={};we.uniqBy=void 0,we.uniqBy=function*(t,n){const e=new Set;let r=0;for(const i of t){const t=n(i,r);e.has(t)||(yield i,e.add(t)),r++}};var Ae={};Ae.uniq=void 0,Ae.uniq=function*(t){const n=new Set;for(const e of t)n.has(e)||(yield e,n.add(e))};var Se={zipAsync:void 0};const Ie=P;var Te;!function(t){t[t.Sync=0]="Sync",t[t.Async=1]="Async"}(Te||(Te={})),Se.zipAsync=function(t,...n){return async function*(...t){var n,e,r,i;const o=t.length,s=t.map((t=>Ie.isAsyncIterable(t)?[Te.Async,t[Symbol.asyncIterator]()]:[Te.Sync,t[Symbol.iterator]()])),a=s.map((()=>!1));try{for(;;){const t=new Array(o);for(let n=0;n<o;n++){const[e,r]=s[n];let i;if(i=e===Te.Async?await r.next():r.next(),i.done)return void(a[n]=!0);t[n]=i.value}yield t}}finally{const t=s.filter(((t,n)=>!a[n]));for(const[o,s]of t)o===Te.Async?await(null===(e=(n=s).return)||void 0===e?void 0:e.call(n)):null===(i=(r=s).return)||void 0===i||i.call(r)}}(t,...n)};var Oe={};Oe.zip=void 0,Oe.zip=function(t,...n){return function*(...t){const n=t.length,e=t.map((t=>t[Symbol.iterator]())),r=e.map((()=>!1));try{for(;;){const t=new Array(n);for(let i=0;i<n;i++){const{value:n,done:o}=e[i].next();if(o)return void(r[i]=!0);t[i]=n}yield t}}finally{e.filter(((t,n)=>!r[n])).forEach((t=>{var n;return null===(n=t.return)||void 0===n?void 0:n.call(t)}))}}(t,...n)},function(t){var n=f&&f.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=f&&f.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(x,t),e(C,t),e(Pt,t),e(Ut,t),e(Mt,t),e(Ft,t),e(Ht,t),e(Xt,t),e(tn,t),e(on,t),e(an,t),e(cn,t),e(dn,t),e(vn,t),e(hn,t),e(mn,t),e(In,t),e(pn,t),e(On,t),e(Rn,t),e(xn,t),e(Bn,t),e(qn,t),e(Pn,t),e(Jn,t),e(Wn,t),e(Hn,t),e(Kn,t),e(Qn,t),e(Gn,t),e(Xn,t),e($n,t),e(ee,t),e(oe,t),e(ae,t),e(ce,t),e(le,t),e(ye,t),e(ve,t),e(he,t),e(pe,t),e(me,t),e(be,t),e(we,t),e(Ae,t),e(Se,t),e(Oe,t)}(k);var je={},Ee={};Ee.consume=void 0,Ee.consume=function(t,n){return n(t)};var Re={eachAsync:void 0};const ke=P;Re.eachAsync=function(t,n){return ke.isAsyncIterable(t)?async function(t){let e=0;for await(const r of t)await n(r,e),e++}(t):async function(t){let e=0;for(const r of t)await n(r,e),e++}(t)};var xe={};xe.each=void 0,xe.each=function(t,n){let e=0;for(const r of t)n(r,e),e++};var Ne={everyAsync:void 0};const Be=P;Ne.everyAsync=function(t,n){return Be.isAsyncIterable(t)?async function(t){let e=0;for await(const r of t){if(!await n(r,e))return!1;e++}return!0}(t):async function(t){let e=0;for(const r of t){if(!await n(r,e))return!1;e++}return!0}(t)};var qe={};qe.every=void 0,qe.every=function(t,n){let e=0;for(const r of t){if(!n(r,e))return!1;e++}return!0};var _e={findAsync:void 0};const Ce=P;_e.findAsync=function(t,n){return Ce.isAsyncIterable(t)?async function(t){let e=0;for await(const r of t){if(await n(r,e))return r;e++}return}(t):async function(t){let e=0;for(const r of t){if(await n(r,e))return r;e++}return}(t)};var Pe={};Pe.find=void 0,Pe.find=function(t,n){let e=0;for(const r of t){if(n(r,e))return r;e++}};var Ue={};Ue.firstAsync=void 0,Ue.firstAsync=async function(t){for await(const n of t)return n};var ze={};ze.first=void 0,ze.first=function(t){for(const n of t)return n};var Je={};Je.includesAsync=void 0,Je.includesAsync=async function(t,n){for await(const e of t)if(e===n)return!0;return!1};var Me={};Me.includes=void 0,Me.includes=function(t,n){for(const e of t)if(e===n)return!0;return!1};var De={};De.matchAsync=void 0,De.matchAsync=async function(t,n){const e=n.length;let r=0;for await(const i of t)if(i===n[r]&&r++,r===e)return!0;return!1};var We={};We.match=void 0,We.match=function(t,n){const e=n.length;let r=0;for(const i of t)if(i===n[r]&&r++,r===e)return!0;return!1};var Fe={reduceAsync:void 0};const Le=P;Fe.reduceAsync=function(t,n,e){return Le.isUndefined(e)?function(t,n){return Le.isAsyncIterable(t)?e(t):r(t);async function e(t){var e;const r=t[Symbol.asyncIterator]();let i;try{let t,s=await o(r),a=1;for(;({value:t,done:i}=await r.next()),!i;)s=await n(s,t,a++);return s}finally{i||await(null===(e=r.return)||void 0===e?void 0:e.call(r))}async function o(t){const n=await t.next();if(n.done)throw i=!0,new Error("Reduce of empty iterable with no initial value");return n.value}}async function r(t){var e;const r=t[Symbol.iterator]();let i;try{let t,s=o(r),a=1;for(;({value:t,done:i}=r.next()),!i;)s=await n(s,t,a++);return s}finally{i||null===(e=r.return)||void 0===e||e.call(r)}function o(t){const n=t.next();if(n.done)throw i=!0,new Error("Reduce of empty iterable with no initial value");return n.value}}}(t,n):function(t,n,e){return Le.isAsyncIterable(t)?i(t):r(t);async function r(t){let r=e,i=0;for(const e of t)r=await n(r,e,i++);return r}async function i(t){let r=e,i=0;for await(const e of t)r=await n(r,e,i++);return r}}(t,n,e)};var He={reduce:void 0};const Ke=P;He.reduce=function(t,n,e){return Ke.isUndefined(e)?function(t,n){var e;const r=t[Symbol.iterator]();let i;try{let t,s=o(r),a=1;for(;({value:t,done:i}=r.next()),!i;)s=n(s,t,a++);return s}finally{i||null===(e=r.return)||void 0===e||e.call(r)}function o(t){const n=t.next();if(n.done)throw i=!0,new Error("Reduce of empty iterable with no initial value");return n.value}}(t,n):function(t,n,e){let r=e,i=0;for(const e of t)r=n(r,e,i++);return r}(t,n,e)};var Ve={someAsync:void 0};const Qe=P;Ve.someAsync=function(t,n){return Qe.isAsyncIterable(t)?async function(t){let e=0;for await(const r of t){if(await n(r,e))return!0;e++}return!1}(t):async function(t){let e=0;for(const r of t){if(await n(r,e))return!0;e++}return!1}(t)};var Ge={};Ge.some=void 0,Ge.some=function(t,n){let e=0;for(const r of t){if(n(r,e))return!0;e++}return!1};var Xe={};Xe.lastAsync=void 0,Xe.lastAsync=async function(t){var n;const e=t[Symbol.asyncIterator]();let r;try{let t,i;for(;({value:t,done:r}=await e.next()),!r;)i=t;return i}finally{r||await(null===(n=e.return)||void 0===n?void 0:n.call(e))}};var Ye={};Ye.last=void 0,Ye.last=function(t){var n;const e=t[Symbol.iterator]();let r;try{let t,i;for(;({value:t,done:r}=e.next()),!r;)i=t;return i}finally{r||null===(n=e.return)||void 0===n||n.call(e)}};var Ze={toArrayAsync:void 0};const $e=Ee;Ze.toArrayAsync=function(t){return $e.consume(t,(async t=>{const n=[];for await(const e of t)n.push(e);return n}))};var tr={toArray:void 0};const nr=Ee;tr.toArray=function(t){return nr.consume(t,(t=>Array.from(t)))};var er={toSetAsync:void 0};const rr=Ee;er.toSetAsync=function(t){return rr.consume(t,(async t=>{const n=new Set;for await(const e of t)n.add(e);return n}))};var ir={toSet:void 0};const or=Ee;var sr;ir.toSet=function(t){return or.consume(t,(t=>new Set(t)))},function(t){var n=f&&f.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=f&&f.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(Ee,t),e(Re,t),e(xe,t),e(Ne,t),e(qe,t),e(_e,t),e(Pe,t),e(Ue,t),e(ze,t),e(Je,t),e(Me,t),e(De,t),e(We,t),e(Fe,t),e(He,t),e(Ve,t),e(Ge,t),e(Xe,t),e(Ye,t),e(Ze,t),e(tr,t),e(er,t),e(ir,t)}(je),function(t){var n=f&&f.__createBinding||(Object.create?function(t,n,e,r){void 0===r&&(r=e),Object.defineProperty(t,r,{enumerable:!0,get:function(){return n[e]}})}:function(t,n,e,r){void 0===r&&(r=e),t[r]=n[e]}),e=f&&f.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||n(e,t,r)};e(k,t),e(je,t)}(R);class ar{constructor(t){this.value=t,this.children=new Map}}class cr{constructor(){sr.set(this,new ar)}get[(sr=new WeakMap,Symbol.toStringTag)](){return this.constructor.name}set(t,e){let r=n(this,sr,"f");for(const n of t)r.children.has(n)||r.children.set(n,new ar),r=r.children.get(n);return r.value=e,this}has(t){let e=n(this,sr,"f");for(const n of t){if(!e.children.has(n))return!1;e=e.children.get(n)}return void 0!==e.value}get(t){let e=n(this,sr,"f");for(const n of t){if(!e.children.has(n))return;e=e.children.get(n)}return e.value}delete(t){const e=[];let r=n(this,sr,"f");for(const n of t){if(!r.children.has(n))return!1;e.push(r),r=r.children.get(n)}if(delete r.value,0===r.children.size)for(const[n,r]of R.toArray(R.zip(t,e)).reverse())if(r.children.delete(n),0!==r.children.size)break;return!0}}t.Emitter=s,t.HashMap=a,t.HashSet=c,t.LRUMap=E,t.Queue=u,t.TrieMap=cr,t.convertArrayToCons=function t([n,...e]){return[n,e.length?t(e):null]},t.convertConsToArray=function t([n,e]){return null===e?[n]:[n,...t(e)]},Object.defineProperty(t,"__esModule",{value:!0})}));
//# sourceMappingURL=index.umd.min.js.map

@@ -1,2 +0,2 @@

export declare class HashSet<V, K = unknown> implements Iterable<V> {
export declare class HashSet<V, H = unknown> implements Iterable<V> {
#private;

@@ -7,3 +7,3 @@ private hash;

[Symbol.iterator](): IterableIterator<V>;
constructor(hash: (value: V) => K);
constructor(hash: (value: V) => H);
add(value: V): this;

@@ -10,0 +10,0 @@ delete(value: V): boolean;

export * from './cons';
export * from './emitter';
export * from './hash-map';
export * from './hash-set';

@@ -4,0 +5,0 @@ export * from './queue';

@@ -15,2 +15,3 @@ "use strict";

__exportStar(require("./emitter"), exports);
__exportStar(require("./hash-map"), exports);
__exportStar(require("./hash-set"), exports);

@@ -17,0 +18,0 @@ __exportStar(require("./queue"), exports);

@@ -1,2 +0,2 @@

export declare class HashSet<V, K = unknown> implements Iterable<V> {
export declare class HashSet<V, H = unknown> implements Iterable<V> {
#private;

@@ -7,3 +7,3 @@ private hash;

[Symbol.iterator](): IterableIterator<V>;
constructor(hash: (value: V) => K);
constructor(hash: (value: V) => H);
add(value: V): this;

@@ -10,0 +10,0 @@ delete(value: V): boolean;

export * from './cons';
export * from './emitter';
export * from './hash-map';
export * from './hash-set';

@@ -4,0 +5,0 @@ export * from './queue';

@@ -15,2 +15,3 @@ "use strict";

__exportStar(require("./emitter"), exports);
__exportStar(require("./hash-map"), exports);
__exportStar(require("./hash-set"), exports);

@@ -17,0 +18,0 @@ __exportStar(require("./queue"), exports);

{
"name": "@blackglory/structures",
"version": "0.2.2",
"version": "0.2.3",
"description": "",

@@ -43,25 +43,25 @@ "files": [

"devDependencies": {
"@blackglory/jest-matchers": "^0.1.19",
"@commitlint/cli": "^12.1.4",
"@commitlint/config-conventional": "^12.1.4",
"@rollup/plugin-commonjs": "^19.0.0",
"@blackglory/jest-matchers": "^0.1.20",
"@commitlint/cli": "^13.1.0",
"@commitlint/config-conventional": "^13.1.0",
"@rollup/plugin-commonjs": "^19.0.2",
"@rollup/plugin-json": "^4.1.0",
"@rollup/plugin-node-resolve": "^13.0.0",
"@rollup/plugin-replace": "^2.4.2",
"@rollup/plugin-typescript": "^8.2.1",
"@types/jest": "^26.0.23",
"@types/node": "^16.0.0",
"@typescript-eslint/eslint-plugin": "^4.28.1",
"@typescript-eslint/parser": "^4.28.1",
"eslint": "^7.30.0",
"@rollup/plugin-node-resolve": "^13.0.4",
"@rollup/plugin-replace": "^3.0.0",
"@rollup/plugin-typescript": "^8.2.3",
"@types/jest": "^26.0.24",
"@types/node": "^16.4.5",
"@typescript-eslint/eslint-plugin": "^4.28.5",
"@typescript-eslint/parser": "^4.28.5",
"eslint": "^7.31.0",
"husky": "^4.3.8",
"iterable-operator": "^0.14.1",
"iterable-operator": "^0.14.2",
"jest": "^27.0.6",
"npm-run-all": "^4.1.5",
"rimraf": "^3.0.2",
"rollup": "^2.52.7",
"rollup": "^2.55.0",
"rollup-plugin-analyzer": "^4.0.0",
"rollup-plugin-terser": "^7.0.2",
"standard-version": "^9.3.0",
"ts-jest": "^27.0.3",
"standard-version": "^9.3.1",
"ts-jest": "^27.0.4",
"tscpaths": "^0.0.9",

@@ -68,0 +68,0 @@ "tslib": "^2.3.0",

@@ -43,6 +43,23 @@ # structures

### HashMap
```ts
class HashMap<K, V, H = unknown> {
get [Symbol.toStringTag](): string
get size(): number
constructor(hash: (key: K) => H)
set(key: K, value: V): this
has(key: K): boolean
get(key: K): V | undefined
delete(key: K): boolean
clear(): void
}
```
### HashSet
```ts
class HashSet<V, K = unknown> implements Iterable<V> {
class HashSet<V, H = unknown> implements Iterable<V> {
get [Symbol.toStringTag](): string

@@ -52,3 +69,3 @@ get size(): number

constructor(hash: (value: V) => K)
constructor(hash: (value: V) => H)

@@ -55,0 +72,0 @@ add(value: V): this

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc