-
Notifications
You must be signed in to change notification settings - Fork 1.4k
/
protobuf.min.js
9 lines (9 loc) · 59.9 KB
/
protobuf.min.js
1
2
3
4
5
6
7
8
9
/*!
* protobuf.js v6.2.1 (c) 2016 Daniel Wirtz
* Compiled Fri, 16 Dec 2016 16:10:12 UTC
* Licensed under the Apache License, Version 2.0
* see: https://github.com/dcodeIO/protobuf.js for details
*/
!function e(t,n,r){function i(o,u){if(!n[o]){if(!t[o]){var a="function"==typeof require&&require;if(!u&&a)return a(o,!0);if(s)return s(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return i(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}for(var s="function"==typeof require&&require,o=0;o<r.length;o++)i(r[o]);return i}({1:[function(e,t,n){n.read=function(e,t,n,r,i){var s,o,u=8*i-r-1,a=(1<<u)-1,f=a>>1,l=-7,h=n?0:i-1,c=n?1:-1,d=e[t+h];for(h+=c,s=d&(1<<-l)-1,d>>=-l,l+=u;l>0;s=256*s+e[t+h],h+=c,l-=8);for(o=s&(1<<-l)-1,s>>=-l,l+=r;l>0;o=256*o+e[t+h],h+=c,l-=8);if(0===s)s=1-f;else{if(s===a)return o?NaN:(d?-1:1)*(1/0);o+=Math.pow(2,r),s-=f}return(d?-1:1)*o*Math.pow(2,s-r)},n.write=function(e,t,n,r,i,s){var o,u,a,f=8*s-i-1,l=(1<<f)-1,h=l>>1,c=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,d=r?s-1:0,p=r?-1:1,v=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(u=isNaN(t)?1:0,o=l):(o=Math.floor(Math.log(t)/Math.LN2),t*(a=Math.pow(2,-o))<1&&(o--,a*=2),t+=o+h>=1?c/a:c*Math.pow(2,1-h),t*a>=2&&(o++,a/=2),o+h>=l?(u=0,o=l):o+h>=1?(u=(t*a-1)*Math.pow(2,i),o+=h):(u=t*Math.pow(2,h-1)*Math.pow(2,i),o=0));i>=8;e[n+d]=255&u,d+=p,u/=256,i-=8);for(o=o<<i|u,f+=i;f>0;e[n+d]=255&o,d+=p,o/=256,f-=8);e[n+d-p]|=128*v}},{}],2:[function(e,t,n){"use strict";function r(e,t){for(var n=[],r=2;r<arguments.length;)n.push(arguments[r++]);var i=!0;return new Promise(function(r,s){n.push(function(e){if(i)if(i=!1,e)s(e);else{for(var t=[],n=1;n<arguments.length;)t.push(arguments[n++]);r.apply(null,t)}});try{e.apply(t||this,n)}catch(e){i&&(i=!1,s(e))}})}t.exports=r},{}],3:[function(e,t,n){"use strict";var r=n;r.length=function(e){var t=e.length;if(!t)return 0;for(var n=0;--t%4>1&&"="===e.charAt(t);)++n;return Math.ceil(3*e.length)/4-n};for(var i=[],s=[],o=0;o<64;)s[i[o]=o<26?o+65:o<52?o+71:o<62?o-4:o-59|43]=o++;r.encode=function(e,t,n){for(var r,s=[],o=0,u=0;t<n;){var a=e[t++];switch(u){case 0:s[o++]=i[a>>2],r=(3&a)<<4,u=1;break;case 1:s[o++]=i[r|a>>4],r=(15&a)<<2,u=2;break;case 2:s[o++]=i[r|a>>6],s[o++]=i[63&a],u=0}}return u&&(s[o++]=i[r],s[o]=61,1===u&&(s[o+1]=61)),String.fromCharCode.apply(String,s)};var u="invalid encoding";r.decode=function(e,t,n){for(var r,i=n,o=0,a=0;a<e.length;){var f=e.charCodeAt(a++);if(61===f&&o>1)break;if(void 0===(f=s[f]))throw Error(u);switch(o){case 0:r=f,o=1;break;case 1:t[n++]=r<<2|(48&f)>>4,r=f,o=2;break;case 2:t[n++]=(15&r)<<4|(60&f)>>2,r=f,o=3;break;case 3:t[n++]=(3&r)<<6|f,o=0}}if(1===o)throw Error(u);return n-i}},{}],4:[function(e,t,n){"use strict";function r(){function e(){for(var t=[],n=0;n<arguments.length;)t.push(arguments[n++]);var r=i.apply(null,t),l=c;if(h.length){var p=h[h.length-1];s.test(p)?l=++c:a.test(p)&&++l,u.test(p)&&!u.test(r)?(l=++c,d=!0):d&&f.test(p)&&(l=--c,d=!1),o.test(r)&&(l=--c)}for(n=0;n<l;++n)r="\t"+r;return h.push(r),e}function t(e){return"function "+(e?e.replace(/[^\w_$]/g,"_"):"")+"("+l.join(", ")+") {\n"+h.join("\n")+"\n}"}function n(t,n){"object"==typeof t&&(n=t,t=void 0);var i=e.str(t);r.verbose&&console.log("--- codegen ---\n"+i.replace(/^/gm,"> ").replace(/\t/g," "));var s=Object.keys(n||(n={}));return Function.apply(null,s.concat("return "+i)).apply(null,s.map(function(e){return n[e]}))}for(var l=[],h=[],c=1,d=!1,p=0;p<arguments.length;)l.push(arguments[p++]);return e.str=t,e.eof=n,e}function i(e){for(var t=[],n=1;n<arguments.length;)t.push(arguments[n++]);return n=0,e.replace(/%([djs])/g,function(e,r){var i=t[n++];switch(r){case"j":return JSON.stringify(i);default:return String(i)}})}t.exports=r;var s=/[{[]$/,o=/^[}\]]/,u=/:$/,a=/^\s*(?:if|else if|while|for)\b|\b(?:else)\s*$/,f=/\b(?:break|continue);?$|^\s*return\b/;r.supported=!1;try{r.supported=1===r("a","b")("return a-b").eof()(2,1)}catch(e){}r.verbose=!1},{}],5:[function(e,t,n){"use strict";function r(){this.a={}}t.exports=r;var i=r.prototype;i.on=function(e,t,n){return(this.a[e]||(this.a[e]=[])).push({fn:t,ctx:n||this}),this},i.off=function(e,t){if(void 0===e)this.a={};else if(void 0===t)this.a[e]=[];else for(var n=this.a[e],r=0;r<n.length;)n[r].fn===t?n.splice(r,1):++r;return this},i.emit=function(e){var t=this.a[e];if(t){for(var n=[],r=1;r<arguments.length;)n.push(arguments[r++]);for(r=0;r<t.length;)t[r].fn.apply(t[r++].ctx,n)}return this}},{}],6:[function(e,t,n){"use strict";function r(e){for(var t=Object.keys(this),n=0;n<t.length;++n)e[t[n]]=this[t[n]];var r=e.prototype=Object.create(this.prototype);return r.constructor=e,r}t.exports=r},{}],7:[function(e,t,n){"use strict";function r(e,t){return t?o.readFile?o.readFile(e,"utf8",function(n,r){return n&&"undefined"!=typeof XMLHttpRequest?i(e,t):t(n,r)}):i(e,t):s(r,this,e)}function i(e,t){var n=new XMLHttpRequest;n.onreadystatechange=function(){return 4===n.readyState?0===n.status||200===n.status?t(null,n.responseText):t(Error("status "+n.status)):void 0},n.open("GET",e),n.send()}t.exports=r;var s=e(2),o=e(8)},{2:2,8:8}],8:[function(require,module,exports){"use strict";try{module.exports=eval(["req","uire"].join(""))("fs")}catch(e){}},{}],9:[function(e,t,n){"use strict";var r=n,i=r.isAbsolute=function(e){return/^(?:\/|\w+:)/.test(e)},s=r.normalize=function(e){e=e.replace(/\\/g,"/").replace(/\/{2,}/g,"/");var t=e.split("/"),n=i(e),r="";n&&(r=t.shift()+"/");for(var s=0;s<t.length;)".."===t[s]?s>0?t.splice(--s,2):n?t.splice(s,1):++s:"."===t[s]?t.splice(s,1):++s;return r+t.join("/")};r.resolve=function(e,t,n){return n||(t=s(t)),i(t)?t:(n||(e=s(e)),(e=e.replace(/(?:\/|^)[^\/]+$/,"")).length?s(e+"/"+t):t)}},{}],10:[function(e,t,n){"use strict";function r(e,t,n){var r=n||8192,i=r>>>1,s=null,o=r;return function(n){if(n>i)return e(n);o+n>r&&(s=e(r),o=0);var u=t.call(s,o,o+=n);return 7&o&&(o=(7|o)+1),u}}t.exports=r},{}],11:[function(e,t,n){"use strict";var r=n;r.length=function(e){for(var t=0,n=0,r=0;r<e.length;++r)n=e.charCodeAt(r),n<128?t+=1:n<2048?t+=2:55296===(64512&n)&&56320===(64512&e.charCodeAt(r+1))?(++r,t+=4):t+=3;return t},r.read=function(e,t,n){var r=n-t;if(r<1)return"";for(var i,s=[],o=[],u=0;t<n;)i=e[t++],i<128?o[u++]=i:i>191&&i<224?o[u++]=(31&i)<<6|63&e[t++]:i>239&&i<365?(i=((7&i)<<18|(63&e[t++])<<12|(63&e[t++])<<6|63&e[t++])-65536,o[u++]=55296+(i>>10),o[u++]=56320+(1023&i)):o[u++]=(15&i)<<12|(63&e[t++])<<6|63&e[t++],u>8191&&(s.push(String.fromCharCode.apply(String,o)),u=0);return u&&s.push(String.fromCharCode.apply(String,o.slice(0,u))),s.join("")},r.write=function(e,t,n){for(var r,i,s=n,o=0;o<e.length;++o)r=e.charCodeAt(o),r<128?t[n++]=r:r<2048?(t[n++]=r>>6|192,t[n++]=63&r|128):55296===(64512&r)&&56320===(64512&(i=e.charCodeAt(o+1)))?(r=65536+((1023&r)<<10)+(1023&i),++o,t[n++]=r>>18|240,t[n++]=r>>12&63|128,t[n++]=r>>6&63|128,t[n++]=63&r|128):(t[n++]=r>>12|224,t[n++]=r>>6&63|128,t[n++]=63&r|128);return n-s}},{}],12:[function(e,t,n){"use strict";function r(e){return r.create(e)}t.exports=r;var i,s=e(19),o=e(33),u=o.b;r.create=function(t,n){if(i||(i=e(31)),!(t instanceof i))throw u("type","a Type");if(n){if("function"!=typeof n)throw u("ctor","a function")}else n=function(e){return function(t){e.call(this,t)}}(s);n.constructor=r;var a=n.prototype=new s;return a.constructor=n,o.merge(n,s,!0),n.$type=t,a.$type=t,t.getFieldsArray().forEach(function(e){a[e.name]=Array.isArray(e.resolve().defaultValue)?o.emptyArray:o.isObject(e.defaultValue)?o.emptyObject:e.defaultValue}),t.getOneofsArray().forEach(function(e){o.prop(a,e.resolve().name,{get:function(){for(var t=Object.keys(this),n=t.length-1;n>-1;--n)if(e.oneof.indexOf(t[n])>-1)return t[n]},set:function(t){for(var n=e.oneof,r=0;r<n.length;++r)n[r]!==t&&delete this[n[r]]}})}),t.setCtor(n),a},r.prototype=s},{19:19,31:31,33:33}],13:[function(e,t,n){"use strict";function r(e,t){/\/|\./.test(e)||(e="google/protobuf/"+e+".proto",t={nested:{google:{nested:{protobuf:{nested:t}}}}}),r[e]=t}t.exports=r,r("any",{Any:{fields:{type_url:{type:"string",id:1},value:{type:"bytes",id:2}}}});var i;r("duration",{Duration:i={fields:{seconds:{type:"int64",id:1},nanos:{type:"int32",id:2}}}}),r("timestamp",{Timestamp:i}),r("empty",{Empty:{fields:{}}}),r("struct",{Struct:{fields:{fields:{keyType:"string",type:"Value",id:1}}},Value:{oneofs:{kind:{oneof:["nullValue","numberValue","stringValue","boolValue","structValue","listValue"]}},fields:{nullValue:{type:"NullValue",id:1},numberValue:{type:"double",id:2},stringValue:{type:"string",id:3},boolValue:{type:"bool",id:4},structValue:{type:"Struct",id:5},listValue:{type:"ListValue",id:6}}},NullValue:{values:{NULL_VALUE:0}},ListValue:{fields:{values:{rule:"repeated",type:"Value",id:1}}}})},{}],14:[function(e,t,n){"use strict";function r(e,t){for(var n=this.getFieldsById(),r=e instanceof s?e:s.create(e),a=void 0===t?r.len:r.pos+t,f=new(this.getCtor());r.pos<a;){var l=r.int32(),h=7&l,c=n[l>>>3].resolve(),d=c.resolvedType instanceof i?"uint32":c.type;if(c)if(c.map){var p=c.resolvedKeyType?"uint32":c.keyType;r.skip(),r.pos++,f[c.name]===u.emptyObject&&(f[c.name]={});var v=r[p]();"object"==typeof v&&(v=u.longToHash(v)),r.pos++,f[c.name][v]=void 0===o.basic[d]?c.resolvedType.decode(r,r.uint32()):r[d]()}else if(c.repeated){var y=f[c.name]&&f[c.name].length?f[c.name]:f[c.name]=[];if(c.packed&&void 0!==o.packed[d]&&2===h)for(var g=r.uint32()+r.pos;r.pos<g;)y.push(r[d]());else void 0===o.basic[d]?y.push(c.resolvedType.decode(r,r.uint32())):y.push(r[d]())}else void 0===o.basic[d]?f[c.name]=c.resolvedType.decode(r,r.uint32()):f[c.name]=r[d]();else r.skipType(h)}return f}t.exports=r;var i=e(16),s=e(25),o=e(32),u=e(33);r.generate=function(e){for(var t=e.getFieldsArray(),n=u.codegen("r","l")("r instanceof Reader||(r=Reader.create(r))")("var c=l===undefined?r.len:r.pos+l,m=new(this.getCtor())")("while(r.pos<c){")("var t=r.int32()")("switch(t>>>3){"),r=0;r<t.length;++r){var s=t[r].resolve(),a=s.resolvedType instanceof i?"uint32":s.type,f=u.safeProp(s.name);if(n("case %d:",s.id),s.map){var l=s.resolvedKeyType?"uint32":s.keyType;n("r.skip().pos++")("if(m%s===util.emptyObject)",f)("m%s={}",f)("var k=r.%s()",l)('if(typeof k==="object")')("k=util.longToHash(k)")("r.pos++"),void 0===o.basic[a]?n("m%s[k]=types[%d].decode(r,r.uint32())",f,r):n("m%s[k]=r.%s()",f,a)}else s.repeated?(n("m%s&&m%s.length?m%s:m%s=[]",f,f,f,f),s.packed&&void 0!==o.packed[a]&&n("if((t&7)===2){")("var e=r.uint32()+r.pos")("while(r.pos<e)")("m%s.push(r.%s())",f,a)("}else"),void 0===o.basic[a]?n("m%s.push(types[%d].decode(r,r.uint32()))",f,r,r):n("m%s.push(r.%s())",f,a)):void 0===o.basic[a]?n("m%s=types[%d].decode(r,r.uint32())",f,r,r):n("m%s=r.%s()",f,a);n("break")}return n("default:")("r.skipType(t&7)")("break")("}")("}")("return m")}},{16:16,25:25,32:32,33:33}],15:[function(e,t,n){"use strict";function r(e,t){t||(t=s.create());for(var n=this.getFieldsArray(),r=0;r<n.length;){var a=n[r++].resolve(),f=a.resolvedType instanceof i?"uint32":a.type,l=o.basic[f];if(a.map){var h=a.resolvedKeyType?"uint32":a.keyType;if(e[a.name]&&e[a.name]!==u.emptyObject)for(var c=Object.keys(e[a.name]),d=0;d<c.length;++d)t.uint32(a.id<<3|2).fork().uint32(8|o.mapKey[h])[h](c[d]),void 0===l?a.resolvedType.encode(e[a.name][c[d]],t.uint32(18).fork()).ldelim():t.uint32(16|l)[f](e[a.name][c[d]]),t.ldelim()}else if(a.repeated){var p=e[a.name];if(p&&p.length)if(a.packed&&void 0!==o.packed[f]){t.fork();for(var d=0;d<p.length;)t[f](p[d++]);t.ldelim(a.id)}else{var d=0;if(void 0!==l)for(;d<p.length;)t.uint32(a.id<<3|l)[f](p[d++]);else for(;d<p.length;)a.resolvedType.encode(p[d++],t.uint32(a.id<<3|2).fork()).ldelim()}}else{var v=e[a.name];(a.partOf&&e[a.partOf.name]===a.name||(a.required||void 0!==v)&&(a.long?u.longNe(v,a.defaultValue.low,a.defaultValue.high):v!==a.defaultValue))&&(void 0!==l?t.uint32(a.id<<3|l)[f](v):(a.resolvedType.encode(v,t.fork()),t.len||a.required?t.ldelim(a.id):t.reset()))}}return t}t.exports=r;var i=e(16),s=e(37),o=e(32),u=e(33),a=u.safeProp;r.generate=function(e){for(var t,n=e.getFieldsArray(),r=e.getOneofsArray(),s=u.codegen("m","w")("w||(w=Writer.create())"),t=0;t<n.length;++t){var f=n[t].resolve(),l=f.resolvedType instanceof i?"uint32":f.type,h=o.basic[l],c=a(f.name);if(f.map){var d=f.resolvedKeyType?"uint32":f.keyType;s("if(m%s&&m%s!==util.emptyObject){",c,c)("for(var ks=Object.keys(m%s),i=0;i<ks.length;++i){",c)("w.uint32(%d).fork().uint32(%d).%s(ks[i])",f.id<<3|2,8|o.mapKey[d],d),void 0===h?s("types[%d].encode(m%s[ks[i]],w.uint32(18).fork()).ldelim()",t,c):s("w.uint32(%d).%s(m%s[ks[i]])",16|h,l,c),s("w.ldelim()")("}")("}")}else f.repeated?f.packed&&void 0!==o.packed[l]?s("if(m%s&&m%s.length){",c,c)("w.fork()")("for(var i=0;i<m%s.length;++i)",c)("w.%s(m%s[i])",l,c)("w.ldelim(%d)",f.id)("}"):(s("if(m%s)",c)("for(var i=0;i<m%s.length;++i)",c),void 0!==h?s("w.uint32(%d).%s(m%s[i])",f.id<<3|h,l,c):s("types[%d].encode(m%s[i],w.uint32(%d).fork()).ldelim()",t,c,f.id<<3|2)):f.partOf||(f.required||(f.long?s("if(m%s!==undefined&&util.longNe(m%s,%d,%d))",c,c,f.defaultValue.low,f.defaultValue.high):s("if(m%s!==undefined&&m%s!==%j)",c,c,f.defaultValue)),void 0!==h?s("w.uint32(%d).%s(m%s)",f.id<<3|h,l,c):f.required?s("types[%d].encode(m%s,w.uint32(%d).fork()).ldelim()",t,c,f.id<<3|2):s("types[%d].encode(m%s,w.fork()).len&&w.ldelim(%d)||w.reset()",t,c,f.id))}for(var t=0;t<r.length;++t){var p=r[t],c=a(p.name);s("switch(m%s){",c);for(var v=p.getFieldsArray(),y=0;y<v.length;++y){var f=v[y],l=f.resolvedType instanceof i?"uint32":f.type,h=o.basic[l],c=a(f.name);s("case%j:",f.name),void 0!==h?s("w.uint32(%d).%s(m%s)",f.id<<3|h,l,c):f.required?s("types[%d].encode(m%s,w.uint32(%d).fork()).ldelim()",n.indexOf(f),c,f.id<<3|2):s("types[%d].encode(m%s,w.fork()).len&&w.ldelim(%d)||w.reset()",n.indexOf(f),c,f.id),s("break;")}s("}")}return s("return w")}},{16:16,32:32,33:33,37:37}],16:[function(e,t,n){"use strict";function r(e,t,n){s.call(this,e,n),this.values=t||{},this.c=null}function i(e){return e.c=null,e}t.exports=r,r.className="Enum";var s=e(22),o=s.extend(r),u=e(33),a=u.b;u.props(o,{valuesById:{get:function(){return this.c||(this.c={},Object.keys(this.values).forEach(function(e){var t=this.values[e];if(this.c[t])throw Error("duplicate id "+t+" in "+this);this.c[t]=e},this)),this.c}}}),r.testJSON=function(e){return Boolean(e&&e.values)},r.fromJSON=function(e,t){return new r(e,t.values,t.options)},o.toJSON=function(){return{options:this.options,values:this.values}},o.add=function(e,t){if(!u.isString(e))throw a("name");if(!u.isInteger(t)||t<0)throw a("id","a non-negative integer");if(void 0!==this.values[e])throw Error("duplicate name '"+e+"' in "+this);if(void 0!==this.getValuesById()[t])throw Error("duplicate id "+t+" in "+this);return this.values[e]=t,i(this)},o.remove=function(e){if(!u.isString(e))throw a("name");if(void 0===this.values[e])throw Error("'"+e+"' is not a name of "+this);return delete this.values[e],i(this)}},{22:22,33:33}],17:[function(e,t,n){"use strict";function r(e,t,n,r,i,s){if(h.isObject(r)?(s=r,r=i=void 0):h.isObject(i)&&(s=i,i=void 0),o.call(this,e,s),!h.isInteger(t)||t<0)throw c("id","a non-negative integer");if(!h.isString(n))throw c("type");if(void 0!==i&&!h.isString(i))throw c("extend");if(void 0!==r&&!/^required|optional|repeated$/.test(r=r.toString().toLowerCase()))throw c("rule","a valid rule string");this.rule=r&&"optional"!==r?r:void 0,this.type=n,this.id=t,this.extend=i||void 0,this.required="required"===r,this.optional=!this.required,this.repeated="repeated"===r,this.map=!1,this.message=null,this.partOf=null,this.defaultValue=null,this.long=!!h.Long&&void 0!==l.long[n],this.bytes="bytes"===n,this.resolvedType=null,this.extensionField=null,this.declaringField=null,this.d=null}t.exports=r,r.className="Field";var i,s,o=e(22),u=e(19),a=o.extend(r),f=e(16),l=e(32),h=e(33),c=h.b;h.props(a,{packed:{get:a.isPacked=function(){return null===this.d&&(this.d=this.getOption("packed")!==!1),this.d}}}),a.setOption=function(e,t,n){return"packed"===e&&(this.d=null),o.prototype.setOption.call(this,e,t,n)},r.testJSON=function(e){return Boolean(e&&void 0!==e.id)},r.fromJSON=function(t,n){return void 0!==n.keyType?(s||(s=e(18)),s.fromJSON(t,n)):new r(t,n.id,n.type,n.rule,n.extend,n.options)},a.toJSON=function(){return{rule:"optional"!==this.rule&&this.rule||void 0,type:this.type,id:this.id,extend:this.extend,options:this.options}},a.resolve=function(){if(this.resolved)return this;var t=l.defaults[this.type];if(void 0===t){var n=this.parent.lookup(this.type);if(i||(i=e(31)),n instanceof i)this.resolvedType=n,t=null;else{if(!(n instanceof f))throw Error("unresolvable field type: "+this.type);this.resolvedType=n,t=0}}var r;return this.map?this.defaultValue={}:this.repeated?this.defaultValue=[]:this.options&&void 0!==(r=this.options.default)?this.defaultValue=r:this.defaultValue=t,this.long&&(this.defaultValue=h.Long.fromValue(this.defaultValue)),o.prototype.resolve.call(this)},a.jsonConvert=function(e,t){if(t){if(e instanceof u)return e.asJSON(t);if(this.resolvedType instanceof f&&t.enum===String)return this.resolvedType.getValuesById()[e];if(t.long&&this.long)return t.long===Number?"number"==typeof e?e:h.LongBits.from(e).toNumber("u"===this.type.charAt(0)):h.Long.fromValue(e,"u"===this.type.charAt(0)).toString();if(t.bytes&&this.bytes)return t.bytes===Array?Array.prototype.slice.call(e):h.base64.encode(e,0,e.length)}return e}},{16:16,18:18,19:19,22:22,31:31,32:32,33:33}],18:[function(e,t,n){"use strict";function r(e,t,n,r,s){if(i.call(this,e,t,r,s),!f.isString(n))throw f.b("keyType");this.keyType=n,this.resolvedKeyType=null,this.map=!0}t.exports=r,r.className="MapField";var i=e(17),s=i.prototype,o=i.extend(r),u=e(16),a=e(32),f=e(33);r.testJSON=function(e){return i.testJSON(e)&&void 0!==e.keyType},r.fromJSON=function(e,t){return new r(e,t.id,t.keyType,t.type,t.options)},o.toJSON=function(){return{keyType:this.keyType,type:this.type,id:this.id,extend:this.extend,options:this.options}},o.resolve=function(){if(this.resolved)return this;var e=a.mapKey[this.keyType];if(void 0===e){var t=this.parent.lookup(this.keyType);if(!(t instanceof u))throw Error("unresolvable map key type: "+this.keyType);this.resolvedKeyType=t}return s.resolve.call(this)}},{16:16,17:17,32:32,33:33}],19:[function(e,t,n){"use strict";function r(e){if(e)for(var t=Object.keys(e),n=0;n<t.length;++n)this[t[n]]=e[t[n]]}t.exports=r;var i=r.prototype;i.asJSON=function(e){e||(e={});var t,n=this.$type.fields,r={};t=e.defaults?Object.keys(n):Object.keys(this);for(var i,s=0;s<t.length;++s){var o=n[i=t[s]],u=this[i];if(o)if(o.repeated){if(u&&(u.length||e.defaults)){for(var a=new Array(u.length),f=0,l=u.length;f<l;++f)a[f]=o.jsonConvert(u[f],e);r[i]=a}}else r[i]=o.jsonConvert(u,e);else e.fieldsOnly||(r[i]=u)}return r},r.encode=function(e,t){return this.$type.encode(e,t)},r.encodeDelimited=function(e,t){return this.$type.encodeDelimited(e,t)},r.decode=function(e){return this.$type.decode(e)},r.decodeDelimited=function(e){return this.$type.decodeDelimited(e)},r.verify=function(e){return this.$type.verify(e)}},{}],20:[function(e,t,n){"use strict";function r(e,t,n,r,s,o,f){if(u.isObject(s)?(f=s,s=o=void 0):u.isObject(o)&&(f=o,o=void 0),t&&!u.isString(t))throw a("type");if(!u.isString(n))throw a("requestType");if(!u.isString(r))throw a("responseType");i.call(this,e,f),this.type=t||"rpc",this.requestType=n,this.requestStream=!!s||void 0,this.responseType=r,this.responseStream=!!o||void 0,this.resolvedRequestType=null,this.resolvedResponseType=null}t.exports=r,r.className="Method";var i=e(22),s=i.extend(r),o=e(31),u=e(33),a=u.b;r.testJSON=function(e){return Boolean(e&&void 0!==e.requestType)},r.fromJSON=function(e,t){return new r(e,t.type,t.requestType,t.responseType,t.requestStream,t.responseStream,t.options)},s.toJSON=function(){return{type:"rpc"!==this.type&&this.type||void 0,requestType:this.requestType,requestStream:this.requestStream,responseType:this.responseType,responseStream:this.responseStream,options:this.options}},s.resolve=function(){if(this.resolved)return this;var e=this.parent.lookup(this.requestType);if(!(e&&e instanceof o))throw Error("unresolvable request type: "+this.requestType);if(this.resolvedRequestType=e,e=this.parent.lookup(this.responseType),!(e&&e instanceof o))throw Error("unresolvable response type: "+this.requestType);return this.resolvedResponseType=e,i.prototype.resolve.call(this)}},{22:22,31:31,33:33}],21:[function(e,t,n){"use strict";function r(){u||(u=e(31)),a||(a=e(29)),f=[d,u,a,p,i],l="one of "+f.map(function(e){return e.name}).join(", ")}function i(e,t){h.call(this,e,t),this.nested=void 0,this.e=null}function s(e){return e.e=null,e}function o(e){if(e&&e.length){for(var t={},n=0;n<e.length;++n)t[e[n].name]=e[n].toJSON();return t}}t.exports=i,i.className="Namespace";var u,a,f,l,h=e(22),c=h.extend(i),d=e(16),p=e(17),v=e(33),y=v.b;v.props(c,{nestedArray:{get:function(){return this.e||(this.e=v.toArray(this.nested))}}}),i.testJSON=function(e){return Boolean(e&&!e.fields&&!e.values&&void 0===e.id&&!e.oneof&&!e.methods&&void 0===e.requestType)},i.fromJSON=function(e,t){return new i(e,t.options).addJSON(t.nested)},c.toJSON=function(){return{options:this.options,nested:o(this.getNestedArray())}},i.arrayToJSON=o,c.addJSON=function(e){var t=this;return e&&(f||r(),Object.keys(e).forEach(function(n){for(var r=e[n],i=0;i<f.length;++i)if(f[i].testJSON(r))return t.add(f[i].fromJSON(n,r));throw y("nested."+n,"JSON for "+l)})),this},c.get=function(e){return void 0===this.nested?null:this.nested[e]||null},c.add=function(t){if(f||r(),!t||f.indexOf(t.constructor)<0)throw y("object",l);if(t instanceof p&&void 0===t.extend)throw y("object","an extension field when not part of a type");if(this.nested){var n=this.get(t.name);if(n){if(u||(u=e(31)),a||(a=e(29)),!(n instanceof i&&t instanceof i)||n instanceof u||n instanceof a)throw Error("duplicate name '"+t.name+"' in "+this);for(var o=n.getNestedArray(),h=0;h<o.length;++h)t.add(o[h]);this.remove(n),this.nested||(this.nested={}),t.setOptions(n.options,!0)}}else this.nested={};return this.nested[t.name]=t,t.onAdd(this),s(this)},c.remove=function(e){if(!(e instanceof h))throw y("object","a ReflectionObject");if(e.parent!==this||!this.nested)throw Error(e+" is not a member of "+this);return delete this.nested[e.name],Object.keys(this.nested).length||(this.nested=void 0),e.onRemove(this),s(this)},c.define=function(e,t){v.isString(e)?e=e.split("."):Array.isArray(e)||(t=e,e=void 0);var n=this;if(e)for(;e.length>0;){var r=e.shift();if(n.nested&&n.nested[r]){if(n=n.nested[r],!(n instanceof i))throw Error("path conflicts with non-namespace objects")}else n.add(n=new i(r))}return t&&n.addJSON(t),n},c.resolveAll=function(){for(var e=this.getNestedArray(),t=0;t<e.length;)e[t]instanceof i?e[t++].resolveAll():e[t++].resolve();return h.prototype.resolve.call(this)},c.lookup=function(e,t){if(v.isString(e)){if(!e.length)return null;e=e.split(".")}else if(!e.length)return null;if(""===e[0])return this.getRoot().lookup(e.slice(1));var n=this.get(e[0]);return n&&(1===e.length||n instanceof i&&(n=n.lookup(e.slice(1),!0)))?n:null===this.parent||t?null:this.parent.lookup(e)},c.lookupType=function(t){var n=this.lookup(t);if(u||(u=e(31)),!(n instanceof u))throw Error("no such type");return n},c.lookupService=function(t){var n=this.lookup(t);if(a||(a=e(29)),!(n instanceof a))throw Error("no such service");return n}},{16:16,17:17,22:22,29:29,31:31,33:33}],22:[function(e,t,n){"use strict";function r(e,t){if(!i.isString(e))throw o("name");if(t&&!i.isObject(t))throw o("options","an object");this.options=t,this.name=e,this.parent=null,this.resolved=!1}t.exports=r;var i=e(33);r.className="ReflectionObject",r.extend=i.extend;var s,o=i.b,u=r.prototype;i.props(u,{root:{get:function(){for(var e=this;null!==e.parent;)e=e.parent;return e}},fullName:{get:u.getFullName=function(){for(var e=[this.name],t=this.parent;t;)e.unshift(t.name),t=t.parent;return e.join(".")}}}),u.toJSON=function(){throw Error()},u.onAdd=function(t){this.parent&&this.parent!==t&&this.parent.remove(this),this.parent=t,this.resolved=!1;var n=t.getRoot();s||(s=e(26)),n instanceof s&&n.f(this)},u.onRemove=function(t){var n=t.getRoot();s||(s=e(26)),n instanceof s&&n.g(this),this.parent=null,this.resolved=!1},u.resolve=function(){if(this.resolved)return this;var t=this.getRoot();return s||(s=e(26)),t instanceof s&&(this.resolved=!0),this},u.getOption=function(e){if(this.options)return this.options[e]},u.setOption=function(e,t,n){return n&&this.options&&void 0!==this.options[e]||((this.options||(this.options={}))[e]=t),this},u.setOptions=function(e,t){return e&&Object.keys(e).forEach(function(n){this.setOption(n,e[n],t)},this),this},u.toString=function(){var e=this.constructor.className,t=this.getFullName();return t.length?e+" "+t:e}},{26:26,33:33}],23:[function(e,t,n){"use strict";function r(e,t,n){if(Array.isArray(t)||(n=t,t=void 0),s.call(this,e,n),t&&!Array.isArray(t))throw f("fieldNames","an Array");this.ucName=this.name.substring(0,1).toUpperCase()+this.name.substring(1),this.oneof=t||[],this.h=[]}function i(e){e.parent&&e.h.forEach(function(t){t.parent||e.parent.add(t)})}t.exports=r,r.className="OneOf";var s=e(22),o=s.extend(r),u=e(17),a=e(33),f=a.b;a.prop(o,"fieldsArray",{get:function(){return this.h}}),r.testJSON=function(e){return Boolean(e.oneof)},r.fromJSON=function(e,t){return new r(e,t.oneof,t.options)},o.toJSON=function(){return{oneof:this.oneof,options:this.options}},o.add=function(e){if(!(e instanceof u))throw f("field","a Field");return e.parent&&e.parent.remove(e),this.oneof.push(e.name),this.h.push(e),e.partOf=this,i(this),this},o.remove=function(e){if(!(e instanceof u))throw f("field","a Field");var t=this.h.indexOf(e);if(t<0)throw Error(e+" is not a member of "+this);return this.h.splice(t,1),t=this.oneof.indexOf(e.name),t>-1&&this.oneof.splice(t,1),e.parent&&e.parent.remove(e),e.partOf=null,this},o.onAdd=function(e){s.prototype.onAdd.call(this,e),i(this)},o.onRemove=function(e){this.h.forEach(function(e){e.parent&&e.parent.remove(e)}),s.prototype.onRemove.call(this,e)}},{17:17,22:22,33:33}],24:[function(e,t,n){"use strict";function r(e){return null===e?null:e.toLowerCase()}function i(e,t,n){function i(e,t){return Error("illegal "+(t||"token")+" '"+e+"' (line "+_.line()+")")}function v(){var e,t=[];do{if('"'!==(e=K())&&"'"!==e)throw i(e);t.push(K()),Z(e),e=W()}while('"'===e||"'"===e);return t.join("")}function w(e){var t=K();switch(r(t)){case"'":case'"':return H(t),v();case"true":return!0;case"false":return!1}try{return x(t)}catch(n){if(e&&m.test(t))return t;throw i(t,"value")}}function k(){var e=O(K()),t=e;return Z("to",!0)&&(t=O(K())),Z(";"),[e,t]}function x(e){var t=1;"-"===e.charAt(0)&&(t=-1,e=e.substring(1));var n=r(e);switch(n){case"inf":return t*(1/0);case"nan":return NaN;case"0":return 0}if(/^[1-9][0-9]*$/.test(e))return t*parseInt(e,10);if(/^0[x][0-9a-f]+$/.test(n))return t*parseInt(e,16);if(/^0[0-7]+$/.test(e))return t*parseInt(e,8);if(/^(?!e)[0-9]*(?:\.[0-9]*)?(?:[e][+-]?[0-9]+)?$/.test(n))return t*parseFloat(e);throw i(e,"number")}function O(e,t){var n=r(e);switch(n){case"min":return 1;case"max":return 536870911;case"0":return 0}if("-"===e.charAt(0)&&!t)throw i(e,"id");if(/^-?[1-9][0-9]*$/.test(e))return parseInt(e,10);if(/^-?0[x][0-9a-f]+$/.test(n))return parseInt(e,16);if(/^-?0[0-7]+$/.test(e))return parseInt(e,8);throw i(e,"id")}function A(){if(void 0!==M)throw i("package");if(M=K(),!m.test(M))throw i(M,"name");Y=Y.define(M),Z(";")}function N(){var e,t=W();switch(t){case"weak":e=D||(D=[]),K();break;case"public":K();default:e=U||(U=[])}t=v(),Z(";"),e.push(t)}function S(){Z("="),P=r(v());var e;if(["proto2",e="proto3"].indexOf(P)<0)throw i(P,"syntax");G=P===e,Z(";")}function T(e,t){switch(t){case"option":return q(e,t),Z(";"),!0;case"message":return j(e,t),!0;case"enum":return B(e,t),!0;case"service":return z(e,t),!0;case"extend":return I(e,t),!0}return!1}function j(e,t){var n=K();if(!g.test(n))throw i(n,"type name");var s=new u(n);if(Z("{",!0)){for(;"}"!==(t=K());){var o=r(t);if(!T(s,t))switch(o){case"map":F(s,o);break;case"required":case"optional":case"repeated":E(s,o);break;case"oneof":J(s,o);break;case"extensions":(s.extensions||(s.extensions=[])).push(k(s,o));break;case"reserved":(s.reserved||(s.reserved=[])).push(k(s,o));break;default:if(!G||!m.test(t))throw i(t);H(t),E(s,"optional")}}Z(";",!0)}else Z(";");e.add(s)}function E(e,t,r){var s=K();if(!m.test(s))throw i(s,"type");var o=K();if(!g.test(o))throw i(o,"name");n.keepCase||(o=y(o)),Z("=");var u=O(K()),f=C(new a(o,u,s,t,r));f.repeated&&f.setOption("packed",G,!0),e.add(f)}function F(e){Z("<");var t=K();if(void 0===p.mapKey[t])throw i(t,"type");Z(",");var r=K();if(!m.test(r))throw i(r,"type");Z(">");var s=K();if(!g.test(s))throw i(s,"name");n.keepCase||(s=y(s)),Z("=");var o=O(K()),u=C(new f(s,o,t,r));e.add(u)}function J(e,t){var r=K();if(!g.test(r))throw i(r,"name");n.keepCase||(r=y(r));var s=new l(r);if(Z("{",!0)){for(;"}"!==(t=K());)"option"===t?(q(s,t),Z(";")):(H(t),E(s,"optional"));Z(";",!0)}else Z(";");e.add(s)}function B(e,t){var n=K();if(!g.test(n))throw i(n,"name");var s={},o=new h(n,s);if(Z("{",!0)){for(;"}"!==(t=K());)"option"===r(t)?q(o):L(o,t);Z(";",!0)}else Z(";");e.add(o)}function L(e,t){if(!g.test(t))throw i(t,"name");var n=t;Z("=");var r=O(K(),!0);e.values[n]=r,C({})}function q(e,t){var n=Z("(",!0),r=K();if(!m.test(r))throw i(r,"name");n&&(Z(")"),r="("+r+")",t=W(),b.test(t)&&(r+=t,K())),Z("="),V(e,r)}function V(e,t){if(Z("{",!0))for(;"}"!==(Q=K());){if(!g.test(Q))throw i(Q,"name");t=t+"."+Q,Z(":",!0)?$(e,t,w(!0)):V(e,t)}else $(e,t,w(!0))}function $(e,t,n){e.setOption?e.setOption(t,n):e[t]=n}function C(e){if(Z("[",!0)){do q(e,"option");while(Z(",",!0));Z("]")}return Z(";"),e}function z(e,t){if(t=K(),!g.test(t))throw i(t,"service name");var n=t,s=new c(n);if(Z("{",!0)){for(;"}"!==(t=K());){var o=r(t);switch(o){case"option":q(s,o),Z(";");break;case"rpc":R(s,o);break;default:throw i(t)}}Z(";",!0)}else Z(";");e.add(s)}function R(e,t){var n=t,s=K();if(!g.test(s))throw i(s,"name");var o,u,a,f;Z("(");var l;if(Z(l="stream",!0)&&(u=!0),!m.test(t=K()))throw i(t);if(o=t,Z(")"),Z("returns"),Z("("),Z(l,!0)&&(f=!0),!m.test(t=K()))throw i(t);a=t,Z(")");var h=new d(s,n,o,a,u,f);if(Z("{",!0)){for(;"}"!==(t=K());){var c=r(t);switch(c){case"option":q(h,c),Z(";");break;default:throw i(t)}}Z(";",!0)}else Z(";");e.add(h)}function I(e,t){var n=K();if(!m.test(n))throw i(n,"reference");if(Z("{",!0)){for(;"}"!==(t=K());){var s=r(t);switch(s){case"required":case"repeated":case"optional":E(e,s,n);break;default:if(!G||!m.test(t))throw i(t);H(t),E(e,"optional",n)}}Z(";",!0)}else Z(";")}t instanceof o?n||(n={}):(t=new o,n=t||{});var M,U,D,P,_=s(e),K=_.next,H=_.push,W=_.peek,Z=_.skip,X=!0,G=!1;t||(t=new o);for(var Q,Y=t;null!==(Q=K());){var ee=r(Q);switch(ee){case"package":if(!X)throw i(Q);A();break;case"import":if(!X)throw i(Q);N();break;case"syntax":if(!X)throw i(Q);S();break;case"option":if(!X)throw i(Q);q(Y,Q),Z(";");break;default:if(T(Y,Q)){X=!1;continue}throw i(Q)}}return{package:M,imports:U,weakImports:D,syntax:P,root:t}}t.exports=i;var s=e(30),o=e(26),u=e(31),a=e(17),f=e(18),l=e(23),h=e(16),c=e(29),d=e(20),p=e(32),v=e(33),y=v.camelCase,g=/^[a-zA-Z_][a-zA-Z_0-9]*$/,m=/^(?:\.?[a-zA-Z_][a-zA-Z_0-9]*)+$/,b=/^(?:\.[a-zA-Z][a-zA-Z_0-9]*)+$/},{16:16,17:17,18:18,20:20,23:23,26:26,29:29,30:30,31:31,32:32,33:33}],25:[function(e,t,n){"use strict";function r(e,t){return RangeError("index out of range: "+e.pos+" + "+(t||1)+" > "+e.len)}function i(e){this.buf=e,this.pos=0,this.len=e.length}function s(){var e=new A(0,0),t=0,n=0;if(this.len-this.pos>4){for(t=0;t<4;++t)if(n=this.buf[this.pos++],e.lo=(e.lo|(127&n)<<7*t)>>>0,n<128)return e;if(n=this.buf[this.pos++],e.lo=(e.lo|(127&n)<<28)>>>0,e.hi=(e.hi|(127&n)>>4)>>>0,n<128)return e}else{for(t=0;t<4;++t){if(this.pos>=this.len)throw r(this);if(n=this.buf[this.pos++],e.lo=(e.lo|(127&n)<<7*t)>>>0,n<128)return e}if(this.pos>=this.len)throw r(this);if(n=this.buf[this.pos++],e.lo=(e.lo|(127&n)<<28)>>>0,e.hi=(e.hi|(127&n)>>4)>>>0,n<128)return e}if(this.len-this.pos>4){for(t=0;t<5;++t)if(n=this.buf[this.pos++],e.hi=(e.hi|(127&n)<<7*t+3)>>>0,n<128)return e}else for(t=0;t<5;++t){if(this.pos>=this.len)throw r(this);
if(n=this.buf[this.pos++],e.hi=(e.hi|(127&n)<<7*t+3)>>>0,n<128)return e}throw Error("invalid varint encoding")}function o(){return s.call(this).toLong()}function u(){return s.call(this).toNumber()}function a(){return s.call(this).toLong(!0)}function f(){return s.call(this).toNumber(!0)}function l(){return s.call(this).zzDecode().toLong()}function h(){return s.call(this).zzDecode().toNumber()}function c(e,t){return e[t-4]|e[t-3]<<8|e[t-2]<<16|e[t-1]<<24}function d(){if(this.pos+8>this.len)throw r(this,8);return new A(c(this.buf,this.pos+=4),c(this.buf,this.pos+=4))}function p(){return d.call(this).toLong(!0)}function v(){return d.call(this).toNumber(!0)}function y(){return d.call(this).zzDecode().toLong()}function g(){return d.call(this).zzDecode().toNumber()}function m(e){F&&F(),i.call(this,e)}function b(e,t,n){return e.utf8Slice(t,n)}function w(e,t,n){return e.toString("utf8",t,n)}function k(){x.Long?(T.int64=o,T.uint64=a,T.sint64=l,T.fixed64=p,T.sfixed64=y):(T.int64=u,T.uint64=f,T.sint64=h,T.fixed64=v,T.sfixed64=g)}t.exports=i,i.BufferReader=m;var x=e(35),O=e(1),A=x.LongBits,N=x.utf8,S="undefined"!=typeof Uint8Array?Uint8Array:Array;i.create=function(e){return new(x.Buffer?m:i)(e)};var T=i.prototype;T.i=S.prototype.subarray||S.prototype.slice,T.int32=function(){var e=this.buf[this.pos++],t=127&e;if(e>127&&(e=this.buf[this.pos++],t|=(127&e)<<7,e>127&&(e=this.buf[this.pos++],t|=(127&e)<<14,e>127&&(e=this.buf[this.pos++],t|=(127&e)<<21,e>127&&(e=this.buf[this.pos++],t|=(127&e)<<28,e>127&&(this.pos+=5))))),this.pos>this.len)throw this.pos=this.len,r(this);return t},T.uint32=function(){return this.int32()>>>0},T.sint32=function(){var e=this.int32();return e>>>1^-(1&e)},T.bool=function(){return 0!==this.int32()},T.fixed32=function(){if(this.pos+4>this.len)throw r(this,4);return c(this.buf,this.pos+=4)},T.sfixed32=function(){var e=this.fixed32();return e>>>1^-(1&e)};var j="undefined"!=typeof Float32Array?function(){var e=new Float32Array(1),t=new Uint8Array(e.buffer);return e[0]=-0,t[3]?function(n,r){return t[0]=n[r],t[1]=n[r+1],t[2]=n[r+2],t[3]=n[r+3],e[0]}:function(n,r){return t[3]=n[r],t[2]=n[r+1],t[1]=n[r+2],t[0]=n[r+3],e[0]}}():function(e,t){return O.read(e,t,!1,23,4)};T.float=function(){if(this.pos+4>this.len)throw r(this,4);var e=j(this.buf,this.pos);return this.pos+=4,e};var E="undefined"!=typeof Float64Array?function(){var e=new Float64Array(1),t=new Uint8Array(e.buffer);return e[0]=-0,t[7]?function(n,r){return t[0]=n[r],t[1]=n[r+1],t[2]=n[r+2],t[3]=n[r+3],t[4]=n[r+4],t[5]=n[r+5],t[6]=n[r+6],t[7]=n[r+7],e[0]}:function(n,r){return t[7]=n[r],t[6]=n[r+1],t[5]=n[r+2],t[4]=n[r+3],t[3]=n[r+4],t[2]=n[r+5],t[1]=n[r+6],t[0]=n[r+7],e[0]}}():function(e,t){return O.read(e,t,!1,52,8)};T.double=function(){if(this.pos+8>this.len)throw r(this,4);var e=E(this.buf,this.pos);return this.pos+=8,e},T.bytes=function(){var e=this.int32()>>>0,t=this.pos,n=this.pos+e;if(n>this.len)throw r(this,e);return this.pos+=e,t===n?new this.buf.constructor(0):this.i.call(this.buf,t,n)},T.string=function(){var e=this.bytes();return N.read(e,0,e.length)},T.skip=function(e){if(void 0===e){do if(this.pos>=this.len)throw r(this);while(128&this.buf[this.pos++])}else{if(this.pos+e>this.len)throw r(this,e);this.pos+=e}return this},T.skipType=function(e){switch(e){case 0:this.skip();break;case 1:this.skip(8);break;case 2:this.skip(this.uint32());break;case 3:for(;;){if(e=7&this.int32(),4===e)break;this.skipType(e)}break;case 5:this.skip(4);break;default:throw Error("invalid wire type: "+e)}return this},T.reset=function(e){return e?(this.buf=e,this.len=e.length):(this.buf=null,this.len=0),this.pos=0,this},T.finish=function(e){var t=this.pos?this.i.call(this.buf,this.pos):this.buf;return this.reset(e),t};var F=function(){var e=x.Buffer;if(!e)throw Error("Buffer is not supported");J.i=e.prototype.slice,B=e.prototype.utf8Slice?b:w,F=!1},J=m.prototype=Object.create(i.prototype);J.constructor=m,"undefined"==typeof Float32Array&&(J.float=function(){if(this.pos+4>this.len)throw r(this,4);var e=this.buf.readFloatLE(this.pos,!0);return this.pos+=4,e}),"undefined"==typeof Float64Array&&(J.double=function(){if(this.pos+8>this.len)throw r(this,8);var e=this.buf.readDoubleLE(this.pos,!0);return this.pos+=8,e});var B;J.string=function(){var e=this.int32()>>>0,t=this.pos,n=this.pos+e;if(n>this.len)throw r(this,e);return this.pos+=e,B(this.buf,t,n)},J.finish=function(e){var t=this.pos?this.buf.slice(this.pos):this.buf;return this.reset(e),t},i.j=k,k()},{1:1,35:35}],26:[function(e,t,n){"use strict";function r(e){o.call(this,"",e),this.deferred=[],this.files=[]}function i(){}function s(e){var t=e.parent.lookup(e.extend);if(t){var n=new a(e.getFullName(),e.id,e.type,e.rule,(void 0),e.options);return n.declaringField=e,e.extensionField=n,t.add(n),!0}return!1}t.exports=r,r.className="Root";var o=e(21),u=o.extend(r),a=e(17),f=e(33),l=e(13);r.fromJSON=function(e,t){return t||(t=new r),t.setOptions(e.options).addJSON(e.nested)},u.resolvePath=f.path.resolve,u.load=function t(n,r,s){function o(e,t){if(s){var n=s;s=null,n(e,t)}}function u(t,n){try{if(f.isString(n)&&"{"===n.charAt(0)&&(n=JSON.parse(n)),f.isString(n)){var i=e(24)(n,h,r);i.imports&&i.imports.forEach(function(e){a(h.resolvePath(t,e))}),i.weakImports&&i.weakImports.forEach(function(e){a(h.resolvePath(t,e),!0)})}else h.setOptions(n.options).addJSON(n.nested)}catch(e){return void o(e)}c||d||o(null,h)}function a(e,t){var n=e.indexOf("google/protobuf/");if(n>-1){var r=e.substring(n);r in l&&(e=r)}if(!(h.files.indexOf(e)>-1)){if(h.files.push(e),e in l)return void(c?u(e,l[e]):(++d,setTimeout(function(){--d,u(e,l[e])})));if(c){var i;try{i=f.fs.readFileSync(e).toString("utf8")}catch(e){return void(t||o(e))}u(e,i)}else++d,f.fetch(e,function(n,r){if(--d,s)return n?void(t||o(n)):void u(e,r)})}}"function"==typeof r&&(s=r,r=void 0);var h=this;if(!s)return f.asPromise(t,h,n);var c=s===i,d=0;return f.isString(n)&&(n=[n]),n.forEach(function(e){a(h.resolvePath("",e))}),c?h:void(d||o(null,h))},u.loadSync=function(e){return this.load(e,i)},u.f=function(e){var t=this.deferred.slice();this.deferred=[];for(var n=0;n<t.length;)s(t[n])?t.splice(n,1):++n;if(this.deferred=t,e instanceof a&&void 0!==e.extend&&!e.extensionField&&!s(e)&&this.deferred.indexOf(e)<0)this.deferred.push(e);else if(e instanceof o){var r=e.getNestedArray();for(n=0;n<r.length;++n)this.f(r[n])}},u.g=function(e){if(e instanceof a){if(void 0!==e.extend&&!e.extensionField){var t=this.deferred.indexOf(e);t>-1&&this.deferred.splice(t,1)}e.extensionField&&(e.extensionField.parent.remove(e.extensionField),e.extensionField=null)}else if(e instanceof o)for(var n=e.getNestedArray(),r=0;r<n.length;++r)this.g(n[r])}},{13:13,17:17,21:21,24:24,33:33}],27:[function(e,t,n){"use strict";var r=n;r.Service=e(28)},{28:28}],28:[function(e,t,n){"use strict";function r(e){s.call(this),this.$rpc=e}t.exports=r;var i=e(33),s=i.EventEmitter,o=r.prototype=Object.create(s.prototype);o.constructor=r,o.end=function(e){return this.$rpc&&(e||this.$rpc(null,null,null),this.$rpc=null,this.emit("end").off()),this}},{33:33}],29:[function(e,t,n){"use strict";function r(e,t){s.call(this,e,t),this.methods={},this.k=null}function i(e){return e.k=null,e}t.exports=r,r.className="Service";var s=e(21),o=s.prototype,u=s.extend(r),a=e(20),f=e(33),l=e(27);f.props(u,{methodsArray:{get:function(){return this.k||(this.k=f.toArray(this.methods))}}}),r.testJSON=function(e){return Boolean(e&&e.methods)},r.fromJSON=function(e,t){var n=new r(e,t.options);return t.methods&&Object.keys(t.methods).forEach(function(e){n.add(a.fromJSON(e,t.methods[e]))}),n},u.toJSON=function(){var e=o.toJSON.call(this);return{options:e&&e.options||void 0,methods:s.arrayToJSON(this.getMethodsArray())||{},nested:e&&e.nested||void 0}},u.get=function(e){return o.get.call(this,e)||this.methods[e]||null},u.resolveAll=function(){for(var e=this.getMethodsArray(),t=0;t<e.length;++t)e[t].resolve();return o.resolve.call(this)},u.add=function(e){if(this.get(e.name))throw Error("duplicate name '"+e.name+"' in "+this);return e instanceof a?(this.methods[e.name]=e,e.parent=this,i(this)):o.add.call(this,e)},u.remove=function(e){if(e instanceof a){if(this.methods[e.name]!==e)throw Error(e+" is not a member of "+this);return delete this.methods[e.name],e.parent=null,i(this)}return o.remove.call(this,e)},u.create=function(e,t,n){var r=new l.Service(e);return this.getMethodsArray().forEach(function(i){r[i.name.substring(0,1).toLowerCase()+i.name.substring(1)]=function(s,o){if(r.$rpc){if(!s)throw f.b("request","not null");i.resolve();var u;try{u=(t?i.resolvedRequestType.encodeDelimited(s):i.resolvedRequestType.encode(s)).finish()}catch(e){return void("function"==typeof setImmediate?setImmediate:setTimeout)(function(){o(e)})}e(i,u,function(e,t){if(e)return r.emit("error",e,i),o?o(e):void 0;if(null===t)return void r.end(!0);var s;try{s=n?i.resolvedResponseType.decodeDelimited(t):i.resolvedResponseType.decode(t)}catch(e){return r.emit("error",e,i),o?o("error",e):void 0}return r.emit("data",s,i),o?o(null,s):void 0})}}}),r}},{20:20,21:21,27:27,33:33}],30:[function(e,t,n){"use strict";function r(e){return e.replace(/\\(.?)/g,function(e,t){switch(t){case"\\":case"":return t;case"0":return"\0";default:return t}})}function i(e){function t(e){return Error("illegal "+e+" (line "+p+")")}function n(){var n="'"===y?u:o;n.lastIndex=c-1;var i=n.exec(e);if(!i)throw t("string");return c=n.lastIndex,f(y),y=null,r(i[1])}function i(t){return e.charAt(t)}function a(){if(v.length>0)return v.shift();if(y)return n();var r,o,u;do{if(c===d)return null;for(r=!1;/\s/.test(u=i(c));)if("\n"===u&&++p,++c===d)return null;if("/"===i(c)){if(++c===d)throw t("comment");if("/"===i(c)){for(;"\n"!==i(++c);)if(c===d)return null;++c,++p,r=!0}else{if("*"!==(u=i(c)))return"/";do{if("\n"===u&&++p,++c===d)return null;o=u,u=i(c)}while("*"!==o||"/"!==u);++c,r=!0}}}while(r);if(c===d)return null;var a=c;s.lastIndex=0;var f=s.test(i(a++));if(!f)for(;a<d&&!s.test(i(a));)++a;var l=e.substring(c,c=a);return'"'!==l&&"'"!==l||(y=l),l}function f(e){v.push(e)}function l(){if(!v.length){var e=a();if(null===e)return null;f(e)}return v[0]}function h(e,n){var r=l(),i=r===e;if(i)return a(),!0;if(!n)throw t("token '"+r+"', '"+e+"' expected");return!1}e=e.toString();var c=0,d=e.length,p=1,v=[],y=null;return{line:function(){return p},next:a,peek:l,push:f,skip:h}}t.exports=i;var s=/[\s{}=;:[\],'"()<>]/g,o=/(?:"([^"\\]*(?:\\.[^"\\]*)*)")/g,u=/(?:'([^'\\]*(?:\\.[^'\\]*)*)')/g},{}],31:[function(e,t,n){"use strict";function r(e,t){a.call(this,e,t),this.fields={},this.oneofs=void 0,this.extensions=void 0,this.reserved=void 0,this.l=null,this.h=null,this.m=null,this.n=null,this.o=null}function i(e){return e.l=e.h=e.n=e.o=null,delete e.encode,delete e.decode,e}t.exports=r,r.className="Type";var s,o,u,a=e(21),f=a.prototype,l=a.extend(r),h=e(16),c=e(23),d=e(17),p=e(29),v=e(12),y=e(19),g=e(25),m=e(37),b=e(33);b.props(l,{fieldsById:{get:function(){if(this.l)return this.l;this.l={};for(var e=Object.keys(this.fields),t=0;t<e.length;++t){var n=this.fields[e[t]],r=n.id;if(this.l[r])throw Error("duplicate id "+r+" in "+this);this.l[r]=n}return this.l}},fieldsArray:{get:function(){return this.h||(this.h=b.toArray(this.fields))}},repeatedFieldsArray:{get:function(){return this.m||(this.m=this.getFieldsArray().filter(function(e){return e.repeated}))}},oneofsArray:{get:function(){return this.n||(this.n=b.toArray(this.oneofs))}},ctor:{get:function(){return this.o||(this.o=v.create(this).constructor)},set:function(e){if(e&&!(e.prototype instanceof y))throw b.b("ctor","a Message constructor");this.o=e}}}),r.testJSON=function(e){return Boolean(e&&e.fields)};var w=[h,r,d,p];r.fromJSON=function(e,t){var n=new r(e,t.options);return n.extensions=t.extensions,n.reserved=t.reserved,t.fields&&Object.keys(t.fields).forEach(function(e){n.add(d.fromJSON(e,t.fields[e]))}),t.oneofs&&Object.keys(t.oneofs).forEach(function(e){n.add(c.fromJSON(e,t.oneofs[e]))}),t.nested&&Object.keys(t.nested).forEach(function(e){for(var r=t.nested[e],i=0;i<w.length;++i)if(w[i].testJSON(r))return void n.add(w[i].fromJSON(e,r));throw Error("invalid nested object in "+n+": "+e)}),t.extensions&&t.extensions.length&&(n.extensions=t.extensions),t.reserved&&t.reserved.length&&(n.reserved=t.reserved),n},l.toJSON=function(){var e=f.toJSON.call(this);return{options:e&&e.options||void 0,oneofs:a.arrayToJSON(this.getOneofsArray()),fields:a.arrayToJSON(this.getFieldsArray().filter(function(e){return!e.declaringField}))||{},extensions:this.extensions&&this.extensions.length?this.extensions:void 0,reserved:this.reserved&&this.reserved.length?this.reserved:void 0,nested:e&&e.nested||void 0}},l.resolveAll=function(){for(var e=this.getFieldsArray(),t=0;t<e.length;)e[t++].resolve();var n=this.getOneofsArray();for(t=0;t<n.length;)n[t++].resolve();return f.resolve.call(this)},l.get=function(e){return f.get.call(this,e)||this.fields&&this.fields[e]||this.oneofs&&this.oneofs[e]||null},l.add=function(e){if(this.get(e.name))throw Error("duplicate name '"+e.name+"' in "+this);if(e instanceof d&&void 0===e.extend){if(this.getFieldsById()[e.id])throw Error("duplicate id "+e.id+" in "+this);return e.parent&&e.parent.remove(e),this.fields[e.name]=e,e.message=this,e.onAdd(this),i(this)}return e instanceof c?(this.oneofs||(this.oneofs={}),this.oneofs[e.name]=e,e.onAdd(this),i(this)):f.add.call(this,e)},l.remove=function(e){if(e instanceof d&&void 0===e.extend){if(this.fields[e.name]!==e)throw Error(e+" is not a member of "+this);return delete this.fields[e.name],e.message=null,i(this)}return f.remove.call(this,e)},l.create=function(e){return new(this.getCtor())(e)},l.encode=function(t,n){return s||(s=e(15)),(this.encode=b.codegen.supported?s.generate(this).eof(this.getFullName()+"$encode",{Writer:m,types:this.getFieldsArray().map(function(e){return e.resolvedType}),util:b}):s).call(this,t,n)},l.encodeDelimited=function(e,t){return this.encode(e,t&&t.len?t.fork():t).ldelim()},l.decode=function(t,n){return o||(o=e(14)),(this.decode=b.codegen.supported?o.generate(this).eof(this.getFullName()+"$decode",{Reader:g,types:this.getFieldsArray().map(function(e){return e.resolvedType}),util:b}):o).call(this,t,n)},l.decodeDelimited=function(e){return e=e instanceof g?e:g.create(e),this.decode(e,e.uint32())},l.verify=function(t){return u||(u=e(36)),(this.verify=b.codegen.supported?u.generate(this).eof(this.getFullName()+"$verify",{types:this.getFieldsArray().map(function(e){return e.resolvedType}),util:b}):u).call(this,t)}},{12:12,14:14,15:15,16:16,17:17,19:19,21:21,23:23,25:25,29:29,33:33,36:36,37:37}],32:[function(e,t,n){"use strict";function r(e,t){var n=0,r={};for(t|=0;n<e.length;)r[o[n+t]]=e[n++];return r}var i=n,s=e(33),o=["double","float","int32","uint32","sint32","fixed32","sfixed32","int64","uint64","sint64","fixed64","sfixed64","bool","string","bytes","message"];i.basic=r([1,5,0,0,0,5,5,0,0,0,1,1,0,2,2]),i.defaults=r([0,0,0,0,0,0,0,0,0,0,0,0,!1,"",s.emptyArray,null]),i.long=r([0,0,0,1,1],7),i.mapKey=r([0,0,0,5,5,0,0,0,1,1,0,2],2),i.packed=r([1,5,0,0,0,5,5,0,0,0,1,1,0])},{33:33}],33:[function(e,t,n){"use strict";var r=t.exports=e(35);r.asPromise=e(2),r.codegen=e(4),r.EventEmitter=e(5),r.extend=e(6),r.fetch=e(7),r.fs=e(8),r.path=e(9),r.toArray=function(e){if(!e)return[];for(var t=Object.keys(e),n=t.length,r=new Array(n),i=0;i<n;++i)r[i]=e[t[i]];return r},r.b=function(e,t){return TypeError(e+" must be "+(t||"a string"))},r.merge=function(e,t,n){if(t)for(var r=Object.keys(t),i=0;i<r.length;++i)void 0!==e[r[i]]&&n||(e[r[i]]=t[r[i]]);return e},r.safeProp=function(e){return'["'+e.replace(/\\/g,"\\\\").replace(/"/g,'\\"')+'"]'},r.camelCase=function(e){return e.substring(0,1)+e.substring(1).replace(/_([a-z])(?=[a-z]|$)/g,function(e,t){return t.toUpperCase()})},r.underScore=function(e){return e.substring(0,1)+e.substring(1).replace(/([A-Z])(?=[a-z]|$)/g,function(e,t){return"_"+t.toLowerCase()})},r.newBuffer=function(e){return e=e||0,r.Buffer?r.Buffer.allocUnsafe?r.Buffer.allocUnsafe(e):new r.Buffer(e):new("undefined"!=typeof Uint8Array?Uint8Array:Array)(e)}},{2:2,35:35,4:4,5:5,6:6,7:7,8:8,9:9}],34:[function(e,t,n){"use strict";function r(e,t){this.lo=e,this.hi=t}t.exports=r;var i=e(35),s=r.prototype,o=r.zero=new r(0,0);o.toNumber=function(){return 0},o.zzEncode=o.zzDecode=function(){return this},o.length=function(){return 1},r.fromNumber=function(e){if(0===e)return o;var t=e<0;e=Math.abs(e);var n=e>>>0,i=(e-n)/4294967296>>>0;return t&&(i=~i>>>0,n=~n>>>0,++n>4294967295&&(n=0,++i>4294967295&&(i=0))),new r(n,i)},r.from=function(e){if("number"==typeof e)return r.fromNumber(e);if("string"==typeof e){if(!i.Long)return r.fromNumber(parseInt(e,10));e=i.Long.fromString(e)}return e.low||e.high?new r(e.low>>>0,e.high>>>0):o},s.toNumber=function(e){return!e&&this.hi>>>31?(this.lo=~this.lo+1>>>0,this.hi=~this.hi>>>0,this.lo||(this.hi=this.hi+1>>>0),-(this.lo+4294967296*this.hi)):this.lo+4294967296*this.hi},s.toLong=function(e){return i.Long?new i.Long(this.lo,this.hi,e):{low:this.lo,high:this.hi,unsigned:Boolean(e)}};var u=String.prototype.charCodeAt;r.fromHash=function(e){return new r((u.call(e,0)|u.call(e,1)<<8|u.call(e,2)<<16|u.call(e,3)<<24)>>>0,(u.call(e,4)|u.call(e,5)<<8|u.call(e,6)<<16|u.call(e,7)<<24)>>>0)},s.toHash=function(){return String.fromCharCode(255&this.lo,this.lo>>>8&255,this.lo>>>16&255,this.lo>>>24&255,255&this.hi,this.hi>>>8&255,this.hi>>>16&255,this.hi>>>24&255)},s.zzEncode=function(){var e=this.hi>>31;return this.hi=((this.hi<<1|this.lo>>>31)^e)>>>0,this.lo=(this.lo<<1^e)>>>0,this},s.zzDecode=function(){var e=-(1&this.lo);return this.lo=((this.lo>>>1|this.hi<<31)^e)>>>0,this.hi=(this.hi>>>1^e)>>>0,this},s.length=function(){var e=this.lo,t=(this.lo>>>28|this.hi<<4)>>>0,n=this.hi>>>24;return 0===n?0===t?e<16384?e<128?1:2:e<1<<21?3:4:t<16384?t<128?5:6:t<1<<21?7:8:n<128?9:10}},{35:35}],35:[function(e,t,n){(function(t){"use strict";var r=n,i=r.LongBits=e(34);r.base64=e(3),r.utf8=e(11),r.pool=e(10);var s=r.isNode=Boolean(t.process&&t.process.versions&&t.process.versions.node);if(r.Buffer=null,s)try{r.Buffer=e("buffer").Buffer}catch(e){}if(r.Long=t.dcodeIO&&t.dcodeIO.Long||null,!r.Long&&s)try{r.Long=e("long")}catch(e){}r.isInteger=Number.isInteger||function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e},r.isString=function(e){return"string"==typeof e||e instanceof String},r.isObject=function(e){return Boolean(e&&"object"==typeof e)},r.longToHash=function(e){return e?i.from(e).toHash():"\0\0\0\0\0\0\0\0"},r.longFromHash=function(e,t){var n=i.fromHash(e);return r.Long?r.Long.fromBits(n.lo,n.hi,t):n.toNumber(Boolean(t))},r.longNeq=function(e,t){return"number"==typeof e?"number"==typeof t?e!==t:(e=i.fromNumber(e)).lo!==t.low||e.hi!==t.high:"number"==typeof t?(t=i.fromNumber(t)).lo!==e.low||t.hi!==e.high:e.low!==t.low||e.high!==t.high},r.longNe=function(e,t,n){if("object"==typeof e)return e.low!==t||e.high!==n;var i=r.LongBits.from(e);return i.lo!==t||i.hi!==n},r.props=function(e,t){Object.keys(t).forEach(function(n){r.prop(e,n,t[n])})},r.prop=function(e,t,n){var r=!-[1],i=t.substring(0,1).toUpperCase()+t.substring(1);n.get&&(e["get"+i]=n.get),n.set&&(e["set"+i]=r?function(e){n.set.call(this,e),this[t]=e}:n.set),r?void 0!==n.value&&(e[t]=n.value):Object.defineProperty(e,t,n)},r.emptyArray=Object.freeze([]),r.emptyObject=Object.freeze({})}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{10:10,11:11,3:3,34:34,buffer:"buffer",long:"long"}],36:[function(e,t,n){"use strict";function r(e,t){return"invalid value for field "+e.getFullName()+" ("+t+(e.repeated&&"array"!==t?"[]":e.map&&"object"!==t?"{k:"+e.keyType+"}":"")+" expected)"}function i(e,t){switch(e.type){case"double":case"float":if("number"!=typeof t)return r(e,"number");break;case"int32":case"uint32":case"sint32":case"fixed32":case"sfixed32":if(!c(t))return r(e,"integer");break;case"int64":case"uint64":case"sint64":case"fixed64":case"sfixed64":if(!(c(t)||t&&c(t.low)&&c(t.high)))return r(e,"integer|Long");break;case"bool":if("boolean"!=typeof t)return r(e,"boolean");break;case"string":if(!h.isString(t))return r(e,"string");break;case"bytes":if(!(t&&"number"==typeof t.length||h.isString(t)))return r(e,"buffer");break;default:if(e.resolvedType instanceof f){if("number"!=typeof e.resolvedType.getValuesById()[t])return r(e,"enum value")}else if(e.resolvedType instanceof l){var n=e.resolvedType.verify(t);if(n)return n}}return null}function s(e,t){switch(e.keyType){case"int64":case"uint64":case"sint64":case"fixed64":case"sfixed64":if(/^[\x00-\xff]{8}$/.test(t))return null;case"int32":case"uint32":case"sint32":case"fixed32":case"sfixed32":if(/^-?(?:0|[1-9]\d*)$/.test(t))return r(e,"integer key");break;case"bool":if(/^true|false|0|1$/.test(t))return r(e,"boolean key")}return null}function o(e){for(var t,n=this.getFieldsArray(),o=0;o<n.length;){var u=n[o++].resolve(),a=e[u.name];if(u.map){if(void 0!==a){if(!h.isObject(a))return r(u,"object");for(var f=Object.keys(a),l=0;l<f.length;++l){if(t=s(u,f[l]))return t;if(t=i(u,a[f[l]]))return t}}}else if(u.repeated){if(void 0!==a){if(!Array.isArray(a))return r(u,"array");for(var l=0;l<a.length;++l)if(t=i(u,a[l]))return t}}else if((u.required||void 0!==a)&&(t=i(u,a)))return t}return null}function u(e,t,n,i){switch(t.type){case"double":case"float":e('if(typeof %s!=="number")',i)("return%j",r(t,"number"));break;case"int32":case"uint32":case"sint32":case"fixed32":case"sfixed32":e("if(!util.isInteger(%s))",i)("return%j",r(t,"integer"));break;case"int64":case"uint64":case"sint64":case"fixed64":case"sfixed64":e("if(!(util.isInteger(%s)||%s&&util.isInteger(%s.low)&&util.isInteger(%s.high)))",i,i,i,i)("return%j",r(t,"integer|Long"));break;case"bool":e('if(typeof %s!=="boolean")',i)("return%j",r(t,"boolean"));break;case"string":e("if(!util.isString(%s))",i)("return%j",r(t,"string"));break;case"bytes":e('if(!(%s&&typeof %s.length==="number"||util.isString(%s)))',i,i,i)("return%j",r(t,"buffer"));break;default:if(t.resolvedType instanceof f){e("switch(%s){",i)("default:")("return%j",r(t,"enum value"));for(var s=h.toArray(t.resolvedType.values),o=0;o<s.length;++o)e("case %d:",s[o]);e("break")("}")}else t.resolvedType instanceof l&&e("var r;")("if(r=types[%d].verify(%s))",n,i)("return r")}}function a(e,t,n){switch(t.keyType){case"int64":case"uint64":case"sint64":case"fixed64":case"sfixed64":e("if(!/^(?:[\\x00-\\xff]{8}|-?(?:0|[1-9]\\d*))$/.test(%s))",n)("return%j",r(t,"integer|Long key"));break;case"int32":case"uint32":case"sint32":case"fixed32":case"sfixed32":e("if(!/^-?(?:0|[1-9]\\d*)$/.test(%s))",n)("return%j",r(t,"integer key"));break;case"bool":e("if(!/^true|false|0|1$/.test(%s))",n)("return%j",r(t,"boolean key"))}}t.exports=o;var f=e(16),l=e(31),h=e(33),c=h.isInteger;o.generate=function(e){for(var t=e.getFieldsArray(),n=h.codegen("m"),i=0;i<t.length;++i){var s=t[i].resolve(),o=h.safeProp(s.name);s.map?(n("if(m%s!==undefined){",o)("if(!util.isObject(m%s))",o)("return%j",r(s,"object"))("var k=Object.keys(m%s)",o)("for(var i=0;i<k.length;++i){"),a(n,s,"k[i]"),u(n,s,i,"m"+o+"[k[i]]"),n("}")("}")):s.repeated?(n("if(m%s!==undefined){",o)("if(!Array.isArray(m%s))",o)("return%j",r(s,"array"))("for(var i=0;i<m%s.length;++i){",o),u(n,s,i,"m"+o+"[i]"),n("}")("}")):(s.required||(s.resolvedType instanceof l?n("if(m%s!==undefined&&m%s!==null){",o,o):n("if(m%s!==undefined){",o)),u(n,s,i,"m"+o),s.required||n("}"))}return n("return null")}},{16:16,31:31,33:33}],37:[function(e,t,n){"use strict";function r(e,t,n){this.fn=e,this.val=t,this.len=n,this.next=null}function i(){}function s(e){this.head=e.head,this.tail=e.tail,this.len=e.len,this.next=e.states}function o(){this.len=0,this.head=new r(i,0,0),this.tail=this.head,this.states=null}function u(e,t,n){t[n]=255&e}function a(e,t,n){for(;e>127;)t[n++]=127&e|128,e>>>=7;t[n]=e}function f(e,t,n){for(;e.hi;)t[n++]=127&e.lo|128,e.lo=(e.lo>>>7|e.hi<<25)>>>0,e.hi>>>=7;for(;e.lo>127;)t[n++]=127&e.lo|128,e.lo=e.lo>>>7;t[n++]=e.lo}function l(e,t,n){t[n++]=255&e,t[n++]=e>>>8&255,t[n++]=e>>>16&255,t[n]=e>>>24}function h(){o.call(this)}function c(e,t,n){t.writeFloatLE(e,n,!0)}function d(e,t,n){t.writeDoubleLE(e,n,!0)}function p(e,t,n){e.length&&e.copy(t,n,0,e.length)}t.exports=o,o.BufferWriter=h;var v=e(35),y=e(1),g=v.LongBits,m=v.base64,b=v.utf8,w="undefined"!=typeof Uint8Array?Uint8Array:Array;o.Op=r,o.State=s,o.create=function(){return new(v.Buffer?h:o)},o.alloc=function(e){return new w(e)},w!==Array&&(o.alloc=v.pool(o.alloc,w.prototype.subarray||w.prototype.slice));var k=o.prototype;k.push=function(e,t,n){var i=new r(e,n,t);return this.tail.next=i,this.tail=i,this.len+=t,this},k.uint32=function(e){return e>>>=0,this.push(a,e<128?1:e<16384?2:e<2097152?3:e<268435456?4:5,e)},k.int32=function(e){return e<0?this.push(f,10,g.fromNumber(e)):this.uint32(e)},k.sint32=function(e){return this.uint32((e<<1^e>>31)>>>0)},k.uint64=function(e){var t=g.from(e);return this.push(f,t.length(),t)},k.int64=k.uint64,k.sint64=function(e){var t=g.from(e).zzEncode();return this.push(f,t.length(),t)},k.bool=function(e){return this.push(u,1,e?1:0)},k.fixed32=function(e){return this.push(l,4,e>>>0)},k.sfixed32=function(e){return this.push(l,4,e<<1^e>>31)},k.fixed64=function(e){var t=g.from(e);return this.push(l,4,t.lo).push(l,4,t.hi)},k.sfixed64=function(e){var t=g.from(e).zzEncode();return this.push(l,4,t.lo).push(l,4,t.hi)};var x="undefined"!=typeof Float32Array?function(){var e=new Float32Array(1),t=new Uint8Array(e.buffer);return e[0]=-0,t[3]?function(n,r,i){e[0]=n,r[i++]=t[0],r[i++]=t[1],r[i++]=t[2],r[i]=t[3]}:function(n,r,i){e[0]=n,r[i++]=t[3],r[i++]=t[2],r[i++]=t[1],r[i]=t[0]}}():function(e,t,n){y.write(t,e,n,!1,23,4)};k.float=function(e){return this.push(x,4,e)};var O="undefined"!=typeof Float64Array?function(){var e=new Float64Array(1),t=new Uint8Array(e.buffer);return e[0]=-0,t[7]?function(n,r,i){e[0]=n,r[i++]=t[0],r[i++]=t[1],r[i++]=t[2],r[i++]=t[3],r[i++]=t[4],r[i++]=t[5],r[i++]=t[6],r[i]=t[7]}:function(n,r,i){e[0]=n,r[i++]=t[7],r[i++]=t[6],r[i++]=t[5],r[i++]=t[4],r[i++]=t[3],r[i++]=t[2],r[i++]=t[1],r[i]=t[0]}}():function(e,t,n){y.write(t,e,n,!1,52,8)};k.double=function(e){return this.push(O,8,e)};var A=w.prototype.set?function(e,t,n){t.set(e,n)}:function(e,t,n){for(var r=0;r<e.length;++r)t[n+r]=e[r]};k.bytes=function(e){var t=e.length>>>0;if("string"==typeof e&&t){var n=o.alloc(t=m.length(e));m.decode(e,n,0),e=n}return t?this.uint32(t).push(A,t,e):this.push(u,1,0)},k.string=function(e){var t=b.length(e);return t?this.uint32(t).push(b.write,t,e):this.push(u,1,0)},k.fork=function(){return this.states=new s(this),this.head=this.tail=new r(i,0,0),this.len=0,this},k.reset=function(){return this.states?(this.head=this.states.head,this.tail=this.states.tail,this.len=this.states.len,this.states=this.states.next):(this.head=this.tail=new r(i,0,0),this.len=0),this},k.ldelim=function(e){var t=this.head,n=this.tail,r=this.len;return this.reset(),e&&this.uint32((e<<3|2)>>>0),this.uint32(r),this.tail.next=t.next,this.tail=n,this.len+=r,this},k.finish=function(){for(var e=this.head.next,t=this.constructor.alloc(this.len),n=0;e;)e.fn(e.val,t,n),n+=e.len,e=e.next;return this.head=this.tail=null,t},h.alloc=function(e){return h.alloc=v.Buffer.allocUnsafe?v.Buffer.allocUnsafe:function(e){return new v.Buffer(e)},h.alloc(e)};var N=h.prototype=Object.create(o.prototype);N.constructor=h,"undefined"==typeof Float32Array&&(N.float=function(e){return this.push(c,4,e)}),"undefined"==typeof Float64Array&&(N.double=function(e){return this.push(d,8,e)}),N.bytes=function(e){"string"==typeof e&&(e=v.Buffer.from?v.Buffer.from(e,"base64"):new v.Buffer(e,"base64"));var t=e.length>>>0;return t?this.uint32(t).push(p,t,e):this.push(u,1,0)};var S=function(){return v.Buffer&&v.Buffer.prototype.utf8Write?function(e,t,n){e.length<40?b.write(e,t,n):t.utf8Write(e,n)}:function(e,t,n){e.length<40?b.write(e,t,n):t.write(e,n)}}();N.string=function(e){var t=e.length<40?b.length(e):v.Buffer.byteLength(e);return t?this.uint32(t).push(S,t,e):this.push(u,1,0)}},{1:1,35:35}],38:[function(e,t,n){(function(t){"use strict";function r(e,t,n){return"function"==typeof t?(n=t,t=new o.Root):t||(t=new o.Root),t.load(e,n)}function i(e,t){return t||(t=new o.Root),t.loadSync(e)}function s(){a.j()}var o=t.protobuf=n;o.load=r,o.loadSync=i,o.roots={},o.tokenize=e(30),o.parse=e(24);var u=o.Writer=e(37);o.BufferWriter=u.BufferWriter;var a=o.Reader=e(25);o.BufferReader=a.BufferReader,o.encode=e(15),o.decode=e(14),o.verify=e(36),o.ReflectionObject=e(22),o.Namespace=e(21),o.Root=e(26),o.Enum=e(16),o.Type=e(31),o.Field=e(17),o.OneOf=e(23),o.MapField=e(18),o.Service=e(29),o.Method=e(20),o.Class=e(12),o.Message=e(19),o.types=e(32),o.common=e(13),o.rpc=e(27),o.util=e(33),o.configure=s,"function"==typeof define&&define.amd&&define(["long"],function(e){return e&&(o.util.Long=e,s()),o})}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{12:12,13:13,14:14,15:15,16:16,17:17,18:18,19:19,20:20,21:21,22:22,23:23,24:24,25:25,26:26,27:27,29:29,30:30,31:31,32:32,33:33,36:36,37:37}]},{},[38]);
//# sourceMappingURL=protobuf.min.js.map