@fern-api/php-dynamic-snippets 0.0.4 → 0.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. package/cjs/DynamicSnippetsGenerator.cjs +16 -15
  2. package/cjs/DynamicSnippetsGenerator.cjs.map +1 -0
  3. package/cjs/DynamicSnippetsGenerator.d.cts +1 -1
  4. package/cjs/EndpointSnippetGenerator.cjs +27 -15
  5. package/cjs/EndpointSnippetGenerator.cjs.map +1 -0
  6. package/cjs/EndpointSnippetGenerator.d.cts +2 -0
  7. package/cjs/context/DynamicSnippetsGeneratorContext.cjs +15 -14
  8. package/cjs/context/DynamicSnippetsGeneratorContext.cjs.map +1 -0
  9. package/cjs/context/DynamicTypeLiteralMapper.cjs +26 -14
  10. package/cjs/context/DynamicTypeLiteralMapper.cjs.map +1 -0
  11. package/cjs/context/FilePropertyMapper.cjs +26 -14
  12. package/cjs/context/FilePropertyMapper.cjs.map +1 -0
  13. package/cjs/index.cjs +28 -27
  14. package/cjs/index.cjs.map +1 -0
  15. package/cjs/index.d.cts +1 -1
  16. package/esm/DynamicSnippetsGenerator.d.ts +1 -1
  17. package/esm/DynamicSnippetsGenerator.js +2 -1
  18. package/esm/DynamicSnippetsGenerator.js.map +1 -0
  19. package/esm/EndpointSnippetGenerator.d.ts +2 -0
  20. package/esm/EndpointSnippetGenerator.js +2 -1
  21. package/esm/EndpointSnippetGenerator.js.map +1 -0
  22. package/esm/{chunk-KF5FVQY4.js → chunk-625QSFAH.js} +2 -1
  23. package/esm/chunk-625QSFAH.js.map +1 -0
  24. package/esm/chunk-7MI6WLZG.js +2 -0
  25. package/esm/chunk-7MI6WLZG.js.map +1 -0
  26. package/esm/chunk-BYNT7UJT.js +2 -0
  27. package/esm/chunk-BYNT7UJT.js.map +1 -0
  28. package/esm/chunk-J4Y3S6QS.js +40 -0
  29. package/esm/chunk-J4Y3S6QS.js.map +1 -0
  30. package/esm/{chunk-OBW623PQ.js → chunk-KU3OGJUU.js} +2 -1
  31. package/esm/chunk-KU3OGJUU.js.map +1 -0
  32. package/esm/chunk-YKXTGZL6.js +4 -0
  33. package/esm/chunk-YKXTGZL6.js.map +1 -0
  34. package/esm/chunk-ZYT6M32A.js +2 -0
  35. package/esm/chunk-ZYT6M32A.js.map +1 -0
  36. package/esm/context/DynamicSnippetsGeneratorContext.js +2 -1
  37. package/esm/context/DynamicSnippetsGeneratorContext.js.map +1 -0
  38. package/esm/context/DynamicTypeLiteralMapper.js +2 -1
  39. package/esm/context/DynamicTypeLiteralMapper.js.map +1 -0
  40. package/esm/context/FilePropertyMapper.js +2 -1
  41. package/esm/context/FilePropertyMapper.js.map +1 -0
  42. package/esm/index.d.ts +1 -1
  43. package/esm/index.js +12 -11
  44. package/esm/index.js.map +1 -0
  45. package/package.json +1 -1
  46. package/esm/chunk-4GDAMWPH.js +0 -1
  47. package/esm/chunk-LVYU2VDV.js +0 -28
  48. package/esm/chunk-MKUTGATJ.js +0 -1
  49. package/esm/chunk-RLJ7N42G.js +0 -3
  50. package/esm/chunk-TSABAZOR.js +0 -14
