eve
Version:
Filesystem-first framework for durable backend AI agents that run anywhere.
1 lines • 239 kB
JavaScript
import{a as e,t}from"../../_chunks/workflow/rolldown-runtime-DPpTSio4.js";import{C as n}from"../../_chunks/workflow/esm-DyLz8Egm.js";var r=t(((e,t)=>{t.exports=n;function n(e,t){for(var n=Array(arguments.length-1),r=0,i=2,a=!0;i<arguments.length;)n[r++]=arguments[i++];return new Promise(function(i,o){n[r]=function(e){if(a){if(a=!1,e)o(e);else{for(var t=Array(arguments.length-1),n=0;n<t.length;)t[n++]=arguments[n];i.apply(null,t)}}};try{e.apply(t||null,n)}catch(e){a&&(a=!1,o(e))}})}})),i=t((e=>{var t=e;t.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(e.length*3)/4-n};for(var n=Array(64),r=Array(123),i=0;i<64;)r[n[i]=i<26?i+65:i<52?i+71:i<62?i-4:i-59|43]=i++;t.encode=function(e,t,r){for(var i=null,a=[],o=0,s=0,c;t<r;){var l=e[t++];switch(s){case 0:a[o++]=n[l>>2],c=(l&3)<<4,s=1;break;case 1:a[o++]=n[c|l>>4],c=(l&15)<<2,s=2;break;case 2:a[o++]=n[c|l>>6],a[o++]=n[l&63],s=0}o>8191&&((i||=[]).push(String.fromCharCode.apply(String,a)),o=0)}return s&&(a[o++]=n[c],a[o++]=61,s===1&&(a[o++]=61)),i?(o&&i.push(String.fromCharCode.apply(String,a.slice(0,o))),i.join(``)):String.fromCharCode.apply(String,a.slice(0,o))};var a=`invalid encoding`;t.decode=function(e,t,n){for(var i=n,o=0,s,c=0;c<e.length;){var l=e.charCodeAt(c++);if(l===61&&o>1)break;if((l=r[l])===void 0)throw Error(a);switch(o){case 0:s=l,o=1;break;case 1:t[n++]=s<<2|(l&48)>>4,s=l,o=2;break;case 2:t[n++]=(s&15)<<4|(l&60)>>2,s=l,o=3;break;case 3:t[n++]=(s&3)<<6|l,o=0}}if(o===1)throw Error(a);return n-i},t.test=function(e){return/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/.test(e)}})),a=t(((e,t)=>{t.exports=n;function n(){this._listeners=Object.create(null)}n.prototype.on=function(e,t,n){return(this._listeners[e]||(this._listeners[e]=[])).push({fn:t,ctx:n||this}),this},n.prototype.off=function(e,t){if(e===void 0)this._listeners=Object.create(null);else if(t===void 0)this._listeners[e]=[];else{var n=this._listeners[e];if(!n)return this;for(var r=0;r<n.length;)n[r].fn===t?n.splice(r,1):++r}return this},n.prototype.emit=function(e){var t=this._listeners[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}})),o=t(((e,t)=>{t.exports=n(n);function n(e){return typeof Float32Array<`u`?(function(){var t=new Float32Array([-0]),n=new Uint8Array(t.buffer),r=n[3]===128;function i(e,r,i){t[0]=e,r[i]=n[0],r[i+1]=n[1],r[i+2]=n[2],r[i+3]=n[3]}function a(e,r,i){t[0]=e,r[i]=n[3],r[i+1]=n[2],r[i+2]=n[1],r[i+3]=n[0]}e.writeFloatLE=r?i:a,e.writeFloatBE=r?a:i;function o(e,r){return n[0]=e[r],n[1]=e[r+1],n[2]=e[r+2],n[3]=e[r+3],t[0]}function s(e,r){return n[3]=e[r],n[2]=e[r+1],n[1]=e[r+2],n[0]=e[r+3],t[0]}e.readFloatLE=r?o:s,e.readFloatBE=r?s:o})():(function(){function t(e,t,n,r){var i=+(t<0);if(i&&(t=-t),t===0)e(1/t>0?0:2147483648,n,r);else if(isNaN(t))e(2143289344,n,r);else if(t>34028234663852886e22)e((i<<31|2139095040)>>>0,n,r);else if(t<11754943508222875e-54)e((i<<31|Math.round(t/1401298464324817e-60))>>>0,n,r);else{var a=Math.floor(Math.log(t)/Math.LN2),o=Math.round(t*2**-a*8388608)&8388607;e((i<<31|a+127<<23|o)>>>0,n,r)}}e.writeFloatLE=t.bind(null,r),e.writeFloatBE=t.bind(null,i);function n(e,t,n){var r=e(t,n),i=(r>>31)*2+1,a=r>>>23&255,o=r&8388607;return a===255?o?NaN:i*(1/0):a===0?i*1401298464324817e-60*o:i*2**(a-150)*(o+8388608)}e.readFloatLE=n.bind(null,a),e.readFloatBE=n.bind(null,o)})(),typeof Float64Array<`u`?(function(){var t=new Float64Array([-0]),n=new Uint8Array(t.buffer),r=n[7]===128;function i(e,r,i){t[0]=e,r[i]=n[0],r[i+1]=n[1],r[i+2]=n[2],r[i+3]=n[3],r[i+4]=n[4],r[i+5]=n[5],r[i+6]=n[6],r[i+7]=n[7]}function a(e,r,i){t[0]=e,r[i]=n[7],r[i+1]=n[6],r[i+2]=n[5],r[i+3]=n[4],r[i+4]=n[3],r[i+5]=n[2],r[i+6]=n[1],r[i+7]=n[0]}e.writeDoubleLE=r?i:a,e.writeDoubleBE=r?a:i;function o(e,r){return n[0]=e[r],n[1]=e[r+1],n[2]=e[r+2],n[3]=e[r+3],n[4]=e[r+4],n[5]=e[r+5],n[6]=e[r+6],n[7]=e[r+7],t[0]}function s(e,r){return n[7]=e[r],n[6]=e[r+1],n[5]=e[r+2],n[4]=e[r+3],n[3]=e[r+4],n[2]=e[r+5],n[1]=e[r+6],n[0]=e[r+7],t[0]}e.readDoubleLE=r?o:s,e.readDoubleBE=r?s:o})():(function(){function t(e,t,n,r,i,a){var o=+(r<0);if(o&&(r=-r),r===0)e(0,i,a+t),e(1/r>0?0:2147483648,i,a+n);else if(isNaN(r))e(0,i,a+t),e(2146959360,i,a+n);else if(r>17976931348623157e292)e(0,i,a+t),e((o<<31|2146435072)>>>0,i,a+n);else{var s;if(r<22250738585072014e-324)s=r/5e-324,e(s>>>0,i,a+t),e((o<<31|s/4294967296)>>>0,i,a+n);else{var c=Math.floor(Math.log(r)/Math.LN2);c===1024&&(c=1023),s=r*2**-c,e(s*4503599627370496>>>0,i,a+t),e((o<<31|c+1023<<20|s*1048576&1048575)>>>0,i,a+n)}}}e.writeDoubleLE=t.bind(null,r,0,4),e.writeDoubleBE=t.bind(null,i,4,0);function n(e,t,n,r,i){var a=e(r,i+t),o=e(r,i+n),s=(o>>31)*2+1,c=o>>>20&2047,l=4294967296*(o&1048575)+a;return c===2047?l?NaN:s*(1/0):c===0?s*5e-324*l:s*2**(c-1075)*(l+4503599627370496)}e.readDoubleLE=n.bind(null,a,0,4),e.readDoubleBE=n.bind(null,o,4,0)})(),e}function r(e,t,n){t[n]=e&255,t[n+1]=e>>>8&255,t[n+2]=e>>>16&255,t[n+3]=e>>>24}function i(e,t,n){t[n]=e>>>24,t[n+1]=e>>>16&255,t[n+2]=e>>>8&255,t[n+3]=e&255}function a(e,t){return(e[t]|e[t+1]<<8|e[t+2]<<16|e[t+3]<<24)>>>0}function o(e,t){return(e[t]<<24|e[t+1]<<16|e[t+2]<<8|e[t+3])>>>0}})),s=t((e=>{var t=e,n=65533;t.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:(n&64512)==55296&&(e.charCodeAt(r+1)&64512)==56320?(++r,t+=4):t+=3;return t},t.read=function(e,t,r){if(r-t<1)return``;for(var i=null,a=[],o=0,s,c,l,u;t<r;)s=e[t++],s<=127?a[o++]=s:s>=192&&s<224?(l=(s&31)<<6|e[t++]&63,a[o++]=l>=128?l:n):s>=224&&s<240?(u=(s&15)<<12|(e[t++]&63)<<6|e[t++]&63,a[o++]=u>=2048?u:n):s>=240&&(c=(s&7)<<18|(e[t++]&63)<<12|(e[t++]&63)<<6|e[t++]&63,c<65536||c>1114111?a[o++]=n:(c-=65536,a[o++]=55296+(c>>10),a[o++]=56320+(c&1023))),o>8191&&((i||=[]).push(String.fromCharCode.apply(String,a.slice(0,o))),o=0);return i?(o&&i.push(String.fromCharCode.apply(String,a.slice(0,o))),i.join(``)):String.fromCharCode.apply(String,a.slice(0,o))},t.write=function(e,t,n){for(var r=n,i,a,o=0;o<e.length;++o)i=e.charCodeAt(o),i<128?t[n++]=i:i<2048?(t[n++]=i>>6|192,t[n++]=i&63|128):(i&64512)==55296&&((a=e.charCodeAt(o+1))&64512)==56320?(i=65536+((i&1023)<<10)+(a&1023),++o,t[n++]=i>>18|240,t[n++]=i>>12&63|128,t[n++]=i>>6&63|128,t[n++]=i&63|128):(t[n++]=i>>12|224,t[n++]=i>>6&63|128,t[n++]=i&63|128);return n-r}})),c=t(((e,t)=>{t.exports=n;function n(e,t,n){var r=n||8192,i=r>>>1,a=null,o=r;return function(n){if(n<1||n>i)return e(n);o+n>r&&(a=e(r),o=0);var s=t.call(a,o,o+=n);return o&7&&(o=(o|7)+1),s}}})),l=t(((e,t)=>{t.exports=r;var n=d();function r(e,t){this.lo=e>>>0,this.hi=t>>>0}var i=r.zero=new r(0,0);i.toNumber=function(){return 0},i.zzEncode=i.zzDecode=function(){return this},i.length=function(){return 1};var a=r.zeroHash=`\0\0\0\0\0\0\0\0`;r.fromNumber=function(e){if(e===0)return i;var t=e<0;t&&(e=-e);var n=e>>>0,a=(e-n)/4294967296>>>0;return t&&(a=~a>>>0,n=~n>>>0,++n>4294967295&&(n=0,++a>4294967295&&(a=0))),new r(n,a)},r.from=function(e){if(typeof e==`number`)return r.fromNumber(e);if(n.isString(e)){if(n.Long)e=n.Long.fromString(e);else return r.fromNumber(parseInt(e,10))}return e.low||e.high?new r(e.low>>>0,e.high>>>0):i},r.prototype.toNumber=function(e){if(!e&&this.hi>>>31){var t=~this.lo+1>>>0,n=~this.hi>>>0;return t||(n=n+1>>>0),-(t+n*4294967296)}return this.lo+this.hi*4294967296},r.prototype.toLong=function(e){return n.Long?new n.Long(this.lo|0,this.hi|0,!!e):{low:this.lo|0,high:this.hi|0,unsigned:!!e}};var o=String.prototype.charCodeAt;r.fromHash=function(e){return e===a?i:new r((o.call(e,0)|o.call(e,1)<<8|o.call(e,2)<<16|o.call(e,3)<<24)>>>0,(o.call(e,4)|o.call(e,5)<<8|o.call(e,6)<<16|o.call(e,7)<<24)>>>0)},r.prototype.toHash=function(){return String.fromCharCode(this.lo&255,this.lo>>>8&255,this.lo>>>16&255,this.lo>>>24,this.hi&255,this.hi>>>8&255,this.hi>>>16&255,this.hi>>>24)},r.prototype.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},r.prototype.zzDecode=function(){var e=-(this.lo&1);return this.lo=((this.lo>>>1|this.hi<<31)^e)>>>0,this.hi=(this.hi>>>1^e)>>>0,this},r.prototype.length=function(){var e=this.lo,t=(this.lo>>>28|this.hi<<4)>>>0,n=this.hi>>>24;return n===0?t===0?e<16384?e<128?1:2:e<2097152?3:4:t<16384?t<128?5:6:t<2097152?7:8:n<128?9:10}})),u=t(((e,t)=>{(function(n,r){function i(e){return e.default||e}typeof define==`function`&&define.amd?define([],function(){var e={};return r(e),i(e)}):typeof e==`object`?(r(e),typeof t==`object`&&(t.exports=i(e))):(function(){var e={};r(e),n.Long=i(e)})()})(typeof globalThis<`u`?globalThis:typeof self<`u`?self:e,function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var t=null;try{t=new WebAssembly.Instance(new WebAssembly.Module(new Uint8Array([0,97,115,109,1,0,0,0,1,13,2,96,0,1,127,96,4,127,127,127,127,1,127,3,7,6,0,1,1,1,1,1,6,6,1,127,1,65,0,11,7,50,6,3,109,117,108,0,1,5,100,105,118,95,115,0,2,5,100,105,118,95,117,0,3,5,114,101,109,95,115,0,4,5,114,101,109,95,117,0,5,8,103,101,116,95,104,105,103,104,0,0,10,191,1,6,4,0,35,0,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,126,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,127,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,128,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,129,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,130,34,4,66,32,135,167,36,0,32,4,167,11])),{}).exports}catch{}function n(e,t,n){this.low=e|0,this.high=t|0,this.unsigned=!!n}n.prototype.__isLong__,Object.defineProperty(n.prototype,"__isLong__",{value:!0});function r(e){return(e&&e.__isLong__)===!0}function i(e){var t=Math.clz32(e&-e);return e?31-t:t}n.isLong=r;var a={},o={};function s(e,t){var n,r,i;return t?(e>>>=0,(i=0<=e&&e<256)&&(r=o[e],r)?r:(n=l(e,0,!0),i&&(o[e]=n),n)):(e|=0,(i=-128<=e&&e<128)&&(r=a[e],r)?r:(n=l(e,e<0?-1:0,!1),i&&(a[e]=n),n))}n.fromInt=s;function c(e,t){if(isNaN(e))return t?b:y;if(t){if(e<0)return b;if(e>=g)return T}else{if(e<=-_)return E;if(e+1>=_)return w}return e<0?c(-e,t).neg():l(e%h|0,e/h|0,t)}n.fromNumber=c;function l(e,t,r){return new n(e,t,r)}n.fromBits=l;var u=Math.pow;function d(e,t,n){if(e.length===0)throw Error(`empty string`);if(typeof t==`number`?(n=t,t=!1):t=!!t,e===`NaN`||e===`Infinity`||e===`+Infinity`||e===`-Infinity`)return t?b:y;if(n||=10,n<2||36<n)throw RangeError(`radix`);var r;if((r=e.indexOf(`-`))>0)throw Error(`interior hyphen`);if(r===0)return d(e.substring(1),t,n).neg();for(var i=c(u(n,8)),a=y,o=0;o<e.length;o+=8){var s=Math.min(8,e.length-o),l=parseInt(e.substring(o,o+s),n);if(s<8){var f=c(u(n,s));a=a.mul(f).add(c(l))}else a=a.mul(i),a=a.add(c(l))}return a.unsigned=t,a}n.fromString=d;function f(e,t){return typeof e==`number`?c(e,t):typeof e==`string`?d(e,t):l(e.low,e.high,typeof t==`boolean`?t:e.unsigned)}n.fromValue=f;var p=65536,m=1<<24,h=p*p,g=h*h,_=g/2,v=s(m),y=s(0);n.ZERO=y;var b=s(0,!0);n.UZERO=b;var x=s(1);n.ONE=x;var S=s(1,!0);n.UONE=S;var C=s(-1);n.NEG_ONE=C;var w=l(-1,2147483647,!1);n.MAX_VALUE=w;var T=l(-1,-1,!0);n.MAX_UNSIGNED_VALUE=T;var E=l(0,-2147483648,!1);n.MIN_VALUE=E;var D=n.prototype;D.toInt=function(){return this.unsigned?this.low>>>0:this.low},D.toNumber=function(){return this.unsigned?(this.high>>>0)*h+(this.low>>>0):this.high*h+(this.low>>>0)},D.toString=function(e){if(e||=10,e<2||36<e)throw RangeError(`radix`);if(this.isZero())return`0`;if(this.isNegative()){if(this.eq(E)){var t=c(e),n=this.div(t),r=n.mul(t).sub(this);return n.toString(e)+r.toInt().toString(e)}return`-`+this.neg().toString(e)}for(var i=c(u(e,6),this.unsigned),a=this,o=``;;){var s=a.div(i),l=(a.sub(s.mul(i)).toInt()>>>0).toString(e);if(a=s,a.isZero())return l+o;for(;l.length<6;)l=`0`+l;o=``+l+o}},D.getHighBits=function(){return this.high},D.getHighBitsUnsigned=function(){return this.high>>>0},D.getLowBits=function(){return this.low},D.getLowBitsUnsigned=function(){return this.low>>>0},D.getNumBitsAbs=function(){if(this.isNegative())return this.eq(E)?64:this.neg().getNumBitsAbs();for(var e=this.high==0?this.low:this.high,t=31;t>0&&!(e&1<<t);t--);return this.high==0?t+1:t+33},D.isSafeInteger=function(){var e=this.high>>21;return!e||!this.unsigned&&e===-1&&(this.low!==0||this.high!==-2097152)},D.isZero=function(){return this.high===0&&this.low===0},D.eqz=D.isZero,D.isNegative=function(){return!this.unsigned&&this.high<0},D.isPositive=function(){return this.unsigned||this.high>=0},D.isOdd=function(){return(this.low&1)==1},D.isEven=function(){return!(this.low&1)},D.equals=function(e){return r(e)||(e=f(e)),this.unsigned!==e.unsigned&&this.high>>>31==1&&e.high>>>31==1?!1:this.high===e.high&&this.low===e.low},D.eq=D.equals,D.notEquals=function(e){return!this.eq(e)},D.neq=D.notEquals,D.ne=D.notEquals,D.lessThan=function(e){return this.comp(e)<0},D.lt=D.lessThan,D.lessThanOrEqual=function(e){return this.comp(e)<=0},D.lte=D.lessThanOrEqual,D.le=D.lessThanOrEqual,D.greaterThan=function(e){return this.comp(e)>0},D.gt=D.greaterThan,D.greaterThanOrEqual=function(e){return this.comp(e)>=0},D.gte=D.greaterThanOrEqual,D.ge=D.greaterThanOrEqual,D.compare=function(e){if(r(e)||(e=f(e)),this.eq(e))return 0;var t=this.isNegative(),n=e.isNegative();return t&&!n?-1:!t&&n?1:this.unsigned?e.high>>>0>this.high>>>0||e.high===this.high&&e.low>>>0>this.low>>>0?-1:1:this.sub(e).isNegative()?-1:1},D.comp=D.compare,D.negate=function(){return!this.unsigned&&this.eq(E)?E:this.not().add(x)},D.neg=D.negate,D.add=function(e){r(e)||(e=f(e));var t=this.high>>>16,n=this.high&65535,i=this.low>>>16,a=this.low&65535,o=e.high>>>16,s=e.high&65535,c=e.low>>>16,u=e.low&65535,d=0,p=0,m=0,h=0;return h+=a+u,m+=h>>>16,h&=65535,m+=i+c,p+=m>>>16,m&=65535,p+=n+s,d+=p>>>16,p&=65535,d+=t+o,d&=65535,l(m<<16|h,d<<16|p,this.unsigned)},D.subtract=function(e){return r(e)||(e=f(e)),this.add(e.neg())},D.sub=D.subtract,D.multiply=function(e){if(this.isZero())return this;if(r(e)||(e=f(e)),t)return l(t.mul(this.low,this.high,e.low,e.high),t.get_high(),this.unsigned);if(e.isZero())return this.unsigned?b:y;if(this.eq(E))return e.isOdd()?E:y;if(e.eq(E))return this.isOdd()?E:y;if(this.isNegative())return e.isNegative()?this.neg().mul(e.neg()):this.neg().mul(e).neg();if(e.isNegative())return this.mul(e.neg()).neg();if(this.lt(v)&&e.lt(v))return c(this.toNumber()*e.toNumber(),this.unsigned);var n=this.high>>>16,i=this.high&65535,a=this.low>>>16,o=this.low&65535,s=e.high>>>16,u=e.high&65535,d=e.low>>>16,p=e.low&65535,m=0,h=0,g=0,_=0;return _+=o*p,g+=_>>>16,_&=65535,g+=a*p,h+=g>>>16,g&=65535,g+=o*d,h+=g>>>16,g&=65535,h+=i*p,m+=h>>>16,h&=65535,h+=a*d,m+=h>>>16,h&=65535,h+=o*u,m+=h>>>16,h&=65535,m+=n*p+i*d+a*u+o*s,m&=65535,l(g<<16|_,m<<16|h,this.unsigned)},D.mul=D.multiply,D.divide=function(e){if(r(e)||(e=f(e)),e.isZero())throw Error(`division by zero`);if(t)return!this.unsigned&&this.high===-2147483648&&e.low===-1&&e.high===-1?this:l((this.unsigned?t.div_u:t.div_s)(this.low,this.high,e.low,e.high),t.get_high(),this.unsigned);if(this.isZero())return this.unsigned?b:y;var n,i,a;if(this.unsigned){if(e.unsigned||(e=e.toUnsigned()),e.gt(this))return b;if(e.gt(this.shru(1)))return S;a=b}else{if(this.eq(E))return e.eq(x)||e.eq(C)?E:e.eq(E)?x:(n=this.shr(1).div(e).shl(1),n.eq(y)?e.isNegative()?x:C:(i=this.sub(e.mul(n)),a=n.add(i.div(e)),a));if(e.eq(E))return this.unsigned?b:y;if(this.isNegative())return e.isNegative()?this.neg().div(e.neg()):this.neg().div(e).neg();if(e.isNegative())return this.div(e.neg()).neg();a=y}for(i=this;i.gte(e);){n=Math.max(1,Math.floor(i.toNumber()/e.toNumber()));for(var o=Math.ceil(Math.log(n)/Math.LN2),s=o<=48?1:u(2,o-48),d=c(n),p=d.mul(e);p.isNegative()||p.gt(i);)n-=s,d=c(n,this.unsigned),p=d.mul(e);d.isZero()&&(d=x),a=a.add(d),i=i.sub(p)}return a},D.div=D.divide,D.modulo=function(e){return r(e)||(e=f(e)),t?l((this.unsigned?t.rem_u:t.rem_s)(this.low,this.high,e.low,e.high),t.get_high(),this.unsigned):this.sub(this.div(e).mul(e))},D.mod=D.modulo,D.rem=D.modulo,D.not=function(){return l(~this.low,~this.high,this.unsigned)},D.countLeadingZeros=function(){return this.high?Math.clz32(this.high):Math.clz32(this.low)+32},D.clz=D.countLeadingZeros,D.countTrailingZeros=function(){return this.low?i(this.low):i(this.high)+32},D.ctz=D.countTrailingZeros,D.and=function(e){return r(e)||(e=f(e)),l(this.low&e.low,this.high&e.high,this.unsigned)},D.or=function(e){return r(e)||(e=f(e)),l(this.low|e.low,this.high|e.high,this.unsigned)},D.xor=function(e){return r(e)||(e=f(e)),l(this.low^e.low,this.high^e.high,this.unsigned)},D.shiftLeft=function(e){return r(e)&&(e=e.toInt()),(e&=63)==0?this:e<32?l(this.low<<e,this.high<<e|this.low>>>32-e,this.unsigned):l(0,this.low<<e-32,this.unsigned)},D.shl=D.shiftLeft,D.shiftRight=function(e){return r(e)&&(e=e.toInt()),(e&=63)==0?this:e<32?l(this.low>>>e|this.high<<32-e,this.high>>e,this.unsigned):l(this.high>>e-32,this.high>=0?0:-1,this.unsigned)},D.shr=D.shiftRight,D.shiftRightUnsigned=function(e){return r(e)&&(e=e.toInt()),(e&=63)==0?this:e<32?l(this.low>>>e|this.high<<32-e,this.high>>>e,this.unsigned):l(e===32?this.high:this.high>>>e-32,0,this.unsigned)},D.shru=D.shiftRightUnsigned,D.shr_u=D.shiftRightUnsigned,D.rotateLeft=function(e){var t;return r(e)&&(e=e.toInt()),(e&=63)==0?this:e===32?l(this.high,this.low,this.unsigned):e<32?(t=32-e,l(this.low<<e|this.high>>>t,this.high<<e|this.low>>>t,this.unsigned)):(e-=32,t=32-e,l(this.high<<e|this.low>>>t,this.low<<e|this.high>>>t,this.unsigned))},D.rotl=D.rotateLeft,D.rotateRight=function(e){var t;return r(e)&&(e=e.toInt()),(e&=63)==0?this:e===32?l(this.high,this.low,this.unsigned):e<32?(t=32-e,l(this.high<<t|this.low>>>e,this.low<<t|this.high>>>e,this.unsigned)):(e-=32,t=32-e,l(this.low<<t|this.high>>>e,this.high<<t|this.low>>>e,this.unsigned))},D.rotr=D.rotateRight,D.toSigned=function(){return this.unsigned?l(this.low,this.high,!1):this},D.toUnsigned=function(){return this.unsigned?this:l(this.low,this.high,!0)},D.toBytes=function(e){return e?this.toBytesLE():this.toBytesBE()},D.toBytesLE=function(){var e=this.high,t=this.low;return[t&255,t>>>8&255,t>>>16&255,t>>>24,e&255,e>>>8&255,e>>>16&255,e>>>24]},D.toBytesBE=function(){var e=this.high,t=this.low;return[e>>>24,e>>>16&255,e>>>8&255,e&255,t>>>24,t>>>16&255,t>>>8&255,t&255]},n.fromBytes=function(e,t,r){return r?n.fromBytesLE(e,t):n.fromBytesBE(e,t)},n.fromBytesLE=function(e,t){return new n(e[0]|e[1]<<8|e[2]<<16|e[3]<<24,e[4]|e[5]<<8|e[6]<<16|e[7]<<24,t)},n.fromBytesBE=function(e,t){return new n(e[4]<<24|e[5]<<16|e[6]<<8|e[7],e[0]<<24|e[1]<<16|e[2]<<8|e[3],t)},typeof BigInt==`function`&&(n.fromBigInt=function(e,t){return l(Number(BigInt.asIntN(32,e)),Number(BigInt.asIntN(32,e>>BigInt(32))),t)},n.fromValue=function(e,t){return typeof e==`bigint`?n.fromBigInt(e,t):f(e,t)},D.toBigInt=function(){var e=BigInt(this.low>>>0);return BigInt(this.unsigned?this.high>>>0:this.high)<<BigInt(32)|e}),e.default=n})})),d=t((e=>{var t=e;t.asPromise=r(),t.base64=i(),t.EventEmitter=a(),t.float=o(),t.utf8=s(),t.pool=c(),t.LongBits=l();function n(e){return e===`__proto__`||e===`prototype`||e===`constructor`}t.isUnsafeProperty=n,t.isNode=!!(typeof global<`u`&&global&&global.process&&global.process.versions&&global.process.versions.node),t.global=t.isNode&&global||typeof window<`u`&&window||typeof self<`u`&&self||e,t.emptyArray=Object.freeze?Object.freeze([]):[],t.emptyObject=Object.freeze?Object.freeze({}):{},t.isInteger=Number.isInteger||function(e){return typeof e==`number`&&isFinite(e)&&Math.floor(e)===e},t.isString=function(e){return typeof e==`string`||e instanceof String},t.isObject=function(e){return e&&typeof e==`object`},t.isset=t.isSet=function(e,t){var n=e[t];return n!=null&&Object.hasOwnProperty.call(e,t)?typeof n!=`object`||(Array.isArray(n)?n.length:Object.keys(n).length)>0:!1},t.Buffer=(function(){try{var e=t.global.Buffer;return e.prototype.utf8Write?e:null}catch{return null}})(),t._Buffer_from=null,t._Buffer_allocUnsafe=null,t.newBuffer=function(e){return typeof e==`number`?t.Buffer?t._Buffer_allocUnsafe(e):new t.Array(e):t.Buffer?t._Buffer_from(e):typeof Uint8Array>`u`?e:new Uint8Array(e)},t.Array=typeof Uint8Array<`u`?Uint8Array:Array,t.Long=t.global.dcodeIO&&t.global.dcodeIO.Long||t.global.Long||(function(){try{var e=u();return e&&e.isLong?e:null}catch{return null}})(),t.key2Re=/^true|false|0|1$/,t.key32Re=/^-?(?:0|[1-9][0-9]*)$/,t.key64Re=/^(?:[\\x00-\\xff]{8}|-?(?:0|[1-9][0-9]*))$/,t.longToHash=function(e){return e?t.LongBits.from(e).toHash():t.LongBits.zeroHash},t.longFromHash=function(e,n){var r=t.LongBits.fromHash(e);return t.Long?t.Long.fromBits(r.lo,r.hi,n):r.toNumber(!!n)};function d(e){var t=typeof arguments[arguments.length-1]==`boolean`,r=t?arguments.length-1:arguments.length;t&&=arguments[arguments.length-1];for(var i=1;i<r;++i){var a=arguments[i];if(a)for(var o=Object.keys(a),s=0;s<o.length;++s)!n(o[s])&&(e[o[s]]===void 0||!t)&&(e[o[s]]=a[o[s]])}return e}t.merge=d,t.nestingLimit=32,t.recursionLimit=100,t.makeProp=function(e,t){Object.defineProperty(e,t,{enumerable:!0,configurable:!0,writable:!0})},t.lcFirst=function(e){return e.charAt(0).toLowerCase()+e.substring(1)};function f(e){function t(e,n){if(!(this instanceof t))return new t(e,n);Object.defineProperty(this,"message",{get:function(){return e}}),Error.captureStackTrace?Error.captureStackTrace(this,t):Object.defineProperty(this,"stack",{value:Error().stack||``}),n&&d(this,n)}return t.prototype=Object.create(Error.prototype,{constructor:{value:t,writable:!0,enumerable:!1,configurable:!0},name:{get:function(){return e},set:void 0,enumerable:!1,configurable:!0},toString:{value:function(){return this.name+`: `+this.message},writable:!0,enumerable:!1,configurable:!0}}),t}t.newError=f,t.ProtocolError=f(`ProtocolError`),t.oneOfGetter=function(e){for(var t={},n=0;n<e.length;++n)t[e[n]]=1;return function(){for(var e=Object.keys(this),n=e.length-1;n>-1;--n)if(t[e[n]]===1&&this[e[n]]!==void 0&&this[e[n]]!==null)return e[n]}},t.oneOfSetter=function(e){return function(t){for(var n=0;n<e.length;++n)e[n]!==t&&delete this[e[n]]}},t.toJSONOptions={longs:String,enums:String,bytes:String,json:!0},t._configure=function(){var e=t.Buffer;if(!e){t._Buffer_from=t._Buffer_allocUnsafe=null;return}t._Buffer_from=e.from!==Uint8Array.from&&e.from||function(t,n){return new e(t,n)},t._Buffer_allocUnsafe=e.allocUnsafe||function(t){return new e(t)}}})),f=t(((e,t)=>{t.exports=u;var n=d(),r,i=n.LongBits,a=n.base64,o=n.utf8;function s(e,t,n){this.fn=e,this.len=t,this.next=void 0,this.val=n}function c(){}function l(e){this.head=e.head,this.tail=e.tail,this.len=e.len,this.next=e.states}function u(){this.len=0,this.head=new s(c,0,0),this.tail=this.head,this.states=null}var f=function(){return n.Buffer?function(){return(u.create=function(){return new r})()}:function(){return new u}};u.create=f(),u.alloc=function(e){return new n.Array(e)},n.Array!==Array&&(u.alloc=n.pool(u.alloc,n.Array.prototype.subarray)),u.prototype._push=function(e,t,n){return this.tail=this.tail.next=new s(e,t,n),this.len+=t,this};function p(e,t,n){t[n]=e&255}function m(e,t,n){for(;e>127;)t[n++]=e&127|128,e>>>=7;t[n]=e}function h(e,t){this.len=e,this.next=void 0,this.val=t}h.prototype=Object.create(s.prototype),h.prototype.fn=m,u.prototype.uint32=function(e){return this.len+=(this.tail=this.tail.next=new h((e>>>=0)<128?1:e<16384?2:e<2097152?3:e<268435456?4:5,e)).len,this},u.prototype.int32=function(e){return(e|=0)<0?this._push(g,10,i.fromNumber(e)):this.uint32(e)},u.prototype.sint32=function(e){return this.uint32((e<<1^e>>31)>>>0)};function g(e,t,n){for(var r=e.lo,i=e.hi;i;)t[n++]=r&127|128,r=(r>>>7|i<<25)>>>0,i>>>=7;for(;r>127;)t[n++]=r&127|128,r>>>=7;t[n++]=r}u.prototype.uint64=function(e){var t=i.from(e);return this._push(g,t.length(),t)},u.prototype.int64=u.prototype.uint64,u.prototype.sint64=function(e){var t=i.from(e).zzEncode();return this._push(g,t.length(),t)},u.prototype.bool=function(e){return this._push(p,1,+!!e)};function _(e,t,n){t[n]=e&255,t[n+1]=e>>>8&255,t[n+2]=e>>>16&255,t[n+3]=e>>>24}u.prototype.fixed32=function(e){return this._push(_,4,e>>>0)},u.prototype.sfixed32=u.prototype.fixed32,u.prototype.fixed64=function(e){var t=i.from(e);return this._push(_,4,t.lo)._push(_,4,t.hi)},u.prototype.sfixed64=u.prototype.fixed64,u.prototype.float=function(e){return this._push(n.float.writeFloatLE,4,e)},u.prototype.double=function(e){return this._push(n.float.writeDoubleLE,8,e)};var v=n.Array.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]};u.prototype.bytes=function(e){var t=e.length>>>0;if(!t)return this._push(p,1,0);if(n.isString(e)){var r=u.alloc(t=a.length(e));a.decode(e,r,0),e=r}return this.uint32(t)._push(v,t,e)},u.prototype.string=function(e){var t=o.length(e);return t?this.uint32(t)._push(o.write,t,e):this._push(p,1,0)},u.prototype.fork=function(){return this.states=new l(this),this.head=this.tail=new s(c,0,0),this.len=0,this},u.prototype.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 s(c,0,0),this.len=0),this},u.prototype.ldelim=function(){var e=this.head,t=this.tail,n=this.len;return this.reset().uint32(n),n&&(this.tail.next=e.next,this.tail=t,this.len+=n),this},u.prototype.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 t},u._configure=function(e){r=e,u.create=f(),r._configure()}})),p=t(((e,t)=>{t.exports=i;var n=f();(i.prototype=Object.create(n.prototype)).constructor=i;var r=d();function i(){n.call(this)}i._configure=function(){i.alloc=r._Buffer_allocUnsafe,i.writeBytesBuffer=r.Buffer&&r.Buffer.prototype instanceof Uint8Array&&r.Buffer.prototype.set.name===`set`?function(e,t,n){t.set(e,n)}:function(e,t,n){if(e.copy)e.copy(t,n,0,e.length);else for(var r=0;r<e.length;)t[n++]=e[r++]}},i.prototype.bytes=function(e){r.isString(e)&&(e=r._Buffer_from(e,`base64`));var t=e.length>>>0;return this.uint32(t),t&&this._push(i.writeBytesBuffer,t,e),this};function a(e,t,n){e.length<40?r.utf8.write(e,t,n):t.utf8Write?t.utf8Write(e,n):t.write(e,n)}i.prototype.string=function(e){var t=r.Buffer.byteLength(e);return this.uint32(t),t&&this._push(a,t,e),this},i._configure()})),m=t(((e,t)=>{t.exports=s;var n=d(),r,i=n.LongBits,a=n.utf8;function o(e,t){return RangeError(`index out of range: `+e.pos+` + `+(t||1)+` > `+e.len)}function s(e){this.buf=e,this.pos=0,this.len=e.length}var c=typeof Uint8Array<`u`?function(e){if(e instanceof Uint8Array||Array.isArray(e))return new s(e);throw Error(`illegal buffer`)}:function(e){if(Array.isArray(e))return new s(e);throw Error(`illegal buffer`)},l=function(){return n.Buffer?function(e){return(s.create=function(e){return n.Buffer.isBuffer(e)?new r(e):c(e)})(e)}:c};s.create=l(),s.prototype._slice=n.Array.prototype.subarray||n.Array.prototype.slice;function u(e){for(var t=0,n=0;n<4;++n){if(e.pos>=e.len)throw o(e);var r=e.buf[e.pos++];if(t=(t|(r&127)<<n*7)>>>0,r<128)return t}throw o(e)}s.prototype.uint32=(function(){var e=4294967295;return function(){if(this.len-this.pos<5){if(this.pos>=this.len)throw o(this);if(this.buf[this.pos]>=128)return u(this)}if(e=(this.buf[this.pos]&127)>>>0,this.buf[this.pos++]<128||(e=(e|(this.buf[this.pos]&127)<<7)>>>0,this.buf[this.pos++]<128)||(e=(e|(this.buf[this.pos]&127)<<14)>>>0,this.buf[this.pos++]<128)||(e=(e|(this.buf[this.pos]&127)<<21)>>>0,this.buf[this.pos++]<128)||(e=(e|(this.buf[this.pos]&15)<<28)>>>0,this.buf[this.pos++]<128))return e;if((this.pos+=5)>this.len)throw this.pos=this.len,o(this,10);return e}})(),s.prototype.int32=function(){return this.uint32()|0},s.prototype.sint32=function(){var e=this.uint32();return e>>>1^-(e&1)|0};function f(){var e=new i(0,0),t=0;if(this.len-this.pos>4){for(;t<4;++t)if(e.lo=(e.lo|(this.buf[this.pos]&127)<<t*7)>>>0,this.buf[this.pos++]<128)return e;if(e.lo=(e.lo|(this.buf[this.pos]&127)<<28)>>>0,e.hi=(e.hi|(this.buf[this.pos]&127)>>4)>>>0,this.buf[this.pos++]<128)return e;t=0}else{for(;t<3;++t){if(this.pos>=this.len)throw o(this);if(e.lo=(e.lo|(this.buf[this.pos]&127)<<t*7)>>>0,this.buf[this.pos++]<128)return e}return e.lo=(e.lo|(this.buf[this.pos++]&127)<<t*7)>>>0,e}if(this.len-this.pos>4){for(;t<5;++t)if(e.hi=(e.hi|(this.buf[this.pos]&127)<<t*7+3)>>>0,this.buf[this.pos++]<128)return e}else for(;t<5;++t){if(this.pos>=this.len)throw o(this);if(e.hi=(e.hi|(this.buf[this.pos]&127)<<t*7+3)>>>0,this.buf[this.pos++]<128)return e}throw Error(`invalid varint encoding`)}s.prototype.bool=function(){return this.uint32()!==0};function p(e,t){return(e[t-4]|e[t-3]<<8|e[t-2]<<16|e[t-1]<<24)>>>0}s.prototype.fixed32=function(){if(this.pos+4>this.len)throw o(this,4);return p(this.buf,this.pos+=4)},s.prototype.sfixed32=function(){if(this.pos+4>this.len)throw o(this,4);return p(this.buf,this.pos+=4)|0};function m(){if(this.pos+8>this.len)throw o(this,8);return new i(p(this.buf,this.pos+=4),p(this.buf,this.pos+=4))}s.prototype.float=function(){if(this.pos+4>this.len)throw o(this,4);var e=n.float.readFloatLE(this.buf,this.pos);return this.pos+=4,e},s.prototype.double=function(){if(this.pos+8>this.len)throw o(this,4);var e=n.float.readDoubleLE(this.buf,this.pos);return this.pos+=8,e},s.prototype.bytes=function(){var e=this.uint32(),t=this.pos,r=this.pos+e;if(r>this.len)throw o(this,e);if(this.pos+=e,Array.isArray(this.buf))return this.buf.slice(t,r);if(t===r){var i=n.Buffer;return i?i.alloc(0):new this.buf.constructor(0)}return this._slice.call(this.buf,t,r)},s.prototype.string=function(){var e=this.bytes();return a.read(e,0,e.length)},s.prototype.skip=function(e){if(typeof e==`number`){if(this.pos+e>this.len)throw o(this,e);this.pos+=e}else do if(this.pos>=this.len)throw o(this);while(this.buf[this.pos++]&128);return this},s.recursionLimit=n.recursionLimit,s.prototype.skipType=function(e,t){if(t===void 0&&(t=0),t>s.recursionLimit)throw Error(`maximum nesting depth exceeded`);switch(e){case 0:this.skip();break;case 1:this.skip(8);break;case 2:this.skip(this.uint32());break;case 3:for(;(e=this.uint32()&7)!=4;)this.skipType(e,t+1);break;case 5:this.skip(4);break;default:throw Error(`invalid wire type `+e+` at offset `+this.pos)}return this},s._configure=function(e){r=e,s.create=l(),r._configure();var t=n.Long?`toLong`:`toNumber`;n.merge(s.prototype,{int64:function(){return f.call(this)[t](!1)},uint64:function(){return f.call(this)[t](!0)},sint64:function(){return f.call(this).zzDecode()[t](!1)},fixed64:function(){return m.call(this)[t](!0)},sfixed64:function(){return m.call(this)[t](!1)}})}})),h=t(((e,t)=>{t.exports=i;var n=m();(i.prototype=Object.create(n.prototype)).constructor=i;var r=d();function i(e){n.call(this,e)}i._configure=function(){r.Buffer&&(i.prototype._slice=r.Buffer.prototype.slice)},i.prototype.string=function(){var e=this.uint32();return this.buf.utf8Slice?this.buf.utf8Slice(this.pos,this.pos=Math.min(this.pos+e,this.len)):this.buf.toString(`utf-8`,this.pos,this.pos=Math.min(this.pos+e,this.len))},i._configure()})),g=t(((e,t)=>{t.exports=r;var n=d();(r.prototype=Object.create(n.EventEmitter.prototype)).constructor=r;function r(e,t,r){if(typeof e!=`function`)throw TypeError(`rpcImpl must be a function`);n.EventEmitter.call(this),this.rpcImpl=e,this.requestDelimited=!!t,this.responseDelimited=!!r}r.prototype.rpcCall=function e(t,r,i,a,o){if(!a)throw TypeError(`request must be specified`);var s=this;if(!o)return n.asPromise(e,s,t,r,i,a);if(!s.rpcImpl){setTimeout(function(){o(Error(`already ended`))},0);return}try{return s.rpcImpl(t,r[s.requestDelimited?`encodeDelimited`:`encode`](a).finish(),function(e,n){if(e)return s.emit(`error`,e,t),o(e);if(n===null){s.end(!0);return}if(!(n instanceof i))try{n=i[s.responseDelimited?`decodeDelimited`:`decode`](n)}catch(e){return s.emit(`error`,e,t),o(e)}return s.emit(`data`,n,t),o(null,n)})}catch(e){s.emit(`error`,e,t),setTimeout(function(){o(e)},0);return}},r.prototype.end=function(e){return this.rpcImpl&&(e||this.rpcImpl(null,null,null),this.rpcImpl=null,this.emit(`end`).off()),this}})),_=t((e=>{var t=e;t.Service=g()})),v=t(((e,t)=>{t.exports=Object.create(null)})),y=t((e=>{var t=e;t.build=`minimal`,t.Writer=f(),t.BufferWriter=p(),t.Reader=m(),t.BufferReader=h(),t.util=d(),t.rpc=_(),t.roots=v(),t.configure=n;function n(){t.util._configure(),t.Writer._configure(t.BufferWriter),t.Reader._configure(t.BufferReader)}n()})),b=t(((e,t)=>{t.exports=y()})),x=t(((e,t)=>{var n=b(),r=n.Reader,i=n.Writer,a=n.util,o=n.roots.default||(n.roots.default={});o.opentelemetry=(function(){var e={};return e.proto=(function(){var e={};return e.common=(function(){var e={};return e.v1=(function(){var e={};return e.AnyValue=(function(){function e(e){if(e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}e.prototype.stringValue=null,e.prototype.boolValue=null,e.prototype.intValue=null,e.prototype.doubleValue=null,e.prototype.arrayValue=null,e.prototype.kvlistValue=null,e.prototype.bytesValue=null;var t;return Object.defineProperty(e.prototype,"value",{get:a.oneOfGetter(t=[`stringValue`,`boolValue`,`intValue`,`doubleValue`,`arrayValue`,`kvlistValue`,`bytesValue`]),set:a.oneOfSetter(t)}),e.create=function(t){return new e(t)},e.encode=function(e,t){return t||=i.create(),e.stringValue!=null&&Object.hasOwnProperty.call(e,`stringValue`)&&t.uint32(10).string(e.stringValue),e.boolValue!=null&&Object.hasOwnProperty.call(e,`boolValue`)&&t.uint32(16).bool(e.boolValue),e.intValue!=null&&Object.hasOwnProperty.call(e,`intValue`)&&t.uint32(24).int64(e.intValue),e.doubleValue!=null&&Object.hasOwnProperty.call(e,`doubleValue`)&&t.uint32(33).double(e.doubleValue),e.arrayValue!=null&&Object.hasOwnProperty.call(e,`arrayValue`)&&o.opentelemetry.proto.common.v1.ArrayValue.encode(e.arrayValue,t.uint32(42).fork()).ldelim(),e.kvlistValue!=null&&Object.hasOwnProperty.call(e,`kvlistValue`)&&o.opentelemetry.proto.common.v1.KeyValueList.encode(e.kvlistValue,t.uint32(50).fork()).ldelim(),e.bytesValue!=null&&Object.hasOwnProperty.call(e,`bytesValue`)&&t.uint32(58).bytes(e.bytesValue),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.common.v1.AnyValue;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.stringValue=e.string();break;case 2:a.boolValue=e.bool();break;case 3:a.intValue=e.int64();break;case 4:a.doubleValue=e.double();break;case 5:a.arrayValue=o.opentelemetry.proto.common.v1.ArrayValue.decode(e,e.uint32());break;case 6:a.kvlistValue=o.opentelemetry.proto.common.v1.KeyValueList.decode(e,e.uint32());break;case 7:a.bytesValue=e.bytes();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;var t={};if(e.stringValue!=null&&e.hasOwnProperty(`stringValue`)&&(t.value=1,!a.isString(e.stringValue)))return`stringValue: string expected`;if(e.boolValue!=null&&e.hasOwnProperty(`boolValue`)){if(t.value===1)return`value: multiple values`;if(t.value=1,typeof e.boolValue!=`boolean`)return`boolValue: boolean expected`}if(e.intValue!=null&&e.hasOwnProperty(`intValue`)){if(t.value===1)return`value: multiple values`;if(t.value=1,!a.isInteger(e.intValue)&&!(e.intValue&&a.isInteger(e.intValue.low)&&a.isInteger(e.intValue.high)))return`intValue: integer|Long expected`}if(e.doubleValue!=null&&e.hasOwnProperty(`doubleValue`)){if(t.value===1)return`value: multiple values`;if(t.value=1,typeof e.doubleValue!=`number`)return`doubleValue: number expected`}if(e.arrayValue!=null&&e.hasOwnProperty(`arrayValue`)){if(t.value===1)return`value: multiple values`;t.value=1;var n=o.opentelemetry.proto.common.v1.ArrayValue.verify(e.arrayValue);if(n)return`arrayValue.`+n}if(e.kvlistValue!=null&&e.hasOwnProperty(`kvlistValue`)){if(t.value===1)return`value: multiple values`;t.value=1;var n=o.opentelemetry.proto.common.v1.KeyValueList.verify(e.kvlistValue);if(n)return`kvlistValue.`+n}if(e.bytesValue!=null&&e.hasOwnProperty(`bytesValue`)){if(t.value===1)return`value: multiple values`;if(t.value=1,!(e.bytesValue&&typeof e.bytesValue.length==`number`||a.isString(e.bytesValue)))return`bytesValue: buffer expected`}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.common.v1.AnyValue)return e;var t=new o.opentelemetry.proto.common.v1.AnyValue;if(e.stringValue!=null&&(t.stringValue=String(e.stringValue)),e.boolValue!=null&&(t.boolValue=!!e.boolValue),e.intValue!=null&&(a.Long?(t.intValue=a.Long.fromValue(e.intValue)).unsigned=!1:typeof e.intValue==`string`?t.intValue=parseInt(e.intValue,10):typeof e.intValue==`number`?t.intValue=e.intValue:typeof e.intValue==`object`&&(t.intValue=new a.LongBits(e.intValue.low>>>0,e.intValue.high>>>0).toNumber())),e.doubleValue!=null&&(t.doubleValue=Number(e.doubleValue)),e.arrayValue!=null){if(typeof e.arrayValue!=`object`)throw TypeError(`.opentelemetry.proto.common.v1.AnyValue.arrayValue: object expected`);t.arrayValue=o.opentelemetry.proto.common.v1.ArrayValue.fromObject(e.arrayValue)}if(e.kvlistValue!=null){if(typeof e.kvlistValue!=`object`)throw TypeError(`.opentelemetry.proto.common.v1.AnyValue.kvlistValue: object expected`);t.kvlistValue=o.opentelemetry.proto.common.v1.KeyValueList.fromObject(e.kvlistValue)}return e.bytesValue!=null&&(typeof e.bytesValue==`string`?a.base64.decode(e.bytesValue,t.bytesValue=a.newBuffer(a.base64.length(e.bytesValue)),0):e.bytesValue.length>=0&&(t.bytesValue=e.bytesValue)),t},e.toObject=function(e,t){t||={};var n={};return e.stringValue!=null&&e.hasOwnProperty(`stringValue`)&&(n.stringValue=e.stringValue,t.oneofs&&(n.value=`stringValue`)),e.boolValue!=null&&e.hasOwnProperty(`boolValue`)&&(n.boolValue=e.boolValue,t.oneofs&&(n.value=`boolValue`)),e.intValue!=null&&e.hasOwnProperty(`intValue`)&&(n.intValue=typeof e.intValue==`number`?t.longs===String?String(e.intValue):e.intValue:t.longs===String?a.Long.prototype.toString.call(e.intValue):t.longs===Number?new a.LongBits(e.intValue.low>>>0,e.intValue.high>>>0).toNumber():e.intValue,t.oneofs&&(n.value=`intValue`)),e.doubleValue!=null&&e.hasOwnProperty(`doubleValue`)&&(n.doubleValue=t.json&&!isFinite(e.doubleValue)?String(e.doubleValue):e.doubleValue,t.oneofs&&(n.value=`doubleValue`)),e.arrayValue!=null&&e.hasOwnProperty(`arrayValue`)&&(n.arrayValue=o.opentelemetry.proto.common.v1.ArrayValue.toObject(e.arrayValue,t),t.oneofs&&(n.value=`arrayValue`)),e.kvlistValue!=null&&e.hasOwnProperty(`kvlistValue`)&&(n.kvlistValue=o.opentelemetry.proto.common.v1.KeyValueList.toObject(e.kvlistValue,t),t.oneofs&&(n.value=`kvlistValue`)),e.bytesValue!=null&&e.hasOwnProperty(`bytesValue`)&&(n.bytesValue=t.bytes===String?a.base64.encode(e.bytesValue,0,e.bytesValue.length):t.bytes===Array?Array.prototype.slice.call(e.bytesValue):e.bytesValue,t.oneofs&&(n.value=`bytesValue`)),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.common.v1.AnyValue`},e})(),e.ArrayValue=(function(){function e(e){if(this.values=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.values=a.emptyArray,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.values!=null&&e.values.length)for(var n=0;n<e.values.length;++n)o.opentelemetry.proto.common.v1.AnyValue.encode(e.values[n],t.uint32(10).fork()).ldelim();return t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.common.v1.ArrayValue;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.values&&a.values.length||(a.values=[]),a.values.push(o.opentelemetry.proto.common.v1.AnyValue.decode(e,e.uint32()));break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.values!=null&&e.hasOwnProperty(`values`)){if(!Array.isArray(e.values))return`values: array expected`;for(var t=0;t<e.values.length;++t){var n=o.opentelemetry.proto.common.v1.AnyValue.verify(e.values[t]);if(n)return`values.`+n}}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.common.v1.ArrayValue)return e;var t=new o.opentelemetry.proto.common.v1.ArrayValue;if(e.values){if(!Array.isArray(e.values))throw TypeError(`.opentelemetry.proto.common.v1.ArrayValue.values: array expected`);t.values=[];for(var n=0;n<e.values.length;++n){if(typeof e.values[n]!=`object`)throw TypeError(`.opentelemetry.proto.common.v1.ArrayValue.values: object expected`);t.values[n]=o.opentelemetry.proto.common.v1.AnyValue.fromObject(e.values[n])}}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.values=[]),e.values&&e.values.length){n.values=[];for(var r=0;r<e.values.length;++r)n.values[r]=o.opentelemetry.proto.common.v1.AnyValue.toObject(e.values[r],t)}return n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.common.v1.ArrayValue`},e})(),e.KeyValueList=(function(){function e(e){if(this.values=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.values=a.emptyArray,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.values!=null&&e.values.length)for(var n=0;n<e.values.length;++n)o.opentelemetry.proto.common.v1.KeyValue.encode(e.values[n],t.uint32(10).fork()).ldelim();return t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.common.v1.KeyValueList;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.values&&a.values.length||(a.values=[]),a.values.push(o.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.values!=null&&e.hasOwnProperty(`values`)){if(!Array.isArray(e.values))return`values: array expected`;for(var t=0;t<e.values.length;++t){var n=o.opentelemetry.proto.common.v1.KeyValue.verify(e.values[t]);if(n)return`values.`+n}}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.common.v1.KeyValueList)return e;var t=new o.opentelemetry.proto.common.v1.KeyValueList;if(e.values){if(!Array.isArray(e.values))throw TypeError(`.opentelemetry.proto.common.v1.KeyValueList.values: array expected`);t.values=[];for(var n=0;n<e.values.length;++n){if(typeof e.values[n]!=`object`)throw TypeError(`.opentelemetry.proto.common.v1.KeyValueList.values: object expected`);t.values[n]=o.opentelemetry.proto.common.v1.KeyValue.fromObject(e.values[n])}}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.values=[]),e.values&&e.values.length){n.values=[];for(var r=0;r<e.values.length;++r)n.values[r]=o.opentelemetry.proto.common.v1.KeyValue.toObject(e.values[r],t)}return n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.common.v1.KeyValueList`},e})(),e.KeyValue=(function(){function e(e){if(e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.key=null,e.prototype.value=null,e.create=function(t){return new e(t)},e.encode=function(e,t){return t||=i.create(),e.key!=null&&Object.hasOwnProperty.call(e,`key`)&&t.uint32(10).string(e.key),e.value!=null&&Object.hasOwnProperty.call(e,`value`)&&o.opentelemetry.proto.common.v1.AnyValue.encode(e.value,t.uint32(18).fork()).ldelim(),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.common.v1.KeyValue;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.key=e.string();break;case 2:a.value=o.opentelemetry.proto.common.v1.AnyValue.decode(e,e.uint32());break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.key!=null&&e.hasOwnProperty(`key`)&&!a.isString(e.key))return`key: string expected`;if(e.value!=null&&e.hasOwnProperty(`value`)){var t=o.opentelemetry.proto.common.v1.AnyValue.verify(e.value);if(t)return`value.`+t}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.common.v1.KeyValue)return e;var t=new o.opentelemetry.proto.common.v1.KeyValue;if(e.key!=null&&(t.key=String(e.key)),e.value!=null){if(typeof e.value!=`object`)throw TypeError(`.opentelemetry.proto.common.v1.KeyValue.value: object expected`);t.value=o.opentelemetry.proto.common.v1.AnyValue.fromObject(e.value)}return t},e.toObject=function(e,t){t||={};var n={};return t.defaults&&(n.key=``,n.value=null),e.key!=null&&e.hasOwnProperty(`key`)&&(n.key=e.key),e.value!=null&&e.hasOwnProperty(`value`)&&(n.value=o.opentelemetry.proto.common.v1.AnyValue.toObject(e.value,t)),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.common.v1.KeyValue`},e})(),e.InstrumentationScope=(function(){function e(e){if(this.attributes=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.name=null,e.prototype.version=null,e.prototype.attributes=a.emptyArray,e.prototype.droppedAttributesCount=null,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.name!=null&&Object.hasOwnProperty.call(e,`name`)&&t.uint32(10).string(e.name),e.version!=null&&Object.hasOwnProperty.call(e,`version`)&&t.uint32(18).string(e.version),e.attributes!=null&&e.attributes.length)for(var n=0;n<e.attributes.length;++n)o.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[n],t.uint32(26).fork()).ldelim();return e.droppedAttributesCount!=null&&Object.hasOwnProperty.call(e,`droppedAttributesCount`)&&t.uint32(32).uint32(e.droppedAttributesCount),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.common.v1.InstrumentationScope;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.name=e.string();break;case 2:a.version=e.string();break;case 3:a.attributes&&a.attributes.length||(a.attributes=[]),a.attributes.push(o.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break;case 4:a.droppedAttributesCount=e.uint32();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.name!=null&&e.hasOwnProperty(`name`)&&!a.isString(e.name))return`name: string expected`;if(e.version!=null&&e.hasOwnProperty(`version`)&&!a.isString(e.version))return`version: string expected`;if(e.attributes!=null&&e.hasOwnProperty(`attributes`)){if(!Array.isArray(e.attributes))return`attributes: array expected`;for(var t=0;t<e.attributes.length;++t){var n=o.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[t]);if(n)return`attributes.`+n}}return e.droppedAttributesCount!=null&&e.hasOwnProperty(`droppedAttributesCount`)&&!a.isInteger(e.droppedAttributesCount)?`droppedAttributesCount: integer expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.common.v1.InstrumentationScope)return e;var t=new o.opentelemetry.proto.common.v1.InstrumentationScope;if(e.name!=null&&(t.name=String(e.name)),e.version!=null&&(t.version=String(e.version)),e.attributes){if(!Array.isArray(e.attributes))throw TypeError(`.opentelemetry.proto.common.v1.InstrumentationScope.attributes: array expected`);t.attributes=[];for(var n=0;n<e.attributes.length;++n){if(typeof e.attributes[n]!=`object`)throw TypeError(`.opentelemetry.proto.common.v1.InstrumentationScope.attributes: object expected`);t.attributes[n]=o.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[n])}}return e.droppedAttributesCount!=null&&(t.droppedAttributesCount=e.droppedAttributesCount>>>0),t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.attributes=[]),t.defaults&&(n.name=``,n.version=``,n.droppedAttributesCount=0),e.name!=null&&e.hasOwnProperty(`name`)&&(n.name=e.name),e.version!=null&&e.hasOwnProperty(`version`)&&(n.version=e.version),e.attributes&&e.attributes.length){n.attributes=[];for(var r=0;r<e.attributes.length;++r)n.attributes[r]=o.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[r],t)}return e.droppedAttributesCount!=null&&e.hasOwnProperty(`droppedAttributesCount`)&&(n.droppedAttributesCount=e.droppedAttributesCount),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.common.v1.InstrumentationScope`},e})(),e.EntityRef=(function(){function e(e){if(this.idKeys=[],this.descriptionKeys=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.schemaUrl=null,e.prototype.type=null,e.prototype.idKeys=a.emptyArray,e.prototype.descriptionKeys=a.emptyArray,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.schemaUrl!=null&&Object.hasOwnProperty.call(e,`schemaUrl`)&&t.uint32(10).string(e.schemaUrl),e.type!=null&&Object.hasOwnProperty.call(e,`type`)&&t.uint32(18).string(e.type),e.idKeys!=null&&e.idKeys.length)for(var n=0;n<e.idKeys.length;++n)t.uint32(26).string(e.idKeys[n]);if(e.descriptionKeys!=null&&e.descriptionKeys.length)for(var n=0;n<e.descriptionKeys.length;++n)t.uint32(34).string(e.descriptionKeys[n]);return t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.common.v1.EntityRef;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.schemaUrl=e.string();break;case 2:a.type=e.string();break;case 3:a.idKeys&&a.idKeys.length||(a.idKeys=[]),a.idKeys.push(e.string());break;case 4:a.descriptionKeys&&a.descriptionKeys.length||(a.descriptionKeys=[]),a.descriptionKeys.push(e.string());break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.schemaUrl!=null&&e.hasOwnProperty(`schemaUrl`)&&!a.isString(e.schemaUrl))return`schemaUrl: string expected`;if(e.type!=null&&e.hasOwnProperty(`type`)&&!a.isString(e.type))return`type: string expected`;if(e.idKeys!=null&&e.hasOwnProperty(`idKeys`)){if(!Array.isArray(e.idKeys))return`idKeys: array expected`;for(var t=0;t<e.idKeys.length;++t)if(!a.isString(e.idKeys[t]))return`idKeys: string[] expected`}if(e.descriptionKeys!=null&&e.hasOwnProperty(`descriptionKeys`)){if(!Array.isArray(e.descriptionKeys))return`descriptionKeys: array expected`;for(var t=0;t<e.descriptionKeys.length;++t)if(!a.isString(e.descriptionKeys[t]))return`descriptionKeys: string[] expected`}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.common.v1.EntityRef)return e;var t=new o.opentelemetry.proto.common.v1.EntityRef;if(e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),e.type!=null&&(t.type=String(e.type)),e.idKeys){if(!Array.isArray(e.idKeys))throw TypeError(`.opentelemetry.proto.common.v1.EntityRef.idKeys: array expected`);t.idKeys=[];for(var n=0;n<e.idKeys.length;++n)t.idKeys[n]=String(e.idKeys[n])}if(e.descriptionKeys){if(!Array.isArray(e.descriptionKeys))throw TypeError(`.opentelemetry.proto.common.v1.EntityRef.descriptionKeys: array expected`);t.descriptionKeys=[];for(var n=0;n<e.descriptionKeys.length;++n)t.descriptionKeys[n]=String(e.descriptionKeys[n])}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.idKeys=[],n.descriptionKeys=[]),t.defaults&&(n.schemaUrl=``,n.type=``),e.schemaUrl!=null&&e.hasOwnProperty(`schemaUrl`)&&(n.schemaUrl=e.schemaUrl),e.type!=null&&e.hasOwnProperty(`type`)&&(n.type=e.type),e.idKeys&&e.idKeys.length){n.idKeys=[];for(var r=0;r<e.idKeys.length;++r)n.idKeys[r]=e.idKeys[r]}if(e.descriptionKeys&&e.descriptionKeys.length){n.descriptionKeys=[];for(var r=0;r<e.descriptionKeys.length;++r)n.descriptionKeys[r]=e.descriptionKeys[r]}return n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.common.v1.EntityRef`},e})(),e})(),e})(),e.resource=(function(){var e={};return e.v1=(function(){var e={};return e.Resource=(function(){function e(e){if(this.attributes=[],this.entityRefs=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.attributes=a.emptyArray,e.prototype.droppedAttributesCount=null,e.prototype.entityRefs=a.emptyArray,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.attributes!=null&&e.attributes.length)for(var n=0;n<e.attributes.length;++n)o.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[n],t.uint32(10).fork()).ldelim();if(e.droppedAttributesCount!=null&&Object.hasOwnProperty.call(e,`droppedAttributesCount`)&&t.uint32(16).uint32(e.droppedAttributesCount),e.entityRefs!=null&&e.entityRefs.length)for(var n=0;n<e.entityRefs.length;++n)o.opentelemetry.proto.common.v1.EntityRef.encode(e.entityRefs[n],t.uint32(26).fork()).ldelim();return t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.resource.v1.Resource;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.attributes&&a.attributes.length||(a.attributes=[]),a.attributes.push(o.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break;case 2:a.droppedAttributesCount=e.uint32();break;case 3:a.entityRefs&&a.entityRefs.length||(a.entityRefs=[]),a.entityRefs.push(o.opentelemetry.proto.common.v1.EntityRef.decode(e,e.uint32()));break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.attributes!=null&&e.hasOwnProperty(`attributes`)){if(!Array.isArray(e.attributes))return`attributes: array expected`;for(var t=0;t<e.attributes.length;++t){var n=o.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[t]);if(n)return`attributes.`+n}}if(e.droppedAttributesCount!=null&&e.hasOwnProperty(`droppedAttributesCount`)&&!a.isInteger(e.droppedAttributesCount))return`droppedAttributesCount: integer expected`;if(e.entityRefs!=null&&e.hasOwnProperty(`entityRefs`)){if(!Array.isArray(e.entityRefs))return`entityRefs: array expected`;for(var t=0;t<e.entityRefs.length;++t){var n=o.opentelemetry.proto.common.v1.EntityRef.verify(e.entityRefs[t]);if(n)return`entityRefs.`+n}}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.resource.v1.Resource)return e;var t=new o.opentelemetry.proto.resource.v1.Resource;if(e.attributes){if(!Array.isArray(e.attributes))throw TypeError(`.opentelemetry.proto.resource.v1.Resource.attributes: array expected`);t.attributes=[];for(var n=0;n<e.attributes.length;++n){if(typeof e.attributes[n]!=`object`)throw TypeError(`.opentelemetry.proto.resource.v1.Resource.attributes: object expected`);t.attributes[n]=o.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[n])}}if(e.droppedAttributesCount!=null&&(t.droppedAttributesCount=e.droppedAttributesCount>>>0),e.entityRefs){if(!Array.isArray(e.entityRefs))throw TypeError(`.opentelemetry.proto.resource.v1.Resource.entityRefs: array expected`);t.entityRefs=[];for(var n=0;n<e.entityRefs.length;++n){if(typeof e.entityRefs[n]!=`object`)throw TypeError(`.opentelemetry.proto.resource.v1.Resource.entityRefs: object expected`);t.entityRefs[n]=o.opentelemetry.proto.common.v1.EntityRef.fromObject(e.entityRefs[n])}}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.attributes=[],n.entityRefs=[]),t.defaults&&(n.droppedAttributesCount=0),e.attributes&&e.attributes.length){n.attributes=[];for(var r=0;r<e.attributes.length;++r)n.attributes[r]=o.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[r],t)}if(e.droppedAttributesCount!=null&&e.hasOwnProperty(`droppedAttributesCount`)&&(n.droppedAttributesCount=e.droppedAttributesCount),e.entityRefs&&e.entityRefs.length){n.entityRefs=[];for(var r=0;r<e.entityRefs.length;++r)n.entityRefs[r]=o.opentelemetry.proto.common.v1.EntityRef.toObject(e.entityRefs[r],t)}return n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.resource.v1.Resource`},e})(),e})(),e})(),e.trace=(function(){var e={};return e.v1=(function(){var e={};return e.TracesData=(function(){function e(e){if(this.resourceSpans=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.resourceSpans=a.emptyArray,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.resourceSpans!=null&&e.resourceSpans.length)for(var n=0;n<e.resourceSpans.length;++n)o.opentelemetry.proto.trace.v1.ResourceSpans.encode(e.resourceSpans[n],t.uint32(10).fork()).ldelim();return t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.trace.v1.TracesData;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.resourceSpans&&a.resourceSpans.length||(a.resourceSpans=[]),a.resourceSpans.push(o.opentelemetry.proto.trace.v1.ResourceSpans.decode(e,e.uint32()));break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.resourceSpans!=null&&e.hasOwnProperty(`resourceSpans`)){if(!Array.isArray(e.resourceSpans))return`resourceSpans: array expected`;for(var t=0;t<e.resourceSpans.length;++t){var n=o.opentelemetry.proto.trace.v1.ResourceSpans.verify(e.resourceSpans[t]);if(n)return`resourceSpans.`+n}}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.trace.v1.TracesData)return e;var t=new o.opentelemetry.proto.trace.v1.TracesData;if(e.resourceSpans){if(!Array.isArray(e.resourceSpans))throw TypeError(`.opentelemetry.proto.trace.v1.TracesData.resourceSpans: array expected`);t.resourceSpans=[];for(var n=0;n<e.resourceSpans.length;++n){if(typeof e.resourceSpans[n]!=`object`)throw TypeError(`.opentelemetry.proto.trace.v1.TracesData.resourceSpans: object expected`);t.resourceSpans[n]=o.opentelemetry.proto.trace.v1.ResourceSpans.fromObject(e.resourceSpans[n])}}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.resourceSpans=[]),e.resourceSpans&&e.resourceSpans.length){n.resourceSpans=[];for(var r=0;r<e.resourceSpans.length;++r)n.resourceSpans[r]=o.opentelemetry.proto.trace.v1.ResourceSpans.toObject(e.resourceSpans[r],t)}return n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.trace.v1.TracesData`},e})(),e.ResourceSpans=(function(){function e(e){if(this.scopeSpans=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.resource=null,e.prototype.scopeSpans=a.emptyArray,e.prototype.schemaUrl=null,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.resource!=null&&Object.hasOwnProperty.call(e,`resource`)&&o.opentelemetry.proto.resource.v1.Resource.encode(e.resource,t.uint32(10).fork()).ldelim(),e.scopeSpans!=null&&e.scopeSpans.length)for(var n=0;n<e.scopeSpans.length;++n)o.opentelemetry.proto.trace.v1.ScopeSpans.encode(e.scopeSpans[n],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,`schemaUrl`)&&t.uint32(26).string(e.schemaUrl),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.trace.v1.ResourceSpans;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.resource=o.opentelemetry.proto.resource.v1.Resource.decode(e,e.uint32());break;case 2:a.scopeSpans&&a.scopeSpans.length||(a.scopeSpans=[]),a.scopeSpans.push(o.opentelemetry.proto.trace.v1.ScopeSpans.decode(e,e.uint32()));break;case 3:a.schemaUrl=e.string();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.resource!=null&&e.hasOwnProperty(`resource`)){var t=o.opentelemetry.proto.resource.v1.Resource.verify(e.resource);if(t)return`resource.`+t}if(e.scopeSpans!=null&&e.hasOwnProperty(`scopeSpans`)){if(!Array.isArray(e.scopeSpans))return`scopeSpans: array expected`;for(var n=0;n<e.scopeSpans.length;++n){var t=o.opentelemetry.proto.trace.v1.ScopeSpans.verify(e.scopeSpans[n]);if(t)return`scopeSpans.`+t}}return e.schemaUrl!=null&&e.hasOwnProperty(`schemaUrl`)&&!a.isString(e.schemaUrl)?`schemaUrl: string expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.trace.v1.ResourceSpans)return e;var t=new o.opentelemetry.proto.trace.v1.ResourceSpans;if(e.resource!=null){if(typeof e.resource!=`object`)throw TypeError(`.opentelemetry.proto.trace.v1.ResourceSpans.resource: object expected`);t.resource=o.opentelemetry.proto.resource.v1.Resource.fromObject(e.resource)}if(e.scopeSpans){if(!Array.isArray(e.scopeSpans))throw TypeError(`.opentelemetry.proto.trace.v1.ResourceSpans.scopeSpans: array expected`);t.scopeSpans=[];for(var n=0;n<e.scopeSpans.length;++n){if(typeof e.scopeSpans[n]!=`object`)throw TypeError(`.opentelemetry.proto.trace.v1.ResourceSpans.scopeSpans: object expected`);t.scopeSpans[n]=o.opentelemetry.proto.trace.v1.ScopeSpans.fromObject(e.scopeSpans[n])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.scopeSpans=[]),t.defaults&&(n.resource=null,n.schemaUrl=``),e.resource!=null&&e.hasOwnProperty(`resource`)&&(n.resource=o.opentelemetry.proto.resource.v1.Resource.toObject(e.resource,t)),e.scopeSpans&&e.scopeSpans.length){n.scopeSpans=[];for(var r=0;r<e.scopeSpans.length;++r)n.scopeSpans[r]=o.opentelemetry.proto.trace.v1.ScopeSpans.toObject(e.scopeSpans[r],t)}return e.schemaUrl!=null&&e.hasOwnProperty(`schemaUrl`)&&(n.schemaUrl=e.schemaUrl),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.trace.v1.ResourceSpans`},e})(),e.ScopeSpans=(function(){function e(e){if(this.spans=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.scope=null,e.prototype.spans=a.emptyArray,e.prototype.schemaUrl=null,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.scope!=null&&Object.hasOwnProperty.call(e,`scope`)&&o.opentelemetry.proto.common.v1.InstrumentationScope.encode(e.scope,t.uint32(10).fork()).ldelim(),e.spans!=null&&e.spans.length)for(var n=0;n<e.spans.length;++n)o.opentelemetry.proto.trace.v1.Span.encode(e.spans[n],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,`schemaUrl`)&&t.uint32(26).string(e.schemaUrl),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.trace.v1.ScopeSpans;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.scope=o.opentelemetry.proto.common.v1.InstrumentationScope.decode(e,e.uint32());break;case 2:a.spans&&a.spans.length||(a.spans=[]),a.spans.push(o.opentelemetry.proto.trace.v1.Span.decode(e,e.uint32()));break;case 3:a.schemaUrl=e.string();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.scope!=null&&e.hasOwnProperty(`scope`)){var t=o.opentelemetry.proto.common.v1.InstrumentationScope.verify(e.scope);if(t)return`scope.`+t}if(e.spans!=null&&e.hasOwnProperty(`spans`)){if(!Array.isArray(e.spans))return`spans: array expected`;for(var n=0;n<e.spans.length;++n){var t=o.opentelemetry.proto.trace.v1.Span.verify(e.spans[n]);if(t)return`spans.`+t}}return e.schemaUrl!=null&&e.hasOwnProperty(`schemaUrl`)&&!a.isString(e.schemaUrl)?`schemaUrl: string expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.trace.v1.ScopeSpans)return e;var t=new o.opentelemetry.proto.trace.v1.ScopeSpans;if(e.scope!=null){if(typeof e.scope!=`object`)throw TypeError(`.opentelemetry.proto.trace.v1.ScopeSpans.scope: object expected`);t.scope=o.opentelemetry.proto.common.v1.InstrumentationScope.fromObject(e.scope)}if(e.spans){if(!Array.isArray(e.spans))throw TypeError(`.opentelemetry.proto.trace.v1.ScopeSpans.spans: array expected`);t.spans=[];for(var n=0;n<e.spans.length;++n){if(typeof e.spans[n]!=`object`)throw TypeError(`.opentelemetry.proto.trace.v1.ScopeSpans.spans: object expected`);t.spans[n]=o.opentelemetry.proto.trace.v1.Span.fromObject(e.spans[n])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.spans=[]),t.defaults&&(n.scope=null,n.schemaUrl=``),e.scope!=null&&e.hasOwnProperty(`scope`)&&(n.scope=o.opentelemetry.proto.common.v1.InstrumentationScope.toObject(e.scope,t)),e.spans&&e.spans.length){n.spans=[];for(var r=0;r<e.spans.length;++r)n.spans[r]=o.opentelemetry.proto.trace.v1.Span.toObject(e.spans[r],t)}return e.schemaUrl!=null&&e.hasOwnProperty(`schemaUrl`)&&(n.schemaUrl=e.schemaUrl),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.trace.v1.ScopeSpans`},e})(),e.Span=(function(){function e(e){if(this.attributes=[],this.events=[],this.links=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.traceId=null,e.prototype.spanId=null,e.prototype.traceState=null,e.prototype.parentSpanId=null,e.prototype.flags=null,e.prototype.name=null,e.prototype.kind=null,e.prototype.startTimeUnixNano=null,e.prototype.endTimeUnixNano=null,e.prototype.attributes=a.emptyArray,e.prototype.droppedAttributesCount=null,e.prototype.events=a.emptyArray,e.prototype.droppedEventsCount=null,e.prototype.links=a.emptyArray,e.prototype.droppedLinksCount=null,e.prototype.status=null,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.traceId!=null&&Object.hasOwnProperty.call(e,`traceId`)&&t.uint32(10).bytes(e.traceId),e.spanId!=null&&Object.hasOwnProperty.call(e,`spanId`)&&t.uint32(18).bytes(e.spanId),e.traceState!=null&&Object.hasOwnProperty.call(e,`traceState`)&&t.uint32(26).string(e.traceState),e.parentSpanId!=null&&Object.hasOwnProperty.call(e,`parentSpanId`)&&t.uint32(34).bytes(e.parentSpanId),e.name!=null&&Object.hasOwnProperty.call(e,`name`)&&t.uint32(42).string(e.name),e.kind!=null&&Object.hasOwnProperty.call(e,`kind`)&&t.uint32(48).int32(e.kind),e.startTimeUnixNano!=null&&Object.hasOwnProperty.call(e,`startTimeUnixNano`)&&t.uint32(57).fixed64(e.startTimeUnixNano),e.endTimeUnixNano!=null&&Object.hasOwnProperty.call(e,`endTimeUnixNano`)&&t.uint32(65).fixed64(e.endTimeUnixNano),e.attributes!=null&&e.attributes.length)for(var n=0;n<e.attributes.length;++n)o.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[n],t.uint32(74).fork()).ldelim();if(e.droppedAttributesCount!=null&&Object.hasOwnProperty.call(e,`droppedAttributesCount`)&&t.uint32(80).uint32(e.droppedAttributesCount),e.events!=null&&e.events.length)for(var n=0;n<e.events.length;++n)o.opentelemetry.proto.trace.v1.Span.Event.encode(e.events[n],t.uint32(90).fork()).ldelim();if(e.droppedEventsCount!=null&&Object.hasOwnProperty.call(e,`droppedEventsCount`)&&t.uint32(96).uint32(e.droppedEventsCount),e.links!=null&&e.links.length)for(var n=0;n<e.links.length;++n)o.opentelemetry.proto.trace.v1.Span.Link.encode(e.links[n],t.uint32(106).fork()).ldelim();return e.droppedLinksCount!=null&&Object.hasOwnProperty.call(e,`droppedLinksCount`)&&t.uint32(112).uint32(e.droppedLinksCount),e.status!=null&&Object.hasOwnProperty.call(e,`status`)&&o.opentelemetry.proto.trace.v1.Status.encode(e.status,t.uint32(122).fork()).ldelim(),e.flags!=null&&Object.hasOwnProperty.call(e,`flags`)&&t.uint32(133).fixed32(e.flags),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.trace.v1.Span;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.traceId=e.bytes();break;case 2:a.spanId=e.bytes();break;case 3:a.traceState=e.string();break;case 4:a.parentSpanId=e.bytes();break;case 16:a.flags=e.fixed32();break;case 5:a.name=e.string();break;case 6:a.kind=e.int32();break;case 7:a.startTimeUnixNano=e.fixed64();break;case 8:a.endTimeUnixNano=e.fixed64();break;case 9:a.attributes&&a.attributes.length||(a.attributes=[]),a.attributes.push(o.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break;case 10:a.droppedAttributesCount=e.uint32();break;case 11:a.events&&a.events.length||(a.events=[]),a.events.push(o.opentelemetry.proto.trace.v1.Span.Event.decode(e,e.uint32()));break;case 12:a.droppedEventsCount=e.uint32();break;case 13:a.links&&a.links.length||(a.links=[]),a.links.push(o.opentelemetry.proto.trace.v1.Span.Link.decode(e,e.uint32()));break;case 14:a.droppedLinksCount=e.uint32();break;case 15:a.status=o.opentelemetry.proto.trace.v1.Status.decode(e,e.uint32());break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.traceId!=null&&e.hasOwnProperty(`traceId`)&&!(e.traceId&&typeof e.traceId.length==`number`||a.isString(e.traceId)))return`traceId: buffer expected`;if(e.spanId!=null&&e.hasOwnProperty(`spanId`)&&!(e.spanId&&typeof e.spanId.length==`number`||a.isString(e.spanId)))return`spanId: buffer expected`;if(e.traceState!=null&&e.hasOwnProperty(`traceState`)&&!a.isString(e.traceState))return`traceState: string expected`;if(e.parentSpanId!=null&&e.hasOwnProperty(`parentSpanId`)&&!(e.parentSpanId&&typeof e.parentSpanId.length==`number`||a.isString(e.parentSpanId)))return`parentSpanId: buffer expected`;if(e.flags!=null&&e.hasOwnProperty(`flags`)&&!a.isInteger(e.flags))return`flags: integer expected`;if(e.name!=null&&e.hasOwnProperty(`name`)&&!a.isString(e.name))return`name: string expected`;if(e.kind!=null&&e.hasOwnProperty(`kind`))switch(e.kind){default:return`kind: enum value expected`;case 0:case 1:case 2:case 3:case 4:case 5:}if(e.startTimeUnixNano!=null&&e.hasOwnProperty(`startTimeUnixNano`)&&!a.isInteger(e.startTimeUnixNano)&&!(e.startTimeUnixNano&&a.isInteger(e.startTimeUnixNano.low)&&a.isInteger(e.startTimeUnixNano.high)))return`startTimeUnixNano: integer|Long expected`;if(e.endTimeUnixNano!=null&&e.hasOwnProperty(`endTimeUnixNano`)&&!a.isInteger(e.endTimeUnixNano)&&!(e.endTimeUnixNano&&a.isInteger(e.endTimeUnixNano.low)&&a.isInteger(e.endTimeUnixNano.high)))return`endTimeUnixNano: integer|Long expected`;if(e.attributes!=null&&e.hasOwnProperty(`attributes`)){if(!Array.isArray(e.attributes))return`attributes: array expected`;for(var t=0;t<e.attributes.length;++t){var n=o.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[t]);if(n)return`attributes.`+n}}if(e.droppedAttributesCount!=null&&e.hasOwnProperty(`droppedAttributesCount`)&&!a.isInteger(e.droppedAttributesCount))return`droppedAttributesCount: integer expected`;if(e.events!=null&&e.hasOwnProperty(`events`)){if(!Array.isArray(e.events))return`events: array expected`;for(var t=0;t<e.events.length;++t){var n=o.opentelemetry.proto.trace.v1.Span.Event.verify(e.events[t]);if(n)return`events.`+n}}if(e.droppedEventsCount!=null&&e.hasOwnProperty(`droppedEventsCount`)&&!a.isInteger(e.droppedEventsCount))return`droppedEventsCount: integer expected`;if(e.links!=null&&e.hasOwnProperty(`links`)){if(!Array.isArray(e.links))return`links: array expected`;for(var t=0;t<e.links.length;++t){var n=o.opentelemetry.proto.trace.v1.Span.Link.verify(e.links[t]);if(n)return`links.`+n}}if(e.droppedLinksCount!=null&&e.hasOwnProperty(`droppedLinksCount`)&&!a.isInteger(e.droppedLinksCount))return`droppedLinksCount: integer expected`;if(e.status!=null&&e.hasOwnProperty(`status`)){var n=o.opentelemetry.proto.trace.v1.Status.verify(e.status);if(n)return`status.`+n}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.trace.v1.Span)return e;var t=new o.opentelemetry.proto.trace.v1.Span;switch(e.traceId!=null&&(typeof e.traceId==`string`?a.base64.decode(e.traceId,t.traceId=a.newBuffer(a.base64.length(e.traceId)),0):e.traceId.length>=0&&(t.traceId=e.traceId)),e.spanId!=null&&(typeof e.spanId==`string`?a.base64.decode(e.spanId,t.spanId=a.newBuffer(a.base64.length(e.spanId)),0):e.spanId.length>=0&&(t.spanId=e.spanId)),e.traceState!=null&&(t.traceState=String(e.traceState)),e.parentSpanId!=null&&(typeof e.parentSpanId==`string`?a.base64.decode(e.parentSpanId,t.parentSpanId=a.newBuffer(a.base64.length(e.parentSpanId)),0):e.parentSpanId.length>=0&&(t.parentSpanId=e.parentSpanId)),e.flags!=null&&(t.flags=e.flags>>>0),e.name!=null&&(t.name=String(e.name)),e.kind){default:if(typeof e.kind==`number`){t.kind=e.kind;break}break;case`SPAN_KIND_UNSPECIFIED`:case 0:t.kind=0;break;case`SPAN_KIND_INTERNAL`:case 1:t.kind=1;break;case`SPAN_KIND_SERVER`:case 2:t.kind=2;break;case`SPAN_KIND_CLIENT`:case 3:t.kind=3;break;case`SPAN_KIND_PRODUCER`:case 4:t.kind=4;break;case`SPAN_KIND_CONSUMER`:case 5:t.kind=5}if(e.startTimeUnixNano!=null&&(a.Long?(t.startTimeUnixNano=a.Long.fromValue(e.startTimeUnixNano)).unsigned=!1:typeof e.startTimeUnixNano==`string`?t.startTimeUnixNano=parseInt(e.startTimeUnixNano,10):typeof e.startTimeUnixNano==`number`?t.startTimeUnixNano=e.startTimeUnixNano:typeof e.startTimeUnixNano==`object`&&(t.startTimeUnixNano=new a.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber())),e.endTimeUnixNano!=null&&(a.Long?(t.endTimeUnixNano=a.Long.fromValue(e.endTimeUnixNano)).unsigned=!1:typeof e.endTimeUnixNano==`string`?t.endTimeUnixNano=parseInt(e.endTimeUnixNano,10):typeof e.endTimeUnixNano==`number`?t.endTimeUnixNano=e.endTimeUnixNano:typeof e.endTimeUnixNano==`object`&&(t.endTimeUnixNano=new a.LongBits(e.endTimeUnixNano.low>>>0,e.endTimeUnixNano.high>>>0).toNumber())),e.attributes){if(!Array.isArray(e.attributes))throw TypeError(`.opentelemetry.proto.trace.v1.Span.attributes: array expected`);t.attributes=[];for(var n=0;n<e.attributes.length;++n){if(typeof e.attributes[n]!=`object`)throw TypeError(`.opentelemetry.proto.trace.v1.Span.attributes: object expected`);t.attributes[n]=o.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[n])}}if(e.droppedAttributesCount!=null&&(t.droppedAttributesCount=e.droppedAttributesCount>>>0),e.events){if(!Array.isArray(e.events))throw TypeError(`.opentelemetry.proto.trace.v1.Span.events: array expected`);t.events=[];for(var n=0;n<e.events.length;++n){if(typeof e.events[n]!=`object`)throw TypeError(`.opentelemetry.proto.trace.v1.Span.events: object expected`);t.events[n]=o.opentelemetry.proto.trace.v1.Span.Event.fromObject(e.events[n])}}if(e.droppedEventsCount!=null&&(t.droppedEventsCount=e.droppedEventsCount>>>0),e.links){if(!Array.isArray(e.links))throw TypeError(`.opentelemetry.proto.trace.v1.Span.links: array expected`);t.links=[];for(var n=0;n<e.links.length;++n){if(typeof e.links[n]!=`object`)throw TypeError(`.opentelemetry.proto.trace.v1.Span.links: object expected`);t.links[n]=o.opentelemetry.proto.trace.v1.Span.Link.fromObject(e.links[n])}}if(e.droppedLinksCount!=null&&(t.droppedLinksCount=e.droppedLinksCount>>>0),e.status!=null){if(typeof e.status!=`object`)throw TypeError(`.opentelemetry.proto.trace.v1.Span.status: object expected`);t.status=o.opentelemetry.proto.trace.v1.Status.fromObject(e.status)}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.attributes=[],n.events=[],n.links=[]),t.defaults){if(t.bytes===String?n.traceId=``:(n.traceId=[],t.bytes!==Array&&(n.traceId=a.newBuffer(n.traceId))),t.bytes===String?n.spanId=``:(n.spanId=[],t.bytes!==Array&&(n.spanId=a.newBuffer(n.spanId))),n.traceState=``,t.bytes===String?n.parentSpanId=``:(n.parentSpanId=[],t.bytes!==Array&&(n.parentSpanId=a.newBuffer(n.parentSpanId))),n.name=``,n.kind=t.enums===String?`SPAN_KIND_UNSPECIFIED`:0,a.Long){var r=new a.Long(0,0,!1);n.startTimeUnixNano=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.startTimeUnixNano=t.longs===String?`0`:0;if(a.Long){var r=new a.Long(0,0,!1);n.endTimeUnixNano=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.endTimeUnixNano=t.longs===String?`0`:0;n.droppedAttributesCount=0,n.droppedEventsCount=0,n.droppedLinksCount=0,n.status=null,n.flags=0}if(e.traceId!=null&&e.hasOwnProperty(`traceId`)&&(n.traceId=t.bytes===String?a.base64.encode(e.traceId,0,e.traceId.length):t.bytes===Array?Array.prototype.slice.call(e.traceId):e.traceId),e.spanId!=null&&e.hasOwnProperty(`spanId`)&&(n.spanId=t.bytes===String?a.base64.encode(e.spanId,0,e.spanId.length):t.bytes===Array?Array.prototype.slice.call(e.spanId):e.spanId),e.traceState!=null&&e.hasOwnProperty(`traceState`)&&(n.traceState=e.traceState),e.parentSpanId!=null&&e.hasOwnProperty(`parentSpanId`)&&(n.parentSpanId=t.bytes===String?a.base64.encode(e.parentSpanId,0,e.parentSpanId.length):t.bytes===Array?Array.prototype.slice.call(e.parentSpanId):e.parentSpanId),e.name!=null&&e.hasOwnProperty(`name`)&&(n.name=e.name),e.kind!=null&&e.hasOwnProperty(`kind`)&&(n.kind=t.enums===String?o.opentelemetry.proto.trace.v1.Span.SpanKind[e.kind]===void 0?e.kind:o.opentelemetry.proto.trace.v1.Span.SpanKind[e.kind]:e.kind),e.startTimeUnixNano!=null&&e.hasOwnProperty(`startTimeUnixNano`)&&(n.startTimeUnixNano=typeof e.startTimeUnixNano==`number`?t.longs===String?String(e.startTimeUnixNano):e.startTimeUnixNano:t.longs===String?a.Long.prototype.toString.call(e.startTimeUnixNano):t.longs===Number?new a.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber():e.startTimeUnixNano),e.endTimeUnixNano!=null&&e.hasOwnProperty(`endTimeUnixNano`)&&(n.endTimeUnixNano=typeof e.endTimeUnixNano==`number`?t.longs===String?String(e.endTimeUnixNano):e.endTimeUnixNano:t.longs===String?a.Long.prototype.toString.call(e.endTimeUnixNano):t.longs===Number?new a.LongBits(e.endTimeUnixNano.low>>>0,e.endTimeUnixNano.high>>>0).toNumber():e.endTimeUnixNano),e.attributes&&e.attributes.length){n.attributes=[];for(var i=0;i<e.attributes.length;++i)n.attributes[i]=o.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[i],t)}if(e.droppedAttributesCount!=null&&e.hasOwnProperty(`droppedAttributesCount`)&&(n.droppedAttributesCount=e.droppedAttributesCount),e.events&&e.events.length){n.events=[];for(var i=0;i<e.events.length;++i)n.events[i]=o.opentelemetry.proto.trace.v1.Span.Event.toObject(e.events[i],t)}if(e.droppedEventsCount!=null&&e.hasOwnProperty(`droppedEventsCount`)&&(n.droppedEventsCount=e.droppedEventsCount),e.links&&e.links.length){n.links=[];for(var i=0;i<e.links.length;++i)n.links[i]=o.opentelemetry.proto.trace.v1.Span.Link.toObject(e.links[i],t)}return e.droppedLinksCount!=null&&e.hasOwnProperty(`droppedLinksCount`)&&(n.droppedLinksCount=e.droppedLinksCount),e.status!=null&&e.hasOwnProperty(`status`)&&(n.status=o.opentelemetry.proto.trace.v1.Status.toObject(e.status,t)),e.flags!=null&&e.hasOwnProperty(`flags`)&&(n.flags=e.flags),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.trace.v1.Span`},e.SpanKind=(function(){var e={},t=Object.create(e);return t[e[0]=`SPAN_KIND_UNSPECIFIED`]=0,t[e[1]=`SPAN_KIND_INTERNAL`]=1,t[e[2]=`SPAN_KIND_SERVER`]=2,t[e[3]=`SPAN_KIND_CLIENT`]=3,t[e[4]=`SPAN_KIND_PRODUCER`]=4,t[e[5]=`SPAN_KIND_CONSUMER`]=5,t})(),e.Event=(function(){function e(e){if(this.attributes=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.timeUnixNano=null,e.prototype.name=null,e.prototype.attributes=a.emptyArray,e.prototype.droppedAttributesCount=null,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.timeUnixNano!=null&&Object.hasOwnProperty.call(e,`timeUnixNano`)&&t.uint32(9).fixed64(e.timeUnixNano),e.name!=null&&Object.hasOwnProperty.call(e,`name`)&&t.uint32(18).string(e.name),e.attributes!=null&&e.attributes.length)for(var n=0;n<e.attributes.length;++n)o.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[n],t.uint32(26).fork()).ldelim();return e.droppedAttributesCount!=null&&Object.hasOwnProperty.call(e,`droppedAttributesCount`)&&t.uint32(32).uint32(e.droppedAttributesCount),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.trace.v1.Span.Event;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.timeUnixNano=e.fixed64();break;case 2:a.name=e.string();break;case 3:a.attributes&&a.attributes.length||(a.attributes=[]),a.attributes.push(o.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break;case 4:a.droppedAttributesCount=e.uint32();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.timeUnixNano!=null&&e.hasOwnProperty(`timeUnixNano`)&&!a.isInteger(e.timeUnixNano)&&!(e.timeUnixNano&&a.isInteger(e.timeUnixNano.low)&&a.isInteger(e.timeUnixNano.high)))return`timeUnixNano: integer|Long expected`;if(e.name!=null&&e.hasOwnProperty(`name`)&&!a.isString(e.name))return`name: string expected`;if(e.attributes!=null&&e.hasOwnProperty(`attributes`)){if(!Array.isArray(e.attributes))return`attributes: array expected`;for(var t=0;t<e.attributes.length;++t){var n=o.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[t]);if(n)return`attributes.`+n}}return e.droppedAttributesCount!=null&&e.hasOwnProperty(`droppedAttributesCount`)&&!a.isInteger(e.droppedAttributesCount)?`droppedAttributesCount: integer expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.trace.v1.Span.Event)return e;var t=new o.opentelemetry.proto.trace.v1.Span.Event;if(e.timeUnixNano!=null&&(a.Long?(t.timeUnixNano=a.Long.fromValue(e.timeUnixNano)).unsigned=!1:typeof e.timeUnixNano==`string`?t.timeUnixNano=parseInt(e.timeUnixNano,10):typeof e.timeUnixNano==`number`?t.timeUnixNano=e.timeUnixNano:typeof e.timeUnixNano==`object`&&(t.timeUnixNano=new a.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber())),e.name!=null&&(t.name=String(e.name)),e.attributes){if(!Array.isArray(e.attributes))throw TypeError(`.opentelemetry.proto.trace.v1.Span.Event.attributes: array expected`);t.attributes=[];for(var n=0;n<e.attributes.length;++n){if(typeof e.attributes[n]!=`object`)throw TypeError(`.opentelemetry.proto.trace.v1.Span.Event.attributes: object expected`);t.attributes[n]=o.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[n])}}return e.droppedAttributesCount!=null&&(t.droppedAttributesCount=e.droppedAttributesCount>>>0),t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.attributes=[]),t.defaults){if(a.Long){var r=new a.Long(0,0,!1);n.timeUnixNano=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.timeUnixNano=t.longs===String?`0`:0;n.name=``,n.droppedAttributesCount=0}if(e.timeUnixNano!=null&&e.hasOwnProperty(`timeUnixNano`)&&(n.timeUnixNano=typeof e.timeUnixNano==`number`?t.longs===String?String(e.timeUnixNano):e.timeUnixNano:t.longs===String?a.Long.prototype.toString.call(e.timeUnixNano):t.longs===Number?new a.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber():e.timeUnixNano),e.name!=null&&e.hasOwnProperty(`name`)&&(n.name=e.name),e.attributes&&e.attributes.length){n.attributes=[];for(var i=0;i<e.attributes.length;++i)n.attributes[i]=o.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[i],t)}return e.droppedAttributesCount!=null&&e.hasOwnProperty(`droppedAttributesCount`)&&(n.droppedAttributesCount=e.droppedAttributesCount),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.trace.v1.Span.Event`},e})(),e.Link=(function(){function e(e){if(this.attributes=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.traceId=null,e.prototype.spanId=null,e.prototype.traceState=null,e.prototype.attributes=a.emptyArray,e.prototype.droppedAttributesCount=null,e.prototype.flags=null,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.traceId!=null&&Object.hasOwnProperty.call(e,`traceId`)&&t.uint32(10).bytes(e.traceId),e.spanId!=null&&Object.hasOwnProperty.call(e,`spanId`)&&t.uint32(18).bytes(e.spanId),e.traceState!=null&&Object.hasOwnProperty.call(e,`traceState`)&&t.uint32(26).string(e.traceState),e.attributes!=null&&e.attributes.length)for(var n=0;n<e.attributes.length;++n)o.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[n],t.uint32(34).fork()).ldelim();return e.droppedAttributesCount!=null&&Object.hasOwnProperty.call(e,`droppedAttributesCount`)&&t.uint32(40).uint32(e.droppedAttributesCount),e.flags!=null&&Object.hasOwnProperty.call(e,`flags`)&&t.uint32(53).fixed32(e.flags),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.trace.v1.Span.Link;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.traceId=e.bytes();break;case 2:a.spanId=e.bytes();break;case 3:a.traceState=e.string();break;case 4:a.attributes&&a.attributes.length||(a.attributes=[]),a.attributes.push(o.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break;case 5:a.droppedAttributesCount=e.uint32();break;case 6:a.flags=e.fixed32();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.traceId!=null&&e.hasOwnProperty(`traceId`)&&!(e.traceId&&typeof e.traceId.length==`number`||a.isString(e.traceId)))return`traceId: buffer expected`;if(e.spanId!=null&&e.hasOwnProperty(`spanId`)&&!(e.spanId&&typeof e.spanId.length==`number`||a.isString(e.spanId)))return`spanId: buffer expected`;if(e.traceState!=null&&e.hasOwnProperty(`traceState`)&&!a.isString(e.traceState))return`traceState: string expected`;if(e.attributes!=null&&e.hasOwnProperty(`attributes`)){if(!Array.isArray(e.attributes))return`attributes: array expected`;for(var t=0;t<e.attributes.length;++t){var n=o.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[t]);if(n)return`attributes.`+n}}return e.droppedAttributesCount!=null&&e.hasOwnProperty(`droppedAttributesCount`)&&!a.isInteger(e.droppedAttributesCount)?`droppedAttributesCount: integer expected`:e.flags!=null&&e.hasOwnProperty(`flags`)&&!a.isInteger(e.flags)?`flags: integer expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.trace.v1.Span.Link)return e;var t=new o.opentelemetry.proto.trace.v1.Span.Link;if(e.traceId!=null&&(typeof e.traceId==`string`?a.base64.decode(e.traceId,t.traceId=a.newBuffer(a.base64.length(e.traceId)),0):e.traceId.length>=0&&(t.traceId=e.traceId)),e.spanId!=null&&(typeof e.spanId==`string`?a.base64.decode(e.spanId,t.spanId=a.newBuffer(a.base64.length(e.spanId)),0):e.spanId.length>=0&&(t.spanId=e.spanId)),e.traceState!=null&&(t.traceState=String(e.traceState)),e.attributes){if(!Array.isArray(e.attributes))throw TypeError(`.opentelemetry.proto.trace.v1.Span.Link.attributes: array expected`);t.attributes=[];for(var n=0;n<e.attributes.length;++n){if(typeof e.attributes[n]!=`object`)throw TypeError(`.opentelemetry.proto.trace.v1.Span.Link.attributes: object expected`);t.attributes[n]=o.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[n])}}return e.droppedAttributesCount!=null&&(t.droppedAttributesCount=e.droppedAttributesCount>>>0),e.flags!=null&&(t.flags=e.flags>>>0),t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.attributes=[]),t.defaults&&(t.bytes===String?n.traceId=``:(n.traceId=[],t.bytes!==Array&&(n.traceId=a.newBuffer(n.traceId))),t.bytes===String?n.spanId=``:(n.spanId=[],t.bytes!==Array&&(n.spanId=a.newBuffer(n.spanId))),n.traceState=``,n.droppedAttributesCount=0,n.flags=0),e.traceId!=null&&e.hasOwnProperty(`traceId`)&&(n.traceId=t.bytes===String?a.base64.encode(e.traceId,0,e.traceId.length):t.bytes===Array?Array.prototype.slice.call(e.traceId):e.traceId),e.spanId!=null&&e.hasOwnProperty(`spanId`)&&(n.spanId=t.bytes===String?a.base64.encode(e.spanId,0,e.spanId.length):t.bytes===Array?Array.prototype.slice.call(e.spanId):e.spanId),e.traceState!=null&&e.hasOwnProperty(`traceState`)&&(n.traceState=e.traceState),e.attributes&&e.attributes.length){n.attributes=[];for(var r=0;r<e.attributes.length;++r)n.attributes[r]=o.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[r],t)}return e.droppedAttributesCount!=null&&e.hasOwnProperty(`droppedAttributesCount`)&&(n.droppedAttributesCount=e.droppedAttributesCount),e.flags!=null&&e.hasOwnProperty(`flags`)&&(n.flags=e.flags),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.trace.v1.Span.Link`},e})(),e})(),e.Status=(function(){function e(e){if(e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.message=null,e.prototype.code=null,e.create=function(t){return new e(t)},e.encode=function(e,t){return t||=i.create(),e.message!=null&&Object.hasOwnProperty.call(e,`message`)&&t.uint32(18).string(e.message),e.code!=null&&Object.hasOwnProperty.call(e,`code`)&&t.uint32(24).int32(e.code),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.trace.v1.Status;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 2:a.message=e.string();break;case 3:a.code=e.int32();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.message!=null&&e.hasOwnProperty(`message`)&&!a.isString(e.message))return`message: string expected`;if(e.code!=null&&e.hasOwnProperty(`code`))switch(e.code){default:return`code: enum value expected`;case 0:case 1:case 2:}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.trace.v1.Status)return e;var t=new o.opentelemetry.proto.trace.v1.Status;switch(e.message!=null&&(t.message=String(e.message)),e.code){default:if(typeof e.code==`number`){t.code=e.code;break}break;case`STATUS_CODE_UNSET`:case 0:t.code=0;break;case`STATUS_CODE_OK`:case 1:t.code=1;break;case`STATUS_CODE_ERROR`:case 2:t.code=2}return t},e.toObject=function(e,t){t||={};var n={};return t.defaults&&(n.message=``,n.code=t.enums===String?`STATUS_CODE_UNSET`:0),e.message!=null&&e.hasOwnProperty(`message`)&&(n.message=e.message),e.code!=null&&e.hasOwnProperty(`code`)&&(n.code=t.enums===String?o.opentelemetry.proto.trace.v1.Status.StatusCode[e.code]===void 0?e.code:o.opentelemetry.proto.trace.v1.Status.StatusCode[e.code]:e.code),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.trace.v1.Status`},e.StatusCode=(function(){var e={},t=Object.create(e);return t[e[0]=`STATUS_CODE_UNSET`]=0,t[e[1]=`STATUS_CODE_OK`]=1,t[e[2]=`STATUS_CODE_ERROR`]=2,t})(),e})(),e.SpanFlags=(function(){var e={},t=Object.create(e);return t[e[0]=`SPAN_FLAGS_DO_NOT_USE`]=0,t[e[255]=`SPAN_FLAGS_TRACE_FLAGS_MASK`]=255,t[e[256]=`SPAN_FLAGS_CONTEXT_HAS_IS_REMOTE_MASK`]=256,t[e[512]=`SPAN_FLAGS_CONTEXT_IS_REMOTE_MASK`]=512,t})(),e})(),e})(),e.collector=(function(){var e={};return e.trace=(function(){var e={};return e.v1=(function(){var e={};return e.TraceService=(function(){function e(e,t,r){n.rpc.Service.call(this,e,t,r)}return(e.prototype=Object.create(n.rpc.Service.prototype)).constructor=e,e.create=function(e,t,n){return new this(e,t,n)},Object.defineProperty(e.prototype.export=function e(t,n){return this.rpcCall(e,o.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest,o.opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse,t,n)},"name",{value:`Export`}),e})(),e.ExportTraceServiceRequest=(function(){function e(e){if(this.resourceSpans=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.resourceSpans=a.emptyArray,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.resourceSpans!=null&&e.resourceSpans.length)for(var n=0;n<e.resourceSpans.length;++n)o.opentelemetry.proto.trace.v1.ResourceSpans.encode(e.resourceSpans[n],t.uint32(10).fork()).ldelim();return t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.resourceSpans&&a.resourceSpans.length||(a.resourceSpans=[]),a.resourceSpans.push(o.opentelemetry.proto.trace.v1.ResourceSpans.decode(e,e.uint32()));break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.resourceSpans!=null&&e.hasOwnProperty(`resourceSpans`)){if(!Array.isArray(e.resourceSpans))return`resourceSpans: array expected`;for(var t=0;t<e.resourceSpans.length;++t){var n=o.opentelemetry.proto.trace.v1.ResourceSpans.verify(e.resourceSpans[t]);if(n)return`resourceSpans.`+n}}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest)return e;var t=new o.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest;if(e.resourceSpans){if(!Array.isArray(e.resourceSpans))throw TypeError(`.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest.resourceSpans: array expected`);t.resourceSpans=[];for(var n=0;n<e.resourceSpans.length;++n){if(typeof e.resourceSpans[n]!=`object`)throw TypeError(`.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest.resourceSpans: object expected`);t.resourceSpans[n]=o.opentelemetry.proto.trace.v1.ResourceSpans.fromObject(e.resourceSpans[n])}}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.resourceSpans=[]),e.resourceSpans&&e.resourceSpans.length){n.resourceSpans=[];for(var r=0;r<e.resourceSpans.length;++r)n.resourceSpans[r]=o.opentelemetry.proto.trace.v1.ResourceSpans.toObject(e.resourceSpans[r],t)}return n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest`},e})(),e.ExportTraceServiceResponse=(function(){function e(e){if(e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.partialSuccess=null,e.create=function(t){return new e(t)},e.encode=function(e,t){return t||=i.create(),e.partialSuccess!=null&&Object.hasOwnProperty.call(e,`partialSuccess`)&&o.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess.encode(e.partialSuccess,t.uint32(10).fork()).ldelim(),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.partialSuccess=o.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess.decode(e,e.uint32());break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.partialSuccess!=null&&e.hasOwnProperty(`partialSuccess`)){var t=o.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess.verify(e.partialSuccess);if(t)return`partialSuccess.`+t}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse)return e;var t=new o.opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse;if(e.partialSuccess!=null){if(typeof e.partialSuccess!=`object`)throw TypeError(`.opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse.partialSuccess: object expected`);t.partialSuccess=o.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess.fromObject(e.partialSuccess)}return t},e.toObject=function(e,t){t||={};var n={};return t.defaults&&(n.partialSuccess=null),e.partialSuccess!=null&&e.hasOwnProperty(`partialSuccess`)&&(n.partialSuccess=o.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess.toObject(e.partialSuccess,t)),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse`},e})(),e.ExportTracePartialSuccess=(function(){function e(e){if(e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.rejectedSpans=null,e.prototype.errorMessage=null,e.create=function(t){return new e(t)},e.encode=function(e,t){return t||=i.create(),e.rejectedSpans!=null&&Object.hasOwnProperty.call(e,`rejectedSpans`)&&t.uint32(8).int64(e.rejectedSpans),e.errorMessage!=null&&Object.hasOwnProperty.call(e,`errorMessage`)&&t.uint32(18).string(e.errorMessage),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.rejectedSpans=e.int64();break;case 2:a.errorMessage=e.string();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){return typeof e!=`object`||!e?`object expected`:e.rejectedSpans!=null&&e.hasOwnProperty(`rejectedSpans`)&&!a.isInteger(e.rejectedSpans)&&!(e.rejectedSpans&&a.isInteger(e.rejectedSpans.low)&&a.isInteger(e.rejectedSpans.high))?`rejectedSpans: integer|Long expected`:e.errorMessage!=null&&e.hasOwnProperty(`errorMessage`)&&!a.isString(e.errorMessage)?`errorMessage: string expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess)return e;var t=new o.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess;return e.rejectedSpans!=null&&(a.Long?(t.rejectedSpans=a.Long.fromValue(e.rejectedSpans)).unsigned=!1:typeof e.rejectedSpans==`string`?t.rejectedSpans=parseInt(e.rejectedSpans,10):typeof e.rejectedSpans==`number`?t.rejectedSpans=e.rejectedSpans:typeof e.rejectedSpans==`object`&&(t.rejectedSpans=new a.LongBits(e.rejectedSpans.low>>>0,e.rejectedSpans.high>>>0).toNumber())),e.errorMessage!=null&&(t.errorMessage=String(e.errorMessage)),t},e.toObject=function(e,t){t||={};var n={};if(t.defaults){if(a.Long){var r=new a.Long(0,0,!1);n.rejectedSpans=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.rejectedSpans=t.longs===String?`0`:0;n.errorMessage=``}return e.rejectedSpans!=null&&e.hasOwnProperty(`rejectedSpans`)&&(n.rejectedSpans=typeof e.rejectedSpans==`number`?t.longs===String?String(e.rejectedSpans):e.rejectedSpans:t.longs===String?a.Long.prototype.toString.call(e.rejectedSpans):t.longs===Number?new a.LongBits(e.rejectedSpans.low>>>0,e.rejectedSpans.high>>>0).toNumber():e.rejectedSpans),e.errorMessage!=null&&e.hasOwnProperty(`errorMessage`)&&(n.errorMessage=e.errorMessage),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess`},e})(),e})(),e})(),e.metrics=(function(){var e={};return e.v1=(function(){var e={};return e.MetricsService=(function(){function e(e,t,r){n.rpc.Service.call(this,e,t,r)}return(e.prototype=Object.create(n.rpc.Service.prototype)).constructor=e,e.create=function(e,t,n){return new this(e,t,n)},Object.defineProperty(e.prototype.export=function e(t,n){return this.rpcCall(e,o.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest,o.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse,t,n)},"name",{value:`Export`}),e})(),e.ExportMetricsServiceRequest=(function(){function e(e){if(this.resourceMetrics=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.resourceMetrics=a.emptyArray,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.resourceMetrics!=null&&e.resourceMetrics.length)for(var n=0;n<e.resourceMetrics.length;++n)o.opentelemetry.proto.metrics.v1.ResourceMetrics.encode(e.resourceMetrics[n],t.uint32(10).fork()).ldelim();return t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.resourceMetrics&&a.resourceMetrics.length||(a.resourceMetrics=[]),a.resourceMetrics.push(o.opentelemetry.proto.metrics.v1.ResourceMetrics.decode(e,e.uint32()));break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.resourceMetrics!=null&&e.hasOwnProperty(`resourceMetrics`)){if(!Array.isArray(e.resourceMetrics))return`resourceMetrics: array expected`;for(var t=0;t<e.resourceMetrics.length;++t){var n=o.opentelemetry.proto.metrics.v1.ResourceMetrics.verify(e.resourceMetrics[t]);if(n)return`resourceMetrics.`+n}}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest)return e;var t=new o.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest;if(e.resourceMetrics){if(!Array.isArray(e.resourceMetrics))throw TypeError(`.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest.resourceMetrics: array expected`);t.resourceMetrics=[];for(var n=0;n<e.resourceMetrics.length;++n){if(typeof e.resourceMetrics[n]!=`object`)throw TypeError(`.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest.resourceMetrics: object expected`);t.resourceMetrics[n]=o.opentelemetry.proto.metrics.v1.ResourceMetrics.fromObject(e.resourceMetrics[n])}}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.resourceMetrics=[]),e.resourceMetrics&&e.resourceMetrics.length){n.resourceMetrics=[];for(var r=0;r<e.resourceMetrics.length;++r)n.resourceMetrics[r]=o.opentelemetry.proto.metrics.v1.ResourceMetrics.toObject(e.resourceMetrics[r],t)}return n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest`},e})(),e.ExportMetricsServiceResponse=(function(){function e(e){if(e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.partialSuccess=null,e.create=function(t){return new e(t)},e.encode=function(e,t){return t||=i.create(),e.partialSuccess!=null&&Object.hasOwnProperty.call(e,`partialSuccess`)&&o.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess.encode(e.partialSuccess,t.uint32(10).fork()).ldelim(),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.partialSuccess=o.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess.decode(e,e.uint32());break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.partialSuccess!=null&&e.hasOwnProperty(`partialSuccess`)){var t=o.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess.verify(e.partialSuccess);if(t)return`partialSuccess.`+t}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse)return e;var t=new o.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse;if(e.partialSuccess!=null){if(typeof e.partialSuccess!=`object`)throw TypeError(`.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse.partialSuccess: object expected`);t.partialSuccess=o.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess.fromObject(e.partialSuccess)}return t},e.toObject=function(e,t){t||={};var n={};return t.defaults&&(n.partialSuccess=null),e.partialSuccess!=null&&e.hasOwnProperty(`partialSuccess`)&&(n.partialSuccess=o.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess.toObject(e.partialSuccess,t)),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse`},e})(),e.ExportMetricsPartialSuccess=(function(){function e(e){if(e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.rejectedDataPoints=null,e.prototype.errorMessage=null,e.create=function(t){return new e(t)},e.encode=function(e,t){return t||=i.create(),e.rejectedDataPoints!=null&&Object.hasOwnProperty.call(e,`rejectedDataPoints`)&&t.uint32(8).int64(e.rejectedDataPoints),e.errorMessage!=null&&Object.hasOwnProperty.call(e,`errorMessage`)&&t.uint32(18).string(e.errorMessage),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.rejectedDataPoints=e.int64();break;case 2:a.errorMessage=e.string();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){return typeof e!=`object`||!e?`object expected`:e.rejectedDataPoints!=null&&e.hasOwnProperty(`rejectedDataPoints`)&&!a.isInteger(e.rejectedDataPoints)&&!(e.rejectedDataPoints&&a.isInteger(e.rejectedDataPoints.low)&&a.isInteger(e.rejectedDataPoints.high))?`rejectedDataPoints: integer|Long expected`:e.errorMessage!=null&&e.hasOwnProperty(`errorMessage`)&&!a.isString(e.errorMessage)?`errorMessage: string expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess)return e;var t=new o.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess;return e.rejectedDataPoints!=null&&(a.Long?(t.rejectedDataPoints=a.Long.fromValue(e.rejectedDataPoints)).unsigned=!1:typeof e.rejectedDataPoints==`string`?t.rejectedDataPoints=parseInt(e.rejectedDataPoints,10):typeof e.rejectedDataPoints==`number`?t.rejectedDataPoints=e.rejectedDataPoints:typeof e.rejectedDataPoints==`object`&&(t.rejectedDataPoints=new a.LongBits(e.rejectedDataPoints.low>>>0,e.rejectedDataPoints.high>>>0).toNumber())),e.errorMessage!=null&&(t.errorMessage=String(e.errorMessage)),t},e.toObject=function(e,t){t||={};var n={};if(t.defaults){if(a.Long){var r=new a.Long(0,0,!1);n.rejectedDataPoints=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.rejectedDataPoints=t.longs===String?`0`:0;n.errorMessage=``}return e.rejectedDataPoints!=null&&e.hasOwnProperty(`rejectedDataPoints`)&&(n.rejectedDataPoints=typeof e.rejectedDataPoints==`number`?t.longs===String?String(e.rejectedDataPoints):e.rejectedDataPoints:t.longs===String?a.Long.prototype.toString.call(e.rejectedDataPoints):t.longs===Number?new a.LongBits(e.rejectedDataPoints.low>>>0,e.rejectedDataPoints.high>>>0).toNumber():e.rejectedDataPoints),e.errorMessage!=null&&e.hasOwnProperty(`errorMessage`)&&(n.errorMessage=e.errorMessage),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess`},e})(),e})(),e})(),e.logs=(function(){var e={};return e.v1=(function(){var e={};return e.LogsService=(function(){function e(e,t,r){n.rpc.Service.call(this,e,t,r)}return(e.prototype=Object.create(n.rpc.Service.prototype)).constructor=e,e.create=function(e,t,n){return new this(e,t,n)},Object.defineProperty(e.prototype.export=function e(t,n){return this.rpcCall(e,o.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest,o.opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse,t,n)},"name",{value:`Export`}),e})(),e.ExportLogsServiceRequest=(function(){function e(e){if(this.resourceLogs=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.resourceLogs=a.emptyArray,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.resourceLogs!=null&&e.resourceLogs.length)for(var n=0;n<e.resourceLogs.length;++n)o.opentelemetry.proto.logs.v1.ResourceLogs.encode(e.resourceLogs[n],t.uint32(10).fork()).ldelim();return t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.resourceLogs&&a.resourceLogs.length||(a.resourceLogs=[]),a.resourceLogs.push(o.opentelemetry.proto.logs.v1.ResourceLogs.decode(e,e.uint32()));break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.resourceLogs!=null&&e.hasOwnProperty(`resourceLogs`)){if(!Array.isArray(e.resourceLogs))return`resourceLogs: array expected`;for(var t=0;t<e.resourceLogs.length;++t){var n=o.opentelemetry.proto.logs.v1.ResourceLogs.verify(e.resourceLogs[t]);if(n)return`resourceLogs.`+n}}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest)return e;var t=new o.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest;if(e.resourceLogs){if(!Array.isArray(e.resourceLogs))throw TypeError(`.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest.resourceLogs: array expected`);t.resourceLogs=[];for(var n=0;n<e.resourceLogs.length;++n){if(typeof e.resourceLogs[n]!=`object`)throw TypeError(`.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest.resourceLogs: object expected`);t.resourceLogs[n]=o.opentelemetry.proto.logs.v1.ResourceLogs.fromObject(e.resourceLogs[n])}}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.resourceLogs=[]),e.resourceLogs&&e.resourceLogs.length){n.resourceLogs=[];for(var r=0;r<e.resourceLogs.length;++r)n.resourceLogs[r]=o.opentelemetry.proto.logs.v1.ResourceLogs.toObject(e.resourceLogs[r],t)}return n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest`},e})(),e.ExportLogsServiceResponse=(function(){function e(e){if(e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.partialSuccess=null,e.create=function(t){return new e(t)},e.encode=function(e,t){return t||=i.create(),e.partialSuccess!=null&&Object.hasOwnProperty.call(e,`partialSuccess`)&&o.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess.encode(e.partialSuccess,t.uint32(10).fork()).ldelim(),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.partialSuccess=o.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess.decode(e,e.uint32());break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.partialSuccess!=null&&e.hasOwnProperty(`partialSuccess`)){var t=o.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess.verify(e.partialSuccess);if(t)return`partialSuccess.`+t}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse)return e;var t=new o.opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse;if(e.partialSuccess!=null){if(typeof e.partialSuccess!=`object`)throw TypeError(`.opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse.partialSuccess: object expected`);t.partialSuccess=o.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess.fromObject(e.partialSuccess)}return t},e.toObject=function(e,t){t||={};var n={};return t.defaults&&(n.partialSuccess=null),e.partialSuccess!=null&&e.hasOwnProperty(`partialSuccess`)&&(n.partialSuccess=o.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess.toObject(e.partialSuccess,t)),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse`},e})(),e.ExportLogsPartialSuccess=(function(){function e(e){if(e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.rejectedLogRecords=null,e.prototype.errorMessage=null,e.create=function(t){return new e(t)},e.encode=function(e,t){return t||=i.create(),e.rejectedLogRecords!=null&&Object.hasOwnProperty.call(e,`rejectedLogRecords`)&&t.uint32(8).int64(e.rejectedLogRecords),e.errorMessage!=null&&Object.hasOwnProperty.call(e,`errorMessage`)&&t.uint32(18).string(e.errorMessage),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.rejectedLogRecords=e.int64();break;case 2:a.errorMessage=e.string();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){return typeof e!=`object`||!e?`object expected`:e.rejectedLogRecords!=null&&e.hasOwnProperty(`rejectedLogRecords`)&&!a.isInteger(e.rejectedLogRecords)&&!(e.rejectedLogRecords&&a.isInteger(e.rejectedLogRecords.low)&&a.isInteger(e.rejectedLogRecords.high))?`rejectedLogRecords: integer|Long expected`:e.errorMessage!=null&&e.hasOwnProperty(`errorMessage`)&&!a.isString(e.errorMessage)?`errorMessage: string expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess)return e;var t=new o.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess;return e.rejectedLogRecords!=null&&(a.Long?(t.rejectedLogRecords=a.Long.fromValue(e.rejectedLogRecords)).unsigned=!1:typeof e.rejectedLogRecords==`string`?t.rejectedLogRecords=parseInt(e.rejectedLogRecords,10):typeof e.rejectedLogRecords==`number`?t.rejectedLogRecords=e.rejectedLogRecords:typeof e.rejectedLogRecords==`object`&&(t.rejectedLogRecords=new a.LongBits(e.rejectedLogRecords.low>>>0,e.rejectedLogRecords.high>>>0).toNumber())),e.errorMessage!=null&&(t.errorMessage=String(e.errorMessage)),t},e.toObject=function(e,t){t||={};var n={};if(t.defaults){if(a.Long){var r=new a.Long(0,0,!1);n.rejectedLogRecords=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.rejectedLogRecords=t.longs===String?`0`:0;n.errorMessage=``}return e.rejectedLogRecords!=null&&e.hasOwnProperty(`rejectedLogRecords`)&&(n.rejectedLogRecords=typeof e.rejectedLogRecords==`number`?t.longs===String?String(e.rejectedLogRecords):e.rejectedLogRecords:t.longs===String?a.Long.prototype.toString.call(e.rejectedLogRecords):t.longs===Number?new a.LongBits(e.rejectedLogRecords.low>>>0,e.rejectedLogRecords.high>>>0).toNumber():e.rejectedLogRecords),e.errorMessage!=null&&e.hasOwnProperty(`errorMessage`)&&(n.errorMessage=e.errorMessage),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess`},e})(),e})(),e})(),e})(),e.metrics=(function(){var e={};return e.v1=(function(){var e={};return e.MetricsData=(function(){function e(e){if(this.resourceMetrics=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.resourceMetrics=a.emptyArray,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.resourceMetrics!=null&&e.resourceMetrics.length)for(var n=0;n<e.resourceMetrics.length;++n)o.opentelemetry.proto.metrics.v1.ResourceMetrics.encode(e.resourceMetrics[n],t.uint32(10).fork()).ldelim();return t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.metrics.v1.MetricsData;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.resourceMetrics&&a.resourceMetrics.length||(a.resourceMetrics=[]),a.resourceMetrics.push(o.opentelemetry.proto.metrics.v1.ResourceMetrics.decode(e,e.uint32()));break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.resourceMetrics!=null&&e.hasOwnProperty(`resourceMetrics`)){if(!Array.isArray(e.resourceMetrics))return`resourceMetrics: array expected`;for(var t=0;t<e.resourceMetrics.length;++t){var n=o.opentelemetry.proto.metrics.v1.ResourceMetrics.verify(e.resourceMetrics[t]);if(n)return`resourceMetrics.`+n}}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.metrics.v1.MetricsData)return e;var t=new o.opentelemetry.proto.metrics.v1.MetricsData;if(e.resourceMetrics){if(!Array.isArray(e.resourceMetrics))throw TypeError(`.opentelemetry.proto.metrics.v1.MetricsData.resourceMetrics: array expected`);t.resourceMetrics=[];for(var n=0;n<e.resourceMetrics.length;++n){if(typeof e.resourceMetrics[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.MetricsData.resourceMetrics: object expected`);t.resourceMetrics[n]=o.opentelemetry.proto.metrics.v1.ResourceMetrics.fromObject(e.resourceMetrics[n])}}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.resourceMetrics=[]),e.resourceMetrics&&e.resourceMetrics.length){n.resourceMetrics=[];for(var r=0;r<e.resourceMetrics.length;++r)n.resourceMetrics[r]=o.opentelemetry.proto.metrics.v1.ResourceMetrics.toObject(e.resourceMetrics[r],t)}return n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.metrics.v1.MetricsData`},e})(),e.ResourceMetrics=(function(){function e(e){if(this.scopeMetrics=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.resource=null,e.prototype.scopeMetrics=a.emptyArray,e.prototype.schemaUrl=null,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.resource!=null&&Object.hasOwnProperty.call(e,`resource`)&&o.opentelemetry.proto.resource.v1.Resource.encode(e.resource,t.uint32(10).fork()).ldelim(),e.scopeMetrics!=null&&e.scopeMetrics.length)for(var n=0;n<e.scopeMetrics.length;++n)o.opentelemetry.proto.metrics.v1.ScopeMetrics.encode(e.scopeMetrics[n],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,`schemaUrl`)&&t.uint32(26).string(e.schemaUrl),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.metrics.v1.ResourceMetrics;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.resource=o.opentelemetry.proto.resource.v1.Resource.decode(e,e.uint32());break;case 2:a.scopeMetrics&&a.scopeMetrics.length||(a.scopeMetrics=[]),a.scopeMetrics.push(o.opentelemetry.proto.metrics.v1.ScopeMetrics.decode(e,e.uint32()));break;case 3:a.schemaUrl=e.string();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.resource!=null&&e.hasOwnProperty(`resource`)){var t=o.opentelemetry.proto.resource.v1.Resource.verify(e.resource);if(t)return`resource.`+t}if(e.scopeMetrics!=null&&e.hasOwnProperty(`scopeMetrics`)){if(!Array.isArray(e.scopeMetrics))return`scopeMetrics: array expected`;for(var n=0;n<e.scopeMetrics.length;++n){var t=o.opentelemetry.proto.metrics.v1.ScopeMetrics.verify(e.scopeMetrics[n]);if(t)return`scopeMetrics.`+t}}return e.schemaUrl!=null&&e.hasOwnProperty(`schemaUrl`)&&!a.isString(e.schemaUrl)?`schemaUrl: string expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.metrics.v1.ResourceMetrics)return e;var t=new o.opentelemetry.proto.metrics.v1.ResourceMetrics;if(e.resource!=null){if(typeof e.resource!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.ResourceMetrics.resource: object expected`);t.resource=o.opentelemetry.proto.resource.v1.Resource.fromObject(e.resource)}if(e.scopeMetrics){if(!Array.isArray(e.scopeMetrics))throw TypeError(`.opentelemetry.proto.metrics.v1.ResourceMetrics.scopeMetrics: array expected`);t.scopeMetrics=[];for(var n=0;n<e.scopeMetrics.length;++n){if(typeof e.scopeMetrics[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.ResourceMetrics.scopeMetrics: object expected`);t.scopeMetrics[n]=o.opentelemetry.proto.metrics.v1.ScopeMetrics.fromObject(e.scopeMetrics[n])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.scopeMetrics=[]),t.defaults&&(n.resource=null,n.schemaUrl=``),e.resource!=null&&e.hasOwnProperty(`resource`)&&(n.resource=o.opentelemetry.proto.resource.v1.Resource.toObject(e.resource,t)),e.scopeMetrics&&e.scopeMetrics.length){n.scopeMetrics=[];for(var r=0;r<e.scopeMetrics.length;++r)n.scopeMetrics[r]=o.opentelemetry.proto.metrics.v1.ScopeMetrics.toObject(e.scopeMetrics[r],t)}return e.schemaUrl!=null&&e.hasOwnProperty(`schemaUrl`)&&(n.schemaUrl=e.schemaUrl),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.metrics.v1.ResourceMetrics`},e})(),e.ScopeMetrics=(function(){function e(e){if(this.metrics=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.scope=null,e.prototype.metrics=a.emptyArray,e.prototype.schemaUrl=null,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.scope!=null&&Object.hasOwnProperty.call(e,`scope`)&&o.opentelemetry.proto.common.v1.InstrumentationScope.encode(e.scope,t.uint32(10).fork()).ldelim(),e.metrics!=null&&e.metrics.length)for(var n=0;n<e.metrics.length;++n)o.opentelemetry.proto.metrics.v1.Metric.encode(e.metrics[n],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,`schemaUrl`)&&t.uint32(26).string(e.schemaUrl),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.metrics.v1.ScopeMetrics;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.scope=o.opentelemetry.proto.common.v1.InstrumentationScope.decode(e,e.uint32());break;case 2:a.metrics&&a.metrics.length||(a.metrics=[]),a.metrics.push(o.opentelemetry.proto.metrics.v1.Metric.decode(e,e.uint32()));break;case 3:a.schemaUrl=e.string();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.scope!=null&&e.hasOwnProperty(`scope`)){var t=o.opentelemetry.proto.common.v1.InstrumentationScope.verify(e.scope);if(t)return`scope.`+t}if(e.metrics!=null&&e.hasOwnProperty(`metrics`)){if(!Array.isArray(e.metrics))return`metrics: array expected`;for(var n=0;n<e.metrics.length;++n){var t=o.opentelemetry.proto.metrics.v1.Metric.verify(e.metrics[n]);if(t)return`metrics.`+t}}return e.schemaUrl!=null&&e.hasOwnProperty(`schemaUrl`)&&!a.isString(e.schemaUrl)?`schemaUrl: string expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.metrics.v1.ScopeMetrics)return e;var t=new o.opentelemetry.proto.metrics.v1.ScopeMetrics;if(e.scope!=null){if(typeof e.scope!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.ScopeMetrics.scope: object expected`);t.scope=o.opentelemetry.proto.common.v1.InstrumentationScope.fromObject(e.scope)}if(e.metrics){if(!Array.isArray(e.metrics))throw TypeError(`.opentelemetry.proto.metrics.v1.ScopeMetrics.metrics: array expected`);t.metrics=[];for(var n=0;n<e.metrics.length;++n){if(typeof e.metrics[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.ScopeMetrics.metrics: object expected`);t.metrics[n]=o.opentelemetry.proto.metrics.v1.Metric.fromObject(e.metrics[n])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.metrics=[]),t.defaults&&(n.scope=null,n.schemaUrl=``),e.scope!=null&&e.hasOwnProperty(`scope`)&&(n.scope=o.opentelemetry.proto.common.v1.InstrumentationScope.toObject(e.scope,t)),e.metrics&&e.metrics.length){n.metrics=[];for(var r=0;r<e.metrics.length;++r)n.metrics[r]=o.opentelemetry.proto.metrics.v1.Metric.toObject(e.metrics[r],t)}return e.schemaUrl!=null&&e.hasOwnProperty(`schemaUrl`)&&(n.schemaUrl=e.schemaUrl),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.metrics.v1.ScopeMetrics`},e})(),e.Metric=(function(){function e(e){if(this.metadata=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}e.prototype.name=null,e.prototype.description=null,e.prototype.unit=null,e.prototype.gauge=null,e.prototype.sum=null,e.prototype.histogram=null,e.prototype.exponentialHistogram=null,e.prototype.summary=null,e.prototype.metadata=a.emptyArray;var t;return Object.defineProperty(e.prototype,"data",{get:a.oneOfGetter(t=[`gauge`,`sum`,`histogram`,`exponentialHistogram`,`summary`]),set:a.oneOfSetter(t)}),e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.name!=null&&Object.hasOwnProperty.call(e,`name`)&&t.uint32(10).string(e.name),e.description!=null&&Object.hasOwnProperty.call(e,`description`)&&t.uint32(18).string(e.description),e.unit!=null&&Object.hasOwnProperty.call(e,`unit`)&&t.uint32(26).string(e.unit),e.gauge!=null&&Object.hasOwnProperty.call(e,`gauge`)&&o.opentelemetry.proto.metrics.v1.Gauge.encode(e.gauge,t.uint32(42).fork()).ldelim(),e.sum!=null&&Object.hasOwnProperty.call(e,`sum`)&&o.opentelemetry.proto.metrics.v1.Sum.encode(e.sum,t.uint32(58).fork()).ldelim(),e.histogram!=null&&Object.hasOwnProperty.call(e,`histogram`)&&o.opentelemetry.proto.metrics.v1.Histogram.encode(e.histogram,t.uint32(74).fork()).ldelim(),e.exponentialHistogram!=null&&Object.hasOwnProperty.call(e,`exponentialHistogram`)&&o.opentelemetry.proto.metrics.v1.ExponentialHistogram.encode(e.exponentialHistogram,t.uint32(82).fork()).ldelim(),e.summary!=null&&Object.hasOwnProperty.call(e,`summary`)&&o.opentelemetry.proto.metrics.v1.Summary.encode(e.summary,t.uint32(90).fork()).ldelim(),e.metadata!=null&&e.metadata.length)for(var n=0;n<e.metadata.length;++n)o.opentelemetry.proto.common.v1.KeyValue.encode(e.metadata[n],t.uint32(98).fork()).ldelim();return t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.metrics.v1.Metric;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.name=e.string();break;case 2:a.description=e.string();break;case 3:a.unit=e.string();break;case 5:a.gauge=o.opentelemetry.proto.metrics.v1.Gauge.decode(e,e.uint32());break;case 7:a.sum=o.opentelemetry.proto.metrics.v1.Sum.decode(e,e.uint32());break;case 9:a.histogram=o.opentelemetry.proto.metrics.v1.Histogram.decode(e,e.uint32());break;case 10:a.exponentialHistogram=o.opentelemetry.proto.metrics.v1.ExponentialHistogram.decode(e,e.uint32());break;case 11:a.summary=o.opentelemetry.proto.metrics.v1.Summary.decode(e,e.uint32());break;case 12:a.metadata&&a.metadata.length||(a.metadata=[]),a.metadata.push(o.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;var t={};if(e.name!=null&&e.hasOwnProperty(`name`)&&!a.isString(e.name))return`name: string expected`;if(e.description!=null&&e.hasOwnProperty(`description`)&&!a.isString(e.description))return`description: string expected`;if(e.unit!=null&&e.hasOwnProperty(`unit`)&&!a.isString(e.unit))return`unit: string expected`;if(e.gauge!=null&&e.hasOwnProperty(`gauge`)){t.data=1;var n=o.opentelemetry.proto.metrics.v1.Gauge.verify(e.gauge);if(n)return`gauge.`+n}if(e.sum!=null&&e.hasOwnProperty(`sum`)){if(t.data===1)return`data: multiple values`;t.data=1;var n=o.opentelemetry.proto.metrics.v1.Sum.verify(e.sum);if(n)return`sum.`+n}if(e.histogram!=null&&e.hasOwnProperty(`histogram`)){if(t.data===1)return`data: multiple values`;t.data=1;var n=o.opentelemetry.proto.metrics.v1.Histogram.verify(e.histogram);if(n)return`histogram.`+n}if(e.exponentialHistogram!=null&&e.hasOwnProperty(`exponentialHistogram`)){if(t.data===1)return`data: multiple values`;t.data=1;var n=o.opentelemetry.proto.metrics.v1.ExponentialHistogram.verify(e.exponentialHistogram);if(n)return`exponentialHistogram.`+n}if(e.summary!=null&&e.hasOwnProperty(`summary`)){if(t.data===1)return`data: multiple values`;t.data=1;var n=o.opentelemetry.proto.metrics.v1.Summary.verify(e.summary);if(n)return`summary.`+n}if(e.metadata!=null&&e.hasOwnProperty(`metadata`)){if(!Array.isArray(e.metadata))return`metadata: array expected`;for(var r=0;r<e.metadata.length;++r){var n=o.opentelemetry.proto.common.v1.KeyValue.verify(e.metadata[r]);if(n)return`metadata.`+n}}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.metrics.v1.Metric)return e;var t=new o.opentelemetry.proto.metrics.v1.Metric;if(e.name!=null&&(t.name=String(e.name)),e.description!=null&&(t.description=String(e.description)),e.unit!=null&&(t.unit=String(e.unit)),e.gauge!=null){if(typeof e.gauge!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.Metric.gauge: object expected`);t.gauge=o.opentelemetry.proto.metrics.v1.Gauge.fromObject(e.gauge)}if(e.sum!=null){if(typeof e.sum!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.Metric.sum: object expected`);t.sum=o.opentelemetry.proto.metrics.v1.Sum.fromObject(e.sum)}if(e.histogram!=null){if(typeof e.histogram!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.Metric.histogram: object expected`);t.histogram=o.opentelemetry.proto.metrics.v1.Histogram.fromObject(e.histogram)}if(e.exponentialHistogram!=null){if(typeof e.exponentialHistogram!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.Metric.exponentialHistogram: object expected`);t.exponentialHistogram=o.opentelemetry.proto.metrics.v1.ExponentialHistogram.fromObject(e.exponentialHistogram)}if(e.summary!=null){if(typeof e.summary!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.Metric.summary: object expected`);t.summary=o.opentelemetry.proto.metrics.v1.Summary.fromObject(e.summary)}if(e.metadata){if(!Array.isArray(e.metadata))throw TypeError(`.opentelemetry.proto.metrics.v1.Metric.metadata: array expected`);t.metadata=[];for(var n=0;n<e.metadata.length;++n){if(typeof e.metadata[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.Metric.metadata: object expected`);t.metadata[n]=o.opentelemetry.proto.common.v1.KeyValue.fromObject(e.metadata[n])}}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.metadata=[]),t.defaults&&(n.name=``,n.description=``,n.unit=``),e.name!=null&&e.hasOwnProperty(`name`)&&(n.name=e.name),e.description!=null&&e.hasOwnProperty(`description`)&&(n.description=e.description),e.unit!=null&&e.hasOwnProperty(`unit`)&&(n.unit=e.unit),e.gauge!=null&&e.hasOwnProperty(`gauge`)&&(n.gauge=o.opentelemetry.proto.metrics.v1.Gauge.toObject(e.gauge,t),t.oneofs&&(n.data=`gauge`)),e.sum!=null&&e.hasOwnProperty(`sum`)&&(n.sum=o.opentelemetry.proto.metrics.v1.Sum.toObject(e.sum,t),t.oneofs&&(n.data=`sum`)),e.histogram!=null&&e.hasOwnProperty(`histogram`)&&(n.histogram=o.opentelemetry.proto.metrics.v1.Histogram.toObject(e.histogram,t),t.oneofs&&(n.data=`histogram`)),e.exponentialHistogram!=null&&e.hasOwnProperty(`exponentialHistogram`)&&(n.exponentialHistogram=o.opentelemetry.proto.metrics.v1.ExponentialHistogram.toObject(e.exponentialHistogram,t),t.oneofs&&(n.data=`exponentialHistogram`)),e.summary!=null&&e.hasOwnProperty(`summary`)&&(n.summary=o.opentelemetry.proto.metrics.v1.Summary.toObject(e.summary,t),t.oneofs&&(n.data=`summary`)),e.metadata&&e.metadata.length){n.metadata=[];for(var r=0;r<e.metadata.length;++r)n.metadata[r]=o.opentelemetry.proto.common.v1.KeyValue.toObject(e.metadata[r],t)}return n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.metrics.v1.Metric`},e})(),e.Gauge=(function(){function e(e){if(this.dataPoints=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.dataPoints=a.emptyArray,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.dataPoints!=null&&e.dataPoints.length)for(var n=0;n<e.dataPoints.length;++n)o.opentelemetry.proto.metrics.v1.NumberDataPoint.encode(e.dataPoints[n],t.uint32(10).fork()).ldelim();return t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.metrics.v1.Gauge;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.dataPoints&&a.dataPoints.length||(a.dataPoints=[]),a.dataPoints.push(o.opentelemetry.proto.metrics.v1.NumberDataPoint.decode(e,e.uint32()));break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.dataPoints!=null&&e.hasOwnProperty(`dataPoints`)){if(!Array.isArray(e.dataPoints))return`dataPoints: array expected`;for(var t=0;t<e.dataPoints.length;++t){var n=o.opentelemetry.proto.metrics.v1.NumberDataPoint.verify(e.dataPoints[t]);if(n)return`dataPoints.`+n}}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.metrics.v1.Gauge)return e;var t=new o.opentelemetry.proto.metrics.v1.Gauge;if(e.dataPoints){if(!Array.isArray(e.dataPoints))throw TypeError(`.opentelemetry.proto.metrics.v1.Gauge.dataPoints: array expected`);t.dataPoints=[];for(var n=0;n<e.dataPoints.length;++n){if(typeof e.dataPoints[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.Gauge.dataPoints: object expected`);t.dataPoints[n]=o.opentelemetry.proto.metrics.v1.NumberDataPoint.fromObject(e.dataPoints[n])}}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.dataPoints=[]),e.dataPoints&&e.dataPoints.length){n.dataPoints=[];for(var r=0;r<e.dataPoints.length;++r)n.dataPoints[r]=o.opentelemetry.proto.metrics.v1.NumberDataPoint.toObject(e.dataPoints[r],t)}return n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.metrics.v1.Gauge`},e})(),e.Sum=(function(){function e(e){if(this.dataPoints=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.dataPoints=a.emptyArray,e.prototype.aggregationTemporality=null,e.prototype.isMonotonic=null,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.dataPoints!=null&&e.dataPoints.length)for(var n=0;n<e.dataPoints.length;++n)o.opentelemetry.proto.metrics.v1.NumberDataPoint.encode(e.dataPoints[n],t.uint32(10).fork()).ldelim();return e.aggregationTemporality!=null&&Object.hasOwnProperty.call(e,`aggregationTemporality`)&&t.uint32(16).int32(e.aggregationTemporality),e.isMonotonic!=null&&Object.hasOwnProperty.call(e,`isMonotonic`)&&t.uint32(24).bool(e.isMonotonic),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.metrics.v1.Sum;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.dataPoints&&a.dataPoints.length||(a.dataPoints=[]),a.dataPoints.push(o.opentelemetry.proto.metrics.v1.NumberDataPoint.decode(e,e.uint32()));break;case 2:a.aggregationTemporality=e.int32();break;case 3:a.isMonotonic=e.bool();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.dataPoints!=null&&e.hasOwnProperty(`dataPoints`)){if(!Array.isArray(e.dataPoints))return`dataPoints: array expected`;for(var t=0;t<e.dataPoints.length;++t){var n=o.opentelemetry.proto.metrics.v1.NumberDataPoint.verify(e.dataPoints[t]);if(n)return`dataPoints.`+n}}if(e.aggregationTemporality!=null&&e.hasOwnProperty(`aggregationTemporality`))switch(e.aggregationTemporality){default:return`aggregationTemporality: enum value expected`;case 0:case 1:case 2:}return e.isMonotonic!=null&&e.hasOwnProperty(`isMonotonic`)&&typeof e.isMonotonic!=`boolean`?`isMonotonic: boolean expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.metrics.v1.Sum)return e;var t=new o.opentelemetry.proto.metrics.v1.Sum;if(e.dataPoints){if(!Array.isArray(e.dataPoints))throw TypeError(`.opentelemetry.proto.metrics.v1.Sum.dataPoints: array expected`);t.dataPoints=[];for(var n=0;n<e.dataPoints.length;++n){if(typeof e.dataPoints[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.Sum.dataPoints: object expected`);t.dataPoints[n]=o.opentelemetry.proto.metrics.v1.NumberDataPoint.fromObject(e.dataPoints[n])}}switch(e.aggregationTemporality){default:if(typeof e.aggregationTemporality==`number`){t.aggregationTemporality=e.aggregationTemporality;break}break;case`AGGREGATION_TEMPORALITY_UNSPECIFIED`:case 0:t.aggregationTemporality=0;break;case`AGGREGATION_TEMPORALITY_DELTA`:case 1:t.aggregationTemporality=1;break;case`AGGREGATION_TEMPORALITY_CUMULATIVE`:case 2:t.aggregationTemporality=2}return e.isMonotonic!=null&&(t.isMonotonic=!!e.isMonotonic),t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.dataPoints=[]),t.defaults&&(n.aggregationTemporality=t.enums===String?`AGGREGATION_TEMPORALITY_UNSPECIFIED`:0,n.isMonotonic=!1),e.dataPoints&&e.dataPoints.length){n.dataPoints=[];for(var r=0;r<e.dataPoints.length;++r)n.dataPoints[r]=o.opentelemetry.proto.metrics.v1.NumberDataPoint.toObject(e.dataPoints[r],t)}return e.aggregationTemporality!=null&&e.hasOwnProperty(`aggregationTemporality`)&&(n.aggregationTemporality=t.enums===String?o.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]===void 0?e.aggregationTemporality:o.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]:e.aggregationTemporality),e.isMonotonic!=null&&e.hasOwnProperty(`isMonotonic`)&&(n.isMonotonic=e.isMonotonic),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.metrics.v1.Sum`},e})(),e.Histogram=(function(){function e(e){if(this.dataPoints=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.dataPoints=a.emptyArray,e.prototype.aggregationTemporality=null,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.dataPoints!=null&&e.dataPoints.length)for(var n=0;n<e.dataPoints.length;++n)o.opentelemetry.proto.metrics.v1.HistogramDataPoint.encode(e.dataPoints[n],t.uint32(10).fork()).ldelim();return e.aggregationTemporality!=null&&Object.hasOwnProperty.call(e,`aggregationTemporality`)&&t.uint32(16).int32(e.aggregationTemporality),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.metrics.v1.Histogram;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.dataPoints&&a.dataPoints.length||(a.dataPoints=[]),a.dataPoints.push(o.opentelemetry.proto.metrics.v1.HistogramDataPoint.decode(e,e.uint32()));break;case 2:a.aggregationTemporality=e.int32();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.dataPoints!=null&&e.hasOwnProperty(`dataPoints`)){if(!Array.isArray(e.dataPoints))return`dataPoints: array expected`;for(var t=0;t<e.dataPoints.length;++t){var n=o.opentelemetry.proto.metrics.v1.HistogramDataPoint.verify(e.dataPoints[t]);if(n)return`dataPoints.`+n}}if(e.aggregationTemporality!=null&&e.hasOwnProperty(`aggregationTemporality`))switch(e.aggregationTemporality){default:return`aggregationTemporality: enum value expected`;case 0:case 1:case 2:}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.metrics.v1.Histogram)return e;var t=new o.opentelemetry.proto.metrics.v1.Histogram;if(e.dataPoints){if(!Array.isArray(e.dataPoints))throw TypeError(`.opentelemetry.proto.metrics.v1.Histogram.dataPoints: array expected`);t.dataPoints=[];for(var n=0;n<e.dataPoints.length;++n){if(typeof e.dataPoints[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.Histogram.dataPoints: object expected`);t.dataPoints[n]=o.opentelemetry.proto.metrics.v1.HistogramDataPoint.fromObject(e.dataPoints[n])}}switch(e.aggregationTemporality){default:if(typeof e.aggregationTemporality==`number`){t.aggregationTemporality=e.aggregationTemporality;break}break;case`AGGREGATION_TEMPORALITY_UNSPECIFIED`:case 0:t.aggregationTemporality=0;break;case`AGGREGATION_TEMPORALITY_DELTA`:case 1:t.aggregationTemporality=1;break;case`AGGREGATION_TEMPORALITY_CUMULATIVE`:case 2:t.aggregationTemporality=2}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.dataPoints=[]),t.defaults&&(n.aggregationTemporality=t.enums===String?`AGGREGATION_TEMPORALITY_UNSPECIFIED`:0),e.dataPoints&&e.dataPoints.length){n.dataPoints=[];for(var r=0;r<e.dataPoints.length;++r)n.dataPoints[r]=o.opentelemetry.proto.metrics.v1.HistogramDataPoint.toObject(e.dataPoints[r],t)}return e.aggregationTemporality!=null&&e.hasOwnProperty(`aggregationTemporality`)&&(n.aggregationTemporality=t.enums===String?o.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]===void 0?e.aggregationTemporality:o.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]:e.aggregationTemporality),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.metrics.v1.Histogram`},e})(),e.ExponentialHistogram=(function(){function e(e){if(this.dataPoints=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.dataPoints=a.emptyArray,e.prototype.aggregationTemporality=null,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.dataPoints!=null&&e.dataPoints.length)for(var n=0;n<e.dataPoints.length;++n)o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.encode(e.dataPoints[n],t.uint32(10).fork()).ldelim();return e.aggregationTemporality!=null&&Object.hasOwnProperty.call(e,`aggregationTemporality`)&&t.uint32(16).int32(e.aggregationTemporality),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.metrics.v1.ExponentialHistogram;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.dataPoints&&a.dataPoints.length||(a.dataPoints=[]),a.dataPoints.push(o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.decode(e,e.uint32()));break;case 2:a.aggregationTemporality=e.int32();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.dataPoints!=null&&e.hasOwnProperty(`dataPoints`)){if(!Array.isArray(e.dataPoints))return`dataPoints: array expected`;for(var t=0;t<e.dataPoints.length;++t){var n=o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.verify(e.dataPoints[t]);if(n)return`dataPoints.`+n}}if(e.aggregationTemporality!=null&&e.hasOwnProperty(`aggregationTemporality`))switch(e.aggregationTemporality){default:return`aggregationTemporality: enum value expected`;case 0:case 1:case 2:}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.metrics.v1.ExponentialHistogram)return e;var t=new o.opentelemetry.proto.metrics.v1.ExponentialHistogram;if(e.dataPoints){if(!Array.isArray(e.dataPoints))throw TypeError(`.opentelemetry.proto.metrics.v1.ExponentialHistogram.dataPoints: array expected`);t.dataPoints=[];for(var n=0;n<e.dataPoints.length;++n){if(typeof e.dataPoints[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.ExponentialHistogram.dataPoints: object expected`);t.dataPoints[n]=o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.fromObject(e.dataPoints[n])}}switch(e.aggregationTemporality){default:if(typeof e.aggregationTemporality==`number`){t.aggregationTemporality=e.aggregationTemporality;break}break;case`AGGREGATION_TEMPORALITY_UNSPECIFIED`:case 0:t.aggregationTemporality=0;break;case`AGGREGATION_TEMPORALITY_DELTA`:case 1:t.aggregationTemporality=1;break;case`AGGREGATION_TEMPORALITY_CUMULATIVE`:case 2:t.aggregationTemporality=2}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.dataPoints=[]),t.defaults&&(n.aggregationTemporality=t.enums===String?`AGGREGATION_TEMPORALITY_UNSPECIFIED`:0),e.dataPoints&&e.dataPoints.length){n.dataPoints=[];for(var r=0;r<e.dataPoints.length;++r)n.dataPoints[r]=o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.toObject(e.dataPoints[r],t)}return e.aggregationTemporality!=null&&e.hasOwnProperty(`aggregationTemporality`)&&(n.aggregationTemporality=t.enums===String?o.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]===void 0?e.aggregationTemporality:o.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]:e.aggregationTemporality),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.metrics.v1.ExponentialHistogram`},e})(),e.Summary=(function(){function e(e){if(this.dataPoints=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.dataPoints=a.emptyArray,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.dataPoints!=null&&e.dataPoints.length)for(var n=0;n<e.dataPoints.length;++n)o.opentelemetry.proto.metrics.v1.SummaryDataPoint.encode(e.dataPoints[n],t.uint32(10).fork()).ldelim();return t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.metrics.v1.Summary;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.dataPoints&&a.dataPoints.length||(a.dataPoints=[]),a.dataPoints.push(o.opentelemetry.proto.metrics.v1.SummaryDataPoint.decode(e,e.uint32()));break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.dataPoints!=null&&e.hasOwnProperty(`dataPoints`)){if(!Array.isArray(e.dataPoints))return`dataPoints: array expected`;for(var t=0;t<e.dataPoints.length;++t){var n=o.opentelemetry.proto.metrics.v1.SummaryDataPoint.verify(e.dataPoints[t]);if(n)return`dataPoints.`+n}}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.metrics.v1.Summary)return e;var t=new o.opentelemetry.proto.metrics.v1.Summary;if(e.dataPoints){if(!Array.isArray(e.dataPoints))throw TypeError(`.opentelemetry.proto.metrics.v1.Summary.dataPoints: array expected`);t.dataPoints=[];for(var n=0;n<e.dataPoints.length;++n){if(typeof e.dataPoints[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.Summary.dataPoints: object expected`);t.dataPoints[n]=o.opentelemetry.proto.metrics.v1.SummaryDataPoint.fromObject(e.dataPoints[n])}}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.dataPoints=[]),e.dataPoints&&e.dataPoints.length){n.dataPoints=[];for(var r=0;r<e.dataPoints.length;++r)n.dataPoints[r]=o.opentelemetry.proto.metrics.v1.SummaryDataPoint.toObject(e.dataPoints[r],t)}return n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.metrics.v1.Summary`},e})(),e.AggregationTemporality=(function(){var e={},t=Object.create(e);return t[e[0]=`AGGREGATION_TEMPORALITY_UNSPECIFIED`]=0,t[e[1]=`AGGREGATION_TEMPORALITY_DELTA`]=1,t[e[2]=`AGGREGATION_TEMPORALITY_CUMULATIVE`]=2,t})(),e.DataPointFlags=(function(){var e={},t=Object.create(e);return t[e[0]=`DATA_POINT_FLAGS_DO_NOT_USE`]=0,t[e[1]=`DATA_POINT_FLAGS_NO_RECORDED_VALUE_MASK`]=1,t})(),e.NumberDataPoint=(function(){function e(e){if(this.attributes=[],this.exemplars=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}e.prototype.attributes=a.emptyArray,e.prototype.startTimeUnixNano=null,e.prototype.timeUnixNano=null,e.prototype.asDouble=null,e.prototype.asInt=null,e.prototype.exemplars=a.emptyArray,e.prototype.flags=null;var t;return Object.defineProperty(e.prototype,"value",{get:a.oneOfGetter(t=[`asDouble`,`asInt`]),set:a.oneOfSetter(t)}),e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.startTimeUnixNano!=null&&Object.hasOwnProperty.call(e,`startTimeUnixNano`)&&t.uint32(17).fixed64(e.startTimeUnixNano),e.timeUnixNano!=null&&Object.hasOwnProperty.call(e,`timeUnixNano`)&&t.uint32(25).fixed64(e.timeUnixNano),e.asDouble!=null&&Object.hasOwnProperty.call(e,`asDouble`)&&t.uint32(33).double(e.asDouble),e.exemplars!=null&&e.exemplars.length)for(var n=0;n<e.exemplars.length;++n)o.opentelemetry.proto.metrics.v1.Exemplar.encode(e.exemplars[n],t.uint32(42).fork()).ldelim();if(e.asInt!=null&&Object.hasOwnProperty.call(e,`asInt`)&&t.uint32(49).sfixed64(e.asInt),e.attributes!=null&&e.attributes.length)for(var n=0;n<e.attributes.length;++n)o.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[n],t.uint32(58).fork()).ldelim();return e.flags!=null&&Object.hasOwnProperty.call(e,`flags`)&&t.uint32(64).uint32(e.flags),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.metrics.v1.NumberDataPoint;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 7:a.attributes&&a.attributes.length||(a.attributes=[]),a.attributes.push(o.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break;case 2:a.startTimeUnixNano=e.fixed64();break;case 3:a.timeUnixNano=e.fixed64();break;case 4:a.asDouble=e.double();break;case 6:a.asInt=e.sfixed64();break;case 5:a.exemplars&&a.exemplars.length||(a.exemplars=[]),a.exemplars.push(o.opentelemetry.proto.metrics.v1.Exemplar.decode(e,e.uint32()));break;case 8:a.flags=e.uint32();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;var t={};if(e.attributes!=null&&e.hasOwnProperty(`attributes`)){if(!Array.isArray(e.attributes))return`attributes: array expected`;for(var n=0;n<e.attributes.length;++n){var r=o.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[n]);if(r)return`attributes.`+r}}if(e.startTimeUnixNano!=null&&e.hasOwnProperty(`startTimeUnixNano`)&&!a.isInteger(e.startTimeUnixNano)&&!(e.startTimeUnixNano&&a.isInteger(e.startTimeUnixNano.low)&&a.isInteger(e.startTimeUnixNano.high)))return`startTimeUnixNano: integer|Long expected`;if(e.timeUnixNano!=null&&e.hasOwnProperty(`timeUnixNano`)&&!a.isInteger(e.timeUnixNano)&&!(e.timeUnixNano&&a.isInteger(e.timeUnixNano.low)&&a.isInteger(e.timeUnixNano.high)))return`timeUnixNano: integer|Long expected`;if(e.asDouble!=null&&e.hasOwnProperty(`asDouble`)&&(t.value=1,typeof e.asDouble!=`number`))return`asDouble: number expected`;if(e.asInt!=null&&e.hasOwnProperty(`asInt`)){if(t.value===1)return`value: multiple values`;if(t.value=1,!a.isInteger(e.asInt)&&!(e.asInt&&a.isInteger(e.asInt.low)&&a.isInteger(e.asInt.high)))return`asInt: integer|Long expected`}if(e.exemplars!=null&&e.hasOwnProperty(`exemplars`)){if(!Array.isArray(e.exemplars))return`exemplars: array expected`;for(var n=0;n<e.exemplars.length;++n){var r=o.opentelemetry.proto.metrics.v1.Exemplar.verify(e.exemplars[n]);if(r)return`exemplars.`+r}}return e.flags!=null&&e.hasOwnProperty(`flags`)&&!a.isInteger(e.flags)?`flags: integer expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.metrics.v1.NumberDataPoint)return e;var t=new o.opentelemetry.proto.metrics.v1.NumberDataPoint;if(e.attributes){if(!Array.isArray(e.attributes))throw TypeError(`.opentelemetry.proto.metrics.v1.NumberDataPoint.attributes: array expected`);t.attributes=[];for(var n=0;n<e.attributes.length;++n){if(typeof e.attributes[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.NumberDataPoint.attributes: object expected`);t.attributes[n]=o.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[n])}}if(e.startTimeUnixNano!=null&&(a.Long?(t.startTimeUnixNano=a.Long.fromValue(e.startTimeUnixNano)).unsigned=!1:typeof e.startTimeUnixNano==`string`?t.startTimeUnixNano=parseInt(e.startTimeUnixNano,10):typeof e.startTimeUnixNano==`number`?t.startTimeUnixNano=e.startTimeUnixNano:typeof e.startTimeUnixNano==`object`&&(t.startTimeUnixNano=new a.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber())),e.timeUnixNano!=null&&(a.Long?(t.timeUnixNano=a.Long.fromValue(e.timeUnixNano)).unsigned=!1:typeof e.timeUnixNano==`string`?t.timeUnixNano=parseInt(e.timeUnixNano,10):typeof e.timeUnixNano==`number`?t.timeUnixNano=e.timeUnixNano:typeof e.timeUnixNano==`object`&&(t.timeUnixNano=new a.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber())),e.asDouble!=null&&(t.asDouble=Number(e.asDouble)),e.asInt!=null&&(a.Long?(t.asInt=a.Long.fromValue(e.asInt)).unsigned=!1:typeof e.asInt==`string`?t.asInt=parseInt(e.asInt,10):typeof e.asInt==`number`?t.asInt=e.asInt:typeof e.asInt==`object`&&(t.asInt=new a.LongBits(e.asInt.low>>>0,e.asInt.high>>>0).toNumber())),e.exemplars){if(!Array.isArray(e.exemplars))throw TypeError(`.opentelemetry.proto.metrics.v1.NumberDataPoint.exemplars: array expected`);t.exemplars=[];for(var n=0;n<e.exemplars.length;++n){if(typeof e.exemplars[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.NumberDataPoint.exemplars: object expected`);t.exemplars[n]=o.opentelemetry.proto.metrics.v1.Exemplar.fromObject(e.exemplars[n])}}return e.flags!=null&&(t.flags=e.flags>>>0),t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.exemplars=[],n.attributes=[]),t.defaults){if(a.Long){var r=new a.Long(0,0,!1);n.startTimeUnixNano=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.startTimeUnixNano=t.longs===String?`0`:0;if(a.Long){var r=new a.Long(0,0,!1);n.timeUnixNano=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.timeUnixNano=t.longs===String?`0`:0;n.flags=0}if(e.startTimeUnixNano!=null&&e.hasOwnProperty(`startTimeUnixNano`)&&(n.startTimeUnixNano=typeof e.startTimeUnixNano==`number`?t.longs===String?String(e.startTimeUnixNano):e.startTimeUnixNano:t.longs===String?a.Long.prototype.toString.call(e.startTimeUnixNano):t.longs===Number?new a.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber():e.startTimeUnixNano),e.timeUnixNano!=null&&e.hasOwnProperty(`timeUnixNano`)&&(n.timeUnixNano=typeof e.timeUnixNano==`number`?t.longs===String?String(e.timeUnixNano):e.timeUnixNano:t.longs===String?a.Long.prototype.toString.call(e.timeUnixNano):t.longs===Number?new a.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber():e.timeUnixNano),e.asDouble!=null&&e.hasOwnProperty(`asDouble`)&&(n.asDouble=t.json&&!isFinite(e.asDouble)?String(e.asDouble):e.asDouble,t.oneofs&&(n.value=`asDouble`)),e.exemplars&&e.exemplars.length){n.exemplars=[];for(var i=0;i<e.exemplars.length;++i)n.exemplars[i]=o.opentelemetry.proto.metrics.v1.Exemplar.toObject(e.exemplars[i],t)}if(e.asInt!=null&&e.hasOwnProperty(`asInt`)&&(n.asInt=typeof e.asInt==`number`?t.longs===String?String(e.asInt):e.asInt:t.longs===String?a.Long.prototype.toString.call(e.asInt):t.longs===Number?new a.LongBits(e.asInt.low>>>0,e.asInt.high>>>0).toNumber():e.asInt,t.oneofs&&(n.value=`asInt`)),e.attributes&&e.attributes.length){n.attributes=[];for(var i=0;i<e.attributes.length;++i)n.attributes[i]=o.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[i],t)}return e.flags!=null&&e.hasOwnProperty(`flags`)&&(n.flags=e.flags),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.metrics.v1.NumberDataPoint`},e})(),e.HistogramDataPoint=(function(){function e(e){if(this.attributes=[],this.bucketCounts=[],this.explicitBounds=[],this.exemplars=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}e.prototype.attributes=a.emptyArray,e.prototype.startTimeUnixNano=null,e.prototype.timeUnixNano=null,e.prototype.count=null,e.prototype.sum=null,e.prototype.bucketCounts=a.emptyArray,e.prototype.explicitBounds=a.emptyArray,e.prototype.exemplars=a.emptyArray,e.prototype.flags=null,e.prototype.min=null,e.prototype.max=null;var t;return Object.defineProperty(e.prototype,"_sum",{get:a.oneOfGetter(t=[`sum`]),set:a.oneOfSetter(t)}),Object.defineProperty(e.prototype,"_min",{get:a.oneOfGetter(t=[`min`]),set:a.oneOfSetter(t)}),Object.defineProperty(e.prototype,"_max",{get:a.oneOfGetter(t=[`max`]),set:a.oneOfSetter(t)}),e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.startTimeUnixNano!=null&&Object.hasOwnProperty.call(e,`startTimeUnixNano`)&&t.uint32(17).fixed64(e.startTimeUnixNano),e.timeUnixNano!=null&&Object.hasOwnProperty.call(e,`timeUnixNano`)&&t.uint32(25).fixed64(e.timeUnixNano),e.count!=null&&Object.hasOwnProperty.call(e,`count`)&&t.uint32(33).fixed64(e.count),e.sum!=null&&Object.hasOwnProperty.call(e,`sum`)&&t.uint32(41).double(e.sum),e.bucketCounts!=null&&e.bucketCounts.length){t.uint32(50).fork();for(var n=0;n<e.bucketCounts.length;++n)t.fixed64(e.bucketCounts[n]);t.ldelim()}if(e.explicitBounds!=null&&e.explicitBounds.length){t.uint32(58).fork();for(var n=0;n<e.explicitBounds.length;++n)t.double(e.explicitBounds[n]);t.ldelim()}if(e.exemplars!=null&&e.exemplars.length)for(var n=0;n<e.exemplars.length;++n)o.opentelemetry.proto.metrics.v1.Exemplar.encode(e.exemplars[n],t.uint32(66).fork()).ldelim();if(e.attributes!=null&&e.attributes.length)for(var n=0;n<e.attributes.length;++n)o.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[n],t.uint32(74).fork()).ldelim();return e.flags!=null&&Object.hasOwnProperty.call(e,`flags`)&&t.uint32(80).uint32(e.flags),e.min!=null&&Object.hasOwnProperty.call(e,`min`)&&t.uint32(89).double(e.min),e.max!=null&&Object.hasOwnProperty.call(e,`max`)&&t.uint32(97).double(e.max),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.metrics.v1.HistogramDataPoint;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 9:a.attributes&&a.attributes.length||(a.attributes=[]),a.attributes.push(o.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break;case 2:a.startTimeUnixNano=e.fixed64();break;case 3:a.timeUnixNano=e.fixed64();break;case 4:a.count=e.fixed64();break;case 5:a.sum=e.double();break;case 6:if(a.bucketCounts&&a.bucketCounts.length||(a.bucketCounts=[]),(s&7)==2)for(var c=e.uint32()+e.pos;e.pos<c;)a.bucketCounts.push(e.fixed64());else a.bucketCounts.push(e.fixed64());break;case 7:if(a.explicitBounds&&a.explicitBounds.length||(a.explicitBounds=[]),(s&7)==2)for(var c=e.uint32()+e.pos;e.pos<c;)a.explicitBounds.push(e.double());else a.explicitBounds.push(e.double());break;case 8:a.exemplars&&a.exemplars.length||(a.exemplars=[]),a.exemplars.push(o.opentelemetry.proto.metrics.v1.Exemplar.decode(e,e.uint32()));break;case 10:a.flags=e.uint32();break;case 11:a.min=e.double();break;case 12:a.max=e.double();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.attributes!=null&&e.hasOwnProperty(`attributes`)){if(!Array.isArray(e.attributes))return`attributes: array expected`;for(var t=0;t<e.attributes.length;++t){var n=o.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[t]);if(n)return`attributes.`+n}}if(e.startTimeUnixNano!=null&&e.hasOwnProperty(`startTimeUnixNano`)&&!a.isInteger(e.startTimeUnixNano)&&!(e.startTimeUnixNano&&a.isInteger(e.startTimeUnixNano.low)&&a.isInteger(e.startTimeUnixNano.high)))return`startTimeUnixNano: integer|Long expected`;if(e.timeUnixNano!=null&&e.hasOwnProperty(`timeUnixNano`)&&!a.isInteger(e.timeUnixNano)&&!(e.timeUnixNano&&a.isInteger(e.timeUnixNano.low)&&a.isInteger(e.timeUnixNano.high)))return`timeUnixNano: integer|Long expected`;if(e.count!=null&&e.hasOwnProperty(`count`)&&!a.isInteger(e.count)&&!(e.count&&a.isInteger(e.count.low)&&a.isInteger(e.count.high)))return`count: integer|Long expected`;if(e.sum!=null&&e.hasOwnProperty(`sum`)&&typeof e.sum!=`number`)return`sum: number expected`;if(e.bucketCounts!=null&&e.hasOwnProperty(`bucketCounts`)){if(!Array.isArray(e.bucketCounts))return`bucketCounts: array expected`;for(var t=0;t<e.bucketCounts.length;++t)if(!a.isInteger(e.bucketCounts[t])&&!(e.bucketCounts[t]&&a.isInteger(e.bucketCounts[t].low)&&a.isInteger(e.bucketCounts[t].high)))return`bucketCounts: integer|Long[] expected`}if(e.explicitBounds!=null&&e.hasOwnProperty(`explicitBounds`)){if(!Array.isArray(e.explicitBounds))return`explicitBounds: array expected`;for(var t=0;t<e.explicitBounds.length;++t)if(typeof e.explicitBounds[t]!=`number`)return`explicitBounds: number[] expected`}if(e.exemplars!=null&&e.hasOwnProperty(`exemplars`)){if(!Array.isArray(e.exemplars))return`exemplars: array expected`;for(var t=0;t<e.exemplars.length;++t){var n=o.opentelemetry.proto.metrics.v1.Exemplar.verify(e.exemplars[t]);if(n)return`exemplars.`+n}}return e.flags!=null&&e.hasOwnProperty(`flags`)&&!a.isInteger(e.flags)?`flags: integer expected`:e.min!=null&&e.hasOwnProperty(`min`)&&typeof e.min!=`number`?`min: number expected`:e.max!=null&&e.hasOwnProperty(`max`)&&typeof e.max!=`number`?`max: number expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.metrics.v1.HistogramDataPoint)return e;var t=new o.opentelemetry.proto.metrics.v1.HistogramDataPoint;if(e.attributes){if(!Array.isArray(e.attributes))throw TypeError(`.opentelemetry.proto.metrics.v1.HistogramDataPoint.attributes: array expected`);t.attributes=[];for(var n=0;n<e.attributes.length;++n){if(typeof e.attributes[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.HistogramDataPoint.attributes: object expected`);t.attributes[n]=o.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[n])}}if(e.startTimeUnixNano!=null&&(a.Long?(t.startTimeUnixNano=a.Long.fromValue(e.startTimeUnixNano)).unsigned=!1:typeof e.startTimeUnixNano==`string`?t.startTimeUnixNano=parseInt(e.startTimeUnixNano,10):typeof e.startTimeUnixNano==`number`?t.startTimeUnixNano=e.startTimeUnixNano:typeof e.startTimeUnixNano==`object`&&(t.startTimeUnixNano=new a.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber())),e.timeUnixNano!=null&&(a.Long?(t.timeUnixNano=a.Long.fromValue(e.timeUnixNano)).unsigned=!1:typeof e.timeUnixNano==`string`?t.timeUnixNano=parseInt(e.timeUnixNano,10):typeof e.timeUnixNano==`number`?t.timeUnixNano=e.timeUnixNano:typeof e.timeUnixNano==`object`&&(t.timeUnixNano=new a.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber())),e.count!=null&&(a.Long?(t.count=a.Long.fromValue(e.count)).unsigned=!1:typeof e.count==`string`?t.count=parseInt(e.count,10):typeof e.count==`number`?t.count=e.count:typeof e.count==`object`&&(t.count=new a.LongBits(e.count.low>>>0,e.count.high>>>0).toNumber())),e.sum!=null&&(t.sum=Number(e.sum)),e.bucketCounts){if(!Array.isArray(e.bucketCounts))throw TypeError(`.opentelemetry.proto.metrics.v1.HistogramDataPoint.bucketCounts: array expected`);t.bucketCounts=[];for(var n=0;n<e.bucketCounts.length;++n)a.Long?(t.bucketCounts[n]=a.Long.fromValue(e.bucketCounts[n])).unsigned=!1:typeof e.bucketCounts[n]==`string`?t.bucketCounts[n]=parseInt(e.bucketCounts[n],10):typeof e.bucketCounts[n]==`number`?t.bucketCounts[n]=e.bucketCounts[n]:typeof e.bucketCounts[n]==`object`&&(t.bucketCounts[n]=new a.LongBits(e.bucketCounts[n].low>>>0,e.bucketCounts[n].high>>>0).toNumber())}if(e.explicitBounds){if(!Array.isArray(e.explicitBounds))throw TypeError(`.opentelemetry.proto.metrics.v1.HistogramDataPoint.explicitBounds: array expected`);t.explicitBounds=[];for(var n=0;n<e.explicitBounds.length;++n)t.explicitBounds[n]=Number(e.explicitBounds[n])}if(e.exemplars){if(!Array.isArray(e.exemplars))throw TypeError(`.opentelemetry.proto.metrics.v1.HistogramDataPoint.exemplars: array expected`);t.exemplars=[];for(var n=0;n<e.exemplars.length;++n){if(typeof e.exemplars[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.HistogramDataPoint.exemplars: object expected`);t.exemplars[n]=o.opentelemetry.proto.metrics.v1.Exemplar.fromObject(e.exemplars[n])}}return e.flags!=null&&(t.flags=e.flags>>>0),e.min!=null&&(t.min=Number(e.min)),e.max!=null&&(t.max=Number(e.max)),t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.bucketCounts=[],n.explicitBounds=[],n.exemplars=[],n.attributes=[]),t.defaults){if(a.Long){var r=new a.Long(0,0,!1);n.startTimeUnixNano=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.startTimeUnixNano=t.longs===String?`0`:0;if(a.Long){var r=new a.Long(0,0,!1);n.timeUnixNano=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.timeUnixNano=t.longs===String?`0`:0;if(a.Long){var r=new a.Long(0,0,!1);n.count=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.count=t.longs===String?`0`:0;n.flags=0}if(e.startTimeUnixNano!=null&&e.hasOwnProperty(`startTimeUnixNano`)&&(n.startTimeUnixNano=typeof e.startTimeUnixNano==`number`?t.longs===String?String(e.startTimeUnixNano):e.startTimeUnixNano:t.longs===String?a.Long.prototype.toString.call(e.startTimeUnixNano):t.longs===Number?new a.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber():e.startTimeUnixNano),e.timeUnixNano!=null&&e.hasOwnProperty(`timeUnixNano`)&&(n.timeUnixNano=typeof e.timeUnixNano==`number`?t.longs===String?String(e.timeUnixNano):e.timeUnixNano:t.longs===String?a.Long.prototype.toString.call(e.timeUnixNano):t.longs===Number?new a.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber():e.timeUnixNano),e.count!=null&&e.hasOwnProperty(`count`)&&(n.count=typeof e.count==`number`?t.longs===String?String(e.count):e.count:t.longs===String?a.Long.prototype.toString.call(e.count):t.longs===Number?new a.LongBits(e.count.low>>>0,e.count.high>>>0).toNumber():e.count),e.sum!=null&&e.hasOwnProperty(`sum`)&&(n.sum=t.json&&!isFinite(e.sum)?String(e.sum):e.sum,t.oneofs&&(n._sum=`sum`)),e.bucketCounts&&e.bucketCounts.length){n.bucketCounts=[];for(var i=0;i<e.bucketCounts.length;++i)typeof e.bucketCounts[i]==`number`?n.bucketCounts[i]=t.longs===String?String(e.bucketCounts[i]):e.bucketCounts[i]:n.bucketCounts[i]=t.longs===String?a.Long.prototype.toString.call(e.bucketCounts[i]):t.longs===Number?new a.LongBits(e.bucketCounts[i].low>>>0,e.bucketCounts[i].high>>>0).toNumber():e.bucketCounts[i]}if(e.explicitBounds&&e.explicitBounds.length){n.explicitBounds=[];for(var i=0;i<e.explicitBounds.length;++i)n.explicitBounds[i]=t.json&&!isFinite(e.explicitBounds[i])?String(e.explicitBounds[i]):e.explicitBounds[i]}if(e.exemplars&&e.exemplars.length){n.exemplars=[];for(var i=0;i<e.exemplars.length;++i)n.exemplars[i]=o.opentelemetry.proto.metrics.v1.Exemplar.toObject(e.exemplars[i],t)}if(e.attributes&&e.attributes.length){n.attributes=[];for(var i=0;i<e.attributes.length;++i)n.attributes[i]=o.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[i],t)}return e.flags!=null&&e.hasOwnProperty(`flags`)&&(n.flags=e.flags),e.min!=null&&e.hasOwnProperty(`min`)&&(n.min=t.json&&!isFinite(e.min)?String(e.min):e.min,t.oneofs&&(n._min=`min`)),e.max!=null&&e.hasOwnProperty(`max`)&&(n.max=t.json&&!isFinite(e.max)?String(e.max):e.max,t.oneofs&&(n._max=`max`)),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.metrics.v1.HistogramDataPoint`},e})(),e.ExponentialHistogramDataPoint=(function(){function e(e){if(this.attributes=[],this.exemplars=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}e.prototype.attributes=a.emptyArray,e.prototype.startTimeUnixNano=null,e.prototype.timeUnixNano=null,e.prototype.count=null,e.prototype.sum=null,e.prototype.scale=null,e.prototype.zeroCount=null,e.prototype.positive=null,e.prototype.negative=null,e.prototype.flags=null,e.prototype.exemplars=a.emptyArray,e.prototype.min=null,e.prototype.max=null,e.prototype.zeroThreshold=null;var t;return Object.defineProperty(e.prototype,"_sum",{get:a.oneOfGetter(t=[`sum`]),set:a.oneOfSetter(t)}),Object.defineProperty(e.prototype,"_min",{get:a.oneOfGetter(t=[`min`]),set:a.oneOfSetter(t)}),Object.defineProperty(e.prototype,"_max",{get:a.oneOfGetter(t=[`max`]),set:a.oneOfSetter(t)}),e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.attributes!=null&&e.attributes.length)for(var n=0;n<e.attributes.length;++n)o.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[n],t.uint32(10).fork()).ldelim();if(e.startTimeUnixNano!=null&&Object.hasOwnProperty.call(e,`startTimeUnixNano`)&&t.uint32(17).fixed64(e.startTimeUnixNano),e.timeUnixNano!=null&&Object.hasOwnProperty.call(e,`timeUnixNano`)&&t.uint32(25).fixed64(e.timeUnixNano),e.count!=null&&Object.hasOwnProperty.call(e,`count`)&&t.uint32(33).fixed64(e.count),e.sum!=null&&Object.hasOwnProperty.call(e,`sum`)&&t.uint32(41).double(e.sum),e.scale!=null&&Object.hasOwnProperty.call(e,`scale`)&&t.uint32(48).sint32(e.scale),e.zeroCount!=null&&Object.hasOwnProperty.call(e,`zeroCount`)&&t.uint32(57).fixed64(e.zeroCount),e.positive!=null&&Object.hasOwnProperty.call(e,`positive`)&&o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.encode(e.positive,t.uint32(66).fork()).ldelim(),e.negative!=null&&Object.hasOwnProperty.call(e,`negative`)&&o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.encode(e.negative,t.uint32(74).fork()).ldelim(),e.flags!=null&&Object.hasOwnProperty.call(e,`flags`)&&t.uint32(80).uint32(e.flags),e.exemplars!=null&&e.exemplars.length)for(var n=0;n<e.exemplars.length;++n)o.opentelemetry.proto.metrics.v1.Exemplar.encode(e.exemplars[n],t.uint32(90).fork()).ldelim();return e.min!=null&&Object.hasOwnProperty.call(e,`min`)&&t.uint32(97).double(e.min),e.max!=null&&Object.hasOwnProperty.call(e,`max`)&&t.uint32(105).double(e.max),e.zeroThreshold!=null&&Object.hasOwnProperty.call(e,`zeroThreshold`)&&t.uint32(113).double(e.zeroThreshold),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.attributes&&a.attributes.length||(a.attributes=[]),a.attributes.push(o.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break;case 2:a.startTimeUnixNano=e.fixed64();break;case 3:a.timeUnixNano=e.fixed64();break;case 4:a.count=e.fixed64();break;case 5:a.sum=e.double();break;case 6:a.scale=e.sint32();break;case 7:a.zeroCount=e.fixed64();break;case 8:a.positive=o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.decode(e,e.uint32());break;case 9:a.negative=o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.decode(e,e.uint32());break;case 10:a.flags=e.uint32();break;case 11:a.exemplars&&a.exemplars.length||(a.exemplars=[]),a.exemplars.push(o.opentelemetry.proto.metrics.v1.Exemplar.decode(e,e.uint32()));break;case 12:a.min=e.double();break;case 13:a.max=e.double();break;case 14:a.zeroThreshold=e.double();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.attributes!=null&&e.hasOwnProperty(`attributes`)){if(!Array.isArray(e.attributes))return`attributes: array expected`;for(var t=0;t<e.attributes.length;++t){var n=o.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[t]);if(n)return`attributes.`+n}}if(e.startTimeUnixNano!=null&&e.hasOwnProperty(`startTimeUnixNano`)&&!a.isInteger(e.startTimeUnixNano)&&!(e.startTimeUnixNano&&a.isInteger(e.startTimeUnixNano.low)&&a.isInteger(e.startTimeUnixNano.high)))return`startTimeUnixNano: integer|Long expected`;if(e.timeUnixNano!=null&&e.hasOwnProperty(`timeUnixNano`)&&!a.isInteger(e.timeUnixNano)&&!(e.timeUnixNano&&a.isInteger(e.timeUnixNano.low)&&a.isInteger(e.timeUnixNano.high)))return`timeUnixNano: integer|Long expected`;if(e.count!=null&&e.hasOwnProperty(`count`)&&!a.isInteger(e.count)&&!(e.count&&a.isInteger(e.count.low)&&a.isInteger(e.count.high)))return`count: integer|Long expected`;if(e.sum!=null&&e.hasOwnProperty(`sum`)&&typeof e.sum!=`number`)return`sum: number expected`;if(e.scale!=null&&e.hasOwnProperty(`scale`)&&!a.isInteger(e.scale))return`scale: integer expected`;if(e.zeroCount!=null&&e.hasOwnProperty(`zeroCount`)&&!a.isInteger(e.zeroCount)&&!(e.zeroCount&&a.isInteger(e.zeroCount.low)&&a.isInteger(e.zeroCount.high)))return`zeroCount: integer|Long expected`;if(e.positive!=null&&e.hasOwnProperty(`positive`)){var n=o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.verify(e.positive);if(n)return`positive.`+n}if(e.negative!=null&&e.hasOwnProperty(`negative`)){var n=o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.verify(e.negative);if(n)return`negative.`+n}if(e.flags!=null&&e.hasOwnProperty(`flags`)&&!a.isInteger(e.flags))return`flags: integer expected`;if(e.exemplars!=null&&e.hasOwnProperty(`exemplars`)){if(!Array.isArray(e.exemplars))return`exemplars: array expected`;for(var t=0;t<e.exemplars.length;++t){var n=o.opentelemetry.proto.metrics.v1.Exemplar.verify(e.exemplars[t]);if(n)return`exemplars.`+n}}return e.min!=null&&e.hasOwnProperty(`min`)&&typeof e.min!=`number`?`min: number expected`:e.max!=null&&e.hasOwnProperty(`max`)&&typeof e.max!=`number`?`max: number expected`:e.zeroThreshold!=null&&e.hasOwnProperty(`zeroThreshold`)&&typeof e.zeroThreshold!=`number`?`zeroThreshold: number expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint)return e;var t=new o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint;if(e.attributes){if(!Array.isArray(e.attributes))throw TypeError(`.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.attributes: array expected`);t.attributes=[];for(var n=0;n<e.attributes.length;++n){if(typeof e.attributes[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.attributes: object expected`);t.attributes[n]=o.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[n])}}if(e.startTimeUnixNano!=null&&(a.Long?(t.startTimeUnixNano=a.Long.fromValue(e.startTimeUnixNano)).unsigned=!1:typeof e.startTimeUnixNano==`string`?t.startTimeUnixNano=parseInt(e.startTimeUnixNano,10):typeof e.startTimeUnixNano==`number`?t.startTimeUnixNano=e.startTimeUnixNano:typeof e.startTimeUnixNano==`object`&&(t.startTimeUnixNano=new a.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber())),e.timeUnixNano!=null&&(a.Long?(t.timeUnixNano=a.Long.fromValue(e.timeUnixNano)).unsigned=!1:typeof e.timeUnixNano==`string`?t.timeUnixNano=parseInt(e.timeUnixNano,10):typeof e.timeUnixNano==`number`?t.timeUnixNano=e.timeUnixNano:typeof e.timeUnixNano==`object`&&(t.timeUnixNano=new a.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber())),e.count!=null&&(a.Long?(t.count=a.Long.fromValue(e.count)).unsigned=!1:typeof e.count==`string`?t.count=parseInt(e.count,10):typeof e.count==`number`?t.count=e.count:typeof e.count==`object`&&(t.count=new a.LongBits(e.count.low>>>0,e.count.high>>>0).toNumber())),e.sum!=null&&(t.sum=Number(e.sum)),e.scale!=null&&(t.scale=e.scale|0),e.zeroCount!=null&&(a.Long?(t.zeroCount=a.Long.fromValue(e.zeroCount)).unsigned=!1:typeof e.zeroCount==`string`?t.zeroCount=parseInt(e.zeroCount,10):typeof e.zeroCount==`number`?t.zeroCount=e.zeroCount:typeof e.zeroCount==`object`&&(t.zeroCount=new a.LongBits(e.zeroCount.low>>>0,e.zeroCount.high>>>0).toNumber())),e.positive!=null){if(typeof e.positive!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.positive: object expected`);t.positive=o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.fromObject(e.positive)}if(e.negative!=null){if(typeof e.negative!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.negative: object expected`);t.negative=o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.fromObject(e.negative)}if(e.flags!=null&&(t.flags=e.flags>>>0),e.exemplars){if(!Array.isArray(e.exemplars))throw TypeError(`.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.exemplars: array expected`);t.exemplars=[];for(var n=0;n<e.exemplars.length;++n){if(typeof e.exemplars[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.exemplars: object expected`);t.exemplars[n]=o.opentelemetry.proto.metrics.v1.Exemplar.fromObject(e.exemplars[n])}}return e.min!=null&&(t.min=Number(e.min)),e.max!=null&&(t.max=Number(e.max)),e.zeroThreshold!=null&&(t.zeroThreshold=Number(e.zeroThreshold)),t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.attributes=[],n.exemplars=[]),t.defaults){if(a.Long){var r=new a.Long(0,0,!1);n.startTimeUnixNano=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.startTimeUnixNano=t.longs===String?`0`:0;if(a.Long){var r=new a.Long(0,0,!1);n.timeUnixNano=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.timeUnixNano=t.longs===String?`0`:0;if(a.Long){var r=new a.Long(0,0,!1);n.count=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.count=t.longs===String?`0`:0;if(n.scale=0,a.Long){var r=new a.Long(0,0,!1);n.zeroCount=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.zeroCount=t.longs===String?`0`:0;n.positive=null,n.negative=null,n.flags=0,n.zeroThreshold=0}if(e.attributes&&e.attributes.length){n.attributes=[];for(var i=0;i<e.attributes.length;++i)n.attributes[i]=o.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[i],t)}if(e.startTimeUnixNano!=null&&e.hasOwnProperty(`startTimeUnixNano`)&&(n.startTimeUnixNano=typeof e.startTimeUnixNano==`number`?t.longs===String?String(e.startTimeUnixNano):e.startTimeUnixNano:t.longs===String?a.Long.prototype.toString.call(e.startTimeUnixNano):t.longs===Number?new a.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber():e.startTimeUnixNano),e.timeUnixNano!=null&&e.hasOwnProperty(`timeUnixNano`)&&(n.timeUnixNano=typeof e.timeUnixNano==`number`?t.longs===String?String(e.timeUnixNano):e.timeUnixNano:t.longs===String?a.Long.prototype.toString.call(e.timeUnixNano):t.longs===Number?new a.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber():e.timeUnixNano),e.count!=null&&e.hasOwnProperty(`count`)&&(n.count=typeof e.count==`number`?t.longs===String?String(e.count):e.count:t.longs===String?a.Long.prototype.toString.call(e.count):t.longs===Number?new a.LongBits(e.count.low>>>0,e.count.high>>>0).toNumber():e.count),e.sum!=null&&e.hasOwnProperty(`sum`)&&(n.sum=t.json&&!isFinite(e.sum)?String(e.sum):e.sum,t.oneofs&&(n._sum=`sum`)),e.scale!=null&&e.hasOwnProperty(`scale`)&&(n.scale=e.scale),e.zeroCount!=null&&e.hasOwnProperty(`zeroCount`)&&(n.zeroCount=typeof e.zeroCount==`number`?t.longs===String?String(e.zeroCount):e.zeroCount:t.longs===String?a.Long.prototype.toString.call(e.zeroCount):t.longs===Number?new a.LongBits(e.zeroCount.low>>>0,e.zeroCount.high>>>0).toNumber():e.zeroCount),e.positive!=null&&e.hasOwnProperty(`positive`)&&(n.positive=o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.toObject(e.positive,t)),e.negative!=null&&e.hasOwnProperty(`negative`)&&(n.negative=o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.toObject(e.negative,t)),e.flags!=null&&e.hasOwnProperty(`flags`)&&(n.flags=e.flags),e.exemplars&&e.exemplars.length){n.exemplars=[];for(var i=0;i<e.exemplars.length;++i)n.exemplars[i]=o.opentelemetry.proto.metrics.v1.Exemplar.toObject(e.exemplars[i],t)}return e.min!=null&&e.hasOwnProperty(`min`)&&(n.min=t.json&&!isFinite(e.min)?String(e.min):e.min,t.oneofs&&(n._min=`min`)),e.max!=null&&e.hasOwnProperty(`max`)&&(n.max=t.json&&!isFinite(e.max)?String(e.max):e.max,t.oneofs&&(n._max=`max`)),e.zeroThreshold!=null&&e.hasOwnProperty(`zeroThreshold`)&&(n.zeroThreshold=t.json&&!isFinite(e.zeroThreshold)?String(e.zeroThreshold):e.zeroThreshold),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint`},e.Buckets=(function(){function e(e){if(this.bucketCounts=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.offset=null,e.prototype.bucketCounts=a.emptyArray,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.offset!=null&&Object.hasOwnProperty.call(e,`offset`)&&t.uint32(8).sint32(e.offset),e.bucketCounts!=null&&e.bucketCounts.length){t.uint32(18).fork();for(var n=0;n<e.bucketCounts.length;++n)t.uint64(e.bucketCounts[n]);t.ldelim()}return t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.offset=e.sint32();break;case 2:if(a.bucketCounts&&a.bucketCounts.length||(a.bucketCounts=[]),(s&7)==2)for(var c=e.uint32()+e.pos;e.pos<c;)a.bucketCounts.push(e.uint64());else a.bucketCounts.push(e.uint64());break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.offset!=null&&e.hasOwnProperty(`offset`)&&!a.isInteger(e.offset))return`offset: integer expected`;if(e.bucketCounts!=null&&e.hasOwnProperty(`bucketCounts`)){if(!Array.isArray(e.bucketCounts))return`bucketCounts: array expected`;for(var t=0;t<e.bucketCounts.length;++t)if(!a.isInteger(e.bucketCounts[t])&&!(e.bucketCounts[t]&&a.isInteger(e.bucketCounts[t].low)&&a.isInteger(e.bucketCounts[t].high)))return`bucketCounts: integer|Long[] expected`}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets)return e;var t=new o.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets;if(e.offset!=null&&(t.offset=e.offset|0),e.bucketCounts){if(!Array.isArray(e.bucketCounts))throw TypeError(`.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.bucketCounts: array expected`);t.bucketCounts=[];for(var n=0;n<e.bucketCounts.length;++n)a.Long?(t.bucketCounts[n]=a.Long.fromValue(e.bucketCounts[n])).unsigned=!0:typeof e.bucketCounts[n]==`string`?t.bucketCounts[n]=parseInt(e.bucketCounts[n],10):typeof e.bucketCounts[n]==`number`?t.bucketCounts[n]=e.bucketCounts[n]:typeof e.bucketCounts[n]==`object`&&(t.bucketCounts[n]=new a.LongBits(e.bucketCounts[n].low>>>0,e.bucketCounts[n].high>>>0).toNumber(!0))}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.bucketCounts=[]),t.defaults&&(n.offset=0),e.offset!=null&&e.hasOwnProperty(`offset`)&&(n.offset=e.offset),e.bucketCounts&&e.bucketCounts.length){n.bucketCounts=[];for(var r=0;r<e.bucketCounts.length;++r)typeof e.bucketCounts[r]==`number`?n.bucketCounts[r]=t.longs===String?String(e.bucketCounts[r]):e.bucketCounts[r]:n.bucketCounts[r]=t.longs===String?a.Long.prototype.toString.call(e.bucketCounts[r]):t.longs===Number?new a.LongBits(e.bucketCounts[r].low>>>0,e.bucketCounts[r].high>>>0).toNumber(!0):e.bucketCounts[r]}return n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets`},e})(),e})(),e.SummaryDataPoint=(function(){function e(e){if(this.attributes=[],this.quantileValues=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.attributes=a.emptyArray,e.prototype.startTimeUnixNano=null,e.prototype.timeUnixNano=null,e.prototype.count=null,e.prototype.sum=null,e.prototype.quantileValues=a.emptyArray,e.prototype.flags=null,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.startTimeUnixNano!=null&&Object.hasOwnProperty.call(e,`startTimeUnixNano`)&&t.uint32(17).fixed64(e.startTimeUnixNano),e.timeUnixNano!=null&&Object.hasOwnProperty.call(e,`timeUnixNano`)&&t.uint32(25).fixed64(e.timeUnixNano),e.count!=null&&Object.hasOwnProperty.call(e,`count`)&&t.uint32(33).fixed64(e.count),e.sum!=null&&Object.hasOwnProperty.call(e,`sum`)&&t.uint32(41).double(e.sum),e.quantileValues!=null&&e.quantileValues.length)for(var n=0;n<e.quantileValues.length;++n)o.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile.encode(e.quantileValues[n],t.uint32(50).fork()).ldelim();if(e.attributes!=null&&e.attributes.length)for(var n=0;n<e.attributes.length;++n)o.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[n],t.uint32(58).fork()).ldelim();return e.flags!=null&&Object.hasOwnProperty.call(e,`flags`)&&t.uint32(64).uint32(e.flags),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.metrics.v1.SummaryDataPoint;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 7:a.attributes&&a.attributes.length||(a.attributes=[]),a.attributes.push(o.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break;case 2:a.startTimeUnixNano=e.fixed64();break;case 3:a.timeUnixNano=e.fixed64();break;case 4:a.count=e.fixed64();break;case 5:a.sum=e.double();break;case 6:a.quantileValues&&a.quantileValues.length||(a.quantileValues=[]),a.quantileValues.push(o.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile.decode(e,e.uint32()));break;case 8:a.flags=e.uint32();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.attributes!=null&&e.hasOwnProperty(`attributes`)){if(!Array.isArray(e.attributes))return`attributes: array expected`;for(var t=0;t<e.attributes.length;++t){var n=o.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[t]);if(n)return`attributes.`+n}}if(e.startTimeUnixNano!=null&&e.hasOwnProperty(`startTimeUnixNano`)&&!a.isInteger(e.startTimeUnixNano)&&!(e.startTimeUnixNano&&a.isInteger(e.startTimeUnixNano.low)&&a.isInteger(e.startTimeUnixNano.high)))return`startTimeUnixNano: integer|Long expected`;if(e.timeUnixNano!=null&&e.hasOwnProperty(`timeUnixNano`)&&!a.isInteger(e.timeUnixNano)&&!(e.timeUnixNano&&a.isInteger(e.timeUnixNano.low)&&a.isInteger(e.timeUnixNano.high)))return`timeUnixNano: integer|Long expected`;if(e.count!=null&&e.hasOwnProperty(`count`)&&!a.isInteger(e.count)&&!(e.count&&a.isInteger(e.count.low)&&a.isInteger(e.count.high)))return`count: integer|Long expected`;if(e.sum!=null&&e.hasOwnProperty(`sum`)&&typeof e.sum!=`number`)return`sum: number expected`;if(e.quantileValues!=null&&e.hasOwnProperty(`quantileValues`)){if(!Array.isArray(e.quantileValues))return`quantileValues: array expected`;for(var t=0;t<e.quantileValues.length;++t){var n=o.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile.verify(e.quantileValues[t]);if(n)return`quantileValues.`+n}}return e.flags!=null&&e.hasOwnProperty(`flags`)&&!a.isInteger(e.flags)?`flags: integer expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.metrics.v1.SummaryDataPoint)return e;var t=new o.opentelemetry.proto.metrics.v1.SummaryDataPoint;if(e.attributes){if(!Array.isArray(e.attributes))throw TypeError(`.opentelemetry.proto.metrics.v1.SummaryDataPoint.attributes: array expected`);t.attributes=[];for(var n=0;n<e.attributes.length;++n){if(typeof e.attributes[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.SummaryDataPoint.attributes: object expected`);t.attributes[n]=o.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[n])}}if(e.startTimeUnixNano!=null&&(a.Long?(t.startTimeUnixNano=a.Long.fromValue(e.startTimeUnixNano)).unsigned=!1:typeof e.startTimeUnixNano==`string`?t.startTimeUnixNano=parseInt(e.startTimeUnixNano,10):typeof e.startTimeUnixNano==`number`?t.startTimeUnixNano=e.startTimeUnixNano:typeof e.startTimeUnixNano==`object`&&(t.startTimeUnixNano=new a.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber())),e.timeUnixNano!=null&&(a.Long?(t.timeUnixNano=a.Long.fromValue(e.timeUnixNano)).unsigned=!1:typeof e.timeUnixNano==`string`?t.timeUnixNano=parseInt(e.timeUnixNano,10):typeof e.timeUnixNano==`number`?t.timeUnixNano=e.timeUnixNano:typeof e.timeUnixNano==`object`&&(t.timeUnixNano=new a.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber())),e.count!=null&&(a.Long?(t.count=a.Long.fromValue(e.count)).unsigned=!1:typeof e.count==`string`?t.count=parseInt(e.count,10):typeof e.count==`number`?t.count=e.count:typeof e.count==`object`&&(t.count=new a.LongBits(e.count.low>>>0,e.count.high>>>0).toNumber())),e.sum!=null&&(t.sum=Number(e.sum)),e.quantileValues){if(!Array.isArray(e.quantileValues))throw TypeError(`.opentelemetry.proto.metrics.v1.SummaryDataPoint.quantileValues: array expected`);t.quantileValues=[];for(var n=0;n<e.quantileValues.length;++n){if(typeof e.quantileValues[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.SummaryDataPoint.quantileValues: object expected`);t.quantileValues[n]=o.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile.fromObject(e.quantileValues[n])}}return e.flags!=null&&(t.flags=e.flags>>>0),t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.quantileValues=[],n.attributes=[]),t.defaults){if(a.Long){var r=new a.Long(0,0,!1);n.startTimeUnixNano=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.startTimeUnixNano=t.longs===String?`0`:0;if(a.Long){var r=new a.Long(0,0,!1);n.timeUnixNano=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.timeUnixNano=t.longs===String?`0`:0;if(a.Long){var r=new a.Long(0,0,!1);n.count=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.count=t.longs===String?`0`:0;n.sum=0,n.flags=0}if(e.startTimeUnixNano!=null&&e.hasOwnProperty(`startTimeUnixNano`)&&(n.startTimeUnixNano=typeof e.startTimeUnixNano==`number`?t.longs===String?String(e.startTimeUnixNano):e.startTimeUnixNano:t.longs===String?a.Long.prototype.toString.call(e.startTimeUnixNano):t.longs===Number?new a.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber():e.startTimeUnixNano),e.timeUnixNano!=null&&e.hasOwnProperty(`timeUnixNano`)&&(n.timeUnixNano=typeof e.timeUnixNano==`number`?t.longs===String?String(e.timeUnixNano):e.timeUnixNano:t.longs===String?a.Long.prototype.toString.call(e.timeUnixNano):t.longs===Number?new a.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber():e.timeUnixNano),e.count!=null&&e.hasOwnProperty(`count`)&&(n.count=typeof e.count==`number`?t.longs===String?String(e.count):e.count:t.longs===String?a.Long.prototype.toString.call(e.count):t.longs===Number?new a.LongBits(e.count.low>>>0,e.count.high>>>0).toNumber():e.count),e.sum!=null&&e.hasOwnProperty(`sum`)&&(n.sum=t.json&&!isFinite(e.sum)?String(e.sum):e.sum),e.quantileValues&&e.quantileValues.length){n.quantileValues=[];for(var i=0;i<e.quantileValues.length;++i)n.quantileValues[i]=o.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile.toObject(e.quantileValues[i],t)}if(e.attributes&&e.attributes.length){n.attributes=[];for(var i=0;i<e.attributes.length;++i)n.attributes[i]=o.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[i],t)}return e.flags!=null&&e.hasOwnProperty(`flags`)&&(n.flags=e.flags),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.metrics.v1.SummaryDataPoint`},e.ValueAtQuantile=(function(){function e(e){if(e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.quantile=null,e.prototype.value=null,e.create=function(t){return new e(t)},e.encode=function(e,t){return t||=i.create(),e.quantile!=null&&Object.hasOwnProperty.call(e,`quantile`)&&t.uint32(9).double(e.quantile),e.value!=null&&Object.hasOwnProperty.call(e,`value`)&&t.uint32(17).double(e.value),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.quantile=e.double();break;case 2:a.value=e.double();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){return typeof e!=`object`||!e?`object expected`:e.quantile!=null&&e.hasOwnProperty(`quantile`)&&typeof e.quantile!=`number`?`quantile: number expected`:e.value!=null&&e.hasOwnProperty(`value`)&&typeof e.value!=`number`?`value: number expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile)return e;var t=new o.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile;return e.quantile!=null&&(t.quantile=Number(e.quantile)),e.value!=null&&(t.value=Number(e.value)),t},e.toObject=function(e,t){t||={};var n={};return t.defaults&&(n.quantile=0,n.value=0),e.quantile!=null&&e.hasOwnProperty(`quantile`)&&(n.quantile=t.json&&!isFinite(e.quantile)?String(e.quantile):e.quantile),e.value!=null&&e.hasOwnProperty(`value`)&&(n.value=t.json&&!isFinite(e.value)?String(e.value):e.value),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile`},e})(),e})(),e.Exemplar=(function(){function e(e){if(this.filteredAttributes=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}e.prototype.filteredAttributes=a.emptyArray,e.prototype.timeUnixNano=null,e.prototype.asDouble=null,e.prototype.asInt=null,e.prototype.spanId=null,e.prototype.traceId=null;var t;return Object.defineProperty(e.prototype,"value",{get:a.oneOfGetter(t=[`asDouble`,`asInt`]),set:a.oneOfSetter(t)}),e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.timeUnixNano!=null&&Object.hasOwnProperty.call(e,`timeUnixNano`)&&t.uint32(17).fixed64(e.timeUnixNano),e.asDouble!=null&&Object.hasOwnProperty.call(e,`asDouble`)&&t.uint32(25).double(e.asDouble),e.spanId!=null&&Object.hasOwnProperty.call(e,`spanId`)&&t.uint32(34).bytes(e.spanId),e.traceId!=null&&Object.hasOwnProperty.call(e,`traceId`)&&t.uint32(42).bytes(e.traceId),e.asInt!=null&&Object.hasOwnProperty.call(e,`asInt`)&&t.uint32(49).sfixed64(e.asInt),e.filteredAttributes!=null&&e.filteredAttributes.length)for(var n=0;n<e.filteredAttributes.length;++n)o.opentelemetry.proto.common.v1.KeyValue.encode(e.filteredAttributes[n],t.uint32(58).fork()).ldelim();return t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.metrics.v1.Exemplar;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 7:a.filteredAttributes&&a.filteredAttributes.length||(a.filteredAttributes=[]),a.filteredAttributes.push(o.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break;case 2:a.timeUnixNano=e.fixed64();break;case 3:a.asDouble=e.double();break;case 6:a.asInt=e.sfixed64();break;case 4:a.spanId=e.bytes();break;case 5:a.traceId=e.bytes();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;var t={};if(e.filteredAttributes!=null&&e.hasOwnProperty(`filteredAttributes`)){if(!Array.isArray(e.filteredAttributes))return`filteredAttributes: array expected`;for(var n=0;n<e.filteredAttributes.length;++n){var r=o.opentelemetry.proto.common.v1.KeyValue.verify(e.filteredAttributes[n]);if(r)return`filteredAttributes.`+r}}if(e.timeUnixNano!=null&&e.hasOwnProperty(`timeUnixNano`)&&!a.isInteger(e.timeUnixNano)&&!(e.timeUnixNano&&a.isInteger(e.timeUnixNano.low)&&a.isInteger(e.timeUnixNano.high)))return`timeUnixNano: integer|Long expected`;if(e.asDouble!=null&&e.hasOwnProperty(`asDouble`)&&(t.value=1,typeof e.asDouble!=`number`))return`asDouble: number expected`;if(e.asInt!=null&&e.hasOwnProperty(`asInt`)){if(t.value===1)return`value: multiple values`;if(t.value=1,!a.isInteger(e.asInt)&&!(e.asInt&&a.isInteger(e.asInt.low)&&a.isInteger(e.asInt.high)))return`asInt: integer|Long expected`}return e.spanId!=null&&e.hasOwnProperty(`spanId`)&&!(e.spanId&&typeof e.spanId.length==`number`||a.isString(e.spanId))?`spanId: buffer expected`:e.traceId!=null&&e.hasOwnProperty(`traceId`)&&!(e.traceId&&typeof e.traceId.length==`number`||a.isString(e.traceId))?`traceId: buffer expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.metrics.v1.Exemplar)return e;var t=new o.opentelemetry.proto.metrics.v1.Exemplar;if(e.filteredAttributes){if(!Array.isArray(e.filteredAttributes))throw TypeError(`.opentelemetry.proto.metrics.v1.Exemplar.filteredAttributes: array expected`);t.filteredAttributes=[];for(var n=0;n<e.filteredAttributes.length;++n){if(typeof e.filteredAttributes[n]!=`object`)throw TypeError(`.opentelemetry.proto.metrics.v1.Exemplar.filteredAttributes: object expected`);t.filteredAttributes[n]=o.opentelemetry.proto.common.v1.KeyValue.fromObject(e.filteredAttributes[n])}}return e.timeUnixNano!=null&&(a.Long?(t.timeUnixNano=a.Long.fromValue(e.timeUnixNano)).unsigned=!1:typeof e.timeUnixNano==`string`?t.timeUnixNano=parseInt(e.timeUnixNano,10):typeof e.timeUnixNano==`number`?t.timeUnixNano=e.timeUnixNano:typeof e.timeUnixNano==`object`&&(t.timeUnixNano=new a.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber())),e.asDouble!=null&&(t.asDouble=Number(e.asDouble)),e.asInt!=null&&(a.Long?(t.asInt=a.Long.fromValue(e.asInt)).unsigned=!1:typeof e.asInt==`string`?t.asInt=parseInt(e.asInt,10):typeof e.asInt==`number`?t.asInt=e.asInt:typeof e.asInt==`object`&&(t.asInt=new a.LongBits(e.asInt.low>>>0,e.asInt.high>>>0).toNumber())),e.spanId!=null&&(typeof e.spanId==`string`?a.base64.decode(e.spanId,t.spanId=a.newBuffer(a.base64.length(e.spanId)),0):e.spanId.length>=0&&(t.spanId=e.spanId)),e.traceId!=null&&(typeof e.traceId==`string`?a.base64.decode(e.traceId,t.traceId=a.newBuffer(a.base64.length(e.traceId)),0):e.traceId.length>=0&&(t.traceId=e.traceId)),t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.filteredAttributes=[]),t.defaults){if(a.Long){var r=new a.Long(0,0,!1);n.timeUnixNano=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.timeUnixNano=t.longs===String?`0`:0;t.bytes===String?n.spanId=``:(n.spanId=[],t.bytes!==Array&&(n.spanId=a.newBuffer(n.spanId))),t.bytes===String?n.traceId=``:(n.traceId=[],t.bytes!==Array&&(n.traceId=a.newBuffer(n.traceId)))}if(e.timeUnixNano!=null&&e.hasOwnProperty(`timeUnixNano`)&&(n.timeUnixNano=typeof e.timeUnixNano==`number`?t.longs===String?String(e.timeUnixNano):e.timeUnixNano:t.longs===String?a.Long.prototype.toString.call(e.timeUnixNano):t.longs===Number?new a.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber():e.timeUnixNano),e.asDouble!=null&&e.hasOwnProperty(`asDouble`)&&(n.asDouble=t.json&&!isFinite(e.asDouble)?String(e.asDouble):e.asDouble,t.oneofs&&(n.value=`asDouble`)),e.spanId!=null&&e.hasOwnProperty(`spanId`)&&(n.spanId=t.bytes===String?a.base64.encode(e.spanId,0,e.spanId.length):t.bytes===Array?Array.prototype.slice.call(e.spanId):e.spanId),e.traceId!=null&&e.hasOwnProperty(`traceId`)&&(n.traceId=t.bytes===String?a.base64.encode(e.traceId,0,e.traceId.length):t.bytes===Array?Array.prototype.slice.call(e.traceId):e.traceId),e.asInt!=null&&e.hasOwnProperty(`asInt`)&&(n.asInt=typeof e.asInt==`number`?t.longs===String?String(e.asInt):e.asInt:t.longs===String?a.Long.prototype.toString.call(e.asInt):t.longs===Number?new a.LongBits(e.asInt.low>>>0,e.asInt.high>>>0).toNumber():e.asInt,t.oneofs&&(n.value=`asInt`)),e.filteredAttributes&&e.filteredAttributes.length){n.filteredAttributes=[];for(var i=0;i<e.filteredAttributes.length;++i)n.filteredAttributes[i]=o.opentelemetry.proto.common.v1.KeyValue.toObject(e.filteredAttributes[i],t)}return n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.metrics.v1.Exemplar`},e})(),e})(),e})(),e.logs=(function(){var e={};return e.v1=(function(){var e={};return e.LogsData=(function(){function e(e){if(this.resourceLogs=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.resourceLogs=a.emptyArray,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.resourceLogs!=null&&e.resourceLogs.length)for(var n=0;n<e.resourceLogs.length;++n)o.opentelemetry.proto.logs.v1.ResourceLogs.encode(e.resourceLogs[n],t.uint32(10).fork()).ldelim();return t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.logs.v1.LogsData;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.resourceLogs&&a.resourceLogs.length||(a.resourceLogs=[]),a.resourceLogs.push(o.opentelemetry.proto.logs.v1.ResourceLogs.decode(e,e.uint32()));break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.resourceLogs!=null&&e.hasOwnProperty(`resourceLogs`)){if(!Array.isArray(e.resourceLogs))return`resourceLogs: array expected`;for(var t=0;t<e.resourceLogs.length;++t){var n=o.opentelemetry.proto.logs.v1.ResourceLogs.verify(e.resourceLogs[t]);if(n)return`resourceLogs.`+n}}return null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.logs.v1.LogsData)return e;var t=new o.opentelemetry.proto.logs.v1.LogsData;if(e.resourceLogs){if(!Array.isArray(e.resourceLogs))throw TypeError(`.opentelemetry.proto.logs.v1.LogsData.resourceLogs: array expected`);t.resourceLogs=[];for(var n=0;n<e.resourceLogs.length;++n){if(typeof e.resourceLogs[n]!=`object`)throw TypeError(`.opentelemetry.proto.logs.v1.LogsData.resourceLogs: object expected`);t.resourceLogs[n]=o.opentelemetry.proto.logs.v1.ResourceLogs.fromObject(e.resourceLogs[n])}}return t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.resourceLogs=[]),e.resourceLogs&&e.resourceLogs.length){n.resourceLogs=[];for(var r=0;r<e.resourceLogs.length;++r)n.resourceLogs[r]=o.opentelemetry.proto.logs.v1.ResourceLogs.toObject(e.resourceLogs[r],t)}return n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.logs.v1.LogsData`},e})(),e.ResourceLogs=(function(){function e(e){if(this.scopeLogs=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.resource=null,e.prototype.scopeLogs=a.emptyArray,e.prototype.schemaUrl=null,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.resource!=null&&Object.hasOwnProperty.call(e,`resource`)&&o.opentelemetry.proto.resource.v1.Resource.encode(e.resource,t.uint32(10).fork()).ldelim(),e.scopeLogs!=null&&e.scopeLogs.length)for(var n=0;n<e.scopeLogs.length;++n)o.opentelemetry.proto.logs.v1.ScopeLogs.encode(e.scopeLogs[n],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,`schemaUrl`)&&t.uint32(26).string(e.schemaUrl),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.logs.v1.ResourceLogs;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.resource=o.opentelemetry.proto.resource.v1.Resource.decode(e,e.uint32());break;case 2:a.scopeLogs&&a.scopeLogs.length||(a.scopeLogs=[]),a.scopeLogs.push(o.opentelemetry.proto.logs.v1.ScopeLogs.decode(e,e.uint32()));break;case 3:a.schemaUrl=e.string();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.resource!=null&&e.hasOwnProperty(`resource`)){var t=o.opentelemetry.proto.resource.v1.Resource.verify(e.resource);if(t)return`resource.`+t}if(e.scopeLogs!=null&&e.hasOwnProperty(`scopeLogs`)){if(!Array.isArray(e.scopeLogs))return`scopeLogs: array expected`;for(var n=0;n<e.scopeLogs.length;++n){var t=o.opentelemetry.proto.logs.v1.ScopeLogs.verify(e.scopeLogs[n]);if(t)return`scopeLogs.`+t}}return e.schemaUrl!=null&&e.hasOwnProperty(`schemaUrl`)&&!a.isString(e.schemaUrl)?`schemaUrl: string expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.logs.v1.ResourceLogs)return e;var t=new o.opentelemetry.proto.logs.v1.ResourceLogs;if(e.resource!=null){if(typeof e.resource!=`object`)throw TypeError(`.opentelemetry.proto.logs.v1.ResourceLogs.resource: object expected`);t.resource=o.opentelemetry.proto.resource.v1.Resource.fromObject(e.resource)}if(e.scopeLogs){if(!Array.isArray(e.scopeLogs))throw TypeError(`.opentelemetry.proto.logs.v1.ResourceLogs.scopeLogs: array expected`);t.scopeLogs=[];for(var n=0;n<e.scopeLogs.length;++n){if(typeof e.scopeLogs[n]!=`object`)throw TypeError(`.opentelemetry.proto.logs.v1.ResourceLogs.scopeLogs: object expected`);t.scopeLogs[n]=o.opentelemetry.proto.logs.v1.ScopeLogs.fromObject(e.scopeLogs[n])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.scopeLogs=[]),t.defaults&&(n.resource=null,n.schemaUrl=``),e.resource!=null&&e.hasOwnProperty(`resource`)&&(n.resource=o.opentelemetry.proto.resource.v1.Resource.toObject(e.resource,t)),e.scopeLogs&&e.scopeLogs.length){n.scopeLogs=[];for(var r=0;r<e.scopeLogs.length;++r)n.scopeLogs[r]=o.opentelemetry.proto.logs.v1.ScopeLogs.toObject(e.scopeLogs[r],t)}return e.schemaUrl!=null&&e.hasOwnProperty(`schemaUrl`)&&(n.schemaUrl=e.schemaUrl),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.logs.v1.ResourceLogs`},e})(),e.ScopeLogs=(function(){function e(e){if(this.logRecords=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.scope=null,e.prototype.logRecords=a.emptyArray,e.prototype.schemaUrl=null,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.scope!=null&&Object.hasOwnProperty.call(e,`scope`)&&o.opentelemetry.proto.common.v1.InstrumentationScope.encode(e.scope,t.uint32(10).fork()).ldelim(),e.logRecords!=null&&e.logRecords.length)for(var n=0;n<e.logRecords.length;++n)o.opentelemetry.proto.logs.v1.LogRecord.encode(e.logRecords[n],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,`schemaUrl`)&&t.uint32(26).string(e.schemaUrl),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.logs.v1.ScopeLogs;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.scope=o.opentelemetry.proto.common.v1.InstrumentationScope.decode(e,e.uint32());break;case 2:a.logRecords&&a.logRecords.length||(a.logRecords=[]),a.logRecords.push(o.opentelemetry.proto.logs.v1.LogRecord.decode(e,e.uint32()));break;case 3:a.schemaUrl=e.string();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.scope!=null&&e.hasOwnProperty(`scope`)){var t=o.opentelemetry.proto.common.v1.InstrumentationScope.verify(e.scope);if(t)return`scope.`+t}if(e.logRecords!=null&&e.hasOwnProperty(`logRecords`)){if(!Array.isArray(e.logRecords))return`logRecords: array expected`;for(var n=0;n<e.logRecords.length;++n){var t=o.opentelemetry.proto.logs.v1.LogRecord.verify(e.logRecords[n]);if(t)return`logRecords.`+t}}return e.schemaUrl!=null&&e.hasOwnProperty(`schemaUrl`)&&!a.isString(e.schemaUrl)?`schemaUrl: string expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.logs.v1.ScopeLogs)return e;var t=new o.opentelemetry.proto.logs.v1.ScopeLogs;if(e.scope!=null){if(typeof e.scope!=`object`)throw TypeError(`.opentelemetry.proto.logs.v1.ScopeLogs.scope: object expected`);t.scope=o.opentelemetry.proto.common.v1.InstrumentationScope.fromObject(e.scope)}if(e.logRecords){if(!Array.isArray(e.logRecords))throw TypeError(`.opentelemetry.proto.logs.v1.ScopeLogs.logRecords: array expected`);t.logRecords=[];for(var n=0;n<e.logRecords.length;++n){if(typeof e.logRecords[n]!=`object`)throw TypeError(`.opentelemetry.proto.logs.v1.ScopeLogs.logRecords: object expected`);t.logRecords[n]=o.opentelemetry.proto.logs.v1.LogRecord.fromObject(e.logRecords[n])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.logRecords=[]),t.defaults&&(n.scope=null,n.schemaUrl=``),e.scope!=null&&e.hasOwnProperty(`scope`)&&(n.scope=o.opentelemetry.proto.common.v1.InstrumentationScope.toObject(e.scope,t)),e.logRecords&&e.logRecords.length){n.logRecords=[];for(var r=0;r<e.logRecords.length;++r)n.logRecords[r]=o.opentelemetry.proto.logs.v1.LogRecord.toObject(e.logRecords[r],t)}return e.schemaUrl!=null&&e.hasOwnProperty(`schemaUrl`)&&(n.schemaUrl=e.schemaUrl),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.logs.v1.ScopeLogs`},e})(),e.SeverityNumber=(function(){var e={},t=Object.create(e);return t[e[0]=`SEVERITY_NUMBER_UNSPECIFIED`]=0,t[e[1]=`SEVERITY_NUMBER_TRACE`]=1,t[e[2]=`SEVERITY_NUMBER_TRACE2`]=2,t[e[3]=`SEVERITY_NUMBER_TRACE3`]=3,t[e[4]=`SEVERITY_NUMBER_TRACE4`]=4,t[e[5]=`SEVERITY_NUMBER_DEBUG`]=5,t[e[6]=`SEVERITY_NUMBER_DEBUG2`]=6,t[e[7]=`SEVERITY_NUMBER_DEBUG3`]=7,t[e[8]=`SEVERITY_NUMBER_DEBUG4`]=8,t[e[9]=`SEVERITY_NUMBER_INFO`]=9,t[e[10]=`SEVERITY_NUMBER_INFO2`]=10,t[e[11]=`SEVERITY_NUMBER_INFO3`]=11,t[e[12]=`SEVERITY_NUMBER_INFO4`]=12,t[e[13]=`SEVERITY_NUMBER_WARN`]=13,t[e[14]=`SEVERITY_NUMBER_WARN2`]=14,t[e[15]=`SEVERITY_NUMBER_WARN3`]=15,t[e[16]=`SEVERITY_NUMBER_WARN4`]=16,t[e[17]=`SEVERITY_NUMBER_ERROR`]=17,t[e[18]=`SEVERITY_NUMBER_ERROR2`]=18,t[e[19]=`SEVERITY_NUMBER_ERROR3`]=19,t[e[20]=`SEVERITY_NUMBER_ERROR4`]=20,t[e[21]=`SEVERITY_NUMBER_FATAL`]=21,t[e[22]=`SEVERITY_NUMBER_FATAL2`]=22,t[e[23]=`SEVERITY_NUMBER_FATAL3`]=23,t[e[24]=`SEVERITY_NUMBER_FATAL4`]=24,t})(),e.LogRecordFlags=(function(){var e={},t=Object.create(e);return t[e[0]=`LOG_RECORD_FLAGS_DO_NOT_USE`]=0,t[e[255]=`LOG_RECORD_FLAGS_TRACE_FLAGS_MASK`]=255,t})(),e.LogRecord=(function(){function e(e){if(this.attributes=[],e)for(var t=Object.keys(e),n=0;n<t.length;++n)e[t[n]]!=null&&(this[t[n]]=e[t[n]])}return e.prototype.timeUnixNano=null,e.prototype.observedTimeUnixNano=null,e.prototype.severityNumber=null,e.prototype.severityText=null,e.prototype.body=null,e.prototype.attributes=a.emptyArray,e.prototype.droppedAttributesCount=null,e.prototype.flags=null,e.prototype.traceId=null,e.prototype.spanId=null,e.prototype.eventName=null,e.create=function(t){return new e(t)},e.encode=function(e,t){if(t||=i.create(),e.timeUnixNano!=null&&Object.hasOwnProperty.call(e,`timeUnixNano`)&&t.uint32(9).fixed64(e.timeUnixNano),e.severityNumber!=null&&Object.hasOwnProperty.call(e,`severityNumber`)&&t.uint32(16).int32(e.severityNumber),e.severityText!=null&&Object.hasOwnProperty.call(e,`severityText`)&&t.uint32(26).string(e.severityText),e.body!=null&&Object.hasOwnProperty.call(e,`body`)&&o.opentelemetry.proto.common.v1.AnyValue.encode(e.body,t.uint32(42).fork()).ldelim(),e.attributes!=null&&e.attributes.length)for(var n=0;n<e.attributes.length;++n)o.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[n],t.uint32(50).fork()).ldelim();return e.droppedAttributesCount!=null&&Object.hasOwnProperty.call(e,`droppedAttributesCount`)&&t.uint32(56).uint32(e.droppedAttributesCount),e.flags!=null&&Object.hasOwnProperty.call(e,`flags`)&&t.uint32(69).fixed32(e.flags),e.traceId!=null&&Object.hasOwnProperty.call(e,`traceId`)&&t.uint32(74).bytes(e.traceId),e.spanId!=null&&Object.hasOwnProperty.call(e,`spanId`)&&t.uint32(82).bytes(e.spanId),e.observedTimeUnixNano!=null&&Object.hasOwnProperty.call(e,`observedTimeUnixNano`)&&t.uint32(89).fixed64(e.observedTimeUnixNano),e.eventName!=null&&Object.hasOwnProperty.call(e,`eventName`)&&t.uint32(98).string(e.eventName),t},e.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},e.decode=function(e,t,n){e instanceof r||(e=r.create(e));for(var i=t===void 0?e.len:e.pos+t,a=new o.opentelemetry.proto.logs.v1.LogRecord;e.pos<i;){var s=e.uint32();if(s===n)break;switch(s>>>3){case 1:a.timeUnixNano=e.fixed64();break;case 11:a.observedTimeUnixNano=e.fixed64();break;case 2:a.severityNumber=e.int32();break;case 3:a.severityText=e.string();break;case 5:a.body=o.opentelemetry.proto.common.v1.AnyValue.decode(e,e.uint32());break;case 6:a.attributes&&a.attributes.length||(a.attributes=[]),a.attributes.push(o.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break;case 7:a.droppedAttributesCount=e.uint32();break;case 8:a.flags=e.fixed32();break;case 9:a.traceId=e.bytes();break;case 10:a.spanId=e.bytes();break;case 12:a.eventName=e.string();break;default:e.skipType(s&7)}}return a},e.decodeDelimited=function(e){return e instanceof r||(e=new r(e)),this.decode(e,e.uint32())},e.verify=function(e){if(typeof e!=`object`||!e)return`object expected`;if(e.timeUnixNano!=null&&e.hasOwnProperty(`timeUnixNano`)&&!a.isInteger(e.timeUnixNano)&&!(e.timeUnixNano&&a.isInteger(e.timeUnixNano.low)&&a.isInteger(e.timeUnixNano.high)))return`timeUnixNano: integer|Long expected`;if(e.observedTimeUnixNano!=null&&e.hasOwnProperty(`observedTimeUnixNano`)&&!a.isInteger(e.observedTimeUnixNano)&&!(e.observedTimeUnixNano&&a.isInteger(e.observedTimeUnixNano.low)&&a.isInteger(e.observedTimeUnixNano.high)))return`observedTimeUnixNano: integer|Long expected`;if(e.severityNumber!=null&&e.hasOwnProperty(`severityNumber`))switch(e.severityNumber){default:return`severityNumber: enum value expected`;case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:case 8:case 9:case 10:case 11:case 12:case 13:case 14:case 15:case 16:case 17:case 18:case 19:case 20:case 21:case 22:case 23:case 24:}if(e.severityText!=null&&e.hasOwnProperty(`severityText`)&&!a.isString(e.severityText))return`severityText: string expected`;if(e.body!=null&&e.hasOwnProperty(`body`)){var t=o.opentelemetry.proto.common.v1.AnyValue.verify(e.body);if(t)return`body.`+t}if(e.attributes!=null&&e.hasOwnProperty(`attributes`)){if(!Array.isArray(e.attributes))return`attributes: array expected`;for(var n=0;n<e.attributes.length;++n){var t=o.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[n]);if(t)return`attributes.`+t}}return e.droppedAttributesCount!=null&&e.hasOwnProperty(`droppedAttributesCount`)&&!a.isInteger(e.droppedAttributesCount)?`droppedAttributesCount: integer expected`:e.flags!=null&&e.hasOwnProperty(`flags`)&&!a.isInteger(e.flags)?`flags: integer expected`:e.traceId!=null&&e.hasOwnProperty(`traceId`)&&!(e.traceId&&typeof e.traceId.length==`number`||a.isString(e.traceId))?`traceId: buffer expected`:e.spanId!=null&&e.hasOwnProperty(`spanId`)&&!(e.spanId&&typeof e.spanId.length==`number`||a.isString(e.spanId))?`spanId: buffer expected`:e.eventName!=null&&e.hasOwnProperty(`eventName`)&&!a.isString(e.eventName)?`eventName: string expected`:null},e.fromObject=function(e){if(e instanceof o.opentelemetry.proto.logs.v1.LogRecord)return e;var t=new o.opentelemetry.proto.logs.v1.LogRecord;switch(e.timeUnixNano!=null&&(a.Long?(t.timeUnixNano=a.Long.fromValue(e.timeUnixNano)).unsigned=!1:typeof e.timeUnixNano==`string`?t.timeUnixNano=parseInt(e.timeUnixNano,10):typeof e.timeUnixNano==`number`?t.timeUnixNano=e.timeUnixNano:typeof e.timeUnixNano==`object`&&(t.timeUnixNano=new a.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber())),e.observedTimeUnixNano!=null&&(a.Long?(t.observedTimeUnixNano=a.Long.fromValue(e.observedTimeUnixNano)).unsigned=!1:typeof e.observedTimeUnixNano==`string`?t.observedTimeUnixNano=parseInt(e.observedTimeUnixNano,10):typeof e.observedTimeUnixNano==`number`?t.observedTimeUnixNano=e.observedTimeUnixNano:typeof e.observedTimeUnixNano==`object`&&(t.observedTimeUnixNano=new a.LongBits(e.observedTimeUnixNano.low>>>0,e.observedTimeUnixNano.high>>>0).toNumber())),e.severityNumber){default:if(typeof e.severityNumber==`number`){t.severityNumber=e.severityNumber;break}break;case`SEVERITY_NUMBER_UNSPECIFIED`:case 0:t.severityNumber=0;break;case`SEVERITY_NUMBER_TRACE`:case 1:t.severityNumber=1;break;case`SEVERITY_NUMBER_TRACE2`:case 2:t.severityNumber=2;break;case`SEVERITY_NUMBER_TRACE3`:case 3:t.severityNumber=3;break;case`SEVERITY_NUMBER_TRACE4`:case 4:t.severityNumber=4;break;case`SEVERITY_NUMBER_DEBUG`:case 5:t.severityNumber=5;break;case`SEVERITY_NUMBER_DEBUG2`:case 6:t.severityNumber=6;break;case`SEVERITY_NUMBER_DEBUG3`:case 7:t.severityNumber=7;break;case`SEVERITY_NUMBER_DEBUG4`:case 8:t.severityNumber=8;break;case`SEVERITY_NUMBER_INFO`:case 9:t.severityNumber=9;break;case`SEVERITY_NUMBER_INFO2`:case 10:t.severityNumber=10;break;case`SEVERITY_NUMBER_INFO3`:case 11:t.severityNumber=11;break;case`SEVERITY_NUMBER_INFO4`:case 12:t.severityNumber=12;break;case`SEVERITY_NUMBER_WARN`:case 13:t.severityNumber=13;break;case`SEVERITY_NUMBER_WARN2`:case 14:t.severityNumber=14;break;case`SEVERITY_NUMBER_WARN3`:case 15:t.severityNumber=15;break;case`SEVERITY_NUMBER_WARN4`:case 16:t.severityNumber=16;break;case`SEVERITY_NUMBER_ERROR`:case 17:t.severityNumber=17;break;case`SEVERITY_NUMBER_ERROR2`:case 18:t.severityNumber=18;break;case`SEVERITY_NUMBER_ERROR3`:case 19:t.severityNumber=19;break;case`SEVERITY_NUMBER_ERROR4`:case 20:t.severityNumber=20;break;case`SEVERITY_NUMBER_FATAL`:case 21:t.severityNumber=21;break;case`SEVERITY_NUMBER_FATAL2`:case 22:t.severityNumber=22;break;case`SEVERITY_NUMBER_FATAL3`:case 23:t.severityNumber=23;break;case`SEVERITY_NUMBER_FATAL4`:case 24:t.severityNumber=24}if(e.severityText!=null&&(t.severityText=String(e.severityText)),e.body!=null){if(typeof e.body!=`object`)throw TypeError(`.opentelemetry.proto.logs.v1.LogRecord.body: object expected`);t.body=o.opentelemetry.proto.common.v1.AnyValue.fromObject(e.body)}if(e.attributes){if(!Array.isArray(e.attributes))throw TypeError(`.opentelemetry.proto.logs.v1.LogRecord.attributes: array expected`);t.attributes=[];for(var n=0;n<e.attributes.length;++n){if(typeof e.attributes[n]!=`object`)throw TypeError(`.opentelemetry.proto.logs.v1.LogRecord.attributes: object expected`);t.attributes[n]=o.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[n])}}return e.droppedAttributesCount!=null&&(t.droppedAttributesCount=e.droppedAttributesCount>>>0),e.flags!=null&&(t.flags=e.flags>>>0),e.traceId!=null&&(typeof e.traceId==`string`?a.base64.decode(e.traceId,t.traceId=a.newBuffer(a.base64.length(e.traceId)),0):e.traceId.length>=0&&(t.traceId=e.traceId)),e.spanId!=null&&(typeof e.spanId==`string`?a.base64.decode(e.spanId,t.spanId=a.newBuffer(a.base64.length(e.spanId)),0):e.spanId.length>=0&&(t.spanId=e.spanId)),e.eventName!=null&&(t.eventName=String(e.eventName)),t},e.toObject=function(e,t){t||={};var n={};if((t.arrays||t.defaults)&&(n.attributes=[]),t.defaults){if(a.Long){var r=new a.Long(0,0,!1);n.timeUnixNano=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.timeUnixNano=t.longs===String?`0`:0;if(n.severityNumber=t.enums===String?`SEVERITY_NUMBER_UNSPECIFIED`:0,n.severityText=``,n.body=null,n.droppedAttributesCount=0,n.flags=0,t.bytes===String?n.traceId=``:(n.traceId=[],t.bytes!==Array&&(n.traceId=a.newBuffer(n.traceId))),t.bytes===String?n.spanId=``:(n.spanId=[],t.bytes!==Array&&(n.spanId=a.newBuffer(n.spanId))),a.Long){var r=new a.Long(0,0,!1);n.observedTimeUnixNano=t.longs===String?r.toString():t.longs===Number?r.toNumber():r}else n.observedTimeUnixNano=t.longs===String?`0`:0;n.eventName=``}if(e.timeUnixNano!=null&&e.hasOwnProperty(`timeUnixNano`)&&(n.timeUnixNano=typeof e.timeUnixNano==`number`?t.longs===String?String(e.timeUnixNano):e.timeUnixNano:t.longs===String?a.Long.prototype.toString.call(e.timeUnixNano):t.longs===Number?new a.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber():e.timeUnixNano),e.severityNumber!=null&&e.hasOwnProperty(`severityNumber`)&&(n.severityNumber=t.enums===String?o.opentelemetry.proto.logs.v1.SeverityNumber[e.severityNumber]===void 0?e.severityNumber:o.opentelemetry.proto.logs.v1.SeverityNumber[e.severityNumber]:e.severityNumber),e.severityText!=null&&e.hasOwnProperty(`severityText`)&&(n.severityText=e.severityText),e.body!=null&&e.hasOwnProperty(`body`)&&(n.body=o.opentelemetry.proto.common.v1.AnyValue.toObject(e.body,t)),e.attributes&&e.attributes.length){n.attributes=[];for(var i=0;i<e.attributes.length;++i)n.attributes[i]=o.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[i],t)}return e.droppedAttributesCount!=null&&e.hasOwnProperty(`droppedAttributesCount`)&&(n.droppedAttributesCount=e.droppedAttributesCount),e.flags!=null&&e.hasOwnProperty(`flags`)&&(n.flags=e.flags),e.traceId!=null&&e.hasOwnProperty(`traceId`)&&(n.traceId=t.bytes===String?a.base64.encode(e.traceId,0,e.traceId.length):t.bytes===Array?Array.prototype.slice.call(e.traceId):e.traceId),e.spanId!=null&&e.hasOwnProperty(`spanId`)&&(n.spanId=t.bytes===String?a.base64.encode(e.spanId,0,e.spanId.length):t.bytes===Array?Array.prototype.slice.call(e.spanId):e.spanId),e.observedTimeUnixNano!=null&&e.hasOwnProperty(`observedTimeUnixNano`)&&(n.observedTimeUnixNano=typeof e.observedTimeUnixNano==`number`?t.longs===String?String(e.observedTimeUnixNano):e.observedTimeUnixNano:t.longs===String?a.Long.prototype.toString.call(e.observedTimeUnixNano):t.longs===Number?new a.LongBits(e.observedTimeUnixNano.low>>>0,e.observedTimeUnixNano.high>>>0).toNumber():e.observedTimeUnixNano),e.eventName!=null&&e.hasOwnProperty(`eventName`)&&(n.eventName=e.eventName),n},e.prototype.toJSON=function(){return this.constructor.toObject(this,n.util.toJSONOptions)},e.getTypeUrl=function(e){return e===void 0&&(e=`type.googleapis.com`),e+`/opentelemetry.proto.logs.v1.LogRecord`},e})(),e})(),e})(),e})(),e})(),t.exports=o}));function S(e,t){let n={attributes:w(e.attributes,t),droppedAttributesCount:0},r=e.schemaUrl;return r&&r!==``&&(n.schemaUrl=r),n}function C(e){return{name:e.name,version:e.version}}function w(e,t){return Object.keys(e).map(n=>T(n,e[n],t))}function T(e,t,n){return{key:e,value:E(t,n)}}function E(e,t){let n=typeof e;if(n===`string`)return{stringValue:e};if(n===`number`)return Number.isInteger(e)?{intValue:e}:{doubleValue:e};if(n===`boolean`)return{boolValue:e};if(e instanceof Uint8Array)return{bytesValue:t.encodeUint8Array(e)};if(Array.isArray(e)){let n=Array(e.length);for(let r=0;r<e.length;r++)n[r]=E(e[r],t);return{arrayValue:{values:n}}}if(n===`object`&&e!=null){let n=Object.keys(e),r=Array(n.length);for(let i=0;i<n.length;i++)r[i]={key:n[i],value:E(e[n[i]],t)};return{kvlistValue:{values:r}}}return{}}function D(e,t){return{resourceLogs:k(e,t)}}function O(e){let t=new Map;for(let n of e){let{resource:e,instrumentationScope:{name:r,version:i=``,schemaUrl:a=``}}=n,o=t.get(e);o||(o=new Map,t.set(e,o));let s=`${r}@${i}:${a}`,c=o.get(s);c||(c=[],o.set(s,c)),c.push(n)}return t}function k(e,t){let n=O(e);return Array.from(n,([e,n])=>{let r=S(e,t);return{resource:r,scopeLogs:Array.from(n,([,e])=>({scope:C(e[0].instrumentationScope),logRecords:e.map(e=>A(e,t)),schemaUrl:e[0].instrumentationScope.schemaUrl})),schemaUrl:r.schemaUrl}})}function A(e,t){return{timeUnixNano:t.encodeHrTime(e.hrTime),observedTimeUnixNano:t.encodeHrTime(e.hrTimeObserved),severityNumber:ee(e.severityNumber),severityText:e.severityText,body:E(e.body,t),eventName:e.eventName,attributes:j(e.attributes,t),droppedAttributesCount:e.droppedAttributesCount,flags:e.spanContext?.traceFlags,traceId:t.encodeOptionalSpanContext(e.spanContext?.traceId),spanId:t.encodeOptionalSpanContext(e.spanContext?.spanId)}}function ee(e){return e}function j(e,t){return Object.keys(e).map(n=>T(n,e[n],t))}const M=10**9;function N(e){return e[0]*M+e[1]}function P(e){return e>=48&&e<=57?e-48:e>=97&&e<=102?e-87:e-55}function F(e){let t=new Uint8Array(e.length/2),n=0;for(let r=0;r<e.length;r+=2){let i=P(e.charCodeAt(r)),a=P(e.charCodeAt(r+1));t[n++]=i<<4|a}return t}function I(e){let t=BigInt(1e9);return BigInt(Math.trunc(e[0]))*t+BigInt(Math.trunc(e[1]))}function te(e){return{low:Number(BigInt.asUintN(32,e)),high:Number(BigInt.asUintN(32,e>>BigInt(32)))}}function ne(e){return te(I(e))}function re(e){return I(e).toString()}const ie=typeof BigInt<`u`?re:N;function L(e){return e}function ae(e){if(e!==void 0)return F(e)}const R={encodeHrTime:ne,encodeSpanContext:F,encodeOptionalSpanContext:ae,encodeUint8Array:L},z={encodeHrTime:ie,encodeSpanContext:L,encodeOptionalSpanContext:L,encodeUint8Array:e=>{if(typeof Buffer<`u`)return Buffer.from(e).toString(`base64`);let t=Array(e.length);for(let n=0;n<e.length;n++)t[n]=String.fromCharCode(e[n]);return btoa(t.join(``))}};var B=e(x());const V=B.opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse,H=B.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest,U={serializeRequest:e=>{let t=D(e,R);return H.encode(t).finish()},deserializeResponse:e=>V.decode(e)};var W;(function(e){e[e.DELTA=0]=`DELTA`,e[e.CUMULATIVE=1]=`CUMULATIVE`})(W||={});var G;(function(e){e.COUNTER=`COUNTER`,e.GAUGE=`GAUGE`,e.HISTOGRAM=`HISTOGRAM`,e.UP_DOWN_COUNTER=`UP_DOWN_COUNTER`,e.OBSERVABLE_COUNTER=`OBSERVABLE_COUNTER`,e.OBSERVABLE_GAUGE=`OBSERVABLE_GAUGE`,e.OBSERVABLE_UP_DOWN_COUNTER=`OBSERVABLE_UP_DOWN_COUNTER`})(G||={});var K;(function(e){e[e.HISTOGRAM=0]=`HISTOGRAM`,e[e.EXPONENTIAL_HISTOGRAM=1]=`EXPONENTIAL_HISTOGRAM`,e[e.GAUGE=2]=`GAUGE`,e[e.SUM=3]=`SUM`})(K||={});var q;(function(e){e[e.AGGREGATION_TEMPORALITY_UNSPECIFIED=0]=`AGGREGATION_TEMPORALITY_UNSPECIFIED`,e[e.AGGREGATION_TEMPORALITY_DELTA=1]=`AGGREGATION_TEMPORALITY_DELTA`,e[e.AGGREGATION_TEMPORALITY_CUMULATIVE=2]=`AGGREGATION_TEMPORALITY_CUMULATIVE`})(q||={});function J(e,t){let n=S(e.resource,t);return{resource:n,schemaUrl:n.schemaUrl,scopeMetrics:oe(e.scopeMetrics,t)}}function oe(e,t){return Array.from(e.map(e=>({scope:C(e.scope),metrics:e.metrics.map(e=>se(e,t)),schemaUrl:e.scope.schemaUrl})))}function se(e,t){let n={name:e.descriptor.name,description:e.descriptor.description,unit:e.descriptor.unit},r=de(e.aggregationTemporality);switch(e.dataPointType){case K.SUM:n.sum={aggregationTemporality:r,isMonotonic:e.isMonotonic,dataPoints:Y(e,t)};break;case K.GAUGE:n.gauge={dataPoints:Y(e,t)};break;case K.HISTOGRAM:n.histogram={aggregationTemporality:r,dataPoints:le(e,t)};break;case K.EXPONENTIAL_HISTOGRAM:n.exponentialHistogram={aggregationTemporality:r,dataPoints:ue(e,t)}}return n}function ce(e,t,r){let i={attributes:w(e.attributes,r),startTimeUnixNano:r.encodeHrTime(e.startTime),timeUnixNano:r.encodeHrTime(e.endTime)};switch(t){case n.INT:i.asInt=e.value;break;case n.DOUBLE:i.asDouble=e.value}return i}function Y(e,t){return e.dataPoints.map(n=>ce(n,e.descriptor.valueType,t))}function le(e,t){return e.dataPoints.map(e=>{let n=e.value;return{attributes:w(e.attributes,t),bucketCounts:n.buckets.counts,explicitBounds:n.buckets.boundaries,count:n.count,sum:n.sum,min:n.min,max:n.max,startTimeUnixNano:t.encodeHrTime(e.startTime),timeUnixNano:t.encodeHrTime(e.endTime)}})}function ue(e,t){return e.dataPoints.map(e=>{let n=e.value;return{attributes:w(e.attributes,t),count:n.count,min:n.min,max:n.max,sum:n.sum,positive:{offset:n.positive.offset,bucketCounts:n.positive.bucketCounts},negative:{offset:n.negative.offset,bucketCounts:n.negative.bucketCounts},scale:n.scale,zeroCount:n.zeroCount,startTimeUnixNano:t.encodeHrTime(e.startTime),timeUnixNano:t.encodeHrTime(e.endTime)}})}function de(e){switch(e){case W.DELTA:return q.AGGREGATION_TEMPORALITY_DELTA;case W.CUMULATIVE:return q.AGGREGATION_TEMPORALITY_CUMULATIVE}}function X(e,t){return{resourceMetrics:e.map(e=>J(e,t))}}const fe=B.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse,pe=B.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest,me={serializeRequest:e=>{let t=X([e],R);return pe.encode(t).finish()},deserializeResponse:e=>fe.decode(e)};function Z(e,t){let n=e&255|256;return t&&(n|=512),n}function Q(e,t){let n=e.spanContext(),r=e.status,i=e.parentSpanContext?.spanId?t.encodeSpanContext(e.parentSpanContext?.spanId):void 0;return{traceId:t.encodeSpanContext(n.traceId),spanId:t.encodeSpanContext(n.spanId),parentSpanId:i,traceState:n.traceState?.serialize(),name:e.name,kind:e.kind==null?0:e.kind+1,startTimeUnixNano:t.encodeHrTime(e.startTime),endTimeUnixNano:t.encodeHrTime(e.endTime),attributes:w(e.attributes,t),droppedAttributesCount:e.droppedAttributesCount,events:e.events.map(e=>ge(e,t)),droppedEventsCount:e.droppedEventsCount,status:{code:r.code,message:r.message},links:e.links.map(e=>he(e,t)),droppedLinksCount:e.droppedLinksCount,flags:Z(n.traceFlags,e.parentSpanContext?.isRemote)}}function he(e,t){return{attributes:e.attributes?w(e.attributes,t):[],spanId:t.encodeSpanContext(e.context.spanId),traceId:t.encodeSpanContext(e.context.traceId),traceState:e.context.traceState?.serialize(),droppedAttributesCount:e.droppedAttributesCount||0,flags:Z(e.context.traceFlags,e.context.isRemote)}}function ge(e,t){return{attributes:e.attributes?w(e.attributes,t):[],name:e.name,timeUnixNano:t.encodeHrTime(e.time),droppedAttributesCount:e.droppedAttributesCount||0}}function $(e,t){return{resourceSpans:ve(e,t)}}function _e(e){let t=new Map;for(let n of e){let e=t.get(n.resource);e||(e=new Map,t.set(n.resource,e));let r=`${n.instrumentationScope.name}@${n.instrumentationScope.version||``}:${n.instrumentationScope.schemaUrl||``}`,i=e.get(r);i||(i=[],e.set(r,i)),i.push(n)}return t}function ve(e,t){let n=_e(e),r=[],i=n.entries(),a=i.next();for(;!a.done;){let[e,n]=a.value,o=[],s=n.values(),c=s.next();for(;!c.done;){let e=c.value;if(e.length>0){let n=e.map(e=>Q(e,t));o.push({scope:C(e[0].instrumentationScope),spans:n,schemaUrl:e[0].instrumentationScope.schemaUrl})}c=s.next()}let l=S(e,t),u={resource:l,scopeSpans:o,schemaUrl:l.schemaUrl};r.push(u),a=i.next()}return r}const ye=B.opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse,be=B.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest,xe={serializeRequest:e=>{let t=$(e,R);return be.encode(t).finish()},deserializeResponse:e=>ye.decode(e)},Se={serializeRequest:e=>{let t=D(e,z);return new TextEncoder().encode(JSON.stringify(t))},deserializeResponse:e=>{if(e.length===0)return{};let t=new TextDecoder;return JSON.parse(t.decode(e))}},Ce={serializeRequest:e=>{let t=X([e],z);return new TextEncoder().encode(JSON.stringify(t))},deserializeResponse:e=>{if(e.length===0)return{};let t=new TextDecoder;return JSON.parse(t.decode(e))}},we={serializeRequest:e=>{let t=$(e,z);return new TextEncoder().encode(JSON.stringify(t))},deserializeResponse:e=>{if(e.length===0)return{};let t=new TextDecoder;return JSON.parse(t.decode(e))}};export{Se as JsonLogsSerializer,Ce as JsonMetricsSerializer,we as JsonTraceSerializer,U as ProtobufLogsSerializer,me as ProtobufMetricsSerializer,xe as ProtobufTraceSerializer};