text: !function(e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).avro=e()}(function(){return function n(o,i,a){function s(t,e){if(!i[t]){if(!o[t]){var r="function"==typeof require&&require;if(!e&&r)return r(t,!0);if(u)return u(t,!0);throw(r=new Error("Cannot find module '"+t+"'")).code="MODULE_NOT_FOUND",r}r=i[t]={exports:{}},o[t][0].call(r.exports,function(e){return s(o[t][1][e]||e)},r,r.exports,n,o,i,a)}return i[t].exports}for(var u="function"==typeof require&&require,e=0;e<a.length;e++)s(a[e]);return s}({1:[function(e,t,r){"use strict";var n=e("./avsc-types"),o=e("../../lib/services"),i=e("../../lib/specs"),e=e("../../lib/utils");t.exports={Service:o.Service,assembleProtocol:i.assembleProtocol,discoverProtocol:o.discoverProtocol,parse:function(e,t){return(e=i.read(e)).protocol?o.Service.forProtocol(e,t):n.Type.forSchema(e,t)},readProtocol:i.readProtocol,readSchema:i.readSchema},e.copyOwnProperties(n,t.exports)},{"../../lib/services":5,"../../lib/specs":6,"../../lib/utils":8,"./avsc-types":2}],2:[function(e,t,r){"use strict";var n=e("../../lib/types");t.exports={Type:n.Type,parse:function(t,e){var r;if("string"==typeof t)try{r=JSON.parse(t)}catch(e){r=t}else r=t;return n.Type.forSchema(r,e)},types:n.builtins,combine:n.Type.forTypes,infer:n.Type.forValue}},{"../../lib/types":7}],3:[function(e,r,t){(function(o){(function(){"use strict";function t(){this.data=void 0}function i(e,t){var r=a(r=e[0],i=e[1],o=e[2],n=e[3],t[0],7,-680876936),n=a(n,r,i,o,t[1],12,-389564586),o=a(o,n,r,i,t[2],17,606105819),i=a(i,o,n,r,t[3],22,-1044525330);r=a(r,i,o,n,t[4],7,-176418897),n=a(n,r,i,o,t[5],12,1200080426),o=a(o,n,r,i,t[6],17,-1473231341),i=a(i,o,n,r,t[7],22,-45705983),r=a(r,i,o,n,t[8],7,1770035416),n=a(n,r,i,o,t[9],12,-1958414417),o=a(o,n,r,i,t[10],17,-42063),i=a(i,o,n,r,t[11],22,-1990404162),r=a(r,i,o,n,t[12],7,1804603682),n=a(n,r,i,o,t[13],12,-40341101),o=a(o,n,r,i,t[14],17,-1502002290),r=u(r,i=a(i,o,n,r,t[15],22,1236535329),o,n,t[1],5,-165796510),n=u(n,r,i,o,t[6],9,-1069501632),o=u(o,n,r,i,t[11],14,643717713),i=u(i,o,n,r,t[0],20,-373897302),r=u(r,i,o,n,t[5],5,-701558691),n=u(n,r,i,o,t[10],9,38016083),o=u(o,n,r,i,t[15],14,-660478335),i=u(i,o,n,r,t[4],20,-405537848),r=u(r,i,o,n,t[9],5,568446438),n=u(n,r,i,o,t[14],9,-1019803690),o=u(o,n,r,i,t[3],14,-187363961),i=u(i,o,n,r,t[8],20,1163531501),r=u(r,i,o,n,t[13],5,-1444681467),n=u(n,r,i,o,t[2],9,-51403784),o=u(o,n,r,i,t[7],14,1735328473),r=c(r,i=u(i,o,n,r,t[12],20,-1926607734),o,n,t[5],4,-378558),n=c(n,r,i,o,t[8],11,-2022574463),o=c(o,n,r,i,t[11],16,1839030562),i=c(i,o,n,r,t[14],23,-35309556),r=c(r,i,o,n,t[1],4,-1530992060),n=c(n,r,i,o,t[4],11,1272893353),o=c(o,n,r,i,t[7],16,-155497632),i=c(i,o,n,r,t[10],23,-1094730640),r=c(r,i,o,n,t[13],4,681279174),n=c(n,r,i,o,t[0],11,-358537222),o=c(o,n,r,i,t[3],16,-722521979),i=c(i,o,n,r,t[6],23,76029189),r=c(r,i,o,n,t[9],4,-640364487),n=c(n,r,i,o,t[12],11,-421815835),o=c(o,n,r,i,t[15],16,530742520),r=f(r,i=c(i,o,n,r,t[2],23,-995338651),o,n,t[0],6,-198630844),n=f(n,r,i,o,t[7],10,1126891415),o=f(o,n,r,i,t[14],15,-1416354905),i=f(i,o,n,r,t[5],21,-57434055),r=f(r,i,o,n,t[12],6,1700485571),n=f(n,r,i,o,t[3],10,-1894986606),o=f(o,n,r,i,t[10],15,-1051523),i=f(i,o,n,r,t[1],21,-2054922799),r=f(r,i,o,n,t[8],6,1873313359),n=f(n,r,i,o,t[15],10,-30611744),o=f(o,n,r,i,t[6],15,-1560198380),i=f(i,o,n,r,t[13],21,1309151649),r=f(r,i,o,n,t[4],6,-145523070),n=f(n,r,i,o,t[11],10,-1120210379),o=f(o,n,r,i,t[2],15,718787259),i=f(i,o,n,r,t[9],21,-343485551),e[0]=p(r,e[0]),e[1]=p(i,e[1]),e[2]=p(o,e[2]),e[3]=p(n,e[3])}function s(e,t,r,n,o,i){return t=p(p(t,e),p(n,i)),p(t<<o|t>>>32-o,r)}function a(e,t,r,n,o,i,a){return s(t&r|~t&n,e,t,o,i,a)}function u(e,t,r,n,o,i,a){return s(t&n|r&~n,e,t,o,i,a)}function c(e,t,r,n,o,i,a){return s(t^r^n,e,t,o,i,a)}function f(e,t,r,n,o,i,a){return s(r^(t|~n),e,t,o,i,a)}function p(e,t){return e+t&4294967295}t.prototype.end=function(e){this.data=e},t.prototype.read=function(){return function(e){var t,r=function(e){var t,r=e.length,n=[1732584193,-271733879,-1732584194,271733878];for(t=64;t<=e.length;t+=64)i(n,function(e){var t,r=[];for(t=0;t<64;t+=4)r[t>>2]=e.charCodeAt(t)+(e.charCodeAt(t+1)<<8)+(e.charCodeAt(t+2)<<16)+(e.charCodeAt(t+3)<<24);return r}(e.substring(t-64,t)));e=e.substring(t-64);var o=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];for(t=0;t<e.length;t++)o[t>>2]|=e.charCodeAt(t)<<(t%4<<3);if(o[t>>2]|=128<<(t%4<<3),55<t)for(i(n,o),t=0;t<16;t++)o[t]=0;return o[14]=8*r,i(n,o),n}(e),n=o.alloc?o.alloc(16):new o(16);for(t=0;t<4;t++)n.writeIntLE(r[t],4*t,4);return n}(this.data)},r.exports={createHash:function(e){if("md5"!==e)throw new Error("only md5 is supported in the browser");return new t}}}).call(this)}).call(this,e("buffer").Buffer)},{buffer:13}],4:[function(e,t,r){"use strict";function n(){return new Error("unsupported in the browser")}t.exports={createImportHook:function(){return function(e,t,r){r(n())}},createSyncImportHook:function(){return function(){throw n()}},existsSync:function(){return!1},readFileSync:function(){throw n()}}},{}],5:[function(X,ee,e){(function(Z,Q){(function(){"use strict";var e=X("./types"),l=X("./utils"),o=X("events"),i=X("stream"),t=X("util"),a=l.Tap,u=e.Type,h=t.debuglog("avsc:services"),p=t.format,s={namespace:"org.apache.avro.ipc"},c=u.forSchema("boolean",s),d=u.forSchema({type:"map",values:"bytes"},s),f=u.forSchema("string",s),y=u.forSchema({name:"HandshakeRequest",type:"record",fields:[{name:"clientHash",type:{name:"MD5",type:"fixed",size:16}},{name:"clientProtocol",type:["null","string"],default:null},{name:"serverHash",type:"MD5"},{name:"meta",type:["null",d],default:null}]},s),g=u.forSchema({name:"HandshakeResponse",type:"record",fields:[{name:"match",type:{name:"HandshakeMatch",type:"enum",symbols:["BOTH","CLIENT","NONE"]}},{name:"serverProtocol",type:["null","string"],default:null},{name:"serverHash",type:["null","MD5"],default:null},{name:"meta",type:["null",d],default:null}]},s),m=16,v=new b("",u.forSchema({name:"PingRequest",type:"record",fields:[]},s),u.forSchema(["string"],s),u.forSchema("null",s));function b(e,t,r,n,o,i){if(this.name=e,!u.isType(t,"record"))throw new Error("invalid request type");if(this.requestType=t,!u.isType(r,"union")||!u.isType(r.getTypes()[0],"string"))throw new Error("invalid error type");if(this.errorType=r,o&&(!u.isType(n,"null")||1<r.getTypes().length))throw new Error("inapplicable one-way parameter");this.responseType=n,this.oneWay=!!o,this.doc=void 0!==i?""+i:void 0,Object.freeze(this)}function _(e,t,r,n,o){if("string"!=typeof e)return _.forProtocol(e,t);this.name=e,this._messagesByName=t||{},this.messages=Object.freeze(l.objectValues(this._messagesByName)),this._typesByName=r||{},this.types=Object.freeze(l.objectValues(this._typesByName)),this.protocol=n,this._hashStr=l.getHash(JSON.stringify(n)).toString("binary"),this.doc=n.doc?""+n.doc:void 0,this._server=o||this.createServer({silent:!0}),Object.freeze(this)}function w(e,t){t=t||{},o.EventEmitter.call(this),this._svc$=e,this._channels$=[],this._fns$=[],this._buffering$=!!t.buffering,this._cache$=t.cache||{},this._policy$=t.channelPolicy,this._strict$=!!t.strictTypes,this._timeout$=l.getOption(t,"timeout",1e4),t.remoteProtocols&&n(this._cache$,t.remoteProtocols,e,!0),this._svc$.messages.forEach(function(e){this[e.name]=this._createMessageHandler$(e)},this)}function r(e,r){r=r||{},o.EventEmitter.call(this),this.service=e,this._handlers={},this._fns=[],this._channels={},this._nextChannelId=1,this._cache=r.cache||{},this._defaultHandler=r.defaultHandler,this._sysErrFormatter=r.systemErrorFormatter,this._silent=!!r.silent,this._strict=!!r.strictTypes,r.remoteProtocols&&n(this._cache,r.remoteProtocols,e,!1),e.messages.forEach(function(e){var t=e.name;r.noCapitalize||(t=l.capitalize(t)),this["on"+t]=this._createMessageHandler(e)},this)}function S(e,t){t=t||{},o.EventEmitter.call(this),this.client=e,this.timeout=l.getOption(t,"timeout",e._timeout$),this._endWritable=!!l.getOption(t,"endWritable",!0),this._prefix=$(t.scope);var r=e._cache$,n=e._svc$,e=t.serverHash,t=(t=r[e=e||n.hash])||(r[e=n.hash]=new B(n,n,e));this._adapter=t,this._registry=new R(this,m),this.pending=0,this.destroyed=!1,this.draining=!1,this.once("_eot",function(e,t){h("client channel EOT"),this.destroyed=!0,this.emit("eot",e,t)})}function E(e,t,r){S.call(this,e,r),this._writableFactory=t,r&&r.noPing||(h("emitting ping request"),this.ping())}function A(e,t,r,n){S.call(this,e,n),this._readable=t,this._writable=r,this._connected=!(!n||!n.noPing),this._readable.on("end",f),this._writable.on("finish",p);var o,i=this,a=null;function s(e){i.destroyed||(o=i._createHandshakeRequest(i._adapter,!e),e=[y.toBuffer(o),l.bufferFrom([0,0])],i._writable.write({id:i._prefix,payload:e}))}function u(e){if(i._matchesPrefix(e.id)){var t=Q.concat(e.payload);try{var r=F(g,t).head;r.serverHash&&(i._adapter=i._getAdapter(r))}catch(e){return void i.destroy(e)}var n=r.match;h("handshake match: %s",n),i.emit("handshake",o,r),"NONE"===n?Z.nextTick(function(){s(!0)}):(h("successfully connected"),a&&(clearTimeout(a),a=null),i._readable.removeListener("data",u).on("data",c),i._connected=!0,i.emit("_ready"),o=null)}else h("discarding unscoped response %s (still connecting)",e.id)}function c(e){var t,r=e.id;i._matchesPrefix(r)?(t=i._registry.get(r))&&Z.nextTick(function(){h("received message %s",r),t(null,Q.concat(e.payload),i._adapter)}):h("discarding unscoped message %s",r)}function f(){i.destroy(!0)}function p(){i.destroy()}this.once("eot",function(){a&&(clearTimeout(a),a=null),i._connected||i.emit("_ready"),this._writable.removeListener("finish",p),this._endWritable&&(h("ending transport"),this._writable.end()),this._readable.removeListener("data",u).removeListener("data",c).removeListener("end",f)}),this._connected?this._readable.on("data",c):(this._readable.on("data",u),Z.nextTick(s),i.timeout&&(a=setTimeout(function(){i.destroy(new Error("timeout"))},i.timeout)))}function k(e,t){t=t||{},o.EventEmitter.call(this),this.server=e,this._endWritable=!!l.getOption(t,"endWritable",!0),this._prefix=$(t.scope);var r=e._cache,t=e.service,e=t.hash;r[e]||(r[e]=new B(t,t,e)),this._adapter=null,this.destroyed=!1,this.draining=!1,this.pending=0,this.once("_eot",function(e,t){h("server channel EOT"),this.emit("eot",e,t)})}function T(e,t,r){k.call(this,e,r),this._writable=void 0;var n,c=this;function o(e){var t,r=e.id,n=Q.concat(e.payload);try{var o=F(y,n),i=o.head,a=c._getAdapter(i)}catch(e){t=z("INVALID_HANDSHAKE_REQUEST",e)}var s=c._createHandshakeResponse(t,i);function u(e){if(!c.destroyed){if(!c._writable)return void c.once("_writable",function(){u(e)});c._writable.write({id:r,payload:[g.toBuffer(s),e]})}c._writable&&c._endWritable&&c._writable.end()}c.emit("handshake",i,s),t?u(c._encodeSystemError(t)):c._receive(o.tail,a,u)}function i(){c.destroy()}function a(e){n.removeListener("data",o).removeListener("end",i),c.destroy(e||!0)}Z.nextTick(function(){n=t.call(c,function(e,t){Z.nextTick(function(){e?a(e):(c._writable=t.on("finish",a),c.emit("_writable"))})}).on("data",o).on("end",i)})}function x(e,t,r,n){k.call(this,e,n),this._adapter=void 0,this._writable=r.on("finish",i),this._readable=t.on("data",c).on("end",o),this.once("_drain",function(){this._readable.removeListener("data",c).removeListener("data",f).removeListener("end",o)}).once("eot",function(){this._writable.removeListener("finish",i),this._endWritable&&this._writable.end()});var u=this;function c(e){var t=e.id;if(u._matchesPrefix(t)){var r,n=Q.concat(e.payload);try{var o=F(y,n),i=o.head;u._adapter=u._getAdapter(i)}catch(e){r=z("INVALID_HANDSHAKE_REQUEST",e)}var a=u._createHandshakeResponse(r,i);u.emit("handshake",i,a),r?s(u._encodeSystemError(r)):(u._readable.removeListener("data",c).on("data",f),u._receive(o.tail,u._adapter,s))}function s(e){u.destroyed||u._writable.write({id:t,payload:[g.toBuffer(a),e]})}}function f(e){var r=e.id;u._matchesPrefix(r)&&(e=Q.concat(e.payload),u._receive(e,u._adapter,function(e,t){u.destroyed||t||u._writable.write({id:r,payload:[e]})}))}function o(){u.destroy()}function i(){u.destroy(!0)}}function O(e,t,r){this._msg=e,this.headers=t||{},this.request=r||{}}function j(e,t,r,n){this._msg=e,this.headers=t,this.error=r,this.response=n}function P(e,t){this.channel=t,this.locals={},this.message=e,Object.freeze(this)}function R(e,t){this._ctx=e,this._mask=-1>>>(0|t),this._id=0,this._n=0,this._cbs={}}function B(e,t,r,n){this._clientSvc=e,this._serverSvc=t,this._hash=r,this._isRemote=!!n,this._readers=D(e,t)}function N(){i.Transform.call(this,{readableObjectMode:!0}),this._id=void 0,this._buf=l.newBuffer(0),this._bufs=[],this.on("finish",function(){this.push(null)})}function I(){i.Transform.call(this,{writableObjectMode:!0}),this.on("finish",function(){this.push(null)})}function C(){i.Transform.call(this,{readableObjectMode:!0}),this._id=void 0,this._frameCount=0,this._buf=l.newBuffer(0),this._bufs=[],this.on("finish",function(){this.push(null)})}function L(){i.Transform.call(this,{writableObjectMode:!0}),this.on("finish",function(){this.push(null)})}function M(e){var t=l.newBuffer(4);return t.writeInt32BE(e),t}function F(e,t){var r=new a(t),t=e._read(r);if(!r.isValid())throw new Error(p("truncated %j",e.schema()));return{head:t,tail:r.buf.slice(r.pos)}}function U(e,t){return e.equals(t)?e:e.createResolver(t)}function D(e,n){var o={};return e.messages.forEach(function(e){var t=e.name,r=n.message(t);try{if(!r)throw new Error(p("missing server message: %s",t));if(r.oneWay!==e.oneWay)throw new Error(p("inconsistent one-way message: %s",t));o[t+"?"]=U(r.requestType,e.requestType),o[t+"*"]=U(e.errorType,r.errorType),o[t+"!"]=U(e.responseType,r.responseType)}catch(e){throw z("INCOMPATIBLE_PROTOCOL",e)}}),o}function n(n,o,i,a){Object.keys(o).forEach(function(e){var t,r=o[e],r=a?(t=i,_.forProtocol(r)):(t=_.forProtocol(r),i);n[e]=new B(t,r,e,!0)})}function W(r,n){var o={};return Object.keys(r).forEach(function(e){var t=r[e];t._isRemote&&(t=n?t._serverSvc:t._clientSvc,o[e]=t.protocol)}),o}function V(e){return e&&"[object Error]"===Object.prototype.toString.call(e)}function q(e,t){e=new Error(e);return e.cause=t,e}function z(e,t){var r=q(e.toLowerCase().replace(/_/g," "),t);return r.rpcCode=t&&t.rpcCode?t.rpcCode:e,r}function H(e,t,r){for(var s,u=[],n=0,o=r.length;n<o;n++)(s=r[n]).type.isValid(t[s.name],{errorHook:a});var i=u.map(function(e){return p("%s = %j but expected %s",e.path,e.value,e.type)}).join(", "),i=new Error(p("%s (%s)",e,i));return i.details=u,i;function a(e,t,r){for(var n,o=[],i=0,a=e.length;i<a;i++)n=e[i],isNaN(n)?o.push("."+n):o.push("["+n+"]");u.push({path:s.name+o.join(""),value:t,type:r})}}function $(e){return e?l.getHash(e).readInt16BE(0)<<32-m:0}function J(e,t){return(e^t)>>32-m==0}function G(e){return e&&e.pipe}function K(e,t){e=e.message(t);if(!e)throw new Error(p("unknown message: %s",t));return e}function Y(i){var a,e=[i.wreq,i.wres],s=[];function u(){var t,e=s.pop();e?(t=!1,e.call(i.ctx,a,function(e){t?i.onError(q("duplicate backward middleware call",e)):(a=e,t=!0,u())})):i.onCompletion.call(i.ctx,a)}!function r(n){var o=!1;n<i.fns.length?i.fns[n].apply(i.ctx,e.concat(function(e,t){if(o)i.onError(q("duplicate forward middleware call",e));else{if(o=!0,e||i.wres&&(void 0!==i.wres.error||void 0!==i.wres.response))return a=e,void u();t&&s.push(t),r(++n)}})):i.onTransition.apply(i.ctx,e.concat(function(e){o?i.onError(q("duplicate handler call",e)):(o=!0,a=e,Z.nextTick(u))}))}(0)}b.forSchema=function(e,t,r){if(r=r||{},!l.isValidName(e))throw new Error(p("invalid message name: %s",e));if(!Array.isArray(t.request))throw new Error(p("invalid message request: %s",e));var n=p("%s.%sRequest",s.namespace,l.capitalize(e)),o=u.forSchema({name:n,type:"record",namespace:r.namespace||"",fields:t.request},r);if(delete r.registry[n],!t.response)throw new Error(p("invalid message response: %s",e));n=u.forSchema(t.response,r);if(void 0!==t.errors&&!Array.isArray(t.errors))throw new Error(p("invalid message errors: %s",e));return new b(e,o,u.forSchema(["string"].concat(t.errors||[]),r),n,!!t["one-way"],t.doc)},b.prototype.schema=u.prototype.getSchema,b.prototype._attrs=function(e){var t={request:this.requestType._attrs(e).fields,response:this.responseType._attrs(e)},r=this.doc;void 0!==r&&(t.doc=r);e=this.errorType._attrs(e);return 1<e.length&&(t.errors=e.slice(1)),this.oneWay&&(t["one-way"]=!0),t},l.addDeprecatedGetters(b,["name","errorType","requestType","responseType"]),b.prototype.isOneWay=t.deprecate(function(){return this.oneWay},"use `.oneWay` directly instead of `.isOneWay()`"),_.Client=w,_.Server=r,_.compatible=function(e,t){try{D(e,t)}catch(e){return!1}return!0},_.forProtocol=function(t,r){r=r||{};var e,n,o=t.protocol;if(!o)throw new Error("missing protocol name");return void 0!==t.namespace?r.namespace=t.namespace:(e=/^(.*)\.[^.]+$/.exec(o))&&(r.namespace=e[1]),o=l.qualify(o,r.namespace),t.types&&t.types.forEach(function(e){u.forSchema(e,r)}),t.messages&&(n={},Object.keys(t.messages).forEach(function(e){n[e]=b.forSchema(e,t.messages[e],r)})),new _(o,n,r.registry,t)},_.isService=function(e){return!!e&&e.hasOwnProperty("_hashStr")},_.prototype.createClient=function(r){var n=new w(this,r);return Z.nextTick(function(){var e,t;r&&r.server?(e={objectMode:!0},t=[new i.PassThrough(e),new i.PassThrough(e)],r.server.createChannel({readable:t[0],writable:t[1]},e),n.createChannel({readable:t[1],writable:t[0]},e)):r&&r.transport&&n.createChannel(r.transport)}),n},_.prototype.createServer=function(e){return new r(this,e)},Object.defineProperty(_.prototype,"hash",{enumerable:!0,get:function(){return l.bufferFrom(this._hashStr,"binary")}}),_.prototype.message=function(e){return this._messagesByName[e]},_.prototype.type=function(e){return this._typesByName[e]},_.prototype.inspect=function(){return p("<Service %j>",this.name)},l.addDeprecatedGetters(_,["message","messages","name","type","types"]),_.prototype.createEmitter=t.deprecate(function(e,t){t=t||{};var r,n,o=this.createClient({cache:t.cache,buffering:!1,strictTypes:t.strictErrors,timeout:t.timeout}),t=o.createChannel(e,t);return n=t,(r=o).on("error",function(e){n.emit("error",e,r)}),t},"use `.createClient()` instead of `.createEmitter()`"),_.prototype.createListener=t.deprecate(function(e,t){if(t&&t.strictErrors)throw new Error("use `.createServer()` to support strict errors");return this._server.createChannel(e,t)},"use `.createServer().createChannel()` instead of `.createListener()`"),_.prototype.emit=t.deprecate(function(e,t,r,n){if(!r||!this.equals(r.client._svc$))throw new Error("invalid emitter");var o=r.client;return w.prototype.emitMessage.call(o,e,t,n&&n.bind(this)),r.getPending()},"create a client via `.createClient()` to emit messages instead of `.emit()`"),_.prototype.equals=t.deprecate(function(e){return _.isService(e)&&this.getFingerprint().equals(e.getFingerprint())},"equality testing is deprecated, compare the `.protocol`s instead"),_.prototype.getFingerprint=t.deprecate(function(e){return l.getHash(JSON.stringify(this.protocol),e)},"use `.hash` instead of `.getFingerprint()`"),_.prototype.getSchema=t.deprecate(u.prototype.getSchema,"use `.protocol` instead of `.getSchema()`"),_.prototype.on=t.deprecate(function(e,r){var n=this;return this._server.onMessage(e,function(e,t){return r.call(n,e,this.channel,t)}),this},"use `.createServer().onMessage()` instead of `.on()`"),_.prototype.subprotocol=t.deprecate(function(){var e=this._server,t={strictTypes:e._strict,cache:e._cache},t=new r(e.service,t);return t._handlers=Object.create(e._handlers),new _(this.name,this._messagesByName,this._typesByName,this.protocol,t)},"`.subprotocol()` will be removed in 5.1"),_.prototype._attrs=function(t){var r={protocol:this.name},n=[];this.types.forEach(function(e){void 0===e.getName()||"string"!=typeof(e=e._attrs(t))&&n.push(e)}),n.length&&(r.types=n);var e=Object.keys(this._messagesByName);return e.length&&(r.messages={},e.forEach(function(e){r.messages[e]=this._messagesByName[e]._attrs(t)},this)),t&&t.exportAttrs&&void 0!==this.doc&&(r.doc=this.doc),r},t.inherits(w,o.EventEmitter),w.prototype.activeChannels=function(){return this._channels$.slice()},w.prototype.createChannel=function(n,e){var o,t,r,i,a,s=e&&e.objectMode;"function"==typeof n?o=new E(this,s?n:function(r){var e=new I,t=n(function(e,t){e?r(e):(e=(new N).once("error",function(e){o.destroy(e)}),r(null,t.pipe(e)))});if(t)return e.pipe(t),e},e):(G(n)?i=t=n:(i=n.readable,t=n.writable),s||(r=new C,i=i.pipe(r),(a=new L).pipe(t),t=a),o=new A(this,i,t,e),s||(o.once("eot",function(){i.unpipe(r),a.unpipe(t)}),r.once("error",function(e){o.destroy(e)})));var u=this._channels$;return u.push(o),o.once("_drain",function(){u.splice(u.indexOf(this),1)}),this._buffering$=!1,this.emit("channel",o),o},w.prototype.destroyChannels=function(t){this._channels$.forEach(function(e){e.destroy(t&&t.noWait)})},w.prototype.emitMessage=function(e,t,r,n){t=new O(K(this._svc$,e),{},t);this._emitMessage$(t,r,n)},w.prototype.remoteProtocols=function(){return W(this._cache$,!0)},Object.defineProperty(w.prototype,"service",{enumerable:!0,get:function(){return this._svc$}}),w.prototype.use=function(){for(var e,t=0,r=arguments.length;t<r;t++)e=arguments[t],this._fns$.push(e.length<3?e(this):e);return this},w.prototype._emitMessage$=function(e,t,i){i||"function"!=typeof t||(i=t,t=void 0);var r,n,a=this,o=this._channels$,s=o.length;if(s){if(void 0===(t=t||{}).timeout&&(t.timeout=this._timeout$),1===s)r=o[0];else if(this._policy$){if(!(r=this._policy$(this._channels$.slice())))return void h("policy returned no channel, skipping call")}else r=o[Math.floor(Math.random()*s)];r._emit(e,t,function(e,t){var r=this,n=r.message.errorType;if(e)return a._strict$&&(e=n.clone(e.message,{wrapUnions:!0})),void o(e);function o(e,t){i?i.call(r,e,t):e&&a.emit("error",e)}t?(e=t.error,a._strict$||(void 0===e?e=null:u.isType(n,"union:unwrapped")?"string"==typeof e&&(e=new Error(e)):e&&e.string&&"string"==typeof e.string&&(e=new Error(e.string))),o(e,t.response)):o()})}else this._buffering$?(h("no active client channels, buffering call"),this.once("channel",function(){this._emitMessage$(e,t,i)})):(n=new Error("no active channels"),Z.nextTick(function(){i?i.call(new P(e._msg),n):a.emit("error",n)}))},w.prototype._createMessageHandler$=function(e){var t=e.requestType.getFields().map(function(e){return e.getName()}),r="return function "+e.name+"(";return t.length&&(r+=t.join(", ")+", "),r+="opts, cb) {\n",r+="  var req = {",r+=t.map(function(e){return e+": "+e}).join(", "),r+="};\n",r+="  return this.emitMessage('"+e.name+"', req, opts, cb);\n",r+="};",new Function(r)()},t.inherits(r,o.EventEmitter),r.prototype.activeChannels=function(){return l.objectValues(this._channels)},r.prototype.createChannel=function(t,e){var n,r,o,i,a,s=e&&e.objectMode;"function"==typeof t?n=new T(this,s?t:function(r){var e=(new N).once("error",function(e){n.destroy(e)});return t(function(e,t){e?r(e):((e=new I).pipe(t),r(null,e))}).pipe(e)},e):(G(t)?i=r=t:(i=t.readable,r=t.writable),s||(o=new C,i=i.pipe(o),(a=new L).pipe(r),r=a),n=new x(this,i,r,e),s||(n.once("eot",function(){i.unpipe(o),a.unpipe(r)}),o.once("error",function(e){n.destroy(e)}))),this.listeners("error").length||this.on("error",this._onError);var u=this._nextChannelId++,c=this._channels;return c[u]=n.once("eot",function(){delete c[u]}),this.emit("channel",n),n},r.prototype.onMessage=function(e,t){return K(this.service,e),this._handlers[e]=t,this},r.prototype.remoteProtocols=function(){return W(this._cache,!1)},r.prototype.use=function(){for(var e,t=0,r=arguments.length;t<r;t++)e=arguments[t],this._fns.push(e.length<3?e(this):e);return this},r.prototype._createMessageHandler=function(e){var t=e.name,r=e.requestType.fields,n=r.length,e=r.length?", "+r.map(function(e){return"req."+e.name}).join(", "):"",r="return function (handler) {\n";return r+="  if (handler.length > "+n+") {\n",r+="    return this.onMessage('"+t+"', function (req, cb) {\n",r+="      return handler.call(this"+e+", cb);\n",r+="    });\n",r+="  } else {\n",r+="    return this.onMessage('"+t+"', function (req) {\n",r+="      return handler.call(this"+e+");\n",r+="    });\n",r+="  }\n",r+="};\n",new Function(r)()},r.prototype._onError=function(e){this._silent||"UNKNOWN_PROTOCOL"===e.rpcCode||(console.error(),e.rpcCode?(console.error(e.rpcCode),console.error(e.cause)):(console.error("INTERNAL_SERVER_ERROR"),console.error(e)))},t.inherits(S,o.EventEmitter),S.prototype.destroy=function(e){h("destroying client channel"),this.draining||(this.draining=!0,this.emit("_drain"));var t=this._registry,r=this.pending;e&&t.clear(),e||!r?V(e)?(h("fatal client channel error: %s",e),this.emit("_eot",r,e)):this.emit("_eot",r):h("client channel entering drain mode (%s pending)",r)},S.prototype.ping=function(e,t){t||"function"!=typeof e||(t=e,e=void 0);var r=this,n=new O(v);this._emit(n,{timeout:e},function(e){t?t.call(r,e):e&&r.destroy(e)})},S.prototype._createHandshakeRequest=function(e,t){var r=this.client._svc$;return{clientHash:r.hash,clientProtocol:t?null:JSON.stringify(r.protocol),serverHash:e._hash}},S.prototype._emit=function(t,i,r){var a=t._msg,n=a.oneWay?void 0:new j(a,{}),o=new P(a,this),s=this;function u(t,n,o){var e,r;if(s.destroyed)r=new Error("channel destroyed");else try{e=t.toBuffer()}catch(e){r=H(p("invalid %j request",a.name),t,[{name:"headers",type:d},{name:"request",type:a.requestType}])}r?o(r):(r=(i&&void 0!==i.timeout?i:s).timeout,r=s._registry.add(r,function(t,e,r){if(!t&&!a.oneWay)try{r._decodeResponse(e,n,a)}catch(e){t=e}o(t)}),r|=s._prefix,h("sending message %s",r),s._send(r,e,!!a&&a.oneWay))}function c(e){s.pending--,r.call(o,e,n),!s.draining||s.destroyed||s.pending||s.destroy()}function f(e){s.client.emit("error",e,s)}this.pending++,Z.nextTick(function(){var e;a.name?(s.emit("outgoingCall",o,i),e=s.client._fns$,h("starting client middleware chain (%s middleware)",e.length),Y({fns:e,ctx:o,wreq:t,wres:n,onTransition:u,onCompletion:c,onError:f})):u(t,n,c)})},S.prototype._getAdapter=function(e){var t=e.serverHash,r=this.client._cache$;if(n=r[t])return n;var e=JSON.parse(e.serverProtocol),e=_.forProtocol(e),n=new B(this.client._svc$,e,t,!0);return r[t]=n},S.prototype._matchesPrefix=function(e){return J(e,this._prefix)},S.prototype._send=l.abstractFunction,l.addDeprecatedGetters(S,["pending","timeout"]),S.prototype.getCache=t.deprecate(function(){return this.client._cache$},"use `.remoteProtocols()` instead of `.getCache()`"),S.prototype.getProtocol=t.deprecate(function(){return this.client._svc$},"use `.service` instead or `.getProtocol()`"),S.prototype.isDestroyed=t.deprecate(function(){return this.destroyed},"use `.destroyed` instead of `.isDestroyed`"),t.inherits(E,S),E.prototype._send=function(t,r){var a=this._registry.get(t),s=this._adapter,u=this;return Z.nextTick(function o(e){if(u.destroyed)return;var i=u._createHandshakeRequest(s,!e);var e=u._writableFactory.call(u,function(e,t){e?a(e):t.on("data",function(e){h("received response %s",e.id);var t=Q.concat(e.payload);try{var r=F(g,t),n=r.head;n.serverHash&&(s=u._getAdapter(n))}catch(e){return void a(e)}var e=n.match;h("handshake match: %s",e),u.emit("handshake",i,n),"NONE"===e?Z.nextTick(function(){o(!0)}):(u._adapter=s,a(null,r.tail,s))})});if(!e)return void a(new Error("invalid writable stream"));e.write({id:t,payload:[y.toBuffer(i),r]});u._endWritable&&e.end()}),!0},t.inherits(A,S),A.prototype._emit=function(){if(this._connected||this.draining)S.prototype._emit.apply(this,arguments);else{h("queuing request");for(var e=[],t=0,r=arguments.length;t<r;t++)e.push(arguments[t]);this.once("_ready",function(){this._emit.apply(this,e)})}},A.prototype._send=function(e,t,r){var n;return r&&(n=this,Z.nextTick(function(){n._registry.get(e)(null,l.bufferFrom([0,0,0]),n._adapter)})),this._writable.write({id:e,payload:[t]})},t.inherits(k,o.EventEmitter),k.prototype.destroy=function(e){this.draining||(this.draining=!0,this.emit("_drain")),!e&&this.pending||(this.destroyed=!0,V(e)?(h("fatal server channel error: %s",e),this.emit("_eot",this.pending,e)):this.emit("_eot",this.pending))},k.prototype._createHandshakeResponse=function(e,t){var r=this.server.service,n=r.hash,t=t&&t.serverHash.equals(n);return{match:e?"NONE":t?"BOTH":"CLIENT",serverProtocol:t?null:JSON.stringify(r.protocol),serverHash:t?null:n}},k.prototype._getAdapter=function(e){var t=e.clientHash;if(r=this.server._cache[t])return r;if(!e.clientProtocol)throw z("UNKNOWN_PROTOCOL");var e=JSON.parse(e.clientProtocol),r=new B(_.forProtocol(e),this.server.service,t,!0);return this.server._cache[t]=r},k.prototype._matchesPrefix=function(e){return J(e,this._prefix)},k.prototype._receive=function(e,t,o){var r,a=this;try{r=t._decodeRequest(e)}catch(e){return void o(a._encodeSystemError(z("INVALID_REQUEST",e)))}var s=r._msg,i=new j(s,{});if(!s.name)return i.response=null,void o(i.toBuffer(),!1);var u=new P(s,this);a.emit("incomingCall",u);var n=this.server._fns;function c(e){a.server.emit("error",e,a)}h("starting server middleware chain (%s middleware)",n.length),a.pending++,Y({fns:n,ctx:u,wreq:r,wres:i,onTransition:function(e,r,n){var t=a.server._handlers[s.name];if(t){var o=!s.oneWay;try{o?t.call(u,e.request,function(e,t){o=!1,r.error=e,r.response=t,n()}):(t.call(u,e.request),n())}catch(e){o?(o=!1,n(e)):c(e)}}else{var i=a.server._defaultHandler;i?i.call(u,e,r,n):(i=new Error(p("no handler for %s",s.name)),n(z("NOT_IMPLEMENTED",i)))}},onCompletion:function(t){a.pending--;var e,r=a.server;if(!t){var n=i.error;r._strict||(V(n)?i.error=s.errorType.clone(n.message,{wrapUnions:!0}):null===n&&(n=i.error=void 0),void 0===n&&void 0===i.response&&s.responseType.isValid(null)&&(i.response=null));try{e=i.toBuffer()}catch(e){t=void 0!==i.error?H(p("invalid %j error",s.name),i,[{name:"headers",type:d},{name:"error",type:s.errorType}]):H(p("invalid %j response",s.name),i,[{name:"headers",type:d},{name:"response",type:s.responseType}])}}e?void 0!==n&&r.emit("error",z("APPLICATION_ERROR",n)):e=a._encodeSystemError(t,i.headers);o(e,s.oneWay),a.draining&&!a.pending&&a.destroy()},onError:c})},l.addDeprecatedGetters(k,["pending"]),k.prototype.getCache=t.deprecate(function(){return this.server._cache},"use `.remoteProtocols()` instead of `.getCache()`"),k.prototype.getProtocol=t.deprecate(function(){return this.server.service},"use `.service` instead of `.getProtocol()`"),k.prototype.isDestroyed=t.deprecate(function(){return this.destroyed},"use `.destroyed` instead of `.isDestroyed`"),k.prototype._encodeSystemError=function(e,t){var r,n,o=this.server;if(o.emit("error",e,this),o._sysErrFormatter?r=o._sysErrFormatter.call(this,e):e.rpcCode&&(r=e.message),t)try{n=d.toBuffer(t)}catch(e){o.emit("error",e,this)}return Q.concat([n||l.bufferFrom([0]),l.bufferFrom([1,0]),f.toBuffer(r||"internal server error")])},t.inherits(T,k),t.inherits(x,k),O.prototype.toBuffer=function(){var e=this._msg;return Q.concat([d.toBuffer(this.headers),f.toBuffer(e.name),e.requestType.toBuffer(this.request)])},j.prototype.toBuffer=function(){var e=d.toBuffer(this.headers),t=void 0!==this.error;return Q.concat([e,c.toBuffer(t),t?this._msg.errorType.toBuffer(this.error):this._msg.responseType.toBuffer(this.response)])},R.prototype.get=function(e){return this._cbs[e&this._mask]},R.prototype.add=function(e,t){this._id=this._id+1&this._mask;var r,n=this,o=this._id;return 0<e&&(r=setTimeout(function(){i(new Error("timeout"))},e)),this._cbs[o]=i,this._n++,o;function i(){n._cbs[o]&&(delete n._cbs[o],n._n--,r&&clearTimeout(r),t.apply(n._ctx,arguments))}},R.prototype.clear=function(){Object.keys(this._cbs).forEach(function(e){this._cbs[e](new Error("interrupted"))},this)},B.prototype._decodeRequest=function(e){var t,r,n=new a(e),o=d._read(n),e=f._read(n);if(e?(t=this._serverSvc.message(e),r=this._readers[e+"?"]._read(n)):t=v,!n.isValid())throw new Error(p("truncated %s request",e||"ping$"));return new O(t,o,r)},B.prototype._decodeResponse=function(e,t,r){var n=new a(e);l.copyOwnProperties(d._read(n),t.headers,!0);var o=c._read(n),i=r.name;if(i){e=this._readers[i+(o?"*":"!")];if(r=this._clientSvc.message(i),o?t.error=e._read(n):t.response=e._read(n),!n.isValid())throw new Error(p("truncated %s response",i))}else r=v},t.inherits(N,i.Transform),N.prototype._transform=function(e,t,r){var n,o;for(e=Q.concat([this._buf,e]);4<=e.length&&e.length>=(n=e.readInt32BE(0))+4;)n?this._bufs.push(e.slice(4,n+4)):(o=this._bufs,this._bufs=[],this.push({id:null,payload:o})),e=e.slice(n+4);this._buf=e,r()},N.prototype._flush=function(e){var t,r;(this._buf.length||this._bufs.length)&&((t=this._bufs.slice()).unshift(this._buf),(r=z("TRAILING_DATA")).trailingData=Q.concat(t).toString(),this.emit("error",r)),e()},t.inherits(I,i.Transform),I.prototype._transform=function(e,t,r){for(var n,o=e.payload,i=0,a=o.length;i<a;i++)n=o[i],this.push(M(n.length)),this.push(n);this.push(M(0)),r()},t.inherits(C,i.Transform),C.prototype._transform=function(e,t,r){for(e=Q.concat([this._buf,e]);;){if(void 0===this._id){if(e.length<8)return this._buf=e,void r();this._id=e.readInt32BE(0),this._frameCount=e.readInt32BE(4),e=e.slice(8)}for(var n;this._frameCount&&4<=e.length&&e.length>=(n=e.readInt32BE(0))+4;)this._frameCount--,this._bufs.push(e.slice(4,n+4)),e=e.slice(n+4);if(this._frameCount)return this._buf=e,void r();var o={id:this._id,payload:this._bufs};this._bufs=[],this._id=void 0,this.push(o)}},C.prototype._flush=N.prototype._flush,t.inherits(L,i.Transform),L.prototype._transform=function(e,t,r){var n,o=e.payload,i=o.length,a=l.newBuffer(8);for(a.writeInt32BE(e.id,0),a.writeInt32BE(i,4),this.push(a),n=0;n<i;n++)a=o[n],this.push(M(a.length)),this.push(a);r()},ee.exports={Adapter:B,HANDSHAKE_REQUEST_TYPE:y,HANDSHAKE_RESPONSE_TYPE:g,Message:b,Registry:R,Service:_,discoverProtocol:function(e,t,r){var n;void 0===r&&"function"==typeof t&&(r=t,t=void 0),new _({protocol:"Empty"},s).createClient({timeout:t&&t.timeout}).createChannel(e,{scope:t&&t.scope,endWritable:"function"==typeof e}).once("handshake",function(e,t){n=t.serverProtocol,this.destroy(!0)}).once("eot",function(e,t){t&&!/interrupted/.test(t)?r(t):r(null,JSON.parse(n))})},streams:{FrameDecoder:N,FrameEncoder:I,NettyDecoder:C,NettyEncoder:L}}}).call(this)}).call(this,X("_process"),X("buffer").Buffer)},{"./types":7,"./utils":8,_process:32,buffer:13,events:18,stream:34,util:53}],6:[function(e,t,r){"use strict";var o=e("./files"),n=e("./utils"),h=e("path"),d=e("util").format,i={date:{type:"int",logicalType:"date"},decimal:{type:"bytes",logicalType:"decimal"},time_ms:{type:"long",logicalType:"time-millis"},timestamp_ms:{type:"long",logicalType:"timestamp-millis"}};function a(f,p,n){function l(o,i){p.importHook(o,"idl",function(e,t){if(e)i(e);else if(void 0!==t){try{var r=new y(t,p)._readProtocol(t,p)}catch(e){return e.path=o,void i(e)}var n,s,u,c;n=r.protocol,s=r.imports,u=i,c=[],function o(){var i=s.shift();if(i){var a=h.join(h.dirname(f),i.name);"idl"===i.kind?l(a,function(e,t){e?u(e):(t&&c.push(t),o())}):p.importHook(a,i.kind,function(e,t){if(e)u(e);else switch(i.kind){case"protocol":case"schema":if(void 0===t)return void o();try{var r=JSON.parse(t)}catch(e){return e.path=a,void u(e)}var n="schema"===i.kind?{types:[r]}:r;return c.push(n),void o();default:u(new Error(d("invalid import kind: %s",i.kind)))}})}else{c.reverse();try{c.forEach(function(e){var t,r;t=n,(e=(r=e).types||[]).reverse(),e.forEach(function(e){t.types||(t.types=[]),void 0===e.namespace&&(e.namespace=g(r)||""),t.types.unshift(e)}),Object.keys(r.messages||{}).forEach(function(e){if(t.messages||(t.messages={}),t.messages[e])throw new Error(d("duplicate message: %s",e));t.messages[e]=r.messages[e]})})}catch(e){return void u(e)}u(null,n)}}()}else i()})}n||"function"!=typeof p||(n=p,p=void 0),(p=p||{}).importHook||(p.importHook=o.createImportHook()),l(f,function(e,t){var r;e?n(e):t?((e=t.types)&&(r=g(t)||"",e.forEach(function(e){e.namespace===r&&delete e.namespace})),n(null,t)):n(new Error("empty root import"))})}function y(e,t){t=t||{},this._tk=new s(e),this._ackVoidMessages=!!t.ackVoidMessages,this._implicitTags=!t.delimitedCollections,this._typeRefs=t.typeRefs||i}function s(e){this._str=e,this.pos=0}function g(e){if(e.namespace)return e.namespace;e=/^(.*)\.[^.]+$/.exec(e.protocol);return e?e[1]:void 0}y.readProtocol=function(e,t){t=new y(e,t)._readProtocol();if(t.imports.length)throw new Error("unresolvable import");return t.protocol},y.readSchema=function(e,t){e=new y(e,t),t=e._readJavadoc(),t=e._readType(void 0===t?{}:{doc:t},!0);return e._tk.next({id:"(eof)"}),t},y.prototype._readProtocol=function(){var e=this._tk,t=[],r=[],n={};this._readImports(t);var o={},i=this._readJavadoc();for(void 0!==i&&(o.doc=i),this._readAnnotations(o),e.next({val:"protocol"}),e.next({val:"{",silent:!0})||(o.protocol=e.next({id:"name"}).val,e.next({val:"{"}));!e.next({val:"}",silent:!0});)if(!this._readImports(t)){var a=this._readJavadoc(),s=this._readType({},!0),u=this._readImports(t,!0),c=void 0,f=e.pos;if(!u&&(c=this._readMessage(s))){void 0!==a&&void 0===c.schema.doc&&(c.schema.doc=a);u=!1;if("void"!==c.schema.response&&"void"!==c.schema.response.type||(u=!this._ackVoidMessages&&!c.schema.errors,"void"===c.schema.response?c.schema.response="null":c.schema.response.type="null"),u&&(c.schema["one-way"]=!0),n[c.name])throw new Error(d("duplicate message: %s",c.name));n[c.name]=c.schema}else a&&("string"==typeof s?s={doc:a,type:s}:void 0===s.doc&&(s.doc=a)),r.push(s),e.pos=f,e.next({val:";",silent:!0});a=void 0}return e.next({id:"(eof)"}),r.length&&(o.types=r),Object.keys(n).length&&(o.messages=n),{protocol:o,imports:t}},y.prototype._readAnnotations=function(e){for(var t=this._tk;t.next({val:"@",silent:!0});){for(var r=[];!t.next({val:"(",silent:!0});)r.push(t.next().val);e[r.join("")]=t.next({id:"json"}).val,t.next({val:")"})}},y.prototype._readMessage=function(e){var t=this._tk,r={request:[],response:e};this._readAnnotations(r);e=t.next().val;if("("===t.next().val){if(!t.next({val:")",silent:!0}))for(;r.request.push(this._readField()),!t.next({val:")",silent:!0})&&t.next({val:","}););var n=t.next();switch(n.val){case"throws":for(r.errors=[];r.errors.push(this._readType()),!t.next({val:";",silent:!0})&&t.next({val:","}););break;case"oneway":r["one-way"]=!0,t.next({val:";"});break;case";":break;default:throw t.error("invalid message suffix",n)}return{name:e,schema:r}}},y.prototype._readJavadoc=function(){var e=this._tk.next({id:"javadoc",emitJavadoc:!0,silent:!0});if(e)return e.val},y.prototype._readField=function(){var e=this._tk,t=this._readJavadoc(),r={type:this._readType()};return void 0!==t&&void 0===r.doc&&(r.doc=t),this._readAnnotations(r),r.name=e.next({id:"name"}).val,e.next({val:"=",silent:!0})&&(r.default=e.next({id:"json"}).val),r},y.prototype._readType=function(e,t){switch(e=e||{},this._readAnnotations(e),e.type=this._tk.next({id:"name"}).val,e.type){case"record":case"error":return this._readRecord(e);case"fixed":return this._readFixed(e);case"enum":return this._readEnum(e,t);case"map":return this._readMap(e);case"array":return this._readArray(e);case"union":if(1<Object.keys(e).length)throw new Error("union annotations are not supported");return this._readUnion();default:var r=this._typeRefs[e.type];return r&&(delete e.type,n.copyOwnProperties(r,e)),1<Object.keys(e).length?e:e.type}},y.prototype._readFixed=function(e){var t=this._tk;return t.next({val:"(",silent:!0})||(e.name=t.next({id:"name"}).val,t.next({val:"("})),e.size=parseInt(t.next({id:"number"}).val),t.next({val:")"}),e},y.prototype._readMap=function(e){var t=this._tk,r=this._implicitTags,r=void 0===t.next({val:"<",silent:r});return e.values=this._readType(),t.next({val:">",silent:r}),e},y.prototype._readArray=function(e){var t=this._tk,r=this._implicitTags,r=void 0===t.next({val:"<",silent:r});return e.items=this._readType(),t.next({val:">",silent:r}),e},y.prototype._readEnum=function(e,t){var r=this._tk;for(r.next({val:"{",silent:!0})||(e.name=r.next({id:"name"}).val,r.next({val:"{"})),e.symbols=[];e.symbols.push(r.next().val),!r.next({val:"}",silent:!0})&&r.next({val:","}););return t&&r.next({val:"=",silent:!0})&&(e.default=r.next().val,r.next({val:";"})),e},y.prototype._readUnion=function(){var e=this._tk,t=[];for(e.next({val:"{"});t.push(this._readType()),!e.next({val:"}",silent:!0})&&e.next({val:","}););return t},y.prototype._readRecord=function(e){var t=this._tk;for(t.next({val:"{",silent:!0})||(e.name=t.next({id:"name"}).val,t.next({val:"{"})),e.fields=[];!t.next({val:"}",silent:!0});)e.fields.push(this._readField()),t.next({val:";"});return e},y.prototype._readImports=function(e,t){for(var r=this._tk,n=0,o=r.pos;r.next({val:"import",silent:!0});){if(!n&&t&&r.next({val:"(",silent:!0}))return void(r.pos=o);var i=r.next({id:"name"}).val,a=JSON.parse(r.next({id:"string"}).val);r.next({val:";"}),e.push({kind:i,name:a}),n++}return n},s.prototype.next=function(e){var t,r={pos:this.pos,id:void 0,val:void 0},n=this._skip(e&&e.emitJavadoc);if(n)r.id="javadoc",r.val=n;else{var o=this.pos,i=this._str,n=i.charAt(o);if(n)if(e&&"json"===e.id?(r.id="json",this.pos=this._endOfJson()):'"'===n?(r.id="string",this.pos=this._endOfString()):/[0-9]/.test(n)?(r.id="number",this.pos=this._endOf(/[0-9]/)):/[`A-Za-z_.]/.test(n)?(r.id="name",this.pos=this._endOf(/[`A-Za-z0-9_.]/)):(r.id="operator",this.pos=o+1),r.val=i.slice(o,this.pos),"json"===r.id)try{r.val=JSON.parse(r.val)}catch(t){throw this.error("invalid JSON",r)}else"name"===r.id&&(r.val=r.val.replace(/`/g,""));else r.id="(eof)"}if(e&&e.id&&e.id!==r.id?t=this.error(d("expected ID %s",e.id),r):e&&e.val&&e.val!==r.val&&(t=this.error(d("expected value %s",e.val),r)),!t)return r;if(!e||!e.silent)throw t;this.pos=r.pos},s.prototype.error=function(e,t){for(var r="number"!=typeof t,n=r?t.pos:t,o=this._str,i=1,a=0,s=0;s<n;s++)"\n"===o.charAt(s)&&(i++,a=s);e=r?d("invalid token %j: %s",t,e):e,e=new Error(e);return e.token=r?t:void 0,e.lineNum=i,e.colNum=n-a,e},s.prototype._skip=function(e){for(var t,r,n=this._str,o=!1;(r=n.charAt(this.pos))&&/\s/.test(r);)this.pos++;if(t=this.pos,"/"===r)switch(n.charAt(this.pos+1)){case"/":for(this.pos+=2;(r=n.charAt(this.pos))&&"\n"!==r;)this.pos++;return this._skip(e);case"*":for(this.pos+=2,"*"===n.charAt(this.pos)&&(o=!0);r=n.charAt(this.pos++);)if("*"===r&&"/"===n.charAt(this.pos))return this.pos++,o&&e?function(e){var t=e.replace(/^[ \t]+|[ \t]+$/g,"").split("\n").map(function(e,t){return t?e.replace(/^\s*\*\s?/,""):e});for(;!t[0];)t.shift();for(;!t[t.length-1];)t.pop();return t.join("\n")}(n.slice(t+3,this.pos-2)):this._skip(e);throw this.error("unterminated comment",t)}},s.prototype._endOf=function(e){for(var t=this.pos,r=this._str;e.test(r.charAt(t));)t++;return t},s.prototype._endOfString=function(){for(var e,t=this.pos+1,r=this._str;e=r.charAt(t);){if('"'===e)return t+1;"\\"===e?t+=2:t++}throw this.error("unterminated string",t-1)},s.prototype._endOfJson=function(){var e=n.jsonEnd(this._str,this.pos);if(e<0)throw this.error("invalid JSON",e);return e},t.exports={Tokenizer:s,assembleProtocol:a,read:function(t){var r;if("string"==typeof t&&~t.indexOf(h.sep)&&o.existsSync(t)){var n=o.readFileSync(t,{encoding:"utf8"});try{return JSON.parse(n)}catch(e){a(t,{importHook:o.createSyncImportHook()},function(e,t){r=e?n:t})}}else r=t;if("string"!=typeof r||"null"===r)return r;try{return JSON.parse(r)}catch(e){try{return y.readProtocol(r)}catch(e){try{return y.readSchema(r)}catch(e){return r}}}},readProtocol:y.readProtocol,readSchema:y.readSchema}},{"./files":4,"./utils":8,path:31,util:53}],7:[function($,J,e){(function(H){(function(){"use strict";var _=$("./utils"),t=$("buffer"),y=$("util"),o=_.Tap,u=y.debuglog("avsc:types"),w=y.format,c={array:x,boolean:s,bytes:v,double:d,enum:A,error:O,fixed:k,float:h,int:p,long:l,map:T,null:e,record:O,string:g},n=new _.Lcg,r=new o(new t.SlowBuffer(1024)),f=null,a=[];function m(e,t){var r;if(f?(r=f,a.push([f,this]),f=null):r=this,this._hash=new N,this.name=void 0,this.aliases=void 0,this.doc=e&&e.doc?""+e.doc:void 0,e){var n=e.name,o=void 0===e.namespace?t&&t.namespace:e.namespace;if(void 0!==n){if(L(n=V(n,o)))throw new Error(w("cannot rename primitive type: %j",n));var i=t&&t.registry;if(i){if(void 0!==i[n])throw new Error(w("duplicate type name: %s",n));i[n]=r}}else if(t&&t.noAnonymousTypes)throw new Error(w("missing name property in schema: %j",e));this.name=n,this.aliases=e.aliases?e.aliases.map(function(e){return V(e,o)}):[]}}function i(e){m.call(this),this._branchConstructor=this._createBranchConstructor(),e||Object.freeze(this)}function e(){i.call(this)}function s(){i.call(this)}function p(){i.call(this)}function l(){i.call(this)}function h(){i.call(this)}function d(){i.call(this)}function g(){i.call(this)}function v(){i.call(this)}function b(e,t){if(m.call(this),!Array.isArray(e))throw new Error(w("non-array union schema: %j",e));if(!e.length)throw new Error("empty union");this.types=Object.freeze(e.map(function(e){return m.forSchema(e,t)})),this._branchIndices={},this.types.forEach(function(e,t){if(m.isType(e,"union"))throw new Error("unions cannot be directly nested");e=e.branchName;if(void 0!==this._branchIndices[e])throw new Error(w("duplicate union branch name: %j",e));this._branchIndices[e]=t},this)}function S(e,t){b.call(this,e,t),this._dynamicBranches=null,this._bucketIndices={},this.types.forEach(function(e,t){if(m.isType(e,"abstract","logical"))this._dynamicBranches||(this._dynamicBranches=[]),this._dynamicBranches.push({index:t,type:e});else{e=q(e);if(void 0!==this._bucketIndices[e])throw new Error(w("ambiguous unwrapped union: %j",this));this._bucketIndices[e]=t}},this),Object.freeze(this)}function E(e,t){b.call(this,e,t),Object.freeze(this)}function A(e,t){if(m.call(this,e,t),!Array.isArray(e.symbols)||!e.symbols.length)throw new Error(w("invalid enum symbols: %j",e.symbols));this.symbols=Object.freeze(e.symbols.slice()),this._indices={},this.symbols.forEach(function(e,t){if(!_.isValidName(e))throw new Error(w("invalid %s symbol: %j",this,e));if(void 0!==this._indices[e])throw new Error(w("duplicate %s symbol: %j",this,e));this._indices[e]=t},this),this._branchConstructor=this._createBranchConstructor(),Object.freeze(this)}function k(e,t){if(m.call(this,e,t),e.size!==(0|e.size)||e.size<0)throw new Error(w("invalid %s size",this.branchName));this.size=0|e.size,this._branchConstructor=this._createBranchConstructor(),Object.freeze(this)}function T(e,t){if(m.call(this),!e.values)throw new Error(w("missing map values: %j",e));this.valuesType=m.forSchema(e.values,t),this._branchConstructor=this._createBranchConstructor(),Object.freeze(this)}function x(e,t){if(m.call(this),!e.items)throw new Error(w("missing array items: %j",e));this.itemsType=m.forSchema(e.items,t),this._branchConstructor=this._createBranchConstructor(),Object.freeze(this)}function O(e,t){var r,n=(t=t||{}).namespace;if(void 0!==e.namespace?t.namespace=e.namespace:!e.name||void 0!==(r=_.impliedNamespace(e.name))&&(t.namespace=r),m.call(this,e,t),!Array.isArray(e.fields))throw new Error(w("non-array record fields: %j",e.fields));if(_.hasDuplicates(e.fields,function(e){return e.name}))throw new Error(w("duplicate field name: %j",e.fields));this._fieldsByName={},this.fields=Object.freeze(e.fields.map(function(e){e=new R(e,t);return this._fieldsByName[e.name]=e},this)),this._branchConstructor=this._createBranchConstructor(),this._isError="error"===e.type,this.recordConstructor=this._createConstructor(t.errorStackTraces,t.omitRecordMethods),this._read=this._createReader(),this._skip=this._createSkipper(),this._write=this._createWriter(),this._check=this._createChecker(),t.namespace=n,Object.freeze(this)}function j(e,t){this._logicalTypeName=e.logicalType,m.call(this),f=this;try{this._underlyingType=m.forSchema(e,t)}finally{f=null;var r=a.length;r&&a[r-1][0]===this&&a.pop()}m.isType(this.underlyingType,"union")?this._branchConstructor=this.underlyingType._branchConstructor:this._branchConstructor=this.underlyingType._createBranchConstructor()}function P(e){this._concreteTypeName="long",i.call(this,!0),this._noUnpack=!!e}function R(e,t){var r=e.name;if("string"!=typeof r||!_.isValidName(r))throw new Error(w("invalid field name: %s",r));this.name=r,this.type=m.forSchema(e.type,t),this.aliases=e.aliases||[],this.doc=void 0!==e.doc?""+e.doc:void 0,this._order=function(e){switch(e){case"ascending":return 1;case"descending":return-1;case"ignore":return 0;default:throw new Error(w("invalid order: %j",e))}}(void 0===e.order?"ascending":e.order);var n,o,e=e.default;void 0!==e&&(n=this.type,o=n._copy(e,{coerce:2,wrap:2}),L(n.typeName)&&"bytes"!==n.typeName?this.defaultValue=function(){return o}:this.defaultValue=function(){return n._copy(o)}),Object.freeze(this)}function B(e){this._readerType=e,this._read=null,this.itemsType=null,this.size=0,this.symbols=null,this.valuesType=null}function N(){this.str=void 0}function I(e,t,r,n){if(r){if(r._readerType!==e)throw new Error("invalid resolver");return r._read(t,n)}return e._read(t)}function C(e){var t={};e.name&&(t[e.name]=!0);for(var r=e.aliases,n=0,o=r.length;n<o;n++)t[r[n]]=!0;return Object.keys(t)}function L(e){e=c[e];return e&&e.prototype instanceof i}function M(e){var t;return"error"===e?e="record":(t=/^([^:]+):(.*)$/.exec(e))&&(e="union"===t[1]?t[2]+"Union":t[1]),_.capitalize(e)+"Type"}function F(e){var t=e.readLong();return t<0&&(t=-t,e.skipLong()),t}function U(e){return-9007199254740990<=e&&e<=9007199254740990}function D(e){return e&&"Buffer"===e.type&&Array.isArray(e.data)}function W(e,t){throw new Error(w("invalid %j: %j",t.schema(),e))}function V(e,t){var r=_.unqualify(e);return L(r)?r:_.qualify(e,t)}function q(e){var t=e.typeName;switch(t){case"double":case"float":case"int":case"long":return"number";case"bytes":case"fixed":return"buffer";case"enum":return"string";case"map":case"error":case"record":return"object";default:return t}}function z(e){if(null===e)return"null";var t=typeof e;if("object"==t){if(Array.isArray(e))return"array";if(H.isBuffer(e))return"buffer"}return t}m.forSchema=function(r,n){(n=n||{}).registry=n.registry||{};var e,t,o=function(e){switch(!0===e?e="always":!1===e?e="never":void 0===e?e="auto":"string"==typeof e&&(e=e.toLowerCase()),e){case"always":return E;case"never":return S;case"auto":return;default:throw new Error(w("invalid wrap unions option: %j",e))}}(n.wrapUnions);if(null===r)throw new Error('invalid type: null (did you mean "null"?)');if(m.isType(r))return r;if(n.typeHook&&(e=n.typeHook(r,n))){if(!m.isType(e))throw new Error(w("invalid typehook return value: %j",e));return e}if("string"==typeof r){if(r=V(r,n.namespace),e=n.registry[r])return e;if(L(r))return n.registry[r]=m.forSchema({type:r},n);throw new Error(w("undefined type name: %s",r))}if(r.logicalType&&n.logicalTypes&&!f){var i=n.logicalTypes[r.logicalType];if(i){var a=n.namespace,s={};Object.keys(n.registry).forEach(function(e){s[e]=n.registry[e]});try{return u("instantiating logical type for %s",r.logicalType),new i(r,n)}catch(e){if(u("failed to instantiate logical type for %s",r.logicalType),n.assertLogicalTypes)throw e;f=null,n.namespace=a,n.registry=s}}}return e=Array.isArray(r)?(t=f,f=null,a=r.map(function(e){return m.forSchema(e,n)}),o=o||(function(e){var t,r,n,o={};for(t=0,r=e.length;t<r;t++)if(n=e[t],!m.isType(n,"logical")){if(n=q(n),o[n])return!0;o[n]=!0}return!1}(a)?E:S),f=t,new o(a,n)):function(e){var t=c[e];if(void 0===t)throw new Error(w("unknown type: %j",e));return new t(r,n)}(r.type)},m.forValue=function(t,r){if((r=r||{}).emptyArrayType=r.emptyArrayType||m.forSchema({type:"array",items:"null"}),r.valueHook){var e=r.valueHook(t,r);if(void 0!==e){if(!m.isType(e))throw new Error(w("invalid value hook return value: %j",e));return e}}switch(typeof t){case"string":return m.forSchema("string",r);case"boolean":return m.forSchema("boolean",r);case"number":return(0|t)===t?m.forSchema("int",r):Math.abs(t)<9007199254740991?m.forSchema("float",r):m.forSchema("double",r);case"object":if(null===t)return m.forSchema("null",r);if(Array.isArray(t))return t.length?m.forSchema({type:"array",items:m.forTypes(t.map(function(e){return m.forValue(e,r)}),r)},r):r.emptyArrayType;if(H.isBuffer(t))return m.forSchema("bytes",r);var n=Object.keys(t);return n.some(function(e){return!_.isValidName(e)})?m.forSchema({type:"map",values:m.forTypes(n.map(function(e){return m.forValue(t[e],r)}),r)},r):m.forSchema({type:"record",fields:n.map(function(e){return{name:e,type:m.forValue(t[e],r)}})},r);default:throw new Error(w("cannot infer type from: %j",t))}},m.forTypes=function(e,r){if(!e.length)throw new Error("no types to combine");if(1===e.length)return e[0];r=r||{};var t=[],n=0,o=!0;if(e.forEach(function(e){switch(e.typeName){case"union:unwrapped":o=!1,t=t.concat(e.types);break;case"union:wrapped":n++,t=t.concat(e.types);break;case"null":t.push(e);break;default:o=!1,t.push(e)}}),n){if(!o)throw new Error("cannot combine wrapped union");var i={};t.forEach(function(e){var t=e.branchName,r=i[t];if(r){if(!e.equals(r))throw new Error("inconsistent branch type")}else i[t]=e});var a,s=r.wrapUnions;r.wrapUnions=!0;try{a=m.forSchema(Object.keys(i).map(function(e){return i[e]}),r)}catch(e){throw r.wrapUnions=s,e}return r.wrapUnions=s,a}var u={};t.forEach(function(e){var t=q(e),r=u[t];r||(u[t]=r=[]),r.push(e)});s=Object.keys(u).map(function(e){var t=u[e];if(1===t.length)return t[0];switch(e){case"null":case"boolean":return t[0];case"number":return function(e){var t,r,n,o,i=["int","long","float","double"],a=-1,s=null;for(t=0,r=e.length;t<r;t++)n=e[t],o=i.indexOf(n.typeName),a<o&&(a=o,s=n);return s}(t);case"string":return function(e,t){var r,n,o,i,a,s,u={};for(r=0,n=e.length;r<n;r++){if("string"===(o=e[r]).typeName)return o;for(i=o.symbols,a=0,s=i.length;a<s;a++)u[i[a]]=!0}return m.forSchema({type:"enum",symbols:Object.keys(u)},t)}(t,r);case"buffer":return function(e,t){var r,n,o,i=-1;for(r=0,n=e.length;r<n;r++){if("bytes"===(o=e[r]).typeName)return o;-1===i?i=o.size:o.size!==i&&(i=-2)}return i<0?m.forSchema("bytes",t):e[0]}(t,r);case"array":return(t=t.filter(function(e){return e!==r.emptyArrayType})).length?m.forSchema({type:"array",items:m.forTypes(t.map(function(e){return e.itemsType}),r)},r):r.emptyArrayType;default:return function(e,s){var t,r,n,o,i,a,u,c,f,p,l=[],h={},d={},y=!0;for(t=0,r=e.length;t<r;t++)if("map"===(n=e[t]).typeName)y=!1,l.push(n.valuesType);else for(o=n.fields,i=0,a=o.length;i<a;i++)u=o[i],c=u.name,f=u.type,l.push(f),y&&(h[c]||(h[c]=[]),h[c].push(f),void 0!==(u=u.defaultValue())&&(d[c]=u));if(y){var g=Object.keys(h);for(t=0,r=g.length;t<r;t++)c=g[t],h[c].length<e.length&&void 0===d[c]&&(s&&s.strictDefaults?y=!1:(h[c].unshift(m.forSchema("null",s)),d[c]=null))}p=y?{type:"record",fields:g.map(function(e){var t=m.forTypes(h[e],s),r=d[e];if(void 0!==r&&~t.typeName.indexOf("union")){for(var n,o=t.types.slice(),i=0,a=o.length;i<a&&!o[i].isValid(r);i++);0<i&&(n=o[0],o[0]=o[i],o[i]=n,t=m.forSchema(o,s))}return{name:e,type:t,default:d[e]}})}:{type:"map",values:m.forTypes(l,s)};return m.forSchema(p,s)}(t,r)}});return 1===s.length?s[0]:m.forSchema(s,r)},m.isType=function(){var e=arguments.length;if(!e)return!1;var t=arguments[0];if(!t||"function"!=typeof t._update||"function"!=typeof t.fingerprint)return!1;if(1===e)return!0;for(var r=t.typeName,n=1;n<e;n++)if(0===r.indexOf(arguments[n]))return!0;return!1},m.__reset=function(e){u("resetting type buffer to %d",e),r.buf=new t.SlowBuffer(e)},Object.defineProperty(m.prototype,"branchName",{enumerable:!0,get:function(){var e=m.isType(this,"logical")?this.underlyingType:this;return e.name||(m.isType(e,"abstract")?e._concreteTypeName:m.isType(e,"union")?void 0:e.typeName)}}),m.prototype.clone=function(e,t){return t?(t={coerce:0|!!t.coerceBuffers,fieldHook:t.fieldHook,qualifyNames:!!t.qualifyNames,skip:!!t.skipMissingFields,wrap:0|!!t.wrapUnions},this._copy(e,t)):this.fromBuffer(this.toBuffer(e))},m.prototype.compare=_.abstractFunction,m.prototype.compareBuffers=function(e,t){return this._match(new o(e),new o(t))},m.prototype.createResolver=function(e,t){if(!m.isType(e))throw new Error(w("not a type: %j",e));if(!m.isType(this,"union","logical")&&m.isType(e,"logical"))return this.createResolver(e.underlyingType,t);var r,n,o;if(t=t||{},t.registry=t.registry||{},m.isType(this,"record","error")&&m.isType(e,"record","error")&&(n=this.name+":"+e.name,r=t.registry[n]))return r;if(r=new B(this),n&&(t.registry[n]=r),m.isType(e,"union")?(o=e.types.map(function(e){return this.createResolver(e,t)},this),r._read=function(e){var t=e.readLong();if(void 0===o[t])throw new Error(w("invalid union index: %s",t));return o[t]._read(e)}):this._update(r,e,t),!r._read)throw new Error(w("cannot read %s as %s",e,this));return Object.freeze(r)},m.prototype.decode=function(e,t,r){t=new o(e,t),r=I(this,t,r);return t.isValid()?{value:r,offset:t.pos}:{value:void 0,offset:-1}},m.prototype.encode=function(e,t,r){r=new o(t,r);return this._write(r,e),r.isValid()?r.pos:t.length-r.pos},m.prototype.equals=function(e){return m.isType(e)&&this.fingerprint().equals(e.fingerprint())},m.prototype.fingerprint=function(e){return e?_.getHash(JSON.stringify(this.schema()),e):(this._hash.str||(e=JSON.stringify(this.schema()),this._hash.str=_.getHash(e).toString("binary")),_.bufferFrom(this._hash.str,"binary"))},m.prototype.fromBuffer=function(e,t,r){var n=new o(e),t=I(this,n,t,r);if(!n.isValid())throw new Error("truncated buffer");if(!r&&n.pos<e.length)throw new Error("trailing data");return t},m.prototype.fromString=function(e){return this._copy(JSON.parse(e),{coerce:2})},m.prototype.inspect=function(){var e=this.typeName,t=M(e);if(L(e))return w("<%s>",t);e=this.schema({exportAttrs:!0,noDeref:!0});return"object"!=typeof e||m.isType(this,"logical")||(e.type=void 0),w("<%s %j>",t,e)},m.prototype.isValid=function(r,e){var t,n,o=0|(e&&e.noUndeclaredFields),i=e&&e.errorHook;return i&&(n=[],t=function(e,t){i.call(this,n.slice(),e,t,r)}),this._check(r,o,t,n)},m.prototype.random=_.abstractFunction,m.prototype.schema=function(e){return this._attrs({exportAttrs:!(!e||!e.exportAttrs),noDeref:!(!e||!e.noDeref)})},m.prototype.toBuffer=function(e){r.pos=0,this._write(r,e);var t=_.newBuffer(r.pos);return r.isValid()?r.buf.copy(t,0,0,r.pos):this._write(new o(t),e),t},m.prototype.toJSON=function(){return this.schema({exportAttrs:!0})},m.prototype.toString=function(e){return void 0===e?JSON.stringify(this.schema({noDeref:!0})):JSON.stringify(this._copy(e,{coerce:3}))},m.prototype.wrap=function(e){var t=this._branchConstructor;return null===t?null:new t(e)},m.prototype._attrs=function(e){e.derefed=e.derefed||{};var t=this.name;if(void 0!==t){if(e.noDeref||e.derefed[t])return t;e.derefed[t]=!0}var r={};void 0!==this.name&&(r.name=t),r.type=this.typeName;t=this._deref(r,e);return void 0!==t&&(r=t),e.exportAttrs&&(this.aliases&&this.aliases.length&&(r.aliases=this.aliases),void 0!==this.doc&&(r.doc=this.doc)),r},m.prototype._createBranchConstructor=function(){var e=this.branchName;if("null"===e)return null;var t=~e.indexOf(".")?"this['"+e+"']":"this."+e,e=new Function("return function Branch$(val) { "+t+" = val; };")();return e.type=this,e.prototype.unwrap=new Function("return "+t+";"),e.prototype.unwrapped=e.prototype.unwrap,e},m.prototype._peek=function(e){var t=e.pos,r=this._read(e);return e.pos=t,r},m.prototype._check=_.abstractFunction,m.prototype._copy=_.abstractFunction,m.prototype._deref=_.abstractFunction,m.prototype._match=_.abstractFunction,m.prototype._read=_.abstractFunction,m.prototype._skip=_.abstractFunction,m.prototype._update=_.abstractFunction,m.prototype._write=_.abstractFunction,m.prototype.getAliases=function(){return this.aliases},m.prototype.getFingerprint=m.prototype.fingerprint,m.prototype.getName=function(e){return this.name||!e?this.name:this.branchName},m.prototype.getSchema=m.prototype.schema,m.prototype.getTypeName=function(){return this.typeName},y.inherits(i,m),i.prototype._update=function(e,t){t.typeName===this.typeName&&(e._read=this._read)},i.prototype._copy=function(e){return this._check(e,void 0,W),e},i.prototype._deref=function(){return this.typeName},i.prototype.compare=_.compare,y.inherits(e,i),e.prototype._check=function(e,t,r){var n=null===e;return!n&&r&&r(e,this),n},e.prototype._read=function(){return null},e.prototype._skip=function(){},e.prototype._write=function(e,t){null!==t&&W(t,this)},e.prototype.compare=e.prototype._match=function(){return 0},e.prototype.typeName="null",e.prototype.random=e.prototype._read,y.inherits(s,i),s.prototype._check=function(e,t,r){var n="boolean"==typeof e;return!n&&r&&r(e,this),n},s.prototype._read=function(e){return e.readBoolean()},s.prototype._skip=function(e){e.skipBoolean()},s.prototype._write=function(e,t){"boolean"!=typeof t&&W(t,this),e.writeBoolean(t)},s.prototype._match=function(e,t){return e.matchBoolean(t)},s.prototype.typeName="boolean",s.prototype.random=function(){return n.nextBoolean()},y.inherits(p,i),p.prototype._check=function(e,t,r){var n=e===(0|e);return!n&&r&&r(e,this),n},p.prototype._read=function(e){return e.readInt()},p.prototype._skip=function(e){e.skipInt()},p.prototype._write=function(e,t){t!==(0|t)&&W(t,this),e.writeInt(t)},p.prototype._match=function(e,t){return e.matchInt(t)},p.prototype.typeName="int",p.prototype.random=function(){return 0|n.nextInt(1e3)},y.inherits(l,i),l.prototype._check=function(e,t,r){var n="number"==typeof e&&e%1==0&&U(e);return!n&&r&&r(e,this),n},l.prototype._read=function(e){e=e.readLong();if(!U(e))throw new Error("potential precision loss");return e},l.prototype._skip=function(e){e.skipLong()},l.prototype._write=function(e,t){("number"!=typeof t||t%1||!U(t))&&W(t,this),e.writeLong(t)},l.prototype._match=function(e,t){return e.matchLong(t)},l.prototype._update=function(e,t){switch(t.typeName){case"int":e._read=t._read;break;case"abstract:long":case"long":e._read=this._read}},l.prototype.typeName="long",l.prototype.random=function(){return n.nextInt()},l.__with=function(t,e){t=t||{};var r={toBuffer:"_toBuffer",fromBuffer:"_fromBuffer",fromJSON:"_fromJSON",toJSON:"_toJSON",isValid:"_isValid",compare:"compare"},n=new P(e);return Object.keys(r).forEach(function(e){if(void 0===t[e])throw new Error(w("missing method implementation: %s",e));n[r[e]]=t[e]}),Object.freeze(n)},y.inherits(h,i),h.prototype._check=function(e,t,r){var n="number"==typeof e;return!n&&r&&r(e,this),n},h.prototype._read=function(e){return e.readFloat()},h.prototype._skip=function(e){e.skipFloat()},h.prototype._write=function(e,t){"number"!=typeof t&&W(t,this),e.writeFloat(t)},h.prototype._match=function(e,t){return e.matchFloat(t)},h.prototype._update=function(e,t){switch(t.typeName){case"float":case"int":e._read=t._read;break;case"abstract:long":case"long":e._read=function(e){return e.readLong()}}},h.prototype.typeName="float",h.prototype.random=function(){return n.nextFloat(1e3)},y.inherits(d,i),d.prototype._check=function(e,t,r){var n="number"==typeof e;return!n&&r&&r(e,this),n},d.prototype._read=function(e){return e.readDouble()},d.prototype._skip=function(e){e.skipDouble()},d.prototype._write=function(e,t){"number"!=typeof t&&W(t,this),e.writeDouble(t)},d.prototype._match=function(e,t){return e.matchDouble(t)},d.prototype._update=function(e,t){switch(t.typeName){case"double":case"float":case"int":e._read=t._read;break;case"abstract:long":case"long":e._read=function(e){return e.readLong()}}},d.prototype.typeName="double",d.prototype.random=function(){return n.nextFloat()},y.inherits(g,i),g.prototype._check=function(e,t,r){var n="string"==typeof e;return!n&&r&&r(e,this),n},g.prototype._read=function(e){return e.readString()},g.prototype._skip=function(e){e.skipString()},g.prototype._write=function(e,t){"string"!=typeof t&&W(t,this),e.writeString(t)},g.prototype._match=function(e,t){return e.matchString(t)},g.prototype._update=function(e,t){switch(t.typeName){case"bytes":case"string":e._read=this._read}},g.prototype.typeName="string",g.prototype.random=function(){return n.nextString(n.nextInt(32))},y.inherits(v,i),v.prototype._check=function(e,t,r){var n=H.isBuffer(e);return!n&&r&&r(e,this),n},v.prototype._read=function(e){return e.readBytes()},v.prototype._skip=function(e){e.skipBytes()},v.prototype._write=function(e,t){H.isBuffer(t)||W(t,this),e.writeBytes(t)},v.prototype._match=function(e,t){return e.matchBytes(t)},v.prototype._update=g.prototype._update,v.prototype._copy=function(e,t){var r;switch(0|(t&&t.coerce)){case 3:return this._check(e,void 0,W),e.toString("binary");case 2:if("string"!=typeof e)throw new Error(w("cannot coerce to buffer: %j",e));return r=_.bufferFrom(e,"binary"),this._check(r,void 0,W),r;case 1:if(!D(e))throw new Error(w("cannot coerce to buffer: %j",e));return r=_.bufferFrom(e.data),this._check(r,void 0,W),r;default:return this._check(e,void 0,W),_.bufferFrom(e)}},v.prototype.compare=H.compare,v.prototype.typeName="bytes",v.prototype.random=function(){return n.nextBuffer(n.nextInt(32))},y.inherits(b,m),b.prototype._branchConstructor=function(){throw new Error("unions cannot be directly wrapped")},b.prototype._skip=function(e){this.types[e.readLong()]._skip(e)},b.prototype._match=function(e,t){var r=e.readLong(),n=t.readLong();return r===n?this.types[r]._match(e,t):r<n?-1:1},b.prototype._deref=function(e,t){return this.types.map(function(e){return e._attrs(t)})},b.prototype.getTypes=function(){return this.types},y.inherits(S,b),S.prototype._getIndex=function(e){var t=this._bucketIndices[z(e)];return this._dynamicBranches&&(t=this._getBranchIndex(e,t)),t},S.prototype._getBranchIndex=function(e,t){for(var r,n=this._dynamicBranches,o=0,i=n.length;o<i;o++)if((r=n[o]).type._check(e)){if(void 0!==t)throw new Error("ambiguous conversion");t=r.index}return t},S.prototype._check=function(e,t,r,n){var o=this._getIndex(e),i=void 0!==o;return i?this.types[o]._check(e,t,r,n):(r&&r(e,this),i)},S.prototype._read=function(e){var t=e.readLong(),r=this.types[t];if(r)return r._read(e);throw new Error(w("invalid union index: %s",t))},S.prototype._write=function(e,t){var r=this._getIndex(t);void 0===r&&W(t,this),e.writeLong(r),null!==t&&this.types[r]._write(e,t)},S.prototype._update=function(e,t,r){for(var n,o=0,i=this.types.length;o<i;o++){try{n=this.types[o].createResolver(t,r)}catch(e){continue}return void(e._read=function(e){return n._read(e)})}},S.prototype._copy=function(e,t){var r,n,o=t&&0|t.coerce,i=t&&0|t.wrap;if(2===i)r=0;else{switch(o){case 1:r=D(e)&&void 0!==this._bucketIndices.buffer?this._bucketIndices.buffer:this._getIndex(e);break;case 2:null===e?r=this._bucketIndices.null:"object"!=typeof e||1===(n=Object.keys(e)).length&&(r=this._branchIndices[n[0]],e=e[n[0]]);break;default:r=this._getIndex(e)}void 0===r&&W(e,this)}var a=this.types[r];if(null===e||3===i)return a._copy(e,t);if(3!==o)return a._copy(e,t);o={};return o[a.branchName]=a._copy(e,t),o},S.prototype.compare=function(e,t){var r=this._getIndex(e),n=this._getIndex(t);if(void 0===r)W(e,this);else{if(void 0!==n)return r===n?this.types[r].compare(e,t):_.compare(r,n);W(t,this)}},S.prototype.typeName="union:unwrapped",S.prototype.random=function(){var e=n.nextInt(this.types.length);return this.types[e].random()},y.inherits(E,b),E.prototype._check=function(e,t,r,n){var o=!1;if(null===e)o=void 0!==this._branchIndices.null;else if("object"==typeof e){var i=Object.keys(e);if(1===i.length){var a=i[0],i=this._branchIndices[a];if(void 0!==i)return r?(n.push(a),o=this.types[i]._check(e[a],t,r,n),n.pop(),o):this.types[i]._check(e[a],t)}}return!o&&r&&r(e,this),o},E.prototype._read=function(e){var t=this.types[e.readLong()];if(!t)throw new Error(w("invalid union index"));var r=t._branchConstructor;return null===r?null:new r(t._read(e))},E.prototype._write=function(e,t){var r,n,o;null===t?(void 0===(r=this._branchIndices.null)&&W(t,this),e.writeLong(r)):(1===(n=Object.keys(t)).length&&(o=n[0],r=this._branchIndices[o]),void 0===r&&W(t,this),e.writeLong(r),this.types[r]._write(e,t[o]))},E.prototype._update=function(e,t,r){for(var n,o,i=0,a=this.types.length;i<a;i++){try{n=this.types[i].createResolver(t,r)}catch(e){continue}return o=this.types[i]._branchConstructor,void(e._read=o?function(e){return new o(n._read(e))}:function(){return null})}},E.prototype._copy=function(e,t){var r,n=t&&0|t.wrap;if(2===n){var o=this.types[0];return null===e&&"null"===o.typeName?null:new o._branchConstructor(o._copy(e,t))}if(null===e&&void 0!==this._branchIndices.null)return null;if("object"==typeof e){o=Object.keys(e);if(1===o.length){var i,a=o[0];if(void 0===(i=this._branchIndices[a])&&t.qualifyNames)for(var s,u=0,c=this.types.length;u<c;u++)if((s=this.types[u]).name&&a===_.unqualify(s.name)){i=u;break}void 0!==i&&(r=this.types[i]._copy(e[a],t))}}if(1===n&&void 0===r)for(i=0,c=this.types.length;i<c&&void 0===r;)try{r=this.types[i]._copy(e,t)}catch(e){i++}if(void 0!==r)return 3===n?r:new this.types[i]._branchConstructor(r);W(e,this)},E.prototype.compare=function(e,t){var r=null===e?"null":Object.keys(e)[0],n=null===t?"null":Object.keys(t)[0],o=this._branchIndices[r];return r===n?"null"===r?0:this.types[o].compare(e[r],t[r]):_.compare(o,this._branchIndices[n])},E.prototype.typeName="union:wrapped",E.prototype.random=function(){var e=n.nextInt(this.types.length),t=this.types[e],e=t._branchConstructor;return e?new e(t.random()):null},y.inherits(A,m),A.prototype._check=function(e,t,r){var n=void 0!==this._indices[e];return!n&&r&&r(e,this),n},A.prototype._read=function(e){var t=e.readLong(),e=this.symbols[t];if(void 0===e)throw new Error(w("invalid %s enum index: %s",this.name,t));return e},A.prototype._skip=function(e){e.skipLong()},A.prototype._write=function(e,t){var r=this._indices[t];void 0===r&&W(t,this),e.writeLong(r)},A.prototype._match=function(e,t){return e.matchLong(t)},A.prototype.compare=function(e,t){return _.compare(this._indices[e],this._indices[t])},A.prototype._update=function(e,t){var r=this.symbols;"enum"!==t.typeName||t.name&&!~C(this).indexOf(t.name)||!t.symbols.every(function(e){return~r.indexOf(e)})||(e.symbols=t.symbols,e._read=t._read)},A.prototype._copy=function(e){return this._check(e,void 0,W),e},A.prototype._deref=function(e){e.symbols=this.symbols},A.prototype.getSymbols=function(){return this.symbols},A.prototype.typeName="enum",A.prototype.random=function(){return n.choice(this.symbols)},y.inherits(k,m),k.prototype._check=function(e,t,r){var n=H.isBuffer(e)&&e.length===this.size;return!n&&r&&r(e,this),n},k.prototype._read=function(e){return e.readFixed(this.size)},k.prototype._skip=function(e){e.skipFixed(this.size)},k.prototype._write=function(e,t){H.isBuffer(t)&&t.length===this.size||W(t,this),e.writeFixed(t,this.size)},k.prototype._match=function(e,t){return e.matchFixed(t,this.size)},k.prototype.compare=H.compare,k.prototype._update=function(e,t){"fixed"!==t.typeName||this.size!==t.size||t.name&&!~C(this).indexOf(t.name)||(e.size=this.size,e._read=this._read)},k.prototype._copy=v.prototype._copy,k.prototype._deref=function(e){e.size=this.size},k.prototype.getSize=function(){return this.size},k.prototype.typeName="fixed",k.prototype.random=function(){return n.nextBuffer(this.size)},y.inherits(T,m),T.prototype._check=function(e,t,r,n){if(!e||"object"!=typeof e||Array.isArray(e))return r&&r(e,this),!1;var o,i,a,s,u=Object.keys(e),c=!0;if(r){for(a=n.length,n.push(""),o=0,i=u.length;o<i;o++)s=n[a]=u[o],this.valuesType._check(e[s],t,r,n)||(c=!1);n.pop()}else for(o=0,i=u.length;o<i;o++)if(!this.valuesType._check(e[u[o]],t))return!1;return c},T.prototype._read=function(e){for(var t,r=this.valuesType,n={};t=F(e);)for(;t--;)n[e.readString()]=r._read(e);return n},T.prototype._skip=function(e){for(var t,r,n=this.valuesType;r=e.readLong();)if(r<0)t=e.readLong(),e.pos+=t;else for(;r--;)e.skipString(),n._skip(e)},T.prototype._write=function(e,t){t&&"object"==typeof t&&!Array.isArray(t)||W(t,this);var r,n,o=this.valuesType,i=Object.keys(t),a=i.length;if(a)for(e.writeLong(a),r=0;r<a;r++)n=i[r],e.writeString(n),o._write(e,t[n]);e.writeLong(0)},T.prototype._match=function(){throw new Error("maps cannot be compared")},T.prototype._update=function(e,t,r){"map"===t.typeName&&(e.valuesType=this.valuesType.createResolver(t.valuesType,r),e._read=this._read)},T.prototype._copy=function(e,t){if(e&&"object"==typeof e&&!Array.isArray(e)){for(var r,n=this.valuesType,o=Object.keys(e),i={},a=0,s=o.length;a<s;a++)i[r=o[a]]=n._copy(e[r],t);return i}W(e,this)},T.prototype.compare=T.prototype._match,T.prototype.typeName="map",T.prototype.getValuesType=function(){return this.valuesType},T.prototype.random=function(){for(var e={},t=0,r=n.nextInt(10);t<r;t++)e[n.nextString(n.nextInt(20))]=this.valuesType.random();return e},T.prototype._deref=function(e,t){e.values=this.valuesType._attrs(t)},y.inherits(x,m),x.prototype._check=function(e,t,r,n){if(!Array.isArray(e))return r&&r(e,this),!1;var o,i,a,s=!0;if(r){for(a=n.length,n.push(""),o=0,i=e.length;o<i;o++)n[a]=""+o,this.itemsType._check(e[o],t,r,n)||(s=!1);n.pop()}else for(o=0,i=e.length;o<i;o++)if(!this.itemsType._check(e[o],t))return!1;return s},x.prototype._read=function(e){for(var t,r=this.itemsType,n=[];t=e.readLong();)for(t<0&&(t=-t,e.skipLong());t--;)n.push(r._read(e));return n},x.prototype._skip=function(e){for(var t,r;r=e.readLong();)if(r<0)t=e.readLong(),e.pos+=t;else for(;r--;)this.itemsType._skip(e)},x.prototype._write=function(e,t){Array.isArray(t)||W(t,this);var r,n=t.length;if(n)for(e.writeLong(n),r=0;r<n;r++)this.itemsType._write(e,t[r]);e.writeLong(0)},x.prototype._match=function(e,t){for(var r,n=e.readLong(),o=t.readLong();n&&o;){if(r=this.itemsType._match(e,t))return r;--n||(n=F(e)),--o||(o=F(t))}return _.compare(n,o)},x.prototype._update=function(e,t,r){"array"===t.typeName&&(e.itemsType=this.itemsType.createResolver(t.itemsType,r),e._read=this._read)},x.prototype._copy=function(e,t){Array.isArray(e)||W(e,this);for(var r=new Array(e.length),n=0,o=e.length;n<o;n++)r[n]=this.itemsType._copy(e[n],t);return r},x.prototype._deref=function(e,t){e.items=this.itemsType._attrs(t)},x.prototype.compare=function(e,t){for(var r,n=e.length,o=t.length,i=0,a=Math.min(n,o);i<a;i++)if(r=this.itemsType.compare(e[i],t[i]))return r;return _.compare(n,o)},x.prototype.getItemsType=function(){return this.itemsType},x.prototype.typeName="array",x.prototype.random=function(){for(var e=[],t=0,r=n.nextInt(10);t<r;t++)e.push(this.itemsType.random());return e},y.inherits(O,m),O.prototype._getConstructorName=function(){return this.name?_.capitalize(_.unqualify(this.name)):this._isError?"Error$":"Record$"},O.prototype._createConstructor=function(e,t){for(var r,n,o,i,a,s=[],u=[],c=[],f="",p=0,l=this.fields.length;p<l;p++)i=void 0!==(o=(r=this.fields[p]).defaultValue)(),n=r.name,e&&this._isError&&"stack"===n&&m.isType(r.type,"string")&&!i&&(a=r),u.push("v"+p),f+="  ",i?(f+="if (v"+p+" === undefined) { ",f+="this."+n+" = d"+c.length+"(); ",f+="} else { this."+n+" = v"+p+"; }\n",s.push("d"+c.length),c.push(o)):f+="this."+n+" = v"+p+";\n";a&&(f+="  if (this.stack === undefined) { ","function"==typeof Error.captureStackTrace?f+="Error.captureStackTrace(this, this.constructor);":f+="this.stack = Error().stack;",f+=" }\n");var h="return function "+this._getConstructorName()+"(";h+=u.join()+") {\n"+f+"};";h=new Function(s.join(),h).apply(void 0,c);if(t)return h;var d=this;return h.getType=function(){return d},h.type=d,this._isError&&(y.inherits(h,Error),h.prototype.name=this._getConstructorName()),h.prototype.clone=function(e){return d.clone(this,e)},h.prototype.compare=function(e){return d.compare(this,e)},h.prototype.isValid=function(e){return d.isValid(this,e)},h.prototype.toBuffer=function(){return d.toBuffer(this)},h.prototype.toString=function(){return d.toString(this)},h.prototype.wrap=function(){return d.wrap(this)},h.prototype.wrapped=h.prototype.wrap,h},O.prototype._createChecker=function(){var e,t,r,n=[],o=[],i="return function check"+this._getConstructorName()+"(v, f, h, p) {\n";if(i+="  if (\n",i+="    v === null ||\n",i+="    typeof v != 'object' ||\n",i+="    (f && !this._checkFields(v))\n",i+="  ) {\n",i+="    if (h) { h(v, this); }\n",i+="    return false;\n",i+="  }\n",this.fields.length){for(e=0,t=this.fields.length;e<t;e++)r=this.fields[e],n.push("t"+e),o.push(r.type),void 0!==r.defaultValue()&&(i+="  var v"+e+" = v."+r.name+";\n");for(i+="  if (h) {\n",i+="    var b = 1;\n",i+="    var j = p.length;\n",i+="    p.push('');\n",e=0,t=this.fields.length;e<t;e++)i+="    p[j] = '"+(r=this.fields[e]).name+"';\n",i+="    b &= ",void 0===r.defaultValue()?i+="t"+e+"._check(v."+r.name+", f, h, p);\n":(i+="v"+e+" === undefined || ",i+="t"+e+"._check(v"+e+", f, h, p);\n");i+="    p.pop();\n",i+="    return !!b;\n",i+="  } else {\n    return (\n      ",i+=this.fields.map(function(e,t){return void 0===e.defaultValue()?"t"+t+"._check(v."+e.name+", f)":"(v"+t+" === undefined || t"+t+"._check(v"+t+", f))"}).join(" &&\n      "),i+="\n    );\n  }\n"}else i+="  return true;\n";return i+="};",new Function(n.join(),i).apply(void 0,o)},O.prototype._createReader=function(){for(var e=[],t=[this.recordConstructor],r=0,n=this.fields.length;r<n;r++)e.push("t"+r),t.push(this.fields[r].type);var o=this._getConstructorName(),i="return function read"+o+"(t) {\n";return i+="  return new "+o+"(\n    ",i+=e.map(function(e){return e+"._read(t)"}).join(",\n    "),i+="\n  );\n};",e.unshift(o),new Function(e.join(),i).apply(void 0,t)},O.prototype._createSkipper=function(){for(var e=[],t="return function skip"+this._getConstructorName()+"(t) {\n",r=[],n=0,o=this.fields.length;n<o;n++)e.push("t"+n),r.push(this.fields[n].type),t+="  t"+n+"._skip(t);\n";return t+="}",new Function(e.join(),t).apply(void 0,r)},O.prototype._createWriter=function(){for(var e,t,r=[],n="return function write"+this._getConstructorName()+"(t, v) {\n",o=[],i=0,a=this.fields.length;i<a;i++)e=this.fields[i],r.push("t"+i),o.push(e.type),n+="  ",void 0===e.defaultValue()?n+="t"+i+"._write(t, v."+e.name+");\n":(t=e.type.toBuffer(e.defaultValue()).toString("binary"),r.push("d"+i),o.push(t),n+="var v"+i+" = v."+e.name+";\n",n+="if (v"+i+" === undefined) {\n",n+="    t.writeBinary(d"+i+", "+t.length+");\n",n+="  } else {\n    t"+i+"._write(t, v"+i+");\n  }\n");return n+="}",new Function(r.join(),n).apply(void 0,o)},O.prototype._update=function(e,t,r){if(t.name&&!~C(this).indexOf(t.name))throw new Error(w("no alias found for %s",t.name));for(var n,o,i,a,s,u,c=this.fields,f=t.fields,p=_.toMap(f,function(e){return e.name}),l=[],h={},d=0;d<c.length;d++){for(a=C(o=c[d]),s=[],n=0;n<a.length;n++)p[i=a[n]]&&s.push(i);if(1<s.length)throw new Error(w("ambiguous aliasing for %s.%s (%s)",t.name,o.name,s));if(s.length)i=s[0],u={resolver:o.type.createResolver(p[i].type,r),name:"_"+o.name},h[i]?h[i].push(u):h[i]=[u],l.push(u.name);else{if(void 0===o.defaultValue())throw new Error(w("no matching field for default-less %s.%s",t.name,o.name));l.push("undefined")}}var y=-1;for(d=f.length;d&&void 0===h[f[--d].name];)y=d;var g=this._getConstructorName(),m=[g],v=[this.recordConstructor],b="  return function read"+g+"(t, b) {\n";for(d=0;d<f.length;d++)if(d===y&&(b+="  if (!b) {\n"),void 0===h[i=(o=t.fields[d]).name])b+=~y&&y<=d?"    ":"  ",m.push("r"+d),v.push(o.type),b+="r"+d+"._skip(t);\n";else for(n=h[i].length;n--;)b+=~y&&y<=d?"    ":"  ",m.push("r"+d+"f"+n),u=h[i][n],v.push(u.resolver),b+="var "+u.name+" = ",b+="r"+d+"f"+n+"._"+(n?"peek":"read")+"(t);\n";~y&&(b+="  }\n"),b+="  return new "+g+"("+l.join()+");\n};",e._read=new Function(m.join(),b).apply(void 0,v)},O.prototype._match=function(e,t){for(var r,n,o=this.fields,i=0,a=o.length;i<a;i++)if(r=(n=o[i])._order,n=n.type,r){if(r*=n._match(e,t))return r}else n._skip(e),n._skip(t);return 0},O.prototype._checkFields=function(e){for(var t=Object.keys(e),r=0,n=t.length;r<n;r++)if(!this._fieldsByName[t[r]])return!1;return!0},O.prototype._copy=function(e,t){for(var r,n,o=t&&t.fieldHook,i=[void 0],a=0,s=this.fields.length;a<s;a++)void 0===(n=e[(r=this.fields[a]).name])&&r.hasOwnProperty("defaultValue")&&(n=r.defaultValue()),(t&&!t.skip||void 0!==n)&&(n=r.type._copy(n,t)),o&&(n=o(r,n,this)),i.push(n);var u=this.recordConstructor;return new(u.bind.apply(u,i))},O.prototype._deref=function(e,o){e.fields=this.fields.map(function(e){var t,r=e.type,n={name:e.name,type:r._attrs(o)};return o.exportAttrs&&(void 0!==(t=e.defaultValue())&&(n.default=r._copy(t,{coerce:3,wrap:3})),"ascending"!==(t=e.order)&&(n.order=t),(t=e.aliases).length&&(n.aliases=t),void 0!==(e=e.doc)&&(n.doc=e)),n})},O.prototype.compare=function(e,t){for(var r,n,o,i=this.fields,a=0,s=i.length;a<s;a++)if(o=i[a],r=o.name,n=o._order,o=o.type,n&&(n*=o.compare(e[r],t[r])))return n;return 0},O.prototype.random=function(){var e=this.fields.map(function(e){return e.type.random()});e.unshift(void 0);var t=this.recordConstructor;return new(t.bind.apply(t,e))},O.prototype.getField=O.prototype.field=function(e){return this._fieldsByName[e]},O.prototype.getFields=function(){return this.fields},O.prototype.getRecordConstructor=function(){return this.recordConstructor},Object.defineProperty(O.prototype,"typeName",{enumerable:!0,get:function(){return this._isError?"error":"record"}}),y.inherits(j,m),Object.defineProperty(j.prototype,"typeName",{enumerable:!0,get:function(){return"logical:"+this._logicalTypeName}}),Object.defineProperty(j.prototype,"underlyingType",{enumerable:!0,get:function(){if(this._underlyingType)return this._underlyingType;for(var e,t=0,r=a.length;t<r;t++)if((e=a[t])[0]===this)return e[1]}}),j.prototype.getUnderlyingType=function(){return this.underlyingType},j.prototype._read=function(e){return this._fromValue(this.underlyingType._read(e))},j.prototype._write=function(e,t){this.underlyingType._write(e,this._toValue(t))},j.prototype._check=function(e,t,r,n){try{var o=this._toValue(e)}catch(e){}return void 0===o?(r&&r(e,this),!1):this.underlyingType._check(o,t,r,n)},j.prototype._copy=function(e,t){var r=this.underlyingType;switch(t&&t.coerce){case 3:return r._copy(this._toValue(e),t);case 2:return this._fromValue(r._copy(e,t));default:return this._fromValue(r._copy(this._toValue(e),t))}},j.prototype._update=function(e,t,r){var n=this._resolve(t,r);n&&(e._read=function(e){return n(t._read(e))})},j.prototype.compare=function(e,t){e=this._toValue(e),t=this._toValue(t);return this.underlyingType.compare(e,t)},j.prototype.random=function(){return this._fromValue(this.underlyingType.random())},j.prototype._deref=function(e,t){var r=this.underlyingType,n=void 0!==r.name&&t.derefed[r.name];return e=r._attrs(t),!n&&t.exportAttrs&&("string"==typeof e&&(e={type:e}),e.logicalType=this._logicalTypeName,this._export(e)),e},j.prototype._skip=function(e){this.underlyingType._skip(e)},j.prototype._export=function(){},j.prototype._fromValue=_.abstractFunction,j.prototype._toValue=_.abstractFunction,j.prototype._resolve=_.abstractFunction,y.inherits(P,l),P.prototype.typeName="abstract:long",P.prototype._check=function(e,t,r){var n=this._isValid(e);return!n&&r&&r(e,this),n},P.prototype._read=function(e){var t=this._noUnpack?(t=e.pos,e.skipLong(),e.buf.slice(t,e.pos)):e.unpackLongBytes(e);if(e.isValid())return this._fromBuffer(t)},P.prototype._write=function(e,t){this._isValid(t)||W(t,this);t=this._toBuffer(t);this._noUnpack?e.writeFixed(t):e.packLongBytes(t)},P.prototype._copy=function(e,t){switch(t&&t.coerce){case 3:return this._toJSON(e);case 2:return this._fromJSON(e);default:return this._fromJSON(this._toJSON(e))}},P.prototype._deref=function(){return"long"},P.prototype._update=function(e,t){var r=this;switch(t.typeName){case"int":e._read=function(e){return r._fromJSON(t._read(e))};break;case"abstract:long":case"long":e._read=function(e){return r._read(e)}}},P.prototype.random=function(){return this._fromJSON(l.prototype.random())},P.prototype._fromBuffer=_.abstractFunction,P.prototype._toBuffer=_.abstractFunction,P.prototype._fromJSON=_.abstractFunction,P.prototype._toJSON=_.abstractFunction,P.prototype._isValid=_.abstractFunction,P.prototype.compare=_.abstractFunction,R.prototype.defaultValue=function(){},Object.defineProperty(R.prototype,"order",{enumerable:!0,get:function(){return["descending","ignore","ascending"][this._order+1]}}),R.prototype.getAliases=function(){return this.aliases},R.prototype.getDefault=R.prototype.defaultValue,R.prototype.getName=function(){return this.name},R.prototype.getOrder=function(){return this.order},R.prototype.getType=function(){return this.type},B.prototype._peek=m.prototype._peek,B.prototype.inspect=function(){return"<Resolver>"},J.exports={Type:m,getTypeBucket:q,getValueBucket:z,isPrimitive:L,builtins:function(){for(var e,t={LogicalType:j,UnwrappedUnionType:S,WrappedUnionType:E},r=Object.keys(c),n=0,o=r.length;n<o;n++)t[M(e=r[n])]=c[e];return t}()}}).call(this)}).call(this,$("buffer").Buffer)},{"./utils":8,buffer:13,util:53}],8:[function(y,g,e){(function(d){(function(){"use strict";var r=y("crypto"),s=y("util"),n=new e(4096),t=/^[A-Za-z_][A-Za-z0-9_]*$/,o=s.format;function u(e){return"function"==typeof d.alloc?d.alloc(e):new d(e)}function i(e,t){return"function"==typeof d.from?d.from(e,t):new d(e,t)}function c(e){return e.charAt(0).toUpperCase()+e.slice(1)}function a(e){return t.test(e)}function e(e){this._len=0|e,this._pos=0,this._slab=u(this._len)}function f(e){var t=Math.pow(2,31),r=Math.floor(e||Math.random()*(t-1));this._max=t,this._nextInt=function(){return r=(1103515245*r+12345)%t}}function p(){this._index=0,this._items=[]}function l(e,t){if(this.buf=e,this.pos=0|t,this.pos<0)throw new Error("negative offset")}function h(e,t){for(;t--;)e[t]=~e[t]}e.prototype.alloc=function(e){if(e<0)throw new Error("negative length");var t=this._len;return t<e?u(e):(this._pos+e>t&&(this._slab=u(t),this._pos=0),this._slab.slice(this._pos,this._pos+=e))},f.prototype.nextBoolean=function(){return!!(this._nextInt()%2)},f.prototype.nextInt=function(e,t){return void 0===t&&(t=e,e=0),t=void 0===t?this._max:t,e+Math.floor(this.nextFloat()*(t-e))},f.prototype.nextFloat=function(e,t){return void 0===t&&(t=e,e=0),e+((t=void 0===t?1:t)-e)*this._nextInt()/this._max},f.prototype.nextString=function(e,t){e|=0;var r="";-1<(t=t||"aA").indexOf("a")&&(r+="abcdefghijklmnopqrstuvwxyz"),-1<t.indexOf("A")&&(r+="ABCDEFGHIJKLMNOPQRSTUVWXYZ"),-1<t.indexOf("#")&&(r+="0123456789"),-1<t.indexOf("!")&&(r+="~`!@#$%^&*()_+-={}[]:\";'<>?,./|\\");for(var n=[],o=0;o<e;o++)n.push(this.choice(r));return n.join("")},f.prototype.nextBuffer=function(e){for(var t=[],r=0;r<e;r++)t.push(this.nextInt(256));return i(t)},f.prototype.choice=function(e){var t=e.length;if(!t)throw new Error("choosing from empty array");return e[this.nextInt(t)]},p.prototype.push=function(e){var t,r=this._items,n=0|r.length;for(r.push(e);0<n&&r[n].index<r[t=n-1>>1].index;)e=r[n],r[n]=r[t],r[t]=e,n=t},p.prototype.pop=function(){var e=this._items,t=e.length-1|0,r=e[0];if(!r||r.index>this._index)return null;if(this._index++,!t)return e.pop(),r;e[0]=e.pop();for(var n,o,i,a,s,u,c=t>>1,f=0;f<c&&(i=e[f],o=f+1<<1,s=e[n=1+(f<<1)],o=!(u=e[o])||s.index<=u.index?(a=s,n):(a=u,o),!(a.index>=i.index));)e[o]=i,e[f]=a,f=o;return r},l.prototype.isValid=function(){return this.pos<=this.buf.length},l.prototype._invalidate=function(){this.pos=this.buf.length+1},l.prototype.readBoolean=function(){return!!this.buf[this.pos++]},l.prototype.skipBoolean=function(){this.pos++},l.prototype.writeBoolean=function(e){this.buf[this.pos++]=!!e},l.prototype.readInt=l.prototype.readLong=function(){for(var e,t,r,n,o=0,i=0,a=this.buf;t=128&(e=a[this.pos++]),o|=(127&e)<<i,i+=7,t&&i<28;);if(t){for(r=o,n=268435456;r+=(127&(e=a[this.pos++]))*n,n*=128,128&e;);return(r%2?-(r+1):r)/2}return o>>1^-(1&o)},l.prototype.skipInt=l.prototype.skipLong=function(){for(var e=this.buf;128&e[this.pos++];);},l.prototype.writeInt=l.prototype.writeLong=function(e){var t,r,n=this.buf;if(-1073741824<=e&&e<1073741824)for(r=0<=e?e<<1:~e<<1|1;n[this.pos]=127&r,r>>=7,r&&(n[this.pos++]|=128););else for(t=0<=e?2*e:2*-e-1;n[this.pos]=127&t,t/=128,1<=t&&(n[this.pos++]|=128););this.pos++},l.prototype.readFloat=function(){var e=this.buf,t=this.pos;return this.pos+=4,this.pos>e.length?0:this.buf.readFloatLE(t)},l.prototype.skipFloat=function(){this.pos+=4},l.prototype.writeFloat=function(e){var t=this.buf,r=this.pos;if(this.pos+=4,!(this.pos>t.length))return this.buf.writeFloatLE(e,r)},l.prototype.readDouble=function(){var e=this.buf,t=this.pos;return this.pos+=8,this.pos>e.length?0:this.buf.readDoubleLE(t)},l.prototype.skipDouble=function(){this.pos+=8},l.prototype.writeDouble=function(e){var t=this.buf,r=this.pos;if(this.pos+=8,!(this.pos>t.length))return this.buf.writeDoubleLE(e,r)},l.prototype.readFixed=function(e){var t=this.pos;if(this.pos+=e,!(this.pos>this.buf.length)){var r=n.alloc(e);return this.buf.copy(r,0,t,t+e),r}},l.prototype.skipFixed=function(e){this.pos+=e},l.prototype.writeFixed=function(e,t){t=t||e.length;var r=this.pos;this.pos+=t,this.pos>this.buf.length||e.copy(this.buf,r,0,t)},l.prototype.readBytes=function(){var e=this.readLong();if(!(e<0))return this.readFixed(e);this._invalidate()},l.prototype.skipBytes=function(){var e=this.readLong();e<0?this._invalidate():this.pos+=e},l.prototype.writeBytes=function(e){var t=e.length;this.writeLong(t),this.writeFixed(e,t)},"function"==typeof d.prototype.utf8Slice?l.prototype.readString=function(){var e=this.readLong();if(e<0)return this._invalidate(),"";var t=this.pos,r=this.buf;return this.pos+=e,this.pos>r.length?void 0:this.buf.utf8Slice(t,t+e)}:l.prototype.readString=function(){var e=this.readLong();if(e<0)return this._invalidate(),"";var t=this.pos,r=this.buf;return this.pos+=e,this.pos>r.length?void 0:this.buf.slice(t,t+e).toString()},l.prototype.skipString=function(){var e=this.readLong();e<0?this._invalidate():this.pos+=e},l.prototype.writeString=function(e){var t=d.byteLength(e),r=this.buf;this.writeLong(t);var n=this.pos;if(this.pos+=t,!(this.pos>r.length))if(64<t&&"function"==typeof d.prototype.utf8Write)r.utf8Write(e,n,t);else for(var o,i,a=0,s=t;a<s;a++)(o=e.charCodeAt(a))<128?r[n++]=o:(o<2048?r[n++]=o>>6|192:(55296==(64512&o)&&56320==(64512&(i=e.charCodeAt(a+1)))?(o=65536+((1023&o)<<10)+(1023&i),a++,r[n++]=o>>18|240,r[n++]=o>>12&63|128):r[n++]=o>>12|224,r[n++]=o>>6&63|128),r[n++]=63&o|128)},"function"==typeof d.prototype.latin1Write?l.prototype.writeBinary=function(e,t){var r=this.pos;this.pos+=t,this.pos>this.buf.length||this.buf.latin1Write(e,r,t)}:"function"==typeof d.prototype.binaryWrite?l.prototype.writeBinary=function(e,t){var r=this.pos;this.pos+=t,this.pos>this.buf.length||this.buf.binaryWrite(e,r,t)}:l.prototype.writeBinary=function(e,t){var r=this.pos;this.pos+=t,this.pos>this.buf.length||this.buf.write(e,r,t,"binary")},l.prototype.matchBoolean=function(e){return this.buf[this.pos++]-e.buf[e.pos++]},l.prototype.matchInt=l.prototype.matchLong=function(e){var t=this.readLong(),e=e.readLong();return t===e?0:t<e?-1:1},l.prototype.matchFloat=function(e){var t=this.readFloat(),e=e.readFloat();return t===e?0:t<e?-1:1},l.prototype.matchDouble=function(e){var t=this.readDouble(),e=e.readDouble();return t===e?0:t<e?-1:1},l.prototype.matchFixed=function(e,t){return this.readFixed(t).compare(e.readFixed(t))},l.prototype.matchBytes=l.prototype.matchString=function(e){var t=this.readLong(),r=this.pos;this.pos+=t;var n=e.readLong(),t=e.pos;e.pos+=n;r=this.buf.slice(r,this.pos),e=e.buf.slice(t,e.pos);return r.compare(e)},l.prototype.unpackLongBytes=function(){var e=u(8),t=0,r=0,n=6,o=this.buf,i=o[this.pos++],a=1&i;for(e.fill(0),t|=(127&i)>>1;128&i;)t|=(127&(i=o[this.pos++]))<<n,8<=(n+=7)&&(n-=8,e[r++]=t,t>>=8);return e[r]=t,a&&h(e,8),e},l.prototype.packLongBytes=function(e){for(var t=(128&e[7])>>7,r=this.buf,n=1,o=0,i=3,a=t?(h(e,8),1):0,s=[e.readUIntLE(0,3),e.readUIntLE(3,3),e.readUIntLE(6,2)];i&&!s[--i];);for(;o<i;)for(a|=s[o++]<<n,n+=24;7<n;)r[this.pos++]=127&a|128,a>>=7,n-=7;for(a|=s[i]<<n;r[this.pos]=127&a,a>>=7,a&&(r[this.pos++]|=128););this.pos++,t&&h(e,8)},g.exports={abstractFunction:function(){throw new Error("abstract")},addDeprecatedGetters:function(e,t){for(var r,n,o=e.prototype,i=0,a=t.length;i<a;i++)o[n="get"+c(r=t[i])]=s.deprecate(function(t){return function(){var e=this[t];return"function"==typeof e?e.apply(this,arguments):e}}(r),"use `."+r+"` instead of `."+n+"()`")},bufferFrom:i,capitalize:c,copyOwnProperties:function(e,t,r){for(var n=Object.getOwnPropertyNames(e),o=0,i=n.length;o<i;o++){var a,s=n[o];t.hasOwnProperty(s)&&!r||(a=Object.getOwnPropertyDescriptor(e,s),Object.defineProperty(t,s,a))}return t},getHash:function(e,t){return t=t||"md5",(t=r.createHash(t)).end(e),t.read()},compare:function(e,t){return e===t?0:e<t?-1:1},getOption:function(e,t,r){return void 0===(t=e[t])?r:t},impliedNamespace:function(e){return(e=/^(.*)\.[^.]+$/.exec(e))?e[1]:void 0},isValidName:a,jsonEnd:function(e,t){t|=0;var r=e.charAt(t++);if(/[\d-]/.test(r)){for(;/[eE\d.+-]/.test(e.charAt(t));)t++;return t}if(/true|null/.test(e.slice(t-1,t+3)))return t+3;if(/false/.test(e.slice(t-1,t+4)))return t+4;var n=0,o=!1;do{switch(r){case"{":case"[":o||n++;break;case"}":case"]":if(!o&&!--n)return t;break;case'"':if(o=!o,!n&&!o)return t;break;case"\\":t++}}while(r=e.charAt(t++));return-1},newBuffer:u,objectValues:function(t){return Object.keys(t).map(function(e){return t[e]})},qualify:function(t,e){return~t.indexOf(".")?t=t.replace(/^\./,""):e&&(t=e+"."+t),t.split(".").forEach(function(e){if(!a(e))throw new Error(o("invalid name: %j",t))}),t},toMap:function(e,t){for(var r,n={},o=0;o<e.length;o++)n[t(r=e[o])]=r;return n},singleIndexOf:function(e,t){var r,n,o=-1;if(!e)return-1;for(r=0,n=e.length;r<n;r++)if(e[r]===t){if(0<=o)return-2;o=r}return o},hasDuplicates:function(e,t){for(var r,n=Object.create(null),o=0,i=e.length;o<i;o++){if(r=e[o],t&&(r=t(r)),n[r])return!0;n[r]=!0}return!1},unqualify:function(e){return(e=e.split("."))[e.length-1]},BufferPool:e,Lcg:f,OrderedQueue:p,Tap:l}}).call(this)}).call(this,y("buffer").Buffer)},{buffer:13,crypto:3,util:53}],9:[function(e,t,r){t.exports=function(e,t,r){if(e.filter)return e.filter(t,r);if(null==e)throw new TypeError;if("function"!=typeof t)throw new TypeError;for(var n,o=[],i=0;i<e.length;i++)a.call(e,i)&&(n=e[i],t.call(r,n,i,e)&&o.push(n));return o};var a=Object.prototype.hasOwnProperty},{}],10:[function(r,n,e){(function(t){(function(){"use strict";var e=r("array-filter");n.exports=function(){return e(["BigInt64Array","BigUint64Array","Float32Array","Float64Array","Int16Array","Int32Array","Int8Array","Uint16Array","Uint32Array","Uint8Array","Uint8ClampedArray"],function(e){return"function"==typeof t[e]})}}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"array-filter":9}],11:[function(e,t,r){"use strict";r.byteLength=function(e){var t=f(e),e=t[0],t=t[1];return 3*(e+t)/4-t},r.toByteArray=function(e){var t,r,n=f(e),o=n[0],n=n[1],i=new c(function(e,t){return 3*(e+t)/4-t}(o,n)),a=0,s=0<n?o-4:o;for(r=0;r<s;r+=4)t=u[e.charCodeAt(r)]<<18|u[e.charCodeAt(r+1)]<<12|u[e.charCodeAt(r+2)]<<6|u[e.charCodeAt(r+3)],i[a++]=t>>16&255,i[a++]=t>>8&255,i[a++]=255&t;2===n&&(t=u[e.charCodeAt(r)]<<2|u[e.charCodeAt(r+1)]>>4,i[a++]=255&t);1===n&&(t=u[e.charCodeAt(r)]<<10|u[e.charCodeAt(r+1)]<<4|u[e.charCodeAt(r+2)]>>2,i[a++]=t>>8&255,i[a++]=255&t);return i},r.fromByteArray=function(e){for(var t,r=e.length,n=r%3,o=[],i=0,a=r-n;i<a;i+=16383)o.push(function(e,t,r){for(var n,o=[],i=t;i<r;i+=3)n=(e[i]<<16&16711680)+(e[i+1]<<8&65280)+(255&e[i+2]),o.push(function(e){return s[e>>18&63]+s[e>>12&63]+s[e>>6&63]+s[63&e]}(n));return o.join("")}(e,i,a<i+16383?a:i+16383));1==n?(t=e[r-1],o.push(s[t>>2]+s[t<<4&63]+"==")):2==n&&(t=(e[r-2]<<8)+e[r-1],o.push(s[t>>10]+s[t>>4&63]+s[t<<2&63]+"="));return o.join("")};for(var s=[],u=[],c="undefined"!=typeof Uint8Array?Uint8Array:Array,n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",o=0,i=n.length;o<i;++o)s[o]=n[o],u[n.charCodeAt(o)]=o;function f(e){var t=e.length;if(0<t%4)throw new Error("Invalid string. Length must be a multiple of 4");e=e.indexOf("=");return-1===e&&(e=t),[e,e===t?0:4-e%4]}u["-".charCodeAt(0)]=62,u["_".charCodeAt(0)]=63},{}],12:[function(e,t,r){},{}],13:[function(R,e,B){(function(e){(function(){"use strict";var s=R("base64-js"),i=R("ieee754");B.Buffer=p,B.SlowBuffer=function(e){+e!=e&&(e=0);return p.alloc(+e)},B.INSPECT_MAX_BYTES=50;var t=2147483647;function o(e){if(t<e)throw new RangeError('The value "'+e+'" is invalid for option "size"');e=new Uint8Array(e);return e.__proto__=p.prototype,e}function p(e,t,r){if("number"!=typeof e)return n(e,t,r);if("string"==typeof t)throw new TypeError('The "string" argument must be of type string. Received type number');return u(e)}function n(e,t,r){if("string"==typeof e)return function(e,t){"string"==typeof t&&""!==t||(t="utf8");if(!p.isEncoding(t))throw new TypeError("Unknown encoding: "+t);var r=0|l(e,t),n=o(r),t=n.write(e,t);t!==r&&(n=n.slice(0,t));return n}(e,t);if(ArrayBuffer.isView(e))return c(e);if(null==e)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(j(e,ArrayBuffer)||e&&j(e.buffer,ArrayBuffer))return function(e,t,r){if(t<0||e.byteLength<t)throw new RangeError('"offset" is outside of buffer bounds');if(e.byteLength<t+(r||0))throw new RangeError('"length" is outside of buffer bounds');r=void 0===t&&void 0===r?new Uint8Array(e):void 0===r?new Uint8Array(e,t):new Uint8Array(e,t,r);return r.__proto__=p.prototype,r}(e,t,r);if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type number');var n=e.valueOf&&e.valueOf();if(null!=n&&n!==e)return p.from(n,t,r);n=function(e){if(p.isBuffer(e)){var t=0|f(e.length),r=o(t);return 0===r.length?r:(e.copy(r,0,0,t),r)}if(void 0!==e.length)return"number"!=typeof e.length||P(e.length)?o(0):c(e);if("Buffer"===e.type&&Array.isArray(e.data))return c(e.data)}(e);if(n)return n;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return p.from(e[Symbol.toPrimitive]("string"),t,r);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function a(e){if("number"!=typeof e)throw new TypeError('"size" argument must be of type number');if(e<0)throw new RangeError('The value "'+e+'" is invalid for option "size"')}function u(e){return a(e),o(e<0?0:0|f(e))}function c(e){for(var t=e.length<0?0:0|f(e.length),r=o(t),n=0;n<t;n+=1)r[n]=255&e[n];return r}function f(e){if(t<=e)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+t.toString(16)+" bytes");return 0|e}function l(e,t){if(p.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||j(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);var r=e.length,n=2<arguments.length&&!0===arguments[2];if(!n&&0===r)return 0;for(var o=!1;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return T(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return x(e).length;default:if(o)return n?-1:T(e).length;t=(""+t).toLowerCase(),o=!0}}function r(e,t,r){var n,o,i,a=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e=e||"utf8";;)switch(e){case"hex":return function(e,t,r){var n=e.length;(!t||t<0)&&(t=0);(!r||r<0||n<r)&&(r=n);for(var o="",i=t;i<r;++i)o+=function(e){return e<16?"0"+e.toString(16):e.toString(16)}(e[i]);return o}(this,t,r);case"utf8":case"utf-8":return v(this,t,r);case"ascii":return function(e,t,r){var n="";r=Math.min(e.length,r);for(var o=t;o<r;++o)n+=String.fromCharCode(127&e[o]);return n}(this,t,r);case"latin1":case"binary":return function(e,t,r){var n="";r=Math.min(e.length,r);for(var o=t;o<r;++o)n+=String.fromCharCode(e[o]);return n}(this,t,r);case"base64":return n=this,i=r,0===(o=t)&&i===n.length?s.fromByteArray(n):s.fromByteArray(n.slice(o,i));case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return function(e,t,r){for(var n=e.slice(t,r),o="",i=0;i<n.length;i+=2)o+=String.fromCharCode(n[i]+256*n[i+1]);return o}(this,t,r);default:if(a)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),a=!0}}function h(e,t,r){var n=e[t];e[t]=e[r],e[r]=n}function d(e,t,r,n,o){if(0===e.length)return-1;if("string"==typeof r?(n=r,r=0):2147483647<r?r=2147483647:r<-2147483648&&(r=-2147483648),P(r=+r)&&(r=o?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(o)return-1;r=e.length-1}else if(r<0){if(!o)return-1;r=0}if("string"==typeof t&&(t=p.from(t,n)),p.isBuffer(t))return 0===t.length?-1:y(e,t,r,n,o);if("number"==typeof t)return t&=255,"function"==typeof Uint8Array.prototype.indexOf?(o?Uint8Array.prototype.indexOf:Uint8Array.prototype.lastIndexOf).call(e,t,r):y(e,[t],r,n,o);throw new TypeError("val must be string, number or Buffer")}function y(e,t,r,n,o){var i=1,a=e.length,s=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;a/=i=2,s/=2,r/=2}function u(e,t){return 1===i?e[t]:e.readUInt16BE(t*i)}if(o)for(var c=-1,f=r;f<a;f++)if(u(e,f)===u(t,-1===c?0:f-c)){if(-1===c&&(c=f),f-c+1===s)return c*i}else-1!==c&&(f-=f-c),c=-1;else for(a<r+s&&(r=a-s),f=r;0<=f;f--){for(var p=!0,l=0;l<s;l++)if(u(e,f+l)!==u(t,l)){p=!1;break}if(p)return f}return-1}function g(e,t,r,n){return O(function(e){for(var t=[],r=0;r<e.length;++r)t.push(255&e.charCodeAt(r));return t}(t),e,r,n)}function m(e,t,r,n){return O(function(e,t){for(var r,n,o=[],i=0;i<e.length&&!((t-=2)<0);++i)n=e.charCodeAt(i),r=n>>8,n=n%256,o.push(n),o.push(r);return o}(t,e.length-r),e,r,n)}function v(e,t,r){r=Math.min(e.length,r);for(var n=[],o=t;o<r;){var i,a,s,u,c=e[o],f=null,p=239<c?4:223<c?3:191<c?2:1;if(o+p<=r)switch(p){case 1:c<128&&(f=c);break;case 2:128==(192&(i=e[o+1]))&&127<(u=(31&c)<<6|63&i)&&(f=u);break;case 3:i=e[o+1],a=e[o+2],128==(192&i)&&128==(192&a)&&2047<(u=(15&c)<<12|(63&i)<<6|63&a)&&(u<55296||57343<u)&&(f=u);break;case 4:i=e[o+1],a=e[o+2],s=e[o+3],128==(192&i)&&128==(192&a)&&128==(192&s)&&65535<(u=(15&c)<<18|(63&i)<<12|(63&a)<<6|63&s)&&u<1114112&&(f=u)}null===f?(f=65533,p=1):65535<f&&(f-=65536,n.push(f>>>10&1023|55296),f=56320|1023&f),n.push(f),o+=p}return function(e){var t=e.length;if(t<=b)return String.fromCharCode.apply(String,e);var r="",n=0;for(;n<t;)r+=String.fromCharCode.apply(String,e.slice(n,n+=b));return r}(n)}B.kMaxLength=t,(p.TYPED_ARRAY_SUPPORT=function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()}catch(e){return!1}}())||"undefined"==typeof console||"function"!=typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(p.prototype,"parent",{enumerable:!0,get:function(){if(p.isBuffer(this))return this.buffer}}),Object.defineProperty(p.prototype,"offset",{enumerable:!0,get:function(){if(p.isBuffer(this))return this.byteOffset}}),"undefined"!=typeof Symbol&&null!=Symbol.species&&p[Symbol.species]===p&&Object.defineProperty(p,Symbol.species,{value:null,configurable:!0,enumerable:!1,writable:!1}),p.poolSize=8192,p.from=n,p.prototype.__proto__=Uint8Array.prototype,p.__proto__=Uint8Array,p.alloc=function(e,t,r){return t=t,r=r,a(e=e),!(e<=0)&&void 0!==t?"string"==typeof r?o(e).fill(t,r):o(e).fill(t):o(e)},p.allocUnsafe=u,p.allocUnsafeSlow=u,p.isBuffer=function(e){return null!=e&&!0===e._isBuffer&&e!==p.prototype},p.compare=function(e,t){if(j(e,Uint8Array)&&(e=p.from(e,e.offset,e.byteLength)),j(t,Uint8Array)&&(t=p.from(t,t.offset,t.byteLength)),!p.isBuffer(e)||!p.isBuffer(t))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===t)return 0;for(var r=e.length,n=t.length,o=0,i=Math.min(r,n);o<i;++o)if(e[o]!==t[o]){r=e[o],n=t[o];break}return r<n?-1:n<r?1:0},p.isEncoding=function(e){switch(String(e).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}},p.concat=function(e,t){if(!Array.isArray(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return p.alloc(0);if(void 0===t)for(o=t=0;o<e.length;++o)t+=e[o].length;for(var r=p.allocUnsafe(t),n=0,o=0;o<e.length;++o){var i=e[o];if(j(i,Uint8Array)&&(i=p.from(i)),!p.isBuffer(i))throw new TypeError('"list" argument must be an Array of Buffers');i.copy(r,n),n+=i.length}return r},p.byteLength=l,p.prototype._isBuffer=!0,p.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)h(this,t,t+1);return this},p.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)h(this,t,t+3),h(this,t+1,t+2);return this},p.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)h(this,t,t+7),h(this,t+1,t+6),h(this,t+2,t+5),h(this,t+3,t+4);return this},p.prototype.toLocaleString=p.prototype.toString=function(){var e=this.length;return 0===e?"":0===arguments.length?v(this,0,e):r.apply(this,arguments)},p.prototype.equals=function(e){if(!p.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===p.compare(this,e)},p.prototype.inspect=function(){var e="",t=B.INSPECT_MAX_BYTES,e=this.toString("hex",0,t).replace(/(.{2})/g,"$1 ").trim();return this.length>t&&(e+=" ... "),"<Buffer "+e+">"},p.prototype.compare=function(e,t,r,n,o){if(j(e,Uint8Array)&&(e=p.from(e,e.offset,e.byteLength)),!p.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===n&&(n=0),void 0===o&&(o=this.length),t<0||r>e.length||n<0||o>this.length)throw new RangeError("out of range index");if(o<=n&&r<=t)return 0;if(o<=n)return-1;if(r<=t)return 1;if(this===e)return 0;for(var i=(o>>>=0)-(n>>>=0),a=(r>>>=0)-(t>>>=0),s=Math.min(i,a),u=this.slice(n,o),c=e.slice(t,r),f=0;f<s;++f)if(u[f]!==c[f]){i=u[f],a=c[f];break}return i<a?-1:a<i?1:0},p.prototype.includes=function(e,t,r){return-1!==this.indexOf(e,t,r)},p.prototype.indexOf=function(e,t,r){return d(this,e,t,r,!0)},p.prototype.lastIndexOf=function(e,t,r){return d(this,e,t,r,!1)},p.prototype.write=function(e,t,r,n){if(void 0===t)n="utf8",r=this.length,t=0;else if(void 0===r&&"string"==typeof t)n=t,r=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t>>>=0,isFinite(r)?(r>>>=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}var o=this.length-t;if((void 0===r||o<r)&&(r=o),0<e.length&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n=n||"utf8";for(var i,a,s,u=!1;;)switch(n){case"hex":return function(e,t,r,n){r=Number(r)||0;var o=e.length-r;(!n||o<(n=Number(n)))&&(n=o),(o=t.length)/2<n&&(n=o/2);for(var i=0;i<n;++i){var a=parseInt(t.substr(2*i,2),16);if(P(a))return i;e[r+i]=a}return i}(this,e,t,r);case"utf8":case"utf-8":return a=t,s=r,O(T(e,(i=this).length-a),i,a,s);case"ascii":return g(this,e,t,r);case"latin1":case"binary":return g(this,e,t,r);case"base64":return i=this,a=t,s=r,O(x(e),i,a,s);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return m(this,e,t,r);default:if(u)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),u=!0}},p.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var b=4096;function _(e,t,r){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(r<e+t)throw new RangeError("Trying to access beyond buffer length")}function w(e,t,r,n,o,i){if(!p.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(o<t||t<i)throw new RangeError('"value" argument is out of bounds');if(r+n>e.length)throw new RangeError("Index out of range")}function S(e,t,r,n){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function E(e,t,r,n,o){return t=+t,r>>>=0,o||S(e,0,r,4),i.write(e,t,r,n,23,4),r+4}function A(e,t,r,n,o){return t=+t,r>>>=0,o||S(e,0,r,8),i.write(e,t,r,n,52,8),r+8}p.prototype.slice=function(e,t){var r=this.length;(e=~~e)<0?(e+=r)<0&&(e=0):r<e&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):r<t&&(t=r),t<e&&(t=e);t=this.subarray(e,t);return t.__proto__=p.prototype,t},p.prototype.readUIntLE=function(e,t,r){e>>>=0,t>>>=0,r||_(e,t,this.length);for(var n=this[e],o=1,i=0;++i<t&&(o*=256);)n+=this[e+i]*o;return n},p.prototype.readUIntBE=function(e,t,r){e>>>=0,t>>>=0,r||_(e,t,this.length);for(var n=this[e+--t],o=1;0<t&&(o*=256);)n+=this[e+--t]*o;return n},p.prototype.readUInt8=function(e,t){return e>>>=0,t||_(e,1,this.length),this[e]},p.prototype.readUInt16LE=function(e,t){return e>>>=0,t||_(e,2,this.length),this[e]|this[e+1]<<8},p.prototype.readUInt16BE=function(e,t){return e>>>=0,t||_(e,2,this.length),this[e]<<8|this[e+1]},p.prototype.readUInt32LE=function(e,t){return e>>>=0,t||_(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},p.prototype.readUInt32BE=function(e,t){return e>>>=0,t||_(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},p.prototype.readIntLE=function(e,t,r){e>>>=0,t>>>=0,r||_(e,t,this.length);for(var n=this[e],o=1,i=0;++i<t&&(o*=256);)n+=this[e+i]*o;return(o*=128)<=n&&(n-=Math.pow(2,8*t)),n},p.prototype.readIntBE=function(e,t,r){e>>>=0,t>>>=0,r||_(e,t,this.length);for(var n=t,o=1,i=this[e+--n];0<n&&(o*=256);)i+=this[e+--n]*o;return(o*=128)<=i&&(i-=Math.pow(2,8*t)),i},p.prototype.readInt8=function(e,t){return e>>>=0,t||_(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},p.prototype.readInt16LE=function(e,t){e>>>=0,t||_(e,2,this.length);e=this[e]|this[e+1]<<8;return 32768&e?4294901760|e:e},p.prototype.readInt16BE=function(e,t){e>>>=0,t||_(e,2,this.length);e=this[e+1]|this[e]<<8;return 32768&e?4294901760|e:e},p.prototype.readInt32LE=function(e,t){return e>>>=0,t||_(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},p.prototype.readInt32BE=function(e,t){return e>>>=0,t||_(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},p.prototype.readFloatLE=function(e,t){return e>>>=0,t||_(e,4,this.length),i.read(this,e,!0,23,4)},p.prototype.readFloatBE=function(e,t){return e>>>=0,t||_(e,4,this.length),i.read(this,e,!1,23,4)},p.prototype.readDoubleLE=function(e,t){return e>>>=0,t||_(e,8,this.length),i.read(this,e,!0,52,8)},p.prototype.readDoubleBE=function(e,t){return e>>>=0,t||_(e,8,this.length),i.read(this,e,!1,52,8)},p.prototype.writeUIntLE=function(e,t,r,n){e=+e,t>>>=0,r>>>=0,n||w(this,e,t,r,Math.pow(2,8*r)-1,0);var o=1,i=0;for(this[t]=255&e;++i<r&&(o*=256);)this[t+i]=e/o&255;return t+r},p.prototype.writeUIntBE=function(e,t,r,n){e=+e,t>>>=0,r>>>=0,n||w(this,e,t,r,Math.pow(2,8*r)-1,0);var o=r-1,i=1;for(this[t+o]=255&e;0<=--o&&(i*=256);)this[t+o]=e/i&255;return t+r},p.prototype.writeUInt8=function(e,t,r){return e=+e,t>>>=0,r||w(this,e,t,1,255,0),this[t]=255&e,t+1},p.prototype.writeUInt16LE=function(e,t,r){return e=+e,t>>>=0,r||w(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},p.prototype.writeUInt16BE=function(e,t,r){return e=+e,t>>>=0,r||w(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},p.prototype.writeUInt32LE=function(e,t,r){return e=+e,t>>>=0,r||w(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},p.prototype.writeUInt32BE=function(e,t,r){return e=+e,t>>>=0,r||w(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},p.prototype.writeIntLE=function(e,t,r,n){e=+e,t>>>=0,n||w(this,e,t,r,(n=Math.pow(2,8*r-1))-1,-n);var o=0,i=1,a=0;for(this[t]=255&e;++o<r&&(i*=256);)e<0&&0===a&&0!==this[t+o-1]&&(a=1),this[t+o]=(e/i>>0)-a&255;return t+r},p.prototype.writeIntBE=function(e,t,r,n){e=+e,t>>>=0,n||w(this,e,t,r,(n=Math.pow(2,8*r-1))-1,-n);var o=r-1,i=1,a=0;for(this[t+o]=255&e;0<=--o&&(i*=256);)e<0&&0===a&&0!==this[t+o+1]&&(a=1),this[t+o]=(e/i>>0)-a&255;return t+r},p.prototype.writeInt8=function(e,t,r){return e=+e,t>>>=0,r||w(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},p.prototype.writeInt16LE=function(e,t,r){return e=+e,t>>>=0,r||w(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},p.prototype.writeInt16BE=function(e,t,r){return e=+e,t>>>=0,r||w(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},p.prototype.writeInt32LE=function(e,t,r){return e=+e,t>>>=0,r||w(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},p.prototype.writeInt32BE=function(e,t,r){return e=+e,t>>>=0,r||w(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},p.prototype.writeFloatLE=function(e,t,r){return E(this,e,t,!0,r)},p.prototype.writeFloatBE=function(e,t,r){return E(this,e,t,!1,r)},p.prototype.writeDoubleLE=function(e,t,r){return A(this,e,t,!0,r)},p.prototype.writeDoubleBE=function(e,t,r){return A(this,e,t,!1,r)},p.prototype.copy=function(e,t,r,n){if(!p.isBuffer(e))throw new TypeError("argument should be a Buffer");if(r=r||0,n||0===n||(n=this.length),t>=e.length&&(t=e.length),t=t||0,0<n&&n<r&&(n=r),n===r)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t<n-r&&(n=e.length-t+r);var o=n-r;if(this===e&&"function"==typeof Uint8Array.prototype.copyWithin)this.copyWithin(t,r,n);else if(this===e&&r<t&&t<n)for(var i=o-1;0<=i;--i)e[i+t]=this[i+r];else Uint8Array.prototype.set.call(e,this.subarray(r,n),t);return o},p.prototype.fill=function(e,t,r,n){if("string"==typeof e){if("string"==typeof t?(n=t,t=0,r=this.length):"string"==typeof r&&(n=r,r=this.length),void 0!==n&&"string"!=typeof n)throw new TypeError("encoding must be a string");if("string"==typeof n&&!p.isEncoding(n))throw new TypeError("Unknown encoding: "+n);var o;1===e.length&&(o=e.charCodeAt(0),("utf8"===n&&o<128||"latin1"===n)&&(e=o))}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<r)throw new RangeError("Out of range index");if(r<=t)return this;var i;if(t>>>=0,r=void 0===r?this.length:r>>>0,"number"==typeof(e=e||0))for(i=t;i<r;++i)this[i]=e;else{var a=p.isBuffer(e)?e:p.from(e,n),s=a.length;if(0===s)throw new TypeError('The value "'+e+'" is invalid for argument "value"');for(i=0;i<r-t;++i)this[i+t]=a[i%s]}return this};var k=/[^+/0-9A-Za-z-_]/g;function T(e,t){var r;t=t||1/0;for(var n=e.length,o=null,i=[],a=0;a<n;++a){if(55295<(r=e.charCodeAt(a))&&r<57344){if(!o){if(56319<r){-1<(t-=3)&&i.push(239,191,189);continue}if(a+1===n){-1<(t-=3)&&i.push(239,191,189);continue}o=r;continue}if(r<56320){-1<(t-=3)&&i.push(239,191,189),o=r;continue}r=65536+(o-55296<<10|r-56320)}else o&&-1<(t-=3)&&i.push(239,191,189);if(o=null,r<128){if(--t<0)break;i.push(r)}else if(r<2048){if((t-=2)<0)break;i.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;i.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return i}function x(e){return s.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(k,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function O(e,t,r,n){for(var o=0;o<n&&!(o+r>=t.length||o>=e.length);++o)t[o+r]=e[o];return o}function j(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function P(e){return e!=e}}).call(this)}).call(this,R("buffer").Buffer)},{"base64-js":11,buffer:13,ieee754:26}],14:[function(e,t,r){"use strict";var n=e("get-intrinsic"),o=e("./"),i=o(n("String.prototype.indexOf"));t.exports=function(e,t){t=n(e,!!t);return"function"==typeof t&&-1<i(e,".prototype.")?o(t):t}},{"./":15,"get-intrinsic":22}],15:[function(e,t,r){"use strict";var n=e("function-bind"),e=e("get-intrinsic"),o=e("%Function.prototype.apply%"),i=e("%Function.prototype.call%"),a=e("%Reflect.apply%",!0)||n.call(i,o),s=e("%Object.getOwnPropertyDescriptor%",!0),u=e("%Object.defineProperty%",!0),c=e("%Math.max%");if(u)try{u({},"a",{value:1})}catch(e){u=null}t.exports=function(e){var t=a(n,i,arguments);return s&&u&&s(t,"length").configurable&&u(t,"length",{value:1+c(0,e.length-(arguments.length-1))}),t};e=function(){return a(n,o,arguments)};u?u(t.exports,"apply",{value:e}):t.exports.apply=e},{"function-bind":21,"get-intrinsic":22}],16:[function(e,t,r){"use strict";function n(e){try{return Function('"use strict"; return ('+e+").constructor;")()}catch(e){}}var h=SyntaxError,o=Function,d=TypeError,y=Object.getOwnPropertyDescriptor;if(y)try{y({},"")}catch(e){y=null}function i(){throw new d}var a=y?function(){try{return i}catch(e){try{return y(arguments,"callee").get}catch(e){return i}}}():i,s=e("has-symbols")(),u=Object.getPrototypeOf||function(e){return e.__proto__},c=n("async function* () {}"),f=c?c.prototype:v,p=f?f.prototype:v,l="undefined"==typeof Uint8Array?v:u(Uint8Array),g={"%AggregateError%":"undefined"==typeof AggregateError?v:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?v:ArrayBuffer,"%ArrayIteratorPrototype%":s?u([][Symbol.iterator]()):v,"%AsyncFromSyncIteratorPrototype%":v,"%AsyncFunction%":n("async function () {}"),"%AsyncGenerator%":f,"%AsyncGeneratorFunction%":c,"%AsyncIteratorPrototype%":p?u(p):v,"%Atomics%":"undefined"==typeof Atomics?v:Atomics,"%BigInt%":"undefined"==typeof BigInt?v:BigInt,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?v:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?v:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?v:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?v:FinalizationRegistry,"%Function%":o,"%GeneratorFunction%":n("function* () {}"),"%Int8Array%":"undefined"==typeof Int8Array?v:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?v:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?v:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":s?u(u([][Symbol.iterator]())):v,"%JSON%":"object"==typeof JSON?JSON:v,"%Map%":"undefined"==typeof Map?v:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&s?u((new Map)[Symbol.iterator]()):v,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?v:Promise,"%Proxy%":"undefined"==typeof Proxy?v:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?v:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?v:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&s?u((new Set)[Symbol.iterator]()):v,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?v:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":s?u(""[Symbol.iterator]()):v,"%Symbol%":s?Symbol:v,"%SyntaxError%":h,"%ThrowTypeError%":a,"%TypedArray%":l,"%TypeError%":d,"%Uint8Array%":"undefined"==typeof Uint8Array?v:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?v:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?v:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?v:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?v:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?v:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?v:WeakSet},m={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},v=e("function-bind"),b=e("has"),_=v.call(Function.call,Array.prototype.concat),w=v.call(Function.apply,Array.prototype.splice),S=v.call(Function.call,String.prototype.replace),E=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,A=/\\(\\)?/g;t.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new d("intrinsic name must be a non-empty string");if(1<arguments.length&&"boolean"!=typeof t)throw new d('"allowMissing" argument must be a boolean');var o,r=(o=[],S(e,E,function(e,t,r,n){o[o.length]=r?S(n,A,"$1"):t||e}),o),n=0<r.length?r[0]:"",i=function(e,t){var r,n=e;if(b(m,n)&&(n="%"+(r=m[n])[0]+"%"),b(g,n)){var o=g[n];if(void 0===o&&!t)throw new d("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:o}}throw new h("intrinsic "+e+" does not exist!")}("%"+n+"%",t),a=i.name,s=i.value,u=!1,i=i.alias;i&&(n=i[0],w(r,_([0,1],i)));for(var c=1,f=!0;c<r.length;c+=1){var p=r[c];if("constructor"!==p&&f||(u=!0),b(g,a="%"+(n+="."+p)+"%"))s=g[a];else if(null!=s){if(y&&c+1>=r.length){var l=y(s,p),f=!!l;if(!(t||p in s))throw new d("base intrinsic for "+e+" exists, but the property is not available.");s=f&&"get"in l&&!("originalValue"in l.get)?l.get:s[p]}else f=b(s,p),s=s[p];f&&!u&&(g[a]=s)}}return s}},{"function-bind":21,has:25,"has-symbols":23}],17:[function(e,t,r){"use strict";var n=e("../GetIntrinsic")("%Object.getOwnPropertyDescriptor%");if(n)try{n([],"length")}catch(e){n=null}t.exports=n},{"../GetIntrinsic":16}],18:[function(e,t,r){"use strict";var n,o="object"==typeof Reflect?Reflect:null,u=o&&"function"==typeof o.apply?o.apply:function(e,t,r){return Function.prototype.apply.call(e,t,r)};n=o&&"function"==typeof o.ownKeys?o.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var i=Number.isNaN||function(e){return e!=e};function a(){a.init.call(this)}t.exports=a,t.exports.once=function(o,i){return new Promise(function(e,t){function r(){void 0!==n&&o.removeListener("error",n),e([].slice.call(arguments))}var n;"error"!==i&&(n=function(e){o.removeListener(i,r),t(e)},o.once("error",n)),o.once(i,r)})},(a.EventEmitter=a).prototype._events=void 0,a.prototype._eventsCount=0,a.prototype._maxListeners=void 0;var s=10;function c(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function f(e){return void 0===e._maxListeners?a.defaultMaxListeners:e._maxListeners}function p(e,t,r,n){var o,i;return c(r),void 0===(o=e._events)?(o=e._events=Object.create(null),e._eventsCount=0):(void 0!==o.newListener&&(e.emit("newListener",t,r.listener||r),o=e._events),i=o[t]),void 0===i?(i=o[t]=r,++e._eventsCount):("function"==typeof i?i=o[t]=n?[r,i]:[i,r]:n?i.unshift(r):i.push(r),0<(r=f(e))&&i.length>r&&!i.warned&&(i.warned=!0,(r=new Error("Possible EventEmitter memory leak detected. "+i.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit")).name="MaxListenersExceededWarning",r.emitter=e,r.type=t,r.count=i.length,r=r,console&&console.warn&&console.warn(r))),e}function l(e,t,r){e={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},t=function(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}.bind(e);return t.listener=r,e.wrapFn=t}function h(e,t,r){e=e._events;if(void 0===e)return[];t=e[t];return void 0===t?[]:"function"==typeof t?r?[t.listener||t]:[t]:r?function(e){for(var t=new Array(e.length),r=0;r<t.length;++r)t[r]=e[r].listener||e[r];return t}(t):y(t,t.length)}function d(e){var t=this._events;if(void 0!==t){e=t[e];if("function"==typeof e)return 1;if(void 0!==e)return e.length}return 0}function y(e,t){for(var r=new Array(t),n=0;n<t;++n)r[n]=e[n];return r}Object.defineProperty(a,"defaultMaxListeners",{enumerable:!0,get:function(){return s},set:function(e){if("number"!=typeof e||e<0||i(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");s=e}}),a.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},a.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||i(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},a.prototype.getMaxListeners=function(){return f(this)},a.prototype.emit=function(e){for(var t=[],r=1;r<arguments.length;r++)t.push(arguments[r]);var n,o="error"===e,i=this._events;if(void 0!==i)o=o&&void 0===i.error;else if(!o)return!1;if(o){if(0<t.length&&(n=t[0]),n instanceof Error)throw n;o=new Error("Unhandled error."+(n?" ("+n.message+")":""));throw o.context=n,o}e=i[e];if(void 0===e)return!1;if("function"==typeof e)u(e,this,t);else for(var a=e.length,s=y(e,a),r=0;r<a;++r)u(s[r],this,t);return!0},a.prototype.addListener=function(e,t){return p(this,e,t,!1)},a.prototype.on=a.prototype.addListener,a.prototype.prependListener=function(e,t){return p(this,e,t,!0)},a.prototype.once=function(e,t){return c(t),this.on(e,l(this,e,t)),this},a.prototype.prependOnceListener=function(e,t){return c(t),this.prependListener(e,l(this,e,t)),this},a.prototype.removeListener=function(e,t){var r,n,o,i,a;if(c(t),void 0===(n=this._events))return this;if(void 0===(r=n[e]))return this;if(r===t||r.listener===t)0==--this._eventsCount?this._events=Object.create(null):(delete n[e],n.removeListener&&this.emit("removeListener",e,r.listener||t));else if("function"!=typeof r){for(o=-1,i=r.length-1;0<=i;i--)if(r[i]===t||r[i].listener===t){a=r[i].listener,o=i;break}if(o<0)return this;0===o?r.shift():function(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}(r,o),1===r.length&&(n[e]=r[0]),void 0!==n.removeListener&&this.emit("removeListener",e,a||t)}return this},a.prototype.off=a.prototype.removeListener,a.prototype.removeAllListeners=function(e){var t,r=this._events;if(void 0===r)return this;if(void 0===r.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==r[e]&&(0==--this._eventsCount?this._events=Object.create(null):delete r[e]),this;if(0===arguments.length){for(var n,o=Object.keys(r),i=0;i<o.length;++i)"removeListener"!==(n=o[i])&&this.removeAllListeners(n);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(t=r[e]))this.removeListener(e,t);else if(void 0!==t)for(i=t.length-1;0<=i;i--)this.removeListener(e,t[i]);return this},a.prototype.listeners=function(e){return h(this,e,!0)},a.prototype.rawListeners=function(e){return h(this,e,!1)},a.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):d.call(e,t)},a.prototype.listenerCount=d,a.prototype.eventNames=function(){return 0<this._eventsCount?n(this._events):[]}},{}],19:[function(e,t,r){var a=Object.prototype.hasOwnProperty,s=Object.prototype.toString;t.exports=function(e,t,r){if("[object Function]"!==s.call(t))throw new TypeError("iterator must be a function");var n=e.length;if(n===+n)for(var o=0;o<n;o++)t.call(r,e[o],o,e);else for(var i in e)a.call(e,i)&&t.call(r,e[i],i,e)}},{}],20:[function(e,t,r){"use strict";var u=Array.prototype.slice,c=Object.prototype.toString;t.exports=function(t){var r=this;if("function"!=typeof r||"[object Function]"!==c.call(r))throw new TypeError("Function.prototype.bind called on incompatible "+r);for(var n,e,o=u.call(arguments,1),i=Math.max(0,r.length-o.length),a=[],s=0;s<i;s++)a.push("$"+s);return n=Function("binder","return function ("+a.join(",")+"){ return binder.apply(this,arguments); }")(function(){if(this instanceof n){var e=r.apply(this,o.concat(u.call(arguments)));return Object(e)===e?e:this}return r.apply(t,o.concat(u.call(arguments)))}),r.prototype&&((e=function(){}).prototype=r.prototype,n.prototype=new e,e.prototype=null),n}},{}],21:[function(e,t,r){"use strict";e=e("./implementation");t.exports=Function.prototype.bind||e},{"./implementation":20}],22:[function(e,t,r){"use strict";function n(e){try{return Function('"use strict"; return ('+e+").constructor;")()}catch(e){}}var h=SyntaxError,o=Function,d=TypeError,y=Object.getOwnPropertyDescriptor;if(y)try{y({},"")}catch(e){y=null}function i(){throw new d}var a=y?function(){try{return i}catch(e){try{return y(arguments,"callee").get}catch(e){return i}}}():i,s=e("has-symbols")(),u=Object.getPrototypeOf||function(e){return e.__proto__},c=n("async function* () {}"),f=c?c.prototype:v,p=f?f.prototype:v,l="undefined"==typeof Uint8Array?v:u(Uint8Array),g={"%AggregateError%":"undefined"==typeof AggregateError?v:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?v:ArrayBuffer,"%ArrayIteratorPrototype%":s?u([][Symbol.iterator]()):v,"%AsyncFromSyncIteratorPrototype%":v,"%AsyncFunction%":n("async function () {}"),"%AsyncGenerator%":f,"%AsyncGeneratorFunction%":c,"%AsyncIteratorPrototype%":p?u(p):v,"%Atomics%":"undefined"==typeof Atomics?v:Atomics,"%BigInt%":"undefined"==typeof BigInt?v:BigInt,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?v:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?v:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?v:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?v:FinalizationRegistry,"%Function%":o,"%GeneratorFunction%":n("function* () {}"),"%Int8Array%":"undefined"==typeof Int8Array?v:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?v:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?v:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":s?u(u([][Symbol.iterator]())):v,"%JSON%":"object"==typeof JSON?JSON:v,"%Map%":"undefined"==typeof Map?v:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&s?u((new Map)[Symbol.iterator]()):v,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?v:Promise,"%Proxy%":"undefined"==typeof Proxy?v:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?v:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?v:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&s?u((new Set)[Symbol.iterator]()):v,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?v:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":s?u(""[Symbol.iterator]()):v,"%Symbol%":s?Symbol:v,"%SyntaxError%":h,"%ThrowTypeError%":a,"%TypedArray%":l,"%TypeError%":d,"%Uint8Array%":"undefined"==typeof Uint8Array?v:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?v:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?v:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?v:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?v:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?v:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?v:WeakSet},m={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},v=e("function-bind"),b=e("has"),_=v.call(Function.call,Array.prototype.concat),w=v.call(Function.apply,Array.prototype.splice),S=v.call(Function.call,String.prototype.replace),E=v.call(Function.call,String.prototype.slice),A=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,k=/\\(\\)?/g;t.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new d("intrinsic name must be a non-empty string");if(1<arguments.length&&"boolean"!=typeof t)throw new d('"allowMissing" argument must be a boolean');var r=function(e){var t=E(e,0,1),r=E(e,-1);if("%"===t&&"%"!==r)throw new h("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==t)throw new h("invalid intrinsic syntax, expected opening `%`");var o=[];return S(e,A,function(e,t,r,n){o[o.length]=r?S(n,k,"$1"):t||e}),o}(e),n=0<r.length?r[0]:"",o=function(e,t){var r,n=e;if(b(m,n)&&(n="%"+(r=m[n])[0]+"%"),b(g,n)){var o=g[n];if(void 0===o&&!t)throw new d("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:o}}throw new h("intrinsic "+e+" does not exist!")}("%"+n+"%",t),i=o.name,a=o.value,s=!1,o=o.alias;o&&(n=o[0],w(r,_([0,1],o)));for(var u=1,c=!0;u<r.length;u+=1){var f=r[u],p=E(f,0,1),l=E(f,-1);if(('"'===p||"'"===p||"`"===p||'"'===l||"'"===l||"`"===l)&&p!==l)throw new h("property names with quotes must have matching quotes");if("constructor"!==f&&c||(s=!0),b(g,i="%"+(n+="."+f)+"%"))a=g[i];else if(null!=a){if(!(f in a)){if(!t)throw new d("base intrinsic for "+e+" exists, but the property is not available.");return}a=y&&u+1>=r.length?(c=!!(l=y(a,f)))&&"get"in l&&!("originalValue"in l.get)?l.get:a[f]:(c=b(a,f),a[f]),c&&!s&&(g[i]=a)}}return a}},{"function-bind":21,has:25,"has-symbols":23}],23:[function(n,o,e){(function(r){(function(){"use strict";var e=r.Symbol,t=n("./shams");o.exports=function(){return"function"==typeof e&&("function"==typeof Symbol&&("symbol"==typeof e("foo")&&("symbol"==typeof Symbol("bar")&&t())))}}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./shams":24}],24:[function(e,t,r){"use strict";t.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var e={},t=Symbol("test"),r=Object(t);if("string"==typeof t)return!1;if("[object Symbol]"!==Object.prototype.toString.call(t))return!1;if("[object Symbol]"!==Object.prototype.toString.call(r))return!1;for(t in e[t]=42,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;r=Object.getOwnPropertySymbols(e);if(1!==r.length||r[0]!==t)return!1;if(!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){e=Object.getOwnPropertyDescriptor(e,t);if(42!==e.value||!0!==e.enumerable)return!1}return!0}},{}],25:[function(e,t,r){"use strict";e=e("function-bind");t.exports=e.call(Function.call,Object.prototype.hasOwnProperty)},{"function-bind":21}],26:[function(e,t,r){r.read=function(e,t,r,n,o){var i,a,s=8*o-n-1,u=(1<<s)-1,c=u>>1,f=-7,p=r?o-1:0,l=r?-1:1,r=e[t+p];for(p+=l,i=r&(1<<-f)-1,r>>=-f,f+=s;0<f;i=256*i+e[t+p],p+=l,f-=8);for(a=i&(1<<-f)-1,i>>=-f,f+=n;0<f;a=256*a+e[t+p],p+=l,f-=8);if(0===i)i=1-c;else{if(i===u)return a?NaN:1/0*(r?-1:1);a+=Math.pow(2,n),i-=c}return(r?-1:1)*a*Math.pow(2,i-n)},r.write=function(e,t,r,n,o,i){var a,s,u=8*i-o-1,c=(1<<u)-1,f=c>>1,p=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,l=n?0:i-1,h=n?1:-1,i=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=c):(a=Math.floor(Math.log(t)/Math.LN2),t*(n=Math.pow(2,-a))<1&&(a--,n*=2),2<=(t+=1<=a+f?p/n:p*Math.pow(2,1-f))*n&&(a++,n/=2),c<=a+f?(s=0,a=c):1<=a+f?(s=(t*n-1)*Math.pow(2,o),a+=f):(s=t*Math.pow(2,f-1)*Math.pow(2,o),a=0));8<=o;e[r+l]=255&s,l+=h,s/=256,o-=8);for(a=a<<o|s,u+=o;0<u;e[r+l]=255&a,l+=h,a/=256,u-=8);e[r+l-h]|=128*i}},{}],27:[function(e,t,r){"function"==typeof Object.create?t.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:t.exports=function(e,t){var r;t&&(e.super_=t,(r=function(){}).prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e)}},{}],28:[function(e,t,r){"use strict";function n(e){return!(i&&e&&"object"==typeof e&&Symbol.toStringTag in e)&&"[object Arguments]"===a(e)}function o(e){return!!n(e)||null!==e&&"object"==typeof e&&"number"==typeof e.length&&0<=e.length&&"[object Array]"!==a(e)&&"[object Function]"===a(e.callee)}var i="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,a=e("call-bind/callBound")("Object.prototype.toString"),e=function(){return n(arguments)}();n.isLegacyArguments=o,t.exports=e?n:o},{"call-bind/callBound":14}],29:[function(e,t,r){"use strict";var n=Object.prototype.toString,o=Function.prototype.toString,i=/^\s*(?:function)?\*/,a="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,s=Object.getPrototypeOf,u=function(){if(!a)return!1;try{return Function("return function*() {}")()}catch(e){}}(),c=!(!s||!u)&&s(u);t.exports=function(e){return"function"==typeof e&&(!!i.test(o.call(e))||(a?s&&s(e)===c:"[object GeneratorFunction]"===n.call(e)))}},{}],30:[function(l,h,e){(function(p){(function(){"use strict";var t=l("foreach"),e=l("available-typed-arrays"),r=l("call-bind/callBound"),o=r("Object.prototype.toString"),i=l("has-symbols")()&&"symbol"==typeof Symbol.toStringTag,a=e(),s=r("Array.prototype.indexOf",!0)||function(e,t){for(var r=0;r<e.length;r+=1)if(e[r]===t)return r;return-1},u=r("String.prototype.slice"),c={},f=l("es-abstract/helpers/getOwnPropertyDescriptor"),n=Object.getPrototypeOf;i&&f&&n&&t(a,function(e){var t=new p[e];if(!(Symbol.toStringTag in t))throw new EvalError("this engine has support for Symbol.toStringTag, but "+e+" does not have the property! Please report this.");var r=n(t),t=f(r,Symbol.toStringTag);t||(r=n(r),t=f(r,Symbol.toStringTag)),c[e]=t.get});h.exports=function(e){if(!e||"object"!=typeof e)return!1;if(i)return!!f&&(r=e,n=!1,t(c,function(e,t){if(!n)try{n=e.call(r)===t}catch(e){}}),n);var r,n,e=u(o(e),8,-1);return-1<s(a,e)}}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"available-typed-arrays":10,"call-bind/callBound":14,"es-abstract/helpers/getOwnPropertyDescriptor":17,foreach:19,"has-symbols":23}],31:[function(e,t,r){(function(a){(function(){"use strict";function l(e){if("string"!=typeof e)throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}function i(e,t){for(var r,n="",o=0,i=-1,a=0,s=0;s<=e.length;++s){if(s<e.length)r=e.charCodeAt(s);else{if(47===r)break;r=47}if(47===r){if(i!==s-1&&1!==a)if(i!==s-1&&2===a){if(n.length<2||2!==o||46!==n.charCodeAt(n.length-1)||46!==n.charCodeAt(n.length-2))if(2<n.length){var u=n.lastIndexOf("/");if(u!==n.length-1){o=-1===u?(n="",0):(n=n.slice(0,u)).length-1-n.lastIndexOf("/"),i=s,a=0;continue}}else if(2===n.length||1===n.length){n="",i=s,a=o=0;continue}t&&(0<n.length?n+="/..":n="..",o=2)}else 0<n.length?n+="/"+e.slice(i+1,s):n=e.slice(i+1,s),o=s-i-1;i=s,a=0}else 46===r&&-1!==a?++a:a=-1}return n}var h={resolve:function(){for(var e,t="",r=!1,n=arguments.length-1;-1<=n&&!r;n--){var o=0<=n?arguments[n]:(void 0===e&&(e=a.cwd()),e);l(o),0!==o.length&&(t=o+"/"+t,r=47===o.charCodeAt(0))}return t=i(t,!r),r?0<t.length?"/"+t:"/":0<t.length?t:"."},normalize:function(e){if(l(e),0===e.length)return".";var t=47===e.charCodeAt(0),r=47===e.charCodeAt(e.length-1);return 0!==(e=i(e,!t)).length||t||(e="."),0<e.length&&r&&(e+="/"),t?"/"+e:e},isAbsolute:function(e){return l(e),0<e.length&&47===e.charCodeAt(0)},join:function(){if(0===arguments.length)return".";for(var e,t=0;t<arguments.length;++t){var r=arguments[t];l(r),0<r.length&&(void 0===e?e=r:e+="/"+r)}return void 0===e?".":h.normalize(e)},relative:function(e,t){if(l(e),l(t),e===t)return"";if((e=h.resolve(e))===(t=h.resolve(t)))return"";for(var r=1;r<e.length&&47===e.charCodeAt(r);++r);for(var n=e.length,o=n-r,i=1;i<t.length&&47===t.charCodeAt(i);++i);for(var a=t.length-i,s=o<a?o:a,u=-1,c=0;c<=s;++c){if(c===s){if(s<a){if(47===t.charCodeAt(i+c))return t.slice(i+c+1);if(0===c)return t.slice(i+c)}else s<o&&(47===e.charCodeAt(r+c)?u=c:0===c&&(u=0));break}var f=e.charCodeAt(r+c);if(f!==t.charCodeAt(i+c))break;47===f&&(u=c)}for(var p="",c=r+u+1;c<=n;++c)c!==n&&47!==e.charCodeAt(c)||(0===p.length?p+="..":p+="/..");return 0<p.length?p+t.slice(i+u):(i+=u,47===t.charCodeAt(i)&&++i,t.slice(i))},_makeLong:function(e){return e},dirname:function(e){if(l(e),0===e.length)return".";for(var t=e.charCodeAt(0),r=47===t,n=-1,o=!0,i=e.length-1;1<=i;--i)if(47===e.charCodeAt(i)){if(!o){n=i;break}}else o=!1;return-1===n?r?"/":".":r&&1===n?"//":e.slice(0,n)},basename:function(e,t){if(void 0!==t&&"string"!=typeof t)throw new TypeError('"ext" argument must be a string');l(e);var r=0,n=-1,o=!0;if(void 0!==t&&0<t.length&&t.length<=e.length){if(t.length===e.length&&t===e)return"";for(var i=t.length-1,a=-1,s=e.length-1;0<=s;--s){var u=e.charCodeAt(s);if(47===u){if(!o){r=s+1;break}}else-1===a&&(o=!1,a=s+1),0<=i&&(u===t.charCodeAt(i)?-1==--i&&(n=s):(i=-1,n=a))}return r===n?n=a:-1===n&&(n=e.length),e.slice(r,n)}for(s=e.length-1;0<=s;--s)if(47===e.charCodeAt(s)){if(!o){r=s+1;break}}else-1===n&&(o=!1,n=s+1);return-1===n?"":e.slice(r,n)},extname:function(e){l(e);for(var t=-1,r=0,n=-1,o=!0,i=0,a=e.length-1;0<=a;--a){var s=e.charCodeAt(a);if(47===s){if(o)continue;r=a+1;break}-1===n&&(o=!1,n=a+1),46===s?-1===t?t=a:1!==i&&(i=1):-1!==t&&(i=-1)}return-1===t||-1===n||0===i||1===i&&t===n-1&&t===r+1?"":e.slice(t,n)},format:function(e){if(null===e||"object"!=typeof e)throw new TypeError('The "pathObject" argument must be of type Object. Received type '+typeof e);return t="/",n=(r=e).dir||r.root,e=r.base||(r.name||"")+(r.ext||""),n?n===r.root?n+e:n+t+e:e;var t,r,n},parse:function(e){l(e);var t={root:"",dir:"",base:"",ext:"",name:""};if(0===e.length)return t;for(var r=e.charCodeAt(0),n=47===r,o=n?(t.root="/",1):0,i=-1,a=0,s=-1,u=!0,c=e.length-1,f=0;o<=c;--c){if(47===(r=e.charCodeAt(c))){if(u)continue;a=c+1;break}-1===s&&(u=!1,s=c+1),46===r?-1===i?i=c:1!==f&&(f=1):-1!==i&&(f=-1)}return-1===i||-1===s||0===f||1===f&&i===s-1&&i===a+1?-1!==s&&(t.base=t.name=0===a&&n?e.slice(1,s):e.slice(a,s)):(0===a&&n?(t.name=e.slice(1,i),t.base=e.slice(1,s)):(t.name=e.slice(a,i),t.base=e.slice(a,s)),t.ext=e.slice(i,s)),0<a?t.dir=e.slice(0,a-1):n&&(t.dir="/"),t},sep:"/",delimiter:":",win32:null,posix:null};h.posix=h,t.exports=h}).call(this)}).call(this,e("_process"))},{_process:32}],32:[function(e,t,r){var n,o,t=t.exports={};function i(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function s(t){if(n===setTimeout)return setTimeout(t,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(e){n=i}try{o="function"==typeof clearTimeout?clearTimeout:a}catch(e){o=a}}();var u,c=[],f=!1,p=-1;function l(){f&&u&&(f=!1,u.length?c=u.concat(c):p=-1,c.length&&h())}function h(){if(!f){var e=s(l);f=!0;for(var t=c.length;t;){for(u=c,c=[];++p<t;)u&&u[p].run();p=-1,t=c.length}u=null,f=!1,function(t){if(o===clearTimeout)return clearTimeout(t);if((o===a||!o)&&clearTimeout)return o=clearTimeout,clearTimeout(t);try{o(t)}catch(e){try{return o.call(null,t)}catch(e){return o.call(this,t)}}}(e)}}function d(e,t){this.fun=e,this.array=t}function y(){}t.nextTick=function(e){var t=new Array(arguments.length-1);if(1<arguments.length)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];c.push(new d(e,t)),1!==c.length||f||s(h)},d.prototype.run=function(){this.fun.apply(null,this.array)},t.title="browser",t.browser=!0,t.env={},t.argv=[],t.version="",t.versions={},t.on=y,t.addListener=y,t.once=y,t.off=y,t.removeListener=y,t.removeAllListeners=y,t.emit=y,t.prependListener=y,t.prependOnceListener=y,t.listeners=function(e){return[]},t.binding=function(e){throw new Error("process.binding is not supported")},t.cwd=function(){return"/"},t.chdir=function(e){throw new Error("process.chdir is not supported")},t.umask=function(){return 0}},{}],33:[function(e,t,r){var n=e("buffer"),o=n.Buffer;function i(e,t){for(var r in e)t[r]=e[r]}function a(e,t,r){return o(e,t,r)}o.from&&o.alloc&&o.allocUnsafe&&o.allocUnsafeSlow?t.exports=n:(i(n,r),r.Buffer=a),a.prototype=Object.create(o.prototype),i(o,a),a.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return o(e,t,r)},a.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");e=o(e);return void 0!==t?"string"==typeof r?e.fill(t,r):e.fill(t):e.fill(0),e},a.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return o(e)},a.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n.SlowBuffer(e)}},{buffer:13}],34:[function(e,t,r){t.exports=n;var f=e("events").EventEmitter;function n(){f.call(this)}e("inherits")(n,f),n.Readable=e("readable-stream/lib/_stream_readable.js"),n.Writable=e("readable-stream/lib/_stream_writable.js"),n.Duplex=e("readable-stream/lib/_stream_duplex.js"),n.Transform=e("readable-stream/lib/_stream_transform.js"),n.PassThrough=e("readable-stream/lib/_stream_passthrough.js"),n.finished=e("readable-stream/lib/internal/streams/end-of-stream.js"),n.pipeline=e("readable-stream/lib/internal/streams/pipeline.js"),(n.Stream=n).prototype.pipe=function(t,e){var r=this;function n(e){t.writable&&!1===t.write(e)&&r.pause&&r.pause()}function o(){r.readable&&r.resume&&r.resume()}r.on("data",n),t.on("drain",o),t._isStdio||e&&!1===e.end||(r.on("end",a),r.on("close",s));var i=!1;function a(){i||(i=!0,t.end())}function s(){i||(i=!0,"function"==typeof t.destroy&&t.destroy())}function u(e){if(c(),0===f.listenerCount(this,"error"))throw e}function c(){r.removeListener("data",n),t.removeListener("drain",o),r.removeListener("end",a),r.removeListener("close",s),r.removeListener("error",u),t.removeListener("error",u),r.removeListener("end",c),r.removeListener("close",c),t.removeListener("close",c)}return r.on("error",u),t.on("error",u),r.on("end",c),r.on("close",c),t.on("close",c),t.emit("pipe",r),t}},{events:18,inherits:27,"readable-stream/lib/_stream_duplex.js":36,"readable-stream/lib/_stream_passthrough.js":37,"readable-stream/lib/_stream_readable.js":38,"readable-stream/lib/_stream_transform.js":39,"readable-stream/lib/_stream_writable.js":40,"readable-stream/lib/internal/streams/end-of-stream.js":44,"readable-stream/lib/internal/streams/pipeline.js":46}],35:[function(e,t,r){"use strict";var n={};function o(e,o,t){var r=function(n){var e,t;function r(e,t,r){return n.call(this,(e=e,t=t,r=r,"string"==typeof o?o:o(e,t,r)))||this}return t=n,(e=r).prototype=Object.create(t.prototype),(e.prototype.constructor=e).__proto__=t,r}(t=t||Error);r.prototype.name=t.name,r.prototype.code=e,n[e]=r}function u(e,t){if(Array.isArray(e)){var r=e.length;return e=e.map(function(e){return String(e)}),2<r?"one of ".concat(t," ").concat(e.slice(0,r-1).join(", "),", or ")+e[r-1]:2===r?"one of ".concat(t," ").concat(e[0]," or ").concat(e[1]):"of ".concat(t," ").concat(e[0])}return"of ".concat(t," ").concat(String(e))}o("ERR_INVALID_OPT_VALUE",function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'},TypeError),o("ERR_INVALID_ARG_TYPE",function(e,t,r){var n,o,i,a,s;return"string"==typeof t&&(a="not ",t.substr(!i||i<0?0:+i,a.length)===a)?(n="must not be",t=t.replace(/^not /,"")):n="must be",i=e,a=" argument",(void 0===s||s>i.length)&&(s=i.length),t=i.substring(s-a.length,s)===a?"The ".concat(e," ").concat(n," ").concat(u(t,"type")):("number"!=typeof o&&(o=0),o=(o+(s=".").length>(a=e).length?void 0:-1!==a.indexOf(s,o))?"property":"argument",'The "'.concat(e,'" ').concat(o," ").concat(n," ").concat(u(t,"type"))),t+=". Received type ".concat(typeof r)},TypeError),o("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),o("ERR_METHOD_NOT_IMPLEMENTED",function(e){return"The "+e+" method is not implemented"}),o("ERR_STREAM_PREMATURE_CLOSE","Premature close"),o("ERR_STREAM_DESTROYED",function(e){return"Cannot call "+e+" after a stream was destroyed"}),o("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),o("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),o("ERR_STREAM_WRITE_AFTER_END","write after end"),o("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),o("ERR_UNKNOWN_ENCODING",function(e){return"Unknown encoding: "+e},TypeError),o("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),t.exports.codes=n},{}],36:[function(f,p,e){(function(c){(function(){"use strict";var e=Object.keys||function(e){var t,r=[];for(t in e)r.push(t);return r};p.exports=a;var t=f("./_stream_readable"),r=f("./_stream_writable");f("inherits")(a,t);for(var n=e(r.prototype),o=0;o<n.length;o++){var i=n[o];a.prototype[i]||(a.prototype[i]=r.prototype[i])}function a(e){if(!(this instanceof a))return new a(e);t.call(this,e),r.call(this,e),this.allowHalfOpen=!0,e&&(!1===e.readable&&(this.readable=!1),!1===e.writable&&(this.writable=!1),!1===e.allowHalfOpen&&(this.allowHalfOpen=!1,this.once("end",s)))}function s(){this._writableState.ended||c.nextTick(u,this)}function u(e){e.end()}Object.defineProperty(a.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(a.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(a.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(a.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}})}).call(this)}).call(this,f("_process"))},{"./_stream_readable":38,"./_stream_writable":40,_process:32,inherits:27}],37:[function(e,t,r){"use strict";t.exports=o;var n=e("./_stream_transform");function o(e){if(!(this instanceof o))return new o(e);n.call(this,e)}e("inherits")(o,n),o.prototype._transform=function(e,t,r){r(null,e)}},{"./_stream_transform":39,inherits:27}],38:[function(U,D,e){(function(M,F){(function(){"use strict";var n;(D.exports=_).ReadableState=b;function g(e,t){return e.listeners(t).length}U("events").EventEmitter;var o=U("./internal/streams/stream"),f=U("buffer").Buffer,p=F.Uint8Array||function(){};var i,e,r,t=U("util"),m=t&&t.debuglog?t.debuglog("stream"):function(){},a=U("./internal/streams/buffer_list"),s=U("./internal/streams/destroy"),u=U("./internal/streams/state").getHighWaterMark,t=U("../errors").codes,l=t.ERR_INVALID_ARG_TYPE,h=t.ERR_STREAM_PUSH_AFTER_EOF,c=t.ERR_METHOD_NOT_IMPLEMENTED,d=t.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;U("inherits")(_,o);var v=s.errorOrDestroy,y=["error","close","destroy","pause","resume"];function b(e,t,r){n=n||U("./_stream_duplex"),e=e||{},"boolean"!=typeof r&&(r=t instanceof n),this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=u(this,e,"readableHighWaterMark",r),this.buffer=new a,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(i=i||U("string_decoder/").StringDecoder,this.decoder=new i(e.encoding),this.encoding=e.encoding)}function _(e){if(n=n||U("./_stream_duplex"),!(this instanceof _))return new _(e);var t=this instanceof n;this._readableState=new b(e,this,t),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),o.call(this)}function w(e,t,r,n,o){m("readableAddChunk",t);var i,a,s,u,c=e._readableState;if(null===t)c.reading=!1,a=e,s=c,m("onEofChunk"),s.ended||(!s.decoder||(u=s.decoder.end())&&u.length&&(s.buffer.push(u),s.length+=s.objectMode?1:u.length),s.ended=!0,s.sync?k(a):(s.needReadable=!1,s.emittedReadable||(s.emittedReadable=!0,T(a))));else if(o||(i=function(e,t){var r;(function(e){return f.isBuffer(e)||e instanceof p})(t)||"string"==typeof t||void 0===t||e.objectMode||(r=new l("chunk",["string","Buffer","Uint8Array"],t));return r}(c,t)),i)v(e,i);else if(c.objectMode||t&&0<t.length)if("string"==typeof t||c.objectMode||Object.getPrototypeOf(t)===f.prototype||(i=t,t=f.from(i)),n)c.endEmitted?v(e,new d):S(e,c,t,!0);else if(c.ended)v(e,new h);else{if(c.destroyed)return!1;c.reading=!1,c.decoder&&!r?(t=c.decoder.write(t),c.objectMode||0!==t.length?S(e,c,t,!1):x(e,c)):S(e,c,t,!1)}else n||(c.reading=!1,x(e,c));return!c.ended&&(c.length<c.highWaterMark||0===c.length)}function S(e,t,r,n){t.flowing&&0===t.length&&!t.sync?(t.awaitDrain=0,e.emit("data",r)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&k(e)),x(e,t)}Object.defineProperty(_.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),_.prototype.destroy=s.destroy,_.prototype._undestroy=s.undestroy,_.prototype._destroy=function(e,t){t(e)},_.prototype.push=function(e,t){var r,n=this._readableState;return n.objectMode?r=!0:"string"==typeof e&&((t=t||n.defaultEncoding)!==n.encoding&&(e=f.from(e,t),t=""),r=!0),w(this,e,t,!1,r)},_.prototype.unshift=function(e){return w(this,e,null,!0,!1)},_.prototype.isPaused=function(){return!1===this._readableState.flowing},_.prototype.setEncoding=function(e){var t=new(i=i||U("string_decoder/").StringDecoder)(e);this._readableState.decoder=t,this._readableState.encoding=this._readableState.decoder.encoding;for(var r=this._readableState.buffer.head,n="";null!==r;)n+=t.write(r.data),r=r.next;return this._readableState.buffer.clear(),""!==n&&this._readableState.buffer.push(n),this._readableState.length=n.length,this};var E=1073741824;function A(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?(t.flowing&&t.length?t.buffer.head.data:t).length:(e>t.highWaterMark&&(t.highWaterMark=(E<=(r=e)?r=E:(r--,r|=r>>>1,r|=r>>>2,r|=r>>>4,r|=r>>>8,r|=r>>>16,r++),r)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0));var r}function k(e){var t=e._readableState;m("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(m("emitReadable",t.flowing),t.emittedReadable=!0,M.nextTick(T,e))}function T(e){var t=e._readableState;m("emitReadable_",t.destroyed,t.length,t.ended),t.destroyed||!t.length&&!t.ended||(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,B(e)}function x(e,t){t.readingMore||(t.readingMore=!0,M.nextTick(O,e,t))}function O(e,t){for(;!t.reading&&!t.ended&&(t.length<t.highWaterMark||t.flowing&&0===t.length);){var r=t.length;if(m("maybeReadMore read 0"),e.read(0),r===t.length)break}t.readingMore=!1}function j(e){var t=e._readableState;t.readableListening=0<e.listenerCount("readable"),t.resumeScheduled&&!t.paused?t.flowing=!0:0<e.listenerCount("data")&&e.resume()}function P(e){m("readable nexttick read 0"),e.read(0)}function R(e,t){m("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),B(e),t.flowing&&!t.reading&&e.read(0)}function B(e){var t=e._readableState;for(m("flow",t.flowing);t.flowing&&null!==e.read(););}function N(e,t){return 0===t.length?null:(t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r);var r}function I(e){var t=e._readableState;m("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,M.nextTick(C,t,e))}function C(e,t){m("endReadableNT",e.endEmitted,e.length),e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"),!e.autoDestroy||(!(e=t._writableState)||e.autoDestroy&&e.finished)&&t.destroy())}function L(e,t){for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}_.prototype.read=function(e){m("read",e),e=parseInt(e,10);var t=this._readableState,r=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&((0!==t.highWaterMark?t.length>=t.highWaterMark:0<t.length)||t.ended))return m("read: emitReadable",t.length,t.ended),(0===t.length&&t.ended?I:k)(this),null;if(0===(e=A(e,t))&&t.ended)return 0===t.length&&I(this),null;var n=t.needReadable;return m("need readable",n),(0===t.length||t.length-e<t.highWaterMark)&&m("length less than watermark",n=!0),t.ended||t.reading?m("reading or ended",n=!1):n&&(m("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=A(r,t))),null===(n=0<e?N(e,t):null)?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.awaitDrain=0),0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&I(this)),null!==n&&this.emit("data",n),n},_.prototype._read=function(e){v(this,new c("_read()"))},_.prototype.pipe=function(r,e){var n=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=r;break;case 1:o.pipes=[o.pipes,r];break;default:o.pipes.push(r)}o.pipesCount+=1,m("pipe count=%d opts=%j",o.pipesCount,e);var t=(!e||!1!==e.end)&&r!==M.stdout&&r!==M.stderr?a:y;function i(e,t){m("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,m("cleanup"),r.removeListener("close",h),r.removeListener("finish",d),r.removeListener("drain",u),r.removeListener("error",l),r.removeListener("unpipe",i),n.removeListener("end",a),n.removeListener("end",y),n.removeListener("data",p),f=!0,!o.awaitDrain||r._writableState&&!r._writableState.needDrain||u())}function a(){m("onend"),r.end()}o.endEmitted?M.nextTick(t):n.once("end",t),r.on("unpipe",i);var s,u=(s=n,function(){var e=s._readableState;m("pipeOnDrain",e.awaitDrain),e.awaitDrain&&e.awaitDrain--,0===e.awaitDrain&&g(s,"data")&&(e.flowing=!0,B(s))});r.on("drain",u);var c,f=!1;function p(e){m("ondata");e=r.write(e);m("dest.write",e),!1===e&&((1===o.pipesCount&&o.pipes===r||1<o.pipesCount&&-1!==L(o.pipes,r))&&!f&&(m("false write response, pause",o.awaitDrain),o.awaitDrain++),n.pause())}function l(e){m("onerror",e),y(),r.removeListener("error",l),0===g(r,"error")&&v(r,e)}function h(){r.removeListener("finish",d),y()}function d(){m("onfinish"),r.removeListener("close",h),y()}function y(){m("unpipe"),n.unpipe(r)}return n.on("data",p),c="error",e=l,"function"==typeof(t=r).prependListener?t.prependListener(c,e):t._events&&t._events[c]?Array.isArray(t._events[c])?t._events[c].unshift(e):t._events[c]=[e,t._events[c]]:t.on(c,e),r.once("close",h),r.once("finish",d),r.emit("pipe",n),o.flowing||(m("pipe resume"),n.resume()),r},_.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e=e||t.pipes,t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var n=t.pipes,o=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var i=0;i<o;i++)n[i].emit("unpipe",this,{hasUnpiped:!1});return this}var a=L(t.pipes,e);return-1===a||(t.pipes.splice(a,1),--t.pipesCount,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r)),this},_.prototype.addListener=_.prototype.on=function(e,t){var r=o.prototype.on.call(this,e,t),t=this._readableState;return"data"===e?(t.readableListening=0<this.listenerCount("readable"),!1!==t.flowing&&this.resume()):"readable"===e&&(t.endEmitted||t.readableListening||(t.readableListening=t.needReadable=!0,t.flowing=!1,t.emittedReadable=!1,m("on readable",t.length,t.reading),t.length?k(this):t.reading||M.nextTick(P,this))),r},_.prototype.removeListener=function(e,t){t=o.prototype.removeListener.call(this,e,t);return"readable"===e&&M.nextTick(j,this),t},_.prototype.removeAllListeners=function(e){var t=o.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||M.nextTick(j,this),t},_.prototype.resume=function(){var e,t,r=this._readableState;return r.flowing||(m("resume"),r.flowing=!r.readableListening,e=this,(t=r).resumeScheduled||(t.resumeScheduled=!0,M.nextTick(R,e,t))),r.paused=!1,this},_.prototype.pause=function(){return m("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(m("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},_.prototype.wrap=function(t){var e,r=this,n=this._readableState,o=!1;for(e in t.on("end",function(){var e;m("wrapped end"),!n.decoder||n.ended||(e=n.decoder.end())&&e.length&&r.push(e),r.push(null)}),t.on("data",function(e){m("wrapped data"),n.decoder&&(e=n.decoder.write(e)),n.objectMode&&null==e||(n.objectMode||e&&e.length)&&(r.push(e)||(o=!0,t.pause()))}),t)void 0===this[e]&&"function"==typeof t[e]&&(this[e]=function(e){return function(){return t[e].apply(t,arguments)}}(e));for(var i=0;i<y.length;i++)t.on(y[i],this.emit.bind(this,y[i]));return this._read=function(e){m("wrapped _read",e),o&&(o=!1,t.resume())},this},"function"==typeof Symbol&&(_.prototype[Symbol.asyncIterator]=function(){return void 0===e&&(e=U("./internal/streams/async_iterator")),e(this)}),Object.defineProperty(_.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(_.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(_.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(e){this._readableState&&(this._readableState.flowing=e)}}),_._fromList=N,Object.defineProperty(_.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}}),"function"==typeof Symbol&&(_.from=function(e,t){return void 0===r&&(r=U("./internal/streams/from")),r(_,e,t)})}).call(this)}).call(this,U("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../errors":35,"./_stream_duplex":36,"./internal/streams/async_iterator":41,"./internal/streams/buffer_list":42,"./internal/streams/destroy":43,"./internal/streams/from":45,"./internal/streams/state":47,"./internal/streams/stream":48,_process:32,buffer:13,events:18,inherits:27,"string_decoder/":49,util:12}],39:[function(e,t,r){"use strict";t.exports=u;var t=e("../errors").codes,n=t.ERR_METHOD_NOT_IMPLEMENTED,o=t.ERR_MULTIPLE_CALLBACK,i=t.ERR_TRANSFORM_ALREADY_TRANSFORMING,a=t.ERR_TRANSFORM_WITH_LENGTH_0,s=e("./_stream_duplex");function u(e){if(!(this instanceof u))return new u(e);s.call(this,e),this._transformState={afterTransform:function(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(null===n)return this.emit("error",new o);r.writechunk=null,(r.writecb=null)!=t&&this.push(t),n(e),(e=this._readableState).reading=!1,(e.needReadable||e.length<e.highWaterMark)&&this._read(e.highWaterMark)}.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",c)}function c(){var r=this;"function"!=typeof this._flush||this._readableState.destroyed?f(this,null,null):this._flush(function(e,t){f(r,e,t)})}function f(e,t,r){if(t)return e.emit("error",t);if(null!=r&&e.push(r),e._writableState.length)throw new a;if(e._transformState.transforming)throw new i;return e.push(null)}e("inherits")(u,s),u.prototype.push=function(e,t){return this._transformState.needTransform=!1,s.prototype.push.call(this,e,t)},u.prototype._transform=function(e,t,r){r(new n("_transform()"))},u.prototype._write=function(e,t,r){var n=this._transformState;n.writecb=r,n.writechunk=e,n.writeencoding=t,n.transforming||(t=this._readableState,(n.needTransform||t.needReadable||t.length<t.highWaterMark)&&this._read(t.highWaterMark))},u.prototype._read=function(e){var t=this._transformState;null===t.writechunk||t.transforming?t.needTransform=!0:(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform))},u.prototype._destroy=function(e,t){s.prototype._destroy.call(this,e,function(e){t(e)})}},{"../errors":35,"./_stream_duplex":36,inherits:27}],40:[function(P,R,e){(function(O,j){(function(){"use strict";function f(e){var t=this;this.next=null,this.entry=null,this.finish=function(){!function(e,t,r){var n=e.entry;for(e.entry=null;n;){var o=n.callback;t.pendingcb--,o(r),n=n.next}t.corkedRequestsFree.next=e}(t,e)}}var n;(R.exports=w).WritableState=_;var e={deprecate:P("util-deprecate")},r=P("./internal/streams/stream"),p=P("buffer").Buffer,l=j.Uint8Array||function(){};var o,t=P("./internal/streams/destroy"),i=P("./internal/streams/state").getHighWaterMark,a=P("../errors").codes,h=a.ERR_INVALID_ARG_TYPE,s=a.ERR_METHOD_NOT_IMPLEMENTED,u=a.ERR_MULTIPLE_CALLBACK,c=a.ERR_STREAM_CANNOT_PIPE,d=a.ERR_STREAM_DESTROYED,y=a.ERR_STREAM_NULL_VALUES,g=a.ERR_STREAM_WRITE_AFTER_END,m=a.ERR_UNKNOWN_ENCODING,v=t.errorOrDestroy;function b(){}function _(e,t,r){n=n||P("./_stream_duplex"),e=e||{},"boolean"!=typeof r&&(r=t instanceof n),this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=i(this,e,"writableHighWaterMark",r),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1;r=(this.destroyed=!1)===e.decodeStrings;this.decodeStrings=!r,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var r=e._writableState,n=r.sync,o=r.writecb;if("function"!=typeof o)throw new u;(function(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0})(r),t?function(e,t,r,n,o){--t.pendingcb,r?(O.nextTick(o,n),O.nextTick(x,e,t),e._writableState.errorEmitted=!0,v(e,n)):(o(n),e._writableState.errorEmitted=!0,v(e,n),x(e,t))}(e,r,n,t,o):((t=k(r)||e.destroyed)||r.corked||r.bufferProcessing||!r.bufferedRequest||A(e,r),n?O.nextTick(E,e,r,t,o):E(e,r,t,o))}(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new f(this)}function w(e){var t=this instanceof(n=n||P("./_stream_duplex"));if(!t&&!o.call(w,this))return new w(e);this._writableState=new _(e,this,t),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),r.call(this)}function S(e,t,r,n,o,i,a){t.writelen=n,t.writecb=a,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new d("write")):r?e._writev(o,t.onwrite):e._write(o,i,t.onwrite),t.sync=!1}function E(e,t,r,n){var o;r||(o=e,0===(r=t).length&&r.needDrain&&(r.needDrain=!1,o.emit("drain"))),t.pendingcb--,n(),x(e,t)}function A(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,o=new Array(n),n=t.corkedRequestsFree;n.entry=r;for(var i=0,a=!0;r;)(o[i]=r).isBuf||(a=!1),r=r.next,i+=1;o.allBuffers=a,S(e,t,!0,t.length,o,"",n.finish),t.pendingcb++,t.lastBufferedRequest=null,n.next?(t.corkedRequestsFree=n.next,n.next=null):t.corkedRequestsFree=new f(t),t.bufferedRequestCount=0}else{for(;r;){var s=r.chunk,u=r.encoding,c=r.callback;if(S(e,t,!1,t.objectMode?1:s.length,s,u,c),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function k(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function T(t,r){t._final(function(e){r.pendingcb--,e&&v(t,e),r.prefinished=!0,t.emit("prefinish"),x(t,r)})}function x(e,t){var r,n,o=k(t);return o&&(r=e,(n=t).prefinished||n.finalCalled||("function"!=typeof r._final||n.destroyed?(n.prefinished=!0,r.emit("prefinish")):(n.pendingcb++,n.finalCalled=!0,O.nextTick(T,r,n))),0===t.pendingcb&&(t.finished=!0,e.emit("finish"),!t.autoDestroy||(!(t=e._readableState)||t.autoDestroy&&t.endEmitted)&&e.destroy())),o}P("inherits")(w,r),_.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(_.prototype,"buffer",{get:e.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(o=Function.prototype[Symbol.hasInstance],Object.defineProperty(w,Symbol.hasInstance,{value:function(e){return!!o.call(this,e)||this===w&&(e&&e._writableState instanceof _)}})):o=function(e){return e instanceof this},w.prototype.pipe=function(){v(this,new c)},w.prototype.write=function(e,t,r){var n,o,i,a,s,u,c=this._writableState,f=!1,n=!c.objectMode&&(n=e,p.isBuffer(n)||n instanceof l);return n&&!p.isBuffer(e)&&(o=e,e=p.from(o)),"function"==typeof t&&(r=t,t=null),t=n?"buffer":t||c.defaultEncoding,"function"!=typeof r&&(r=b),c.ending?(a=this,s=r,u=new g,v(a,u),O.nextTick(s,u)):(n||(o=this,a=c,s=r,null===(u=e)?i=new y:"string"==typeof u||a.objectMode||(i=new h("chunk",["string","Buffer"],u)),i?(v(o,i),void O.nextTick(s,i)):1))&&(c.pendingcb++,f=function(e,t,r,n,o,i){r||(u=function(e,t,r){e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=p.from(t,r));return t}(t,n,o),n!==u&&(r=!0,o="buffer",n=u));var a=t.objectMode?1:n.length;t.length+=a;var s=t.length<t.highWaterMark;s||(t.needDrain=!0);{var u;t.writing||t.corked?(u=t.lastBufferedRequest,t.lastBufferedRequest={chunk:n,encoding:o,isBuf:r,callback:i,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1):S(e,t,!1,a,n,o,i)}return s}(this,c,n,e,t,r)),f},w.prototype.cork=function(){this._writableState.corked++},w.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.bufferProcessing||!e.bufferedRequest||A(this,e))},w.prototype.setDefaultEncoding=function(e){if("string"==typeof e&&(e=e.toLowerCase()),!(-1<["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())))throw new m(e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(w.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(w.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),w.prototype._write=function(e,t,r){r(new s("_write()"))},w.prototype._writev=null,w.prototype.end=function(e,t,r){var n=this._writableState;return"function"==typeof e?(r=e,t=e=null):"function"==typeof t&&(r=t,t=null),null!=e&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||(t=this,r=r,(n=n).ending=!0,x(t,n),r&&(n.finished?O.nextTick(r):t.once("finish",r)),n.ended=!0,t.writable=!1),this},Object.defineProperty(w.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(w.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),w.prototype.destroy=t.destroy,w.prototype._undestroy=t.undestroy,w.prototype._destroy=function(e,t){t(e)}}).call(this)}).call(this,P("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"../errors":35,"./_stream_duplex":36,"./internal/streams/destroy":43,"./internal/streams/state":47,"./internal/streams/stream":48,_process:32,buffer:13,inherits:27,"util-deprecate":50}],41:[function(n,g,e){(function(y){(function(){"use strict";var e;function r(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var o=n("./end-of-stream"),i=Symbol("lastResolve"),a=Symbol("lastReject"),s=Symbol("error"),u=Symbol("ended"),c=Symbol("lastPromise"),f=Symbol("handlePromise"),p=Symbol("stream");function l(e,t){return{value:e,done:t}}function h(e){var t,r=e[i];null===r||null!==(t=e[p].read())&&(e[c]=null,e[i]=null,e[a]=null,r(l(t,!1)))}var t=Object.getPrototypeOf(function(){}),d=Object.setPrototypeOf((r(e={get stream(){return this[p]},next:function(){var r=this,e=this[s];if(null!==e)return Promise.reject(e);if(this[u])return Promise.resolve(l(void 0,!0));if(this[p].destroyed)return new Promise(function(e,t){y.nextTick(function(){r[s]?t(r[s]):e(l(void 0,!0))})});var t,n,o,e=this[c];if(e)t=new Promise((n=e,o=this,function(e,t){n.then(function(){o[u]?e(l(void 0,!0)):o[f](e,t)},t)}));else{e=this[p].read();if(null!==e)return Promise.resolve(l(e,!1));t=new Promise(this[f])}return this[c]=t}},Symbol.asyncIterator,function(){return this}),r(e,"return",function(){var e=this;return new Promise(function(t,r){e[p].destroy(null,function(e){e?r(e):t(l(void 0,!0))})})}),e),t);g.exports=function(e){var t,n=Object.create(d,(r(t={},p,{value:e,writable:!0}),r(t,i,{value:null,writable:!0}),r(t,a,{value:null,writable:!0}),r(t,s,{value:null,writable:!0}),r(t,u,{value:e._readableState.endEmitted,writable:!0}),r(t,f,{value:function(e,t){var r=n[p].read();r?(n[c]=null,n[i]=null,n[a]=null,e(l(r,!1))):(n[i]=e,n[a]=t)},writable:!0}),t));return n[c]=null,o(e,function(e){if(e&&"ERR_STREAM_PREMATURE_CLOSE"!==e.code){var t=n[a];return null!==t&&(n[c]=null,n[i]=null,n[a]=null,t(e)),void(n[s]=e)}e=n[i];null!==e&&(n[c]=null,n[i]=null,e(l(void 0,!(n[a]=null)))),n[u]=!0}),e.on("readable",function(e){y.nextTick(h,e)}.bind(null,n)),n}}).call(this)}).call(this,n("_process"))},{"./end-of-stream":44,_process:32}],42:[function(e,t,r){"use strict";function i(t,e){var r,n=Object.keys(t);return Object.getOwnPropertySymbols&&(r=Object.getOwnPropertySymbols(t),e&&(r=r.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),n.push.apply(n,r)),n}function o(n){for(var e=1;e<arguments.length;e++){var o=null!=arguments[e]?arguments[e]:{};e%2?i(Object(o),!0).forEach(function(e){var t,r;t=n,e=o[r=e],r in t?Object.defineProperty(t,r,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[r]=e}):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(o)):i(Object(o)).forEach(function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(o,e))})}return n}function a(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}var s=e("buffer").Buffer,u=e("util").inspect,c=u&&u.custom||"inspect";t.exports=function(){function t(){!function(e){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this),this.head=null,this.tail=null,this.length=0}var e,r,n;return e=t,(r=[{key:"push",value:function(e){e={data:e,next:null};0<this.length?this.tail.next=e:this.head=e,this.tail=e,++this.length}},{key:"unshift",value:function(e){e={data:e,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length}},{key:"shift",value:function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(e){if(0===this.length)return"";for(var t=this.head,r=""+t.data;t=t.next;)r+=e+t.data;return r}},{key:"concat",value:function(e){if(0===this.length)return s.alloc(0);for(var t,r,n,o=s.allocUnsafe(e>>>0),i=this.head,a=0;i;)t=i.data,r=o,n=a,s.prototype.copy.call(t,r,n),a+=i.data.length,i=i.next;return o}},{key:"consume",value:function(e,t){var r;return e<this.head.data.length?(r=this.head.data.slice(0,e),this.head.data=this.head.data.slice(e)):r=e===this.head.data.length?this.shift():t?this._getString(e):this._getBuffer(e),r}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(e){var t=this.head,r=1,n=t.data;for(e-=n.length;t=t.next;){var o=t.data,i=e>o.length?o.length:e;if(i===o.length?n+=o:n+=o.slice(0,e),0===(e-=i)){i===o.length?(++r,t.next?this.head=t.next:this.head=this.tail=null):(this.head=t).data=o.slice(i);break}++r}return this.length-=r,n}},{key:"_getBuffer",value:function(e){var t=s.allocUnsafe(e),r=this.head,n=1;for(r.data.copy(t),e-=r.data.length;r=r.next;){var o=r.data,i=e>o.length?o.length:e;if(o.copy(t,t.length-e,0,i),0===(e-=i)){i===o.length?(++n,r.next?this.head=r.next:this.head=this.tail=null):(this.head=r).data=o.slice(i);break}++n}return this.length-=n,t}},{key:c,value:function(e,t){return u(this,o({},t,{depth:0,customInspect:!1}))}}])&&a(e.prototype,r),n&&a(e,n),t}()},{buffer:13,util:12}],43:[function(e,t,r){(function(u){(function(){"use strict";function i(e,t){s(e,t),a(e)}function a(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit("close")}function s(e,t){e.emit("error",t)}t.exports={destroy:function(e,t){var r=this,n=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return n||o?t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,u.nextTick(s,this,e)):u.nextTick(s,this,e)):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?r._writableState?r._writableState.errorEmitted?u.nextTick(a,r):(r._writableState.errorEmitted=!0,u.nextTick(i,r,e)):u.nextTick(i,r,e):t?(u.nextTick(a,r),t(e)):u.nextTick(a,r)})),this},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)},errorOrDestroy:function(e,t){var r=e._readableState,n=e._writableState;r&&r.autoDestroy||n&&n.autoDestroy?e.destroy(t):e.emit("error",t)}}}).call(this)}).call(this,e("_process"))},{_process:32}],44:[function(e,t,r){"use strict";var m=e("../../../errors").codes.ERR_STREAM_PREMATURE_CLOSE;function v(){}t.exports=function e(t,r,n){if("function"==typeof r)return e(t,null,r);var o,i;o=n||v,i=!1,n=function(){if(!i){i=!0;for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];o.apply(this,t)}};function a(){t.writable||y()}function s(){g=!(l=!1),h||n.call(t)}function u(e){n.call(t,e)}function c(){var e;return l&&!g?(t._readableState&&t._readableState.ended||(e=new m),n.call(t,e)):h&&!d?(t._writableState&&t._writableState.ended||(e=new m),n.call(t,e)):void 0}function f(){t.req.on("finish",y)}var p,l=(r=r||{}).readable||!1!==r.readable&&t.readable,h=r.writable||!1!==r.writable&&t.writable,d=t._writableState&&t._writableState.finished,y=function(){d=!(h=!1),l||n.call(t)},g=t._readableState&&t._readableState.endEmitted;return(p=t).setHeader&&"function"==typeof p.abort?(t.on("complete",y),t.on("abort",c),t.req?f():t.on("request",f)):h&&!t._writableState&&(t.on("end",a),t.on("close",a)),t.on("end",s),t.on("finish",y),!1!==r.error&&t.on("error",u),t.on("close",c),function(){t.removeListener("complete",y),t.removeListener("abort",c),t.removeListener("request",f),t.req&&t.req.removeListener("finish",y),t.removeListener("end",a),t.removeListener("close",a),t.removeListener("finish",y),t.removeListener("end",s),t.removeListener("error",u),t.removeListener("close",c)}}},{"../../../errors":35}],45:[function(e,t,r){t.exports=function(){throw new Error("Readable.from is not available in the browser")}},{}],46:[function(u,e,t){"use strict";var c;var r=u("../../../errors").codes,s=r.ERR_MISSING_ARGS,f=r.ERR_STREAM_DESTROYED;function p(e){if(e)throw e}function l(r,e,t,n){var o,i;o=n,i=!1;var a=!(n=function(){i||(i=!0,o.apply(void 0,arguments))});r.on("close",function(){a=!0}),void 0===c&&(c=u("./end-of-stream")),c(r,{readable:e,writable:t},function(e){return e?n(e):(a=!0,void n())});var s=!1;return function(e){var t;if(!a&&!s)return s=!0,(t=r).setHeader&&"function"==typeof t.abort?r.abort():"function"==typeof r.destroy?r.destroy():void n(e||new f("pipe"))}}function h(e){e()}function d(e,t){return e.pipe(t)}e.exports=function(){for(var e=arguments.length,n=new Array(e),t=0;t<e;t++)n[t]=arguments[t];var r,o,i=!(r=n).length||"function"!=typeof r[r.length-1]?p:r.pop();if(Array.isArray(n[0])&&(n=n[0]),n.length<2)throw new s("streams");var a=n.map(function(e,t){var r=t<n.length-1;return l(e,r,0<t,function(e){o=o||e,e&&a.forEach(h),r||(a.forEach(h),i(o))})});return n.reduce(d)}},{"../../../errors":35,"./end-of-stream":44}],47:[function(e,t,r){"use strict";var a=e("../../../errors").codes.ERR_INVALID_OPT_VALUE;t.exports={getHighWaterMark:function(e,t,r,n){var o,i=(o=n,i=r,null!=(t=t).highWaterMark?t.highWaterMark:o?t[i]:null);if(null==i)return e.objectMode?16:16384;if(!isFinite(i)||Math.floor(i)!==i||i<0)throw new a(n?r:"highWaterMark",i);return Math.floor(i)}}},{"../../../errors":35}],48:[function(e,t,r){t.exports=e("events").EventEmitter},{events:18}],49:[function(e,t,r){"use strict";var n=e("safe-buffer").Buffer,o=n.isEncoding||function(e){switch((e=""+e)&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function i(e){var t=function(e){if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}(e);if("string"!=typeof t&&(n.isEncoding===o||!o(e)))throw new Error("Unknown encoding: "+e);return t||e}function a(e){var t;switch(this.encoding=i(e),this.encoding){case"utf16le":this.text=c,this.end=f,t=4;break;case"utf8":this.fillLast=u,t=4;break;case"base64":this.text=p,this.end=l,t=3;break;default:return this.write=h,void(this.end=d)}this.lastNeed=0,this.lastTotal=0,this.lastChar=n.allocUnsafe(t)}function s(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function u(e){var t,r,n=this.lastTotal-this.lastNeed,t=(t=this,128!=(192&(r=e)[0])?(t.lastNeed=0,"�"):1<t.lastNeed&&1<r.length?128!=(192&r[1])?(t.lastNeed=1,"�"):2<t.lastNeed&&2<r.length&&128!=(192&r[2])?(t.lastNeed=2,"�"):void 0:void 0);return void 0!==t?t:this.lastNeed<=e.length?(e.copy(this.lastChar,n,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,n,0,e.length),void(this.lastNeed-=e.length))}function c(e,t){if((e.length-t)%2!=0)return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1);var r=e.toString("utf16le",t);if(r){t=r.charCodeAt(r.length-1);if(55296<=t&&t<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}function f(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){e=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,e)}return t}function p(e,t){var r=(e.length-t)%3;return 0==r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1==r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function l(e){e=e&&e.length?this.write(e):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function h(e){return e.toString(this.encoding)}function d(e){return e&&e.length?this.write(e):""}(r.StringDecoder=a).prototype.write=function(e){if(0===e.length)return"";var t,r;if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""},a.prototype.end=function(e){e=e&&e.length?this.write(e):"";return this.lastNeed?e+"�":e},a.prototype.text=function(e,t){var r=function(e,t,r){var n=t.length-1;if(n<r)return 0;var o=s(t[n]);if(0<=o)return 0<o&&(e.lastNeed=o-1),o;if(--n<r||-2===o)return 0;if(0<=(o=s(t[n])))return 0<o&&(e.lastNeed=o-2),o;if(--n<r||-2===o)return 0;if(0<=(o=s(t[n])))return 0<o&&(2===o?o=0:e.lastNeed=o-3),o;return 0}(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;r=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,r),e.toString("utf8",t,r)},a.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},{"safe-buffer":33}],50:[function(e,r,t){(function(t){(function(){function n(e){try{if(!t.localStorage)return}catch(e){return}e=t.localStorage[e];return null!=e&&"true"===String(e).toLowerCase()}r.exports=function(e,t){if(n("noDeprecation"))return e;var r=!1;return function(){if(!r){if(n("throwDeprecation"))throw new Error(t);n("traceDeprecation")?console.trace(t):console.warn(t),r=!0}return e.apply(this,arguments)}}}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],51:[function(e,t,r){t.exports=function(e){return e&&"object"==typeof e&&"function"==typeof e.copy&&"function"==typeof e.fill&&"function"==typeof e.readUInt8}},{}],52:[function(e,t,r){"use strict";var n=e("is-arguments"),o=e("is-generator-function"),i=e("which-typed-array"),a=e("is-typed-array");function s(e){return e.call.bind(e)}var u,c,f="undefined"!=typeof BigInt,p="undefined"!=typeof Symbol,l=s(Object.prototype.toString),h=s(Number.prototype.valueOf),d=s(String.prototype.valueOf),y=s(Boolean.prototype.valueOf);function g(e,t){if("object"!=typeof e)return!1;try{return t(e),!0}catch(e){return!1}}function m(e){return"[object Map]"===l(e)}function v(e){return"[object Set]"===l(e)}function b(e){return"[object WeakMap]"===l(e)}function _(e){return"[object WeakSet]"===l(e)}function w(e){return"[object ArrayBuffer]"===l(e)}function S(e){return"undefined"!=typeof ArrayBuffer&&(w.working?w(e):e instanceof ArrayBuffer)}function E(e){return"[object DataView]"===l(e)}function A(e){return"undefined"!=typeof DataView&&(E.working?E(e):e instanceof DataView)}function k(e){return"[object SharedArrayBuffer]"===l(e)}function T(e){return"undefined"!=typeof SharedArrayBuffer&&(k.working?k(e):e instanceof SharedArrayBuffer)}function x(e){return g(e,h)}function O(e){return g(e,d)}function j(e){return g(e,y)}function P(e){return f&&g(e,u)}function R(e){return p&&g(e,c)}f&&(u=s(BigInt.prototype.valueOf)),p&&(c=s(Symbol.prototype.valueOf)),r.isArgumentsObject=n,r.isGeneratorFunction=o,r.isTypedArray=a,r.isPromise=function(e){return"undefined"!=typeof Promise&&e instanceof Promise||null!==e&&"object"==typeof e&&"function"==typeof e.then&&"function"==typeof e.catch},r.isArrayBufferView=function(e){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):a(e)||A(e)},r.isUint8Array=function(e){return"Uint8Array"===i(e)},r.isUint8ClampedArray=function(e){return"Uint8ClampedArray"===i(e)},r.isUint16Array=function(e){return"Uint16Array"===i(e)},r.isUint32Array=function(e){return"Uint32Array"===i(e)},r.isInt8Array=function(e){return"Int8Array"===i(e)},r.isInt16Array=function(e){return"Int16Array"===i(e)},r.isInt32Array=function(e){return"Int32Array"===i(e)},r.isFloat32Array=function(e){return"Float32Array"===i(e)},r.isFloat64Array=function(e){return"Float64Array"===i(e)},r.isBigInt64Array=function(e){return"BigInt64Array"===i(e)},r.isBigUint64Array=function(e){return"BigUint64Array"===i(e)},m.working="undefined"!=typeof Map&&m(new Map),r.isMap=function(e){return"undefined"!=typeof Map&&(m.working?m(e):e instanceof Map)},v.working="undefined"!=typeof Set&&v(new Set),r.isSet=function(e){return"undefined"!=typeof Set&&(v.working?v(e):e instanceof Set)},b.working="undefined"!=typeof WeakMap&&b(new WeakMap),r.isWeakMap=function(e){return"undefined"!=typeof WeakMap&&(b.working?b(e):e instanceof WeakMap)},_.working="undefined"!=typeof WeakSet&&_(new WeakSet),r.isWeakSet=_,w.working="undefined"!=typeof ArrayBuffer&&w(new ArrayBuffer),r.isArrayBuffer=S,E.working="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView&&E(new DataView(new ArrayBuffer(1),0,1)),r.isDataView=A,k.working="undefined"!=typeof SharedArrayBuffer&&k(new SharedArrayBuffer),r.isSharedArrayBuffer=T,r.isAsyncFunction=function(e){return"[object AsyncFunction]"===l(e)},r.isMapIterator=function(e){return"[object Map Iterator]"===l(e)},r.isSetIterator=function(e){return"[object Set Iterator]"===l(e)},r.isGeneratorObject=function(e){return"[object Generator]"===l(e)},r.isWebAssemblyCompiledModule=function(e){return"[object WebAssembly.Module]"===l(e)},r.isNumberObject=x,r.isStringObject=O,r.isBooleanObject=j,r.isBigIntObject=P,r.isSymbolObject=R,r.isBoxedPrimitive=function(e){return x(e)||O(e)||j(e)||P(e)||R(e)},r.isAnyArrayBuffer=function(e){return"undefined"!=typeof Uint8Array&&(S(e)||T(e))},["isProxy","isExternal","isModuleNamespaceObject"].forEach(function(e){Object.defineProperty(r,e,{enumerable:!1,value:function(){throw new Error(e+" is not supported in userland")}})})},{"is-arguments":28,"is-generator-function":29,"is-typed-array":30,"which-typed-array":54}],53:[function(O,e,j){(function(x){(function(){var t=Object.getOwnPropertyDescriptors||function(e){for(var t=Object.keys(e),r={},n=0;n<t.length;n++)r[t[n]]=Object.getOwnPropertyDescriptor(e,t[n]);return r},s=/%[sdj%]/g;j.format=function(e){if(!g(e)){for(var t=[],r=0;r<arguments.length;r++)t.push(u(arguments[r]));return t.join(" ")}for(var r=1,n=arguments,o=n.length,i=String(e).replace(s,function(e){if("%%"===e)return"%";if(o<=r)return e;switch(e){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(e){return"[Circular]"}default:return e}}),a=n[r];r<o;a=n[++r])d(a)||!b(a)?i+=" "+a:i+=" "+u(a);return i},j.deprecate=function(e,t){if(void 0!==x&&!0===x.noDeprecation)return e;if(void 0===x)return function(){return j.deprecate(e,t).apply(this,arguments)};var r=!1;return function(){if(!r){if(x.throwDeprecation)throw new Error(t);x.traceDeprecation?console.trace(t):console.error(t),r=!0}return e.apply(this,arguments)}};var e,n={},o=/^$/;function u(e,t){var r={seen:[],stylize:a};return 3<=arguments.length&&(r.depth=arguments[2]),4<=arguments.length&&(r.colors=arguments[3]),h(t)?r.showHidden=t:t&&j._extend(r,t),m(r.showHidden)&&(r.showHidden=!1),m(r.depth)&&(r.depth=2),m(r.colors)&&(r.colors=!1),m(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=i),c(r,e,r.depth)}function i(e,t){t=u.styles[t];return t?"["+u.colors[t][0]+"m"+e+"["+u.colors[t][1]+"m":e}function a(e,t){return e}function c(t,r,n){if(t.customInspect&&r&&S(r.inspect)&&r.inspect!==j.inspect&&(!r.constructor||r.constructor.prototype!==r)){var e=r.inspect(n,t);return g(e)||(e=c(t,e,n)),e}var o=function(e,t){if(m(t))return e.stylize("undefined","undefined");if(g(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}if(y(t))return e.stylize(""+t,"number");if(h(t))return e.stylize(""+t,"boolean");if(d(t))return e.stylize("null","null")}(t,r);if(o)return o;var i,e=Object.keys(r),a=(i={},e.forEach(function(e,t){i[e]=!0}),i);if(t.showHidden&&(e=Object.getOwnPropertyNames(r)),w(r)&&(0<=e.indexOf("message")||0<=e.indexOf("description")))return f(r);if(0===e.length){if(S(r)){var s=r.name?": "+r.name:"";return t.stylize("[Function"+s+"]","special")}if(v(r))return t.stylize(RegExp.prototype.toString.call(r),"regexp");if(_(r))return t.stylize(Date.prototype.toString.call(r),"date");if(w(r))return f(r)}var o="",u=!1,s=["{","}"];return l(r)&&(u=!0,s=["[","]"]),S(r)&&(o=" [Function"+(r.name?": "+r.name:"")+"]"),v(r)&&(o=" "+RegExp.prototype.toString.call(r)),_(r)&&(o=" "+Date.prototype.toUTCString.call(r)),w(r)&&(o=" "+f(r)),0!==e.length||u&&0!=r.length?n<0?v(r)?t.stylize(RegExp.prototype.toString.call(r),"regexp"):t.stylize("[Object]","special"):(t.seen.push(r),e=u?function(t,r,n,o,e){for(var i=[],a=0,s=r.length;a<s;++a)k(r,String(a))?i.push(p(t,r,n,o,String(a),!0)):i.push("");return e.forEach(function(e){e.match(/^\d+$/)||i.push(p(t,r,n,o,e,!0))}),i}(t,r,n,a,e):e.map(function(e){return p(t,r,n,a,e,u)}),t.seen.pop(),function(e,t,r){if(60<e.reduce(function(e,t){return 0<=t.indexOf("\n")&&0,e+t.replace(/\u001b\[\d\d?m/g,"").length+1},0))return r[0]+(""===t?"":t+"\n ")+" "+e.join(",\n  ")+" "+r[1];return r[0]+t+" "+e.join(", ")+" "+r[1]}(e,o,s)):s[0]+o+s[1]}function f(e){return"["+Error.prototype.toString.call(e)+"]"}function p(e,t,r,n,o,i){var a,s,t=Object.getOwnPropertyDescriptor(t,o)||{value:t[o]};if(t.get?s=t.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):t.set&&(s=e.stylize("[Setter]","special")),k(n,o)||(a="["+o+"]"),s||(e.seen.indexOf(t.value)<0?-1<(s=d(r)?c(e,t.value,null):c(e,t.value,r-1)).indexOf("\n")&&(s=i?s.split("\n").map(function(e){return"  "+e}).join("\n").substr(2):"\n"+s.split("\n").map(function(e){return"   "+e}).join("\n")):s=e.stylize("[Circular]","special")),m(a)){if(i&&o.match(/^\d+$/))return s;a=(a=JSON.stringify(""+o)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.substr(1,a.length-2),e.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),e.stylize(a,"string"))}return a+": "+s}function l(e){return Array.isArray(e)}function h(e){return"boolean"==typeof e}function d(e){return null===e}function y(e){return"number"==typeof e}function g(e){return"string"==typeof e}function m(e){return void 0===e}function v(e){return b(e)&&"[object RegExp]"===r(e)}function b(e){return"object"==typeof e&&null!==e}function _(e){return b(e)&&"[object Date]"===r(e)}function w(e){return b(e)&&("[object Error]"===r(e)||e instanceof Error)}function S(e){return"function"==typeof e}function r(e){return Object.prototype.toString.call(e)}function E(e){return e<10?"0"+e.toString(10):e.toString(10)}x.env.NODE_DEBUG&&(e=(e=x.env.NODE_DEBUG).replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase(),o=new RegExp("^"+e+"$","i")),j.debuglog=function(t){var r;return t=t.toUpperCase(),n[t]||(o.test(t)?(r=x.pid,n[t]=function(){var e=j.format.apply(j,arguments);console.error("%s %d: %s",t,r,e)}):n[t]=function(){}),n[t]},(j.inspect=u).colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},u.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},j.types=O("./support/types"),j.isArray=l,j.isBoolean=h,j.isNull=d,j.isNullOrUndefined=function(e){return null==e},j.isNumber=y,j.isString=g,j.isSymbol=function(e){return"symbol"==typeof e},j.isUndefined=m,j.isRegExp=v,j.types.isRegExp=v,j.isObject=b,j.isDate=_,j.types.isDate=_,j.isError=w,j.types.isNativeError=w,j.isFunction=S,j.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},j.isBuffer=O("./support/isBuffer");var A=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function k(e,t){return Object.prototype.hasOwnProperty.call(e,t)}j.log=function(){var e,t;console.log("%s - %s",(e=new Date,t=[E(e.getHours()),E(e.getMinutes()),E(e.getSeconds())].join(":"),[e.getDate(),A[e.getMonth()],t].join(" ")),j.format.apply(j,arguments))},j.inherits=O("inherits"),j._extend=function(e,t){if(!t||!b(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e};var T="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;j.promisify=function(i){if("function"!=typeof i)throw new TypeError('The "original" argument must be of type Function');if(T&&i[T]){var e;if("function"!=typeof(e=i[T]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(e,T,{value:e,enumerable:!1,writable:!1,configurable:!0}),e}function e(){for(var r,n,e=new Promise(function(e,t){r=e,n=t}),t=[],o=0;o<arguments.length;o++)t.push(arguments[o]);t.push(function(e,t){e?n(e):r(t)});try{i.apply(this,t)}catch(e){n(e)}return e}return Object.setPrototypeOf(e,Object.getPrototypeOf(i)),T&&Object.defineProperty(e,T,{value:e,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(e,t(i))},j.promisify.custom=T,j.callbackify=function(i){if("function"!=typeof i)throw new TypeError('The "original" argument must be of type Function');function e(){for(var e=[],t=0;t<arguments.length;t++)e.push(arguments[t]);var r=e.pop();if("function"!=typeof r)throw new TypeError("The last argument must be of type Function");function n(){return r.apply(o,arguments)}var o=this;i.apply(this,e).then(function(e){x.nextTick(n.bind(null,null,e))},function(e){x.nextTick(function(e,t){var r;return e||((r=new Error("Promise was rejected with a falsy value")).reason=e,e=r),t(e)}.bind(null,e,n))})}return Object.setPrototypeOf(e,Object.getPrototypeOf(i)),Object.defineProperties(e,t(i)),e}}).call(this)}).call(this,O("_process"))},{"./support/isBuffer":51,"./support/types":52,_process:32,inherits:27}],54:[function(p,l,e){(function(f){(function(){"use strict";var t=p("foreach"),e=p("available-typed-arrays"),r=p("call-bind/callBound"),i=r("Object.prototype.toString"),a=p("has-symbols")()&&"symbol"==typeof Symbol.toStringTag,e=e(),s=r("String.prototype.slice"),u={},n=p("es-abstract/helpers/getOwnPropertyDescriptor"),o=Object.getPrototypeOf;a&&n&&o&&t(e,function(e){if("function"==typeof f[e]){var t=new f[e];if(!(Symbol.toStringTag in t))throw new EvalError("this engine has support for Symbol.toStringTag, but "+e+" does not have the property! Please report this.");var r=o(t),t=n(r,Symbol.toStringTag);t||(r=o(r),t=n(r,Symbol.toStringTag)),u[e]=t.get}});var c=p("is-typed-array");l.exports=function(e){return!!c(e)&&(a?(n=e,o=!1,t(u,function(e,t){if(!o)try{var r=e.call(n);r===t&&(o=r)}catch(e){}}),o):s(i(e),8,-1));var n,o}}).call(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"available-typed-arrays":10,"call-bind/callBound":14,"es-abstract/helpers/getOwnPropertyDescriptor":17,foreach:19,"has-symbols":23,"is-typed-array":30}]},{},[1])(1)});