@@ -1,21 +1,21 @@
1
- "use strict";var le=Object.defineProperty,lt=Object.defineProperties,ht=Object.getOwnPropertyDescriptor,pt=Object.getOwnPropertyDescriptors,mt=Object.getOwnPropertyNames,be=Object.getOwnPropertySymbols;var Ce=Object.prototype.hasOwnProperty,dt=Object.prototype.propertyIsEnumerable;var Ee=(i,t,e)=>t in i?le(i,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):i[t]=e,he=(i,t)=>{for(var e in t||(t={}))Ce.call(t,e)&&Ee(i,e,t[e]);if(be)for(var e of be(t))dt.call(t,e)&&Ee(i,e,t[e]);return i},pe=(i,t)=>lt(i,pt(t));var ve=(i,t)=>()=>(i&&(t=i(i=0)),t);var Se=(i,t)=>{for(var e in t)le(i,e,{get:t[e],enumerable:!0})},wt=(i,t,e,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of mt(t))!Ce.call(i,n)&&n!==e&&le(i,n,{get:()=>t[n],enumerable:!(r=ht(t,n))||r.enumerable});return i};var yt=i=>wt(le({},"__esModule",{value:!0}),i);var f=(i,t,e)=>Ee(i,typeof t!="symbol"?t+"":t,e);function Be(){throw new Error("setTimeout has not been defined")}function Ue(){throw new Error("clearTimeout has not been defined")}function Me(i){if(O===setTimeout)return setTimeout(i,0);if((O===Be||!O)&&setTimeout)return O=setTimeout,setTimeout(i,0);try{return O(i,0)}catch(t){try{return O.call(null,i,0)}catch(e){return O.call(this,i,0)}}}function xt(i){if(Y===clearTimeout)return clearTimeout(i);if((Y===Ue||!Y)&&clearTimeout)return Y=clearTimeout,clearTimeout(i);try{return Y(i)}catch(t){try{return Y.call(null,i)}catch(e){return Y.call(this,i)}}}function gt(){!se||!J||(se=!1,J.length?P=J.concat(P):me=-1,P.length&&Fe())}function Fe(){if(!se){var i=Me(gt);se=!0;for(var t=P.length;t;){for(J=P,P=[];++me<t;)J&&J[me].run();me=-1,t=P.length}J=null,se=!1,xt(i)}}function Tt(i){var t=new Array(arguments.length-1);if(arguments.length>1)for(var e=1;e<arguments.length;e++)t[e-1]=arguments[e];P.push(new De(i,t)),P.length===1&&!se&&Me(Fe)}function De(i,t){this.fun=i,this.array=t}function H(){}function Ft(i){throw new Error("process.binding is not supported")}function Dt(){return"/"}function $t(i){throw new Error("process.chdir is not supported")}function Ot(){return 0}function Wt(i){var t=Yt.call(oe)*.001,e=Math.floor(t),r=Math.floor(t%1*1e9);return i&&(e=e-i[0],r=r-i[1],r<0&&(e--,r+=1e9)),[e,r]}function zt(){var i=new Date,t=i-Vt;return t/1e3}var O,Y,P,se,J,me,At,Et,vt,Nt,Lt,It,Rt,_t,kt,bt,Ct,St,Pt,Bt,Ut,Mt,oe,Yt,Vt,d,Pe,u=ve(()=>{"use strict";O=Be,Y=Ue;typeof globalThis.setTimeout=="function"&&(O=setTimeout);typeof globalThis.clearTimeout=="function"&&(Y=clearTimeout);P=[],se=!1,me=-1;De.prototype.run=function(){this.fun.apply(null,this.array)};At="browser",Et="browser",vt=!0,Nt={},Lt=[],It="",Rt={},_t={},kt={};bt=H,Ct=H,St=H,Pt=H,Bt=H,Ut=H,Mt=H;oe=globalThis.performance||{},Yt=oe.now||oe.mozNow||oe.msNow||oe.oNow||oe.webkitNow||function(){return new Date().getTime()};Vt=new Date;d={nextTick:Tt,title:At,browser:vt,env:Nt,argv:Lt,version:It,versions:Rt,on:bt,addListener:Ct,once:St,off:Pt,removeListener:Bt,removeAllListeners:Ut,emit:Mt,binding:Ft,cwd:Dt,chdir:$t,umask:Ot,hrtime:Wt,platform:Et,release:_t,config:kt,uptime:zt},Pe={};Object.keys(Pe).forEach(i=>{let t=i.split("."),e=d;for(let r=0;r<t.length;r++){let n=t[r];r===t.length-1?e[n]=Pe[i]:e=e[n]||(e[n]={})}})});function We(){Le=!0;for(var i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",t=0,e=i.length;t<e;++t)_[t]=i[t],N[i.charCodeAt(t)]=t;N[45]=62,N[95]=63}function Gt(i){Le||We();var t,e,r,n,o,s,c=i.length;if(c%4>0)throw new Error("Invalid string. Length must be a multiple of 4");o=i[c-2]==="="?2:i[c-1]==="="?1:0,s=new qt(c*3/4-o),r=o>0?c-4:c;var h=0;for(t=0,e=0;t<r;t+=4,e+=3)n=N[i.charCodeAt(t)]<<18|N[i.charCodeAt(t+1)]<<12|N[i.charCodeAt(t+2)]<<6|N[i.charCodeAt(t+3)],s[h++]=n>>16&255,s[h++]=n>>8&255,s[h++]=n&255;return o===2?(n=N[i.charCodeAt(t)]<<2|N[i.charCodeAt(t+1)]>>4,s[h++]=n&255):o===1&&(n=N[i.charCodeAt(t)]<<10|N[i.charCodeAt(t+1)]<<4|N[i.charCodeAt(t+2)]>>2,s[h++]=n>>8&255,s[h++]=n&255),s}function Jt(i){return _[i>>18&63]+_[i>>12&63]+_[i>>6&63]+_[i&63]}function Ht(i,t,e){for(var r,n=[],o=t;o<e;o+=3)r=(i[o]<<16)+(i[o+1]<<8)+i[o+2],n.push(Jt(r));return n.join("")}function $e(i){Le||We();for(var t,e=i.length,r=e%3,n="",o=[],s=16383,c=0,h=e-r;c<h;c+=s)o.push(Ht(i,c,c+s>h?h:c+s));return r===1?(t=i[e-1],n+=_[t>>2],n+=_[t<<4&63],n+="=="):r===2&&(t=(i[e-2]<<8)+i[e-1],n+=_[t>>10],n+=_[t>>4&63],n+=_[t<<2&63],n+="="),o.push(n),o.join("")}function de(){return a.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function B(i,t){if(de()<t)throw new RangeError("Invalid typed array length");return a.TYPED_ARRAY_SUPPORT?(i=new Uint8Array(t),i.__proto__=a.prototype):(i===null&&(i=new a(t)),i.length=t),i}function a(i,t,e){if(!a.TYPED_ARRAY_SUPPORT&&!(this instanceof a))return new a(i,t,e);if(typeof i=="number"){if(typeof t=="string")throw new Error("If encoding is specified then the first argument must be a string");return Ie(this,i)}return Ve(this,i,t,e)}function Ve(i,t,e,r){if(typeof t=="number")throw new TypeError('"value" argument must not be a number');return typeof ArrayBuffer!="undefined"&&t instanceof ArrayBuffer?Zt(i,t,e,r):typeof t=="string"?Xt(i,t,e):jt(i,t)}function ze(i){if(typeof i!="number")throw new TypeError('"size" argument must be a number');if(i<0)throw new RangeError('"size" argument must not be negative')}function Qt(i,t,e,r){return ze(t),t<=0?B(i,t):e!==void 0?typeof r=="string"?B(i,t).fill(e,r):B(i,t).fill(e):B(i,t)}function Ie(i,t){if(ze(t),i=B(i,t<0?0:Re(t)|0),!a.TYPED_ARRAY_SUPPORT)for(var e=0;e<t;++e)i[e]=0;return i}function Xt(i,t,e){if((typeof e!="string"||e==="")&&(e="utf8"),!a.isEncoding(e))throw new TypeError('"encoding" must be a valid string encoding');var r=qe(t,e)|0;i=B(i,r);var n=i.write(t,e);return n!==r&&(i=i.slice(0,n)),i}function Ne(i,t){var e=t.length<0?0:Re(t.length)|0;i=B(i,e);for(var r=0;r<e;r+=1)i[r]=t[r]&255;return i}function Zt(i,t,e,r){if(t.byteLength,e<0||t.byteLength<e)throw new RangeError("'offset' is out of bounds");if(t.byteLength<e+(r||0))throw new RangeError("'length' is out of bounds");return e===void 0&&r===void 0?t=new Uint8Array(t):r===void 0?t=new Uint8Array(t,e):t=new Uint8Array(t,e,r),a.TYPED_ARRAY_SUPPORT?(i=t,i.__proto__=a.prototype):i=Ne(i,t),i}function jt(i,t){if(k(t)){var e=Re(t.length)|0;return i=B(i,e),i.length===0||t.copy(i,0,0,e),i}if(t){if(typeof ArrayBuffer!="undefined"&&t.buffer instanceof ArrayBuffer||"length"in t)return typeof t.length!="number"||yr(t.length)?B(i,0):Ne(i,t);if(t.type==="Buffer"&&Array.isArray(t.data))return Ne(i,t.data)}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}function Re(i){if(i>=de())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+de().toString(16)+" bytes");return i|0}function k(i){return!!(i!=null&&i._isBuffer)}function qe(i,t){if(k(i))return i.length;if(typeof ArrayBuffer!="undefined"&&typeof ArrayBuffer.isView=="function"&&(ArrayBuffer.isView(i)||i instanceof ArrayBuffer))return i.byteLength;typeof i!="string"&&(i=""+i);var e=i.length;if(e===0)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return e;case"utf8":case"utf-8":case void 0:return we(i).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return e*2;case"hex":return e>>>1;case"base64":return je(i).length;default:if(r)return we(i).length;t=(""+t).toLowerCase(),r=!0}}function Kt(i,t,e){var r=!1;if((t===void 0||t<0)&&(t=0),t>this.length||((e===void 0||e>this.length)&&(e=this.length),e<=0)||(e>>>=0,t>>>=0,e<=t))return"";for(i||(i="utf8");;)switch(i){case"hex":return cr(this,t,e);case"utf8":case"utf-8":return He(this,t,e);case"ascii":return ar(this,t,e);case"latin1":case"binary":return fr(this,t,e);case"base64":return or(this,t,e);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ur(this,t,e);default:if(r)throw new TypeError("Unknown encoding: "+i);i=(i+"").toLowerCase(),r=!0}}function Q(i,t,e){var r=i[t];i[t]=i[e],i[e]=r}function Ge(i,t,e,r,n){if(i.length===0)return-1;if(typeof e=="string"?(r=e,e=0):e>2147483647?e=2147483647:e<-2147483648&&(e=-2147483648),e=+e,isNaN(e)&&(e=n?0:i.length-1),e<0&&(e=i.length+e),e>=i.length){if(n)return-1;e=i.length-1}else if(e<0)if(n)e=0;else return-1;if(typeof t=="string"&&(t=a.from(t,r)),k(t))return t.length===0?-1:Oe(i,t,e,r,n);if(typeof t=="number")return t=t&255,a.TYPED_ARRAY_SUPPORT&&typeof Uint8Array.prototype.indexOf=="function"?n?Uint8Array.prototype.indexOf.call(i,t,e):Uint8Array.prototype.lastIndexOf.call(i,t,e):Oe(i,[t],e,r,n);throw new TypeError("val must be string, number or Buffer")}function Oe(i,t,e,r,n){var o=1,s=i.length,c=t.length;if(r!==void 0&&(r=String(r).toLowerCase(),r==="ucs2"||r==="ucs-2"||r==="utf16le"||r==="utf-16le")){if(i.length<2||t.length<2)return-1;o=2,s/=2,c/=2,e/=2}function h(E,ne){return o===1?E[ne]:E.readUInt16BE(ne*o)}var m;if(n){var w=-1;for(m=e;m<s;m++)if(h(i,m)===h(t,w===-1?0:m-w)){if(w===-1&&(w=m),m-w+1===c)return w*o}else w!==-1&&(m-=m-w),w=-1}else for(e+c>s&&(e=s-c),m=e;m>=0;m--){for(var y=!0,I=0;I<c;I++)if(h(i,m+I)!==h(t,I)){y=!1;break}if(y)return m}return-1}function er(i,t,e,r){e=Number(e)||0;var n=i.length-e;r?(r=Number(r),r>n&&(r=n)):r=n;var o=t.length;if(o%2!==0)throw new TypeError("Invalid hex string");r>o/2&&(r=o/2);for(var s=0;s<r;++s){var c=parseInt(t.substr(s*2,2),16);if(isNaN(c))return s;i[e+s]=c}return s}function tr(i,t,e,r){return ge(we(t,i.length-e),i,e,r)}function Je(i,t,e,r){return ge(dr(t),i,e,r)}function rr(i,t,e,r){return Je(i,t,e,r)}function ir(i,t,e,r){return ge(je(t),i,e,r)}function nr(i,t,e,r){return ge(wr(t,i.length-e),i,e,r)}function or(i,t,e){return t===0&&e===i.length?$e(i):$e(i.slice(t,e))}function He(i,t,e){e=Math.min(i.length,e);for(var r=[],n=t;n<e;){var o=i[n],s=null,c=o>239?4:o>223?3:o>191?2:1;if(n+c<=e){var h,m,w,y;switch(c){case 1:o<128&&(s=o);break;case 2:h=i[n+1],(h&192)===128&&(y=(o&31)<<6|h&63,y>127&&(s=y));break;case 3:h=i[n+1],m=i[n+2],(h&192)===128&&(m&192)===128&&(y=(o&15)<<12|(h&63)<<6|m&63,y>2047&&(y<55296||y>57343)&&(s=y));break;case 4:h=i[n+1],m=i[n+2],w=i[n+3],(h&192)===128&&(m&192)===128&&(w&192)===128&&(y=(o&15)<<18|(h&63)<<12|(m&63)<<6|w&63,y>65535&&y<1114112&&(s=y))}}s===null?(s=65533,c=1):s>65535&&(s-=65536,r.push(s>>>10&1023|55296),s=56320|s&1023),r.push(s),n+=c}return sr(r)}function sr(i){var t=i.length;if(t<=Ye)return String.fromCharCode.apply(String,i);for(var e="",r=0;r<t;)e+=String.fromCharCode.apply(String,i.slice(r,r+=Ye));return e}function ar(i,t,e){var r="";e=Math.min(i.length,e);for(var n=t;n<e;++n)r+=String.fromCharCode(i[n]&127);return r}function fr(i,t,e){var r="";e=Math.min(i.length,e);for(var n=t;n<e;++n)r+=String.fromCharCode(i[n]);return r}function cr(i,t,e){var r=i.length;(!t||t<0)&&(t=0),(!e||e<0||e>r)&&(e=r);for(var n="",o=t;o<e;++o)n+=mr(i[o]);return n}function ur(i,t,e){for(var r=i.slice(t,e),n="",o=0;o<r.length;o+=2)n+=String.fromCharCode(r[o]+r[o+1]*256);return n}function x(i,t,e){if(i%1!==0||i<0)throw new RangeError("offset is not uint");if(i+t>e)throw new RangeError("Trying to access beyond buffer length")}function A(i,t,e,r,n,o){if(!k(i))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>n||t<o)throw new RangeError('"value" argument is out of bounds');if(e+r>i.length)throw new RangeError("Index out of range")}function ye(i,t,e,r){t<0&&(t=65535+t+1);for(var n=0,o=Math.min(i.length-e,2);n<o;++n)i[e+n]=(t&255<<8*(r?n:1-n))>>>(r?n:1-n)*8}function xe(i,t,e,r){t<0&&(t=4294967295+t+1);for(var n=0,o=Math.min(i.length-e,4);n<o;++n)i[e+n]=t>>>(r?n:3-n)*8&255}function Qe(i,t,e,r,n,o){if(e+r>i.length)throw new RangeError("Index out of range");if(e<0)throw new RangeError("Index out of range")}function Xe(i,t,e,r,n){return n||Qe(i,t,e,4,34028234663852886e22,-34028234663852886e22),et(i,t,e,r,23,4),e+4}function Ze(i,t,e,r,n){return n||Qe(i,t,e,8,17976931348623157e292,-17976931348623157e292),et(i,t,e,r,52,8),e+8}function hr(i){if(i=pr(i).replace(lr,""),i.length<2)return"";for(;i.length%4!==0;)i=i+"=";return i}function pr(i){return i.trim?i.trim():i.replace(/^\s+|\s+$/g,"")}function mr(i){return i<16?"0"+i.toString(16):i.toString(16)}function we(i,t){t=t||1/0;for(var e,r=i.length,n=null,o=[],s=0;s<r;++s){if(e=i.charCodeAt(s),e>55295&&e<57344){if(!n){if(e>56319){(t-=3)>-1&&o.push(239,191,189);continue}else if(s+1===r){(t-=3)>-1&&o.push(239,191,189);continue}n=e;continue}if(e<56320){(t-=3)>-1&&o.push(239,191,189),n=e;continue}e=(n-55296<<10|e-56320)+65536}else n&&(t-=3)>-1&&o.push(239,191,189);if(n=null,e<128){if((t-=1)<0)break;o.push(e)}else if(e<2048){if((t-=2)<0)break;o.push(e>>6|192,e&63|128)}else if(e<65536){if((t-=3)<0)break;o.push(e>>12|224,e>>6&63|128,e&63|128)}else if(e<1114112){if((t-=4)<0)break;o.push(e>>18|240,e>>12&63|128,e>>6&63|128,e&63|128)}else throw new Error("Invalid code point")}return o}function dr(i){for(var t=[],e=0;e<i.length;++e)t.push(i.charCodeAt(e)&255);return t}function wr(i,t){for(var e,r,n,o=[],s=0;s<i.length&&!((t-=2)<0);++s)e=i.charCodeAt(s),r=e>>8,n=e%256,o.push(n),o.push(r);return o}function je(i){return Gt(hr(i))}function ge(i,t,e,r){for(var n=0;n<r&&!(n+e>=t.length||n>=i.length);++n)t[n+e]=i[n];return n}function yr(i){return i!==i}function xr(i){return i!=null&&(!!i._isBuffer||Ke(i)||gr(i))}function Ke(i){return!!i.constructor&&typeof i.constructor.isBuffer=="function"&&i.constructor.isBuffer(i)}function gr(i){return typeof i.readFloatLE=="function"&&typeof i.slice=="function"&&Ke(i.slice(0,0))}function Te(i,t,e,r,n){var o,s,c=n*8-r-1,h=(1<<c)-1,m=h>>1,w=-7,y=e?n-1:0,I=e?-1:1,E=i[t+y];for(y+=I,o=E&(1<<-w)-1,E>>=-w,w+=c;w>0;o=o*256+i[t+y],y+=I,w-=8);for(s=o&(1<<-w)-1,o>>=-w,w+=r;w>0;s=s*256+i[t+y],y+=I,w-=8);if(o===0)o=1-m;else{if(o===h)return s?NaN:(E?-1:1)*(1/0);s=s+Math.pow(2,r),o=o-m}return(E?-1:1)*s*Math.pow(2,o-r)}function et(i,t,e,r,n,o){var s,c,h,m=o*8-n-1,w=(1<<m)-1,y=w>>1,I=n===23?Math.pow(2,-24)-Math.pow(2,-77):0,E=r?0:o-1,ne=r?1:-1,ut=t<0||t===0&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(c=isNaN(t)?1:0,s=w):(s=Math.floor(Math.log(t)/Math.LN2),t*(h=Math.pow(2,-s))<1&&(s--,h*=2),s+y>=1?t+=I/h:t+=I*Math.pow(2,1-y),t*h>=2&&(s++,h/=2),s+y>=w?(c=0,s=w):s+y>=1?(c=(t*h-1)*Math.pow(2,n),s=s+y):(c=t*Math.pow(2,y-1)*Math.pow(2,n),s=0));n>=8;i[e+E]=c&255,E+=ne,c/=256,n-=8);for(s=s<<n|c,m+=n;m>0;i[e+E]=s&255,E+=ne,s/=256,m-=8);i[e+E-ne]|=ut*128}var _,N,qt,Le,Ye,lr,tt=ve(()=>{"use strict";u();l();_=[],N=[],qt=typeof Uint8Array!="undefined"?Uint8Array:Array,Le=!1;a.TYPED_ARRAY_SUPPORT=globalThis.TYPED_ARRAY_SUPPORT!==void 0?globalThis.TYPED_ARRAY_SUPPORT:!0;a.poolSize=8192;a._augment=function(i){return i.__proto__=a.prototype,i};a.from=function(i,t,e){return Ve(null,i,t,e)};a.kMaxLength=de();a.TYPED_ARRAY_SUPPORT&&(a.prototype.__proto__=Uint8Array.prototype,a.__proto__=Uint8Array,typeof Symbol!="undefined"&&Symbol.species&&a[Symbol.species]);a.alloc=function(i,t,e){return Qt(null,i,t,e)};a.allocUnsafe=function(i){return Ie(null,i)};a.allocUnsafeSlow=function(i){return Ie(null,i)};a.isBuffer=xr;a.compare=function(t,e){if(!k(t)||!k(e))throw new TypeError("Arguments must be Buffers");if(t===e)return 0;for(var r=t.length,n=e.length,o=0,s=Math.min(r,n);o<s;++o)if(t[o]!==e[o]){r=t[o],n=e[o];break}return r<n?-1:n<r?1:0};a.isEncoding=function(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}};a.concat=function(t,e){if(!Array.isArray(t))throw new TypeError('"list" argument must be an Array of Buffers');if(t.length===0)return a.alloc(0);var r;if(e===void 0)for(e=0,r=0;r<t.length;++r)e+=t[r].length;var n=a.allocUnsafe(e),o=0;for(r=0;r<t.length;++r){var s=t[r];if(!k(s))throw new TypeError('"list" argument must be an Array of Buffers');s.copy(n,o),o+=s.length}return n};a.byteLength=qe;a.prototype._isBuffer=!0;a.prototype.swap16=function(){var t=this.length;if(t%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var e=0;e<t;e+=2)Q(this,e,e+1);return this};a.prototype.swap32=function(){var t=this.length;if(t%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var e=0;e<t;e+=4)Q(this,e,e+3),Q(this,e+1,e+2);return this};a.prototype.swap64=function(){var t=this.length;if(t%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var e=0;e<t;e+=8)Q(this,e,e+7),Q(this,e+1,e+6),Q(this,e+2,e+5),Q(this,e+3,e+4);return this};a.prototype.toString=function(){var t=this.length|0;return t===0?"":arguments.length===0?He(this,0,t):Kt.apply(this,arguments)};a.prototype.equals=function(t){if(!k(t))throw new TypeError("Argument must be a Buffer");return this===t?!0:a.compare(this,t)===0};a.prototype.compare=function(t,e,r,n,o){if(!k(t))throw new TypeError("Argument must be a Buffer");if(e===void 0&&(e=0),r===void 0&&(r=t?t.length:0),n===void 0&&(n=0),o===void 0&&(o=this.length),e<0||r>t.length||n<0||o>this.length)throw new RangeError("out of range index");if(n>=o&&e>=r)return 0;if(n>=o)return-1;if(e>=r)return 1;if(e>>>=0,r>>>=0,n>>>=0,o>>>=0,this===t)return 0;for(var s=o-n,c=r-e,h=Math.min(s,c),m=this.slice(n,o),w=t.slice(e,r),y=0;y<h;++y)if(m[y]!==w[y]){s=m[y],c=w[y];break}return s<c?-1:c<s?1:0};a.prototype.includes=function(t,e,r){return this.indexOf(t,e,r)!==-1};a.prototype.indexOf=function(t,e,r){return Ge(this,t,e,r,!0)};a.prototype.lastIndexOf=function(t,e,r){return Ge(this,t,e,r,!1)};a.prototype.write=function(t,e,r,n){if(e===void 0)n="utf8",r=this.length,e=0;else if(r===void 0&&typeof e=="string")n=e,r=this.length,e=0;else if(isFinite(e))e=e|0,isFinite(r)?(r=r|0,n===void 0&&(n="utf8")):(n=r,r=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var o=this.length-e;if((r===void 0||r>o)&&(r=o),t.length>0&&(r<0||e<0)||e>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var s=!1;;)switch(n){case"hex":return er(this,t,e,r);case"utf8":case"utf-8":return tr(this,t,e,r);case"ascii":return Je(this,t,e,r);case"latin1":case"binary":return rr(this,t,e,r);case"base64":return ir(this,t,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return nr(this,t,e,r);default:if(s)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),s=!0}};a.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};Ye=4096;a.prototype.slice=function(t,e){var r=this.length;t=~~t,e=e===void 0?r:~~e,t<0?(t+=r,t<0&&(t=0)):t>r&&(t=r),e<0?(e+=r,e<0&&(e=0)):e>r&&(e=r),e<t&&(e=t);var n;if(a.TYPED_ARRAY_SUPPORT)n=this.subarray(t,e),n.__proto__=a.prototype;else{var o=e-t;n=new a(o,void 0);for(var s=0;s<o;++s)n[s]=this[s+t]}return n};a.prototype.readUIntLE=function(t,e,r){t=t|0,e=e|0,r||x(t,e,this.length);for(var n=this[t],o=1,s=0;++s<e&&(o*=256);)n+=this[t+s]*o;return n};a.prototype.readUIntBE=function(t,e,r){t=t|0,e=e|0,r||x(t,e,this.length);for(var n=this[t+--e],o=1;e>0&&(o*=256);)n+=this[t+--e]*o;return n};a.prototype.readUInt8=function(t,e){return e||x(t,1,this.length),this[t]};a.prototype.readUInt16LE=function(t,e){return e||x(t,2,this.length),this[t]|this[t+1]<<8};a.prototype.readUInt16BE=function(t,e){return e||x(t,2,this.length),this[t]<<8|this[t+1]};a.prototype.readUInt32LE=function(t,e){return e||x(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+this[t+3]*16777216};a.prototype.readUInt32BE=function(t,e){return e||x(t,4,this.length),this[t]*16777216+(this[t+1]<<16|this[t+2]<<8|this[t+3])};a.prototype.readIntLE=function(t,e,r){t=t|0,e=e|0,r||x(t,e,this.length);for(var n=this[t],o=1,s=0;++s<e&&(o*=256);)n+=this[t+s]*o;return o*=128,n>=o&&(n-=Math.pow(2,8*e)),n};a.prototype.readIntBE=function(t,e,r){t=t|0,e=e|0,r||x(t,e,this.length);for(var n=e,o=1,s=this[t+--n];n>0&&(o*=256);)s+=this[t+--n]*o;return o*=128,s>=o&&(s-=Math.pow(2,8*e)),s};a.prototype.readInt8=function(t,e){return e||x(t,1,this.length),this[t]&128?(255-this[t]+1)*-1:this[t]};a.prototype.readInt16LE=function(t,e){e||x(t,2,this.length);var r=this[t]|this[t+1]<<8;return r&32768?r|4294901760:r};a.prototype.readInt16BE=function(t,e){e||x(t,2,this.length);var r=this[t+1]|this[t]<<8;return r&32768?r|4294901760:r};a.prototype.readInt32LE=function(t,e){return e||x(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24};a.prototype.readInt32BE=function(t,e){return e||x(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]};a.prototype.readFloatLE=function(t,e){return e||x(t,4,this.length),Te(this,t,!0,23,4)};a.prototype.readFloatBE=function(t,e){return e||x(t,4,this.length),Te(this,t,!1,23,4)};a.prototype.readDoubleLE=function(t,e){return e||x(t,8,this.length),Te(this,t,!0,52,8)};a.prototype.readDoubleBE=function(t,e){return e||x(t,8,this.length),Te(this,t,!1,52,8)};a.prototype.writeUIntLE=function(t,e,r,n){if(t=+t,e=e|0,r=r|0,!n){var o=Math.pow(2,8*r)-1;A(this,t,e,r,o,0)}var s=1,c=0;for(this[e]=t&255;++c<r&&(s*=256);)this[e+c]=t/s&255;return e+r};a.prototype.writeUIntBE=function(t,e,r,n){if(t=+t,e=e|0,r=r|0,!n){var o=Math.pow(2,8*r)-1;A(this,t,e,r,o,0)}var s=r-1,c=1;for(this[e+s]=t&255;--s>=0&&(c*=256);)this[e+s]=t/c&255;return e+r};a.prototype.writeUInt8=function(t,e,r){return t=+t,e=e|0,r||A(this,t,e,1,255,0),a.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[e]=t&255,e+1};a.prototype.writeUInt16LE=function(t,e,r){return t=+t,e=e|0,r||A(this,t,e,2,65535,0),a.TYPED_ARRAY_SUPPORT?(this[e]=t&255,this[e+1]=t>>>8):ye(this,t,e,!0),e+2};a.prototype.writeUInt16BE=function(t,e,r){return t=+t,e=e|0,r||A(this,t,e,2,65535,0),a.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=t&255):ye(this,t,e,!1),e+2};a.prototype.writeUInt32LE=function(t,e,r){return t=+t,e=e|0,r||A(this,t,e,4,4294967295,0),a.TYPED_ARRAY_SUPPORT?(this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=t&255):xe(this,t,e,!0),e+4};a.prototype.writeUInt32BE=function(t,e,r){return t=+t,e=e|0,r||A(this,t,e,4,4294967295,0),a.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=t&255):xe(this,t,e,!1),e+4};a.prototype.writeIntLE=function(t,e,r,n){if(t=+t,e=e|0,!n){var o=Math.pow(2,8*r-1);A(this,t,e,r,o-1,-o)}var s=0,c=1,h=0;for(this[e]=t&255;++s<r&&(c*=256);)t<0&&h===0&&this[e+s-1]!==0&&(h=1),this[e+s]=(t/c>>0)-h&255;return e+r};a.prototype.writeIntBE=function(t,e,r,n){if(t=+t,e=e|0,!n){var o=Math.pow(2,8*r-1);A(this,t,e,r,o-1,-o)}var s=r-1,c=1,h=0;for(this[e+s]=t&255;--s>=0&&(c*=256);)t<0&&h===0&&this[e+s+1]!==0&&(h=1),this[e+s]=(t/c>>0)-h&255;return e+r};a.prototype.writeInt8=function(t,e,r){return t=+t,e=e|0,r||A(this,t,e,1,127,-128),a.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[e]=t&255,e+1};a.prototype.writeInt16LE=function(t,e,r){return t=+t,e=e|0,r||A(this,t,e,2,32767,-32768),a.TYPED_ARRAY_SUPPORT?(this[e]=t&255,this[e+1]=t>>>8):ye(this,t,e,!0),e+2};a.prototype.writeInt16BE=function(t,e,r){return t=+t,e=e|0,r||A(this,t,e,2,32767,-32768),a.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=t&255):ye(this,t,e,!1),e+2};a.prototype.writeInt32LE=function(t,e,r){return t=+t,e=e|0,r||A(this,t,e,4,2147483647,-2147483648),a.TYPED_ARRAY_SUPPORT?(this[e]=t&255,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24):xe(this,t,e,!0),e+4};a.prototype.writeInt32BE=function(t,e,r){return t=+t,e=e|0,r||A(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),a.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=t&255):xe(this,t,e,!1),e+4};a.prototype.writeFloatLE=function(t,e,r){return Xe(this,t,e,!0,r)};a.prototype.writeFloatBE=function(t,e,r){return Xe(this,t,e,!1,r)};a.prototype.writeDoubleLE=function(t,e,r){return Ze(this,t,e,!0,r)};a.prototype.writeDoubleBE=function(t,e,r){return Ze(this,t,e,!1,r)};a.prototype.copy=function(t,e,r,n){if(r||(r=0),!n&&n!==0&&(n=this.length),e>=t.length&&(e=t.length),e||(e=0),n>0&&n<r&&(n=r),n===r||t.length===0||this.length===0)return 0;if(e<0)throw new RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),t.length-e<n-r&&(n=t.length-e+r);var o=n-r,s;if(this===t&&r<e&&e<n)for(s=o-1;s>=0;--s)t[s+e]=this[s+r];else if(o<1e3||!a.TYPED_ARRAY_SUPPORT)for(s=0;s<o;++s)t[s+e]=this[s+r];else Uint8Array.prototype.set.call(t,this.subarray(r,r+o),e);return o};a.prototype.fill=function(t,e,r,n){if(typeof t=="string"){if(typeof e=="string"?(n=e,e=0,r=this.length):typeof r=="string"&&(n=r,r=this.length),t.length===1){var o=t.charCodeAt(0);o<256&&(t=o)}if(n!==void 0&&typeof n!="string")throw new TypeError("encoding must be a string");if(typeof n=="string"&&!a.isEncoding(n))throw new TypeError("Unknown encoding: "+n)}else typeof t=="number"&&(t=t&255);if(e<0||this.length<e||this.length<r)throw new RangeError("Out of range index");if(r<=e)return this;e=e>>>0,r=r===void 0?this.length:r>>>0,t||(t=0);var s;if(typeof t=="number")for(s=e;s<r;++s)this[s]=t;else{var c=k(t)?t:we(new a(t,n).toString()),h=c.length;for(s=0;s<r-e;++s)this[s+e]=c[s%h]}return this};lr=/[^+\/0-9A-Za-z-_]/g});var l=ve(()=>{"use strict";tt()});var Jr={};Se(Jr,{FilePropertyMapper:()=>ke});module.exports=yt(Jr);u();l();u();l();u();l();function W(i){throw new Error("Unexpected value: "+JSON.stringify(i))}u();l();u();l();var fe="",rt="self",it="static";var L={};Se(L,{Access:()=>V,Array:()=>X,AstNode:()=>p,Attribute:()=>Z,Class:()=>M,ClassInstantiation:()=>S,ClassReference:()=>g,CodeBlock:()=>T,DataClass:()=>K,Enum:()=>ee,Field:()=>te,Map:()=>re,Method:()=>D,MethodInvocation:()=>$,Parameter:()=>F,Trait:()=>j,Type:()=>R,TypeLiteral:()=>G,Writer:()=>C,array:()=>_r,assignVariable:()=>Wr,attribute:()=>kr,classReference:()=>Sr,class_:()=>br,codeblock:()=>ie,dataClass:()=>Pr,enum_:()=>Br,field:()=>Ur,instantiateClass:()=>ct,invokeMethod:()=>Mr,map:()=>Dr,mergeArrays:()=>qr,method:()=>$r,parameter:()=>Or,string:()=>zr,ternary:()=>Yr,this_:()=>Gr,throwException:()=>Fr,trait:()=>Cr,variable:()=>Vr});u();l();u();l();u();l();var U=class{};u();l();u();l();var b=class extends U{constructor(e){super();f(this,"value");this.value=e}write(e){typeof this.value=="string"?e.write(this.value):this.value(e)}};var Tr=4,ce=class{constructor(){f(this,"buffer","");f(this,"indentLevel",0);f(this,"hasWrittenAnything",!1);f(this,"lastCharacterIsNewline",!1)}write(t){let e=t.length>0&&t.endsWith(`
2
- `),r=e?t.substring(0,t.length-1):t,n=this.getIndentString(),o=r.replaceAll(`
1
+ "use strict";var Fe=Object.defineProperty,$o=Object.defineProperties,Wo=Object.getOwnPropertyDescriptor,Yo=Object.getOwnPropertyDescriptors,zo=Object.getOwnPropertyNames,Pt=Object.getOwnPropertySymbols;var Ot=Object.prototype.hasOwnProperty,Go=Object.prototype.propertyIsEnumerable;var ht=(r,t,e)=>t in r?Fe(r,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):r[t]=e,je=(r,t)=>{for(var e in t||(t={}))Ot.call(t,e)&&ht(r,e,t[e]);if(Pt)for(var e of Pt(t))Go.call(t,e)&&ht(r,e,t[e]);return r},$e=(r,t)=>$o(r,Yo(t));var xt=(r,t)=>()=>(r&&(t=r(r=0)),t);var Bt=(r,t)=>{for(var e in t)Fe(r,e,{get:t[e],enumerable:!0})},qo=(r,t,e,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of zo(t))!Ot.call(r,i)&&i!==e&&Fe(r,i,{get:()=>t[i],enumerable:!(o=Wo(t,i))||o.enumerable});return r};var Ho=r=>qo(Fe({},"__esModule",{value:!0}),r);var c=(r,t,e)=>ht(r,typeof t!="symbol"?t+"":t,e);function Mt(){throw new Error("setTimeout has not been defined")}function Ut(){throw new Error("clearTimeout has not been defined")}function Dt(r){if(Z===setTimeout)return setTimeout(r,0);if((Z===Mt||!Z)&&setTimeout)return Z=setTimeout,setTimeout(r,0);try{return Z(r,0)}catch(t){try{return Z.call(null,r,0)}catch(e){return Z.call(this,r,0)}}}function Vo(r){if(ee===clearTimeout)return clearTimeout(r);if((ee===Ut||!ee)&&clearTimeout)return ee=clearTimeout,clearTimeout(r);try{return ee(r)}catch(t){try{return ee.call(null,r)}catch(e){return ee.call(this,r)}}}function Ko(){!Ee||!le||(Ee=!1,le.length?F=le.concat(F):We=-1,F.length&&Ft())}function Ft(){if(!Ee){var r=Dt(Ko);Ee=!0;for(var t=F.length;t;){for(le=F,F=[];++We<t;)le&&le[We].run();We=-1,t=F.length}le=null,Ee=!1,Vo(r)}}function Jo(r){var t=new Array(arguments.length-1);if(arguments.length>1)for(var e=1;e<arguments.length;e++)t[e-1]=arguments[e];F.push(new jt(r,t)),F.length===1&&!Ee&&Dt(Ft)}function jt(r,t){this.fun=r,this.array=t}function ce(){}function mi(r){throw new Error("process.binding is not supported")}function di(){return"/"}function hi(r){throw new Error("process.chdir is not supported")}function xi(){return 0}function wi(r){var t=yi.call(_e)*.001,e=Math.floor(t),o=Math.floor(t%1*1e9);return r&&(e=e-r[0],o=o-r[1],o<0&&(e--,o+=1e9)),[e,o]}function Ti(){var r=new Date,t=r-gi;return t/1e3}var Z,ee,F,Ee,le,We,Qo,Xo,Zo,ei,ti,ri,oi,ii,ni,ai,si,fi,pi,ui,li,ci,_e,yi,gi,u,kt,n=xt(()=>{"use strict";Z=Mt,ee=Ut;typeof globalThis.setTimeout=="function"&&(Z=setTimeout);typeof globalThis.clearTimeout=="function"&&(ee=clearTimeout);F=[],Ee=!1,We=-1;jt.prototype.run=function(){this.fun.apply(null,this.array)};Qo="browser",Xo="browser",Zo=!0,ei={},ti=[],ri="",oi={},ii={},ni={};ai=ce,si=ce,fi=ce,pi=ce,ui=ce,li=ce,ci=ce;_e=globalThis.performance||{},yi=_e.now||_e.mozNow||_e.msNow||_e.oNow||_e.webkitNow||function(){return new Date().getTime()};gi=new Date;u={nextTick:Jo,title:Qo,browser:Zo,env:ei,argv:ti,version:ri,versions:oi,on:ai,addListener:si,once:fi,off:pi,removeListener:ui,removeAllListeners:li,emit:ci,binding:mi,cwd:di,chdir:hi,umask:xi,hrtime:wi,platform:Xo,release:ii,config:ni,uptime:Ti},kt={};Object.keys(kt).forEach(r=>{let t=r.split("."),e=u;for(let o=0;o<t.length;o++){let i=t[o];o===t.length-1?e[i]=kt[r]:e=e[i]||(e[i]={})}})});function zt(){wt=!0;for(var r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",t=0,e=r.length;t<e;++t)k[t]=r[t],N[r.charCodeAt(t)]=t;N[45]=62,N[95]=63}function vi(r){wt||zt();var t,e,o,i,s,p,l=r.length;if(l%4>0)throw new Error("Invalid string. Length must be a multiple of 4");s=r[l-2]==="="?2:r[l-1]==="="?1:0,p=new Ai(l*3/4-s),o=s>0?l-4:l;var m=0;for(t=0,e=0;t<o;t+=4,e+=3)i=N[r.charCodeAt(t)]<<18|N[r.charCodeAt(t+1)]<<12|N[r.charCodeAt(t+2)]<<6|N[r.charCodeAt(t+3)],p[m++]=i>>16&255,p[m++]=i>>8&255,p[m++]=i&255;return s===2?(i=N[r.charCodeAt(t)]<<2|N[r.charCodeAt(t+1)]>>4,p[m++]=i&255):s===1&&(i=N[r.charCodeAt(t)]<<10|N[r.charCodeAt(t+1)]<<4|N[r.charCodeAt(t+2)]>>2,p[m++]=i>>8&255,p[m++]=i&255),p}function bi(r){return k[r>>18&63]+k[r>>12&63]+k[r>>6&63]+k[r&63]}function _i(r,t,e){for(var o,i=[],s=t;s<e;s+=3)o=(r[s]<<16)+(r[s+1]<<8)+r[s+2],i.push(bi(o));return i.join("")}function $t(r){wt||zt();for(var t,e=r.length,o=e%3,i="",s=[],p=16383,l=0,m=e-o;l<m;l+=p)s.push(_i(r,l,l+p>m?m:l+p));return o===1?(t=r[e-1],i+=k[t>>2],i+=k[t<<4&63],i+="=="):o===2&&(t=(r[e-2]<<8)+r[e-1],i+=k[t>>10],i+=k[t>>4&63],i+=k[t<<2&63],i+="="),s.push(i),s.join("")}function Ye(){return f.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function j(r,t){if(Ye()<t)throw new RangeError("Invalid typed array length");return f.TYPED_ARRAY_SUPPORT?(r=new Uint8Array(t),r.__proto__=f.prototype):(r===null&&(r=new f(t)),r.length=t),r}function f(r,t,e){if(!f.TYPED_ARRAY_SUPPORT&&!(this instanceof f))return new f(r,t,e);if(typeof r=="number"){if(typeof t=="string")throw new Error("If encoding is specified then the first argument must be a string");return gt(this,r)}return Gt(this,r,t,e)}function Gt(r,t,e,o){if(typeof t=="number")throw new TypeError('"value" argument must not be a number');return typeof ArrayBuffer!="undefined"&&t instanceof ArrayBuffer?Si(r,t,e,o):typeof t=="string"?Ii(r,t,e):Li(r,t)}function qt(r){if(typeof r!="number")throw new TypeError('"size" argument must be a number');if(r<0)throw new RangeError('"size" argument must not be negative')}function Ei(r,t,e,o){return qt(t),t<=0?j(r,t):e!==void 0?typeof o=="string"?j(r,t).fill(e,o):j(r,t).fill(e):j(r,t)}function gt(r,t){if(qt(t),r=j(r,t<0?0:Tt(t)|0),!f.TYPED_ARRAY_SUPPORT)for(var e=0;e<t;++e)r[e]=0;return r}function Ii(r,t,e){if((typeof e!="string"||e==="")&&(e="utf8"),!f.isEncoding(e))throw new TypeError('"encoding" must be a valid string encoding');var o=Ht(t,e)|0;r=j(r,o);var i=r.write(t,e);return i!==o&&(r=r.slice(0,i)),r}function yt(r,t){var e=t.length<0?0:Tt(t.length)|0;r=j(r,e);for(var o=0;o<e;o+=1)r[o]=t[o]&255;return r}function Si(r,t,e,o){if(t.byteLength,e<0||t.byteLength<e)throw new RangeError("'offset' is out of bounds");if(t.byteLength<e+(o||0))throw new RangeError("'length' is out of bounds");return e===void 0&&o===void 0?t=new Uint8Array(t):o===void 0?t=new Uint8Array(t,e):t=new Uint8Array(t,e,o),f.TYPED_ARRAY_SUPPORT?(r=t,r.__proto__=f.prototype):r=yt(r,t),r}function Li(r,t){if(M(t)){var e=Tt(t.length)|0;return r=j(r,e),r.length===0||t.copy(r,0,0,e),r}if(t){if(typeof ArrayBuffer!="undefined"&&t.buffer instanceof ArrayBuffer||"length"in t)return typeof t.length!="number"||Hi(t.length)?j(r,0):yt(r,t);if(t.type==="Buffer"&&Array.isArray(t.data))return yt(r,t.data)}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}function Tt(r){if(r>=Ye())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+Ye().toString(16)+" bytes");return r|0}function M(r){return!!(r!=null&&r._isBuffer)}function Ht(r,t){if(M(r))return r.length;if(typeof ArrayBuffer!="undefined"&&typeof ArrayBuffer.isView=="function"&&(ArrayBuffer.isView(r)||r instanceof ArrayBuffer))return r.byteLength;typeof r!="string"&&(r=""+r);var e=r.length;if(e===0)return 0;for(var o=!1;;)switch(t){case"ascii":case"latin1":case"binary":return e;case"utf8":case"utf-8":case void 0:return ze(r).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return e*2;case"hex":return e>>>1;case"base64":return er(r).length;default:if(o)return ze(r).length;t=(""+t).toLowerCase(),o=!0}}function Ni(r,t,e){var o=!1;if((t===void 0||t<0)&&(t=0),t>this.length||((e===void 0||e>this.length)&&(e=this.length),e<=0)||(e>>>=0,t>>>=0,e<=t))return"";for(r||(r="utf8");;)switch(r){case"hex":return Fi(this,t,e);case"utf8":case"utf-8":return Jt(this,t,e);case"ascii":return Ui(this,t,e);case"latin1":case"binary":return Di(this,t,e);case"base64":return ki(this,t,e);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ji(this,t,e);default:if(o)throw new TypeError("Unknown encoding: "+r);r=(r+"").toLowerCase(),o=!0}}function me(r,t,e){var o=r[t];r[t]=r[e],r[e]=o}function Vt(r,t,e,o,i){if(r.length===0)return-1;if(typeof e=="string"?(o=e,e=0):e>2147483647?e=2147483647:e<-2147483648&&(e=-2147483648),e=+e,isNaN(e)&&(e=i?0:r.length-1),e<0&&(e=r.length+e),e>=r.length){if(i)return-1;e=r.length-1}else if(e<0)if(i)e=0;else return-1;if(typeof t=="string"&&(t=f.from(t,o)),M(t))return t.length===0?-1:Wt(r,t,e,o,i);if(typeof t=="number")return t=t&255,f.TYPED_ARRAY_SUPPORT&&typeof Uint8Array.prototype.indexOf=="function"?i?Uint8Array.prototype.indexOf.call(r,t,e):Uint8Array.prototype.lastIndexOf.call(r,t,e):Wt(r,[t],e,o,i);throw new TypeError("val must be string, number or Buffer")}function Wt(r,t,e,o,i){var s=1,p=r.length,l=t.length;if(o!==void 0&&(o=String(o).toLowerCase(),o==="ucs2"||o==="ucs-2"||o==="utf16le"||o==="utf-16le")){if(r.length<2||t.length<2)return-1;s=2,p/=2,l/=2,e/=2}function m(T,A){return s===1?T[A]:T.readUInt16BE(A*s)}var d;if(i){var h=-1;for(d=e;d<p;d++)if(m(r,d)===m(t,h===-1?0:d-h)){if(h===-1&&(h=d),d-h+1===l)return h*s}else h!==-1&&(d-=d-h),h=-1}else for(e+l>p&&(e=p-l),d=e;d>=0;d--){for(var x=!0,w=0;w<l;w++)if(m(r,d+w)!==m(t,w)){x=!1;break}if(x)return d}return-1}function Ci(r,t,e,o){e=Number(e)||0;var i=r.length-e;o?(o=Number(o),o>i&&(o=i)):o=i;var s=t.length;if(s%2!==0)throw new TypeError("Invalid hex string");o>s/2&&(o=s/2);for(var p=0;p<o;++p){var l=parseInt(t.substr(p*2,2),16);if(isNaN(l))return p;r[e+p]=l}return p}function Ri(r,t,e,o){return He(ze(t,r.length-e),r,e,o)}function Kt(r,t,e,o){return He(Gi(t),r,e,o)}function Pi(r,t,e,o){return Kt(r,t,e,o)}function Oi(r,t,e,o){return He(er(t),r,e,o)}function Bi(r,t,e,o){return He(qi(t,r.length-e),r,e,o)}function ki(r,t,e){return t===0&&e===r.length?$t(r):$t(r.slice(t,e))}function Jt(r,t,e){e=Math.min(r.length,e);for(var o=[],i=t;i<e;){var s=r[i],p=null,l=s>239?4:s>223?3:s>191?2:1;if(i+l<=e){var m,d,h,x;switch(l){case 1:s<128&&(p=s);break;case 2:m=r[i+1],(m&192)===128&&(x=(s&31)<<6|m&63,x>127&&(p=x));break;case 3:m=r[i+1],d=r[i+2],(m&192)===128&&(d&192)===128&&(x=(s&15)<<12|(m&63)<<6|d&63,x>2047&&(x<55296||x>57343)&&(p=x));break;case 4:m=r[i+1],d=r[i+2],h=r[i+3],(m&192)===128&&(d&192)===128&&(h&192)===128&&(x=(s&15)<<18|(m&63)<<12|(d&63)<<6|h&63,x>65535&&x<1114112&&(p=x))}}p===null?(p=65533,l=1):p>65535&&(p-=65536,o.push(p>>>10&1023|55296),p=56320|p&1023),o.push(p),i+=l}return Mi(o)}function Mi(r){var t=r.length;if(t<=Yt)return String.fromCharCode.apply(String,r);for(var e="",o=0;o<t;)e+=String.fromCharCode.apply(String,r.slice(o,o+=Yt));return e}function Ui(r,t,e){var o="";e=Math.min(r.length,e);for(var i=t;i<e;++i)o+=String.fromCharCode(r[i]&127);return o}function Di(r,t,e){var o="";e=Math.min(r.length,e);for(var i=t;i<e;++i)o+=String.fromCharCode(r[i]);return o}function Fi(r,t,e){var o=r.length;(!t||t<0)&&(t=0),(!e||e<0||e>o)&&(e=o);for(var i="",s=t;s<e;++s)i+=zi(r[s]);return i}function ji(r,t,e){for(var o=r.slice(t,e),i="",s=0;s<o.length;s+=2)i+=String.fromCharCode(o[s]+o[s+1]*256);return i}function v(r,t,e){if(r%1!==0||r<0)throw new RangeError("offset is not uint");if(r+t>e)throw new RangeError("Trying to access beyond buffer length")}function I(r,t,e,o,i,s){if(!M(r))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||t<s)throw new RangeError('"value" argument is out of bounds');if(e+o>r.length)throw new RangeError("Index out of range")}function Ge(r,t,e,o){t<0&&(t=65535+t+1);for(var i=0,s=Math.min(r.length-e,2);i<s;++i)r[e+i]=(t&255<<8*(o?i:1-i))>>>(o?i:1-i)*8}function qe(r,t,e,o){t<0&&(t=4294967295+t+1);for(var i=0,s=Math.min(r.length-e,4);i<s;++i)r[e+i]=t>>>(o?i:3-i)*8&255}function Qt(r,t,e,o,i,s){if(e+o>r.length)throw new RangeError("Index out of range");if(e<0)throw new RangeError("Index out of range")}function Xt(r,t,e,o,i){return i||Qt(r,t,e,4,34028234663852886e22,-34028234663852886e22),rr(r,t,e,o,23,4),e+4}function Zt(r,t,e,o,i){return i||Qt(r,t,e,8,17976931348623157e292,-17976931348623157e292),rr(r,t,e,o,52,8),e+8}function Wi(r){if(r=Yi(r).replace($i,""),r.length<2)return"";for(;r.length%4!==0;)r=r+"=";return r}function Yi(r){return r.trim?r.trim():r.replace(/^\s+|\s+$/g,"")}function zi(r){return r<16?"0"+r.toString(16):r.toString(16)}function ze(r,t){t=t||1/0;for(var e,o=r.length,i=null,s=[],p=0;p<o;++p){if(e=r.charCodeAt(p),e>55295&&e<57344){if(!i){if(e>56319){(t-=3)>-1&&s.push(239,191,189);continue}else if(p+1===o){(t-=3)>-1&&s.push(239,191,189);continue}i=e;continue}if(e<56320){(t-=3)>-1&&s.push(239,191,189),i=e;continue}e=(i-55296<<10|e-56320)+65536}else i&&(t-=3)>-1&&s.push(239,191,189);if(i=null,e<128){if((t-=1)<0)break;s.push(e)}else if(e<2048){if((t-=2)<0)break;s.push(e>>6|192,e&63|128)}else if(e<65536){if((t-=3)<0)break;s.push(e>>12|224,e>>6&63|128,e&63|128)}else if(e<1114112){if((t-=4)<0)break;s.push(e>>18|240,e>>12&63|128,e>>6&63|128,e&63|128)}else throw new Error("Invalid code point")}return s}function Gi(r){for(var t=[],e=0;e<r.length;++e)t.push(r.charCodeAt(e)&255);return t}function qi(r,t){for(var e,o,i,s=[],p=0;p<r.length&&!((t-=2)<0);++p)e=r.charCodeAt(p),o=e>>8,i=e%256,s.push(i),s.push(o);return s}function er(r){return vi(Wi(r))}function He(r,t,e,o){for(var i=0;i<o&&!(i+e>=t.length||i>=r.length);++i)t[i+e]=r[i];return i}function Hi(r){return r!==r}function Vi(r){return r!=null&&(!!r._isBuffer||tr(r)||Ki(r))}function tr(r){return!!r.constructor&&typeof r.constructor.isBuffer=="function"&&r.constructor.isBuffer(r)}function Ki(r){return typeof r.readFloatLE=="function"&&typeof r.slice=="function"&&tr(r.slice(0,0))}function Ve(r,t,e,o,i){var s,p,l=i*8-o-1,m=(1<<l)-1,d=m>>1,h=-7,x=e?i-1:0,w=e?-1:1,T=r[t+x];for(x+=w,s=T&(1<<-h)-1,T>>=-h,h+=l;h>0;s=s*256+r[t+x],x+=w,h-=8);for(p=s&(1<<-h)-1,s>>=-h,h+=o;h>0;p=p*256+r[t+x],x+=w,h-=8);if(s===0)s=1-d;else{if(s===m)return p?NaN:(T?-1:1)*(1/0);p=p+Math.pow(2,o),s=s-d}return(T?-1:1)*p*Math.pow(2,s-o)}function rr(r,t,e,o,i,s){var p,l,m,d=s*8-i-1,h=(1<<d)-1,x=h>>1,w=i===23?Math.pow(2,-24)-Math.pow(2,-77):0,T=o?0:s-1,A=o?1:-1,S=t<0||t===0&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(l=isNaN(t)?1:0,p=h):(p=Math.floor(Math.log(t)/Math.LN2),t*(m=Math.pow(2,-p))<1&&(p--,m*=2),p+x>=1?t+=w/m:t+=w*Math.pow(2,1-x),t*m>=2&&(p++,m/=2),p+x>=h?(l=0,p=h):p+x>=1?(l=(t*m-1)*Math.pow(2,i),p=p+x):(l=t*Math.pow(2,x-1)*Math.pow(2,i),p=0));i>=8;r[e+T]=l&255,T+=A,l/=256,i-=8);for(p=p<<i|l,d+=i;d>0;r[e+T]=p&255,T+=A,p/=256,d-=8);r[e+T-A]|=S*128}var k,N,Ai,wt,Yt,$i,or=xt(()=>{"use strict";n();a();k=[],N=[],Ai=typeof Uint8Array!="undefined"?Uint8Array:Array,wt=!1;f.TYPED_ARRAY_SUPPORT=globalThis.TYPED_ARRAY_SUPPORT!==void 0?globalThis.TYPED_ARRAY_SUPPORT:!0;f.poolSize=8192;f._augment=function(r){return r.__proto__=f.prototype,r};f.from=function(r,t,e){return Gt(null,r,t,e)};f.kMaxLength=Ye();f.TYPED_ARRAY_SUPPORT&&(f.prototype.__proto__=Uint8Array.prototype,f.__proto__=Uint8Array,typeof Symbol!="undefined"&&Symbol.species&&f[Symbol.species]);f.alloc=function(r,t,e){return Ei(null,r,t,e)};f.allocUnsafe=function(r){return gt(null,r)};f.allocUnsafeSlow=function(r){return gt(null,r)};f.isBuffer=Vi;f.compare=function(t,e){if(!M(t)||!M(e))throw new TypeError("Arguments must be Buffers");if(t===e)return 0;for(var o=t.length,i=e.length,s=0,p=Math.min(o,i);s<p;++s)if(t[s]!==e[s]){o=t[s],i=e[s];break}return o<i?-1:i<o?1:0};f.isEncoding=function(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}};f.concat=function(t,e){if(!Array.isArray(t))throw new TypeError('"list" argument must be an Array of Buffers');if(t.length===0)return f.alloc(0);var o;if(e===void 0)for(e=0,o=0;o<t.length;++o)e+=t[o].length;var i=f.allocUnsafe(e),s=0;for(o=0;o<t.length;++o){var p=t[o];if(!M(p))throw new TypeError('"list" argument must be an Array of Buffers');p.copy(i,s),s+=p.length}return i};f.byteLength=Ht;f.prototype._isBuffer=!0;f.prototype.swap16=function(){var t=this.length;if(t%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var e=0;e<t;e+=2)me(this,e,e+1);return this};f.prototype.swap32=function(){var t=this.length;if(t%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var e=0;e<t;e+=4)me(this,e,e+3),me(this,e+1,e+2);return this};f.prototype.swap64=function(){var t=this.length;if(t%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var e=0;e<t;e+=8)me(this,e,e+7),me(this,e+1,e+6),me(this,e+2,e+5),me(this,e+3,e+4);return this};f.prototype.toString=function(){var t=this.length|0;return t===0?"":arguments.length===0?Jt(this,0,t):Ni.apply(this,arguments)};f.prototype.equals=function(t){if(!M(t))throw new TypeError("Argument must be a Buffer");return this===t?!0:f.compare(this,t)===0};f.prototype.compare=function(t,e,o,i,s){if(!M(t))throw new TypeError("Argument must be a Buffer");if(e===void 0&&(e=0),o===void 0&&(o=t?t.length:0),i===void 0&&(i=0),s===void 0&&(s=this.length),e<0||o>t.length||i<0||s>this.length)throw new RangeError("out of range index");if(i>=s&&e>=o)return 0;if(i>=s)return-1;if(e>=o)return 1;if(e>>>=0,o>>>=0,i>>>=0,s>>>=0,this===t)return 0;for(var p=s-i,l=o-e,m=Math.min(p,l),d=this.slice(i,s),h=t.slice(e,o),x=0;x<m;++x)if(d[x]!==h[x]){p=d[x],l=h[x];break}return p<l?-1:l<p?1:0};f.prototype.includes=function(t,e,o){return this.indexOf(t,e,o)!==-1};f.prototype.indexOf=function(t,e,o){return Vt(this,t,e,o,!0)};f.prototype.lastIndexOf=function(t,e,o){return Vt(this,t,e,o,!1)};f.prototype.write=function(t,e,o,i){if(e===void 0)i="utf8",o=this.length,e=0;else if(o===void 0&&typeof e=="string")i=e,o=this.length,e=0;else if(isFinite(e))e=e|0,isFinite(o)?(o=o|0,i===void 0&&(i="utf8")):(i=o,o=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var s=this.length-e;if((o===void 0||o>s)&&(o=s),t.length>0&&(o<0||e<0)||e>this.length)throw new RangeError("Attempt to write outside buffer bounds");i||(i="utf8");for(var p=!1;;)switch(i){case"hex":return Ci(this,t,e,o);case"utf8":case"utf-8":return Ri(this,t,e,o);case"ascii":return Kt(this,t,e,o);case"latin1":case"binary":return Pi(this,t,e,o);case"base64":return Oi(this,t,e,o);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Bi(this,t,e,o);default:if(p)throw new TypeError("Unknown encoding: "+i);i=(""+i).toLowerCase(),p=!0}};f.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};Yt=4096;f.prototype.slice=function(t,e){var o=this.length;t=~~t,e=e===void 0?o:~~e,t<0?(t+=o,t<0&&(t=0)):t>o&&(t=o),e<0?(e+=o,e<0&&(e=0)):e>o&&(e=o),e<t&&(e=t);var i;if(f.TYPED_ARRAY_SUPPORT)i=this.subarray(t,e),i.__proto__=f.prototype;else{var s=e-t;i=new f(s,void 0);for(var p=0;p<s;++p)i[p]=this[p+t]}return i};f.prototype.readUIntLE=function(t,e,o){t=t|0,e=e|0,o||v(t,e,this.length);for(var i=this[t],s=1,p=0;++p<e&&(s*=256);)i+=this[t+p]*s;return i};f.prototype.readUIntBE=function(t,e,o){t=t|0,e=e|0,o||v(t,e,this.length);for(var i=this[t+--e],s=1;e>0&&(s*=256);)i+=this[t+--e]*s;return i};f.prototype.readUInt8=function(t,e){return e||v(t,1,this.length),this[t]};f.prototype.readUInt16LE=function(t,e){return e||v(t,2,this.length),this[t]|this[t+1]<<8};f.prototype.readUInt16BE=function(t,e){return e||v(t,2,this.length),this[t]<<8|this[t+1]};f.prototype.readUInt32LE=function(t,e){return e||v(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+this[t+3]*16777216};f.prototype.readUInt32BE=function(t,e){return e||v(t,4,this.length),this[t]*16777216+(this[t+1]<<16|this[t+2]<<8|this[t+3])};f.prototype.readIntLE=function(t,e,o){t=t|0,e=e|0,o||v(t,e,this.length);for(var i=this[t],s=1,p=0;++p<e&&(s*=256);)i+=this[t+p]*s;return s*=128,i>=s&&(i-=Math.pow(2,8*e)),i};f.prototype.readIntBE=function(t,e,o){t=t|0,e=e|0,o||v(t,e,this.length);for(var i=e,s=1,p=this[t+--i];i>0&&(s*=256);)p+=this[t+--i]*s;return s*=128,p>=s&&(p-=Math.pow(2,8*e)),p};f.prototype.readInt8=function(t,e){return e||v(t,1,this.length),this[t]&128?(255-this[t]+1)*-1:this[t]};f.prototype.readInt16LE=function(t,e){e||v(t,2,this.length);var o=this[t]|this[t+1]<<8;return o&32768?o|4294901760:o};f.prototype.readInt16BE=function(t,e){e||v(t,2,this.length);var o=this[t+1]|this[t]<<8;return o&32768?o|4294901760:o};f.prototype.readInt32LE=function(t,e){return e||v(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24};f.prototype.readInt32BE=function(t,e){return e||v(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]};f.prototype.readFloatLE=function(t,e){return e||v(t,4,this.length),Ve(this,t,!0,23,4)};f.prototype.readFloatBE=function(t,e){return e||v(t,4,this.length),Ve(this,t,!1,23,4)};f.prototype.readDoubleLE=function(t,e){return e||v(t,8,this.length),Ve(this,t,!0,52,8)};f.prototype.readDoubleBE=function(t,e){return e||v(t,8,this.length),Ve(this,t,!1,52,8)};f.prototype.writeUIntLE=function(t,e,o,i){if(t=+t,e=e|0,o=o|0,!i){var s=Math.pow(2,8*o)-1;I(this,t,e,o,s,0)}var p=1,l=0;for(this[e]=t&255;++l<o&&(p*=256);)this[e+l]=t/p&255;return e+o};f.prototype.writeUIntBE=function(t,e,o,i){if(t=+t,e=e|0,o=o|0,!i){var s=Math.pow(2,8*o)-1;I(this,t,e,o,s,0)}var p=o-1,l=1;for(this[e+p]=t&255;--p>=0&&(l*=256);)this[e+p]=t/l&255;return e+o};f.prototype.writeUInt8=function(t,e,o){return t=+t,e=e|0,o||I(this,t,e,1,255,0),f.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[e]=t&255,e+1};f.prototype.writeUInt16LE=function(t,e,o){return t=+t,e=e|0,o||I(this,t,e,2,65535,0),f.TYPED_ARRAY_SUPPORT?(this[e]=t&255,this[e+1]=t>>>8):Ge(this,t,e,!0),e+2};f.prototype.writeUInt16BE=function(t,e,o){return t=+t,e=e|0,o||I(this,t,e,2,65535,0),f.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=t&255):Ge(this,t,e,!1),e+2};f.prototype.writeUInt32LE=function(t,e,o){return t=+t,e=e|0,o||I(this,t,e,4,4294967295,0),f.TYPED_ARRAY_SUPPORT?(this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=t&255):qe(this,t,e,!0),e+4};f.prototype.writeUInt32BE=function(t,e,o){return t=+t,e=e|0,o||I(this,t,e,4,4294967295,0),f.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=t&255):qe(this,t,e,!1),e+4};f.prototype.writeIntLE=function(t,e,o,i){if(t=+t,e=e|0,!i){var s=Math.pow(2,8*o-1);I(this,t,e,o,s-1,-s)}var p=0,l=1,m=0;for(this[e]=t&255;++p<o&&(l*=256);)t<0&&m===0&&this[e+p-1]!==0&&(m=1),this[e+p]=(t/l>>0)-m&255;return e+o};f.prototype.writeIntBE=function(t,e,o,i){if(t=+t,e=e|0,!i){var s=Math.pow(2,8*o-1);I(this,t,e,o,s-1,-s)}var p=o-1,l=1,m=0;for(this[e+p]=t&255;--p>=0&&(l*=256);)t<0&&m===0&&this[e+p+1]!==0&&(m=1),this[e+p]=(t/l>>0)-m&255;return e+o};f.prototype.writeInt8=function(t,e,o){return t=+t,e=e|0,o||I(this,t,e,1,127,-128),f.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[e]=t&255,e+1};f.prototype.writeInt16LE=function(t,e,o){return t=+t,e=e|0,o||I(this,t,e,2,32767,-32768),f.TYPED_ARRAY_SUPPORT?(this[e]=t&255,this[e+1]=t>>>8):Ge(this,t,e,!0),e+2};f.prototype.writeInt16BE=function(t,e,o){return t=+t,e=e|0,o||I(this,t,e,2,32767,-32768),f.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=t&255):Ge(this,t,e,!1),e+2};f.prototype.writeInt32LE=function(t,e,o){return t=+t,e=e|0,o||I(this,t,e,4,2147483647,-2147483648),f.TYPED_ARRAY_SUPPORT?(this[e]=t&255,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24):qe(this,t,e,!0),e+4};f.prototype.writeInt32BE=function(t,e,o){return t=+t,e=e|0,o||I(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),f.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=t&255):qe(this,t,e,!1),e+4};f.prototype.writeFloatLE=function(t,e,o){return Xt(this,t,e,!0,o)};f.prototype.writeFloatBE=function(t,e,o){return Xt(this,t,e,!1,o)};f.prototype.writeDoubleLE=function(t,e,o){return Zt(this,t,e,!0,o)};f.prototype.writeDoubleBE=function(t,e,o){return Zt(this,t,e,!1,o)};f.prototype.copy=function(t,e,o,i){if(o||(o=0),!i&&i!==0&&(i=this.length),e>=t.length&&(e=t.length),e||(e=0),i>0&&i<o&&(i=o),i===o||t.length===0||this.length===0)return 0;if(e<0)throw new RangeError("targetStart out of bounds");if(o<0||o>=this.length)throw new RangeError("sourceStart out of bounds");if(i<0)throw new RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),t.length-e<i-o&&(i=t.length-e+o);var s=i-o,p;if(this===t&&o<e&&e<i)for(p=s-1;p>=0;--p)t[p+e]=this[p+o];else if(s<1e3||!f.TYPED_ARRAY_SUPPORT)for(p=0;p<s;++p)t[p+e]=this[p+o];else Uint8Array.prototype.set.call(t,this.subarray(o,o+s),e);return s};f.prototype.fill=function(t,e,o,i){if(typeof t=="string"){if(typeof e=="string"?(i=e,e=0,o=this.length):typeof o=="string"&&(i=o,o=this.length),t.length===1){var s=t.charCodeAt(0);s<256&&(t=s)}if(i!==void 0&&typeof i!="string")throw new TypeError("encoding must be a string");if(typeof i=="string"&&!f.isEncoding(i))throw new TypeError("Unknown encoding: "+i)}else typeof t=="number"&&(t=t&255);if(e<0||this.length<e||this.length<o)throw new RangeError("Out of range index");if(o<=e)return this;e=e>>>0,o=o===void 0?this.length:o>>>0,t||(t=0);var p;if(typeof t=="number")for(p=e;p<o;++p)this[p]=t;else{var l=M(t)?t:ze(new f(t,i).toString()),m=l.length;for(p=0;p<o-e;++p)this[p+e]=l[p%m]}return this};$i=/[^+\/0-9A-Za-z-_]/g});var a=xt(()=>{"use strict";or()});var Zf={};Bt(Zf,{FilePropertyMapper:()=>Ct});module.exports=Ho(Zf);n();a();n();a();n();a();function $(r){throw new Error("Unexpected value: "+JSON.stringify(r))}n();a();n();a();n();a();n();a();n();a();var Ji=typeof globalThis=="object"&&globalThis&&globalThis.Object===Object&&globalThis,Ke=Ji;var Qi=typeof self=="object"&&self&&self.Object===Object&&self,Xi=Ke||Qi||Function("return this")(),b=Xi;var Zi=b.Symbol,W=Zi;n();a();var ir=Object.prototype,en=ir.hasOwnProperty,tn=ir.toString,Pe=W?W.toStringTag:void 0;function rn(r){var t=en.call(r,Pe),e=r[Pe];try{r[Pe]=void 0;var o=!0}catch(s){}var i=tn.call(r);return o&&(t?r[Pe]=e:delete r[Pe]),i}var nr=rn;n();a();var on=Object.prototype,nn=on.toString;function an(r){return nn.call(r)}var ar=an;var sn="[object Null]",fn="[object Undefined]",sr=W?W.toStringTag:void 0;function pn(r){return r==null?r===void 0?fn:sn:sr&&sr in Object(r)?nr(r):ar(r)}var Y=pn;n();a();function un(r){return r!=null&&typeof r=="object"}var z=un;n();a();var ln=Array.isArray,de=ln;n();a();function cn(r){var t=typeof r;return r!=null&&(t=="object"||t=="function")}var Je=cn;n();a();n();a();n();a();n();a();var mn="[object AsyncFunction]",dn="[object Function]",hn="[object GeneratorFunction]",xn="[object Proxy]";function yn(r){if(!Je(r))return!1;var t=Y(r);return t==dn||t==hn||t==mn||t==xn}var Qe=yn;n();a();n();a();var wn=b["__core-js_shared__"],Xe=wn;var fr=(function(){var r=/[^.]+$/.exec(Xe&&Xe.keys&&Xe.keys.IE_PROTO||"");return r?"Symbol(src)_1."+r:""})();function gn(r){return!!fr&&fr in r}var pr=gn;n();a();var Tn=Function.prototype,An=Tn.toString;function vn(r){if(r!=null){try{return An.call(r)}catch(t){}try{return r+""}catch(t){}}return""}var G=vn;var bn=/[\\^$.*+?()[\]{}|]/g,_n=/^\[object .+?Constructor\]$/,En=Function.prototype,In=Object.prototype,Sn=En.toString,Ln=In.hasOwnProperty,Nn=RegExp("^"+Sn.call(Ln).replace(bn,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Cn(r){if(!Je(r)||pr(r))return!1;var t=Qe(r)?Nn:_n;return t.test(G(r))}var ur=Cn;n();a();function Rn(r,t){return r==null?void 0:r[t]}var lr=Rn;function Pn(r,t){var e=lr(r,t);return ur(e)?e:void 0}var C=Pn;var On=C(b,"WeakMap"),Ze=On;n();a();function Bn(){}var cr=Bn;n();a();n();a();n();a();function kn(r,t,e,o){for(var i=r.length,s=e+(o?1:-1);o?s--:++s<i;)if(t(r[s],s,r))return s;return-1}var mr=kn;n();a();function Mn(r){return r!==r}var dr=Mn;n();a();function Un(r,t,e){for(var o=e-1,i=r.length;++o<i;)if(r[o]===t)return o;return-1}var hr=Un;function Dn(r,t,e){return t===t?hr(r,t,e):mr(r,dr,e)}var xr=Dn;function Fn(r,t){var e=r==null?0:r.length;return!!e&&xr(r,t,0)>-1}var yr=Fn;n();a();var jn=9007199254740991,$n=/^(?:0|[1-9]\d*)$/;function Wn(r,t){var e=typeof r;return t=t==null?jn:t,!!t&&(e=="number"||e!="symbol"&&$n.test(r))&&r>-1&&r%1==0&&r<t}var wr=Wn;n();a();function Yn(r,t){return r===t||r!==r&&t!==t}var et=Yn;n();a();n();a();var zn=9007199254740991;function Gn(r){return typeof r=="number"&&r>-1&&r%1==0&&r<=zn}var tt=Gn;function qn(r){return r!=null&&tt(r.length)&&!Qe(r)}var gr=qn;n();a();var Hn=Object.prototype;function Vn(r){var t=r&&r.constructor,e=typeof t=="function"&&t.prototype||Hn;return r===e}var Tr=Vn;n();a();n();a();n();a();function Kn(r,t){for(var e=-1,o=Array(r);++e<r;)o[e]=t(e);return o}var Ar=Kn;n();a();n();a();var Jn="[object Arguments]";function Qn(r){return z(r)&&Y(r)==Jn}var At=Qn;var vr=Object.prototype,Xn=vr.hasOwnProperty,Zn=vr.propertyIsEnumerable,ea=At((function(){return arguments})())?At:function(r){return z(r)&&Xn.call(r,"callee")&&!Zn.call(r,"callee")},br=ea;n();a();n();a();function ta(){return!1}var _r=ta;var Sr=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Er=Sr&&typeof module=="object"&&module&&!module.nodeType&&module,ra=Er&&Er.exports===Sr,Ir=ra?b.Buffer:void 0,oa=Ir?Ir.isBuffer:void 0,ia=oa||_r,Oe=ia;n();a();n();a();var na="[object Arguments]",aa="[object Array]",sa="[object Boolean]",fa="[object Date]",pa="[object Error]",ua="[object Function]",la="[object Map]",ca="[object Number]",ma="[object Object]",da="[object RegExp]",ha="[object Set]",xa="[object String]",ya="[object WeakMap]",wa="[object ArrayBuffer]",ga="[object DataView]",Ta="[object Float32Array]",Aa="[object Float64Array]",va="[object Int8Array]",ba="[object Int16Array]",_a="[object Int32Array]",Ea="[object Uint8Array]",Ia="[object Uint8ClampedArray]",Sa="[object Uint16Array]",La="[object Uint32Array]",g={};g[Ta]=g[Aa]=g[va]=g[ba]=g[_a]=g[Ea]=g[Ia]=g[Sa]=g[La]=!0;g[na]=g[aa]=g[wa]=g[sa]=g[ga]=g[fa]=g[pa]=g[ua]=g[la]=g[ca]=g[ma]=g[da]=g[ha]=g[xa]=g[ya]=!1;function Na(r){return z(r)&&tt(r.length)&&!!g[Y(r)]}var Lr=Na;n();a();function Ca(r){return function(t){return r(t)}}var Nr=Ca;n();a();var Cr=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Be=Cr&&typeof module=="object"&&module&&!module.nodeType&&module,Ra=Be&&Be.exports===Cr,vt=Ra&&Ke.process,Pa=(function(){try{var r=Be&&Be.require&&Be.require("util").types;return r||vt&&vt.binding&&vt.binding("util")}catch(t){}})(),bt=Pa;var Rr=bt&&bt.isTypedArray,Oa=Rr?Nr(Rr):Lr,rt=Oa;var Ba=Object.prototype,ka=Ba.hasOwnProperty;function Ma(r,t){var e=de(r),o=!e&&br(r),i=!e&&!o&&Oe(r),s=!e&&!o&&!i&&rt(r),p=e||o||i||s,l=p?Ar(r.length,String):[],m=l.length;for(var d in r)(t||ka.call(r,d))&&!(p&&(d=="length"||i&&(d=="offset"||d=="parent")||s&&(d=="buffer"||d=="byteLength"||d=="byteOffset")||wr(d,m)))&&l.push(d);return l}var Pr=Ma;n();a();n();a();n();a();function Ua(r,t){return function(e){return r(t(e))}}var Or=Ua;var Da=Or(Object.keys,Object),Br=Da;var Fa=Object.prototype,ja=Fa.hasOwnProperty;function $a(r){if(!Tr(r))return Br(r);var t=[];for(var e in Object(r))ja.call(r,e)&&e!="constructor"&&t.push(e);return t}var kr=$a;function Wa(r){return gr(r)?Pr(r):kr(r)}var Mr=Wa;n();a();n();a();n();a();n();a();n();a();var Ya=C(Object,"create"),q=Ya;function za(){this.__data__=q?q(null):{},this.size=0}var Ur=za;n();a();function Ga(r){var t=this.has(r)&&delete this.__data__[r];return this.size-=t?1:0,t}var Dr=Ga;n();a();var qa="__lodash_hash_undefined__",Ha=Object.prototype,Va=Ha.hasOwnProperty;function Ka(r){var t=this.__data__;if(q){var e=t[r];return e===qa?void 0:e}return Va.call(t,r)?t[r]:void 0}var Fr=Ka;n();a();var Ja=Object.prototype,Qa=Ja.hasOwnProperty;function Xa(r){var t=this.__data__;return q?t[r]!==void 0:Qa.call(t,r)}var jr=Xa;n();a();var Za="__lodash_hash_undefined__";function es(r,t){var e=this.__data__;return this.size+=this.has(r)?0:1,e[r]=q&&t===void 0?Za:t,this}var $r=es;function Ie(r){var t=-1,e=r==null?0:r.length;for(this.clear();++t<e;){var o=r[t];this.set(o[0],o[1])}}Ie.prototype.clear=Ur;Ie.prototype.delete=Dr;Ie.prototype.get=Fr;Ie.prototype.has=jr;Ie.prototype.set=$r;var _t=Ie;n();a();n();a();function ts(){this.__data__=[],this.size=0}var Wr=ts;n();a();n();a();function rs(r,t){for(var e=r.length;e--;)if(et(r[e][0],t))return e;return-1}var te=rs;var os=Array.prototype,is=os.splice;function ns(r){var t=this.__data__,e=te(t,r);if(e<0)return!1;var o=t.length-1;return e==o?t.pop():is.call(t,e,1),--this.size,!0}var Yr=ns;n();a();function as(r){var t=this.__data__,e=te(t,r);return e<0?void 0:t[e][1]}var zr=as;n();a();function ss(r){return te(this.__data__,r)>-1}var Gr=ss;n();a();function fs(r,t){var e=this.__data__,o=te(e,r);return o<0?(++this.size,e.push([r,t])):e[o][1]=t,this}var qr=fs;function Se(r){var t=-1,e=r==null?0:r.length;for(this.clear();++t<e;){var o=r[t];this.set(o[0],o[1])}}Se.prototype.clear=Wr;Se.prototype.delete=Yr;Se.prototype.get=zr;Se.prototype.has=Gr;Se.prototype.set=qr;var re=Se;n();a();var ps=C(b,"Map"),oe=ps;function us(){this.size=0,this.__data__={hash:new _t,map:new(oe||re),string:new _t}}var Hr=us;n();a();n();a();n();a();function ls(r){var t=typeof r;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?r!=="__proto__":r===null}var Vr=ls;function cs(r,t){var e=r.__data__;return Vr(t)?e[typeof t=="string"?"string":"hash"]:e.map}var ie=cs;function ms(r){var t=ie(this,r).delete(r);return this.size-=t?1:0,t}var Kr=ms;n();a();function ds(r){return ie(this,r).get(r)}var Jr=ds;n();a();function hs(r){return ie(this,r).has(r)}var Qr=hs;n();a();function xs(r,t){var e=ie(this,r),o=e.size;return e.set(r,t),this.size+=e.size==o?0:1,this}var Xr=xs;function Le(r){var t=-1,e=r==null?0:r.length;for(this.clear();++t<e;){var o=r[t];this.set(o[0],o[1])}}Le.prototype.clear=Hr;Le.prototype.delete=Kr;Le.prototype.get=Jr;Le.prototype.has=Qr;Le.prototype.set=Xr;var ot=Le;n();a();function ys(r,t){for(var e=-1,o=t.length,i=r.length;++e<o;)r[i+e]=t[e];return r}var Zr=ys;n();a();n();a();function ws(){this.__data__=new re,this.size=0}var eo=ws;n();a();function gs(r){var t=this.__data__,e=t.delete(r);return this.size=t.size,e}var to=gs;n();a();function Ts(r){return this.__data__.get(r)}var ro=Ts;n();a();function As(r){return this.__data__.has(r)}var oo=As;n();a();var vs=200;function bs(r,t){var e=this.__data__;if(e instanceof re){var o=e.__data__;if(!oe||o.length<vs-1)return o.push([r,t]),this.size=++e.size,this;e=this.__data__=new ot(o)}return e.set(r,t),this.size=e.size,this}var io=bs;function Ne(r){var t=this.__data__=new re(r);this.size=t.size}Ne.prototype.clear=eo;Ne.prototype.delete=to;Ne.prototype.get=ro;Ne.prototype.has=oo;Ne.prototype.set=io;var it=Ne;n();a();n();a();function _s(r,t){for(var e=-1,o=r==null?0:r.length,i=0,s=[];++e<o;){var p=r[e];t(p,e,r)&&(s[i++]=p)}return s}var no=_s;n();a();function Es(){return[]}var ao=Es;var Is=Object.prototype,Ss=Is.propertyIsEnumerable,so=Object.getOwnPropertySymbols,Ls=so?function(r){return r==null?[]:(r=Object(r),no(so(r),function(t){return Ss.call(r,t)}))}:ao,fo=Ls;n();a();n();a();function Ns(r,t,e){var o=t(r);return de(r)?o:Zr(o,e(r))}var po=Ns;function Cs(r){return po(r,Mr,fo)}var Et=Cs;n();a();n();a();var Rs=C(b,"DataView"),nt=Rs;n();a();var Ps=C(b,"Promise"),at=Ps;n();a();var Os=C(b,"Set"),ne=Os;var uo="[object Map]",Bs="[object Object]",lo="[object Promise]",co="[object Set]",mo="[object WeakMap]",ho="[object DataView]",ks=G(nt),Ms=G(oe),Us=G(at),Ds=G(ne),Fs=G(Ze),he=Y;(nt&&he(new nt(new ArrayBuffer(1)))!=ho||oe&&he(new oe)!=uo||at&&he(at.resolve())!=lo||ne&&he(new ne)!=co||Ze&&he(new Ze)!=mo)&&(he=function(r){var t=Y(r),e=t==Bs?r.constructor:void 0,o=e?G(e):"";if(o)switch(o){case ks:return ho;case Ms:return uo;case Us:return lo;case Ds:return co;case Fs:return mo}return t});var It=he;n();a();var js=b.Uint8Array,St=js;n();a();n();a();n();a();n();a();n();a();var $s="__lodash_hash_undefined__";function Ws(r){return this.__data__.set(r,$s),this}var xo=Ws;n();a();function Ys(r){return this.__data__.has(r)}var yo=Ys;function st(r){var t=-1,e=r==null?0:r.length;for(this.__data__=new ot;++t<e;)this.add(r[t])}st.prototype.add=st.prototype.push=xo;st.prototype.has=yo;var ft=st;n();a();function zs(r,t){for(var e=-1,o=r==null?0:r.length;++e<o;)if(t(r[e],e,r))return!0;return!1}var wo=zs;n();a();function Gs(r,t){return r.has(t)}var pt=Gs;var qs=1,Hs=2;function Vs(r,t,e,o,i,s){var p=e&qs,l=r.length,m=t.length;if(l!=m&&!(p&&m>l))return!1;var d=s.get(r),h=s.get(t);if(d&&h)return d==t&&h==r;var x=-1,w=!0,T=e&Hs?new ft:void 0;for(s.set(r,t),s.set(t,r);++x<l;){var A=r[x],S=t[x];if(o)var X=p?o(S,A,x,t,r,s):o(A,S,x,r,t,s);if(X!==void 0){if(X)continue;w=!1;break}if(T){if(!wo(t,function(pe,ue){if(!pt(T,ue)&&(A===pe||i(A,pe,e,o,s)))return T.push(ue)})){w=!1;break}}else if(!(A===S||i(A,S,e,o,s))){w=!1;break}}return s.delete(r),s.delete(t),w}var ut=Vs;n();a();n();a();function Ks(r){var t=-1,e=Array(r.size);return r.forEach(function(o,i){e[++t]=[i,o]}),e}var go=Ks;n();a();function Js(r){var t=-1,e=Array(r.size);return r.forEach(function(o){e[++t]=o}),e}var Ce=Js;var Qs=1,Xs=2,Zs="[object Boolean]",ef="[object Date]",tf="[object Error]",rf="[object Map]",of="[object Number]",nf="[object RegExp]",af="[object Set]",sf="[object String]",ff="[object Symbol]",pf="[object ArrayBuffer]",uf="[object DataView]",To=W?W.prototype:void 0,Lt=To?To.valueOf:void 0;function lf(r,t,e,o,i,s,p){switch(e){case uf:if(r.byteLength!=t.byteLength||r.byteOffset!=t.byteOffset)return!1;r=r.buffer,t=t.buffer;case pf:return!(r.byteLength!=t.byteLength||!s(new St(r),new St(t)));case Zs:case ef:case of:return et(+r,+t);case tf:return r.name==t.name&&r.message==t.message;case nf:case sf:return r==t+"";case rf:var l=go;case af:var m=o&Qs;if(l||(l=Ce),r.size!=t.size&&!m)return!1;var d=p.get(r);if(d)return d==t;o|=Xs,p.set(r,t);var h=ut(l(r),l(t),o,i,s,p);return p.delete(r),h;case ff:if(Lt)return Lt.call(r)==Lt.call(t)}return!1}var Ao=lf;n();a();var cf=1,mf=Object.prototype,df=mf.hasOwnProperty;function hf(r,t,e,o,i,s){var p=e&cf,l=Et(r),m=l.length,d=Et(t),h=d.length;if(m!=h&&!p)return!1;for(var x=m;x--;){var w=l[x];if(!(p?w in t:df.call(t,w)))return!1}var T=s.get(r),A=s.get(t);if(T&&A)return T==t&&A==r;var S=!0;s.set(r,t),s.set(t,r);for(var X=p;++x<m;){w=l[x];var pe=r[w],ue=t[w];if(o)var Rt=p?o(ue,pe,w,t,r,s):o(pe,ue,w,r,t,s);if(!(Rt===void 0?pe===ue||i(pe,ue,e,o,s):Rt)){S=!1;break}X||(X=w=="constructor")}if(S&&!X){var Ue=r.constructor,De=t.constructor;Ue!=De&&"constructor"in r&&"constructor"in t&&!(typeof Ue=="function"&&Ue instanceof Ue&&typeof De=="function"&&De instanceof De)&&(S=!1)}return s.delete(r),s.delete(t),S}var vo=hf;var xf=1,bo="[object Arguments]",_o="[object Array]",lt="[object Object]",yf=Object.prototype,Eo=yf.hasOwnProperty;function wf(r,t,e,o,i,s){var p=de(r),l=de(t),m=p?_o:It(r),d=l?_o:It(t);m=m==bo?lt:m,d=d==bo?lt:d;var h=m==lt,x=d==lt,w=m==d;if(w&&Oe(r)){if(!Oe(t))return!1;p=!0,h=!1}if(w&&!h)return s||(s=new it),p||rt(r)?ut(r,t,e,o,i,s):Ao(r,t,m,e,o,i,s);if(!(e&xf)){var T=h&&Eo.call(r,"__wrapped__"),A=x&&Eo.call(t,"__wrapped__");if(T||A){var S=T?r.value():r,X=A?t.value():t;return s||(s=new it),i(S,X,e,o,s)}}return w?(s||(s=new it),vo(r,t,e,o,i,s)):!1}var Io=wf;function So(r,t,e,o,i){return r===t?!0:r==null||t==null||!z(r)&&!z(t)?r!==r&&t!==t:Io(r,t,e,o,So,i)}var Lo=So;n();a();function gf(r,t,e){for(var o=-1,i=r==null?0:r.length;++o<i;)if(e(t,r[o]))return!0;return!1}var No=gf;n();a();function Tf(r,t){return Lo(r,t)}var ct=Tf;n();a();n();a();var Af=1/0,vf=ne&&1/Ce(new ne([,-0]))[1]==Af?function(r){return new ne(r)}:cr,Co=vf;var bf=200;function _f(r,t,e){var o=-1,i=yr,s=r.length,p=!0,l=[],m=l;if(e)p=!1,i=No;else if(s>=bf){var d=t?null:Co(r);if(d)return Ce(d);p=!1,i=pt,m=new ft}else m=t?[]:l;e:for(;++o<s;){var h=r[o],x=t?t(h):h;if(h=e||h!==0?h:0,p&&x===x){for(var w=m.length;w--;)if(m[w]===x)continue e;t&&m.push(x),l.push(h)}else i(m,x,e)||(m!==l&&m.push(x),l.push(h))}return l}var Ro=_f;n();a();function Ef(r,t){return t=typeof t=="function"?t:void 0,r&&r.length?Ro(r,void 0,t):[]}var mt=Ef;n();a();n();a();var Po="self",Oo="static";var R={};Bt(R,{Access:()=>ae,Array:()=>xe,AstNode:()=>y,Attribute:()=>ye,Class:()=>V,ClassInstantiation:()=>D,ClassReference:()=>_,CodeBlock:()=>E,DataClass:()=>we,Enum:()=>ge,Field:()=>Te,Map:()=>Ae,Method:()=>Q,MethodInvocation:()=>J,Parameter:()=>K,Trait:()=>ve,Type:()=>B,TypeLiteral:()=>O,Writer:()=>U,array:()=>Bf,assignVariable:()=>Vf,attribute:()=>kf,classReference:()=>Df,class_:()=>Mf,codeblock:()=>be,dataClass:()=>Ff,enum_:()=>jf,field:()=>$f,instantiateClass:()=>jo,invokeMethod:()=>Wf,map:()=>zf,mergeArrays:()=>Qf,method:()=>Gf,parameter:()=>qf,string:()=>Jf,ternary:()=>Hf,this_:()=>Xf,throwException:()=>Yf,trait:()=>Uf,variable:()=>Kf});n();a();n();a();n();a();var H=class{};n();a();n();a();var P=class extends H{constructor(e){super();c(this,"value");this.value=e}write(e){typeof this.value=="string"?e.write(this.value):typeof this.value=="function"?this.value(e):this.value.write(e)}};var If=4,ke=class{constructor(){c(this,"buffer","");c(this,"indentLevel",0);c(this,"hasWrittenAnything",!1);c(this,"lastCharacterIsSemicolon",!1);c(this,"lastCharacterIsNewline",!1)}write(t){let e=t.length>0&&t.endsWith(`
2
+ `),o=e?t.substring(0,t.length-1):t,i=this.getIndentString(),s=o.replaceAll(`
3
3
  `,`
4
- ${n}`);this.isAtStartOfLine()&&(o=n+o),e&&(o+=`
5
- `),this.writeInternal(o)}writeNoIndent(t){let e=this.indentLevel;this.indentLevel=0,this.write(t),this.indentLevel=e}writeNode(t){t.write(this)}writeNodeOrString(t){if(typeof t=="string"){this.write(t);return}this.writeNode(t)}writeNodeStatement(t){t.write(this),this.write(";"),this.writeNewLineIfLastLineNot()}writeTextStatement(t){new b(t).write(this),this.write(";"),this.writeNewLineIfLastLineNot()}controlFlow(t,e){new b(t).write(this),this.write(" ("),this.writeNode(e),this.write(") {"),this.writeNewLineIfLastLineNot(),this.indent()}endControlFlow(){this.dedent(),this.writeLine("}")}contiguousControlFlow(t,e){this.dedent(),this.write("} "),new b(t).write(this),this.write(" ("),this.writeNode(e),this.write(") {"),this.writeNewLineIfLastLineNot(),this.indent()}alternativeControlFlow(t){this.dedent(),this.write("} "),new b(t).write(this),this.write(" {"),this.writeNewLineIfLastLineNot(),this.indent()}openBlock(t,e="{",r,n="}"){let o=t.filter(s=>s!==void 0).join(" ");o?this.write(`${o} ${e!=null?e:""}`):this.write(e!=null?e:"");try{this.indent(),r(),this.dedent()}finally{this.write(n!=null?n:"")}}writeLine(t=""){this.write(t),this.writeNewLineIfLastLineNot()}newLine(){this.writeInternal(`
6
- `)}writeNewLineIfLastLineNot(){this.lastCharacterIsNewline||this.writeInternal(`
7
- `)}indent(){this.indentLevel++}dedent(){this.indentLevel--}delimit({nodes:t,delimiter:e,writeFunction:r}){if(t.length>0){let n=t[0];n!=null&&r(n);for(let o=1;o<t.length;o++){this.write(e);let s=t[o];s!=null&&r(s)}}}toString(){return this.buffer}writeInternal(t){return t.length>0&&(this.hasWrittenAnything=!0,this.lastCharacterIsNewline=t.endsWith(`
8
- `)),this.buffer+=t}isAtStartOfLine(){return this.lastCharacterIsNewline||!this.hasWrittenAnything}getIndentString(){return" ".repeat(this.indentLevel*Tr)}};u();l();function _e(i){return(i==null?void 0:i.name)!=null}u();l();var ue=class extends U{constructor({condition:e,true_:r,false_:n}){super();f(this,"condition");f(this,"true_");f(this,"false_");this.condition=e,this.true_=r,this.false_=n}write(e){e.writeNode(this.condition),e.write(" ? "),e.writeNode(this.true_),e.write(" : "),e.writeNode(this.false_)}};u();l();u();l();var V={Public:"public",PublicReadonly:"public readonly",Protected:"protected",Private:"private"};u();l();u();l();u();l();function nt(i){return{namespace:i.substring(0,i.lastIndexOf("\\")),name:i.substring(i.lastIndexOf("\\")+1)}}var C=class extends ce{constructor({namespace:e,rootNamespace:r,customConfig:n}){super();f(this,"namespace");f(this,"rootNamespace");f(this,"customConfig");f(this,"references",{});this.namespace=e,this.rootNamespace=r,this.customConfig=n}addReference(e){var s,c;if(e.namespace==null)return;if(Object.keys(this.references).filter(h=>{let m=nt(h);return m.namespace!==e.namespace&&m.name===e.name}).length>0){e.requireFullyQualified();return}let n=e.namespace===fe?e.name:`${e.namespace}\\${e.name}`;((c=(s=this.references)[n])!=null?c:s[n]=[]).push(e)}toString(){let e=`namespace ${this.namespace};`,r=this.stringifyImports();return r.length>0?`${e}
4
+ ${i}`);this.isAtStartOfLine()&&(s=i+s),e&&(s+=`
5
+ `),this.writeInternal(s)}writeNoIndent(t){let e=this.indentLevel;this.indentLevel=0,this.write(t),this.indentLevel=e}writeNode(t){t.write(this)}writeNodeOrString(t){if(typeof t=="string"){this.write(t);return}this.writeNode(t)}writeNodeStatement(t){t.write(this),this.write(";"),this.writeNewLineIfLastLineNot()}writeTextStatement(t){new P(t).write(this),this.write(";"),this.writeNewLineIfLastLineNot()}controlFlow(t,e){new P(t).write(this),this.write(" ("),this.writeNode(e),this.write(") {"),this.writeNewLineIfLastLineNot(),this.indent()}controlFlowWithoutStatement(t){new P(t).write(this),this.write(" {"),this.writeNewLineIfLastLineNot(),this.indent()}endControlFlow(){this.dedent(),this.writeLine("}")}contiguousControlFlow(t,e){this.dedent(),this.write("} "),new P(t).write(this),this.write(" ("),this.writeNode(e),this.write(") {"),this.writeNewLineIfLastLineNot(),this.indent()}alternativeControlFlow(t){this.dedent(),this.write("} "),new P(t).write(this),this.write(" {"),this.writeNewLineIfLastLineNot(),this.indent()}writeLine(t=""){this.write(t),this.writeNewLineIfLastLineNot()}newLine(){this.writeInternal(`
6
+ `)}writeSemicolonIfLastCharacterIsNot(){this.lastCharacterIsSemicolon||this.writeInternal(";")}writeNewLineIfLastLineNot(){this.lastCharacterIsNewline||this.writeInternal(`
7
+ `)}indent(){this.indentLevel++}dedent(){this.indentLevel--}delimit({nodes:t,delimiter:e,writeFunction:o}){if(t.length>0){let i=t[0];i!=null&&o(i);for(let s=1;s<t.length;s++){this.write(e);let p=t[s];p!=null&&o(p)}}}toString(){return this.buffer}writeInternal(t){return t.length>0&&(this.hasWrittenAnything=!0,this.lastCharacterIsNewline=t.endsWith(`
8
+ `),this.lastCharacterIsSemicolon=t.endsWith(";")),this.buffer+=t}isAtStartOfLine(){return this.lastCharacterIsNewline||!this.hasWrittenAnything}getIndentString(){return" ".repeat(this.indentLevel*this.getTabSize())}getTabSize(){return If}};n();a();function Nt(r){return(r==null?void 0:r.name)!=null}n();a();var Me=class extends H{constructor({condition:e,true_:o,false_:i}){super();c(this,"condition");c(this,"true_");c(this,"false_");this.condition=e,this.true_=o,this.false_=i}write(e){e.writeNode(this.condition),e.write(" ? "),e.writeNode(this.true_),e.write(" : "),e.writeNode(this.false_)}};n();a();n();a();var ae={Public:"public",PublicReadonly:"public readonly",Protected:"protected",Private:"private"};n();a();n();a();n();a();function Bo(r){return{namespace:r.substring(0,r.lastIndexOf("\\")),name:r.substring(r.lastIndexOf("\\")+1)}}var U=class extends ke{constructor({namespace:e,rootNamespace:o,customConfig:i}){super();c(this,"namespace");c(this,"rootNamespace");c(this,"customConfig");c(this,"references",{});this.namespace=e,this.rootNamespace=o,this.customConfig=i}addReference(e){var p,l;if(e.namespace==null)return;if(Object.keys(this.references).filter(m=>{let d=Bo(m);return d.namespace!==e.namespace&&d.name===e.name}).length>0){e.requireFullyQualified();return}let i=e.namespace===""?e.name:`${e.namespace}\\${e.name}`;((l=(p=this.references)[i])!=null?l:p[i]=[]).push(e)}toString(e=!1){if(e)return this.buffer;let o=`namespace ${this.namespace};`,i=this.stringifyImports();return i.length>0?`${o}
9
9
 
10
- ${r}
10
+ ${i}
11
11
 
12
- ${this.buffer}`:e+`
12
+ ${this.buffer}`:o+`
13
13
 
14
- `+this.buffer}stringifyImports(){let e=Object.keys(this.references);return e.length===0?"":e.filter(r=>nt(r).namespace!==this.namespace).map(r=>`use ${r};`).join(`
15
- `)}};var p=class extends U{toString(t){if(t==null)throw new Error("Internal error; AstNode.toString method called incorrectly.");let{namespace:e,rootNamespace:r,customConfig:n}=t,o=new C({namespace:e,rootNamespace:r,customConfig:n});return this.write(o),o.toString()}async toStringAsync({namespace:t,rootNamespace:e,customConfig:r}){let n=new C({namespace:t,rootNamespace:e,customConfig:r});return this.write(n),n.toString()}};var X=class extends p{constructor({entries:e}){super();f(this,"entries");this.entries=e!=null?e:[]}write(e){e.write("["),this.entries.forEach((r,n)=>{n>0&&e.write(", "),r.write(e)}),e.write("]")}};u();l();var Z=class extends p{constructor(e){var r;super();f(this,"reference");f(this,"arguments");this.reference=e.reference,this.arguments=(r=e.arguments)!=null?r:[]}write(e){e.addReference(this.reference),e.write(`${this.reference.name}`),this.arguments.length>0&&(e.write("("),this.arguments.forEach((r,n)=>{n>0&&e.write(","),typeof r=="string"?e.write(r):r.write(e)}),e.write(")"))}};u();l();u();l();var g=class extends p{constructor({name:e,namespace:r,generics:n}){super();f(this,"name");f(this,"namespace");f(this,"generics");f(this,"fullyQualified");this.name=e,this.namespace=r,this.generics=n,this.fullyQualified=!1}requireFullyQualified(){this.fullyQualified=!0}write(e){e.addReference(this);let r=this.fullyQualified?`\\${this.namespace}\\${this.name}`:this.name;e.write(`${r}`)}};u();l();u();l();function z(i){return i.startsWith("$")?i:`$${i}`}var v=class extends p{constructor({docs:e}={}){super();f(this,"docs");f(this,"tags",[]);this.docs=e}addTag(e){this.tags.push(pe(he({},e),{name:e.name!=null?z(e.name):void 0}))}write(e){e.writeLine("/**"),this.docs!=null&&(this.docs.split(`
16
- `).forEach(r=>{e.writeLine(` * ${r}`)}),this.tags.length>0&&e.writeLine(" *"));for(let r of this.tags)this.writeTag({writer:e,tag:r});e.writeLine(" */")}writeTag({writer:e,tag:r}){let n=r.docs!=null?r.docs.split(`
17
- `):void 0;n!=null&&n.length>1&&(n.forEach(o=>{e.writeLine(` * ${o}`)}),e.writeLine(" *")),e.write(` * @${r.tagType} `),r.type.write(e,{comment:!0}),r.name!=null&&e.write(` ${r.name}`),n!=null&&n.length===1&&e.write(` ${n[0]}`),e.newLine()}};u();l();function q(i){return Ar(i,[V.Public,V.PublicReadonly,V.Protected,V.Private])}function Ar(i,t){return t.reduce((e,r)=>[...e,...i.filter(n=>n.access===r)],[])}var M=class extends p{constructor({name:e,namespace:r,abstract:n,docs:o,parentClassReference:s,traits:c}){super();f(this,"name");f(this,"namespace");f(this,"abstract");f(this,"docs");f(this,"parentClassReference");f(this,"traits");f(this,"fields",[]);f(this,"methods",[]);f(this,"constructor_");this.name=e,this.namespace=r,this.abstract=n!=null?n:!1,this.docs=o,this.parentClassReference=s,this.traits=c!=null?c:[]}addConstructor(e){this.constructor_=e}addField(e){this.fields.push(e)}addMethod(e){this.methods.push(e)}addMethods(e){this.methods.push(...e)}addTrait(e){this.traits.push(e)}write(e){e.addReference(new g({name:this.name,namespace:this.namespace})),this.abstract&&e.write("abstract "),this.writeComment(e),e.write(`class ${this.name} `),this.parentClassReference!=null&&(e.write("extends "),this.parentClassReference.write(e)),e.newLine(),e.writeLine("{"),e.indent(),this.traits.length>0&&(e.write("use "),this.traits.forEach((r,n)=>{n>0&&e.write(","),e.writeNode(r)}),e.writeTextStatement(""),e.newLine()),this.writeFields({writer:e,fields:q(this.fields)}),(this.constructor!=null||this.methods.length>0)&&e.newLine(),this.constructor_!=null&&(this.writeConstructor({writer:e,constructor:this.constructor_}),this.methods.length>0&&e.newLine()),this.writeMethods({writer:e,methods:q(this.methods)}),e.dedent(),e.writeLine("}")}writeComment(e){if(this.docs==null)return;new v({docs:this.docs}).write(e)}writeConstructor({writer:e,constructor:r}){var n;this.writeConstructorComment({writer:e,constructor:r}),r.access!=null&&e.write(`${r.access} `),e.write("function __construct("),e.indent(),r.parameters.forEach((o,s)=>{s===0&&e.newLine(),o.write(e),e.writeLine(",")}),e.dedent(),e.writeLine(")"),e.writeLine("{"),e.indent(),(n=r.body)==null||n.write(e),e.writeNewLineIfLastLineNot(),e.dedent(),e.writeLine("}")}writeConstructorComment({writer:e,constructor:r}){if(r.parameters.length===0)return;let n=new v;for(let o of r.parameters)n.addTag(o.getCommentTag());n.write(e)}writeFields({writer:e,fields:r}){r.filter(n=>!n.inherited).forEach((n,o)=>{o>0&&e.newLine(),n.write(e),e.writeNewLineIfLastLineNot()})}writeMethods({writer:e,methods:r}){r.forEach((n,o)=>{o>0&&e.newLine(),n.write(e),e.writeNewLineIfLastLineNot()})}};u();l();var j=class extends p{constructor({name:e,namespace:r,docs:n,traits:o}){super();f(this,"name");f(this,"namespace");f(this,"docs");f(this,"traits");f(this,"fields",[]);f(this,"methods",[]);this.name=e,this.namespace=r,this.docs=n,this.traits=o!=null?o:[]}addField(e){this.fields.push(e)}addMethod(e){this.methods.push(e)}write(e){this.writeComment(e),e.write(`trait ${this.name} `),e.newLine(),e.writeLine("{"),e.indent(),this.traits.length>0&&(e.write("use "),this.traits.forEach((r,n)=>{n>0&&e.write(","),e.writeNode(r)}),e.writeTextStatement(""),e.newLine()),this.writeFields({writer:e,fields:q(this.fields)}),this.fields.length>0&&this.methods.length>0&&e.newLine(),this.writeMethods({writer:e,methods:q(this.methods)}),e.dedent(),e.writeLine("}")}writeComment(e){let r=new v({docs:this.docs});for(let n of this.fields)r.addTag({tagType:"property",type:n.type,name:n.name});r.write(e)}writeFields({writer:e,fields:r}){r.forEach((n,o)=>{o>0&&e.newLine(),n.write(e),e.writeNewLineIfLastLineNot()})}writeMethods({writer:e,methods:r}){r.forEach((n,o)=>{o>0&&e.newLine(),n.write(e),e.writeNewLineIfLastLineNot()})}};u();l();u();l();function ae({writer:i,arguments_:t,multiline:e}){if(t.length===0){i.write("()");return}if(e){Er({writer:i,arguments_:t});return}vr({writer:i,arguments_:t})}function Er({writer:i,arguments_:t}){i.writeLine("("),i.indent();for(let e of t)ot({writer:i,argument:e,writeCompact:!1}),i.writeLine(",");i.dedent(),i.write(")")}function vr({writer:i,arguments_:t}){i.write("("),t.forEach((e,r)=>{r>0&&i.write(", "),ot({writer:i,argument:e,writeCompact:!0})}),i.write(")")}function ot({writer:i,argument:t,writeCompact:e}){_e(t)?(t.docs&&(e?i.write(`/* ${t.docs} */ `):i.writeLine(`/* ${t.docs} */`)),i.write(`${t.name}: `),i.writeNodeOrString(t.assignment)):t.write(i)}var S=class extends p{constructor({classReference:e,arguments_:r,multiline:n}){super();f(this,"classReference");f(this,"arguments_");f(this,"multiline");this.classReference=e,this.arguments_=r,this.multiline=n!=null?n:!1}write(e){e.write("new "),e.writeNode(this.classReference),ae({writer:e,arguments_:this.arguments_,multiline:this.multiline})}};u();l();var T=class extends p{constructor(e){super();f(this,"arg");this.arg=e}write(e){return new b(this.arg).write(e)}};u();l();u();l();var F=class extends p{constructor({name:e,type:r,docs:n,initializer:o,access:s,readonly_:c}){super();f(this,"name");f(this,"type");f(this,"docs");f(this,"initializer");f(this,"access");f(this,"readonly_");this.name=z(e),this.type=r,this.docs=n,this.initializer=o,this.access=s,this.readonly_=c!=null?c:!1}getCommentTag(){return{tagType:"param",type:this.type,name:this.name,docs:this.docs}}write(e){this.access!=null&&e.write(`${this.access} `),this.readonly_&&e.write("readonly "),this.type.write(e),e.write(` ${this.name}`),this.initializer!=null?(e.write(" = "),this.initializer.write(e)):this.type.isOptional()&&e.write(" = null")}};u();l();var R=class i extends p{constructor(e){super();f(this,"internalType");this.internalType=e}write(e,{comment:r}={}){switch(this.internalType.type){case"int":e.write("int");break;case"string":e.write("string");break;case"bool":e.write("bool");break;case"float":e.write("float");break;case"date":e.addReference(st),e.write("DateTime");break;case"dateTime":e.addReference(st),e.write("DateTime");break;case"mixed":e.write("mixed");break;case"object":e.write("object");break;case"array":if(!r){e.write("array");break}e.write("array<"),this.internalType.value.write(e,{comment:r}),e.write(">");break;case"map":{if(!r){e.write("array");break}e.write("array<"),this.internalType.keyType.write(e,{comment:r}),e.write(", "),this.internalType.valueType.write(e,{comment:r}),e.write(">");break}case"null":{e.write("null");break}case"typeDict":{if(!r){e.write("array");break}if(this.internalType.multiline){e.writeLine("array{");let n=this.internalType.entries.filter(c=>!c.valueType.isOptional()),o=this.internalType.entries.filter(c=>c.valueType.isOptional()),s=[...n,...o];for(let c of s)e.write(" * "),this.writeTypeDictEntry({writer:e,entry:c,comment:r}),e.writeLine(",");e.write(" * }");break}e.write("array{"),this.internalType.entries.forEach((n,o)=>{o>0&&e.write(", "),this.writeTypeDictEntry({writer:e,entry:n,comment:r})}),e.write("}");break}case"union":{let n=this.getUniqueTypes({types:this.internalType.types,comment:r,writer:e}),o=n.filter(s=>s.underlyingType().internalType.type==="mixed").length>0;if(o&&!r){e.write("mixed");break}n.length>0&&r?(e.writeLine("("),n.forEach((s,c)=>{c>0?e.write(" * |"):e.write(" * "),o&&(s=s.underlyingType()),s.write(e,{comment:r}),e.writeLine(),c++}),e.write(" * )")):n.forEach((s,c)=>{c>0&&e.write("|"),o&&(s=s.underlyingType()),s.write(e,{comment:r}),c++});break}case"optional":{let n=this.internalType.value.internalType.type==="mixed",o=this.internalType.value.internalType.type==="union";!o&&!n&&e.write("?"),this.internalType.value.write(e,{comment:r}),o&&(e.write("|"),e.writeNode(i.null()));break}case"reference":if(r){e.writeNode(this.internalType.value);let n=this.internalType.value.generics;n&&n.length>0&&(e.write("<"),n.forEach((o,s)=>{s>0&&e.write(", "),o.write(e,{comment:r})}),e.write(">"))}else e.writeNode(this.internalType.value);break;case"enumString":r?(e.write("value-of<"),e.writeNode(this.internalType.value),e.write(">")):e.write("string");break;default:W(this.internalType)}}toOptionalIfNotAlready(){return this.internalType.type==="optional"?this:i.optional(this)}underlyingTypeIfOptional(){if(this.internalType.type==="optional")return this.internalType.value}underlyingType(){var e;return(e=this.underlyingTypeIfOptional())!=null?e:this}isOptional(){return this.internalType.type==="optional"}getClassReference(){switch(this.internalType.type){case"date":case"dateTime":return new g({name:"DateTime",namespace:fe});case"enumString":case"reference":return this.internalType.value;case"int":case"string":case"bool":case"float":case"object":case"map":case"array":case"null":case"mixed":case"optional":case"typeDict":case"union":throw new Error("Cannot get class reference for "+this.internalType.type);default:W(this.internalType)}}static int(){return new this({type:"int"})}static string(){return new this({type:"string"})}static bool(){return new this({type:"bool"})}static float(){return new this({type:"float"})}static date(){return new this({type:"date"})}static dateTime(){return new this({type:"dateTime"})}static mixed(){return new this({type:"mixed"})}static object(){return new this({type:"object"})}static array(e){return new this({type:"array",value:e})}static map(e,r){return new this({type:"map",keyType:e,valueType:r})}static typeDict(e,{multiline:r}={}){return new this({type:"typeDict",entries:e,multiline:r})}static union(e){return new this({type:"union",types:e})}static optional(e){return this.isAlreadyOptional(e)?e:new this({type:"optional",value:e})}static null(){return new this({type:"null"})}static reference(e){return new this({type:"reference",value:e})}static enumString(e){return new this({type:"enumString",value:e})}static isAlreadyOptional(e){return e.internalType.type==="optional"}writeTypeDictEntry({writer:e,entry:r,comment:n}){e.write(r.key),r.optional&&e.write("?"),e.write(": "),r.valueType.write(e,{comment:n})}getUniqueTypes({writer:e,types:r,comment:n}){let o=new Set;return r.filter(s=>{let c=s.toString({namespace:e.namespace,rootNamespace:e.rootNamespace,customConfig:e.customConfig,comment:n});return o.has(c)?!1:(o.add(c),!0)})}toString({namespace:e,rootNamespace:r,customConfig:n,comment:o}){let s=new C({namespace:e,rootNamespace:r,customConfig:n});return this.write(s,{comment:o!=null?o:!1}),s.toString()}},st=new g({namespace:fe,name:"DateTime"});u();l();function at(i){return i.startsWith("$")?i.slice(1):i}var ft="values",K=class extends p{constructor({name:e,namespace:r,abstract:n,docs:o,parentClassReference:s,traits:c}){super();f(this,"name");f(this,"namespace");f(this,"class_");this.name=e,this.namespace=r,this.class_=new M({name:e,namespace:r,abstract:n,docs:o,parentClassReference:s,traits:c})}addField(e){this.class_.addField(e)}addMethod(e){this.class_.addMethod(e)}addTrait(e){this.class_.addTrait(e)}write(e){let r=q(this.class_.fields).map(n=>pe(he({},n),{name:at(n.name)}));r.length>0&&this.class_.addConstructor({access:"public",parameters:this.getConstructorParameters({orderedFields:r}),body:L.codeblock(n=>{for(let o of r)n.write(`$this->${o.name} = $${ft}['${o.name}']`),o.type.isOptional()&&n.write(" ?? null"),n.write(";")})}),this.class_.write(e)}allFieldsAreOptional(){return this.class_.fields.every(e=>e.type.isOptional())}getConstructorParameters({orderedFields:e}){return[new F({name:ft,type:R.typeDict(e.map(r=>({key:r.name,valueType:r.type,optional:r.type.isOptional()})),{multiline:!0}),initializer:this.allFieldsAreOptional()?new T("[]"):void 0})]}};u();l();u();l();var D=class extends p{constructor({name:e,access:r,parameters:n,throws:o,return_:s,body:c,docs:h,classReference:m,static_:w}){super();f(this,"name");f(this,"access");f(this,"parameters");f(this,"throws");f(this,"return_");f(this,"body");f(this,"docs");f(this,"classReference");f(this,"static_");this.name=e,this.access=r,this.parameters=n,this.throws=o!=null?o:[],this.return_=s,this.body=c,this.docs=h,this.classReference=m,this.static_=w!=null?w:!1}write(e){var s;this.writeComment(e),e.write(`${this.access}${this.static_?" static":""} function ${this.name}(`);let r=this.parameters.filter(c=>!c.type.isOptional()),n=this.parameters.filter(c=>c.type.isOptional());[...r,...n].forEach((c,h)=>{h>0&&e.write(", "),c.write(e)}),e.write("): "),this.return_!=null?e.writeNodeOrString(this.return_):e.write("void"),e.writeLine(" {"),e.indent(),(s=this.body)==null||s.write(e),e.dedent(),e.writeLine("}")}writeComment(e){let r=new v({docs:this.docs});for(let n of this.parameters)r.addTag({tagType:"param",type:n.type,name:n.name,docs:n.docs});this.return_!=null&&this.return_!==rt&&this.return_!==it&&r.addTag({tagType:"return",type:this.return_});for(let n of this.throws)r.addTag({tagType:"throws",type:R.reference(n)});e.writeNode(r)}};var ee=class extends p{constructor({name:e,namespace:r,backing:n,docs:o,serializable:s}){super();f(this,"name");f(this,"namespace");f(this,"backing");f(this,"docs");f(this,"members",[]);f(this,"serializable");this.name=e,this.namespace=r,this.backing=n,this.docs=o,this.serializable=s!=null?s:!1}addMember(e){this.members.push(e)}write(e){this.writeComment(e),e.write("enum "),e.writeLine(`${this.name}`),this.backing!=null&&e.write(` : ${this.backing}`),this.serializable&&(e.addReference(new g({name:"JsonSerializable",namespace:""})),e.writeLine(" implements JsonSerializable")),e.writeLine(" {"),e.indent();for(let r of this.members)e.write(`case ${r.name}`),r.value!=null&&(typeof r.value=="string"?e.write(` = "${r.value}"`):e.write(` = ${r.value}`)),e.writeTextStatement("");this.serializable&&(e.newLine(),e.writeNode(new D({name:"jsonSerialize",return_:R.string(),access:"public",parameters:[],body:new T("return $this->value;")}))),e.writeNewLineIfLastLineNot(),e.dedent(),e.writeLine("}")}writeComment(e){if(this.docs==null)return;new v({docs:this.docs}).write(e)}};u();l();var te=class extends p{constructor({name:e,type:r,access:n,readonly_:o,initializer:s,docs:c,inlineDocs:h,attributes:m,inherited:w}){super();f(this,"name");f(this,"type");f(this,"access");f(this,"readonly_");f(this,"initializer");f(this,"docs");f(this,"inlineDocs");f(this,"attributes");f(this,"inherited");this.name=z(e),this.type=r,this.access=n,this.readonly_=o!=null?o:!1,this.initializer=s,this.docs=c,this.inlineDocs=h,this.attributes=m!=null?m:[],this.inherited=w!=null?w:!1}write(e){this.writeComment(e),this.writeAttributesIfPresent(e),e.write(`${this.access} `),this.readonly_&&e.write("readonly "),this.type.write(e),e.write(` ${this.name}`),this.initializer!=null&&(e.write(" = "),this.initializer.write(e)),e.write(";"),this.inlineDocs!=null&&e.write(` // ${this.inlineDocs}`),e.newLine()}writeComment(e){let r=new v;r.addTag({tagType:"var",type:this.type,name:this.name,docs:this.docs}),r.write(e)}writeAttributesIfPresent(e){this.attributes.length>0&&(e.write("#["),this.attributes.forEach((r,n)=>{n>0&&e.write(", "),r.write(e)}),e.writeLine("]"))}};u();l();var re=class extends p{constructor({entries:e,multiline:r}){super();f(this,"entries");f(this,"multiline");this.entries=e!=null?e:[],this.multiline=r!=null?r:!1}write(e){if(this.multiline){this.writeMultiline(e);return}this.writeCompact(e)}writeMultiline(e){e.writeLine("["),e.indent();for(let{key:r,value:n}of this.entries)r.write(e),e.write(" => "),n.write(e),e.writeLine(",");e.dedent(),e.write("]")}writeCompact(e){e.write("[");for(let[r,{key:n,value:o}]of this.entries.entries())r>0&&e.write(", "),n.write(e),e.write(" => "),o.write(e);e.write("]")}};u();l();var $=class extends p{constructor({method:e,arguments_:r,static_:n,multiline:o,on:s}){super();f(this,"method");f(this,"arguments_");f(this,"multiline");f(this,"static_");f(this,"on");this.method=e,this.arguments_=r,this.static_=n!=null?n:!1,this.multiline=o!=null?o:!1,this.on=s}write(e){this.on!=null&&(this.on.write(e),e.write(this.getMethodAccessor())),e.write(this.method),ae({writer:e,arguments_:this.arguments_,multiline:this.multiline})}getMethodAccessor(){return this.static_?"::":"->"}};u();l();u();l();var G=class i extends p{constructor(e){super();f(this,"internalType");this.internalType=e}write(e){switch(this.internalType.type){case"list":{this.writeList({writer:e,list:this.internalType});break}case"boolean":{e.write(this.internalType.value.toString());break}case"class":{this.writeClass({writer:e,class_:this.internalType});break}case"file":{e.writeNode(Lr({writer:e,value:this.internalType.value}));break}case"float":{e.write(this.internalType.value.toString());break}case"number":{e.write(this.internalType.value.toString());break}case"map":{this.writeMap({writer:e,map:this.internalType});break}case"reference":{e.writeNode(this.internalType.value);break}case"datetime":{e.writeNode(Nr({writer:e,value:this.internalType.value}));break}case"string":{if(this.internalType.value.includes(`
18
- `)){this.writeStringWithHeredoc({writer:e,value:this.internalType.value});break}e.write(`'${this.internalType.value.replaceAll("'","\\'")}'`);break}case"unknown":{this.writeUnknown({writer:e,value:this.internalType.value});break}case"null":{e.write("null");break}case"nop":break;default:W(this.internalType)}}isClass(){return this.internalType.type==="class"}asClassOrThrow(){if(this.isClass())return this.internalType;throw new Error("Internal error; ts.TypeLiteral is not a class")}writeStringWithHeredoc({writer:e,value:r}){e.writeLine("<<<EOT"),e.writeNoIndent(r),e.newLine(),e.writeNoIndent("EOT")}writeClass({writer:e,class_:r}){e.writeNode(new S({classReference:r.reference,arguments_:[i.map({entries:r.fields.map(n=>({key:i.string(n.name),value:n.value}))})]}))}writeList({writer:e,list:r}){let n=Rr({values:r.values});if(n.length===0){e.write("[]");return}e.writeLine("["),e.indent();for(let o of n)o.write(e),e.writeLine(",");e.dedent(),e.write("]")}writeMap({writer:e,map:r}){let n=Ir({entries:r.entries});if(n.length===0){e.write("[]");return}e.writeLine("["),e.indent();for(let o of n)o.key.write(e),e.write(" => "),o.value.write(e),e.writeLine(",");e.dedent(),e.write("]")}static list({values:e}){return new this({type:"list",values:e})}static boolean(e){return new this({type:"boolean",value:e})}static class_({reference:e,fields:r}){return new this({type:"class",reference:e,fields:r})}static file(e){return new this({type:"file",value:e})}static float(e){return new this({type:"float",value:e})}static datetime(e){return new this({type:"datetime",value:e})}static number(e){return new this({type:"number",value:e})}static map({entries:e}){return new this({type:"map",entries:e})}static reference(e){return new this({type:"reference",value:e})}static string(e){return new this({type:"string",value:e})}static unknown(e){return new this({type:"unknown",value:e})}static null(){return new this({type:"null"})}static nop(){return new this({type:"nop"})}static isNop(e){return e.internalType.type==="nop"}writeUnknown({writer:e,value:r}){switch(typeof r){case"boolean":e.write(r.toString());return;case"string":e.write(r.includes('"')?`\`${r}\``:`"${r}"`);return;case"number":e.write(r.toString());return;case"object":if(r==null){e.write("null");return}if(Array.isArray(r)){this.writeUnknownArray({writer:e,value:r});return}this.writeUnknownMap({writer:e,value:r});return;default:throw new Error(`Internal error; unsupported unknown type: ${typeof r}`)}}writeUnknownArray({writer:e,value:r}){if(r.length===0){e.write("[]");return}e.writeLine("["),e.indent();for(let n of r)e.writeNode(i.unknown(n)),e.writeLine(",");e.dedent(),e.write("]")}writeUnknownMap({writer:e,value:r}){let n=Object.entries(r);if(n.length===0){e.write("[]");return}e.writeLine("["),e.indent();for(let[o,s]of n)e.write(`'${o}' => `),e.writeNode(i.unknown(s)),e.writeLine(",");e.dedent(),e.write("]")}};function Nr({writer:i,value:t}){return new S({classReference:new g({name:"DateTime",namespace:""}),arguments_:[new T(`'${t}'`)]})}function Lr({writer:i,value:t}){return new $({on:new g({name:"File",namespace:`${i.rootNamespace}\\Utils`}),method:"createFromString",arguments_:[new T(`"${t}"`)]})}function Ir({entries:i}){return i.filter(t=>!G.isNop(t.key)&&!G.isNop(t.value))}function Rr({values:i}){return i.filter(t=>!G.isNop(t))}u();l();var Ae=class extends p{constructor(e){super();f(this,"arrays");this.arrays=e}write(e){e.write("array_merge"),ae({writer:e,arguments_:this.arrays.map(r=>ie(n=>{if(typeof r=="string"||r instanceof p){n.writeNodeOrString(r);return}n.writeNodeOrString(r.ref),r.fallback&&(n.write(" ?? "),n.writeNodeOrString(r.fallback))}))})}};function _r(i){return new X(i)}function kr(i){return new Z(i)}function br(i){return new M(i)}function Cr(i){return new j(i)}function Sr(i){return new g(i)}function ie(i){return new T(i)}function Pr(i){return new K(i)}function Br(i){return new ee(i)}function Ur(i){return new te(i)}function ct(i){return new S(i)}function Mr(i){return new $(i)}function Fr(i){return ie(t=>{t.write("throw "),t.writeNode(ct(i))})}function Dr(i){return new re(i)}function $r(i){return new D(i)}function Or(i){return new F(i)}function Yr(i){return new ue(i)}function Wr(i,t){return ie(e=>{e.writeNodeOrString(i),e.write(" = "),e.writeNodeOrString(t)})}function Vr(i){return ie(z(i))}function zr(i){return ie(`"${i}"`)}function qr(...i){return new Ae(i)}function Gr(){return new T(i=>{i.write("$this")})}var ke=class{constructor({context:t}){f(this,"context");this.context=t}getFilePropertyInfo({body:t,value:e}){var o;let r={fileFields:[],bodyPropertyFields:[]},n=(o=this.context.getRecord(e))!=null?o:{};for(let s of t.properties)switch(s.type){case"file":r.fileFields.push({name:this.context.getPropertyName(s.name),value:this.getSingleFileProperty({property:s,record:n})});break;case"fileArray":r.fileFields.push({name:this.context.getPropertyName(s.name),value:this.getArrayFileProperty({property:s,record:n})});break;case"bodyProperty":r.bodyPropertyFields.push({name:this.context.getPropertyName(s.name.name),value:this.getBodyProperty({property:s,record:n})});break;default:W(s)}return r}getSingleFileProperty({property:t,record:e}){let r=this.context.getSingleFileValue({property:t,record:e});return r==null?L.TypeLiteral.nop():L.TypeLiteral.file(r)}getArrayFileProperty({property:t,record:e}){let r=this.context.getFileArrayValues({property:t,record:e});return r==null?L.TypeLiteral.nop():L.TypeLiteral.list({values:r.map(n=>L.TypeLiteral.file(n))})}getBodyProperty({property:t,record:e}){let r=e[t.name.wireValue];return r==null?L.TypeLiteral.nop():this.context.dynamicTypeLiteralMapper.convert({typeReference:t.typeReference,value:r})}};0&&(module.exports={FilePropertyMapper});
14
+ `+this.buffer}stringifyImports(){let e=Object.keys(this.references);return e.length===0?"":e.filter(o=>Bo(o).namespace!==this.namespace).map(o=>`use ${o};`).join(`
15
+ `)}};var y=class extends H{toString(t){if(t==null)throw new Error("Internal error; AstNode.toString method called incorrectly.");let{namespace:e,rootNamespace:o,customConfig:i,skipImports:s=!1}=t,p=new U({namespace:e,rootNamespace:o,customConfig:i});return this.write(p),p.toString(s)}async toStringAsync({namespace:t,rootNamespace:e,customConfig:o}){let i=new U({namespace:t,rootNamespace:e,customConfig:o});return this.write(i),i.toString()}};var xe=class extends y{constructor({entries:e}){super();c(this,"entries");this.entries=e!=null?e:[]}write(e){e.write("["),this.entries.forEach((o,i)=>{i>0&&e.write(", "),o.write(e)}),e.write("]")}};n();a();var ye=class extends y{constructor(e){var o;super();c(this,"reference");c(this,"arguments");this.reference=e.reference,this.arguments=(o=e.arguments)!=null?o:[]}write(e){e.addReference(this.reference),e.write(`${this.reference.name}`),this.arguments.length>0&&(e.write("("),this.arguments.forEach((o,i)=>{i>0&&e.write(","),typeof o=="string"?e.write(o):o.write(e)}),e.write(")"))}};n();a();n();a();var _=class extends y{constructor({name:e,namespace:o,generics:i}){super();c(this,"name");c(this,"namespace");c(this,"generics");c(this,"fullyQualified");this.name=e,this.namespace=o,this.generics=i,this.fullyQualified=!1}requireFullyQualified(){this.fullyQualified=!0}write(e){e.addReference(this);let o=this.fullyQualified?`\\${this.namespace}\\${this.name}`:this.name;e.write(`${o}`)}};n();a();n();a();function se(r){return r.startsWith("$")?r:`$${r}`}var L=class extends y{constructor({docs:e}={}){super();c(this,"docs");c(this,"tags",[]);this.docs=e}addTag(e){this.tags.push($e(je({},e),{name:e.name!=null?se(e.name):void 0}))}write(e){e.writeLine("/**"),this.docs!=null&&(this.docs.split(`
16
+ `).forEach(o=>{e.writeLine(` * ${o}`)}),this.tags.length>0&&e.writeLine(" *"));for(let o of this.tags)this.writeTag({writer:e,tag:o});e.writeLine(" */")}writeTag({writer:e,tag:o}){let i=o.docs!=null?o.docs.split(`
17
+ `):void 0;i!=null&&i.length>1&&(i.forEach(s=>{e.writeLine(` * ${s}`)}),e.writeLine(" *")),e.write(` * @${o.tagType} `),o.type.write(e,{comment:!0}),o.name!=null&&e.write(` ${o.name}`),i!=null&&i.length===1&&e.write(` ${i[0]}`),e.newLine()}};n();a();function fe(r){return Sf(r,[ae.Public,ae.PublicReadonly,ae.Protected,ae.Private])}function Sf(r,t){return t.reduce((e,o)=>[...e,...r.filter(i=>i.access===o)],[])}var V=class extends y{constructor({name:e,namespace:o,abstract:i,docs:s,parentClassReference:p,traits:l}){super();c(this,"name");c(this,"namespace");c(this,"abstract");c(this,"docs");c(this,"parentClassReference");c(this,"traits");c(this,"fields",[]);c(this,"methods",[]);c(this,"constructor_");this.name=e,this.namespace=o,this.abstract=i!=null?i:!1,this.docs=s,this.parentClassReference=p,this.traits=l!=null?l:[]}addConstructor(e){this.constructor_=e}addField(e){this.fields.push(e)}addMethod(e){this.methods.push(e)}addMethods(e){this.methods.push(...e)}addTrait(e){this.traits.push(e)}write(e){e.addReference(new _({name:this.name,namespace:this.namespace})),this.abstract&&e.write("abstract "),this.writeComment(e),e.write(`class ${this.name} `),this.parentClassReference!=null&&(e.write("extends "),this.parentClassReference.write(e)),e.newLine(),e.writeLine("{"),e.indent(),this.traits.length>0&&(e.write("use "),this.traits.forEach((o,i)=>{i>0&&e.write(","),e.writeNode(o)}),e.writeTextStatement(""),e.newLine()),this.writeFields({writer:e,fields:fe(this.fields)}),(this.constructor!=null||this.methods.length>0)&&e.newLine(),this.constructor_!=null&&(this.writeConstructor({writer:e,constructor:this.constructor_}),this.methods.length>0&&e.newLine()),this.writeMethods({writer:e,methods:fe(this.methods)}),e.dedent(),e.writeLine("}")}writeComment(e){if(this.docs==null)return;new L({docs:this.docs}).write(e)}writeConstructor({writer:e,constructor:o}){var i;this.writeConstructorComment({writer:e,constructor:o}),o.access!=null&&e.write(`${o.access} `),e.write("function __construct("),e.indent(),o.parameters.forEach((s,p)=>{p===0&&e.newLine(),s.write(e),e.writeLine(",")}),e.dedent(),e.writeLine(")"),e.writeLine("{"),e.indent(),(i=o.body)==null||i.write(e),e.writeNewLineIfLastLineNot(),e.dedent(),e.writeLine("}")}writeConstructorComment({writer:e,constructor:o}){if(o.parameters.length===0)return;let i=new L;for(let s of o.parameters)i.addTag(s.getCommentTag());i.write(e)}writeFields({writer:e,fields:o}){o.filter(i=>!i.inherited).forEach((i,s)=>{s>0&&e.newLine(),i.write(e),e.writeNewLineIfLastLineNot()})}writeMethods({writer:e,methods:o}){o.forEach((i,s)=>{s>0&&e.newLine(),i.write(e),e.writeNewLineIfLastLineNot()})}};n();a();n();a();function Re({writer:r,arguments_:t,multiline:e}){if(t.length===0){r.write("()");return}if(e){Lf({writer:r,arguments_:t});return}Nf({writer:r,arguments_:t})}function Lf({writer:r,arguments_:t}){r.writeLine("("),r.indent();for(let e of t)Mo({writer:r,argument:e,writeCompact:!1}),r.writeLine(",");r.dedent(),r.write(")")}function Nf({writer:r,arguments_:t}){r.write("("),t.forEach((e,o)=>{o>0&&r.write(", "),Mo({writer:r,argument:e,writeCompact:!0})}),r.write(")")}function Mo({writer:r,argument:t,writeCompact:e}){Nt(t)?(t.docs&&(e?r.write(`/* ${t.docs} */ `):r.writeLine(`/* ${t.docs} */`)),r.write(`${t.name}: `),r.writeNodeOrString(t.assignment)):t.write(r)}var D=class extends y{constructor({classReference:e,arguments_:o,multiline:i}){super();c(this,"classReference");c(this,"arguments_");c(this,"multiline");this.classReference=e,this.arguments_=o,this.multiline=i!=null?i:!1}write(e){e.write("new "),e.writeNode(this.classReference),Re({writer:e,arguments_:this.arguments_,multiline:this.multiline})}};n();a();var E=class extends y{constructor(e){super();c(this,"arg");this.arg=e}write(e){return new P(this.arg).write(e)}};n();a();n();a();var K=class extends y{constructor({name:e,type:o,docs:i,initializer:s,access:p,readonly_:l}){super();c(this,"name");c(this,"type");c(this,"docs");c(this,"initializer");c(this,"access");c(this,"readonly_");this.name=se(e),this.type=o,this.docs=i,this.initializer=s,this.access=p,this.readonly_=l!=null?l:!1}getCommentTag(){return{tagType:"param",type:this.type,name:this.name,docs:this.docs}}write(e){this.access!=null&&e.write(`${this.access} `),this.readonly_&&e.write("readonly "),this.type.write(e),e.write(` ${this.name}`),this.initializer!=null?(e.write(" = "),this.initializer.write(e)):this.type.isOptional()&&e.write(" = null")}};n();a();n();a();n();a();n();a();var J=class extends y{constructor({method:e,arguments_:o,static_:i,multiline:s,on:p}){super();c(this,"method");c(this,"arguments_");c(this,"multiline");c(this,"static_");c(this,"on");this.method=e,this.arguments_=o,this.static_=i!=null?i:!1,this.multiline=s!=null?s:!1,this.on=p}write(e){this.on!=null&&(this.on.write(e),e.write(this.getMethodAccessor())),e.write(this.method),Re({writer:e,arguments_:this.arguments_,multiline:this.multiline})}getMethodAccessor(){return this.static_?"::":"->"}};var O=class r extends y{constructor(e){super();c(this,"internalType");this.internalType=e}write(e){switch(this.internalType.type){case"list":{this.writeList({writer:e,list:this.internalType});break}case"boolean":{e.write(this.internalType.value.toString());break}case"class":{this.writeClass({writer:e,class_:this.internalType});break}case"file":{e.writeNode(Rf({writer:e,value:this.internalType.value}));break}case"float":{e.write(this.internalType.value.toString());break}case"number":{e.write(this.internalType.value.toString());break}case"map":{this.writeMap({writer:e,map:this.internalType});break}case"reference":{e.writeNode(this.internalType.value);break}case"datetime":{e.writeNode(Cf({writer:e,value:this.internalType.value}));break}case"string":{if(this.internalType.value.includes(`
18
+ `)){this.writeStringWithHeredoc({writer:e,value:this.internalType.value});break}if(this.internalType.value.includes("'")){e.write(`"${this.internalType.value.replaceAll('"','\\"')}"`);break}e.write(`'${this.internalType.value}'`);break}case"unknown":{this.writeUnknown({writer:e,value:this.internalType.value});break}case"null":{e.write("null");break}case"nop":break;default:$(this.internalType)}}isClass(){return this.internalType.type==="class"}asClassOrThrow(){if(this.isClass())return this.internalType;throw new Error("Internal error; ts.TypeLiteral is not a class")}writeStringWithHeredoc({writer:e,value:o}){e.writeLine("<<<EOT"),e.writeNoIndent(o),e.newLine(),e.writeNoIndent("EOT")}writeClass({writer:e,class_:o}){e.writeNode(new D({classReference:o.reference,arguments_:[r.map({entries:o.fields.map(i=>({key:r.string(i.name),value:i.value}))})]}))}writeList({writer:e,list:o}){let i=Of({values:o.values});if(i.length===0){e.write("[]");return}e.writeLine("["),e.indent();for(let s of i)s.write(e),e.writeLine(",");e.dedent(),e.write("]")}writeMap({writer:e,map:o}){let i=Pf({entries:o.entries});if(i.length===0){e.write("[]");return}e.writeLine("["),e.indent();for(let s of i)s.key.write(e),e.write(" => "),s.value.write(e),e.writeLine(",");e.dedent(),e.write("]")}static list({values:e}){return new this({type:"list",values:e})}static boolean(e){return new this({type:"boolean",value:e})}static class_({reference:e,fields:o}){return new this({type:"class",reference:e,fields:o})}static file(e){return new this({type:"file",value:e})}static float(e){return new this({type:"float",value:e})}static datetime(e){return new this({type:"datetime",value:e})}static number(e){return new this({type:"number",value:e})}static map({entries:e}){return new this({type:"map",entries:e})}static reference(e){return new this({type:"reference",value:e})}static string(e){return new this({type:"string",value:e})}static unknown(e){return new this({type:"unknown",value:e})}static null(){return new this({type:"null"})}static nop(){return new this({type:"nop"})}static isNop(e){return e.internalType.type==="nop"}writeUnknown({writer:e,value:o}){switch(typeof o){case"boolean":e.write(o.toString());return;case"string":e.write(o.includes('"')?`\`${o}\``:`"${o}"`);return;case"number":e.write(o.toString());return;case"object":if(o==null){e.write("null");return}if(Array.isArray(o)){this.writeUnknownArray({writer:e,value:o});return}this.writeUnknownMap({writer:e,value:o});return;default:throw new Error(`Internal error; unsupported unknown type: ${typeof o}`)}}writeUnknownArray({writer:e,value:o}){if(o.length===0){e.write("[]");return}e.writeLine("["),e.indent();for(let i of o)e.writeNode(r.unknown(i)),e.writeLine(",");e.dedent(),e.write("]")}writeUnknownMap({writer:e,value:o}){let i=Object.entries(o);if(i.length===0){e.write("[]");return}e.writeLine("["),e.indent();for(let[s,p]of i)e.write(`'${s}' => `),e.writeNode(r.unknown(p)),e.writeLine(",");e.dedent(),e.write("]")}};function Cf({writer:r,value:t}){return new D({classReference:new _({name:"DateTime",namespace:""}),arguments_:[new E(`'${t}'`)]})}function Rf({writer:r,value:t}){return new J({on:new _({name:"File",namespace:`${r.rootNamespace}\\Utils`}),method:"createFromString",arguments_:[new E(`"${t}"`)]})}function Pf({entries:r}){return r.filter(t=>!O.isNop(t.key)&&!O.isNop(t.value))}function Of({values:r}){return r.filter(t=>!O.isNop(t))}var B=class r extends y{constructor(e){super();c(this,"internalType");this.internalType=e}write(e,{comment:o}={}){switch(this.internalType.type){case"int":e.write("int");break;case"string":e.write("string");break;case"bool":e.write("bool");break;case"float":e.write("float");break;case"date":e.addReference(Uo),e.write("DateTime");break;case"dateTime":e.addReference(Uo),e.write("DateTime");break;case"mixed":e.write("mixed");break;case"object":e.write("object");break;case"array":if(!o){e.write("array");break}e.write("array<"),this.internalType.value.write(e,{comment:o}),e.write(">");break;case"map":{if(!o){e.write("array");break}e.write("array<"),this.internalType.keyType.write(e,{comment:o}),e.write(", "),this.internalType.valueType.write(e,{comment:o}),e.write(">");break}case"null":{e.write("null");break}case"typeDict":{if(!o){e.write("array");break}if(this.internalType.multiline){e.writeLine("array{");let i=this.internalType.entries.filter(l=>!l.valueType.isOptional()),s=this.internalType.entries.filter(l=>l.valueType.isOptional()),p=[...i,...s];for(let l of p)e.write(" * "),this.writeTypeDictEntry({writer:e,entry:l,comment:o}),e.writeLine(",");e.write(" * }");break}e.write("array{"),this.internalType.entries.forEach((i,s)=>{s>0&&e.write(", "),this.writeTypeDictEntry({writer:e,entry:i,comment:o})}),e.write("}");break}case"union":{this.writeUnion({writer:e,unionTypes:this.internalType.types,comment:o});break}case"optional":{let i=this.internalType.value.internalType,s=i.type==="mixed",p=i.type==="union";!p&&!s&&e.write("?"),this.internalType.value.write(e,{comment:o}),p&&!this.unionHasOptional(i.types)&&(e.write("|"),e.writeNode(r.null()));break}case"reference":if(o){e.writeNode(this.internalType.value);let i=this.internalType.value.generics;i&&i.length>0&&(e.write("<"),i.forEach((s,p)=>{p>0&&e.write(", "),s.write(e,{comment:o})}),e.write(">"))}else e.writeNode(this.internalType.value);break;case"enumString":o?(e.write("value-of<"),e.writeNode(this.internalType.value),e.write(">")):e.write("string");break;case"literal":if(o)e.writeNode(this.internalType.value);else switch(this.internalType.value.internalType.type){case"string":e.write("string");break;case"boolean":e.write("bool");break;default:$(this.internalType.value.internalType)}break;default:$(this.internalType)}}toOptionalIfNotAlready(){return this.internalType.type==="optional"?this:r.optional(this)}underlyingTypeIfOptional(){if(this.internalType.type==="optional")return this.internalType.value}underlyingType(){var e;return(e=this.underlyingTypeIfOptional())!=null?e:this}isOptional(){return this.internalType.type==="optional"}getClassReference(){switch(this.internalType.type){case"date":case"dateTime":return new _({name:"DateTime",namespace:""});case"enumString":case"reference":return this.internalType.value;case"int":case"string":case"bool":case"float":case"object":case"map":case"array":case"null":case"mixed":case"optional":case"typeDict":case"union":case"literal":throw new Error("Cannot get class reference for "+this.internalType.type);default:$(this.internalType)}}static int(){return new this({type:"int"})}static string(){return new this({type:"string"})}static bool(){return new this({type:"bool"})}static float(){return new this({type:"float"})}static date(){return new this({type:"date"})}static dateTime(){return new this({type:"dateTime"})}static mixed(){return new this({type:"mixed"})}static object(){return new this({type:"object"})}static array(e){return new this({type:"array",value:e})}static map(e,o){return new this({type:"map",keyType:e,valueType:o})}static typeDict(e,{multiline:o}={}){return new this({type:"typeDict",entries:e,multiline:o})}static union(e){let o=this.flattenUnionTypes(e),i=mt(o,ct);return new this({type:"union",types:i})}static flattenUnionTypes(e){let o=[];for(let i of e)i.internalType.type==="union"?o.push(...this.flattenUnionTypes(i.internalType.types)):o.push(i);return o}static optional(e){return this.isAlreadyOptional(e)?e:new this({type:"optional",value:e})}static null(){return new this({type:"null"})}static reference(e){return new this({type:"reference",value:e})}static enumString(e){return new this({type:"enumString",value:e})}static literalString(e){return new this({type:"literal",value:O.string(e)})}static literalBoolean(e){return new this({type:"literal",value:O.boolean(e)})}static isAlreadyOptional(e){return e.internalType.type==="optional"}writeUnion({writer:e,unionTypes:o,comment:i}){let s=this.getUniqueTypes({types:o,comment:i,writer:e}),p=this.unwrapOptionalTypes(s),l=p.filter(m=>m.underlyingType().internalType.type==="mixed").length>0;if(l&&!i){e.write("mixed");return}if(p.length>0&&i){e.writeLine("("),p.forEach((m,d)=>{d>0?e.write(" * |"):e.write(" * "),l&&(m=m.underlyingType()),m.write(e,{comment:i}),e.writeLine(),d++}),e.write(" * )");return}p.forEach((m,d)=>{d>0&&e.write("|"),l&&(m=m.underlyingType()),m.write(e,{comment:i}),d++})}writeTypeDictEntry({writer:e,entry:o,comment:i}){e.write(o.key),o.optional&&e.write("?"),e.write(": "),o.valueType.write(e,{comment:i})}getUniqueTypes({writer:e,types:o,comment:i}){let s=mt(o,ct),p=new Set;return s.filter(l=>{let m=l.toString({namespace:e.namespace,rootNamespace:e.rootNamespace,customConfig:e.customConfig,comment:i});return p.has(m)?!1:(p.add(m),!0)})}unwrapOptionalTypes(e){let o=!1,i=e.map(s=>s.internalType.type==="optional"?(o=!0,s.internalType.value):s);return o&&i.push(r.null()),i}unionHasOptional(e){return e.filter(o=>o.internalType.type==="optional").length>0}toString({namespace:e,rootNamespace:o,customConfig:i,comment:s}){let p=new U({namespace:e,rootNamespace:o,customConfig:i});return this.write(p,{comment:s!=null?s:!1}),p.toString()}},Uo=new _({namespace:"",name:"DateTime"});n();a();function Do(r){return r.startsWith("$")?r.slice(1):r}var Fo="values",we=class extends y{constructor({name:e,namespace:o,abstract:i,docs:s,parentClassReference:p,traits:l,constructorAccess:m}){super();c(this,"name");c(this,"namespace");c(this,"constructorAccess");c(this,"class_");this.name=e,this.namespace=o,this.constructorAccess=m!=null?m:"public",this.class_=new V({name:e,namespace:o,abstract:i,docs:s,parentClassReference:p,traits:l})}addField(e){this.class_.addField(e)}addMethod(e){this.class_.addMethod(e)}addTrait(e){this.class_.addTrait(e)}write(e){let o=fe(this.class_.fields).map(i=>$e(je({},i),{name:Do(i.name)}));o.length>0&&this.class_.addConstructor({access:this.constructorAccess,parameters:this.getConstructorParameters({orderedFields:o}),body:R.codeblock(i=>{for(let s of o)i.write(`$this->${s.name} = $${Fo}['${s.name}']`),s.type.isOptional()&&i.write(" ?? null"),i.write(";")})}),this.class_.write(e)}allFieldsAreOptional(){return this.class_.fields.every(e=>e.type.isOptional())}getConstructorParameters({orderedFields:e}){return[new K({name:Fo,type:B.typeDict(e.map(o=>({key:o.name,valueType:o.type,optional:o.type.isOptional()})),{multiline:!0}),initializer:this.allFieldsAreOptional()?new E("[]"):void 0})]}};n();a();n();a();var Q=class extends y{constructor({name:e,access:o,parameters:i,throws:s,return_:p,body:l,docs:m,classReference:d,static_:h}){super();c(this,"name");c(this,"access");c(this,"parameters");c(this,"throws");c(this,"return_");c(this,"body");c(this,"docs");c(this,"classReference");c(this,"static_");this.name=e,this.access=o,this.parameters=i,this.throws=s!=null?s:[],this.return_=p,this.body=l,this.docs=m,this.classReference=d,this.static_=h!=null?h:!1}write(e){var p;this.writeComment(e),e.write(`${this.access}${this.static_?" static":""} function ${this.name}(`);let o=this.parameters.filter(l=>!l.type.isOptional()),i=this.parameters.filter(l=>l.type.isOptional());[...o,...i].forEach((l,m)=>{m>0&&e.write(", "),l.write(e)}),e.write("): "),this.return_!=null?e.writeNodeOrString(this.return_):e.write("void"),e.writeLine(" {"),e.indent(),(p=this.body)==null||p.write(e),e.dedent(),e.writeLine("}")}writeComment(e){let o=new L({docs:this.docs});for(let i of this.parameters)o.addTag({tagType:"param",type:i.type,name:i.name,docs:i.docs});this.return_!=null&&this.return_!==Po&&this.return_!==Oo&&o.addTag({tagType:"return",type:this.return_});for(let i of this.throws)o.addTag({tagType:"throws",type:B.reference(i)});e.writeNode(o)}};var ge=class extends y{constructor({name:e,namespace:o,backing:i,docs:s,serializable:p}){super();c(this,"name");c(this,"namespace");c(this,"backing");c(this,"docs");c(this,"members",[]);c(this,"serializable");this.name=e,this.namespace=o,this.backing=i,this.docs=s,this.serializable=p!=null?p:!1}addMember(e){this.members.push(e)}write(e){this.writeComment(e),e.write("enum "),e.writeLine(`${this.name}`),this.backing!=null&&e.write(` : ${this.backing}`),this.serializable&&(e.addReference(new _({name:"JsonSerializable",namespace:""})),e.writeLine(" implements JsonSerializable")),e.writeLine(" {"),e.indent();for(let o of this.members)e.write(`case ${o.name}`),o.value!=null&&(typeof o.value=="string"?e.write(` = "${o.value}"`):e.write(` = ${o.value}`)),e.writeTextStatement("");this.serializable&&(e.newLine(),e.writeNode(new Q({name:"jsonSerialize",return_:B.string(),access:"public",parameters:[],body:new E("return $this->value;")}))),e.writeNewLineIfLastLineNot(),e.dedent(),e.writeLine("}")}writeComment(e){if(this.docs==null)return;new L({docs:this.docs}).write(e)}};n();a();var Te=class extends y{constructor({name:e,type:o,access:i,readonly_:s,initializer:p,docs:l,inlineDocs:m,attributes:d,inherited:h}){super();c(this,"name");c(this,"type");c(this,"access");c(this,"readonly_");c(this,"initializer");c(this,"docs");c(this,"inlineDocs");c(this,"attributes");c(this,"inherited");this.name=se(e),this.type=o,this.access=i,this.readonly_=s!=null?s:!1,this.initializer=p,this.docs=l,this.inlineDocs=m,this.attributes=d!=null?d:[],this.inherited=h!=null?h:!1}write(e){this.writeComment(e),this.writeAttributesIfPresent(e),e.write(`${this.access} `),this.readonly_&&e.write("readonly "),this.type.write(e),e.write(` ${this.name}`),this.initializer!=null&&(e.write(" = "),this.initializer.write(e)),e.write(";"),this.inlineDocs!=null&&e.write(` // ${this.inlineDocs}`),e.newLine()}writeComment(e){let o=new L;o.addTag({tagType:"var",type:this.type,name:this.name,docs:this.docs}),o.write(e)}writeAttributesIfPresent(e){this.attributes.length>0&&(e.write("#["),this.attributes.forEach((o,i)=>{i>0&&e.write(", "),o.write(e)}),e.writeLine("]"))}};n();a();var Ae=class extends y{constructor({entries:e,multiline:o}){super();c(this,"entries");c(this,"multiline");this.entries=e!=null?e:[],this.multiline=o!=null?o:!1}write(e){if(this.multiline){this.writeMultiline(e);return}this.writeCompact(e)}writeMultiline(e){e.writeLine("["),e.indent();for(let{key:o,value:i}of this.entries)o.write(e),e.write(" => "),i.write(e),e.writeLine(",");e.dedent(),e.write("]")}writeCompact(e){e.write("[");for(let[o,{key:i,value:s}]of this.entries.entries())o>0&&e.write(", "),i.write(e),e.write(" => "),s.write(e);e.write("]")}};n();a();var ve=class extends y{constructor({name:e,namespace:o,docs:i,traits:s}){super();c(this,"name");c(this,"namespace");c(this,"docs");c(this,"traits");c(this,"fields",[]);c(this,"methods",[]);this.name=e,this.namespace=o,this.docs=i,this.traits=s!=null?s:[]}addField(e){this.fields.push(e)}addMethod(e){this.methods.push(e)}write(e){this.writeComment(e),e.write(`trait ${this.name} `),e.newLine(),e.writeLine("{"),e.indent(),this.traits.length>0&&(e.write("use "),this.traits.forEach((o,i)=>{i>0&&e.write(","),e.writeNode(o)}),e.writeTextStatement(""),e.newLine()),this.writeFields({writer:e,fields:fe(this.fields)}),this.fields.length>0&&this.methods.length>0&&e.newLine(),this.writeMethods({writer:e,methods:fe(this.methods)}),e.dedent(),e.writeLine("}")}writeComment(e){let o=new L({docs:this.docs});for(let i of this.fields)o.addTag({tagType:"property",type:i.type,name:i.name});o.write(e)}writeFields({writer:e,fields:o}){o.forEach((i,s)=>{s>0&&e.newLine(),i.write(e),e.writeNewLineIfLastLineNot()})}writeMethods({writer:e,methods:o}){o.forEach((i,s)=>{s>0&&e.newLine(),i.write(e),e.writeNewLineIfLastLineNot()})}};n();a();var dt=class extends y{constructor(e){super();c(this,"arrays");this.arrays=e}write(e){e.write("array_merge"),Re({writer:e,arguments_:this.arrays.map(o=>be(i=>{if(typeof o=="string"||o instanceof y){i.writeNodeOrString(o);return}i.writeNodeOrString(o.ref),o.fallback&&(i.write(" ?? "),i.writeNodeOrString(o.fallback))}))})}};function Bf(r){return new xe(r)}function kf(r){return new ye(r)}function Mf(r){return new V(r)}function Uf(r){return new ve(r)}function Df(r){return new _(r)}function be(r){return new E(r)}function Ff(r){return new we(r)}function jf(r){return new ge(r)}function $f(r){return new Te(r)}function jo(r){return new D(r)}function Wf(r){return new J(r)}function Yf(r){return be(t=>{t.write("throw "),t.writeNode(jo(r))})}function zf(r){return new Ae(r)}function Gf(r){return new Q(r)}function qf(r){return new K(r)}function Hf(r){return new Me(r)}function Vf(r,t){return be(e=>{e.writeNodeOrString(r),e.write(" = "),e.writeNodeOrString(t)})}function Kf(r){return be(se(r))}function Jf(r){return be(`"${r}"`)}function Qf(...r){return new dt(r)}function Xf(){return new E(r=>{r.write("$this")})}var Ct=class{constructor({context:t}){c(this,"context");this.context=t}getFilePropertyInfo({body:t,value:e}){var s;let o={fileFields:[],bodyPropertyFields:[]},i=(s=this.context.getRecord(e))!=null?s:{};for(let p of t.properties)switch(p.type){case"file":o.fileFields.push({name:this.context.getPropertyName(p.name),value:this.getSingleFileProperty({property:p,record:i})});break;case"fileArray":o.fileFields.push({name:this.context.getPropertyName(p.name),value:this.getArrayFileProperty({property:p,record:i})});break;case"bodyProperty":o.bodyPropertyFields.push({name:this.context.getPropertyName(p.name.name),value:this.getBodyProperty({property:p,record:i})});break;default:$(p)}return o}getSingleFileProperty({property:t,record:e}){let o=this.context.getSingleFileValue({property:t,record:e});return o==null?R.TypeLiteral.nop():R.TypeLiteral.file(o)}getArrayFileProperty({property:t,record:e}){let o=this.context.getFileArrayValues({property:t,record:e});return o==null?R.TypeLiteral.nop():R.TypeLiteral.list({values:o.map(i=>R.TypeLiteral.file(i))})}getBodyProperty({property:t,record:e}){let o=e[t.name.wireValue];return o==null?R.TypeLiteral.nop():this.context.dynamicTypeLiteralMapper.convert({typeReference:t.typeReference,value:o})}};0&&(module.exports={FilePropertyMapper});
19
19
  /*! Bundled license information:
20
20
 
21
21
  @esbuild-plugins/node-globals-polyfill/Buffer.js:
@@ -25,4 +25,16 @@ ${this.buffer}`:e+`
25
25
  * @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org>
26
26
  * @license MIT
27
27
  *)
28
+
29
+ lodash-es/lodash.js:
30
+ (**
31
+ * @license
32
+ * Lodash (Custom Build) <https://lodash.com/>
33
+ * Build: `lodash modularize exports="es" -o ./`
34
+ * Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
35
+ * Released under MIT license <https://lodash.com/license>
36
+ * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
37
+ * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
38
+ *)
28
39
  */
40
+ //# sourceMappingURL=FilePropertyMapper.cjs.map