UNPKG

tronweb

Version:

JavaScript SDK that encapsulates the TRON HTTP API

2 lines 958 kB
/*! For license information please see TronWeb.js.LICENSE.txt */ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("TronWeb",[],t):"object"==typeof exports?exports.TronWeb=t():e.TronWeb=t()}(self,()=>(()=>{var e={8734(e,t){"use strict";t.byteLength=function(e){var t=a(e),r=t[0],n=t[1];return 3*(r+n)/4-n},t.toByteArray=function(e){var t,r,s=a(e),i=s[0],c=s[1],u=new o(function(e,t,r){return 3*(t+r)/4-r}(0,i,c)),l=0,d=c>0?i-4:i;for(r=0;r<d;r+=4)t=n[e.charCodeAt(r)]<<18|n[e.charCodeAt(r+1)]<<12|n[e.charCodeAt(r+2)]<<6|n[e.charCodeAt(r+3)],u[l++]=t>>16&255,u[l++]=t>>8&255,u[l++]=255&t;return 2===c&&(t=n[e.charCodeAt(r)]<<2|n[e.charCodeAt(r+1)]>>4,u[l++]=255&t),1===c&&(t=n[e.charCodeAt(r)]<<10|n[e.charCodeAt(r+1)]<<4|n[e.charCodeAt(r+2)]>>2,u[l++]=t>>8&255,u[l++]=255&t),u},t.fromByteArray=function(e){for(var t,n=e.length,o=n%3,s=[],i=16383,a=0,c=n-o;a<c;a+=i)s.push(u(e,a,a+i>c?c:a+i));return 1===o?(t=e[n-1],s.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],s.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"=")),s.join("")};for(var r=[],n=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",i=0;i<64;++i)r[i]=s[i],n[s.charCodeAt(i)]=i;function a(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");return-1===r&&(r=t),[r,r===t?0:4-r%4]}function c(e){return r[e>>18&63]+r[e>>12&63]+r[e>>6&63]+r[63&e]}function u(e,t,r){for(var n,o=[],s=t;s<r;s+=3)n=(e[s]<<16&16711680)+(e[s+1]<<8&65280)+(255&e[s+2]),o.push(c(n));return o.join("")}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},7351(e,t,r){"use strict";const n=r(8734),o=r(6275),s="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;t.hp=c,t.IS=50;const i=2147483647;function a(e){if(e>i)throw new RangeError('The value "'+e+'" is invalid for option "size"');const t=new Uint8Array(e);return Object.setPrototypeOf(t,c.prototype),t}function c(e,t,r){if("number"==typeof e){if("string"==typeof t)throw new TypeError('The "string" argument must be of type string. Received type number');return d(e)}return u(e,t,r)}function u(e,t,r){if("string"==typeof e)return function(e,t){if("string"==typeof t&&""!==t||(t="utf8"),!c.isEncoding(t))throw new TypeError("Unknown encoding: "+t);const r=0|g(e,t);let n=a(r);const o=n.write(e,t);return o!==r&&(n=n.slice(0,o)),n}(e,t);if(ArrayBuffer.isView(e))return function(e){if(q(e,Uint8Array)){const t=new Uint8Array(e);return f(t.buffer,t.byteOffset,t.byteLength)}return p(e)}(e);if(null==e)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(q(e,ArrayBuffer)||e&&q(e.buffer,ArrayBuffer))return f(e,t,r);if("undefined"!=typeof SharedArrayBuffer&&(q(e,SharedArrayBuffer)||e&&q(e.buffer,SharedArrayBuffer)))return f(e,t,r);if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type number');const n=e.valueOf&&e.valueOf();if(null!=n&&n!==e)return c.from(n,t,r);const o=function(e){if(c.isBuffer(e)){const t=0|h(e.length),r=a(t);return 0===r.length||e.copy(r,0,0,t),r}return void 0!==e.length?"number"!=typeof e.length||Y(e.length)?a(0):p(e):"Buffer"===e.type&&Array.isArray(e.data)?p(e.data):void 0}(e);if(o)return o;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return c.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 l(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 d(e){return l(e),a(e<0?0:0|h(e))}function p(e){const t=e.length<0?0:0|h(e.length),r=a(t);for(let n=0;n<t;n+=1)r[n]=255&e[n];return r}function f(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');let n;return n=void 0===t&&void 0===r?new Uint8Array(e):void 0===r?new Uint8Array(e,t):new Uint8Array(e,t,r),Object.setPrototypeOf(n,c.prototype),n}function h(e){if(e>=i)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+i.toString(16)+" bytes");return 0|e}function g(e,t){if(c.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||q(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);const r=e.length,n=arguments.length>2&&!0===arguments[2];if(!n&&0===r)return 0;let o=!1;for(;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return H(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return K(e).length;default:if(o)return n?-1:H(e).length;t=(""+t).toLowerCase(),o=!0}}function y(e,t,r){let n=!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 S(this,t,r);case"utf8":case"utf-8":return E(this,t,r);case"ascii":return I(this,t,r);case"latin1":case"binary":return O(this,t,r);case"base64":return B(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return M(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function b(e,t,r){const n=e[t];e[t]=e[r],e[r]=n}function m(e,t,r,n,o){if(0===e.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),Y(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=c.from(t,n)),c.isBuffer(t))return 0===t.length?-1:T(e,t,r,n,o);if("number"==typeof t)return t&=255,"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):T(e,[t],r,n,o);throw new TypeError("val must be string, number or Buffer")}function T(e,t,r,n,o){let s,i=1,a=e.length,c=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;i=2,a/=2,c/=2,r/=2}function u(e,t){return 1===i?e[t]:e.readUInt16BE(t*i)}if(o){let n=-1;for(s=r;s<a;s++)if(u(e,s)===u(t,-1===n?0:s-n)){if(-1===n&&(n=s),s-n+1===c)return n*i}else-1!==n&&(s-=s-n),n=-1}else for(r+c>a&&(r=a-c),s=r;s>=0;s--){let r=!0;for(let n=0;n<c;n++)if(u(e,s+n)!==u(t,n)){r=!1;break}if(r)return s}return-1}function w(e,t,r,n){r=Number(r)||0;const o=e.length-r;n?(n=Number(n))>o&&(n=o):n=o;const s=t.length;let i;for(n>s/2&&(n=s/2),i=0;i<n;++i){const n=parseInt(t.substr(2*i,2),16);if(Y(n))return i;e[r+i]=n}return i}function A(e,t,r,n){return Z(H(t,e.length-r),e,r,n)}function P(e,t,r,n){return Z(function(e){const t=[];for(let r=0;r<e.length;++r)t.push(255&e.charCodeAt(r));return t}(t),e,r,n)}function v(e,t,r,n){return Z(K(t),e,r,n)}function W(e,t,r,n){return Z(function(e,t){let r,n,o;const s=[];for(let i=0;i<e.length&&!((t-=2)<0);++i)r=e.charCodeAt(i),n=r>>8,o=r%256,s.push(o),s.push(n);return s}(t,e.length-r),e,r,n)}function B(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function E(e,t,r){r=Math.min(e.length,r);const n=[];let o=t;for(;o<r;){const t=e[o];let s=null,i=t>239?4:t>223?3:t>191?2:1;if(o+i<=r){let r,n,a,c;switch(i){case 1:t<128&&(s=t);break;case 2:r=e[o+1],128==(192&r)&&(c=(31&t)<<6|63&r,c>127&&(s=c));break;case 3:r=e[o+1],n=e[o+2],128==(192&r)&&128==(192&n)&&(c=(15&t)<<12|(63&r)<<6|63&n,c>2047&&(c<55296||c>57343)&&(s=c));break;case 4:r=e[o+1],n=e[o+2],a=e[o+3],128==(192&r)&&128==(192&n)&&128==(192&a)&&(c=(15&t)<<18|(63&r)<<12|(63&n)<<6|63&a,c>65535&&c<1114112&&(s=c))}}null===s?(s=65533,i=1):s>65535&&(s-=65536,n.push(s>>>10&1023|55296),s=56320|1023&s),n.push(s),o+=i}return function(e){const t=e.length;if(t<=C)return String.fromCharCode.apply(String,e);let r="",n=0;for(;n<t;)r+=String.fromCharCode.apply(String,e.slice(n,n+=C));return r}(n)}c.TYPED_ARRAY_SUPPORT=function(){try{const e=new Uint8Array(1),t={foo:function(){return 42}};return Object.setPrototypeOf(t,Uint8Array.prototype),Object.setPrototypeOf(e,t),42===e.foo()}catch(e){return!1}}(),c.TYPED_ARRAY_SUPPORT||"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(c.prototype,"parent",{enumerable:!0,get:function(){if(c.isBuffer(this))return this.buffer}}),Object.defineProperty(c.prototype,"offset",{enumerable:!0,get:function(){if(c.isBuffer(this))return this.byteOffset}}),c.poolSize=8192,c.from=function(e,t,r){return u(e,t,r)},Object.setPrototypeOf(c.prototype,Uint8Array.prototype),Object.setPrototypeOf(c,Uint8Array),c.alloc=function(e,t,r){return function(e,t,r){return l(e),e<=0?a(e):void 0!==t?"string"==typeof r?a(e).fill(t,r):a(e).fill(t):a(e)}(e,t,r)},c.allocUnsafe=function(e){return d(e)},c.allocUnsafeSlow=function(e){return d(e)},c.isBuffer=function(e){return null!=e&&!0===e._isBuffer&&e!==c.prototype},c.compare=function(e,t){if(q(e,Uint8Array)&&(e=c.from(e,e.offset,e.byteLength)),q(t,Uint8Array)&&(t=c.from(t,t.offset,t.byteLength)),!c.isBuffer(e)||!c.isBuffer(t))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===t)return 0;let r=e.length,n=t.length;for(let o=0,s=Math.min(r,n);o<s;++o)if(e[o]!==t[o]){r=e[o],n=t[o];break}return r<n?-1:n<r?1:0},c.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}},c.concat=function(e,t){if(!Array.isArray(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return c.alloc(0);let r;if(void 0===t)for(t=0,r=0;r<e.length;++r)t+=e[r].length;const n=c.allocUnsafe(t);let o=0;for(r=0;r<e.length;++r){let t=e[r];if(q(t,Uint8Array))o+t.length>n.length?(c.isBuffer(t)||(t=c.from(t)),t.copy(n,o)):Uint8Array.prototype.set.call(n,t,o);else{if(!c.isBuffer(t))throw new TypeError('"list" argument must be an Array of Buffers');t.copy(n,o)}o+=t.length}return n},c.byteLength=g,c.prototype._isBuffer=!0,c.prototype.swap16=function(){const e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let t=0;t<e;t+=2)b(this,t,t+1);return this},c.prototype.swap32=function(){const e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let t=0;t<e;t+=4)b(this,t,t+3),b(this,t+1,t+2);return this},c.prototype.swap64=function(){const e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let t=0;t<e;t+=8)b(this,t,t+7),b(this,t+1,t+6),b(this,t+2,t+5),b(this,t+3,t+4);return this},c.prototype.toString=function(){const e=this.length;return 0===e?"":0===arguments.length?E(this,0,e):y.apply(this,arguments)},c.prototype.toLocaleString=c.prototype.toString,c.prototype.equals=function(e){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===c.compare(this,e)},c.prototype.inspect=function(){let e="";const r=t.IS;return e=this.toString("hex",0,r).replace(/(.{2})/g,"$1 ").trim(),this.length>r&&(e+=" ... "),"<Buffer "+e+">"},s&&(c.prototype[s]=c.prototype.inspect),c.prototype.compare=function(e,t,r,n,o){if(q(e,Uint8Array)&&(e=c.from(e,e.offset,e.byteLength)),!c.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(n>=o&&t>=r)return 0;if(n>=o)return-1;if(t>=r)return 1;if(this===e)return 0;let s=(o>>>=0)-(n>>>=0),i=(r>>>=0)-(t>>>=0);const a=Math.min(s,i),u=this.slice(n,o),l=e.slice(t,r);for(let e=0;e<a;++e)if(u[e]!==l[e]){s=u[e],i=l[e];break}return s<i?-1:i<s?1:0},c.prototype.includes=function(e,t,r){return-1!==this.indexOf(e,t,r)},c.prototype.indexOf=function(e,t,r){return m(this,e,t,r,!0)},c.prototype.lastIndexOf=function(e,t,r){return m(this,e,t,r,!1)},c.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)}const o=this.length-t;if((void 0===r||r>o)&&(r=o),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");let s=!1;for(;;)switch(n){case"hex":return w(this,e,t,r);case"utf8":case"utf-8":return A(this,e,t,r);case"ascii":case"latin1":case"binary":return P(this,e,t,r);case"base64":return v(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return W(this,e,t,r);default:if(s)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),s=!0}},c.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};const C=4096;function I(e,t,r){let n="";r=Math.min(e.length,r);for(let o=t;o<r;++o)n+=String.fromCharCode(127&e[o]);return n}function O(e,t,r){let n="";r=Math.min(e.length,r);for(let o=t;o<r;++o)n+=String.fromCharCode(e[o]);return n}function S(e,t,r){const n=e.length;(!t||t<0)&&(t=0),(!r||r<0||r>n)&&(r=n);let o="";for(let n=t;n<r;++n)o+=J[e[n]];return o}function M(e,t,r){const n=e.slice(t,r);let o="";for(let e=0;e<n.length-1;e+=2)o+=String.fromCharCode(n[e]+256*n[e+1]);return o}function F(e,t,r){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>r)throw new RangeError("Trying to access beyond buffer length")}function R(e,t,r,n,o,s){if(!c.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||t<s)throw new RangeError('"value" argument is out of bounds');if(r+n>e.length)throw new RangeError("Index out of range")}function _(e,t,r,n,o){j(t,n,o,e,r,7);let s=Number(t&BigInt(4294967295));e[r++]=s,s>>=8,e[r++]=s,s>>=8,e[r++]=s,s>>=8,e[r++]=s;let i=Number(t>>BigInt(32)&BigInt(4294967295));return e[r++]=i,i>>=8,e[r++]=i,i>>=8,e[r++]=i,i>>=8,e[r++]=i,r}function x(e,t,r,n,o){j(t,n,o,e,r,7);let s=Number(t&BigInt(4294967295));e[r+7]=s,s>>=8,e[r+6]=s,s>>=8,e[r+5]=s,s>>=8,e[r+4]=s;let i=Number(t>>BigInt(32)&BigInt(4294967295));return e[r+3]=i,i>>=8,e[r+2]=i,i>>=8,e[r+1]=i,i>>=8,e[r]=i,r+8}function N(e,t,r,n,o,s){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function U(e,t,r,n,s){return t=+t,r>>>=0,s||N(e,0,r,4),o.write(e,t,r,n,23,4),r+4}function k(e,t,r,n,s){return t=+t,r>>>=0,s||N(e,0,r,8),o.write(e,t,r,n,52,8),r+8}c.prototype.slice=function(e,t){const r=this.length;(e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t<e&&(t=e);const n=this.subarray(e,t);return Object.setPrototypeOf(n,c.prototype),n},c.prototype.readUintLE=c.prototype.readUIntLE=function(e,t,r){e>>>=0,t>>>=0,r||F(e,t,this.length);let n=this[e],o=1,s=0;for(;++s<t&&(o*=256);)n+=this[e+s]*o;return n},c.prototype.readUintBE=c.prototype.readUIntBE=function(e,t,r){e>>>=0,t>>>=0,r||F(e,t,this.length);let n=this[e+--t],o=1;for(;t>0&&(o*=256);)n+=this[e+--t]*o;return n},c.prototype.readUint8=c.prototype.readUInt8=function(e,t){return e>>>=0,t||F(e,1,this.length),this[e]},c.prototype.readUint16LE=c.prototype.readUInt16LE=function(e,t){return e>>>=0,t||F(e,2,this.length),this[e]|this[e+1]<<8},c.prototype.readUint16BE=c.prototype.readUInt16BE=function(e,t){return e>>>=0,t||F(e,2,this.length),this[e]<<8|this[e+1]},c.prototype.readUint32LE=c.prototype.readUInt32LE=function(e,t){return e>>>=0,t||F(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},c.prototype.readUint32BE=c.prototype.readUInt32BE=function(e,t){return e>>>=0,t||F(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},c.prototype.readBigUInt64LE=X(function(e){$(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||V(e,this.length-8);const n=t+256*this[++e]+65536*this[++e]+this[++e]*2**24,o=this[++e]+256*this[++e]+65536*this[++e]+r*2**24;return BigInt(n)+(BigInt(o)<<BigInt(32))}),c.prototype.readBigUInt64BE=X(function(e){$(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||V(e,this.length-8);const n=t*2**24+65536*this[++e]+256*this[++e]+this[++e],o=this[++e]*2**24+65536*this[++e]+256*this[++e]+r;return(BigInt(n)<<BigInt(32))+BigInt(o)}),c.prototype.readIntLE=function(e,t,r){e>>>=0,t>>>=0,r||F(e,t,this.length);let n=this[e],o=1,s=0;for(;++s<t&&(o*=256);)n+=this[e+s]*o;return o*=128,n>=o&&(n-=Math.pow(2,8*t)),n},c.prototype.readIntBE=function(e,t,r){e>>>=0,t>>>=0,r||F(e,t,this.length);let n=t,o=1,s=this[e+--n];for(;n>0&&(o*=256);)s+=this[e+--n]*o;return o*=128,s>=o&&(s-=Math.pow(2,8*t)),s},c.prototype.readInt8=function(e,t){return e>>>=0,t||F(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},c.prototype.readInt16LE=function(e,t){e>>>=0,t||F(e,2,this.length);const r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},c.prototype.readInt16BE=function(e,t){e>>>=0,t||F(e,2,this.length);const r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},c.prototype.readInt32LE=function(e,t){return e>>>=0,t||F(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},c.prototype.readInt32BE=function(e,t){return e>>>=0,t||F(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},c.prototype.readBigInt64LE=X(function(e){$(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||V(e,this.length-8);const n=this[e+4]+256*this[e+5]+65536*this[e+6]+(r<<24);return(BigInt(n)<<BigInt(32))+BigInt(t+256*this[++e]+65536*this[++e]+this[++e]*2**24)}),c.prototype.readBigInt64BE=X(function(e){$(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||V(e,this.length-8);const n=(t<<24)+65536*this[++e]+256*this[++e]+this[++e];return(BigInt(n)<<BigInt(32))+BigInt(this[++e]*2**24+65536*this[++e]+256*this[++e]+r)}),c.prototype.readFloatLE=function(e,t){return e>>>=0,t||F(e,4,this.length),o.read(this,e,!0,23,4)},c.prototype.readFloatBE=function(e,t){return e>>>=0,t||F(e,4,this.length),o.read(this,e,!1,23,4)},c.prototype.readDoubleLE=function(e,t){return e>>>=0,t||F(e,8,this.length),o.read(this,e,!0,52,8)},c.prototype.readDoubleBE=function(e,t){return e>>>=0,t||F(e,8,this.length),o.read(this,e,!1,52,8)},c.prototype.writeUintLE=c.prototype.writeUIntLE=function(e,t,r,n){e=+e,t>>>=0,r>>>=0,n||R(this,e,t,r,Math.pow(2,8*r)-1,0);let o=1,s=0;for(this[t]=255&e;++s<r&&(o*=256);)this[t+s]=e/o&255;return t+r},c.prototype.writeUintBE=c.prototype.writeUIntBE=function(e,t,r,n){e=+e,t>>>=0,r>>>=0,n||R(this,e,t,r,Math.pow(2,8*r)-1,0);let o=r-1,s=1;for(this[t+o]=255&e;--o>=0&&(s*=256);)this[t+o]=e/s&255;return t+r},c.prototype.writeUint8=c.prototype.writeUInt8=function(e,t,r){return e=+e,t>>>=0,r||R(this,e,t,1,255,0),this[t]=255&e,t+1},c.prototype.writeUint16LE=c.prototype.writeUInt16LE=function(e,t,r){return e=+e,t>>>=0,r||R(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},c.prototype.writeUint16BE=c.prototype.writeUInt16BE=function(e,t,r){return e=+e,t>>>=0,r||R(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},c.prototype.writeUint32LE=c.prototype.writeUInt32LE=function(e,t,r){return e=+e,t>>>=0,r||R(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},c.prototype.writeUint32BE=c.prototype.writeUInt32BE=function(e,t,r){return e=+e,t>>>=0,r||R(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},c.prototype.writeBigUInt64LE=X(function(e){return _(this,e,arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,BigInt(0),BigInt("0xffffffffffffffff"))}),c.prototype.writeBigUInt64BE=X(function(e){return x(this,e,arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,BigInt(0),BigInt("0xffffffffffffffff"))}),c.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t>>>=0,!n){const n=Math.pow(2,8*r-1);R(this,e,t,r,n-1,-n)}let o=0,s=1,i=0;for(this[t]=255&e;++o<r&&(s*=256);)e<0&&0===i&&0!==this[t+o-1]&&(i=1),this[t+o]=(e/s|0)-i&255;return t+r},c.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t>>>=0,!n){const n=Math.pow(2,8*r-1);R(this,e,t,r,n-1,-n)}let o=r-1,s=1,i=0;for(this[t+o]=255&e;--o>=0&&(s*=256);)e<0&&0===i&&0!==this[t+o+1]&&(i=1),this[t+o]=(e/s|0)-i&255;return t+r},c.prototype.writeInt8=function(e,t,r){return e=+e,t>>>=0,r||R(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},c.prototype.writeInt16LE=function(e,t,r){return e=+e,t>>>=0,r||R(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},c.prototype.writeInt16BE=function(e,t,r){return e=+e,t>>>=0,r||R(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},c.prototype.writeInt32LE=function(e,t,r){return e=+e,t>>>=0,r||R(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},c.prototype.writeInt32BE=function(e,t,r){return e=+e,t>>>=0,r||R(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},c.prototype.writeBigInt64LE=X(function(e){return _(this,e,arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),c.prototype.writeBigInt64BE=X(function(e){return x(this,e,arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),c.prototype.writeFloatLE=function(e,t,r){return U(this,e,t,!0,r)},c.prototype.writeFloatBE=function(e,t,r){return U(this,e,t,!1,r)},c.prototype.writeDoubleLE=function(e,t,r){return k(this,e,t,!0,r)},c.prototype.writeDoubleBE=function(e,t,r){return k(this,e,t,!1,r)},c.prototype.copy=function(e,t,r,n){if(!c.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),n>0&&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);const o=n-r;return this===e&&"function"==typeof Uint8Array.prototype.copyWithin?this.copyWithin(t,r,n):Uint8Array.prototype.set.call(e,this.subarray(r,n),t),o},c.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&&!c.isEncoding(n))throw new TypeError("Unknown encoding: "+n);if(1===e.length){const t=e.charCodeAt(0);("utf8"===n&&t<128||"latin1"===n)&&(e=t)}}else"number"==typeof e?e&=255:"boolean"==typeof e&&(e=Number(e));if(t<0||this.length<t||this.length<r)throw new RangeError("Out of range index");if(r<=t)return this;let o;if(t>>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(o=t;o<r;++o)this[o]=e;else{const s=c.isBuffer(e)?e:c.from(e,n),i=s.length;if(0===i)throw new TypeError('The value "'+e+'" is invalid for argument "value"');for(o=0;o<r-t;++o)this[o+t]=s[o%i]}return this};const D={};function L(e,t,r){D[e]=class extends r{constructor(){super(),Object.defineProperty(this,"message",{value:t.apply(this,arguments),writable:!0,configurable:!0}),this.name="".concat(this.name," [").concat(e,"]"),this.stack,delete this.name}get code(){return e}set code(e){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:e,writable:!0})}toString(){return"".concat(this.name," [").concat(e,"]: ").concat(this.message)}}}function z(e){let t="",r=e.length;const n="-"===e[0]?1:0;for(;r>=n+4;r-=3)t="_".concat(e.slice(r-3,r)).concat(t);return"".concat(e.slice(0,r)).concat(t)}function j(e,t,r,n,o,s){if(e>r||e<t){const n="bigint"==typeof t?"n":"";let o;throw o=s>3?0===t||t===BigInt(0)?">= 0".concat(n," and < 2").concat(n," ** ").concat(8*(s+1)).concat(n):">= -(2".concat(n," ** ").concat(8*(s+1)-1).concat(n,") and < 2 ** ")+"".concat(8*(s+1)-1).concat(n):">= ".concat(t).concat(n," and <= ").concat(r).concat(n),new D.ERR_OUT_OF_RANGE("value",o,e)}!function(e,t,r){$(t,"offset"),void 0!==e[t]&&void 0!==e[t+r]||V(t,e.length-(r+1))}(n,o,s)}function $(e,t){if("number"!=typeof e)throw new D.ERR_INVALID_ARG_TYPE(t,"number",e)}function V(e,t,r){if(Math.floor(e)!==e)throw $(e,r),new D.ERR_OUT_OF_RANGE(r||"offset","an integer",e);if(t<0)throw new D.ERR_BUFFER_OUT_OF_BOUNDS;throw new D.ERR_OUT_OF_RANGE(r||"offset",">= ".concat(r?1:0," and <= ").concat(t),e)}L("ERR_BUFFER_OUT_OF_BOUNDS",function(e){return e?"".concat(e," is outside of buffer bounds"):"Attempt to access memory outside buffer bounds"},RangeError),L("ERR_INVALID_ARG_TYPE",function(e,t){return'The "'.concat(e,'" argument must be of type number. Received type ').concat(typeof t)},TypeError),L("ERR_OUT_OF_RANGE",function(e,t,r){let n='The value of "'.concat(e,'" is out of range.'),o=r;return Number.isInteger(r)&&Math.abs(r)>2**32?o=z(String(r)):"bigint"==typeof r&&(o=String(r),(r>BigInt(2)**BigInt(32)||r<-(BigInt(2)**BigInt(32)))&&(o=z(o)),o+="n"),n+=" It must be ".concat(t,". Received ").concat(o),n},RangeError);const G=/[^+/0-9A-Za-z-_]/g;function H(e,t){let r;t=t||1/0;const n=e.length;let o=null;const s=[];for(let i=0;i<n;++i){if(r=e.charCodeAt(i),r>55295&&r<57344){if(!o){if(r>56319){(t-=3)>-1&&s.push(239,191,189);continue}if(i+1===n){(t-=3)>-1&&s.push(239,191,189);continue}o=r;continue}if(r<56320){(t-=3)>-1&&s.push(239,191,189),o=r;continue}r=65536+(o-55296<<10|r-56320)}else o&&(t-=3)>-1&&s.push(239,191,189);if(o=null,r<128){if((t-=1)<0)break;s.push(r)}else if(r<2048){if((t-=2)<0)break;s.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;s.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;s.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return s}function K(e){return n.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(G,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function Z(e,t,r,n){let o;for(o=0;o<n&&!(o+r>=t.length||o>=e.length);++o)t[o+r]=e[o];return o}function q(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function Y(e){return e!=e}const J=function(){const e="0123456789abcdef",t=new Array(256);for(let r=0;r<16;++r){const n=16*r;for(let o=0;o<16;++o)t[n+o]=e[r]+e[o]}return t}();function X(e){return"undefined"==typeof BigInt?Q:e}function Q(){throw new Error("BigInt not supported")}},3788(e){"use strict";var t=Object.prototype.hasOwnProperty,r="~";function n(){}function o(e,t,r){this.fn=e,this.context=t,this.once=r||!1}function s(e,t,n,s,i){if("function"!=typeof n)throw new TypeError("The listener must be a function");var a=new o(n,s||e,i),c=r?r+t:t;return e._events[c]?e._events[c].fn?e._events[c]=[e._events[c],a]:e._events[c].push(a):(e._events[c]=a,e._eventsCount++),e}function i(e,t){0===--e._eventsCount?e._events=new n:delete e._events[t]}function a(){this._events=new n,this._eventsCount=0}Object.create&&(n.prototype=Object.create(null),(new n).__proto__||(r=!1)),a.prototype.eventNames=function(){var e,n,o=[];if(0===this._eventsCount)return o;for(n in e=this._events)t.call(e,n)&&o.push(r?n.slice(1):n);return Object.getOwnPropertySymbols?o.concat(Object.getOwnPropertySymbols(e)):o},a.prototype.listeners=function(e){var t=r?r+e:e,n=this._events[t];if(!n)return[];if(n.fn)return[n.fn];for(var o=0,s=n.length,i=new Array(s);o<s;o++)i[o]=n[o].fn;return i},a.prototype.listenerCount=function(e){var t=r?r+e:e,n=this._events[t];return n?n.fn?1:n.length:0},a.prototype.emit=function(e,t,n,o,s,i){var a=r?r+e:e;if(!this._events[a])return!1;var c,u,l=this._events[a],d=arguments.length;if(l.fn){switch(l.once&&this.removeListener(e,l.fn,void 0,!0),d){case 1:return l.fn.call(l.context),!0;case 2:return l.fn.call(l.context,t),!0;case 3:return l.fn.call(l.context,t,n),!0;case 4:return l.fn.call(l.context,t,n,o),!0;case 5:return l.fn.call(l.context,t,n,o,s),!0;case 6:return l.fn.call(l.context,t,n,o,s,i),!0}for(u=1,c=new Array(d-1);u<d;u++)c[u-1]=arguments[u];l.fn.apply(l.context,c)}else{var p,f=l.length;for(u=0;u<f;u++)switch(l[u].once&&this.removeListener(e,l[u].fn,void 0,!0),d){case 1:l[u].fn.call(l[u].context);break;case 2:l[u].fn.call(l[u].context,t);break;case 3:l[u].fn.call(l[u].context,t,n);break;case 4:l[u].fn.call(l[u].context,t,n,o);break;default:if(!c)for(p=1,c=new Array(d-1);p<d;p++)c[p-1]=arguments[p];l[u].fn.apply(l[u].context,c)}}return!0},a.prototype.on=function(e,t,r){return s(this,e,t,r,!1)},a.prototype.once=function(e,t,r){return s(this,e,t,r,!0)},a.prototype.removeListener=function(e,t,n,o){var s=r?r+e:e;if(!this._events[s])return this;if(!t)return i(this,s),this;var a=this._events[s];if(a.fn)a.fn!==t||o&&!a.once||n&&a.context!==n||i(this,s);else{for(var c=0,u=[],l=a.length;c<l;c++)(a[c].fn!==t||o&&!a[c].once||n&&a[c].context!==n)&&u.push(a[c]);u.length?this._events[s]=1===u.length?u[0]:u:i(this,s)}return this},a.prototype.removeAllListeners=function(e){var t;return e?(t=r?r+e:e,this._events[t]&&i(this,t)):(this._events=new n,this._eventsCount=0),this},a.prototype.off=a.prototype.removeListener,a.prototype.addListener=a.prototype.on,a.prefixed=r,a.EventEmitter=a,e.exports=a},2835(e,t,r){var n="function"==typeof Object.defineProperties?Object.defineProperty:function(e,t,r){e!=Array.prototype&&e!=Object.prototype&&(e[t]=r.value)},o="undefined"!=typeof window&&window===this?this:void 0!==r.g&&null!=r.g?r.g:this;function s(){s=function(){},o.Symbol||(o.Symbol=c)}function i(e,t){this.a=e,n(this,"description",{configurable:!0,writable:!0,value:t})}i.prototype.toString=function(){return this.a};var a,c=(a=0,function e(t){if(this instanceof e)throw new TypeError("Symbol is not a constructor");return new i("jscomp_symbol_"+(t||"")+"_"+a++,t)});function u(){s();var e=o.Symbol.iterator;e||(e=o.Symbol.iterator=o.Symbol("Symbol.iterator")),"function"!=typeof Array.prototype[e]&&n(Array.prototype,e,{configurable:!0,writable:!0,value:function(){return function(e){return u(),(e={next:e})[o.Symbol.iterator]=function(){return this},e}(function(e){var t=0;return function(){return t<e.length?{done:!1,value:e[t++]}:{done:!0}}}(this))}}),u=function(){}}!function(e,t){if(t){var r=o;e=e.split(".");for(var s=0;s<e.length-1;s++){var i=e[s];i in r||(r[i]={}),r=r[i]}(t=t(s=r[e=e[e.length-1]]))!=s&&null!=t&&n(r,e,{configurable:!0,writable:!0,value:t})}}("Array.prototype.entries",function(e){return e||function(){return function(e,t){u(),e instanceof String&&(e+="");var r=0,n={next:function(){if(r<e.length){var o=r++;return{value:t(o,e[o]),done:!1}}return n.next=function(){return{done:!0,value:void 0}},n.next()}};return n[Symbol.iterator]=function(){return n},n}(this,function(e,t){return[e,t]})}});var l=this||self;function d(e,t,r){e=e.split("."),r=r||l,e[0]in r||void 0===r.execScript||r.execScript("var "+e[0]);for(var n;e.length&&(n=e.shift());)e.length||void 0===t?r=r[n]&&r[n]!==Object.prototype[n]?r[n]:r[n]={}:r[n]=t}function p(e){var t=typeof e;if("object"==t){if(!e)return"null";if(e instanceof Array)return"array";if(e instanceof Object)return t;var r=Object.prototype.toString.call(e);if("[object Window]"==r)return"object";if("[object Array]"==r||"number"==typeof e.length&&void 0!==e.splice&&void 0!==e.propertyIsEnumerable&&!e.propertyIsEnumerable("splice"))return"array";if("[object Function]"==r||void 0!==e.call&&void 0!==e.propertyIsEnumerable&&!e.propertyIsEnumerable("call"))return"function"}else if("function"==t&&void 0===e.call)return"object";return t}function f(e){var t=typeof e;return"object"==t&&null!=e||"function"==t}var h="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" "),g=Array.prototype.forEach?function(e,t){Array.prototype.forEach.call(e,t,void 0)}:function(e,t){for(var r=e.length,n="string"==typeof e?e.split(""):e,o=0;o<r;o++)o in n&&t.call(void 0,n[o],o,e)},y=Array.prototype.map?function(e,t){return Array.prototype.map.call(e,t,void 0)}:function(e,t){for(var r=e.length,n=Array(r),o="string"==typeof e?e.split(""):e,s=0;s<r;s++)s in o&&(n[s]=t.call(void 0,o[s],s,e));return n};function b(e,t,r){return 2>=arguments.length?Array.prototype.slice.call(e,t):Array.prototype.slice.call(e,t,r)}function m(e,t,r,n){var o="Assertion failed";if(r){o+=": "+r;var s=n}else e&&(o+=": "+e,s=t);throw Error(o,s||[])}function T(e,t,r){for(var n=[],o=2;o<arguments.length;++o)n[o-2]=arguments[o];return e||m("",null,t,n),e}function w(e,t){for(var r=[],n=1;n<arguments.length;++n)r[n-1]=arguments[n];throw Error("Failure"+(e?": "+e:""),r)}function A(e,t,r,n){for(var o=[],s=3;s<arguments.length;++s)o[s-3]=arguments[s];e instanceof t||m("Expected instanceof %s but got %s.",[P(t),P(e)],r,o)}function P(e){return e instanceof Function?e.displayName||e.name||"unknown type name":e instanceof Object?e.constructor.displayName||e.constructor.name||Object.prototype.toString.call(e):null===e?"null":typeof e}function v(e,t){if(this.c=e,this.b=t,this.a={},this.arrClean=!0,0<this.c.length){for(e=0;e<this.c.length;e++){var r=(t=this.c[e])[0];this.a[r.toString()]=new C(r,t[1])}this.arrClean=!0}}function W(e){this.a=0,this.b=e}function B(e,t){return e.b?(t.a||(t.a=new e.b(t.value)),t.a):t.value}function E(e){e=e.a;var t,r=[];for(t in e)Object.prototype.hasOwnProperty.call(e,t)&&r.push(t);return r}function C(e,t){this.key=e,this.value=t,this.a=void 0}function I(e){if(8192>=e.length)return String.fromCharCode.apply(null,e);for(var t="",r=0;r<e.length;r+=8192)t+=String.fromCharCode.apply(null,b(e,r,r+8192));return t}d("jspb.Map",v,void 0),v.prototype.g=function(){if(this.arrClean){if(this.b){var e,t=this.a;for(e in t)if(Object.prototype.hasOwnProperty.call(t,e)){var r=t[e].a;r&&r.g()}}}else{for(this.c.length=0,(t=E(this)).sort(),e=0;e<t.length;e++){var n=this.a[t[e]];(r=n.a)&&r.g(),this.c.push([n.key,n.value])}this.arrClean=!0}return this.c},v.prototype.toArray=v.prototype.g,v.prototype.Mc=function(e,t){for(var r=this.g(),n=[],o=0;o<r.length;o++){var s=this.a[r[o][0].toString()];B(this,s);var i=s.a;i?(T(t),n.push([s.key,t(e,i)])):n.push([s.key,s.value])}return n},v.prototype.toObject=v.prototype.Mc,v.fromObject=function(e,t,r){t=new v([],t);for(var n=0;n<e.length;n++){var o=e[n][0],s=r(e[n][1]);t.set(o,s)}return t},W.prototype.next=function(){return this.a<this.b.length?{done:!1,value:this.b[this.a++]}:{done:!0,value:void 0}},"undefined"!=typeof Symbol&&(W.prototype[Symbol.iterator]=function(){return this}),v.prototype.Jb=function(){return E(this).length},v.prototype.getLength=v.prototype.Jb,v.prototype.clear=function(){this.a={},this.arrClean=!1},v.prototype.clear=v.prototype.clear,v.prototype.Cb=function(e){e=e.toString();var t=this.a.hasOwnProperty(e);return delete this.a[e],this.arrClean=!1,t},v.prototype.del=v.prototype.Cb,v.prototype.Eb=function(){var e=[],t=E(this);t.sort();for(var r=0;r<t.length;r++){var n=this.a[t[r]];e.push([n.key,n.value])}return e},v.prototype.getEntryList=v.prototype.Eb,v.prototype.entries=function(){var e=[],t=E(this);t.sort();for(var r=0;r<t.length;r++){var n=this.a[t[r]];e.push([n.key,B(this,n)])}return new W(e)},v.prototype.entries=v.prototype.entries,v.prototype.keys=function(){var e=[],t=E(this);t.sort();for(var r=0;r<t.length;r++)e.push(this.a[t[r]].key);return new W(e)},v.prototype.keys=v.prototype.keys,v.prototype.values=function(){var e=[],t=E(this);t.sort();for(var r=0;r<t.length;r++)e.push(B(this,this.a[t[r]]));return new W(e)},v.prototype.values=v.prototype.values,v.prototype.forEach=function(e,t){var r=E(this);r.sort();for(var n=0;n<r.length;n++){var o=this.a[r[n]];e.call(t,B(this,o),o.key,this)}},v.prototype.forEach=v.prototype.forEach,v.prototype.set=function(e,t){var r=new C(e);return this.b?(r.a=t,r.value=t.g()):r.value=t,this.a[e.toString()]=r,this.arrClean=!1,this},v.prototype.set=v.prototype.set,v.prototype.get=function(e){if(e=this.a[e.toString()])return B(this,e)},v.prototype.get=v.prototype.get,v.prototype.has=function(e){return e.toString()in this.a},v.prototype.has=v.prototype.has,v.prototype.Jc=function(e,t,r,n,o){var s=E(this);s.sort();for(var i=0;i<s.length;i++){var a=this.a[s[i]];t.Va(e),r.call(t,1,a.key),this.b?n.call(t,2,B(this,a),o):n.call(t,2,a.value),t.Ya()}},v.prototype.serializeBinary=v.prototype.Jc,v.deserializeBinary=function(e,t,r,n,o,s,i){for(;t.oa()&&!t.bb();){var a=t.c;1==a?s=r.call(t):2==a&&(e.b?(T(o),i||(i=new e.b),n.call(t,i,o)):i=n.call(t))}T(null!=s),T(null!=i),e.set(s,i)};var O={"\0":"\\0","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","\t":"\\t","\v":"\\x0B",'"':'\\"',"\\":"\\\\","<":"\\u003C"},S={"'":"\\'"},M={},F=null;function R(e,t){void 0===t&&(t=0),x(),t=M[t];for(var r=[],n=0;n<e.length;n+=3){var o=e[n],s=n+1<e.length,i=s?e[n+1]:0,a=n+2<e.length,c=a?e[n+2]:0,u=o>>2;o=(3&o)<<4|i>>4,i=(15&i)<<2|c>>6,c&=63,a||(c=64,s||(i=64)),r.push(t[u],t[o],t[i]||"",t[c]||"")}return r.join("")}function _(e){var t=e.length,r=3*t/4;r%3?r=Math.floor(r):-1!="=.".indexOf(e[t-1])&&(r=-1!="=.".indexOf(e[t-2])?r-2:r-1);var n=new Uint8Array(r),o=0;return function(e,t){function r(t){for(;n<e.length;){var r=e.charAt(n++),o=F[r];if(null!=o)return o;if(!/^[\s\xa0]*$/.test(r))throw Error("Unknown base64 encoding at char: "+r)}return t}x();for(var n=0;;){var o=r(-1),s=r(0),i=r(64),a=r(64);if(64===a&&-1===o)break;t(o<<2|s>>4),64!=i&&(t(s<<4&240|i>>2),64!=a&&t(i<<6&192|a))}}(e,function(e){n[o++]=e}),n.subarray(0,o)}function x(){if(!F){F={};for(var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789".split(""),t=["+/=","+/","-_=","-_.","-_"],r=0;5>r;r++){var n=e.concat(t[r].split(""));M[r]=n;for(var o=0;o<n.length;o++){var s=n[o];void 0===F[s]&&(F[s]=o)}}}}d("jspb.ConstBinaryMessage",function(){},void 0),d("jspb.BinaryMessage",function(){},void 0),d("jspb.BinaryConstants.FieldType",{yb:-1,ee:1,FLOAT:2,ke:3,te:4,je:5,xb:6,wb:7,BOOL:8,re:9,ie:10,le:11,ce:12,se:13,ge:14,me:15,ne:16,oe:17,pe:18,he:30,ve:31},void 0),d("jspb.BinaryConstants.WireType",{yb:-1,ue:0,xb:1,de:2,qe:3,fe:4,wb:5},void 0),d("jspb.BinaryConstants.FieldTypeToWireType",function(e){switch(e){case 5:case 3:case 13:case 4:case 17:case 18:case 8:case 14:case 31:return 0;case 1:case 6:case 16:case 30:return 1;case 9:case 11:case 12:return 2;case 2:case 7:case 15:return 5;default:return-1}},void 0),d("jspb.BinaryConstants.INVALID_FIELD_NUMBER",-1,void 0),d("jspb.BinaryConstants.FLOAT32_EPS",1401298464324817e-60,void 0),d("jspb.BinaryConstants.FLOAT32_MIN",11754943508222875e-54,void 0),d("jspb.BinaryConstants.FLOAT32_MAX",34028234663852886e22,void 0),d("jspb.BinaryConstants.FLOAT64_EPS",5e-324,void 0),d("jspb.BinaryConstants.FLOAT64_MIN",22250738585072014e-324,void 0),d("jspb.BinaryConstants.FLOAT64_MAX",17976931348623157e292,void 0),d("jspb.BinaryConstants.TWO_TO_20",1048576,void 0),d("jspb.BinaryConstants.TWO_TO_23",8388608,void 0),d("jspb.BinaryConstants.TWO_TO_31",2147483648,void 0),d("jspb.BinaryConstants.TWO_TO_32",4294967296,void 0),d("jspb.BinaryConstants.TWO_TO_52",4503599627370496,void 0),d("jspb.BinaryConstants.TWO_TO_63",0x8000000000000000,void 0),d("jspb.BinaryConstants.TWO_TO_64",0x10000000000000000,void 0),d("jspb.BinaryConstants.ZERO_HASH","\0\0\0\0\0\0\0\0",void 0);var N=0,U=0;function k(e){var t=e>>>0;e=Math.floor((e-t)/4294967296)>>>0,N=t,U=e}function D(e){var t=0>e,r=(e=Math.abs(e))>>>0;e=Math.floor((e-r)/4294967296),e>>>=0,t&&(e=~e>>>0,4294967295<(r=(~r>>>0)+1)&&(r=0,4294967295<++e&&(e=0))),N=r,U=e}function L(e){var t=0>e;k(e=2*Math.abs(e)),e=N;var r=U;t&&(0==e?0==r?r=e=4294967295:(r--,e=4294967295):e--),N=e,U=r}function z(e){var t=0>e?1:0;if(0===(e=t?-e:e))0<1/e?N=U=0:(U=0,N=2147483648);else if(isNaN(e))U=0,N=2147483647;else if(34028234663852886e22<e)U=0,N=(t<<31|2139095040)>>>0;else if(11754943508222875e-54>e)e=Math.round(e/Math.pow(2,-149)),U=0,N=(t<<31|e)>>>0;else{var r=Math.floor(Math.log(e)/Math.LN2);e*=Math.pow(2,-r),16777216<=(e=Math.round(8388608*e))&&++r,U=0,N=(t<<31|r+127<<23|8388607&e)>>>0}}function j(e){var t=0>e?1:0;if(0===(e=t?-e:e))U=0<1/e?0:2147483648,N=0;else if(isNaN(e))U=2147483647,N=4294967295;else if(17976931348623157e292<e)U=(t<<31|2146435072)>>>0,N=0;else if(22250738585072014e-324>e)e/=Math.pow(2,-1074),U=(t<<31|e/4294967296)>>>0,N=e>>>0;else{var r=e,n=0;if(2<=r)for(;2<=r&&1023>n;)n++,r/=2;else for(;1>r&&-1022<n;)r*=2,n--;e*=Math.pow(2,-n),U=(t<<31|n+1023<<20|1048576*e&1048575)>>>0,N=4503599627370496*e>>>0}}function $(e){var t=e.charCodeAt(4),r=e.charCodeAt(5),n=e.charCodeAt(6),o=e.charCodeAt(7);N=e.charCodeAt(0)+(e.charCodeAt(1)<<8)+(e.charCodeAt(2)<<16)+(e.charCodeAt(3)<<24)>>>0,U=t+(r<<8)+(n<<16)+(o<<24)>>>0}function V(e,t){return 4294967296*t+(e>>>0)}function G(e,t){var r=2147483648&t;return r&&(t=~t>>>0,0==(e=1+~e>>>0)&&(t=t+1>>>0)),e=V(e,t),r?-e:e}function H(e,t,r){var n=t>>31;return r(e<<1^n,(t<<1|e>>>31)^n)}function K(e,t){return Z(e,t,G)}function Z(e,t,r){var n=-(1&e);return r((e>>>1|t<<31)^n,t>>>1^n)}function q(e){var t=2*(e>>31)+1,r=e>>>23&255;return e&=8388607,255==r?e?NaN:1/0*t:0==r?t*Math.pow(2,-149)*e:t*Math.pow(2,r-150)*(e+Math.pow(2,23))}function Y(e,t){var r=2*(t>>31)+1,n=t>>>20&2047;return e=4294967296*(1048575&t)+e,2047==n?e?NaN:1/0*r:0==n?r*Math.pow(2,-1074)*e:r*Math.pow(2,n-1075)*(e+4503599627370496)}function J(e,t){return String.fromCharCode(e>>>0&255,e>>>8&255,e>>>16&255,e>>>24&255,t>>>0&255,t>>>8&255,t>>>16&255,t>>>24&255)}function X(e,t){function r(e,t){return e=e?String(e):"",t?"0000000".slice(e.length)+e:e}if(2097151>=t)return""+V(e,t);var n=(e>>>24|t<<8)>>>0&16777215;return e=(16777215&e)+6777216*n+6710656*(t=t>>16&65535),n+=8147497*t,t*=2,1e7<=e&&(n+=Math.floor(e/1e7),e%=1e7),1e7<=n&&(t+=Math.floor(n/1e7),n%=1e7),r(t,0)+r(n,t)+r(e,1)}function Q(e,t){var r=2147483648&t;return r&&(t=~t+(0==(e=1+~e>>>0)?1:0)>>>0),e=X(e,t),r?"-"+e:e}function ee(e,t){$(e),e=N;var r=U;return t?Q(e,r):X(e,r)}function te(e){function t(e,t){for(var r=0;8>r&&(1!==e||0<t);r++)t=e*n[r]+t,n[r]=255&t,t>>>=8}T(0<e.length);var r=!1;"-"===e[0]&&(r=!0,e=e.slice(1));for(var n=[0,0,0,0,0,0,0,0],o=0;o<e.length;o++)t(10,e.charCodeAt(o)-48);return r&&(function(){for(var e=0;8>e;e++)n[e]=255&~n[e]}(),t(1,1)),I(n)}function re(e){return String.fromCharCode(10>e?48+e:87+e)}function ne(e){return 97<=e?e-97+10:e-48}function oe(e,t,r,n,o){var s=0;if(128>n)for(;t<r&&e[t++]==n;)s++,t+=o;else for(;t<r;){for(var i=n;128<i;){if(e[t++]!=(127&i|128))return s;i>>=7}if(e[t++]!=i)break;s++,t+=o}return s}function se(e){return e.constructor===Uint8Array?e:e.constructor===ArrayBuffer||e.constructor===Array?new Uint8Array(e):e.constructor===String?_(e):e instanceof Uint8Array?new Uint8Array(e.buffer,e.byteOffset,e.byteLength):(w("Type not convertible to Uint8Array."),new Uint8Array(0))}function ie(e,t,r){this.b=null,this.a=this.c=this.h=0,this.v=!1,e&&this.H(e,t,r)}d("jspb.utils.getSplit64Low",function(){return N},void 0),d("jspb.utils.getSplit64High",function(){return U},void 0),d("jspb.utils.splitUint64",k,void 0),d("jspb.utils.splitInt64",D,void 0),d("jspb.utils.splitZigzag64",L,void 0),d("jspb.utils.splitFloat32",z,void 0),d("jspb.utils.splitFloat64",j,void 0),d("jspb.utils.splitHash64",$,void 0),d("jspb.utils.joinUint64",V,void 0),d("jspb.utils.joinInt64",G,void 0),d("jspb.utils.toZigzag64",H,void 0),d("jspb.utils.joinZigzag64",K,void 0),d("jspb.utils.fromZigzag64",Z,void 0),d("jspb.utils.joinFloat32",q,void 0),d("jspb.utils.joinFloat64",Y,void 0),d("jspb.utils.joinHash64",J,void 0),d("jspb.utils.DIGITS","0123456789abcdef".split(""),void 0),d("jspb.utils.joinUnsignedDecimalString",X,void 0),d("jspb.utils.joinSignedDecimalString",Q,void 0),d("jspb.utils.hash64ToDecimalString",ee,void 0),d("jspb.utils.hash64ArrayToDecimalStrings",function(e,t){for(var r=Array(e.length),n=0;n<e.length;n++)r[n]=ee(e[n],t);return r},void 0),d("jspb.utils.decimalStringToHash64",te,void 0),d("jspb.utils.splitDecimalString",function(e){$(te(e))},void 0),d("jspb.utils.hash64ToHexString",function(e){var t=Array(18);t[0]="0",t[1]="x";for(var r=0;8>r;r++){var n=e.charCodeAt(7-r);t[2*r+2]=re(n>>4),t[2*r+3]=re(15&n)}return t.join("")},void 0),d("jspb.utils.hexStringToHash64",function(e){T(18==(e=e.toLowerCase()).length),T("0"==e[0]),T("x"==e[1]);for(var t="",r=0;8>r;r++)t=String.fromCharCode(16*ne(e.charCodeAt(2*r+2))+ne(e.charCodeAt(2*r+3)))+t;return t},void 0),d("jspb.utils.hash64ToNumber",function(e,t){$(e),e=N;var r=U;return t?G(e,r):V(e,r)},void 0),d("jspb.utils.numberToHash64",function(e){return D(e),J(N,U)},void 0),d("jspb.utils.countVarints",function(e,t,r){for(var n=0,o=t;o<r;o++)n+=e[o]>>7;return r-t-n},void 0),d("jspb.utils.countVarintFields",function(e,t,r,n){var o=0;if(128>(n*=8))for(;t<r&&e[t++]==n;)for(o++;;){var s=e[t++];if(!(128&s))break}else for(;t<r;){for(s=n;128<s;){if(e[t]!=(127&s|128))return o;t++,s>>=7}if(e[t++]!=s)break;for(o++;128&(s=e[t++]););}return o},void 0),d("jspb.utils.countFixed32Fields",function(e,t,r,n){return oe(e,t,r,8*n+5,4)},void 0),d("jspb.utils.countFixed64Fields",function(e,t,r,n){return oe(e,t,r,8*n+1,8)},void 0),d("jspb.utils.countDelimitedFields",function(e,t,r,n){var o=0;for(n=8*n+2;t<r;){for(var s=n;128<s;){if(e[t++]!=(127&s|128))return o;s>>=7}if(e[t++]!=s)break;o++;for(var i=0,a=1;i+=(127&(s=e[t++]))*a,a*=128,128&s;);t+=i}return o},void 0),d("jspb.utils.debugBytesToTextFormat",function(e){var t='"';if(e){e=se(e);for(var r=0;r<e.length;r++)t+="\\x",16>e[r]&&(t+="0"),t+=e[r].toString(16)}return t+'"'},void 0),d("jspb.utils.debugScalarToTextFormat",function(e){if("string"==typeof e){e=String(e);for(var t=['"'],r=0;r<e.length;r++){var n,o=e.charAt(r),s=o.charCodeAt(0),i=r+1;(n=O[o])||(31<s&&127>s||((s=o)in S?o=S[s]:s in O?o=S[s]=O[s]:(31<(n=s.charCodeAt(0))&&127>n?o=s:(256>n?(o="\\x",(16>n||256<n)&&(o+="0")):(o="\\u",4096>n&&(o+="0")),o+=n.toString(16).toUpperCase()),o=S[s]=o)),n=o),t[i]=n}t.push('"'),e=t.join("")}else e=e.toString();return e},void 0),d("jspb.utils.stringToByteArray",function(e){for(var t=new Uint8Array(e.length),r=0;r<e.length;r++){var n=e.charCodeAt(r);if(255<n)throw Error("Conversion error: string contains codepoint outside of byte range");t[r]=n}return t},void 0),d("jspb.utils.byteSourceToUint8Array",se,void 0),d("jspb.BinaryDecoder",ie,void 0);var ae=[];function ce(e,t,r){if(ae.length){var n=ae.pop();return e&&n.H(e,t,r),n}return new ie(e,t,r)}function ue(e,t,r){this.a=ce(e,t,r),this.O=this.a.B(),this.b=this.c=-1,this.h=!1,this.v=null}ie.getInstanceCacheLength=function(){return ae.length},ie.alloc=ce,ie.prototype.Ca=function(){this.clear(),100>ae.length&&ae.push(this)},ie.prototype.free=ie.prototype.Ca,ie.prototype.clone=function(){return ce(this.b,this.h,this.c-this.h)},ie.prototype.clone=ie.prototype.clone,ie.prototype.clear=function(){this.b=null,this.a=this.c=this.h=0,this.v=!1},ie.prototype.clear=ie.prototype.clear,ie.prototype.Y=function(){return this.b},ie.prototype.getBuffer=ie.prototype.Y,ie.prototype.H=function(e,t,r){this.b=se(e),this.h=void 0!==t?t:0,this.c=void 0!==r?this.h+r:this.b.length,this.a=this.h},ie.prototype.setBlock=ie.prototype.H,ie.prototype.Db=function(){return this.c},ie.prototype.getEnd=ie.prototype.Db,ie.prototype.setEnd=function(e){this.c=e},ie.prototype.setEnd=ie.prototype.setEnd,ie.prototype.reset=function(){this.a=this.h},ie.prototype.reset=ie.prototype.reset,ie.prototype.B=function(){return this.a},ie.prototype.getCursor=ie.prototype.B,ie.prototype.Ma=function(e){this.a=e},ie.prototype.setCursor=ie.prototype.Ma,ie.prototype.advance=function(e){this.a+=e,T(this.a<=this.c)},ie.prototype.advance=ie.prototype.advance,ie.prototype.ya=function(){return this.a==this.c},ie.prototype.atEnd=ie.prototype.ya,ie.prototype.Qb=function(){return this.a>this.c},ie.prototype.pastEnd=ie.prototype.Qb,ie.prototype.getError=function(){return this.v||0>this.a||this.a>this.c},ie.prototype.getError=ie.prototype.getError,ie.prototype.w=function(e){for(var t=128,r=0,n=0,o=0;4>o&&128<=t;o++)r|=(127&(t=this.b[this.a++]))<<7*o;if(128<=t&&(r|=(127&(t=this.b[this.a++]))<<28,n|=(127&t)>>4),128<=t)for(o=0;5>o&&128<=t;o++)n|=(127&(t=this.b[this.a++]))<<7*o+3;if(128>t)return e(r>>>0,n>>>0);w("Failed to read varint, encoding is invalid."),this.v=!0},ie.prototype.readSplitVarint64=ie.prototype.w,ie.prototype.ea=function(e){return this.w(function(t,r){return Z(t,r,e)})},ie.prototype.readSplitZigzagVarint64=ie.prototype.ea,ie.prototype.ta=function(e){var t=this.b,r=this.a;this.a+=8;for(var n=0,o=0,s=r+7;s>=r;s--)n=n<<8|t[s],o=o<<8|t[s+4];return e(n,o)},ie.prototype.readSplitFixed64=ie.prototype.ta,ie.prototype.kb=function(){for(;128&this.b[this.a];)this.a++;this.a++},ie.prototype.skipVarint=ie.prototype.kb,ie.prototype.mb=function(e){for(;128<e;)this.a--,e>>>=7;this.a--},ie.prototype.unskipVarint=ie.prototype.mb,ie.prototype.o=function(){var e=this.b,t=e[this.a],r=127&t;return 128>t?(this.a+=1,T(this.a<=this.c),r):(r|=(127&(t=e[this.a+1]))<<7,128>t?(this.a+=2,T(this.a<=this.c),r):(r|=(127&(t=e[this.a+2]))<<14,128>t?(this.a+=3,T(this.a<=this.c),r):(r|=(127&(t=e[this.a+3]))<<21,128>t?(this.a+=4,T(this.a<=this.c),r):(r|=(15&(t=e[this.a+4]))<<28,128>t?(this.a+=5,T(this.a<=this.c),r>>>0):(this.a+=5,128<=e[this.a++]&&128<=e[this.a++]&&128<=e[this.a++]&&128<=e[this.a++]&&128<=e[this.a++]&&T(!1),T(this.a<=this.c),r)))))},ie.prototype.readUnsignedVarint32=ie.prototype.o,ie.prototype.da=function(){return~~this.o()},ie.prototype.readSignedVarint32=ie.prototype.da,ie.prototype.O=function(){return this.o().toString()},ie.prototype.Ea=function(){return this.da().toString()},ie.prototype.readSignedVarint32String=ie.prototype.Ea,ie.proto