define((function(){"use strict";return class{constructor(){}static getHeaderArray(t){let r=[];for(let n=0;n>24&255,t>>16&255,t>>8&255,255&t]}static bytesToInt(t){return t[0]<<24|t[1]<<16|t[2]<<8|t[3]}static varintToInt(t){let r=[],n=[],e=3,i=0;for(let o=t.length-1;o>=0&&(n[0]=o-1>=0?t[o-1]<<7-i:0,-1!==e);o--)r[e]=(127&t[o])>>i|n[0],e--,i++;let o=r[0]<<24&4278190080|r[1]<<16&16711680|r[2]<<8&65280|255&r[3];return o=o>>1^-(1&o),o}static intToVarint(t){if(0===t)return[0];t=this._zigZagEncoding(t);let r,n=[],e=0;for(let i=5;i>0;i--)r=t>>7*(i-1)&127,0!==e&&(r|=128),0!==r&&n.push(r),e=r;return n}static varintToIntArray(t){let r,n=[],e=0,i=[];for(let o=0;o>7&1,0===r&&e>0&&e<=5&&(i.push(this.varintToInt(n)),n=[],e=0),n.push(t[o]),e++;return i.push(this.varintToInt(n)),i}static intArrayToVarintBuffer(t){let r,n=[];for(let e=0;e>31^t<<1}}}));