1
|
|
|
var $jscomp=$jscomp||{};$jscomp.scope={};$jscomp.ASSUME_ES5=!1;$jscomp.ASSUME_NO_NATIVE_MAP=!1;$jscomp.ASSUME_NO_NATIVE_SET=!1;$jscomp.SIMPLE_FROUND_POLYFILL=!1;$jscomp.objectCreate=$jscomp.ASSUME_ES5||"function"==typeof Object.create?Object.create:function(b){var a=function(){};a.prototype=b;return new a};$jscomp.underscoreProtoCanBeSet=function(){var b={a:!0},a={};try{return a.__proto__=b,a.a}catch(e){}return!1}; |
|
|
|
|
2
|
|
|
$jscomp.setPrototypeOf="function"==typeof Object.setPrototypeOf?Object.setPrototypeOf:$jscomp.underscoreProtoCanBeSet()?function(b,a){b.__proto__=a;if(b.__proto__!==a)throw new TypeError(b+" is not extensible");return b}:null; |
|
|
|
|
3
|
|
|
$jscomp.inherits=function(b,a){b.prototype=$jscomp.objectCreate(a.prototype);b.prototype.constructor=b;if($jscomp.setPrototypeOf){var e=$jscomp.setPrototypeOf;e(b,a)}else for(e in a)if("prototype"!=e)if(Object.defineProperties){var c=Object.getOwnPropertyDescriptor(a,e);c&&Object.defineProperty(b,e,c)}else b[e]=a[e];b.superClass_=a.prototype}; |
|
|
|
|
4
|
|
|
(function(b,a){"object"===typeof exports&&"undefined"!==typeof module?a(exports):"function"===typeof define&&define.amd?define(["exports"],a):(b=b||self,a(b.TwosComplementBuffer={}))})(this,function(b){var a=function(c){this.bits=c;this.bytes=8>c?1:Math.ceil(c/8);this.max=Math.pow(2,c)-1;this.min=0;c=8-((c-1|7)+1-c);this.lastByteMask_=Math.pow(2,0<c?c:8)-1};a.prototype.pack=function(c,a,d){d=void 0===d?0:d;if(a!==a||"number"!=typeof a)throw new TypeError;this.overflow(a);return this.pack_(c,a,d)}; |
|
|
|
|
5
|
|
|
a.prototype.packUnsafe=function(c,a,d){return this.pack_(c,a,void 0===d?0:d)};a.prototype.unpack=function(c,a){var d=this.unpackUnsafe(c,void 0===a?0:a);this.overflow(d);return d};a.prototype.unpackUnsafe=function(c,a){a=void 0===a?0:a;for(var d=0,b=0;b<this.bytes;b++)d+=c[a+b]*Math.pow(256,b);return d};a.prototype.overflow=function(a){if(a>this.max||a<this.min)throw new RangeError;};a.prototype.pack_=function(a,b,d){d=void 0===d?0:d;a[d]=(0>b?b+Math.pow(2,this.bits):b)&255;d++;for(var c=this.bytes, |
|
|
|
|
6
|
|
|
e=2;e<c;e++)a[d]=Math.floor(b/Math.pow(2,8*(e-1)))&255,d++;8<this.bits&&(a[d]=Math.floor(b/Math.pow(2,8*(this.bytes-1)))&this.lastByteMask_,d++);return d};var e=function(c){c=a.call(this,c)||this;c.max=Math.pow(2,c.bits)/2-1;c.min=-c.max-1;return c};$jscomp.inherits(e,a);e.prototype.pack=function(c,b,d){return a.prototype.pack.call(this,c,b,void 0===d?0:d)};e.prototype.unpack=function(c,b){var d=a.prototype.unpackUnsafe.call(this,c,void 0===b?0:b);d=this.sign_(d);this.overflow(d);return d};e.prototype.sign_= |
|
|
|
|
7
|
|
|
function(a){a>this.max&&(a-=2*this.max+2);return a};b.TwosComplementBuffer=e;Object.defineProperty(b,"__esModule",{value:!0})}); |
8
|
|
|
|