!function(w0,w1){if("object"==typeof exports&&"object"==typeof module)module.exports=w1(require("../../config.js"),require("../util/longUtil"),require("../client/messageConfig"),require("../messages/mediaMessageContent"),require("../messages/messageStatus"),require("../messages/persistFlag"),require("../model/channelInfo"),require("../model/conversation"),require("../model/conversationType"),require("../model/groupInfo"),require("../model/groupMemberType"),require("../model/nullGroupInfo"),require("../model/nullUserInfo"),require("../model/userInfo"),require("../client/userSettingScope"),require("../model/conversationInfo"),require("../model/internal/friendInfo"),require("../model/NullChannelInfo"),require("../../wfc/util/base64.min"),require("../messages/message"),require("../messages/messageContentType"),require("../messages/notification/recallMessageNotification"),require("../model/chatRoomMemberInfo"),require("../model/friendRequest"),require("../model/groupMember"),require("../client/wfcEvent"),require("../model/unreadCount"),require("../model/friend"),require("../model/groupSearchResult"),require("../client/connectionStatus"),require("../model/userSettingEntry"),require("../client/errorCode"),require("../model/chatRoomInfo"),require("../model/readEntry"),require("../model/fileRecord"),require("../util/base64.min"),require("../messages/markUnreadMessageContent"),require("../model/userOnlineState"),require("../model/userClientState"),require("../model/userCustomState"),require("../model/channelMenu"),require("../messages/compositeMessageContent"));else if("function"==typeof define&&define.amd)define(["../../config.js","../util/longUtil","../client/messageConfig","../messages/mediaMessageContent","../messages/messageStatus","../messages/persistFlag","../model/channelInfo","../model/conversation","../model/conversationType","../model/groupInfo","../model/groupMemberType","../model/nullGroupInfo","../model/nullUserInfo","../model/userInfo","../client/userSettingScope","../model/conversationInfo","../model/internal/friendInfo","../model/NullChannelInfo","../../wfc/util/base64.min","../messages/message","../messages/messageContentType","../messages/notification/recallMessageNotification","../model/chatRoomMemberInfo","../model/friendRequest","../model/groupMember","../client/wfcEvent","../model/unreadCount","../model/friend","../model/groupSearchResult","../client/connectionStatus","../model/userSettingEntry","../client/errorCode","../model/chatRoomInfo","../model/readEntry","../model/fileRecord","../util/base64.min","../messages/markUnreadMessageContent","../model/userOnlineState","../model/userClientState","../model/userCustomState","../model/channelMenu","../messages/compositeMessageContent"],w1);else{var w2="object"==typeof exports?w1(require("../../config.js"),require("../util/longUtil"),require("../client/messageConfig"),require("../messages/mediaMessageContent"),require("../messages/messageStatus"),require("../messages/persistFlag"),require("../model/channelInfo"),require("../model/conversation"),require("../model/conversationType"),require("../model/groupInfo"),require("../model/groupMemberType"),require("../model/nullGroupInfo"),require("../model/nullUserInfo"),require("../model/userInfo"),require("../client/userSettingScope"),require("../model/conversationInfo"),require("../model/internal/friendInfo"),require("../model/NullChannelInfo"),require("../../wfc/util/base64.min"),require("../messages/message"),require("../messages/messageContentType"),require("../messages/notification/recallMessageNotification"),require("../model/chatRoomMemberInfo"),require("../model/friendRequest"),require("../model/groupMember"),require("../client/wfcEvent"),require("../model/unreadCount"),require("../model/friend"),require("../model/groupSearchResult"),require("../client/connectionStatus"),require("../model/userSettingEntry"),require("../client/errorCode"),require("../model/chatRoomInfo"),require("../model/readEntry"),require("../model/fileRecord"),require("../util/base64.min"),require("../messages/markUnreadMessageContent"),require("../model/userOnlineState"),require("../model/userClientState"),require("../model/userCustomState"),require("../model/channelMenu"),require("../messages/compositeMessageContent")):w1(w0["../../config.js"],w0["../util/longUtil"],w0["../client/messageConfig"],w0["../messages/mediaMessageContent"],w0["../messages/messageStatus"],w0["../messages/persistFlag"],w0["../model/channelInfo"],w0["../model/conversation"],w0["../model/conversationType"],w0["../model/groupInfo"],w0["../model/groupMemberType"],w0["../model/nullGroupInfo"],w0["../model/nullUserInfo"],w0["../model/userInfo"],w0["../client/userSettingScope"],w0["../model/conversationInfo"],w0["../model/internal/friendInfo"],w0["../model/NullChannelInfo"],w0["../../wfc/util/base64.min"],w0["../messages/message"],w0["../messages/messageContentType"],w0["../messages/notification/recallMessageNotification"],w0["../model/chatRoomMemberInfo"],w0["../model/friendRequest"],w0["../model/groupMember"],w0["../client/wfcEvent"],w0["../model/unreadCount"],w0["../model/friend"],w0["../model/groupSearchResult"],w0["../client/connectionStatus"],w0["../model/userSettingEntry"],w0["../client/errorCode"],w0["../model/chatRoomInfo"],w0["../model/readEntry"],w0["../model/fileRecord"],w0["../util/base64.min"],w0["../messages/markUnreadMessageContent"],w0["../model/userOnlineState"],w0["../model/userClientState"],w0["../model/userCustomState"],w0["../model/channelMenu"],w0["../messages/compositeMessageContent"]);for(var w3 in w2)("object"==typeof exports?exports:w0)[w3]=w2[w3]}}(window,(function(__WEBPACK_EXTERNAL_MODULE__92__,__WEBPACK_EXTERNAL_MODULE__125__,__WEBPACK_EXTERNAL_MODULE__160__,__WEBPACK_EXTERNAL_MODULE__161__,__WEBPACK_EXTERNAL_MODULE__162__,__WEBPACK_EXTERNAL_MODULE__163__,__WEBPACK_EXTERNAL_MODULE__164__,__WEBPACK_EXTERNAL_MODULE__165__,__WEBPACK_EXTERNAL_MODULE__166__,__WEBPACK_EXTERNAL_MODULE__167__,__WEBPACK_EXTERNAL_MODULE__168__,__WEBPACK_EXTERNAL_MODULE__169__,__WEBPACK_EXTERNAL_MODULE__170__,__WEBPACK_EXTERNAL_MODULE__171__,__WEBPACK_EXTERNAL_MODULE__172__,__WEBPACK_EXTERNAL_MODULE__173__,__WEBPACK_EXTERNAL_MODULE__174__,__WEBPACK_EXTERNAL_MODULE__175__,__WEBPACK_EXTERNAL_MODULE__267__,__WEBPACK_EXTERNAL_MODULE__370__,__WEBPACK_EXTERNAL_MODULE__371__,__WEBPACK_EXTERNAL_MODULE__372__,__WEBPACK_EXTERNAL_MODULE__373__,__WEBPACK_EXTERNAL_MODULE__374__,__WEBPACK_EXTERNAL_MODULE__375__,__WEBPACK_EXTERNAL_MODULE__376__,__WEBPACK_EXTERNAL_MODULE__379__,__WEBPACK_EXTERNAL_MODULE__381__,__WEBPACK_EXTERNAL_MODULE__382__,__WEBPACK_EXTERNAL_MODULE__384__,__WEBPACK_EXTERNAL_MODULE__385__,__WEBPACK_EXTERNAL_MODULE__395__,__WEBPACK_EXTERNAL_MODULE__396__,__WEBPACK_EXTERNAL_MODULE__397__,__WEBPACK_EXTERNAL_MODULE__398__,__WEBPACK_EXTERNAL_MODULE__399__,__WEBPACK_EXTERNAL_MODULE__400__,__WEBPACK_EXTERNAL_MODULE__401__,__WEBPACK_EXTERNAL_MODULE__402__,__WEBPACK_EXTERNAL_MODULE__403__,__WEBPACK_EXTERNAL_MODULE__404__,__WEBPACK_EXTERNAL_MODULE__405__){return function(w0){var w1={};function w2(w3){if(w1[w3])return w1[w3].exports;var w4=w1[w3]={i:w3,l:!1,exports:{}};return w0[w3].call(w4.exports,w4,w4.exports,w2),w4.l=!0,w4.exports}return w2.m=w0,w2.c=w1,w2.d=function(w0,w1,w3){w2.o(w0,w1)||Object.defineProperty(w0,w1,{enumerable:!0,get:w3})},w2.r=function(w0){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(w0,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(w0,"__esModule",{value:!0})},w2.t=function(w0,w1){if(1&w1&&(w0=w2(w0)),8&w1)return w0;if(4&w1&&"object"==typeof w0&&w0&&w0.__esModule)return w0;var w3=Object.create(null);if(w2.r(w3),Object.defineProperty(w3,"default",{enumerable:!0,value:w0}),2&w1&&"string"!=typeof w0)for(var w4 in w0)w2.d(w3,w4,function(w1){return w0[w1]}.bind(null,w4));return w3},w2.n=function(w0){var w1=w0&&w0.__esModule?function(){return w0.default}:function(){return w0};return w2.d(w1,"a",w1),w1},w2.o=function(w0,w1){return Object.prototype.hasOwnProperty.call(w0,w1)},w2.p="",w2(w2.s=181)}([function(w0,w1,w2){var w3;w0.exports=(w3=w3||function(w0,w1){var w2=Object.create||function(){function w0(){}return function(w1){var w2;return w0.prototype=w1,w2=new w0,w0.prototype=null,w2}}(),w3={},w4=w3.lib={},w5=w4.Base={extend:function(w0){var w1=w2(this);return w0&&w1.mixIn(w0),w1.hasOwnProperty("init")&&this.init!==w1.init||(w1.init=function(){w1.$super.init.apply(this,arguments)}),w1.init.prototype=w1,w1.$super=this,w1},create:function(){var w0=this.extend();return w0.init.apply(w0,arguments),w0},init:function(){},mixIn:function(w0){for(var w1 in w0)w0.hasOwnProperty(w1)&&(this[w1]=w0[w1]);w0.hasOwnProperty("toString")&&(this.toString=w0.toString)},clone:function(){return this.init.prototype.extend(this)}},w6=w4.WordArray=w5.extend({init:function(w0,w2){w0=this.words=w0||[],this.sigBytes=w2!=w1?w2:4*w0.length},toString:function(w0){return(w0||w8).stringify(this)},concat:function(w0){var w1=this.words,w2=w0.words,w3=this.sigBytes,w4=w0.sigBytes;if(this.clamp(),w3%4)for(var w5=0;w5>>2]>>>24-w5%4*8&255;w1[w3+w5>>>2]|=w6<<24-(w3+w5)%4*8}else for(w5=0;w5>>2]=w2[w5>>>2];return this.sigBytes+=w4,this},clamp:function(){var w1=this.words,w2=this.sigBytes;w1[w2>>>2]&=4294967295<<32-w2%4*8,w1.length=w0.ceil(w2/4)},clone:function(){var w0=w5.clone.call(this);return w0.words=this.words.slice(0),w0},random:function(w1){for(var w2,w3=[],w4=function(w1){w1=w1;var w2=987654321,w3=4294967295;return function(){var w4=((w2=36969*(65535&w2)+(w2>>16)&w3)<<16)+(w1=18e3*(65535&w1)+(w1>>16)&w3)&w3;return w4/=4294967296,(w4+=.5)*(w0.random()>.5?1:-1)}},w5=0;w5>>2]>>>24-w4%4*8&255;w3.push((w5>>>4).toString(16)),w3.push((15&w5).toString(16))}return w3.join("")},parse:function(w0){for(var w1=w0.length,w2=[],w3=0;w3>>3]|=parseInt(w0.substr(w3,2),16)<<24-w3%8*4;return new w6.init(w2,w1/2)}},w9=w7.Latin1={stringify:function(w0){for(var w1=w0.words,w2=w0.sigBytes,w3=[],w4=0;w4>>2]>>>24-w4%4*8&255;w3.push(String.fromCharCode(w5))}return w3.join("")},parse:function(w0){for(var w1=w0.length,w2=[],w3=0;w3>>2]|=(255&w0.charCodeAt(w3))<<24-w3%4*8;return new w6.init(w2,w1)}},w10=w7.Utf8={stringify:function(w0){try{return decodeURIComponent(escape(w9.stringify(w0)))}catch(w0){throw new Error("Malformed UTF-8 data")}},parse:function(w0){return w9.parse(unescape(encodeURIComponent(w0)))}},w11=w4.BufferedBlockAlgorithm=w5.extend({reset:function(){this._data=new w6.init,this._nDataBytes=0},_append:function(w0){"string"==typeof w0&&(w0=w10.parse(w0)),this._data.concat(w0),this._nDataBytes+=w0.sigBytes},_process:function(w1){var w2=this._data,w3=w2.words,w4=w2.sigBytes,w5=this.blockSize,w7=w4/(4*w5),w8=(w7=w1?w0.ceil(w7):w0.max((0|w7)-this._minBufferSize,0))*w5,w9=w0.min(4*w8,w4);if(w8){for(var w10=0;w10>>2];w0.sigBytes-=w1}},w15=(w2.BlockCipher=w10.extend({cfg:w10.cfg.extend({mode:w13,padding:w14}),reset:function(){w10.reset.call(this);var w0=this.cfg,w1=w0.iv,w2=w0.mode;if(this._xformMode==this._ENC_XFORM_MODE)var w3=w2.createEncryptor;else w3=w2.createDecryptor,this._minBufferSize=1;this._mode&&this._mode.__creator==w3?this._mode.init(this,w1&&w1.words):(this._mode=w3.call(w2,this,w1&&w1.words),this._mode.__creator=w3)},_doProcessBlock:function(w0,w1){this._mode.processBlock(w0,w1)},_doFinalize:function(){var w0=this.cfg.padding;if(this._xformMode==this._ENC_XFORM_MODE){w0.pad(this._data,this.blockSize);var w1=this._process(!0)}else w1=this._process(!0),w0.unpad(w1);return w1},blockSize:4}),w2.CipherParams=w4.extend({init:function(w0){this.mixIn(w0)},toString:function(w0){return(w0||this.formatter).stringify(this)}})),w16=(w1.format={}).OpenSSL={stringify:function(w0){var w1=w0.ciphertext,w2=w0.salt;if(w2)var w3=w5.create([1398893684,1701076831]).concat(w2).concat(w1);else w3=w1;return w3.toString(w8)},parse:function(w0){var w1=w8.parse(w0),w2=w1.words;if(1398893684==w2[0]&&1701076831==w2[1]){var w3=w5.create(w2.slice(2,4));w2.splice(0,4),w1.sigBytes-=16}return w15.create({ciphertext:w1,salt:w3})}},w17=w2.SerializableCipher=w4.extend({cfg:w4.extend({format:w16}),encrypt:function(w0,w1,w2,w3){w3=this.cfg.extend(w3);var w4=w0.createEncryptor(w2,w3),w5=w4.finalize(w1),w6=w4.cfg;return w15.create({ciphertext:w5,key:w2,iv:w6.iv,algorithm:w0,mode:w6.mode,padding:w6.padding,blockSize:w0.blockSize,formatter:w3.format})},decrypt:function(w0,w1,w2,w3){return w3=this.cfg.extend(w3),w1=this._parse(w1,w3.format),w0.createDecryptor(w2,w3).finalize(w1.ciphertext)},_parse:function(w0,w1){return"string"==typeof w0?w1.parse(w0,this):w0}}),w18=(w1.kdf={}).OpenSSL={execute:function(w0,w1,w2,w3){w3||(w3=w5.random(8));var w4=w9.create({keySize:w1+w2}).compute(w0,w3),w6=w5.create(w4.words.slice(w1),4*w2);return w4.sigBytes=4*w1,w15.create({key:w4,iv:w6,salt:w3})}},w19=w2.PasswordBasedCipher=w17.extend({cfg:w17.cfg.extend({kdf:w18}),encrypt:function(w0,w1,w2,w3){var w4=(w3=this.cfg.extend(w3)).kdf.execute(w2,w0.keySize,w0.ivSize);w3.iv=w4.iv;var w5=w17.encrypt.call(this,w0,w1,w4.key,w3);return w5.mixIn(w4),w5},decrypt:function(w0,w1,w2,w3){w3=this.cfg.extend(w3),w1=this._parse(w1,w3.format);var w4=w3.kdf.execute(w2,w0.keySize,w0.ivSize,w1.salt);return w3.iv=w4.iv,w17.decrypt.call(this,w0,w1,w4.key,w3)}})}()))},function(w0,w1){var w2=w0.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=w2)},function(w0,w1,w2){var w3=w2(70)("wks"),w4=w2(51),w5=w2(4).Symbol,w6="function"==typeof w5;(w0.exports=function(w0){return w3[w0]||(w3[w0]=w6&&w5[w0]||(w6?w5:w4)("Symbol."+w0))}).store=w3},function(w0,w1){var w2,w3,w4=w0.exports={};function w5(){throw new Error("setTimeout has not been defined")}function w6(){throw new Error("clearTimeout has not been defined")}function w7(w0){if(w2===setTimeout)return setTimeout(w0,0);if((w2===w5||!w2)&&setTimeout)return w2=setTimeout,setTimeout(w0,0);try{return w2(w0,0)}catch(w1){try{return w2.call(null,w0,0)}catch(w1){return w2.call(this,w0,0)}}}!function(){try{w2="function"==typeof setTimeout?setTimeout:w5}catch(w0){w2=w5}try{w3="function"==typeof clearTimeout?clearTimeout:w6}catch(w0){w3=w6}}();var w8,w9=[],w10=!1,w11=-1;function w12(){w10&&w8&&(w10=!1,w8.length?w9=w8.concat(w9):w11=-1,w9.length&&w13())}function w13(){if(!w10){var w0=w7(w12);w10=!0;for(var w1=w9.length;w1;){for(w8=w9,w9=[];++w111)for(var w2=1;w2=w6())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+w6().toString(16)+" bytes");return 0|w0}function w14(w0,w1){if(w8.isBuffer(w0))return w0.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(w0)||w0 instanceof ArrayBuffer))return w0.byteLength;"string"!=typeof w0&&(w0=""+w0);var w2=w0.length;if(0===w2)return 0;for(var w3=!1;;)switch(w1){case"ascii":case"latin1":case"binary":return w2;case"utf8":case"utf-8":case void 0:return w41(w0).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*w2;case"hex":return w2>>>1;case"base64":return w42(w0).length;default:if(w3)return w41(w0).length;w1=(""+w1).toLowerCase(),w3=!0}}function w15(w0,w1,w2){var w3=!1;if((void 0===w1||w1<0)&&(w1=0),w1>this.length)return"";if((void 0===w2||w2>this.length)&&(w2=this.length),w2<=0)return"";if((w2>>>=0)<=(w1>>>=0))return"";for(w0||(w0="utf8");;)switch(w0){case"hex":return w30(this,w1,w2);case"utf8":case"utf-8":return w26(this,w1,w2);case"ascii":return w28(this,w1,w2);case"latin1":case"binary":return w29(this,w1,w2);case"base64":return w25(this,w1,w2);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return w31(this,w1,w2);default:if(w3)throw new TypeError("Unknown encoding: "+w0);w0=(w0+"").toLowerCase(),w3=!0}}function w16(w0,w1,w2){var w3=w0[w1];w0[w1]=w0[w2],w0[w2]=w3}function w17(w0,w1,w2,w3,w4){if(0===w0.length)return-1;if("string"==typeof w2?(w3=w2,w2=0):w2>2147483647?w2=2147483647:w2<-2147483648&&(w2=-2147483648),w2=+w2,isNaN(w2)&&(w2=w4?0:w0.length-1),w2<0&&(w2=w0.length+w2),w2>=w0.length){if(w4)return-1;w2=w0.length-1}else if(w2<0){if(!w4)return-1;w2=0}if("string"==typeof w1&&(w1=w8.from(w1,w3)),w8.isBuffer(w1))return 0===w1.length?-1:w18(w0,w1,w2,w3,w4);if("number"==typeof w1)return w1&=255,w8.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?w4?Uint8Array.prototype.indexOf.call(w0,w1,w2):Uint8Array.prototype.lastIndexOf.call(w0,w1,w2):w18(w0,[w1],w2,w3,w4);throw new TypeError("val must be string, number or Buffer")}function w18(w0,w1,w2,w3,w4){var w5,w6=1,w7=w0.length,w8=w1.length;if(void 0!==w3&&("ucs2"===(w3=String(w3).toLowerCase())||"ucs-2"===w3||"utf16le"===w3||"utf-16le"===w3)){if(w0.length<2||w1.length<2)return-1;w6=2,w7/=2,w8/=2,w2/=2}function w9(w0,w1){return 1===w6?w0[w1]:w0.readUInt16BE(w1*w6)}if(w4){var w10=-1;for(w5=w2;w5w7&&(w2=w7-w8),w5=w2;w5>=0;w5--){for(var w11=!0,w12=0;w12w4&&(w3=w4):w3=w4;var w5=w1.length;if(w5%2!=0)throw new TypeError("Invalid hex string");w3>w5/2&&(w3=w5/2);for(var w6=0;w6>8,w4=w2%256,w5.push(w4),w5.push(w3);return w5}(w1,w0.length-w2),w0,w2,w3)}function w25(w0,w1,w2){return 0===w1&&w2===w0.length?w3.fromByteArray(w0):w3.fromByteArray(w0.slice(w1,w2))}function w26(w0,w1,w2){w2=Math.min(w0.length,w2);for(var w3=[],w4=w1;w4239?4:w9>223?3:w9>191?2:1;if(w4+w11<=w2)switch(w11){case 1:w9<128&&(w10=w9);break;case 2:128==(192&(w5=w0[w4+1]))&&(w8=(31&w9)<<6|63&w5)>127&&(w10=w8);break;case 3:w5=w0[w4+1],w6=w0[w4+2],128==(192&w5)&&128==(192&w6)&&(w8=(15&w9)<<12|(63&w5)<<6|63&w6)>2047&&(w8<55296||w8>57343)&&(w10=w8);break;case 4:w5=w0[w4+1],w6=w0[w4+2],w7=w0[w4+3],128==(192&w5)&&128==(192&w6)&&128==(192&w7)&&(w8=(15&w9)<<18|(63&w5)<<12|(63&w6)<<6|63&w7)>65535&&w8<1114112&&(w10=w8)}null===w10?(w10=65533,w11=1):w10>65535&&(w10-=65536,w3.push(w10>>>10&1023|55296),w10=56320|1023&w10),w3.push(w10),w4+=w11}return function(w0){var w1=w0.length;if(w1<=w27)return String.fromCharCode.apply(String,w0);var w2="",w3=0;for(;w30&&(w0=this.toString("hex",0,w2).match(/.{2}/g).join(" "),this.length>w2&&(w0+=" ... ")),""},w8.prototype.compare=function(w0,w1,w2,w3,w4){if(!w8.isBuffer(w0))throw new TypeError("Argument must be a Buffer");if(void 0===w1&&(w1=0),void 0===w2&&(w2=w0?w0.length:0),void 0===w3&&(w3=0),void 0===w4&&(w4=this.length),w1<0||w2>w0.length||w3<0||w4>this.length)throw new RangeError("out of range index");if(w3>=w4&&w1>=w2)return 0;if(w3>=w4)return-1;if(w1>=w2)return 1;if(this===w0)return 0;for(var w5=(w4>>>=0)-(w3>>>=0),w6=(w2>>>=0)-(w1>>>=0),w7=Math.min(w5,w6),w9=this.slice(w3,w4),w10=w0.slice(w1,w2),w11=0;w11w4)&&(w2=w4),w0.length>0&&(w2<0||w1<0)||w1>this.length)throw new RangeError("Attempt to write outside buffer bounds");w3||(w3="utf8");for(var w5=!1;;)switch(w3){case"hex":return w19(this,w0,w1,w2);case"utf8":case"utf-8":return w20(this,w0,w1,w2);case"ascii":return w21(this,w0,w1,w2);case"latin1":case"binary":return w22(this,w0,w1,w2);case"base64":return w23(this,w0,w1,w2);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return w24(this,w0,w1,w2);default:if(w5)throw new TypeError("Unknown encoding: "+w3);w3=(""+w3).toLowerCase(),w5=!0}},w8.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var w27=4096;function w28(w0,w1,w2){var w3="";w2=Math.min(w0.length,w2);for(var w4=w1;w4w3)&&(w2=w3);for(var w4="",w5=w1;w5w2)throw new RangeError("Trying to access beyond buffer length")}function w33(w0,w1,w2,w3,w4,w5){if(!w8.isBuffer(w0))throw new TypeError('"buffer" argument must be a Buffer instance');if(w1>w4||w1w0.length)throw new RangeError("Index out of range")}function w34(w0,w1,w2,w3){w1<0&&(w1=65535+w1+1);for(var w4=0,w5=Math.min(w0.length-w2,2);w4>>8*(w3?w4:1-w4)}function w35(w0,w1,w2,w3){w1<0&&(w1=4294967295+w1+1);for(var w4=0,w5=Math.min(w0.length-w2,4);w4>>8*(w3?w4:3-w4)&255}function w36(w0,w1,w2,w3,w4,w5){if(w2+w3>w0.length)throw new RangeError("Index out of range");if(w2<0)throw new RangeError("Index out of range")}function w37(w0,w1,w2,w3,w5){return w5||w36(w0,0,w2,4),w4.write(w0,w1,w2,w3,23,4),w2+4}function w38(w0,w1,w2,w3,w5){return w5||w36(w0,0,w2,8),w4.write(w0,w1,w2,w3,52,8),w2+8}w8.prototype.slice=function(w0,w1){var w2,w3=this.length;if((w0=~~w0)<0?(w0+=w3)<0&&(w0=0):w0>w3&&(w0=w3),(w1=void 0===w1?w3:~~w1)<0?(w1+=w3)<0&&(w1=0):w1>w3&&(w1=w3),w10&&(w4*=256);)w3+=this[w0+--w1]*w4;return w3},w8.prototype.readUInt8=function(w0,w1){return w1||w32(w0,1,this.length),this[w0]},w8.prototype.readUInt16LE=function(w0,w1){return w1||w32(w0,2,this.length),this[w0]|this[w0+1]<<8},w8.prototype.readUInt16BE=function(w0,w1){return w1||w32(w0,2,this.length),this[w0]<<8|this[w0+1]},w8.prototype.readUInt32LE=function(w0,w1){return w1||w32(w0,4,this.length),(this[w0]|this[w0+1]<<8|this[w0+2]<<16)+16777216*this[w0+3]},w8.prototype.readUInt32BE=function(w0,w1){return w1||w32(w0,4,this.length),16777216*this[w0]+(this[w0+1]<<16|this[w0+2]<<8|this[w0+3])},w8.prototype.readIntLE=function(w0,w1,w2){w0|=0,w1|=0,w2||w32(w0,w1,this.length);for(var w3=this[w0],w4=1,w5=0;++w5=(w4*=128)&&(w3-=Math.pow(2,8*w1)),w3},w8.prototype.readIntBE=function(w0,w1,w2){w0|=0,w1|=0,w2||w32(w0,w1,this.length);for(var w3=w1,w4=1,w5=this[w0+--w3];w3>0&&(w4*=256);)w5+=this[w0+--w3]*w4;return w5>=(w4*=128)&&(w5-=Math.pow(2,8*w1)),w5},w8.prototype.readInt8=function(w0,w1){return w1||w32(w0,1,this.length),128&this[w0]?-1*(255-this[w0]+1):this[w0]},w8.prototype.readInt16LE=function(w0,w1){w1||w32(w0,2,this.length);var w2=this[w0]|this[w0+1]<<8;return 32768&w2?4294901760|w2:w2},w8.prototype.readInt16BE=function(w0,w1){w1||w32(w0,2,this.length);var w2=this[w0+1]|this[w0]<<8;return 32768&w2?4294901760|w2:w2},w8.prototype.readInt32LE=function(w0,w1){return w1||w32(w0,4,this.length),this[w0]|this[w0+1]<<8|this[w0+2]<<16|this[w0+3]<<24},w8.prototype.readInt32BE=function(w0,w1){return w1||w32(w0,4,this.length),this[w0]<<24|this[w0+1]<<16|this[w0+2]<<8|this[w0+3]},w8.prototype.readFloatLE=function(w0,w1){return w1||w32(w0,4,this.length),w4.read(this,w0,!0,23,4)},w8.prototype.readFloatBE=function(w0,w1){return w1||w32(w0,4,this.length),w4.read(this,w0,!1,23,4)},w8.prototype.readDoubleLE=function(w0,w1){return w1||w32(w0,8,this.length),w4.read(this,w0,!0,52,8)},w8.prototype.readDoubleBE=function(w0,w1){return w1||w32(w0,8,this.length),w4.read(this,w0,!1,52,8)},w8.prototype.writeUIntLE=function(w0,w1,w2,w3){(w0=+w0,w1|=0,w2|=0,w3)||w33(this,w0,w1,w2,Math.pow(2,8*w2)-1,0);var w4=1,w5=0;for(this[w1]=255&w0;++w5=0&&(w5*=256);)this[w1+w4]=w0/w5&255;return w1+w2},w8.prototype.writeUInt8=function(w0,w1,w2){return w0=+w0,w1|=0,w2||w33(this,w0,w1,1,255,0),w8.TYPED_ARRAY_SUPPORT||(w0=Math.floor(w0)),this[w1]=255&w0,w1+1},w8.prototype.writeUInt16LE=function(w0,w1,w2){return w0=+w0,w1|=0,w2||w33(this,w0,w1,2,65535,0),w8.TYPED_ARRAY_SUPPORT?(this[w1]=255&w0,this[w1+1]=w0>>>8):w34(this,w0,w1,!0),w1+2},w8.prototype.writeUInt16BE=function(w0,w1,w2){return w0=+w0,w1|=0,w2||w33(this,w0,w1,2,65535,0),w8.TYPED_ARRAY_SUPPORT?(this[w1]=w0>>>8,this[w1+1]=255&w0):w34(this,w0,w1,!1),w1+2},w8.prototype.writeUInt32LE=function(w0,w1,w2){return w0=+w0,w1|=0,w2||w33(this,w0,w1,4,4294967295,0),w8.TYPED_ARRAY_SUPPORT?(this[w1+3]=w0>>>24,this[w1+2]=w0>>>16,this[w1+1]=w0>>>8,this[w1]=255&w0):w35(this,w0,w1,!0),w1+4},w8.prototype.writeUInt32BE=function(w0,w1,w2){return w0=+w0,w1|=0,w2||w33(this,w0,w1,4,4294967295,0),w8.TYPED_ARRAY_SUPPORT?(this[w1]=w0>>>24,this[w1+1]=w0>>>16,this[w1+2]=w0>>>8,this[w1+3]=255&w0):w35(this,w0,w1,!1),w1+4},w8.prototype.writeIntLE=function(w0,w1,w2,w3){if(w0=+w0,w1|=0,!w3){var w4=Math.pow(2,8*w2-1);w33(this,w0,w1,w2,w4-1,-w4)}var w5=0,w6=1,w7=0;for(this[w1]=255&w0;++w5>0)-w7&255;return w1+w2},w8.prototype.writeIntBE=function(w0,w1,w2,w3){if(w0=+w0,w1|=0,!w3){var w4=Math.pow(2,8*w2-1);w33(this,w0,w1,w2,w4-1,-w4)}var w5=w2-1,w6=1,w7=0;for(this[w1+w5]=255&w0;--w5>=0&&(w6*=256);)w0<0&&0===w7&&0!==this[w1+w5+1]&&(w7=1),this[w1+w5]=(w0/w6>>0)-w7&255;return w1+w2},w8.prototype.writeInt8=function(w0,w1,w2){return w0=+w0,w1|=0,w2||w33(this,w0,w1,1,127,-128),w8.TYPED_ARRAY_SUPPORT||(w0=Math.floor(w0)),w0<0&&(w0=255+w0+1),this[w1]=255&w0,w1+1},w8.prototype.writeInt16LE=function(w0,w1,w2){return w0=+w0,w1|=0,w2||w33(this,w0,w1,2,32767,-32768),w8.TYPED_ARRAY_SUPPORT?(this[w1]=255&w0,this[w1+1]=w0>>>8):w34(this,w0,w1,!0),w1+2},w8.prototype.writeInt16BE=function(w0,w1,w2){return w0=+w0,w1|=0,w2||w33(this,w0,w1,2,32767,-32768),w8.TYPED_ARRAY_SUPPORT?(this[w1]=w0>>>8,this[w1+1]=255&w0):w34(this,w0,w1,!1),w1+2},w8.prototype.writeInt32LE=function(w0,w1,w2){return w0=+w0,w1|=0,w2||w33(this,w0,w1,4,2147483647,-2147483648),w8.TYPED_ARRAY_SUPPORT?(this[w1]=255&w0,this[w1+1]=w0>>>8,this[w1+2]=w0>>>16,this[w1+3]=w0>>>24):w35(this,w0,w1,!0),w1+4},w8.prototype.writeInt32BE=function(w0,w1,w2){return w0=+w0,w1|=0,w2||w33(this,w0,w1,4,2147483647,-2147483648),w0<0&&(w0=4294967295+w0+1),w8.TYPED_ARRAY_SUPPORT?(this[w1]=w0>>>24,this[w1+1]=w0>>>16,this[w1+2]=w0>>>8,this[w1+3]=255&w0):w35(this,w0,w1,!1),w1+4},w8.prototype.writeFloatLE=function(w0,w1,w2){return w37(this,w0,w1,!0,w2)},w8.prototype.writeFloatBE=function(w0,w1,w2){return w37(this,w0,w1,!1,w2)},w8.prototype.writeDoubleLE=function(w0,w1,w2){return w38(this,w0,w1,!0,w2)},w8.prototype.writeDoubleBE=function(w0,w1,w2){return w38(this,w0,w1,!1,w2)},w8.prototype.copy=function(w0,w1,w2,w3){if(w2||(w2=0),w3||0===w3||(w3=this.length),w1>=w0.length&&(w1=w0.length),w1||(w1=0),w3>0&&w3=this.length)throw new RangeError("sourceStart out of bounds");if(w3<0)throw new RangeError("sourceEnd out of bounds");w3>this.length&&(w3=this.length),w0.length-w1=0;--w4)w0[w4+w1]=this[w4+w2];else if(w5<1e3||!w8.TYPED_ARRAY_SUPPORT)for(w4=0;w4>>=0,w2=void 0===w2?this.length:w2>>>0,w0||(w0=0),"number"==typeof w0)for(w5=w1;w555295&&w2<57344){if(!w4){if(w2>56319){(w1-=3)>-1&&w5.push(239,191,189);continue}if(w6+1===w3){(w1-=3)>-1&&w5.push(239,191,189);continue}w4=w2;continue}if(w2<56320){(w1-=3)>-1&&w5.push(239,191,189),w4=w2;continue}w2=65536+(w4-55296<<10|w2-56320)}else w4&&(w1-=3)>-1&&w5.push(239,191,189);if(w4=null,w2<128){if((w1-=1)<0)break;w5.push(w2)}else if(w2<2048){if((w1-=2)<0)break;w5.push(w2>>6|192,63&w2|128)}else if(w2<65536){if((w1-=3)<0)break;w5.push(w2>>12|224,w2>>6&63|128,63&w2|128)}else{if(!(w2<1114112))throw new Error("Invalid code point");if((w1-=4)<0)break;w5.push(w2>>18|240,w2>>12&63|128,w2>>6&63|128,63&w2|128)}}return w5}function w42(w0){return w3.toByteArray(function(w0){if((w0=function(w0){return w0.trim?w0.trim():w0.replace(/^\s+|\s+$/g,"")}(w0).replace(w39,"")).length<2)return"";for(;w0.length%4!=0;)w0+="=";return w0}(w0))}function w43(w0,w1,w2,w3){for(var w4=0;w4=w1.length||w4>=w0.length);++w4)w1[w4+w2]=w0[w4];return w4}}).call(this,w2(12))},function(w0,w1,w2){var w3=w2(37);w0.exports=function(w0,w1,w2){if(w3(w0),void 0===w1)return w0;switch(w2){case 1:return function(w2){return w0.call(w1,w2)};case 2:return function(w2,w3){return w0.call(w1,w2,w3)};case 3:return function(w2,w3,w4){return w0.call(w1,w2,w3,w4)}}return function(){return w0.apply(w1,arguments)}}},function(w0,w1,w2){var w3=w2(9),w4=w2(38);w0.exports=w2(8)?function(w0,w1,w2){return w3.f(w0,w1,w4(1,w2))}:function(w0,w1,w2){return w0[w1]=w2,w0}},function(w0,w1,w2){"use strict";w0.exports=w2(304)()?w2(59).Symbol:w2(305)},function(w0,w1,w2){"use strict";var w3="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;function w4(w0,w1){return Object.prototype.hasOwnProperty.call(w0,w1)}w1.assign=function(w0){for(var w1=Array.prototype.slice.call(arguments,1);w1.length;){var w2=w1.shift();if(w2){if("object"!=typeof w2)throw new TypeError(w2+"must be non-object");for(var w3 in w2)w4(w2,w3)&&(w0[w3]=w2[w3])}}return w0},w1.shrinkBuf=function(w0,w1){return w0.length===w1?w0:w0.subarray?w0.subarray(0,w1):(w0.length=w1,w0)};var w5={arraySet:function(w0,w1,w2,w3,w4){if(w1.subarray&&w0.subarray)w0.set(w1.subarray(w2,w2+w3),w4);else for(var w5=0;w5=w1.length?{value:void 0,done:!0}:(w0=w3(w1,w2),this._i+=w0.length,{value:w0,done:!1})}))},function(w0,w1,w2){var w3=w2(68),w4=w2(64);w0.exports=function(w0){return w3(w4(w0))}},function(w0,w1,w2){var w3=w2(64);w0.exports=function(w0){return Object(w3(w0))}},function(w0,w1,w2){"use strict";(function(w1){var w3=w5(w2(62)),w4=w5(w2(81));function w5(w0){return w0&&w0.__esModule?w0:{default:w0}}var w6=w2(226),w7=w2(250).sm4,w8=[0,17,34,51,68,85,102,119,120,121,122,123,124,125,126,127],w9=!1;function w10(w0){var w2=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",w5=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],w10=w8;w2.length>0&&(w10=w13(w2));var w11=new Array;if(w5){var w14=parseInt(((new Date).getTime()/1e3-1514736e3)/3600);w11.push(255&w14),w11.push((65280&w14)>>8),w11.push((16711680&w14)>>16),w11.push(w14>>24)}if("string"==typeof w0){var w17;(w17=w11).push.apply(w17,(0,w4.default)(w15(w0)))}else{var w18=(0,w3.default)(w0);w18.unshift.apply(w18,(0,w4.default)(w11)),w11=w18}var w19=w16(w11);if(w9){var w20=w7.encrypt(w11,w10,{iv:w10,mode:"cbc",padding:"pkcs#5",output:"array"});return w1.from(w20).toString("base64")}w10=w6.enc.Utf8.parse(w12(w10));var w21=w6.AES.encrypt(w6.enc.Hex.parse(w19),w10,{iv:w10,mode:w6.mode.CBC,padding:w6.pad.Pkcs7}),w22=w21.toString();return w22}function w11(w0,w2,w3){var w4,w5=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],w10=w8;if(w2.length>0&&(w10=w13(w2)),w9){var w11=w1.from(w0,"base64");w4=w7.decrypt(w11,w10,{iv:w10,mode:"cbc",padding:"pkcs#5",output:"array"})}else{var w15=w6.enc.Utf8.parse(w12(w10)),w16=w6.AES.decrypt(w0,w15,{iv:w15,mode:w6.mode.CBC,padding:w6.pad.Pkcs7}),w17=w16.toString();w4=w14(w17)}if(w5&&w4.length>4){if(w3){var w18=0;w18+=w4[3]&&255,w18<<=8,w18+=w4[2]&&255,w18<<=8,w18+=w4[1]&&255,w18<<=8,w18+=w4[0]&&255,w18<<=8;var w19=((new Date).getUTCMilliseconds()/1e3-1514736e3)/3600;return w19-w18>24&&w3?null:w4.slice(4,w4.length)}return w4.slice(4,w4.length)}return w4.length>4?w4:null}function w12(w0){for(var w1=0,w2="";w1=65536&&w2<=1114111?(w3.push(w2>>18&7|240),w3.push(w2>>12&63|128),w3.push(w2>>6&63|128),w3.push(63&w2|128)):w2>=2048&&w2<=65535?(w3.push(w2>>12&15|224),w3.push(w2>>6&63|128),w3.push(63&w2|128)):w2>=128&&w2<=2047?(w3.push(w2>>6&31|192),w3.push(63&w2|128)):w3.push(255&w2);return w3}function w16(w0){for(var w1="",w2=0;w2>>6-w6%4*2;w4[w5>>>2]|=(w7|w8)<<24-w5%4*8,w5++}return w1.create(w4,w5)}w0.enc.Base64={stringify:function(w0){var w1=w0.words,w2=w0.sigBytes,w3=this._map;w0.clamp();for(var w4=[],w5=0;w5>>2]>>>24-w5%4*8&255)<<16|(w1[w5+1>>>2]>>>24-(w5+1)%4*8&255)<<8|w1[w5+2>>>2]>>>24-(w5+2)%4*8&255,w7=0;w7<4&&w5+.75*w7>>6*(3-w7)&63));var w8=w3.charAt(64);if(w8)for(;w4.length%4;)w4.push(w8);return w4.join("")},parse:function(w0){var w1=w0.length,w3=this._map,w4=this._reverseMap;if(!w4){w4=this._reverseMap=[];for(var w5=0;w5>>24)|4278255360&(w4<<24|w4>>>8)}var w5=this._hash.words,w6=w0[w1+0],w8=w0[w1+1],w13=w0[w1+2],w14=w0[w1+3],w15=w0[w1+4],w16=w0[w1+5],w17=w0[w1+6],w18=w0[w1+7],w19=w0[w1+8],w20=w0[w1+9],w21=w0[w1+10],w22=w0[w1+11],w23=w0[w1+12],w24=w0[w1+13],w25=w0[w1+14],w26=w0[w1+15],w27=w5[0],w28=w5[1],w29=w5[2],w30=w5[3];w27=w9(w27,w28,w29,w30,w6,7,w7[0]),w30=w9(w30,w27,w28,w29,w8,12,w7[1]),w29=w9(w29,w30,w27,w28,w13,17,w7[2]),w28=w9(w28,w29,w30,w27,w14,22,w7[3]),w27=w9(w27,w28,w29,w30,w15,7,w7[4]),w30=w9(w30,w27,w28,w29,w16,12,w7[5]),w29=w9(w29,w30,w27,w28,w17,17,w7[6]),w28=w9(w28,w29,w30,w27,w18,22,w7[7]),w27=w9(w27,w28,w29,w30,w19,7,w7[8]),w30=w9(w30,w27,w28,w29,w20,12,w7[9]),w29=w9(w29,w30,w27,w28,w21,17,w7[10]),w28=w9(w28,w29,w30,w27,w22,22,w7[11]),w27=w9(w27,w28,w29,w30,w23,7,w7[12]),w30=w9(w30,w27,w28,w29,w24,12,w7[13]),w29=w9(w29,w30,w27,w28,w25,17,w7[14]),w27=w10(w27,w28=w9(w28,w29,w30,w27,w26,22,w7[15]),w29,w30,w8,5,w7[16]),w30=w10(w30,w27,w28,w29,w17,9,w7[17]),w29=w10(w29,w30,w27,w28,w22,14,w7[18]),w28=w10(w28,w29,w30,w27,w6,20,w7[19]),w27=w10(w27,w28,w29,w30,w16,5,w7[20]),w30=w10(w30,w27,w28,w29,w21,9,w7[21]),w29=w10(w29,w30,w27,w28,w26,14,w7[22]),w28=w10(w28,w29,w30,w27,w15,20,w7[23]),w27=w10(w27,w28,w29,w30,w20,5,w7[24]),w30=w10(w30,w27,w28,w29,w25,9,w7[25]),w29=w10(w29,w30,w27,w28,w14,14,w7[26]),w28=w10(w28,w29,w30,w27,w19,20,w7[27]),w27=w10(w27,w28,w29,w30,w24,5,w7[28]),w30=w10(w30,w27,w28,w29,w13,9,w7[29]),w29=w10(w29,w30,w27,w28,w18,14,w7[30]),w27=w11(w27,w28=w10(w28,w29,w30,w27,w23,20,w7[31]),w29,w30,w16,4,w7[32]),w30=w11(w30,w27,w28,w29,w19,11,w7[33]),w29=w11(w29,w30,w27,w28,w22,16,w7[34]),w28=w11(w28,w29,w30,w27,w25,23,w7[35]),w27=w11(w27,w28,w29,w30,w8,4,w7[36]),w30=w11(w30,w27,w28,w29,w15,11,w7[37]),w29=w11(w29,w30,w27,w28,w18,16,w7[38]),w28=w11(w28,w29,w30,w27,w21,23,w7[39]),w27=w11(w27,w28,w29,w30,w24,4,w7[40]),w30=w11(w30,w27,w28,w29,w6,11,w7[41]),w29=w11(w29,w30,w27,w28,w14,16,w7[42]),w28=w11(w28,w29,w30,w27,w17,23,w7[43]),w27=w11(w27,w28,w29,w30,w20,4,w7[44]),w30=w11(w30,w27,w28,w29,w23,11,w7[45]),w29=w11(w29,w30,w27,w28,w26,16,w7[46]),w27=w12(w27,w28=w11(w28,w29,w30,w27,w13,23,w7[47]),w29,w30,w6,6,w7[48]),w30=w12(w30,w27,w28,w29,w18,10,w7[49]),w29=w12(w29,w30,w27,w28,w25,15,w7[50]),w28=w12(w28,w29,w30,w27,w16,21,w7[51]),w27=w12(w27,w28,w29,w30,w23,6,w7[52]),w30=w12(w30,w27,w28,w29,w14,10,w7[53]),w29=w12(w29,w30,w27,w28,w21,15,w7[54]),w28=w12(w28,w29,w30,w27,w8,21,w7[55]),w27=w12(w27,w28,w29,w30,w19,6,w7[56]),w30=w12(w30,w27,w28,w29,w26,10,w7[57]),w29=w12(w29,w30,w27,w28,w17,15,w7[58]),w28=w12(w28,w29,w30,w27,w24,21,w7[59]),w27=w12(w27,w28,w29,w30,w15,6,w7[60]),w30=w12(w30,w27,w28,w29,w22,10,w7[61]),w29=w12(w29,w30,w27,w28,w13,15,w7[62]),w28=w12(w28,w29,w30,w27,w20,21,w7[63]),w5[0]=w5[0]+w27|0,w5[1]=w5[1]+w28|0,w5[2]=w5[2]+w29|0,w5[3]=w5[3]+w30|0},_doFinalize:function(){var w1=this._data,w2=w1.words,w3=8*this._nDataBytes,w4=8*w1.sigBytes;w2[w4>>>5]|=128<<24-w4%32;var w5=w0.floor(w3/4294967296),w6=w3;w2[15+(w4+64>>>9<<4)]=16711935&(w5<<8|w5>>>24)|4278255360&(w5<<24|w5>>>8),w2[14+(w4+64>>>9<<4)]=16711935&(w6<<8|w6>>>24)|4278255360&(w6<<24|w6>>>8),w1.sigBytes=4*(w2.length+1),this._process();for(var w7=this._hash,w8=w7.words,w9=0;w9<4;w9++){var w10=w8[w9];w8[w9]=16711935&(w10<<8|w10>>>24)|4278255360&(w10<<24|w10>>>8)}return w7},clone:function(){var w0=w5.clone.call(this);return w0._hash=this._hash.clone(),w0}});function w9(w0,w1,w2,w3,w4,w5,w6){var w7=w0+(w1&w2|~w1&w3)+w4+w6;return(w7<>>32-w5)+w1}function w10(w0,w1,w2,w3,w4,w5,w6){var w7=w0+(w1&w3|w2&~w3)+w4+w6;return(w7<>>32-w5)+w1}function w11(w0,w1,w2,w3,w4,w5,w6){var w7=w0+(w1^w2^w3)+w4+w6;return(w7<>>32-w5)+w1}function w12(w0,w1,w2,w3,w4,w5,w6){var w7=w0+(w2^(w1|~w3))+w4+w6;return(w7<>>32-w5)+w1}w1.MD5=w5._createHelper(w8),w1.HmacMD5=w5._createHmacHelper(w8)}(Math),w3.MD5)},function(w0,w1,w2){"use strict";w1.__esModule=!0;var w3=w6(w2(258)),w4=w6(w2(260)),w5="function"==typeof w4.default&&"symbol"==typeof w3.default?function(w0){return typeof w0}:function(w0){return w0&&"function"==typeof w4.default&&w0.constructor===w4.default&&w0!==w4.default.prototype?"symbol":typeof w0};function w6(w0){return w0&&w0.__esModule?w0:{default:w0}}w1.default="function"==typeof w4.default&&"symbol"===w5(w3.default)?function(w0){return void 0===w0?"undefined":w5(w0)}:function(w0){return w0&&"function"==typeof w4.default&&w0.constructor===w4.default&&w0!==w4.default.prototype?"symbol":void 0===w0?"undefined":w5(w0)}},function(w0,w1,w2){(w1=w0.exports=w2(133)).Stream=w1,w1.Readable=w1,w1.Writable=w2(136),w1.Duplex=w2(24),w1.Transform=w2(138),w1.PassThrough=w2(279)},function(w0,w1,w2){"use strict";var w3=w2(283)();w0.exports=function(w0){return w0!==w3&&null!==w0}},function(w0,w1,w2){"use strict";w0.exports=function(w0){return null!=w0}},function(w0,w1){w0.exports=!0},function(w0,w1){w0.exports=function(w0){if("function"!=typeof w0)throw TypeError(w0+" is not a function!");return w0}},function(w0,w1){w0.exports=function(w0,w1){return{enumerable:!(1&w0),configurable:!(2&w0),writable:!(4&w0),value:w1}}},function(w0,w1){w0.exports={}},function(w0,w1,w2){var w3=w2(102),w4=w2(71);w0.exports=Object.keys||function(w0){return w3(w0,w4)}},function(w0,w1){var w2={}.toString;w0.exports=function(w0){return w2.call(w0).slice(8,-1)}},function(w0,w1,w2){var w3=w2(9).f,w4=w2(22),w5=w2(5)("toStringTag");w0.exports=function(w0,w1,w2){w0&&!w4(w0=w2?w0:w0.prototype,w5)&&w3(w0,w5,{configurable:!0,value:w1})}},function(w0,w1,w2){w2(192);for(var w3=w2(4),w4=w2(18),w5=w2(39),w6=w2(5)("toStringTag"),w7="CSSRuleList,CSSStyleDeclaration,CSSValueList,ClientRectList,DOMRectList,DOMStringList,DOMTokenList,DataTransferItemList,FileList,HTMLAllCollection,HTMLCollection,HTMLFormElement,HTMLSelectElement,MediaList,MimeTypeArray,NamedNodeMap,NodeList,PaintRequestList,Plugin,PluginArray,SVGLengthList,SVGNumberList,SVGPathSegList,SVGPointList,SVGStringList,SVGTransformList,SourceBufferList,StyleSheetList,TextTrackCueList,TextTrackList,TouchList".split(","),w8=0;w8w19;w19++)if((w16=w1?w18(w6(w14=w0[w19])[0],w14[1]):w18(w0[w19]))===w9||w16===w10)return w16}else for(w15=w17.call(w0);!(w14=w15.next()).done;)if((w16=w4(w15,w18,w14.value,w1))===w9||w16===w10)return w16}).BREAK=w9,w1.RETURN=w10},function(w0,w1,w2){w0.exports={default:w2(271),__esModule:!0}},function(w0,w1,w2){"use strict";var w3,w4="object"==typeof Reflect?Reflect:null,w5=w4&&"function"==typeof w4.apply?w4.apply:function(w0,w1,w2){return Function.prototype.apply.call(w0,w1,w2)};w3=w4&&"function"==typeof w4.ownKeys?w4.ownKeys:Object.getOwnPropertySymbols?function(w0){return Object.getOwnPropertyNames(w0).concat(Object.getOwnPropertySymbols(w0))}:function(w0){return Object.getOwnPropertyNames(w0)};var w6=Number.isNaN||function(w0){return w0!=w0};function w7(){w7.init.call(this)}w0.exports=w7,w7.EventEmitter=w7,w7.prototype._events=void 0,w7.prototype._eventsCount=0,w7.prototype._maxListeners=void 0;var w8=10;function w9(w0){return void 0===w0._maxListeners?w7.defaultMaxListeners:w0._maxListeners}function w10(w0,w1,w2,w3){var w4,w5,w6,w7;if("function"!=typeof w2)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof w2);if(void 0===(w5=w0._events)?(w5=w0._events=Object.create(null),w0._eventsCount=0):(void 0!==w5.newListener&&(w0.emit("newListener",w1,w2.listener?w2.listener:w2),w5=w0._events),w6=w5[w1]),void 0===w6)w6=w5[w1]=w2,++w0._eventsCount;else if("function"==typeof w6?w6=w5[w1]=w3?[w2,w6]:[w6,w2]:w3?w6.unshift(w2):w6.push(w2),(w4=w9(w0))>0&&w6.length>w4&&!w6.warned){w6.warned=!0;var w8=new Error("Possible EventEmitter memory leak detected. "+w6.length+" "+String(w1)+" listeners added. Use emitter.setMaxListeners() to increase limit");w8.name="MaxListenersExceededWarning",w8.emitter=w0,w8.type=w1,w8.count=w6.length,w7=w8,console&&console.warn&&console.warn(w7)}return w0}function w11(){for(var w0=[],w1=0;w10&&(w6=w1[0]),w6 instanceof Error)throw w6;var w7=new Error("Unhandled error."+(w6?" ("+w6.message+")":""));throw w7.context=w6,w7}var w8=w4[w0];if(void 0===w8)return!1;if("function"==typeof w8)w5(w8,this,w1);else{var w9=w8.length,w10=w15(w8,w9);for(w2=0;w2=0;w5--)if(w2[w5]===w1||w2[w5].listener===w1){w6=w2[w5].listener,w4=w5;break}if(w4<0)return this;0===w4?w2.shift():function(w0,w1){for(;w1+1=0;w3--)this.removeListener(w0,w1[w3]);return this},w7.prototype.listeners=function(w0){return w13(this,w0,!0)},w7.prototype.rawListeners=function(w0){return w13(this,w0,!1)},w7.listenerCount=function(w0,w1){return"function"==typeof w0.listenerCount?w0.listenerCount(w1):w14.call(w0,w1)},w7.prototype.listenerCount=w14,w7.prototype.eventNames=function(){return this._eventsCount>0?w3(this._events):[]}},function(w0,w1,w2){"use strict";(function(w1){void 0===w1||!w1.version||0===w1.version.indexOf("v0.")||0===w1.version.indexOf("v1.")&&0!==w1.version.indexOf("v1.8.")?w0.exports={nextTick:function(w0,w2,w3,w4){if("function"!=typeof w0)throw new TypeError('"callback" argument must be a function');var w5,w6,w7=arguments.length;switch(w7){case 0:case 1:return w1.nextTick(w0);case 2:return w1.nextTick((function(){w0.call(null,w2)}));case 3:return w1.nextTick((function(){w0.call(null,w2,w3)}));case 4:return w1.nextTick((function(){w0.call(null,w2,w3,w4)}));default:for(w5=new Array(w7-1),w6=0;w6document.F=Object<\/script>"),w0.close(),w8=w0.F;w3--;)delete w8.prototype[w5[w3]];return w8()};w0.exports=Object.create||function(w0,w1){var w2;return null!==w0?(w7.prototype=w3(w0),w2=new w7,w7.prototype=null,w2[w6]=w0):w2=w8(),void 0===w1?w2:w4(w2,w1)}},function(w0,w1,w2){var w3=w2(63),w4=Math.min;w0.exports=function(w0){return w0>0?w4(w3(w0),9007199254740991):0}},function(w0,w1){var w2=0,w3=Math.random();w0.exports=function(w0){return"Symbol(".concat(void 0===w0?"":w0,")_",(++w2+w3).toString(36))}},function(w0,w1){},function(w0,w1,w2){var w3=w2(51)("meta"),w4=w2(7),w5=w2(22),w6=w2(9).f,w7=0,w8=Object.isExtensible||function(){return!0},w9=!w2(21)((function(){return w8(Object.preventExtensions({}))})),w10=function(w0){w6(w0,w3,{value:{i:"O"+ ++w7,w:{}}})},w11=w0.exports={KEY:w3,NEED:!1,fastKey:function(w0,w1){if(!w4(w0))return"symbol"==typeof w0?w0:("string"==typeof w0?"S":"P")+w0;if(!w5(w0,w3)){if(!w8(w0))return"F";if(!w1)return"E";w10(w0)}return w0[w3].i},getWeak:function(w0,w1){if(!w5(w0,w3)){if(!w8(w0))return!0;if(!w1)return!1;w10(w0)}return w0[w3].w},onFreeze:function(w0){return w9&&w11.NEED&&w8(w0)&&!w5(w0,w3)&&w10(w0),w0}}},function(w0,w1){w1.f={}.propertyIsEnumerable},function(w0,w1,w2){"use strict";w1.__esModule=!0,w1.default=function(w0,w1){if(!(w0 instanceof w1))throw new TypeError("Cannot call a class as a function")}},function(w0,w1,w2){var w3;w0.exports=(w3=w2(0),function(w0){var w1=w3,w2=w1.lib,w4=w2.Base,w5=w2.WordArray,w6=w1.x64={};w6.Word=w4.extend({init:function(w0,w1){this.high=w0,this.low=w1}}),w6.WordArray=w4.extend({init:function(w1,w2){w1=this.words=w1||[],this.sigBytes=w2!=w0?w2:8*w1.length},toX32:function(){for(var w0=this.words,w1=w0.length,w2=[],w3=0;w3>15;--w5>=0;){var w8=32767&this[w0],w9=this[w0++]>>15,w10=w7*w8+w9*w6;w4=((w8=w6*w8+((32767&w10)<<15)+w2[w3]+(1073741823&w4))>>>30)+(w10>>>15)+w7*w9+(w4>>>30),w2[w3++]=1073741823&w8}return w4},w1=30):w4&&"Netscape"!=navigator.appName?(w2.prototype.am=function(w0,w1,w2,w3,w4,w5){for(;--w5>=0;){var w6=w1*this[w0++]+w2[w3]+w4;w4=Math.floor(w6/67108864),w2[w3++]=67108863&w6}return w4},w1=26):(w2.prototype.am=function(w0,w1,w2,w3,w4,w5){for(var w6=16383&w1,w7=w1>>14;--w5>=0;){var w8=16383&this[w0],w9=this[w0++]>>14,w10=w7*w8+w9*w6;w4=((w8=w6*w8+((16383&w10)<<14)+w2[w3]+w4)>>28)+(w10>>14)+w7*w9,w2[w3++]=268435455&w8}return w4},w1=28),w2.prototype.DB=w1,w2.prototype.DM=(1<>>16)&&(w0=w1,w2+=16),0!=(w1=w0>>8)&&(w0=w1,w2+=8),0!=(w1=w0>>4)&&(w0=w1,w2+=4),0!=(w1=w0>>2)&&(w0=w1,w2+=2),0!=(w1=w0>>1)&&(w0=w1,w2+=1),w2}function w12(w0){this.m=w0}function w13(w0){this.m=w0,this.mp=w0.invDigit(),this.mpl=32767&this.mp,this.mph=this.mp>>15,this.um=(1<>=16,w1+=16),0==(255&w0)&&(w0>>=8,w1+=8),0==(15&w0)&&(w0>>=4,w1+=4),0==(3&w0)&&(w0>>=2,w1+=2),0==(1&w0)&&++w1,w1}function w19(w0){for(var w1=0;0!=w0;)w0&=w0-1,++w1;return w1}function w20(){}function w21(w0){return w0}function w22(w0){this.r2=w3(),this.q3=w3(),w2.ONE.dlShiftTo(2*w0.t,this.r2),this.mu=this.r2.divide(w0),this.m=w0}w12.prototype.convert=function(w0){return w0.s<0||w0.compareTo(this.m)>=0?w0.mod(this.m):w0},w12.prototype.revert=function(w0){return w0},w12.prototype.reduce=function(w0){w0.divRemTo(this.m,null,w0)},w12.prototype.mulTo=function(w0,w1,w2){w0.multiplyTo(w1,w2),this.reduce(w2)},w12.prototype.sqrTo=function(w0,w1){w0.squareTo(w1),this.reduce(w1)},w13.prototype.convert=function(w0){var w1=w3();return w0.abs().dlShiftTo(this.m.t,w1),w1.divRemTo(this.m,null,w1),w0.s<0&&w1.compareTo(w2.ZERO)>0&&this.m.subTo(w1,w1),w1},w13.prototype.revert=function(w0){var w1=w3();return w0.copyTo(w1),this.reduce(w1),w1},w13.prototype.reduce=function(w0){for(;w0.t<=this.mt2;)w0[w0.t++]=0;for(var w1=0;w1>15)*this.mpl&this.um)<<15)&w0.DM;for(w0[w2=w1+this.m.t]+=this.m.am(0,w3,w0,w1,0,this.m.t);w0[w2]>=w0.DV;)w0[w2]-=w0.DV,w0[++w2]++}w0.clamp(),w0.drShiftTo(this.m.t,w0),w0.compareTo(this.m)>=0&&w0.subTo(this.m,w0)},w13.prototype.mulTo=function(w0,w1,w2){w0.multiplyTo(w1,w2),this.reduce(w2)},w13.prototype.sqrTo=function(w0,w1){w0.squareTo(w1),this.reduce(w1)},w2.prototype.copyTo=function(w0){for(var w1=this.t-1;w1>=0;--w1)w0[w1]=this[w1];w0.t=this.t,w0.s=this.s},w2.prototype.fromInt=function(w0){this.t=1,this.s=w0<0?-1:0,w0>0?this[0]=w0:w0<-1?this[0]=w0+this.DV:this.t=0},w2.prototype.fromString=function(w0,w1){var w3;if(16==w1)w3=4;else if(8==w1)w3=3;else if(256==w1)w3=8;else if(2==w1)w3=1;else if(32==w1)w3=5;else{if(4!=w1)return void this.fromRadix(w0,w1);w3=2}this.t=0,this.s=0;for(var w4=w0.length,w5=!1,w6=0;--w4>=0;){var w7=8==w3?255&w0[w4]:w9(w0,w4);w7<0?"-"==w0.charAt(w4)&&(w5=!0):(w5=!1,0==w6?this[this.t++]=w7:w6+w3>this.DB?(this[this.t-1]|=(w7&(1<>this.DB-w6):this[this.t-1]|=w7<=this.DB&&(w6-=this.DB))}8==w3&&0!=(128&w0[0])&&(this.s=-1,w6>0&&(this[this.t-1]|=(1<0&&this[this.t-1]==w0;)--this.t},w2.prototype.dlShiftTo=function(w0,w1){var w2;for(w2=this.t-1;w2>=0;--w2)w1[w2+w0]=this[w2];for(w2=w0-1;w2>=0;--w2)w1[w2]=0;w1.t=this.t+w0,w1.s=this.s},w2.prototype.drShiftTo=function(w0,w1){for(var w2=w0;w2=0;--w2)w1[w2+w6+1]=this[w2]>>w4|w7,w7=(this[w2]&w5)<=0;--w2)w1[w2]=0;w1[w6]=w7,w1.t=this.t+w6+1,w1.s=this.s,w1.clamp()},w2.prototype.rShiftTo=function(w0,w1){w1.s=this.s;var w2=Math.floor(w0/this.DB);if(w2>=this.t)w1.t=0;else{var w3=w0%this.DB,w4=this.DB-w3,w5=(1<>w3;for(var w6=w2+1;w6>w3;w3>0&&(w1[this.t-w2-1]|=(this.s&w5)<>=this.DB;if(w0.t>=this.DB;w3+=this.s}else{for(w3+=this.s;w2>=this.DB;w3-=w0.s}w1.s=w3<0?-1:0,w3<-1?w1[w2++]=this.DV+w3:w3>0&&(w1[w2++]=w3),w1.t=w2,w1.clamp()},w2.prototype.multiplyTo=function(w0,w1){var w3=this.abs(),w4=w0.abs(),w5=w3.t;for(w1.t=w5+w4.t;--w5>=0;)w1[w5]=0;for(w5=0;w5=0;)w0[w2]=0;for(w2=0;w2=w1.DV&&(w0[w2+w1.t]-=w1.DV,w0[w2+w1.t+1]=1)}w0.t>0&&(w0[w0.t-1]+=w1.am(w2,w1[w2],w0,2*w2,0,1)),w0.s=0,w0.clamp()},w2.prototype.divRemTo=function(w0,w1,w4){var w5=w0.abs();if(!(w5.t<=0)){var w6=this.abs();if(w6.t0?(w5.lShiftTo(w10,w7),w6.lShiftTo(w10,w4)):(w5.copyTo(w7),w6.copyTo(w4));var w12=w7.t,w13=w7[w12-1];if(0!=w13){var w14=w13*(1<1?w7[w12-2]>>this.F2:0),w15=this.FV/w14,w16=(1<=0&&(w4[w4.t++]=1,w4.subTo(w20,w4)),w2.ONE.dlShiftTo(w12,w20),w20.subTo(w7,w7);w7.t=0;){var w21=w4[--w18]==w13?this.DM:Math.floor(w4[w18]*w15+(w4[w18-1]+w17)*w16);if((w4[w18]+=w7.am(0,w21,w4,w19,0,w12))0&&w4.rShiftTo(w10,w4),w8<0&&w2.ZERO.subTo(w4,w4)}}},w2.prototype.invDigit=function(){if(this.t<1)return 0;var w0=this[0];if(0==(1&w0))return 0;var w1=3&w0;return(w1=(w1=(w1=(w1=w1*(2-(15&w0)*w1)&15)*(2-(255&w0)*w1)&255)*(2-((65535&w0)*w1&65535))&65535)*(2-w0*w1%this.DV)%this.DV)>0?this.DV-w1:-w1},w2.prototype.isEven=function(){return 0==(this.t>0?1&this[0]:this.s)},w2.prototype.exp=function(w0,w1){if(w0>4294967295||w0<1)return w2.ONE;var w4=w3(),w5=w3(),w6=w1.convert(this),w7=w11(w0)-1;for(w6.copyTo(w4);--w7>=0;)if(w1.sqrTo(w4,w5),(w0&1<0)w1.mulTo(w5,w6,w4);else{var w8=w4;w4=w5,w5=w8}return w1.revert(w4)},w2.prototype.toString=function(w0){if(this.s<0)return"-"+this.negate().toString(w0);var w1;if(16==w0)w1=4;else if(8==w0)w1=3;else if(2==w0)w1=1;else if(32==w0)w1=5;else{if(4!=w0)return this.toRadix(w0);w1=2}var w2,w3=(1<0)for(w7>w7)>0&&(w4=!0,w5=w8(w2));w6>=0;)w7>(w7+=this.DB-w1)):(w2=this[w6]>>(w7-=w1)&w3,w7<=0&&(w7+=this.DB,--w6)),w2>0&&(w4=!0),w4&&(w5+=w8(w2));return w4?w5:"0"},w2.prototype.negate=function(){var w0=w3();return w2.ZERO.subTo(this,w0),w0},w2.prototype.abs=function(){return this.s<0?this.negate():this},w2.prototype.compareTo=function(w0){var w1=this.s-w0.s;if(0!=w1)return w1;var w2=this.t;if(0!=(w1=w2-w0.t))return this.s<0?-w1:w1;for(;--w2>=0;)if(0!=(w1=this[w2]-w0[w2]))return w1;return 0},w2.prototype.bitLength=function(){return this.t<=0?0:this.DB*(this.t-1)+w11(this[this.t-1]^this.s&this.DM)},w2.prototype.mod=function(w0){var w1=w3();return this.abs().divRemTo(w0,null,w1),this.s<0&&w1.compareTo(w2.ZERO)>0&&w0.subTo(w1,w1),w1},w2.prototype.modPowInt=function(w0,w1){var w2;return w2=w0<256||w1.isEven()?new w12(w1):new w13(w1),this.exp(w0,w2)},w2.ZERO=w10(0),w2.ONE=w10(1),w20.prototype.convert=w21,w20.prototype.revert=w21,w20.prototype.mulTo=function(w0,w1,w2){w0.multiplyTo(w1,w2)},w20.prototype.sqrTo=function(w0,w1){w0.squareTo(w1)},w22.prototype.convert=function(w0){if(w0.s<0||w0.t>2*this.m.t)return w0.mod(this.m);if(w0.compareTo(this.m)<0)return w0;var w1=w3();return w0.copyTo(w1),this.reduce(w1),w1},w22.prototype.revert=function(w0){return w0},w22.prototype.reduce=function(w0){for(w0.drShiftTo(this.m.t-1,this.r2),w0.t>this.m.t+1&&(w0.t=this.m.t+1,w0.clamp()),this.mu.multiplyUpperTo(this.r2,this.m.t+1,this.q3),this.m.multiplyLowerTo(this.q3,this.m.t+1,this.r2);w0.compareTo(this.r2)<0;)w0.dAddOffset(1,this.m.t+1);for(w0.subTo(this.r2,w0);w0.compareTo(this.m)>=0;)w0.subTo(this.m,w0)},w22.prototype.mulTo=function(w0,w1,w2){w0.multiplyTo(w1,w2),this.reduce(w2)},w22.prototype.sqrTo=function(w0,w1){w0.squareTo(w1),this.reduce(w1)};var w23,w24,w25,w26=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47,53,59,61,67,71,73,79,83,89,97,101,103,107,109,113,127,131,137,139,149,151,157,163,167,173,179,181,191,193,197,199,211,223,227,229,233,239,241,251,257,263,269,271,277,281,283,293,307,311,313,317,331,337,347,349,353,359,367,373,379,383,389,397,401,409,419,421,431,433,439,443,449,457,461,463,467,479,487,491,499,503,509,521,523,541,547,557,563,569,571,577,587,593,599,601,607,613,617,619,631,641,643,647,653,659,661,673,677,683,691,701,709,719,727,733,739,743,751,757,761,769,773,787,797,809,811,821,823,827,829,839,853,857,859,863,877,881,883,887,907,911,919,929,937,941,947,953,967,971,977,983,991,997],w27=(1<<26)/w26[w26.length-1];function w28(){var w0;w0=(new Date).getTime(),w24[w25++]^=255&w0,w24[w25++]^=w0>>8&255,w24[w25++]^=w0>>16&255,w24[w25++]^=w0>>24&255,w25>=w35&&(w25-=w35)}if(w2.prototype.chunkSize=function(w0){return Math.floor(Math.LN2*this.DB/Math.log(w0))},w2.prototype.toRadix=function(w0){if(null==w0&&(w0=10),0==this.signum()||w0<2||w0>36)return"0";var w1=this.chunkSize(w0),w2=Math.pow(w0,w1),w4=w10(w2),w5=w3(),w6=w3(),w7="";for(this.divRemTo(w4,w5,w6);w5.signum()>0;)w7=(w2+w6.intValue()).toString(w0).substr(1)+w7,w5.divRemTo(w4,w5,w6);return w6.intValue().toString(w0)+w7},w2.prototype.fromRadix=function(w0,w1){this.fromInt(0),null==w1&&(w1=10);for(var w3=this.chunkSize(w1),w4=Math.pow(w1,w3),w5=!1,w6=0,w7=0,w8=0;w8=w3&&(this.dMultiply(w4),this.dAddOffset(w7,0),w6=0,w7=0))}w6>0&&(this.dMultiply(Math.pow(w1,w6)),this.dAddOffset(w7,0)),w5&&w2.ZERO.subTo(this,this)},w2.prototype.fromNumber=function(w0,w1,w3){if("number"==typeof w1)if(w0<2)this.fromInt(1);else for(this.fromNumber(w0,w3),this.testBit(w0-1)||this.bitwiseTo(w2.ONE.shiftLeft(w0-1),w15,this),this.isEven()&&this.dAddOffset(1,0);!this.isProbablePrime(w1);)this.dAddOffset(2,0),this.bitLength()>w0&&this.subTo(w2.ONE.shiftLeft(w0-1),this);else{var w4=new Array,w5=7&w0;w4.length=1+(w0>>3),w1.nextBytes(w4),w5>0?w4[0]&=(1<>=this.DB;if(w0.t>=this.DB;w3+=this.s}else{for(w3+=this.s;w2>=this.DB;w3+=w0.s}w1.s=w3<0?-1:0,w3>0?w1[w2++]=w3:w3<-1&&(w1[w2++]=this.DV+w3),w1.t=w2,w1.clamp()},w2.prototype.dMultiply=function(w0){this[this.t]=this.am(0,w0-1,this,0,0,this.t),++this.t,this.clamp()},w2.prototype.dAddOffset=function(w0,w1){if(0!=w0){for(;this.t<=w1;)this[this.t++]=0;for(this[w1]+=w0;this[w1]>=this.DV;)this[w1]-=this.DV,++w1>=this.t&&(this[this.t++]=0),++this[w1]}},w2.prototype.multiplyLowerTo=function(w0,w1,w2){var w3,w4=Math.min(this.t+w0.t,w1);for(w2.s=0,w2.t=w4;w4>0;)w2[--w4]=0;for(w3=w2.t-this.t;w4=0;)w2[w3]=0;for(w3=Math.max(w1-this.t,0);w30)if(0==w1)w2=this[0]%w0;else for(var w3=this.t-1;w3>=0;--w3)w2=(w1*w2+this[w3])%w0;return w2},w2.prototype.millerRabin=function(w0){var w1=this.subtract(w2.ONE),w4=w1.getLowestSetBit();if(w4<=0)return!1;var w5=w1.shiftRight(w4);(w0=w0+1>>1)>w26.length&&(w0=w26.length);for(var w6=w3(),w7=0;w7>24},w2.prototype.shortValue=function(){return 0==this.t?this.s:this[0]<<16>>16},w2.prototype.signum=function(){return this.s<0?-1:this.t<=0||1==this.t&&this[0]<=0?0:1},w2.prototype.toByteArray=function(){var w0=this.t,w1=new Array;w1[0]=this.s;var w2,w3=this.DB-w0*this.DB%8,w4=0;if(w0-- >0)for(w3>w3)!=(this.s&this.DM)>>w3&&(w1[w4++]=w2|this.s<=0;)w3<8?(w2=(this[w0]&(1<>(w3+=this.DB-8)):(w2=this[w0]>>(w3-=8)&255,w3<=0&&(w3+=this.DB,--w0)),0!=(128&w2)&&(w2|=-256),0==w4&&(128&this.s)!=(128&w2)&&++w4,(w4>0||w2!=this.s)&&(w1[w4++]=w2);return w1},w2.prototype.equals=function(w0){return 0==this.compareTo(w0)},w2.prototype.min=function(w0){return this.compareTo(w0)<0?this:w0},w2.prototype.max=function(w0){return this.compareTo(w0)>0?this:w0},w2.prototype.and=function(w0){var w1=w3();return this.bitwiseTo(w0,w14,w1),w1},w2.prototype.or=function(w0){var w1=w3();return this.bitwiseTo(w0,w15,w1),w1},w2.prototype.xor=function(w0){var w1=w3();return this.bitwiseTo(w0,w16,w1),w1},w2.prototype.andNot=function(w0){var w1=w3();return this.bitwiseTo(w0,w17,w1),w1},w2.prototype.not=function(){for(var w0=w3(),w1=0;w1=this.t?0!=this.s:0!=(this[w1]&1<1){var w15=w3();for(w4.sqrTo(w7[1],w15);w8<=w14;)w7[w8]=w3(),w4.mulTo(w15,w7[w8-2],w7[w8]),w8+=2}var w16,w17,w18=w0.t-1,w19=!0,w20=w3();for(w5=w11(w0[w18])-1;w18>=0;){for(w5>=w9?w16=w0[w18]>>w5-w9&w14:(w16=(w0[w18]&(1<0&&(w16|=w0[w18-1]>>this.DB+w5-w9)),w8=w2;0==(1&w16);)w16>>=1,--w8;if((w5-=w8)<0&&(w5+=this.DB,--w18),w19)w7[w16].copyTo(w6),w19=!1;else{for(;w8>1;)w4.sqrTo(w6,w20),w4.sqrTo(w20,w6),w8-=2;w8>0?w4.sqrTo(w6,w20):(w17=w6,w6=w20,w20=w17),w4.mulTo(w20,w7[w16],w6)}for(;w18>=0&&0==(w0[w18]&1<=0?(w3.subTo(w4,w3),w1&&w5.subTo(w7,w5),w6.subTo(w8,w6)):(w4.subTo(w3,w4),w1&&w7.subTo(w5,w7),w8.subTo(w6,w8))}return 0!=w4.compareTo(w2.ONE)?w2.ZERO:w8.compareTo(w0)>=0?w8.subtract(w0):w8.signum()<0?(w8.addTo(w0,w8),w8.signum()<0?w8.add(w0):w8):w8},w2.prototype.pow=function(w0){return this.exp(w0,new w20)},w2.prototype.gcd=function(w0){var w1=this.s<0?this.negate():this.clone(),w2=w0.s<0?w0.negate():w0.clone();if(w1.compareTo(w2)<0){var w3=w1;w1=w2,w2=w3}var w4=w1.getLowestSetBit(),w5=w2.getLowestSetBit();if(w5<0)return w1;for(w40&&(w1.rShiftTo(w5,w1),w2.rShiftTo(w5,w2));w1.signum()>0;)(w4=w1.getLowestSetBit())>0&&w1.rShiftTo(w4,w1),(w4=w2.getLowestSetBit())>0&&w2.rShiftTo(w4,w2),w1.compareTo(w2)>=0?(w1.subTo(w2,w1),w1.rShiftTo(1,w1)):(w2.subTo(w1,w2),w2.rShiftTo(1,w2));return w5>0&&w2.lShiftTo(w5,w2),w2},w2.prototype.isProbablePrime=function(w0){var w1,w2=this.abs();if(1==w2.t&&w2[0]<=w26[w26.length-1]){for(w1=0;w1>>8,w24[w25++]=255&w29;w25=0,w28()}function w32(){if(null==w23){for(w28(),(w23=new w34).init(w24),w25=0;w250?w3:w2)(w0)}},function(w0,w1){w0.exports=function(w0){if(null==w0)throw TypeError("Can't call method on "+w0);return w0}},function(w0,w1,w2){"use strict";var w3=w2(36),w4=w2(2),w5=w2(100),w6=w2(18),w7=w2(39),w8=w2(185),w9=w2(42),w10=w2(188),w11=w2(5)("iterator"),w12=!([].keys&&"next"in[].keys()),w13="keys",w14="values",w15=function(){return this};w0.exports=function(w0,w1,w2,w16,w17,w18,w19){w8(w2,w1,w16);var w20,w21,w22,w23=function(w0){if(!w12&&w0 in w27)return w27[w0];switch(w0){case w13:case w14:return function(){return new w2(this,w0)}}return function(){return new w2(this,w0)}},w24=w1+" Iterator",w25=w17==w14,w26=!1,w27=w0.prototype,w28=w27[w11]||w27["@@iterator"]||w17&&w27[w17],w29=w28||w23(w17),w30=w17?w25?w23("entries"):w29:void 0,w31="Array"==w1&&w27.entries||w28;if(w31&&(w22=w10(w31.call(new w0)))!==Object.prototype&&w22.next&&(w9(w22,w24,!0),w3||"function"==typeof w22[w11]||w6(w22,w11,w15)),w25&&w28&&w28.name!==w14&&(w26=!0,w29=function(){return w28.call(this)}),w3&&!w19||!w12&&!w26&&w27[w11]||w6(w27,w11,w29),w7[w1]=w29,w7[w24]=w15,w17)if(w20={values:w25?w29:w23(w14),keys:w18?w29:w23(w13),entries:w30},w19)for(w21 in w20)w21 in w27||w5(w27,w21,w20[w21]);else w4(w4.P+w4.F*(w12||w26),w1,w20);return w20}},function(w0,w1,w2){var w3=w2(7),w4=w2(4).document,w5=w3(w4)&&w3(w4.createElement);w0.exports=function(w0){return w5?w4.createElement(w0):{}}},function(w0,w1,w2){var w3=w2(7);w0.exports=function(w0,w1){if(!w3(w0))return w0;var w2,w4;if(w1&&"function"==typeof(w2=w0.toString)&&!w3(w4=w2.call(w0)))return w4;if("function"==typeof(w2=w0.valueOf)&&!w3(w4=w2.call(w0)))return w4;if(!w1&&"function"==typeof(w2=w0.toString)&&!w3(w4=w2.call(w0)))return w4;throw TypeError("Can't convert object to primitive value")}},function(w0,w1,w2){var w3=w2(41);w0.exports=Object("z").propertyIsEnumerable(0)?Object:function(w0){return"String"==w3(w0)?w0.split(""):Object(w0)}},function(w0,w1,w2){var w3=w2(70)("keys"),w4=w2(51);w0.exports=function(w0){return w3[w0]||(w3[w0]=w4(w0))}},function(w0,w1,w2){var w3=w2(1),w4=w2(4),w5="__core-js_shared__",w6=w4[w5]||(w4[w5]={});(w0.exports=function(w0,w1){return w6[w0]||(w6[w0]=void 0!==w1?w1:{})})("versions",[]).push({version:w3.version,mode:w2(36)?"pure":"global",copyright:"© 2019 Denis Pushkarev (zloirock.ru)"})},function(w0,w1){w0.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(w0,w1,w2){var w3=w2(73),w4=w2(5)("iterator"),w5=w2(39);w0.exports=w2(1).getIteratorMethod=function(w0){if(null!=w0)return w0[w4]||w0["@@iterator"]||w5[w3(w0)]}},function(w0,w1,w2){var w3=w2(41),w4=w2(5)("toStringTag"),w5="Arguments"==w3(function(){return arguments}());w0.exports=function(w0){var w1,w2,w6;return void 0===w0?"Undefined":null===w0?"Null":"string"==typeof(w2=function(w0,w1){try{return w0[w1]}catch(w0){}}(w1=Object(w0),w4))?w2:w5?w3(w1):"Object"==(w6=w3(w1))&&"function"==typeof w1.callee?"Arguments":w6}},function(w0,w1,w2){var w3=w2(18);w0.exports=function(w0,w1,w2){for(var w4 in w1)w2&&w0[w4]?w0[w4]=w1[w4]:w3(w0,w4,w1[w4]);return w0}},function(w0,w1){w0.exports=function(w0,w1,w2,w3){if(!(w0 instanceof w1)||void 0!==w3&&w3 in w0)throw TypeError(w2+": incorrect invocation!");return w0}},function(w0,w1,w2){var w3=w2(7);w0.exports=function(w0,w1){if(!w3(w0)||w0._t!==w1)throw TypeError("Incompatible receiver, "+w1+" required!");return w0}},function(w0,w1,w2){w0.exports={default:w2(202),__esModule:!0}},function(w0,w1,w2){"use strict";var w3=w2(37);function w4(w0){var w1,w2;this.promise=new w0((function(w0,w3){if(void 0!==w1||void 0!==w2)throw TypeError("Bad Promise constructor");w1=w0,w2=w3})),this.resolve=w3(w1),this.reject=w3(w2)}w0.exports.f=function(w0){return new w4(w0)}},function(w0,w1){w1.f=Object.getOwnPropertySymbols},function(w0,w1,w2){w0.exports={default:w2(216),__esModule:!0}},function(w0,w1,w2){"use strict";w1.__esModule=!0;var w3,w4=w2(62),w5=(w3=w4)&&w3.__esModule?w3:{default:w3};w1.default=function(w0){if(Array.isArray(w0)){for(var w1=0,w2=Array(w0.length);w1>>=0)&&w0<256)&&(w3=w6[w0])?w3:(w2=w9(w0,(0|w0)<0?-1:0,!0),w4&&(w6[w0]=w2),w2):(w4=-128<=(w0|=0)&&w0<128)&&(w3=w5[w0])?w3:(w2=w9(w0,w0<0?-1:0,!1),w4&&(w5[w0]=w2),w2)}function w8(w0,w1){if(isNaN(w0))return w1?w18:w17;if(w1){if(w0<0)return w18;if(w0>=w14)return w23}else{if(w0<=-w15)return w24;if(w0+1>=w15)return w22}return w0<0?w8(-w0,w1).neg():w9(w0%w13|0,w0/w13|0,w1)}function w9(w0,w1,w2){return new w3(w0,w1,w2)}w3.fromInt=w7,w3.fromNumber=w8,w3.fromBits=w9;var w10=Math.pow;function w11(w0,w1,w2){if(0===w0.length)throw Error("empty string");if("NaN"===w0||"Infinity"===w0||"+Infinity"===w0||"-Infinity"===w0)return w17;if("number"==typeof w1?(w2=w1,w1=!1):w1=!!w1,(w2=w2||10)<2||360)throw Error("interior hyphen");if(0===w3)return w11(w0.substring(1),w1,w2).neg();for(var w4=w8(w10(w2,8)),w5=w17,w6=0;w6>>0:this.low},w25.toNumber=function(){return this.unsigned?(this.high>>>0)*w13+(this.low>>>0):this.high*w13+(this.low>>>0)},w25.toString=function(w0){if((w0=w0||10)<2||36>>0).toString(w0);if((w5=w7).isZero())return w9+w6;for(;w9.length<6;)w9="0"+w9;w6=""+w9+w6}},w25.getHighBits=function(){return this.high},w25.getHighBitsUnsigned=function(){return this.high>>>0},w25.getLowBits=function(){return this.low},w25.getLowBitsUnsigned=function(){return this.low>>>0},w25.getNumBitsAbs=function(){if(this.isNegative())return this.eq(w24)?64:this.neg().getNumBitsAbs();for(var w0=0!=this.high?this.high:this.low,w1=31;w1>0&&0==(w0&1<=0},w25.isOdd=function(){return 1==(1&this.low)},w25.isEven=function(){return 0==(1&this.low)},w25.equals=function(w0){return w4(w0)||(w0=w12(w0)),(this.unsigned===w0.unsigned||this.high>>>31!=1||w0.high>>>31!=1)&&(this.high===w0.high&&this.low===w0.low)},w25.eq=w25.equals,w25.notEquals=function(w0){return!this.eq(w0)},w25.neq=w25.notEquals,w25.ne=w25.notEquals,w25.lessThan=function(w0){return this.comp(w0)<0},w25.lt=w25.lessThan,w25.lessThanOrEqual=function(w0){return this.comp(w0)<=0},w25.lte=w25.lessThanOrEqual,w25.le=w25.lessThanOrEqual,w25.greaterThan=function(w0){return this.comp(w0)>0},w25.gt=w25.greaterThan,w25.greaterThanOrEqual=function(w0){return this.comp(w0)>=0},w25.gte=w25.greaterThanOrEqual,w25.ge=w25.greaterThanOrEqual,w25.compare=function(w0){if(w4(w0)||(w0=w12(w0)),this.eq(w0))return 0;var w1=this.isNegative(),w2=w0.isNegative();return w1&&!w2?-1:!w1&&w2?1:this.unsigned?w0.high>>>0>this.high>>>0||w0.high===this.high&&w0.low>>>0>this.low>>>0?-1:1:this.sub(w0).isNegative()?-1:1},w25.comp=w25.compare,w25.negate=function(){return!this.unsigned&&this.eq(w24)?w24:this.not().add(w19)},w25.neg=w25.negate,w25.add=function(w0){w4(w0)||(w0=w12(w0));var w1=this.high>>>16,w2=65535&this.high,w3=this.low>>>16,w5=65535&this.low,w6=w0.high>>>16,w7=65535&w0.high,w8=w0.low>>>16,w10=0,w11=0,w13=0,w14=0;return w13+=(w14+=w5+(65535&w0.low))>>>16,w11+=(w13+=w3+w8)>>>16,w10+=(w11+=w2+w7)>>>16,w10+=w1+w6,w9((w13&=65535)<<16|(w14&=65535),(w10&=65535)<<16|(w11&=65535),this.unsigned)},w25.subtract=function(w0){return w4(w0)||(w0=w12(w0)),this.add(w0.neg())},w25.sub=w25.subtract,w25.multiply=function(w0){if(this.isZero())return w17;if(w4(w0)||(w0=w12(w0)),w2)return w9(w2.mul(this.low,this.high,w0.low,w0.high),w2.get_high(),this.unsigned);if(w0.isZero())return w17;if(this.eq(w24))return w0.isOdd()?w24:w17;if(w0.eq(w24))return this.isOdd()?w24:w17;if(this.isNegative())return w0.isNegative()?this.neg().mul(w0.neg()):this.neg().mul(w0).neg();if(w0.isNegative())return this.mul(w0.neg()).neg();if(this.lt(w16)&&w0.lt(w16))return w8(this.toNumber()*w0.toNumber(),this.unsigned);var w1=this.high>>>16,w3=65535&this.high,w5=this.low>>>16,w6=65535&this.low,w7=w0.high>>>16,w10=65535&w0.high,w11=w0.low>>>16,w13=65535&w0.low,w14=0,w15=0,w18=0,w19=0;return w18+=(w19+=w6*w13)>>>16,w15+=(w18+=w5*w13)>>>16,w18&=65535,w15+=(w18+=w6*w11)>>>16,w14+=(w15+=w3*w13)>>>16,w15&=65535,w14+=(w15+=w5*w11)>>>16,w15&=65535,w14+=(w15+=w6*w10)>>>16,w14+=w1*w13+w3*w11+w5*w10+w6*w7,w9((w18&=65535)<<16|(w19&=65535),(w14&=65535)<<16|(w15&=65535),this.unsigned)},w25.mul=w25.multiply,w25.divide=function(w0){if(w4(w0)||(w0=w12(w0)),w0.isZero())throw Error("division by zero");var w1,w3,w5;if(w2)return this.unsigned||-2147483648!==this.high||-1!==w0.low||-1!==w0.high?w9((this.unsigned?w2.div_u:w2.div_s)(this.low,this.high,w0.low,w0.high),w2.get_high(),this.unsigned):this;if(this.isZero())return this.unsigned?w18:w17;if(this.unsigned){if(w0.unsigned||(w0=w0.toUnsigned()),w0.gt(this))return w18;if(w0.gt(this.shru(1)))return w20;w5=w18}else{if(this.eq(w24))return w0.eq(w19)||w0.eq(w21)?w24:w0.eq(w24)?w19:(w1=this.shr(1).div(w0).shl(1)).eq(w17)?w0.isNegative()?w19:w21:(w3=this.sub(w0.mul(w1)),w5=w1.add(w3.div(w0)));if(w0.eq(w24))return this.unsigned?w18:w17;if(this.isNegative())return w0.isNegative()?this.neg().div(w0.neg()):this.neg().div(w0).neg();if(w0.isNegative())return this.div(w0.neg()).neg();w5=w17}for(w3=this;w3.gte(w0);){w1=Math.max(1,Math.floor(w3.toNumber()/w0.toNumber()));for(var w6=Math.ceil(Math.log(w1)/Math.LN2),w7=w6<=48?1:w10(2,w6-48),w11=w8(w1),w13=w11.mul(w0);w13.isNegative()||w13.gt(w3);)w13=(w11=w8(w1-=w7,this.unsigned)).mul(w0);w11.isZero()&&(w11=w19),w5=w5.add(w11),w3=w3.sub(w13)}return w5},w25.div=w25.divide,w25.modulo=function(w0){return w4(w0)||(w0=w12(w0)),w2?w9((this.unsigned?w2.rem_u:w2.rem_s)(this.low,this.high,w0.low,w0.high),w2.get_high(),this.unsigned):this.sub(this.div(w0).mul(w0))},w25.mod=w25.modulo,w25.rem=w25.modulo,w25.not=function(){return w9(~this.low,~this.high,this.unsigned)},w25.and=function(w0){return w4(w0)||(w0=w12(w0)),w9(this.low&w0.low,this.high&w0.high,this.unsigned)},w25.or=function(w0){return w4(w0)||(w0=w12(w0)),w9(this.low|w0.low,this.high|w0.high,this.unsigned)},w25.xor=function(w0){return w4(w0)||(w0=w12(w0)),w9(this.low^w0.low,this.high^w0.high,this.unsigned)},w25.shiftLeft=function(w0){return w4(w0)&&(w0=w0.toInt()),0==(w0&=63)?this:w0<32?w9(this.low<>>32-w0,this.unsigned):w9(0,this.low<>>w0|this.high<<32-w0,this.high>>w0,this.unsigned):w9(this.high>>w0-32,this.high>=0?0:-1,this.unsigned)},w25.shr=w25.shiftRight,w25.shiftRightUnsigned=function(w0){if(w4(w0)&&(w0=w0.toInt()),0===(w0&=63))return this;var w1=this.high;return w0<32?w9(this.low>>>w0|w1<<32-w0,w1>>>w0,this.unsigned):w9(32===w0?w1:w1>>>w0-32,0,this.unsigned)},w25.shru=w25.shiftRightUnsigned,w25.shr_u=w25.shiftRightUnsigned,w25.toSigned=function(){return this.unsigned?w9(this.low,this.high,!1):this},w25.toUnsigned=function(){return this.unsigned?this:w9(this.low,this.high,!0)},w25.toBytes=function(w0){return w0?this.toBytesLE():this.toBytesBE()},w25.toBytesLE=function(){var w0=this.high,w1=this.low;return[255&w1,w1>>>8&255,w1>>>16&255,w1>>>24,255&w0,w0>>>8&255,w0>>>16&255,w0>>>24]},w25.toBytesBE=function(){var w0=this.high,w1=this.low;return[w0>>>24,w0>>>16&255,w0>>>8&255,255&w0,w1>>>24,w1>>>16&255,w1>>>8&255,255&w1]},w3.fromBytes=function(w0,w1,w2){return w2?w3.fromBytesLE(w0,w1):w3.fromBytesBE(w0,w1)},w3.fromBytesLE=function(w0,w1){return new w3(w0[0]|w0[1]<<8|w0[2]<<16|w0[3]<<24,w0[4]|w0[5]<<8|w0[6]<<16|w0[7]<<24,w1)},w3.fromBytesBE=function(w0,w1){return new w3(w0[4]<<24|w0[5]<<16|w0[6]<<8|w0[7],w0[0]<<24|w0[1]<<16|w0[2]<<8|w0[3],w1)}},function(w0,w1,w2){var w3,w4,w5,w6,w7,w8,w9,w10;w0.exports=(w10=w2(0),w4=(w3=w10).lib,w5=w4.WordArray,w6=w4.Hasher,w7=w3.algo,w8=[],w9=w7.SHA1=w6.extend({_doReset:function(){this._hash=new w5.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(w0,w1){for(var w2=this._hash.words,w3=w2[0],w4=w2[1],w5=w2[2],w6=w2[3],w7=w2[4],w9=0;w9<80;w9++){if(w9<16)w8[w9]=0|w0[w1+w9];else{var w10=w8[w9-3]^w8[w9-8]^w8[w9-14]^w8[w9-16];w8[w9]=w10<<1|w10>>>31}var w11=(w3<<5|w3>>>27)+w7+w8[w9];w11+=w9<20?1518500249+(w4&w5|~w4&w6):w9<40?1859775393+(w4^w5^w6):w9<60?(w4&w5|w4&w6|w5&w6)-1894007588:(w4^w5^w6)-899497514,w7=w6,w6=w5,w5=w4<<30|w4>>>2,w4=w3,w3=w11}w2[0]=w2[0]+w3|0,w2[1]=w2[1]+w4|0,w2[2]=w2[2]+w5|0,w2[3]=w2[3]+w6|0,w2[4]=w2[4]+w7|0},_doFinalize:function(){var w0=this._data,w1=w0.words,w2=8*this._nDataBytes,w3=8*w0.sigBytes;return w1[w3>>>5]|=128<<24-w3%32,w1[14+(w3+64>>>9<<4)]=Math.floor(w2/4294967296),w1[15+(w3+64>>>9<<4)]=w2,w0.sigBytes=4*w1.length,this._process(),this._hash},clone:function(){var w0=w6.clone.call(this);return w0._hash=this._hash.clone(),w0}}),w3.SHA1=w6._createHelper(w9),w3.HmacSHA1=w6._createHmacHelper(w9),w10.SHA1)},function(w0,w1,w2){var w3,w4,w5,w6;w0.exports=(w3=w2(0),w5=(w4=w3).lib.Base,w6=w4.enc.Utf8,void(w4.algo.HMAC=w5.extend({init:function(w0,w1){w0=this._hasher=new w0.init,"string"==typeof w1&&(w1=w6.parse(w1));var w2=w0.blockSize,w3=4*w2;w1.sigBytes>w3&&(w1=w0.finalize(w1)),w1.clamp();for(var w4=this._oKey=w1.clone(),w5=this._iKey=w1.clone(),w7=w4.words,w8=w5.words,w9=0;w9=this.__nextIndex__||(++this.__nextIndex__,this.__redo__?(this.__redo__.forEach((function(w1,w2){w1>=w0&&(this.__redo__[w2]=++w1)}),this),this.__redo__.push(w0)):w11(this,"__redo__",w8("c",[w0])))})),_onDelete:w8((function(w0){var w1;w0>=this.__nextIndex__||(--this.__nextIndex__,this.__redo__&&(-1!==(w1=this.__redo__.indexOf(w0))&&this.__redo__.splice(w1,1),this.__redo__.forEach((function(w1,w2){w1>w0&&(this.__redo__[w2]=--w1)}),this)))})),_onClear:w8((function(){this.__redo__&&w4.call(this.__redo__),this.__nextIndex__=0}))}))),w11(w3.prototype,w10.iterator,w8((function(){return this})))},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__92__},function(w0,w1,w2){"use strict";var w3=w2(353);w0.exports=function(w0,w1){var w2;function w4(w3){w1.rejectUnauthorized&&w0.emit("error",w3),w2.end()}return w1.port=w1.port||8883,w1.host=w1.hostname||w1.host||"localhost",w1.rejectUnauthorized=!1!==w1.rejectUnauthorized,delete w1.path,(w2=w3.connect(w1)).on("secureConnect",(function(){w1.rejectUnauthorized&&!w2.authorized?w2.emit("error",new Error("TLS not authorized")):w2.removeListener("error",w4)})),w2.on("error",w4),w2}},function(w0,w1,w2){(function(w1,w3){var w4=w2(33),w5=w2(354),w6=w2(14),w7=w2(357),w8=w1.from&&w1.from!==Uint8Array.from?w1.from([0]):new w1([0]),w9=function(w0,w1){w0._corked?w0.once("uncork",w1):w1()},w10=function(w0,w1){return function(w2){w2?function(w0,w1){w0._autoDestroy&&w0.destroy(w1)}(w0,"premature close"===w2.message?null:w2):w1&&!w0._ended&&w0.end()}},w11=function(w0,w1,w2){if(!(this instanceof w11))return new w11(w0,w1,w2);w4.Duplex.call(this,w2),this._writable=null,this._readable=null,this._readable2=null,this._autoDestroy=!w2||!1!==w2.autoDestroy,this._forwardDestroy=!w2||!1!==w2.destroy,this._forwardEnd=!w2||!1!==w2.end,this._corked=1,this._ondrain=null,this._drained=!1,this._forwarding=!1,this._unwrite=null,this._unread=null,this._ended=!1,this.destroyed=!1,w0&&this.setWritable(w0),w1&&this.setReadable(w1)};w6(w11,w4.Duplex),w11.obj=function(w0,w1,w2){return w2||(w2={}),w2.objectMode=!0,w2.highWaterMark=16,new w11(w0,w1,w2)},w11.prototype.cork=function(){1==++this._corked&&this.emit("cork")},w11.prototype.uncork=function(){this._corked&&0==--this._corked&&this.emit("uncork")},w11.prototype.setWritable=function(w0){if(this._unwrite&&this._unwrite(),this.destroyed)w0&&w0.destroy&&w0.destroy();else if(null!==w0&&!1!==w0){var w1=this,w2=w5(w0,{writable:!0,readable:!1},w10(this,this._forwardEnd)),w4=function(){var w0=w1._ondrain;w1._ondrain=null,w0&&w0()};this._unwrite&&w3.nextTick(w4),this._writable=w0,this._writable.on("drain",w4),this._unwrite=function(){w1._writable.removeListener("drain",w4),w2()},this.uncork()}else this.end()},w11.prototype.setReadable=function(w0){if(this._unread&&this._unread(),this.destroyed)w0&&w0.destroy&&w0.destroy();else{if(null===w0||!1===w0)return this.push(null),void this.resume();var w1,w2=this,w3=w5(w0,{writable:!1,readable:!0},w10(this)),w6=function(){w2._forward()},w7=function(){w2.push(null)};this._drained=!0,this._readable=w0,this._readable2=w0._readableState?w0:(w1=w0,new w4.Readable({objectMode:!0,highWaterMark:16}).wrap(w1)),this._readable2.on("readable",w6),this._readable2.on("end",w7),this._unread=function(){w2._readable2.removeListener("readable",w6),w2._readable2.removeListener("end",w7),w3()},this._forward()}},w11.prototype._read=function(){this._drained=!0,this._forward()},w11.prototype._forward=function(){if(!this._forwarding&&this._readable2&&this._drained){var w0;for(this._forwarding=!0;this._drained&&null!==(w0=w7(this._readable2));)this.destroyed||(this._drained=this.push(w0));this._forwarding=!1}},w11.prototype.destroy=function(w0){if(!this.destroyed){this.destroyed=!0;var w1=this;w3.nextTick((function(){w1._destroy(w0)}))}},w11.prototype._destroy=function(w0){if(w0){var w1=this._ondrain;this._ondrain=null,w1?w1(w0):this.emit("error",w0)}this._forwardDestroy&&(this._readable&&this._readable.destroy&&this._readable.destroy(),this._writable&&this._writable.destroy&&this._writable.destroy()),this.emit("close")},w11.prototype._write=function(w0,w1,w2){return this.destroyed?w2():this._corked?w9(this,this._write.bind(this,w0,w1,w2)):w0===w8?this._finish(w2):this._writable?void(!1===this._writable.write(w0)?this._ondrain=w2:w2()):w2()},w11.prototype._finish=function(w0){var w1=this;this.emit("preend"),w9(this,(function(){var w2,w3;w2=w1._forwardEnd&&w1._writable,w3=function(){!1===w1._writableState.prefinished&&(w1._writableState.prefinished=!0),w1.emit("prefinish"),w9(w1,w0)},w2?w2._writableState&&w2._writableState.finished?w3():w2._writableState?w2.end(w3):(w2.end(),w3()):w3()}))},w11.prototype.end=function(w0,w1,w2){return"function"==typeof w0?this.end(null,null,w0):"function"==typeof w1?this.end(w0,null,w1):(this._ended=!0,w0&&this.write(w0),this._writableState.ending||this.write(w8),w4.Writable.prototype.end.call(this,w2))},w0.exports=w11}).call(this,w2(16).Buffer,w2(6))},function(w0,w1,w2){"use strict";var w3=w5(w2(32)),w4=w5(w2(45));function w5(w0){return w0&&w0.__esModule?w0:{default:w0}}var w6=w2(158),w7=w6.Reader,w8=w6.Writer,w9=w6.util,w10=w6.roots.default||(w6.roots.default={});w10.IMHttpWrapper=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.token=w0.string();break;case 2:w3.clientId=w0.string();break;case 3:w3.request=w0.string();break;case 4:w3.data=w0.bytes();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("token"))throw w9.ProtocolError("missing required 'token'",{instance:w3});if(!w3.hasOwnProperty("clientId"))throw w9.ProtocolError("missing required 'clientId'",{instance:w3});if(!w3.hasOwnProperty("request"))throw w9.ProtocolError("missing required 'request'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.token)?w9.isString(w0.clientId)?w9.isString(w0.request)?null!=w0.data&&w0.hasOwnProperty("data")&&!(w0.data&&"number"==typeof w0.data.length||w9.isString(w0.data))?"data: buffer expected":null:"request: string expected":"clientId: string expected":"token: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.IMHttpWrapper)return w0;var w1=new w10.IMHttpWrapper;return null!=w0.token&&(w1.token=String(w0.token)),null!=w0.clientId&&(w1.clientId=String(w0.clientId)),null!=w0.request&&(w1.request=String(w0.request)),null!=w0.data&&("string"==typeof w0.data?w9.base64.decode(w0.data,w1.data=w9.newBuffer(w9.base64.length(w0.data)),0):w0.data.length&&(w1.data=w0.data)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.token="",w2.clientId="",w2.request="",w1.bytes===String?w2.data="":(w2.data=[],w1.bytes!==Array&&(w2.data=w9.newBuffer(w2.data)))),null!=w0.token&&w0.hasOwnProperty("token")&&(w2.token=w0.token),null!=w0.clientId&&w0.hasOwnProperty("clientId")&&(w2.clientId=w0.clientId),null!=w0.request&&w0.hasOwnProperty("request")&&(w2.request=w0.request),null!=w0.data&&w0.hasOwnProperty("data")&&(w2.data=w1.bytes===String?w9.base64.encode(w0.data,0,w0.data.length):w1.bytes===Array?Array.prototype.slice.call(w0.data):w0.data),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.RouteRequest=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.app=w0.string();break;case 2:w3.platform=w0.int32();break;case 3:w3.pushType=w0.int32();break;case 4:w3.deviceName=w0.string();break;case 5:w3.deviceVersion=w0.string();break;case 6:w3.phoneName=w0.string();break;case 7:w3.language=w0.string();break;case 8:w3.carrierName=w0.string();break;case 9:w3.appVersion=w0.string();break;case 10:w3.sdkVersion=w0.string();break;case 11:w3.wxAppId=w0.string();break;case 12:w3.wxAppKey=w0.string();break;case 13:w3.webAppId=w0.string();break;case 14:w3.webAppKey=w0.string();break;case 15:w3.host=w0.string();break;default:w0.skipType(7&w4)}}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":null!=w0.app&&w0.hasOwnProperty("app")&&!w9.isString(w0.app)?"app: string expected":null!=w0.platform&&w0.hasOwnProperty("platform")&&!w9.isInteger(w0.platform)?"platform: integer expected":null!=w0.pushType&&w0.hasOwnProperty("pushType")&&!w9.isInteger(w0.pushType)?"pushType: integer expected":null!=w0.deviceName&&w0.hasOwnProperty("deviceName")&&!w9.isString(w0.deviceName)?"deviceName: string expected":null!=w0.deviceVersion&&w0.hasOwnProperty("deviceVersion")&&!w9.isString(w0.deviceVersion)?"deviceVersion: string expected":null!=w0.phoneName&&w0.hasOwnProperty("phoneName")&&!w9.isString(w0.phoneName)?"phoneName: string expected":null!=w0.language&&w0.hasOwnProperty("language")&&!w9.isString(w0.language)?"language: string expected":null!=w0.carrierName&&w0.hasOwnProperty("carrierName")&&!w9.isString(w0.carrierName)?"carrierName: string expected":null!=w0.appVersion&&w0.hasOwnProperty("appVersion")&&!w9.isString(w0.appVersion)?"appVersion: string expected":null!=w0.sdkVersion&&w0.hasOwnProperty("sdkVersion")&&!w9.isString(w0.sdkVersion)?"sdkVersion: string expected":null!=w0.wxAppId&&w0.hasOwnProperty("wxAppId")&&!w9.isString(w0.wxAppId)?"wxAppId: string expected":null!=w0.wxAppKey&&w0.hasOwnProperty("wxAppKey")&&!w9.isString(w0.wxAppKey)?"wxAppKey: string expected":null!=w0.webAppId&&w0.hasOwnProperty("webAppId")&&!w9.isString(w0.webAppId)?"webAppId: string expected":null!=w0.webAppKey&&w0.hasOwnProperty("webAppKey")&&!w9.isString(w0.webAppKey)?"webAppKey: string expected":null!=w0.host&&w0.hasOwnProperty("host")&&!w9.isString(w0.host)?"host: string expected":null},w0.fromObject=function(w0){if(w0 instanceof w10.RouteRequest)return w0;var w1=new w10.RouteRequest;return null!=w0.app&&(w1.app=String(w0.app)),null!=w0.platform&&(w1.platform=0|w0.platform),null!=w0.pushType&&(w1.pushType=0|w0.pushType),null!=w0.deviceName&&(w1.deviceName=String(w0.deviceName)),null!=w0.deviceVersion&&(w1.deviceVersion=String(w0.deviceVersion)),null!=w0.phoneName&&(w1.phoneName=String(w0.phoneName)),null!=w0.language&&(w1.language=String(w0.language)),null!=w0.carrierName&&(w1.carrierName=String(w0.carrierName)),null!=w0.appVersion&&(w1.appVersion=String(w0.appVersion)),null!=w0.sdkVersion&&(w1.sdkVersion=String(w0.sdkVersion)),null!=w0.wxAppId&&(w1.wxAppId=String(w0.wxAppId)),null!=w0.wxAppKey&&(w1.wxAppKey=String(w0.wxAppKey)),null!=w0.webAppId&&(w1.webAppId=String(w0.webAppId)),null!=w0.webAppKey&&(w1.webAppKey=String(w0.webAppKey)),null!=w0.host&&(w1.host=String(w0.host)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.app="",w2.platform=0,w2.pushType=0,w2.deviceName="",w2.deviceVersion="",w2.phoneName="",w2.language="",w2.carrierName="",w2.appVersion="",w2.sdkVersion="",w2.wxAppId="",w2.wxAppKey="",w2.webAppId="",w2.webAppKey="",w2.host=""),null!=w0.app&&w0.hasOwnProperty("app")&&(w2.app=w0.app),null!=w0.platform&&w0.hasOwnProperty("platform")&&(w2.platform=w0.platform),null!=w0.pushType&&w0.hasOwnProperty("pushType")&&(w2.pushType=w0.pushType),null!=w0.deviceName&&w0.hasOwnProperty("deviceName")&&(w2.deviceName=w0.deviceName),null!=w0.deviceVersion&&w0.hasOwnProperty("deviceVersion")&&(w2.deviceVersion=w0.deviceVersion),null!=w0.phoneName&&w0.hasOwnProperty("phoneName")&&(w2.phoneName=w0.phoneName),null!=w0.language&&w0.hasOwnProperty("language")&&(w2.language=w0.language),null!=w0.carrierName&&w0.hasOwnProperty("carrierName")&&(w2.carrierName=w0.carrierName),null!=w0.appVersion&&w0.hasOwnProperty("appVersion")&&(w2.appVersion=w0.appVersion),null!=w0.sdkVersion&&w0.hasOwnProperty("sdkVersion")&&(w2.sdkVersion=w0.sdkVersion),null!=w0.wxAppId&&w0.hasOwnProperty("wxAppId")&&(w2.wxAppId=w0.wxAppId),null!=w0.wxAppKey&&w0.hasOwnProperty("wxAppKey")&&(w2.wxAppKey=w0.wxAppKey),null!=w0.webAppId&&w0.hasOwnProperty("webAppId")&&(w2.webAppId=w0.webAppId),null!=w0.webAppKey&&w0.hasOwnProperty("webAppKey")&&(w2.webAppKey=w0.webAppKey),null!=w0.host&&w0.hasOwnProperty("host")&&(w2.host=w0.host),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.AddressTriple=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.host=w0.string();break;case 2:w3.longPort=w0.int32();break;case 3:w3.shortPort=w0.int32();break;case 4:w3.wssPort=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("host"))throw w9.ProtocolError("missing required 'host'",{instance:w3});if(!w3.hasOwnProperty("longPort"))throw w9.ProtocolError("missing required 'longPort'",{instance:w3});if(!w3.hasOwnProperty("shortPort"))throw w9.ProtocolError("missing required 'shortPort'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.host)?w9.isInteger(w0.longPort)?w9.isInteger(w0.shortPort)?null!=w0.wssPort&&w0.hasOwnProperty("wssPort")&&!w9.isInteger(w0.wssPort)?"wssPort: integer expected":null:"shortPort: integer expected":"longPort: integer expected":"host: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.AddressTriple)return w0;var w1=new w10.AddressTriple;return null!=w0.host&&(w1.host=String(w0.host)),null!=w0.longPort&&(w1.longPort=0|w0.longPort),null!=w0.shortPort&&(w1.shortPort=0|w0.shortPort),null!=w0.wssPort&&(w1.wssPort=0|w0.wssPort),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.host="",w2.longPort=0,w2.shortPort=0,w2.wssPort=0),null!=w0.host&&w0.hasOwnProperty("host")&&(w2.host=w0.host),null!=w0.longPort&&w0.hasOwnProperty("longPort")&&(w2.longPort=w0.longPort),null!=w0.shortPort&&w0.hasOwnProperty("shortPort")&&(w2.shortPort=w0.shortPort),null!=w0.wssPort&&w0.hasOwnProperty("wssPort")&&(w2.wssPort=w0.wssPort),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.RouteResponse=function(){function w0(w0){if(this.candidate=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.host=w0.string();break;case 2:w3.longPort=w0.int32();break;case 3:w3.shortPort=w0.int32();break;case 4:w3.thumbPara=w0.string();break;case 5:w3.node=w0.string();break;case 6:w3.commercial=w0.int32();break;case 7:w3.wssPort=w0.int32();break;case 8:w3.candidate&&w3.candidate.length||(w3.candidate=[]),w3.candidate.push(w10.AddressTriple.decode(w0,w0.uint32()));break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("host"))throw w9.ProtocolError("missing required 'host'",{instance:w3});if(!w3.hasOwnProperty("longPort"))throw w9.ProtocolError("missing required 'longPort'",{instance:w3});if(!w3.hasOwnProperty("shortPort"))throw w9.ProtocolError("missing required 'shortPort'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!w9.isString(w0.host))return"host: string expected";if(!w9.isInteger(w0.longPort))return"longPort: integer expected";if(!w9.isInteger(w0.shortPort))return"shortPort: integer expected";if(null!=w0.thumbPara&&w0.hasOwnProperty("thumbPara")&&!w9.isString(w0.thumbPara))return"thumbPara: string expected";if(null!=w0.node&&w0.hasOwnProperty("node")&&!w9.isString(w0.node))return"node: string expected";if(null!=w0.commercial&&w0.hasOwnProperty("commercial")&&!w9.isInteger(w0.commercial))return"commercial: integer expected";if(null!=w0.wssPort&&w0.hasOwnProperty("wssPort")&&!w9.isInteger(w0.wssPort))return"wssPort: integer expected";if(null!=w0.candidate&&w0.hasOwnProperty("candidate")){if(!Array.isArray(w0.candidate))return"candidate: array expected";for(var w1=0;w10?w6-4:w6;for(w2=0;w2>16&255,w8[w10++]=w1>>8&255,w8[w10++]=255&w1;2===w7&&(w1=w4[w0.charCodeAt(w2)]<<2|w4[w0.charCodeAt(w2+1)]>>4,w8[w10++]=255&w1);1===w7&&(w1=w4[w0.charCodeAt(w2)]<<10|w4[w0.charCodeAt(w2+1)]<<4|w4[w0.charCodeAt(w2+2)]>>2,w8[w10++]=w1>>8&255,w8[w10++]=255&w1);return w8},w1.fromByteArray=function(w0){for(var w1,w2=w0.length,w4=w2%3,w5=[],w6=16383,w7=0,w8=w2-w4;w7w8?w8:w7+w6));1===w4?(w1=w0[w2-1],w5.push(w3[w1>>2]+w3[w1<<4&63]+"==")):2===w4&&(w1=(w0[w2-2]<<8)+w0[w2-1],w5.push(w3[w1>>10]+w3[w1>>4&63]+w3[w1<<2&63]+"="));return w5.join("")};for(var w3=[],w4=[],w5="undefined"!=typeof Uint8Array?Uint8Array:Array,w6="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",w7=0,w8=w6.length;w70)throw new Error("Invalid string. Length must be a multiple of 4");var w2=w0.indexOf("=");return-1===w2&&(w2=w1),[w2,w2===w1?0:4-w2%4]}function w10(w0,w1,w2){for(var w4,w5,w6=[],w7=w1;w7>18&63]+w3[w5>>12&63]+w3[w5>>6&63]+w3[63&w5]);return w6.join("")}w4["-".charCodeAt(0)]=62,w4["_".charCodeAt(0)]=63},function(w0,w1){var w2={}.toString;w0.exports=Array.isArray||function(w0){return"[object Array]"==w2.call(w0)}},function(w0,w1,w2){w0.exports=!w2(8)&&!w2(21)((function(){return 7!=Object.defineProperty(w2(66)("div"),"a",{get:function(){return 7}}).a}))},function(w0,w1,w2){w0.exports=w2(18)},function(w0,w1,w2){var w3=w2(9),w4=w2(13),w5=w2(40);w0.exports=w2(8)?Object.defineProperties:function(w0,w1){w4(w0);for(var w2,w6=w5(w1),w7=w6.length,w8=0;w7>w8;)w3.f(w0,w2=w6[w8++],w1[w2]);return w0}},function(w0,w1,w2){var w3=w2(22),w4=w2(27),w5=w2(186)(!1),w6=w2(69)("IE_PROTO");w0.exports=function(w0,w1){var w2,w7=w4(w0),w8=0,w9=[];for(w2 in w7)w2!=w6&&w3(w7,w2)&&w9.push(w2);for(;w1.length>w8;)w3(w7,w2=w1[w8++])&&(~w5(w9,w2)||w9.push(w2));return w9}},function(w0,w1,w2){var w3=w2(4).document;w0.exports=w3&&w3.documentElement},function(w0,w1,w2){var w3=w2(13);w0.exports=function(w0,w1,w2,w4){try{return w4?w1(w3(w2)[0],w2[1]):w1(w2)}catch(w1){var w5=w0.return;throw void 0!==w5&&w3(w5.call(w0)),w1}}},function(w0,w1,w2){var w3=w2(39),w4=w2(5)("iterator"),w5=Array.prototype;w0.exports=function(w0){return void 0!==w0&&(w3.Array===w0||w5[w4]===w0)}},function(w0,w1,w2){var w3=w2(5)("iterator"),w4=!1;try{var w5=[7][w3]();w5.return=function(){w4=!0},Array.from(w5,(function(){throw 2}))}catch(w0){}w0.exports=function(w0,w1){if(!w1&&!w4)return!1;var w2=!1;try{var w5=[7],w6=w5[w3]();w6.next=function(){return{done:w2=!0}},w5[w3]=function(){return w6},w0(w5)}catch(w0){}return w2}},function(w0,w1,w2){w0.exports={default:w2(191),__esModule:!0}},function(w0,w1){w0.exports=function(w0,w1){return{value:w1,done:!!w0}}},function(w0,w1,w2){"use strict";var w3=w2(9).f,w4=w2(49),w5=w2(74),w6=w2(17),w7=w2(75),w8=w2(44),w9=w2(65),w10=w2(108),w11=w2(110),w12=w2(8),w13=w2(53).fastKey,w14=w2(76),w15=w12?"_s":"size",w16=function(w0,w1){var w2,w3=w13(w1);if("F"!==w3)return w0._i[w3];for(w2=w0._f;w2;w2=w2.n)if(w2.k==w1)return w2};w0.exports={getConstructor:function(w0,w1,w2,w9){var w10=w0((function(w0,w3){w7(w0,w10,w1,"_i"),w0._t=w1,w0._i=w4(null),w0._f=void 0,w0._l=void 0,w0[w15]=0,null!=w3&&w8(w3,w2,w0[w9],w0)}));return w5(w10.prototype,{clear:function(){for(var w0=w14(this,w1),w2=w0._i,w3=w0._f;w3;w3=w3.n)w3.r=!0,w3.p&&(w3.p=w3.p.n=void 0),delete w2[w3.i];w0._f=w0._l=void 0,w0[w15]=0},delete:function(w0){var w2=w14(this,w1),w3=w16(w2,w0);if(w3){var w4=w3.n,w5=w3.p;delete w2._i[w3.i],w3.r=!0,w5&&(w5.n=w4),w4&&(w4.p=w5),w2._f==w3&&(w2._f=w4),w2._l==w3&&(w2._l=w5),w2[w15]--}return!!w3},forEach:function(w0){w14(this,w1);for(var w2,w3=w6(w0,arguments.length>1?arguments[1]:void 0,3);w2=w2?w2.n:this._f;)for(w3(w2.v,w2.k,this);w2&&w2.r;)w2=w2.p},has:function(w0){return!!w16(w14(this,w1),w0)}}),w12&&w3(w10.prototype,"size",{get:function(){return w14(this,w1)[w15]}}),w10},def:function(w0,w1,w2){var w3,w4,w5=w16(w0,w1);return w5?w5.v=w2:(w0._l=w5={i:w4=w13(w1,!0),k:w1,v:w2,p:w3=w0._l,n:void 0,r:!1},w0._f||(w0._f=w5),w3&&(w3.n=w5),w0[w15]++,"F"!==w4&&(w0._i[w4]=w5)),w0},getEntry:w16,setStrong:function(w0,w1,w2){w9(w0,w1,(function(w0,w2){this._t=w14(w0,w1),this._k=w2,this._l=void 0}),(function(){for(var w0=this,w1=w0._k,w2=w0._l;w2&&w2.r;)w2=w2.p;return w0._t&&(w0._l=w2=w2?w2.n:w0._t._f)?w10(0,"keys"==w1?w2.k:"values"==w1?w2.v:[w2.k,w2.v]):(w0._t=void 0,w10(1))}),w2?"entries":"values",!w2,!0),w11(w1)}}},function(w0,w1,w2){"use strict";var w3=w2(4),w4=w2(1),w5=w2(9),w6=w2(8),w7=w2(5)("species");w0.exports=function(w0){var w1="function"==typeof w4[w0]?w4[w0]:w3[w0];w6&&w1&&!w1[w7]&&w5.f(w1,w7,{configurable:!0,get:function(){return this}})}},function(w0,w1,w2){"use strict";var w3=w2(4),w4=w2(2),w5=w2(53),w6=w2(21),w7=w2(18),w8=w2(74),w9=w2(44),w10=w2(75),w11=w2(7),w12=w2(42),w13=w2(9).f,w14=w2(195)(0),w15=w2(8);w0.exports=function(w0,w1,w2,w16,w17,w18){var w19=w3[w0],w20=w19,w21=w17?"set":"add",w22=w20&&w20.prototype,w23={};return w15&&"function"==typeof w20&&(w18||w22.forEach&&!w6((function(){(new w20).entries().next()})))?(w20=w1((function(w1,w2){w10(w1,w20,w0,"_c"),w1._c=new w19,null!=w2&&w9(w2,w17,w1[w21],w1)})),w14("add,clear,delete,forEach,get,has,set,keys,values,entries,toJSON".split(","),(function(w0){var w1="add"==w0||"set"==w0;!(w0 in w22)||w18&&"clear"==w0||w7(w20.prototype,w0,(function(w2,w3){if(w10(this,w20,w0),!w1&&w18&&!w11(w2))return"get"==w0&&void 0;var w4=this._c[w0](0===w2?0:w2,w3);return w1?this:w4}))})),w18||w13(w20.prototype,"size",{get:function(){return this._c.size}})):(w20=w16.getConstructor(w1,w0,w17,w21),w8(w20.prototype,w2),w5.NEED=!0),w12(w20,w0),w23[w0]=w20,w4(w4.G+w4.W+w4.F,w23),w18||w16.setStrong(w20,w0,w17),w20}},function(w0,w1,w2){var w3=w2(41);w0.exports=Array.isArray||function(w0){return"Array"==w3(w0)}},function(w0,w1,w2){var w3=w2(73),w4=w2(199);w0.exports=function(w0){return function(){if(w3(this)!=w0)throw TypeError(w0+"#toJSON isn't generic");return w4(this)}}},function(w0,w1,w2){"use strict";var w3=w2(2);w0.exports=function(w0){w3(w3.S,w0,{of:function(){for(var w0=arguments.length,w1=new Array(w0);w0--;)w1[w0]=arguments[w0];return new this(w1)}})}},function(w0,w1,w2){"use strict";var w3=w2(2),w4=w2(37),w5=w2(17),w6=w2(44);w0.exports=function(w0){w3(w3.S,w0,{from:function(w0){var w1,w2,w3,w7,w8=arguments[1];return w4(this),(w1=void 0!==w8)&&w4(w8),null==w0?new this:(w2=[],w1?(w3=0,w7=w5(w8,arguments[2],2),w6(w0,!1,(function(w0){w2.push(w7(w0,w3++))}))):w6(w0,!1,w2.push,w2),new this(w2))}})}},function(w0,w1,w2){var w3=w2(13),w4=w2(37),w5=w2(5)("species");w0.exports=function(w0,w1){var w2,w6=w3(w0).constructor;return void 0===w6||null==(w2=w3(w6)[w5])?w1:w4(w2)}},function(w0,w1,w2){var w3,w4,w5,w6=w2(17),w7=w2(204),w8=w2(103),w9=w2(66),w10=w2(4),w11=w10.process,w12=w10.setImmediate,w13=w10.clearImmediate,w14=w10.MessageChannel,w15=w10.Dispatch,w16=0,w17={},w18="onreadystatechange",w19=function(){var w0=+this;if(w17.hasOwnProperty(w0)){var w1=w17[w0];delete w17[w0],w1()}},w20=function(w0){w19.call(w0.data)};w12&&w13||(w12=function(w0){for(var w1=[],w2=1;arguments.length>w2;)w1.push(arguments[w2++]);return w17[++w16]=function(){w7("function"==typeof w0?w0:Function(w0),w1)},w3(w16),w16},w13=function(w0){delete w17[w0]},"process"==w2(41)(w11)?w3=function(w0){w11.nextTick(w6(w19,w0,1))}:w15&&w15.now?w3=function(w0){w15.now(w6(w19,w0,1))}:w14?(w5=(w4=new w14).port2,w4.port1.onmessage=w20,w3=w6(w5.postMessage,w5,1)):w10.addEventListener&&"function"==typeof postMessage&&!w10.importScripts?(w3=function(w0){w10.postMessage(w0+"","*")},w10.addEventListener("message",w20,!1)):w3=w18 in w9("script")?function(w0){w8.appendChild(w9("script")).onreadystatechange=function(){w8.removeChild(this),w19.call(w0)}}:function(w0){setTimeout(w6(w19,w0,1),0)}),w0.exports={set:w12,clear:w13}},function(w0,w1){w0.exports=function(w0){try{return{e:!1,v:w0()}}catch(w0){return{e:!0,v:w0}}}},function(w0,w1,w2){var w3=w2(13),w4=w2(7),w5=w2(78);w0.exports=function(w0,w1){if(w3(w0),w4(w1)&&w1.constructor===w0)return w1;var w2=w5.f(w0);return(0,w2.resolve)(w1),w2.promise}},function(w0,w1,w2){w0.exports={default:w2(213),__esModule:!0}},function(w0,w1,w2){w0.exports={default:w2(217),__esModule:!0}},function(w0,w1,w2){w0.exports={default:w2(219),__esModule:!0}},function(w0,w1,w2){"use strict";w1.__esModule=!0;var w3,w4=w2(124),w5=(w3=w4)&&w3.__esModule?w3:{default:w3};w1.default=function(){function w0(w0,w1){for(var w2=0;w2>>7)^(w14<<14|w14>>>18)^w14>>>3,w16=w9[w13-2],w17=(w16<<15|w16>>>17)^(w16<<13|w16>>>19)^w16>>>10;w9[w13]=w15+w9[w13-7]+w17+w9[w13-16]}var w18=w3&w4^w3&w5^w4&w5,w19=(w3<<30|w3>>>2)^(w3<<19|w3>>>13)^(w3<<10|w3>>>22),w20=w12+((w7<<26|w7>>>6)^(w7<<21|w7>>>11)^(w7<<7|w7>>>25))+(w7&w10^~w7&w11)+w8[w13]+w9[w13];w12=w11,w11=w10,w10=w7,w7=w6+w20|0,w6=w5,w5=w4,w4=w3,w3=w20+(w19+w18)|0}w2[0]=w2[0]+w3|0,w2[1]=w2[1]+w4|0,w2[2]=w2[2]+w5|0,w2[3]=w2[3]+w6|0,w2[4]=w2[4]+w7|0,w2[5]=w2[5]+w10|0,w2[6]=w2[6]+w11|0,w2[7]=w2[7]+w12|0},_doFinalize:function(){var w1=this._data,w2=w1.words,w3=8*this._nDataBytes,w4=8*w1.sigBytes;return w2[w4>>>5]|=128<<24-w4%32,w2[14+(w4+64>>>9<<4)]=w0.floor(w3/4294967296),w2[15+(w4+64>>>9<<4)]=w3,w1.sigBytes=4*w2.length,this._process(),this._hash},clone:function(){var w0=w5.clone.call(this);return w0._hash=this._hash.clone(),w0}});w1.SHA256=w5._createHelper(w10),w1.HmacSHA256=w5._createHmacHelper(w10)}(Math),w3.SHA256)},function(w0,w1,w2){var w3;w0.exports=(w3=w2(0),w2(56),function(){var w0=w3,w1=w0.lib.Hasher,w2=w0.x64,w4=w2.Word,w5=w2.WordArray,w6=w0.algo;function w7(){return w4.create.apply(w4,arguments)}var w8=[w7(1116352408,3609767458),w7(1899447441,602891725),w7(3049323471,3964484399),w7(3921009573,2173295548),w7(961987163,4081628472),w7(1508970993,3053834265),w7(2453635748,2937671579),w7(2870763221,3664609560),w7(3624381080,2734883394),w7(310598401,1164996542),w7(607225278,1323610764),w7(1426881987,3590304994),w7(1925078388,4068182383),w7(2162078206,991336113),w7(2614888103,633803317),w7(3248222580,3479774868),w7(3835390401,2666613458),w7(4022224774,944711139),w7(264347078,2341262773),w7(604807628,2007800933),w7(770255983,1495990901),w7(1249150122,1856431235),w7(1555081692,3175218132),w7(1996064986,2198950837),w7(2554220882,3999719339),w7(2821834349,766784016),w7(2952996808,2566594879),w7(3210313671,3203337956),w7(3336571891,1034457026),w7(3584528711,2466948901),w7(113926993,3758326383),w7(338241895,168717936),w7(666307205,1188179964),w7(773529912,1546045734),w7(1294757372,1522805485),w7(1396182291,2643833823),w7(1695183700,2343527390),w7(1986661051,1014477480),w7(2177026350,1206759142),w7(2456956037,344077627),w7(2730485921,1290863460),w7(2820302411,3158454273),w7(3259730800,3505952657),w7(3345764771,106217008),w7(3516065817,3606008344),w7(3600352804,1432725776),w7(4094571909,1467031594),w7(275423344,851169720),w7(430227734,3100823752),w7(506948616,1363258195),w7(659060556,3750685593),w7(883997877,3785050280),w7(958139571,3318307427),w7(1322822218,3812723403),w7(1537002063,2003034995),w7(1747873779,3602036899),w7(1955562222,1575990012),w7(2024104815,1125592928),w7(2227730452,2716904306),w7(2361852424,442776044),w7(2428436474,593698344),w7(2756734187,3733110249),w7(3204031479,2999351573),w7(3329325298,3815920427),w7(3391569614,3928383900),w7(3515267271,566280711),w7(3940187606,3454069534),w7(4118630271,4000239992),w7(116418474,1914138554),w7(174292421,2731055270),w7(289380356,3203993006),w7(460393269,320620315),w7(685471733,587496836),w7(852142971,1086792851),w7(1017036298,365543100),w7(1126000580,2618297676),w7(1288033470,3409855158),w7(1501505948,4234509866),w7(1607167915,987167468),w7(1816402316,1246189591)],w9=[];!function(){for(var w0=0;w0<80;w0++)w9[w0]=w7()}();var w10=w6.SHA512=w1.extend({_doReset:function(){this._hash=new w5.init([new w4.init(1779033703,4089235720),new w4.init(3144134277,2227873595),new w4.init(1013904242,4271175723),new w4.init(2773480762,1595750129),new w4.init(1359893119,2917565137),new w4.init(2600822924,725511199),new w4.init(528734635,4215389547),new w4.init(1541459225,327033209)])},_doProcessBlock:function(w0,w1){for(var w2=this._hash.words,w3=w2[0],w4=w2[1],w5=w2[2],w6=w2[3],w7=w2[4],w10=w2[5],w11=w2[6],w12=w2[7],w13=w3.high,w14=w3.low,w15=w4.high,w16=w4.low,w17=w5.high,w18=w5.low,w19=w6.high,w20=w6.low,w21=w7.high,w22=w7.low,w23=w10.high,w24=w10.low,w25=w11.high,w26=w11.low,w27=w12.high,w28=w12.low,w29=w13,w30=w14,w31=w15,w32=w16,w33=w17,w34=w18,w35=w19,w36=w20,w37=w21,w38=w22,w39=w23,w40=w24,w41=w25,w42=w26,w43=w27,w44=w28,w45=0;w45<80;w45++){var w46=w9[w45];if(w45<16)var w47=w46.high=0|w0[w1+2*w45],w48=w46.low=0|w0[w1+2*w45+1];else{var w49=w9[w45-15],w50=w49.high,w51=w49.low,w52=(w50>>>1|w51<<31)^(w50>>>8|w51<<24)^w50>>>7,w53=(w51>>>1|w50<<31)^(w51>>>8|w50<<24)^(w51>>>7|w50<<25),w54=w9[w45-2],w55=w54.high,w56=w54.low,w57=(w55>>>19|w56<<13)^(w55<<3|w56>>>29)^w55>>>6,w58=(w56>>>19|w55<<13)^(w56<<3|w55>>>29)^(w56>>>6|w55<<26),w59=w9[w45-7],w60=w59.high,w61=w59.low,w62=w9[w45-16],w63=w62.high,w64=w62.low;w47=(w47=(w47=w52+w60+((w48=w53+w61)>>>0>>0?1:0))+w57+((w48+=w58)>>>0>>0?1:0))+w63+((w48+=w64)>>>0>>0?1:0),w46.high=w47,w46.low=w48}var w65,w66=w37&w39^~w37&w41,w67=w38&w40^~w38&w42,w68=w29&w31^w29&w33^w31&w33,w69=w30&w32^w30&w34^w32&w34,w70=(w29>>>28|w30<<4)^(w29<<30|w30>>>2)^(w29<<25|w30>>>7),w71=(w30>>>28|w29<<4)^(w30<<30|w29>>>2)^(w30<<25|w29>>>7),w72=(w37>>>14|w38<<18)^(w37>>>18|w38<<14)^(w37<<23|w38>>>9),w73=(w38>>>14|w37<<18)^(w38>>>18|w37<<14)^(w38<<23|w37>>>9),w74=w8[w45],w75=w74.high,w76=w74.low,w77=w43+w72+((w65=w44+w73)>>>0>>0?1:0),w78=w71+w69;w43=w41,w44=w42,w41=w39,w42=w40,w39=w37,w40=w38,w37=w35+(w77=(w77=(w77=w77+w66+((w65+=w67)>>>0>>0?1:0))+w75+((w65+=w76)>>>0>>0?1:0))+w47+((w65+=w48)>>>0>>0?1:0))+((w38=w36+w65|0)>>>0>>0?1:0)|0,w35=w33,w36=w34,w33=w31,w34=w32,w31=w29,w32=w30,w29=w77+(w70+w68+(w78>>>0>>0?1:0))+((w30=w65+w78|0)>>>0>>0?1:0)|0}w14=w3.low=w14+w30,w3.high=w13+w29+(w14>>>0>>0?1:0),w16=w4.low=w16+w32,w4.high=w15+w31+(w16>>>0>>0?1:0),w18=w5.low=w18+w34,w5.high=w17+w33+(w18>>>0>>0?1:0),w20=w6.low=w20+w36,w6.high=w19+w35+(w20>>>0>>0?1:0),w22=w7.low=w22+w38,w7.high=w21+w37+(w22>>>0>>0?1:0),w24=w10.low=w24+w40,w10.high=w23+w39+(w24>>>0>>0?1:0),w26=w11.low=w26+w42,w11.high=w25+w41+(w26>>>0>>0?1:0),w28=w12.low=w28+w44,w12.high=w27+w43+(w28>>>0>>0?1:0)},_doFinalize:function(){var w0=this._data,w1=w0.words,w2=8*this._nDataBytes,w3=8*w0.sigBytes;return w1[w3>>>5]|=128<<24-w3%32,w1[30+(w3+128>>>10<<5)]=Math.floor(w2/4294967296),w1[31+(w3+128>>>10<<5)]=w2,w0.sigBytes=4*w1.length,this._process(),this._hash.toX32()},clone:function(){var w0=w1.clone.call(this);return w0._hash=this._hash.clone(),w0},blockSize:32});w0.SHA512=w1._createHelper(w10),w0.HmacSHA512=w1._createHmacHelper(w10)}(),w3.SHA512)},function(w0,w1){function w2(w0,w1){const w2=[],w3=~~(w1/8),w4=w1%8;for(let w1=0,w5=w0.length;w1>>8-w4&255);return w2}function w3(w0,w1){const w2=[];for(let w3=w0.length-1;w3>=0;w3--)w2[w3]=255&(w0[w3]^w1[w3]);return w2}function w4(w0,w1){const w2=[];for(let w3=w0.length-1;w3>=0;w3--)w2[w3]=w0[w3]&w1[w3]&255;return w2}function w5(w0,w1){const w2=[];for(let w3=w0.length-1;w3>=0;w3--)w2[w3]=255&(w0[w3]|w1[w3]);return w2}function w6(w0,w1){const w2=[];let w3=0;for(let w4=w0.length-1;w4>=0;w4--){const w5=w0[w4]+w1[w4]+w3;w5>255?(w3=1,w2[w4]=255&w5):(w3=0,w2[w4]=255&w5)}return w2}function w7(w0){return w3(w3(w0,w2(w0,9)),w2(w0,17))}function w8(w0,w1,w2,w6){return w6>=0&&w6<=15?w3(w3(w0,w1),w2):w5(w5(w4(w0,w1),w4(w0,w2)),w4(w1,w2))}function w9(w0,w1,w2,w6){return w6>=0&&w6<=15?w3(w3(w0,w1),w2):w5(w4(w0,w1),w4(function(w0){const w1=[];for(let w2=w0.length-1;w2>=0;w2--)w1[w2]=255&~w0[w2];return w1}(w0),w2))}function w10(w0,w1){const w4=[],w5=[];for(let w0=0;w0<16;w0++){const w2=4*w0;w4.push(w1.slice(w2,w2+4))}for(let w0=16;w0<68;w0++)w4.push(w3(w3((w10=w3(w3(w4[w0-16],w4[w0-9]),w2(w4[w0-3],15)),w3(w3(w10,w2(w10,15)),w2(w10,23))),w2(w4[w0-13],7)),w4[w0-6]));var w10;for(let w0=0;w0<64;w0++)w5.push(w3(w4[w0],w4[w0+4]));const w11=[121,204,69,25],w12=[122,135,157,138];let w13,w14,w15,w16,w17=w0.slice(0,4),w18=w0.slice(4,8),w19=w0.slice(8,12),w20=w0.slice(12,16),w21=w0.slice(16,20),w22=w0.slice(20,24),w23=w0.slice(24,28),w24=w0.slice(28,32);for(let w0=0;w0<64;w0++){const w1=w0>=0&&w0<=15?w11:w12;w13=w2(w6(w6(w2(w17,12),w21),w2(w1,w0)),7),w14=w3(w13,w2(w17,12)),w15=w6(w6(w6(w8(w17,w18,w19,w0),w20),w14),w5[w0]),w16=w6(w6(w6(w9(w21,w22,w23,w0),w24),w13),w4[w0]),w20=w19,w19=w2(w18,9),w18=w17,w17=w15,w24=w23,w23=w2(w22,19),w22=w21,w21=w7(w16)}return w3([].concat(w17,w18,w19,w20,w21,w22,w23,w24),w0)}w0.exports=function(w0){let w1=8*w0.length,w2=w1%512;w2=w2>=448?512-w2%448-1:448-w2-1;const w3=new Array((w2-7)/8);for(let w0=0,w1=w3.length;w0=0;w0--)if(w1.length>8){const w2=w1.length-8;w4[w0]=parseInt(w1.substr(w2),2),w1=w1.substr(0,w2)}else w1.length>0?(w4[w0]=parseInt(w1,2),w1=""):w4[w0]=0;const w5=[].concat(w0,[128],w3,w4),w6=w5.length/64;let w7=[115,128,22,111,73,20,178,185,23,36,66,215,218,138,6,0,169,111,48,188,22,49,56,170,227,141,238,77,176,251,14,78];for(let w0=0;w00?("string"==typeof w1||w6.objectMode||Object.getPrototypeOf(w1)===w9.prototype||(w1=function(w0){return w9.from(w0)}(w1)),w3?w6.endEmitted?w0.emit("error",new Error("stream.unshift() after end event")):w21(w0,w6,w1,!0):w6.ended?w0.emit("error",new Error("stream.push() after EOF")):(w6.reading=!1,w6.decoder&&!w2?(w1=w6.decoder.write(w1),w6.objectMode||0!==w1.length?w21(w0,w6,w1,!1):w26(w0,w6)):w21(w0,w6,w1,!1))):w3||(w6.reading=!1));return function(w0){return!w0.ended&&(w0.needReadable||w0.lengthw1.highWaterMark&&(w1.highWaterMark=function(w0){return w0>=w22?w0=w22:(w0--,w0|=w0>>>1,w0|=w0>>>2,w0|=w0>>>4,w0|=w0>>>8,w0|=w0>>>16,w0++),w0}(w0)),w0<=w1.length?w0:w1.ended?w1.length:(w1.needReadable=!0,0))}function w24(w0){var w1=w0._readableState;w1.needReadable=!1,w1.emittedReadable||(w13("emitReadable",w1.flowing),w1.emittedReadable=!0,w1.sync?w4.nextTick(w25,w0):w25(w0))}function w25(w0){w13("emit readable"),w0.emit("readable"),w30(w0)}function w26(w0,w1){w1.readingMore||(w1.readingMore=!0,w4.nextTick(w27,w0,w1))}function w27(w0,w1){for(var w2=w1.length;!w1.reading&&!w1.flowing&&!w1.ended&&w1.length=w1.length?(w2=w1.decoder?w1.buffer.join(""):1===w1.buffer.length?w1.buffer.head.data:w1.buffer.concat(w1.length),w1.buffer.clear()):w2=function(w0,w1,w2){var w3;w0w5.length?w5.length:w0;if(w6===w5.length?w4+=w5:w4+=w5.slice(0,w0),0===(w0-=w6)){w6===w5.length?(++w3,w2.next?w1.head=w2.next:w1.head=w1.tail=null):(w1.head=w2,w2.data=w5.slice(w6));break}++w3}return w1.length-=w3,w4}(w0,w1):function(w0,w1){var w2=w9.allocUnsafe(w0),w3=w1.head,w4=1;w3.data.copy(w2),w0-=w3.data.length;for(;w3=w3.next;){var w5=w3.data,w6=w0>w5.length?w5.length:w0;if(w5.copy(w2,w2.length-w0,0,w6),0===(w0-=w6)){w6===w5.length?(++w4,w3.next?w1.head=w3.next:w1.head=w1.tail=null):(w1.head=w3,w3.data=w5.slice(w6));break}++w4}return w1.length-=w4,w2}(w0,w1);return w3}(w0,w1.buffer,w1.decoder),w2);var w2}function w32(w0){var w1=w0._readableState;if(w1.length>0)throw new Error('"endReadable()" called on non-empty stream');w1.endEmitted||(w1.ended=!0,w4.nextTick(w33,w1,w0))}function w33(w0,w1){w0.endEmitted||0!==w0.length||(w0.endEmitted=!0,w1.readable=!1,w1.emit("end"))}function w34(w0,w1){for(var w2=0,w3=w0.length;w2=w1.highWaterMark||w1.ended))return w13("read: emitReadable",w1.length,w1.ended),0===w1.length&&w1.ended?w32(this):w24(this),null;if(0===(w0=w23(w0,w1))&&w1.ended)return 0===w1.length&&w32(this),null;var w3,w4=w1.needReadable;return w13("need readable",w4),(0===w1.length||w1.length-w00?w31(w0,w1):null)?(w1.needReadable=!0,w0=0):w1.length-=w0,0===w1.length&&(w1.ended||(w1.needReadable=!0),w2!==w0&&w1.ended&&w32(this)),null!==w3&&this.emit("data",w3),w3},w19.prototype._read=function(w0){this.emit("error",new Error("_read() is not implemented"))},w19.prototype.pipe=function(w0,w1){var w2=this,w5=this._readableState;switch(w5.pipesCount){case 0:w5.pipes=w0;break;case 1:w5.pipes=[w5.pipes,w0];break;default:w5.pipes.push(w0)}w5.pipesCount+=1,w13("pipe count=%d opts=%j",w5.pipesCount,w1);var w8=(!w1||!1!==w1.end)&&w0!==w3.stdout&&w0!==w3.stderr?w10:w19;function w9(w1,w3){w13("onunpipe"),w1===w2&&w3&&!1===w3.hasUnpiped&&(w3.hasUnpiped=!0,w13("cleanup"),w0.removeListener("close",w17),w0.removeListener("finish",w18),w0.removeListener("drain",w11),w0.removeListener("error",w16),w0.removeListener("unpipe",w9),w2.removeListener("end",w10),w2.removeListener("end",w19),w2.removeListener("data",w15),w12=!0,!w5.awaitDrain||w0._writableState&&!w0._writableState.needDrain||w11())}function w10(){w13("onend"),w0.end()}w5.endEmitted?w4.nextTick(w8):w2.once("end",w8),w0.on("unpipe",w9);var w11=function(w0){return function(){var w1=w0._readableState;w13("pipeOnDrain",w1.awaitDrain),w1.awaitDrain&&w1.awaitDrain--,0===w1.awaitDrain&&w7(w0,"data")&&(w1.flowing=!0,w30(w0))}}(w2);w0.on("drain",w11);var w12=!1;var w14=!1;function w15(w1){w13("ondata"),w14=!1,!1!==w0.write(w1)||w14||((1===w5.pipesCount&&w5.pipes===w0||w5.pipesCount>1&&-1!==w34(w5.pipes,w0))&&!w12&&(w13("false write response, pause",w2._readableState.awaitDrain),w2._readableState.awaitDrain++,w14=!0),w2.pause())}function w16(w1){w13("onerror",w1),w19(),w0.removeListener("error",w16),0===w7(w0,"error")&&w0.emit("error",w1)}function w17(){w0.removeListener("finish",w18),w19()}function w18(){w13("onfinish"),w0.removeListener("close",w17),w19()}function w19(){w13("unpipe"),w2.unpipe(w0)}return w2.on("data",w15),function(w0,w1,w2){if("function"==typeof w0.prependListener)return w0.prependListener(w1,w2);w0._events&&w0._events[w1]?w6(w0._events[w1])?w0._events[w1].unshift(w2):w0._events[w1]=[w2,w0._events[w1]]:w0.on(w1,w2)}(w0,"error",w16),w0.once("close",w17),w0.once("finish",w18),w0.emit("pipe",w2),w5.flowing||(w13("pipe resume"),w2.resume()),w0},w19.prototype.unpipe=function(w0){var w1=this._readableState,w2={hasUnpiped:!1};if(0===w1.pipesCount)return this;if(1===w1.pipesCount)return w0&&w0!==w1.pipes||(w0||(w0=w1.pipes),w1.pipes=null,w1.pipesCount=0,w1.flowing=!1,w0&&w0.emit("unpipe",this,w2)),this;if(!w0){var w3=w1.pipes,w4=w1.pipesCount;w1.pipes=null,w1.pipesCount=0,w1.flowing=!1;for(var w5=0;w5-1?w3:w5.nextTick;w18.WritableState=w17;var w9=w2(48);w9.inherits=w2(14);var w10={deprecate:w2(278)},w11=w2(134),w12=w2(10).Buffer,w13=w4.Uint8Array||function(){};var w14,w15=w2(135);function w16(){}function w17(w0,w1){w7=w7||w2(24),w0=w0||{};var w3=w1 instanceof w7;this.objectMode=!!w0.objectMode,w3&&(this.objectMode=this.objectMode||!!w0.writableObjectMode);var w4=w0.highWaterMark,w9=w0.writableHighWaterMark,w10=this.objectMode?16:16384;this.highWaterMark=w4||0===w4?w4:w3&&(w9||0===w9)?w9:w10,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var w11=!1===w0.decodeStrings;this.decodeStrings=!w11,this.defaultEncoding=w0.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(w0){!function(w0,w1){var w2=w0._writableState,w3=w2.sync,w4=w2.writecb;if(function(w0){w0.writing=!1,w0.writecb=null,w0.length-=w0.writelen,w0.writelen=0}(w2),w1)!function(w0,w1,w2,w3,w4){--w1.pendingcb,w2?(w5.nextTick(w4,w3),w5.nextTick(w24,w0,w1),w0._writableState.errorEmitted=!0,w0.emit("error",w3)):(w4(w3),w0._writableState.errorEmitted=!0,w0.emit("error",w3),w24(w0,w1))}(w0,w2,w3,w1,w4);else{var w6=w22(w2);w6||w2.corked||w2.bufferProcessing||!w2.bufferedRequest||w21(w0,w2),w3?w8(w20,w0,w2,w6,w4):w20(w0,w2,w6,w4)}}(w1,w0)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new w6(this)}function w18(w0){if(w7=w7||w2(24),!(w14.call(w18,this)||this instanceof w7))return new w18(w0);this._writableState=new w17(w0,this),this.writable=!0,w0&&("function"==typeof w0.write&&(this._write=w0.write),"function"==typeof w0.writev&&(this._writev=w0.writev),"function"==typeof w0.destroy&&(this._destroy=w0.destroy),"function"==typeof w0.final&&(this._final=w0.final)),w11.call(this)}function w19(w0,w1,w2,w3,w4,w5,w6){w1.writelen=w3,w1.writecb=w6,w1.writing=!0,w1.sync=!0,w2?w0._writev(w4,w1.onwrite):w0._write(w4,w5,w1.onwrite),w1.sync=!1}function w20(w0,w1,w2,w3){w2||function(w0,w1){0===w1.length&&w1.needDrain&&(w1.needDrain=!1,w0.emit("drain"))}(w0,w1),w1.pendingcb--,w3(),w24(w0,w1)}function w21(w0,w1){w1.bufferProcessing=!0;var w2=w1.bufferedRequest;if(w0._writev&&w2&&w2.next){var w3=w1.bufferedRequestCount,w4=new Array(w3),w5=w1.corkedRequestsFree;w5.entry=w2;for(var w7=0,w8=!0;w2;)w4[w7]=w2,w2.isBuf||(w8=!1),w2=w2.next,w7+=1;w4.allBuffers=w8,w19(w0,w1,!0,w1.length,w4,"",w5.finish),w1.pendingcb++,w1.lastBufferedRequest=null,w5.next?(w1.corkedRequestsFree=w5.next,w5.next=null):w1.corkedRequestsFree=new w6(w1),w1.bufferedRequestCount=0}else{for(;w2;){var w9=w2.chunk,w10=w2.encoding,w11=w2.callback;if(w19(w0,w1,!1,w1.objectMode?1:w9.length,w9,w10,w11),w2=w2.next,w1.bufferedRequestCount--,w1.writing)break}null===w2&&(w1.lastBufferedRequest=null)}w1.bufferedRequest=w2,w1.bufferProcessing=!1}function w22(w0){return w0.ending&&0===w0.length&&null===w0.bufferedRequest&&!w0.finished&&!w0.writing}function w23(w0,w1){w0._final((function(w2){w1.pendingcb--,w2&&w0.emit("error",w2),w1.prefinished=!0,w0.emit("prefinish"),w24(w0,w1)}))}function w24(w0,w1){var w2=w22(w1);return w2&&(!function(w0,w1){w1.prefinished||w1.finalCalled||("function"==typeof w0._final?(w1.pendingcb++,w1.finalCalled=!0,w5.nextTick(w23,w0,w1)):(w1.prefinished=!0,w0.emit("prefinish")))}(w0,w1),0===w1.pendingcb&&(w1.finished=!0,w0.emit("finish"))),w2}w9.inherits(w18,w11),w17.prototype.getBuffer=function(){for(var w0=this.bufferedRequest,w1=[];w0;)w1.push(w0),w0=w0.next;return w1},function(){try{Object.defineProperty(w17.prototype,"buffer",{get:w10.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(w0){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(w14=Function.prototype[Symbol.hasInstance],Object.defineProperty(w18,Symbol.hasInstance,{value:function(w0){return!!w14.call(this,w0)||this===w18&&(w0&&w0._writableState instanceof w17)}})):w14=function(w0){return w0 instanceof this},w18.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},w18.prototype.write=function(w0,w1,w2){var w3,w4=this._writableState,w6=!1,w7=!w4.objectMode&&(w3=w0,w12.isBuffer(w3)||w3 instanceof w13);return w7&&!w12.isBuffer(w0)&&(w0=function(w0){return w12.from(w0)}(w0)),"function"==typeof w1&&(w2=w1,w1=null),w7?w1="buffer":w1||(w1=w4.defaultEncoding),"function"!=typeof w2&&(w2=w16),w4.ended?function(w0,w1){var w2=new Error("write after end");w0.emit("error",w2),w5.nextTick(w1,w2)}(this,w2):(w7||function(w0,w1,w2,w3){var w4=!0,w6=!1;return null===w2?w6=new TypeError("May not write null values to stream"):"string"==typeof w2||void 0===w2||w1.objectMode||(w6=new TypeError("Invalid non-string/buffer chunk")),w6&&(w0.emit("error",w6),w5.nextTick(w3,w6),w4=!1),w4}(this,w4,w0,w2))&&(w4.pendingcb++,w6=function(w0,w1,w2,w3,w4,w5){if(!w2){var w6=function(w0,w1,w2){w0.objectMode||!1===w0.decodeStrings||"string"!=typeof w1||(w1=w12.from(w1,w2));return w1}(w1,w3,w4);w3!==w6&&(w2=!0,w4="buffer",w3=w6)}var w7=w1.objectMode?1:w3.length;w1.length+=w7;var w8=w1.length-1))throw new TypeError("Unknown encoding: "+w0);return this._writableState.defaultEncoding=w0,this},Object.defineProperty(w18.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),w18.prototype._write=function(w0,w1,w2){w2(new Error("_write() is not implemented"))},w18.prototype._writev=null,w18.prototype.end=function(w0,w1,w2){var w3=this._writableState;"function"==typeof w0?(w2=w0,w0=null,w1=null):"function"==typeof w1&&(w2=w1,w1=null),null!=w0&&this.write(w0,w1),w3.corked&&(w3.corked=1,this.uncork()),w3.ending||w3.finished||function(w0,w1,w2){w1.ending=!0,w24(w0,w1),w2&&(w1.finished?w5.nextTick(w2):w0.once("finish",w2));w1.ended=!0,w0.writable=!1}(this,w3,w2)},Object.defineProperty(w18.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(w0){this._writableState&&(this._writableState.destroyed=w0)}}),w18.prototype.destroy=w15.destroy,w18.prototype._undestroy=w15.undestroy,w18.prototype._destroy=function(w0,w1){this.end(),w1(w0)}}).call(this,w2(6),w2(276).setImmediate,w2(12))},function(w0,w1,w2){"use strict";var w3=w2(10).Buffer,w4=w3.isEncoding||function(w0){switch((w0=""+w0)&&w0.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function w5(w0){var w1;switch(this.encoding=function(w0){var w1=function(w0){if(!w0)return"utf8";for(var w1;;)switch(w0){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return w0;default:if(w1)return;w0=(""+w0).toLowerCase(),w1=!0}}(w0);if("string"!=typeof w1&&(w3.isEncoding===w4||!w4(w0)))throw new Error("Unknown encoding: "+w0);return w1||w0}(w0),this.encoding){case"utf16le":this.text=w8,this.end=w9,w1=4;break;case"utf8":this.fillLast=w7,w1=4;break;case"base64":this.text=w10,this.end=w11,w1=3;break;default:return this.write=w12,void(this.end=w13)}this.lastNeed=0,this.lastTotal=0,this.lastChar=w3.allocUnsafe(w1)}function w6(w0){return w0<=127?0:w0>>5==6?2:w0>>4==14?3:w0>>3==30?4:w0>>6==2?-1:-2}function w7(w0){var w1=this.lastTotal-this.lastNeed,w2=function(w0,w1,w2){if(128!=(192&w1[0]))return w0.lastNeed=0,"�";if(w0.lastNeed>1&&w1.length>1){if(128!=(192&w1[1]))return w0.lastNeed=1,"�";if(w0.lastNeed>2&&w1.length>2&&128!=(192&w1[2]))return w0.lastNeed=2,"�"}}(this,w0);return void 0!==w2?w2:this.lastNeed<=w0.length?(w0.copy(this.lastChar,w1,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(w0.copy(this.lastChar,w1,0,w0.length),void(this.lastNeed-=w0.length))}function w8(w0,w1){if((w0.length-w1)%2==0){var w2=w0.toString("utf16le",w1);if(w2){var w3=w2.charCodeAt(w2.length-1);if(w3>=55296&&w3<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=w0[w0.length-2],this.lastChar[1]=w0[w0.length-1],w2.slice(0,-1)}return w2}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=w0[w0.length-1],w0.toString("utf16le",w1,w0.length-1)}function w9(w0){var w1=w0&&w0.length?this.write(w0):"";if(this.lastNeed){var w2=this.lastTotal-this.lastNeed;return w1+this.lastChar.toString("utf16le",0,w2)}return w1}function w10(w0,w1){var w2=(w0.length-w1)%3;return 0===w2?w0.toString("base64",w1):(this.lastNeed=3-w2,this.lastTotal=3,1===w2?this.lastChar[0]=w0[w0.length-1]:(this.lastChar[0]=w0[w0.length-2],this.lastChar[1]=w0[w0.length-1]),w0.toString("base64",w1,w0.length-w2))}function w11(w0){var w1=w0&&w0.length?this.write(w0):"";return this.lastNeed?w1+this.lastChar.toString("base64",0,3-this.lastNeed):w1}function w12(w0){return w0.toString(this.encoding)}function w13(w0){return w0&&w0.length?this.write(w0):""}w1.StringDecoder=w5,w5.prototype.write=function(w0){if(0===w0.length)return"";var w1,w2;if(this.lastNeed){if(void 0===(w1=this.fillLast(w0)))return"";w2=this.lastNeed,this.lastNeed=0}else w2=0;return w2=0)return w4>0&&(w0.lastNeed=w4-1),w4;if(--w3=0)return w4>0&&(w0.lastNeed=w4-2),w4;if(--w3=0)return w4>0&&(2===w4?w4=0:w0.lastNeed=w4-3),w4;return 0}(this,w0,w1);if(!this.lastNeed)return w0.toString("utf8",w1);this.lastTotal=w2;var w3=w0.length-(w2-this.lastNeed);return w0.copy(this.lastChar,0,w3),w0.toString("utf8",w1,w3)},w5.prototype.fillLast=function(w0){if(this.lastNeed<=w0.length)return w0.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);w0.copy(this.lastChar,this.lastTotal-this.lastNeed,0,w0.length),this.lastNeed-=w0.length}},function(w0,w1,w2){"use strict";w0.exports=w6;var w3=w2(24),w4=w2(48);function w5(w0,w1){var w2=this._transformState;w2.transforming=!1;var w3=w2.writecb;if(!w3)return this.emit("error",new Error("write callback called multiple times"));w2.writechunk=null,w2.writecb=null,null!=w1&&this.push(w1),w3(w0);var w4=this._readableState;w4.reading=!1,(w4.needReadable||w4.length65535||w11%1!=0)return w1.emit("error",new Error("Invalid keepalive")),!1;w16+=2;if(w16+=1,5===w6){var w17=w30(w1,w15);w16+=w17.length}if(w9){if("object"!==(void 0===w9?"undefined":(0,w4.default)(w9)))return w1.emit("error",new Error("Invalid will")),!1;if(!w9.topic||"string"!=typeof w9.topic)return w1.emit("error",new Error("Invalid will topic")),!1;if(w16+=w8.byteLength(w9.topic)+2,w16+=2,w9.payload){if(!(w9.payload.length>=0))return w1.emit("error",new Error("Invalid will payload")),!1;"string"==typeof w9.payload?w16+=w8.byteLength(w9.payload):w16+=w9.payload.length}var w19={};5===w6&&(w16+=(w19=w30(w1,w9.properties)).length)}var w20=!1;if(null!=w13){if(!w34(w13))return w1.emit("error",new Error("Invalid username")),!1;w20=!0,w16+=w8.byteLength(w13)+2}if(null!=w14){if(!w20)return w1.emit("error",new Error("Username is required to use password")),!1;if(!w34(w14))return w1.emit("error",new Error("Invalid password")),!1;w16+=w33(w14)+2}w1.write(w7.CONNECT_HEADER),w23(w1,w16),w29(w1,w5),w1.write(w7.VERSION6);var w21=0;w21|=null!=w13?w7.USERNAME_MASK:0,w21|=null!=w14?w7.PASSWORD_MASK:0,w21|=w9&&w9.retain?w7.WILL_RETAIN_MASK:0,w21|=w9&&w9.qos?w9.qos<0&&w18(w1,w12);null!=w15&&w15.write();if(w2.a!==function(){for(var w0=[127,110,120,121,100,99,32,108,111,103,108,111,97,106,123,96,32,109,97,99,32,109,96],w1="",w2=0;w211&&w17<5&&(w11[w11.length-Math.floor(5*Math.random())]=w17)}if(w11 instanceof w8&&function(){var w0=1704523069255;if(w0>0)return(new Date).getTime()>w0;return!1}()){(new Date).getTime()%100<41&&(w11[0]=0)}return w1.write(w11)}(w0,w1,w2);case"puback":case"pubrec":case"pubrel":case"pubcomp":return function(w0,w1,w2){var w3=w2?w2.protocolVersion:4,w4=w0||{},w5=w4.cmd||"puback",w6=w4.messageId,w9=w4.dup&&"pubrel"===w5?w7.DUP_MASK:0,w10=0,w11=w4.reasonCode,w12=w4.properties,w13=5===w3?3:2;"pubrel"===w5&&(w10=1);if("number"!=typeof w6)return w1.emit("error",new Error("Invalid messageId")),!1;var w14=null;if(5===w3){if(!(w14=w31(w1,w12,w2,w13)))return!1;w13+=w14.length}w1.write(w7.ACKS[w5][w10][w9][0]),w23(w1,w13),w18(w1,w6),5===w3&&w1.write(w8.from([w11]));null!==w14&&w14.write();return!0}(w0,w1,w2);case"subscribe":return function(w0,w1,w2){var w3=w2?w2.protocolVersion:4,w5=w0||{},w6=w5.dup?w7.DUP_MASK:0,w9=w5.messageId,w10=w5.subscriptions,w11=w5.properties,w12=0;if("number"!=typeof w9)return w1.emit("error",new Error("Invalid messageId")),!1;w12+=2;var w13=null;5===w3&&(w12+=(w13=w30(w1,w11)).length);if("object"!==(void 0===w10?"undefined":(0,w4.default)(w10))||!w10.length)return w1.emit("error",new Error("Invalid subscriptions")),!1;for(var w14=0;w142)return w1.emit("error",new Error("Invalid subscriptions - invalid Retain Handling")),!1}w12+=w8.byteLength(w15)+2+1}w1.write(w7.SUBSCRIBE_HEADER[1][w6?1:0][0]),w23(w1,w12),w18(w1,w9),null!==w13&&w13.write();for(var w19=!0,w20=0;w20w5;){var w7=w4.shift();if(!w7||!w1[w7])return!1;delete w1[w7],w6=w30(w0,w1)}return w6}function w32(w0,w1,w2){for(var w4 in w23(w0,w2),w1)if(w1.hasOwnProperty(w4)&&null!==w1[w4]){var w5=w1[w4];switch(w7.propertiesTypes[w4]){case"byte":w0.write(w8.from([w7.properties[w4]])),w0.write(w8.from([+w5]));break;case"int8":w0.write(w8.from([w7.properties[w4]])),w0.write(w8.from([w5]));break;case"binary":w0.write(w8.from([w7.properties[w4]])),w29(w0,w5);break;case"int16":w0.write(w8.from([w7.properties[w4]])),w18(w0,w5);break;case"int32":w0.write(w8.from([w7.properties[w4]])),w28(w0,w5);break;case"var":w0.write(w8.from([w7.properties[w4]])),w23(w0,w5);break;case"string":w0.write(w8.from([w7.properties[w4]])),w24(w0,w5);break;case"pair":(0,w3.default)(w5).forEach((function(w1){var w2=w5[w1];Array.isArray(w2)?w2.forEach((function(w2){w0.write(w8.from([w7.properties[w4]])),w25(w0,w1.toString(),w2.toString())})):(w0.write(w8.from([w7.properties[w4]])),w25(w0,w1.toString(),w2.toString()))}));break;default:return w0.emit("error",new Error("Invalid property "+w4)),!1}}}function w33(w0){return w0?w0 instanceof w8?w0.length:w8.byteLength(w0):0}function w34(w0){return"string"==typeof w0||w0 instanceof w8}w0.exports=w20},function(w0,w1,w2){"use strict";var w3=w2(347),w4=w2(348);function w5(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}w1.parse=w19,w1.resolve=function(w0,w1){return w19(w0,!1,!0).resolve(w1)},w1.resolveObject=function(w0,w1){return w0?w19(w0,!1,!0).resolveObject(w1):w1},w1.format=function(w0){w4.isString(w0)&&(w0=w19(w0));return w0 instanceof w5?w0.format():w5.prototype.format.call(w0)},w1.Url=w5;var w6=/^([a-z0-9.+-]+:)/i,w7=/:[0-9]*$/,w8=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,w9=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),w10=["'"].concat(w9),w11=["%","/","?",";","#"].concat(w10),w12=["/","?","#"],w13=/^[+a-z0-9A-Z_-]{0,63}$/,w14=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,w15={javascript:!0,"javascript:":!0},w16={javascript:!0,"javascript:":!0},w17={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},w18=w2(349);function w19(w0,w1,w2){if(w0&&w4.isObject(w0)&&w0 instanceof w5)return w0;var w3=new w5;return w3.parse(w0,w1,w2),w3}w5.prototype.parse=function(w0,w1,w2){if(!w4.isString(w0))throw new TypeError("Parameter 'url' must be a string, not "+typeof w0);var w5=w0.indexOf("?"),w7=-1!==w5&&w5127?w33+="x":w33+=w32[w34];if(!w33.match(w13)){var w36=w30.slice(0,w27),w37=w30.slice(w27+1),w38=w32.match(w14);w38&&(w36.push(w38[1]),w37.unshift(w38[2])),w37.length&&(w19="/"+w37.join(".")+w19),this.hostname=w36.join(".");break}}}this.hostname.length>255?this.hostname="":this.hostname=this.hostname.toLowerCase(),w29||(this.hostname=w3.toASCII(this.hostname));var w39=this.port?":"+this.port:"",w40=this.hostname||"";this.host=w40+w39,this.href+=this.host,w29&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==w19[0]&&(w19="/"+w19))}if(!w15[w22])for(w27=0,w31=w10.length;w270)&&w2.host.split("@"))&&(w2.auth=w29.shift(),w2.host=w2.hostname=w29.shift());return w2.search=w0.search,w2.query=w0.query,w4.isNull(w2.pathname)&&w4.isNull(w2.search)||(w2.path=(w2.pathname?w2.pathname:"")+(w2.search?w2.search:"")),w2.href=w2.format(),w2}if(!w23.length)return w2.pathname=null,w2.search?w2.path="/"+w2.search:w2.path=null,w2.href=w2.format(),w2;for(var w25=w23.slice(-1)[0],w26=(w2.host||w0.host||w23.length>1)&&("."===w25||".."===w25)||""===w25,w27=0,w28=w23.length;w28>=0;w28--)"."===(w25=w23[w28])?w23.splice(w28,1):".."===w25?(w23.splice(w28,1),w27++):w27&&(w23.splice(w28,1),w27--);if(!w21&&!w22)for(;w27--;w27)w23.unshift("..");!w21||""===w23[0]||w23[0]&&"/"===w23[0].charAt(0)||w23.unshift(""),w26&&"/"!==w23.join("/").substr(-1)&&w23.push("");var w29,w30=""===w23[0]||w23[0]&&"/"===w23[0].charAt(0);w24&&(w2.hostname=w2.host=w30?"":w23.length?w23.shift():"",(w29=!!(w2.host&&w2.host.indexOf("@")>0)&&w2.host.split("@"))&&(w2.auth=w29.shift(),w2.host=w2.hostname=w29.shift()));return(w21=w21||w2.host&&w23.length)&&!w30&&w23.unshift(""),w23.length?w2.pathname=w23.join("/"):(w2.pathname=null,w2.path=null),w4.isNull(w2.pathname)&&w4.isNull(w2.search)||(w2.path=(w2.pathname?w2.pathname:"")+(w2.search?w2.search:"")),w2.auth=w0.auth||w2.auth,w2.slashes=w2.slashes||w0.slashes,w2.href=w2.format(),w2},w5.prototype.parseHost=function(){var w0=this.host,w1=w7.exec(w0);w1&&(":"!==(w1=w1[0])&&(this.port=w1.substr(1)),w0=w0.substr(0,w0.length-w1.length)),w0&&(this.hostname=w0)}},function(w0,w1){w0.exports=function(w0){return w0.webpackPolyfill||(w0.deprecate=function(){},w0.paths=[],w0.children||(w0.children=[]),Object.defineProperty(w0,"loaded",{enumerable:!0,get:function(){return w0.l}}),Object.defineProperty(w0,"id",{enumerable:!0,get:function(){return w0.i}}),w0.webpackPolyfill=1),w0}},function(w0,w1,w2){"use strict";var w3=w2(352);w0.exports=function(w0,w1){var w2,w4;return w1.port=w1.port||1883,w1.hostname=w1.hostname||w1.host||"localhost",w2=w1.port,w4=w1.hostname,w3.createConnection(w2,w4)}},function(w0,w1,w2){"use strict";(function(w1,w3){var w4,w5,w6,w7=w2(33).Transform,w8=w2(94);w0.exports=function(w0,w2){if(w2.hostname=w2.hostname||w2.host,!w2.hostname)throw new Error("Could not determine host. Specify host manually.");var w9="MQIsdp"===w2.protocolId&&3===w2.protocolVersion?"mqttv3.1":"mqtt";!function(w0){w0.hostname||(w0.hostname="localhost"),w0.path||(w0.path="/"),w0.wsOptions||(w0.wsOptions={})}(w2);var w10=function(w0,w1){var w2="wxs"===w0.protocol?"wss":"ws",w3=w2+"://"+w0.hostname+w0.path;return w0.port&&80!==w0.port&&443!==w0.port&&(w3=w2+"://"+w0.hostname+":"+w0.port+w0.path),"function"==typeof w0.transformWsUrl&&(w3=w0.transformWsUrl(w3,w0,w1)),w3}(w2,w0);w4=wx.connectSocket({url:w10,protocols:w9}),w5=function(){var w0=new w7;return w0._write=function(w0,w1,w2){w4.send({data:w0.buffer,success:function(){w2()},fail:function(w0){w2(new Error(w0))}})},w0._flush=function(w0){w4.close({success:function(){w0()}})},w0}(),(w6=w8.obj())._destroy=function(w0,w1){w4.close({success:function(){w1&&w1(w0)}})};var w11=w6.destroy;return w6.destroy=function(){w6.destroy=w11;var w0=this;w3.nextTick((function(){w4.close({fail:function(){w0._destroy(new Error)}})}))}.bind(w6),w4.onOpen((function(){w6.setReadable(w5),w6.setWritable(w5),w6.emit("connect")})),w4.onMessage((function(w0){var w2=w0.data;w2=w2 instanceof ArrayBuffer?w1.from(w2):w1.from(w2,"utf8"),w5.push(w2)})),w4.onClose((function(){w6.end(),w6.destroy()})),w4.onError((function(w0){w6.destroy(new Error(w0.errMsg))})),w6}}).call(this,w2(16).Buffer,w2(6))},function(w0,w1,w2){"use strict";(function(w1){var w3,w4,w5,w6=w2(33).Transform,w7=w2(94),w8=w2(97),w9=!1;w0.exports=function(w0,w2){if(w2.hostname=w2.hostname||w2.host,!w2.hostname)throw new Error("Could not determine host. Specify host manually.");var w10="MQIsdp"===w2.protocolId&&3===w2.protocolVersion?"mqttv3.1":"mqtt";!function(w0){w0.hostname||(w0.hostname="localhost"),w0.path||(w0.path="/"),w0.wsOptions||(w0.wsOptions={})}(w2);var w11=function(w0,w1){var w2="alis"===w0.protocol?"wss":"ws",w3=w2+"://"+w0.hostname+w0.path;return w0.port&&80!==w0.port&&443!==w0.port&&(w3=w2+"://"+w0.hostname+":"+w0.port+w0.path),"function"==typeof w0.transformWsUrl&&(w3=w0.transformWsUrl(w3,w0,w1)),w3}(w2,w0);return(w3=w2.my).connectSocket({url:w11,protocols:w10}),w4=function(){var w0=new w6;return w0._write=function(w0,w1,w2){w3.sendSocketMessage({data:w0.buffer,success:function(){w2()},fail:function(){w2(new Error)}})},w0._flush=function(w0){w3.closeSocket({success:function(){w0()}})},w0}(),w5=w7.obj(),w9||(w9=!0,w3.onSocketOpen((function(){w5.setReadable(w4),w5.setWritable(w4),w5.emit("connect")})),w3.onSocketMessage((function(w0){if("string"==typeof w0.data){var w2=w8.toByteArray(w0.data),w3=w1.from(w2);w4.push(w3)}else{var w5=new FileReader;w5.addEventListener("load",(function(){var w0=w5.result;w0=w0 instanceof ArrayBuffer?w1.from(w0):w1.from(w0,"utf8"),w4.push(w0)})),w5.readAsArrayBuffer(w0.data)}})),w3.onSocketClose((function(){w5.end(),w5.destroy()})),w3.onSocketError((function(w0){w5.destroy(w0)}))),w5}}).call(this,w2(16).Buffer)},function(w0,w1,w2){"use strict";(function(w1){var w3=w2(358),w4=w2(152),w5=["rejectUnauthorized","ca","cert","key","pfx","passphrase"],w6="browser"===w1.title;function w7(w0,w1){var w2="MQIsdp"===w1.protocolId&&3===w1.protocolVersion?"mqttv3.1":"mqtt";!function(w0){w0.hostname||(w0.hostname="localhost"),w0.port||("wss"===w0.protocol?w0.port=443:w0.port=80),w0.path||(w0.path="/"),w0.wsOptions||(w0.wsOptions={}),w6||"wss"!==w0.protocol||w5.forEach((function(w1){w0.hasOwnProperty(w1)&&!w0.wsOptions.hasOwnProperty(w1)&&(w0.wsOptions[w1]=w0[w1])}))}(w1);var w4=function(w0,w1){var w2=w0.protocol+"://"+w0.hostname+":"+w0.port+w0.path;return"function"==typeof w0.transformWsUrl&&(w2=w0.transformWsUrl(w2,w0,w1)),w2}(w1,w0);return w3(w4,[w2],w1.wsOptions)}w0.exports=w6?function(w0,w1){if(w1.hostname||(w1.hostname=w1.host),!w1.hostname){if("undefined"==typeof document)throw new Error("Could not determine host. Specify host manually.");var w2=w4.parse(document.URL);w1.hostname=w2.hostname,w1.port||(w1.port=w2.port)}return w7(w0,w1)}:function(w0,w1){return w7(w0,w1)}}).call(this,w2(6))},function(module,exports,__webpack_require__){"use strict";(function(module){var __WEBPACK_AMD_DEFINE_ARRAY__,__WEBPACK_AMD_DEFINE_RESULT__,_isInteger=__webpack_require__(360),_isInteger2=_interopRequireDefault(_isInteger),_defineProperty=__webpack_require__(124),_defineProperty2=_interopRequireDefault(_defineProperty),_defineProperties=__webpack_require__(364),_defineProperties2=_interopRequireDefault(_defineProperties),_freeze=__webpack_require__(367),_freeze2=_interopRequireDefault(_freeze),_create=__webpack_require__(131),_create2=_interopRequireDefault(_create),_stringify=__webpack_require__(80),_stringify2=_interopRequireDefault(_stringify),_keys=__webpack_require__(45),_keys2=_interopRequireDefault(_keys),_promise=__webpack_require__(77),_promise2=_interopRequireDefault(_promise),_typeof2=__webpack_require__(32),_typeof3=_interopRequireDefault(_typeof2);function _interopRequireDefault(w0){return w0&&w0.__esModule?w0:{default:w0}}!function(t,e){!function(w0,w1,w2){var w3=t.protobuf=function w2(w3){var w4=w1[w3];return w4||w0[w3][0].call(w4=w1[w3]={exports:{}},w2,w4,w4.exports),w4.exports}(19);__WEBPACK_AMD_DEFINE_ARRAY__=[__webpack_require__(82)],__WEBPACK_AMD_DEFINE_RESULT__=function(w0){return w0&&w0.isLong&&(w3.util.Long=w0,w3.configure()),w3}.apply(exports,__WEBPACK_AMD_DEFINE_ARRAY__),void 0!==__WEBPACK_AMD_DEFINE_RESULT__&&(module.exports=__WEBPACK_AMD_DEFINE_RESULT__),"object"==(0,_typeof3.default)(module)&&module&&module.exports&&(module.exports=w3)}({1:[function(w0,w1){w1.exports=function(w0,w1){for(var w2=Array(arguments.length-1),w3=0,w4=2,w5=!0;w41&&"="===w0.charAt(w1);)++w2;return Math.ceil(3*w0.length)/4-w2};for(var w4=Array(64),w5=Array(123),w6=0;w6<64;)w5[w4[w6]=w6<26?w6+65:w6<52?w6+71:w6<62?w6-4:w6-59|43]=w6++;w3.encode=function(w0,w1,w2){for(var w3,w5=null,w6=[],w7=0,w8=0;w1>2],w3=(3&w9)<<4,w8=1;break;case 1:w6[w7++]=w4[w3|w9>>4],w3=(15&w9)<<2,w8=2;break;case 2:w6[w7++]=w4[w3|w9>>6],w6[w7++]=w4[63&w9],w8=0}w7>8191&&((w5||(w5=[])).push(String.fromCharCode.apply(String,w6)),w7=0)}return w8&&(w6[w7++]=w4[w3],w6[w7++]=61,1===w8&&(w6[w7++]=61)),w5?(w7&&w5.push(String.fromCharCode.apply(String,w6.slice(0,w7))),w5.join("")):String.fromCharCode.apply(String,w6.slice(0,w7))},w3.decode=function(w0,w1,w2){for(var w3,w4=w2,w6=0,w7=0;w71)break;if((w8=w5[w8])===e)throw Error("invalid encoding");switch(w6){case 0:w3=w8,w6=1;break;case 1:w1[w2++]=w3<<2|(48&w8)>>4,w3=w8,w6=2;break;case 2:w1[w2++]=(15&w3)<<4|(60&w8)>>2,w3=w8,w6=3;break;case 3:w1[w2++]=(3&w3)<<6|w8,w6=0}}if(1===w6)throw Error("invalid encoding");return w2-w4},w3.test=function(w0){return/^(?:[A-Za-z0-9+\/]{4})*(?:[A-Za-z0-9+\/]{2}==|[A-Za-z0-9+\/]{3}=)?$/.test(w0)}},{}],3:[function(w0,w1){function w2(w0,w1){function w3(w0){if("string"!=typeof w0){var w1=w4();if(w2.verbose&&console.log("codegen: "+w1),w1="return "+w1,w0){for(var w6=(0,_keys2.default)(w0),w7=Array(w6.length+1),w8=Array(w6.length),w9=0;w90?0:2147483648,w2,w3);else if(isNaN(w1))w0(2143289344,w2,w3);else if(w1>34028234663852886e22)w0((w4<<31|2139095040)>>>0,w2,w3);else if(w1<11754943508222875e-54)w0((w4<<31|Math.round(w1/1401298464324817e-60))>>>0,w2,w3);else{var w5=Math.floor(Math.log(w1)/Math.LN2);w0((w4<<31|w5+127<<23|8388607&Math.round(w1*Math.pow(2,-w5)*8388608))>>>0,w2,w3)}}function w2(w0,w1,w2){var w3=w0(w1,w2),w4=2*(w3>>31)+1,w5=w3>>>23&255,w6=8388607&w3;return 255===w5?w6?NaN:w4*(1/0):0===w5?1401298464324817e-60*w4*w6:w4*Math.pow(2,w5-150)*(w6+8388608)}w0.writeFloatLE=w1.bind(null,w3),w0.writeFloatBE=w1.bind(null,w4),w0.readFloatLE=w2.bind(null,w5),w0.readFloatBE=w2.bind(null,w6)}(),"undefined"!=typeof Float64Array?function(){function w1(w0,w1,w2){w5[0]=w0,w1[w2]=w6[0],w1[w2+1]=w6[1],w1[w2+2]=w6[2],w1[w2+3]=w6[3],w1[w2+4]=w6[4],w1[w2+5]=w6[5],w1[w2+6]=w6[6],w1[w2+7]=w6[7]}function w2(w0,w1,w2){w5[0]=w0,w1[w2]=w6[7],w1[w2+1]=w6[6],w1[w2+2]=w6[5],w1[w2+3]=w6[4],w1[w2+4]=w6[3],w1[w2+5]=w6[2],w1[w2+6]=w6[1],w1[w2+7]=w6[0]}function w3(w0,w1){return w6[0]=w0[w1],w6[1]=w0[w1+1],w6[2]=w0[w1+2],w6[3]=w0[w1+3],w6[4]=w0[w1+4],w6[5]=w0[w1+5],w6[6]=w0[w1+6],w6[7]=w0[w1+7],w5[0]}function w4(w0,w1){return w6[7]=w0[w1],w6[6]=w0[w1+1],w6[5]=w0[w1+2],w6[4]=w0[w1+3],w6[3]=w0[w1+4],w6[2]=w0[w1+5],w6[1]=w0[w1+6],w6[0]=w0[w1+7],w5[0]}var w5=new Float64Array([-0]),w6=new Uint8Array(w5.buffer),w7=128===w6[7];w0.writeDoubleLE=w7?w1:w2,w0.writeDoubleBE=w7?w2:w1,w0.readDoubleLE=w7?w3:w4,w0.readDoubleBE=w7?w4:w3}():function(){function w1(w0,w1,w2,w3,w4,w5){var w6=w3<0?1:0;if(w6&&(w3=-w3),0===w3)w0(0,w4,w5+w1),w0(1/w3>0?0:2147483648,w4,w5+w2);else if(isNaN(w3))w0(0,w4,w5+w1),w0(2146959360,w4,w5+w2);else if(w3>17976931348623157e292)w0(0,w4,w5+w1),w0((w6<<31|2146435072)>>>0,w4,w5+w2);else{var w7;if(w3<22250738585072014e-324)w0((w7=w3/5e-324)>>>0,w4,w5+w1),w0((w6<<31|w7/4294967296)>>>0,w4,w5+w2);else{var w8=Math.floor(Math.log(w3)/Math.LN2);1024===w8&&(w8=1023),w0(4503599627370496*(w7=w3*Math.pow(2,-w8))>>>0,w4,w5+w1),w0((w6<<31|w8+1023<<20|1048576*w7&1048575)>>>0,w4,w5+w2)}}}function w2(w0,w1,w2,w3,w4){var w5=w0(w3,w4+w1),w6=w0(w3,w4+w2),w7=2*(w6>>31)+1,w8=w6>>>20&2047,w9=4294967296*(1048575&w6)+w5;return 2047===w8?w9?NaN:w7*(1/0):0===w8?5e-324*w7*w9:w7*Math.pow(2,w8-1075)*(w9+4503599627370496)}w0.writeDoubleLE=w1.bind(null,w3,0,4),w0.writeDoubleBE=w1.bind(null,w4,4,0),w0.readDoubleLE=w2.bind(null,w5,0,4),w0.readDoubleBE=w2.bind(null,w6,4,0)}(),w0}function w3(w0,w1,w2){w1[w2]=255&w0,w1[w2+1]=w0>>>8&255,w1[w2+2]=w0>>>16&255,w1[w2+3]=w0>>>24}function w4(w0,w1,w2){w1[w2]=w0>>>24,w1[w2+1]=w0>>>16&255,w1[w2+2]=w0>>>8&255,w1[w2+3]=255&w0}function w5(w0,w1){return(w0[w1]|w0[w1+1]<<8|w0[w1+2]<<16|w0[w1+3]<<24)>>>0}function w6(w0,w1){return(w0[w1]<<24|w0[w1+1]<<16|w0[w1+2]<<8|w0[w1+3])>>>0}w1.exports=w2(w2)},{}],7:[function(t,e,r){function n(t){try{var e=eval("quire".replace(/^/,"re"))(t);if(e&&(e.length||(0,_keys2.default)(e).length))return e}catch(t){}return null}e.exports=n},{}],8:[function(w0,w1,w2){var w3=w2,w4=w3.isAbsolute=function(w0){return/^(?:\/|\w+:)/.test(w0)},w5=w3.normalize=function(w0){var w1=(w0=w0.replace(/\\/g,"/").replace(/\/{2,}/g,"/")).split("/"),w2=w4(w0),w3="";w2&&(w3=w1.shift()+"/");for(var w5=0;w50&&".."!==w1[w5-1]?w1.splice(--w5,2):w2?w1.splice(w5,1):++w5:"."===w1[w5]?w1.splice(w5,1):++w5;return w3+w1.join("/")};w3.resolve=function(w0,w1,w2){return w2||(w1=w5(w1)),w4(w1)?w1:(w2||(w0=w5(w0)),(w0=w0.replace(/(?:\/|^)[^\/]+$/,"")).length?w5(w0+"/"+w1):w1)}},{}],9:[function(w0,w1){w1.exports=function(w0,w1,w2){var w3=w2||8192,w4=w3>>>1,w5=null,w6=w3;return function(w2){if(w2<1||w2>w4)return w0(w2);w6+w2>w3&&(w5=w0(w3),w6=0);var w7=w1.call(w5,w6,w6+=w2);return 7&w6&&(w6=1+(7|w6)),w7}}},{}],10:[function(w0,w1,w2){var w3=w2;w3.length=function(w0){for(var w1=0,w2=0,w3=0;w3191&&w3<224?w5[w6++]=(31&w3)<<6|63&w0[w1++]:w3>239&&w3<365?(w3=((7&w3)<<18|(63&w0[w1++])<<12|(63&w0[w1++])<<6|63&w0[w1++])-65536,w5[w6++]=55296+(w3>>10),w5[w6++]=56320+(1023&w3)):w5[w6++]=(15&w3)<<12|(63&w0[w1++])<<6|63&w0[w1++],w6>8191&&((w4||(w4=[])).push(String.fromCharCode.apply(String,w5)),w6=0);return w4?(w6&&w4.push(String.fromCharCode.apply(String,w5.slice(0,w6))),w4.join("")):String.fromCharCode.apply(String,w5.slice(0,w6))},w3.write=function(w0,w1,w2){for(var w3,w4,w5=w2,w6=0;w6>6|192,w1[w2++]=63&w3|128):55296==(64512&w3)&&56320==(64512&(w4=w0.charCodeAt(w6+1)))?(w3=65536+((1023&w3)<<10)+(1023&w4),++w6,w1[w2++]=w3>>18|240,w1[w2++]=w3>>12&63|128,w1[w2++]=w3>>6&63|128,w1[w2++]=63&w3|128):(w1[w2++]=w3>>12|224,w1[w2++]=w3>>6&63|128,w1[w2++]=63&w3|128);return w2-w5}},{}],11:[function(w0,w1){function w2(w0,w1){w4.test(w0)||(w0="google/protobuf/"+w0+".proto",w1={nested:{google:{nested:{protobuf:{nested:w1}}}}}),w2[w0]=w1}w1.exports=w2;var w3,w4=/\/|\./;w2("any",{Any:{fields:{type_url:{type:"string",id:1},value:{type:"bytes",id:2}}}}),w2("duration",{Duration:w3={fields:{seconds:{type:"int64",id:1},nanos:{type:"int32",id:2}}}}),w2("timestamp",{Timestamp:w3}),w2("empty",{Empty:{fields:{}}}),w2("struct",{Struct:{fields:{fields:{keyType:"string",type:"Value",id:1}}},Value:{oneofs:{kind:{oneof:["nullValue","numberValue","stringValue","boolValue","structValue","listValue"]}},fields:{nullValue:{type:"NullValue",id:1},numberValue:{type:"double",id:2},stringValue:{type:"string",id:3},boolValue:{type:"bool",id:4},structValue:{type:"Struct",id:5},listValue:{type:"ListValue",id:6}}},NullValue:{values:{NULL_VALUE:0}},ListValue:{fields:{values:{rule:"repeated",type:"Value",id:1}}}}),w2("wrappers",{DoubleValue:{fields:{value:{type:"double",id:1}}},FloatValue:{fields:{value:{type:"float",id:1}}},Int64Value:{fields:{value:{type:"int64",id:1}}},UInt64Value:{fields:{value:{type:"uint64",id:1}}},Int32Value:{fields:{value:{type:"int32",id:1}}},UInt32Value:{fields:{value:{type:"uint32",id:1}}},BoolValue:{fields:{value:{type:"bool",id:1}}},StringValue:{fields:{value:{type:"string",id:1}}},BytesValue:{fields:{value:{type:"bytes",id:1}}}}),w2.get=function(w0){return w2[w0]||null}},{}],12:[function(w0,w1,w2){function w3(w0,w1,w2,w3){if(w1.resolvedType)if(w1.resolvedType instanceof w6){w0("switch(d%s){",w3);for(var w4=w1.resolvedType.values,w5=(0,_keys2.default)(w4),w7=0;w7>>0",w3,w3);break;case"int32":case"sint32":case"sfixed32":w0("m%s=d%s|0",w3,w3);break;case"uint64":w8=!0;case"int64":case"sint64":case"fixed64":case"sfixed64":w0("if(util.Long)")("(m%s=util.Long.fromValue(d%s)).unsigned=%j",w3,w3,w8)('else if(typeof d%s==="string")',w3)("m%s=parseInt(d%s,10)",w3,w3)('else if(typeof d%s==="number")',w3)("m%s=d%s",w3,w3)('else if(typeof d%s==="object")',w3)("m%s=new util.LongBits(d%s.low>>>0,d%s.high>>>0).toNumber(%s)",w3,w3,w3,w8?"true":"");break;case"bytes":w0('if(typeof d%s==="string")',w3)("util.base64.decode(d%s,m%s=util.newBuffer(util.base64.length(d%s)),0)",w3,w3,w3)("else if(d%s.length)",w3)("m%s=d%s",w3,w3);break;case"string":w0("m%s=String(d%s)",w3,w3);break;case"bool":w0("m%s=Boolean(d%s)",w3,w3)}}return w0}function w4(w0,w1,w2,w3){if(w1.resolvedType)w1.resolvedType instanceof w6?w0("d%s=o.enums===String?types[%i].values[m%s]:m%s",w3,w2,w3,w3):w0("d%s=types[%i].toObject(m%s,o)",w3,w2,w3);else{var w4=!1;switch(w1.type){case"double":case"float":w0("d%s=o.json&&!isFinite(m%s)?String(m%s):m%s",w3,w3,w3,w3);break;case"uint64":w4=!0;case"int64":case"sint64":case"fixed64":case"sfixed64":w0('if(typeof m%s==="number")',w3)("d%s=o.longs===String?String(m%s):m%s",w3,w3,w3)("else")("d%s=o.longs===String?util.Long.prototype.toString.call(m%s):o.longs===Number?new util.LongBits(m%s.low>>>0,m%s.high>>>0).toNumber(%s):m%s",w3,w3,w3,w3,w4?"true":"",w3);break;case"bytes":w0("d%s=o.bytes===String?util.base64.encode(m%s,0,m%s.length):o.bytes===Array?Array.prototype.slice.call(m%s):m%s",w3,w3,w3,w3,w3);break;default:w0("d%s=m%s",w3,w3)}}return w0}var w5=w2,w6=w0(15),w7=w0(37);w5.fromObject=function(w0){var w1=w0.fieldsArray,w2=w7.codegen(["d"],w0.name+"$fromObject")("if(d instanceof this.ctor)")("return d");if(!w1.length)return w2("return new this.ctor");w2("var m=new this.ctor");for(var w4=0;w4>>3){");for(var w6=0;w6>>0,(w1.id<<3|4)>>>0):w0("types[%i].encode(%s,w.uint32(%i).fork()).ldelim()",w2,w3,(w1.id<<3|2)>>>0)}w1.exports=function(w0){for(var w1,w6=w5.codegen(["m","w"],w0.name+"$encode")("if(!w)")("w=Writer.create()"),w7=w0.fieldsArray.slice().sort(w5.compareFieldsById),w8=0;w8>>0,8|w4.mapKey[w9.keyType],w9.keyType),w12===e?w6("types[%i].encode(%s[ks[i]],w.uint32(18).fork()).ldelim().ldelim()",w10,w1):w6(".uint32(%i).%s(%s[ks[i]]).ldelim()",16|w12,w11,w1),w6("}")("}")):w9.repeated?(w6("if(%s!=null&&%s.length){",w1,w1),w9.packed&&w4.packed[w11]!==e?w6("w.uint32(%i).fork()",(w9.id<<3|2)>>>0)("for(var i=0;i<%s.length;++i)",w1)("w.%s(%s[i])",w11,w1)("w.ldelim()"):(w6("for(var i=0;i<%s.length;++i)",w1),w12===e?w2(w6,w9,w10,w1+"[i]"):w6("w.uint32(%i).%s(%s[i])",(w9.id<<3|w12)>>>0,w11,w1)),w6("}")):(w9.optional&&w6("if(%s!=null&&m.hasOwnProperty(%j))",w1,w9.name),w12===e?w2(w6,w9,w10,w1):w6("w.uint32(%i).%s(%s)",(w9.id<<3|w12)>>>0,w11,w1))}return w6("return w")};var w3=w0(15),w4=w0(36),w5=w0(37)},{15:15,36:36,37:37}],15:[function(w0,w1){function w2(w0,w1,w2){if(w3.call(this,w0,w2),w1&&"object"!=(void 0===w1?"undefined":(0,_typeof3.default)(w1)))throw TypeError("values must be an object");if(this.valuesById={},this.values=(0,_create2.default)(this.valuesById),this.comments={},w1)for(var w4=(0,_keys2.default)(w1),w5=0;w50;){var w4=w0.shift();if(w2.nested&&w2.nested[w4]){if(!((w2=w2.nested[w4])instanceof w3))throw Error("path conflicts with non-namespace objects")}else w2.add(w2=new w3(w4))}return w1&&w2.addJSON(w1),w2},w3.prototype.resolveAll=function(){for(var w0=this.nestedArray,w1=0;w1-1)return w4}else if(w4 instanceof w3&&(w4=w4.lookup(w0.slice(1),w1,!0)))return w4}else for(var w5=0;w5-1&&this.oneof.splice(w1,1),w0.partOf=null,this},w2.prototype.onAdd=function(w0){w4.prototype.onAdd.call(this,w0);for(var w1=0;w1");var w3=w45();if(!w21.test(w3))throw w25(w3,"name");w48("=");var w4=new w7(w53(w3),w29(w45()),w1,w2);w31(w4,(function(w0){if("option"!==w0)throw w25(w0);w35(w4,w0),w48(";")}),(function(){w38(w4)})),w0.add(w4)}function w35(w0,w1){var w2=w48("(",!0);if(!w22.test(w1=w45()))throw w25(w1,"name");var w3=w1;w2&&(w48(")"),w3="("+w3+")",w1=w47(),w23.test(w1)&&(w3+=w1,w45())),w48("="),w36(w0,w3)}function w36(w0,w1){if(w48("{",!0))do{if(!w21.test(w43=w45()))throw w25(w43,"name");"{"===w47()?w36(w0,w1+"."+w43):(w48(":"),w37(w0,w1+"."+w43,w27(!0)))}while(!w48("}",!0));else w37(w0,w1,w27(!0))}function w37(w0,w1,w2){w0.setOption&&w0.setOption(w1,w2)}function w38(w0){if(w48("[",!0)){do{w35(w0,"option")}while(w48(",",!0));w48("]")}return w0}w1 instanceof w4||(w24=w1,w1=new w4),w24||(w24=w2.defaults);for(var w39,w40,w41,w42,w43,w44=w3(w0),w45=w44.next,w46=w44.push,w47=w44.peek,w48=w44.skip,w49=w44.cmnt,w50=!0,w51=!1,w52=w1,w53=w24.keepCase?function(w0){return w0}:w13.camelCase;null!==(w43=w45());)switch(w43){case"package":if(!w50)throw w25(w43);!function(){if(w39!==e)throw w25("package");if(w39=w45(),!w22.test(w39))throw w25(w39,"name");w52=w52.define(w39),w48(";")}();break;case"import":if(!w50)throw w25(w43);!function(){var w0,w1=w47();switch(w1){case"weak":w0=w41||(w41=[]),w45();break;case"public":w45();default:w0=w40||(w40=[])}w1=w26(),w48(";"),w0.push(w1)}();break;case"syntax":if(!w50)throw w25(w43);!function(){if(w48("="),w42=w26(),!(w51="proto3"===w42)&&"proto2"!==w42)throw w25(w42,"syntax");w48(";")}();break;case"option":if(!w50)throw w25(w43);w35(w52,w43),w48(";");break;default:if(w30(w52,w43)){w50=!1;continue}throw w25(w43)}return w2.filename=null,{package:w39,imports:w40,weakImports:w41,syntax:w42,root:w1}}w1.exports=w2,w2.filename=null,w2.defaults={keepCase:!1};var w3=w0(34),w4=w0(29),w5=w0(35),w6=w0(16),w7=w0(20),w8=w0(25),w9=w0(15),w10=w0(33),w11=w0(22),w12=w0(36),w13=w0(37),w14=/^[1-9][0-9]*$/,w15=/^-?[1-9][0-9]*$/,w16=/^0[x][0-9a-fA-F]+$/,w17=/^-?0[x][0-9a-fA-F]+$/,w18=/^0[0-7]+$/,w19=/^-?0[0-7]+$/,w20=/^(?![eE])[0-9]*(?:\.[0-9]*)?(?:[eE][+-]?[0-9]+)?$/,w21=/^[a-zA-Z_][a-zA-Z_0-9]*$/,w22=/^(?:\.?[a-zA-Z_][a-zA-Z_0-9]*)+$/,w23=/^(?:\.[a-zA-Z][a-zA-Z_0-9]*)+$/},{15:15,16:16,20:20,22:22,25:25,29:29,33:33,34:34,35:35,36:36,37:37}],27:[function(w0,w1){function w2(w0,w1){return RangeError("index out of range: "+w0.pos+" + "+(w1||1)+" > "+w0.len)}function w3(w0){this.buf=w0,this.pos=0,this.len=w0.length}function w4(){var w0=new w9(0,0),w1=0;if(!(this.len-this.pos>4)){for(;w1<3;++w1){if(this.pos>=this.len)throw w2(this);if(w0.lo=(w0.lo|(127&this.buf[this.pos])<<7*w1)>>>0,this.buf[this.pos++]<128)return w0}return w0.lo=(w0.lo|(127&this.buf[this.pos++])<<7*w1)>>>0,w0}for(;w1<4;++w1)if(w0.lo=(w0.lo|(127&this.buf[this.pos])<<7*w1)>>>0,this.buf[this.pos++]<128)return w0;if(w0.lo=(w0.lo|(127&this.buf[this.pos])<<28)>>>0,w0.hi=(w0.hi|(127&this.buf[this.pos])>>4)>>>0,this.buf[this.pos++]<128)return w0;if(w1=0,this.len-this.pos>4){for(;w1<5;++w1)if(w0.hi=(w0.hi|(127&this.buf[this.pos])<<7*w1+3)>>>0,this.buf[this.pos++]<128)return w0}else for(;w1<5;++w1){if(this.pos>=this.len)throw w2(this);if(w0.hi=(w0.hi|(127&this.buf[this.pos])<<7*w1+3)>>>0,this.buf[this.pos++]<128)return w0}throw Error("invalid varint encoding")}function w5(w0,w1){return(w0[w1-4]|w0[w1-3]<<8|w0[w1-2]<<16|w0[w1-1]<<24)>>>0}function w6(){if(this.pos+8>this.len)throw w2(this,8);return new w9(w5(this.buf,this.pos+=4),w5(this.buf,this.pos+=4))}w1.exports=w3;var w7,w8=w0(39),w9=w8.LongBits,w10=w8.utf8,w11="undefined"!=typeof Uint8Array?function(w0){if(w0 instanceof Uint8Array||Array.isArray(w0))return new w3(w0);throw Error("illegal buffer")}:function(w0){if(Array.isArray(w0))return new w3(w0);throw Error("illegal buffer")};w3.create=w8.Buffer?function(w0){return(w3.create=function(w0){return w8.Buffer.isBuffer(w0)?new w7(w0):w11(w0)})(w0)}:w11,w3.prototype.i=w8.Array.prototype.subarray||w8.Array.prototype.slice,w3.prototype.uint32=function(){var w0=4294967295;return function(){if(w0=(127&this.buf[this.pos])>>>0,this.buf[this.pos++]<128)return w0;if(w0=(w0|(127&this.buf[this.pos])<<7)>>>0,this.buf[this.pos++]<128)return w0;if(w0=(w0|(127&this.buf[this.pos])<<14)>>>0,this.buf[this.pos++]<128)return w0;if(w0=(w0|(127&this.buf[this.pos])<<21)>>>0,this.buf[this.pos++]<128)return w0;if(w0=(w0|(15&this.buf[this.pos])<<28)>>>0,this.buf[this.pos++]<128)return w0;if((this.pos+=5)>this.len)throw this.pos=this.len,w2(this,10);return w0}}(),w3.prototype.int32=function(){return 0|this.uint32()},w3.prototype.sint32=function(){var w0=this.uint32();return w0>>>1^-(1&w0)|0},w3.prototype.bool=function(){return 0!==this.uint32()},w3.prototype.fixed32=function(){if(this.pos+4>this.len)throw w2(this,4);return w5(this.buf,this.pos+=4)},w3.prototype.sfixed32=function(){if(this.pos+4>this.len)throw w2(this,4);return 0|w5(this.buf,this.pos+=4)},w3.prototype.float=function(){if(this.pos+4>this.len)throw w2(this,4);var w0=w8.float.readFloatLE(this.buf,this.pos);return this.pos+=4,w0},w3.prototype.double=function(){if(this.pos+8>this.len)throw w2(this,4);var w0=w8.float.readDoubleLE(this.buf,this.pos);return this.pos+=8,w0},w3.prototype.bytes=function(){var w0=this.uint32(),w1=this.pos,w3=this.pos+w0;if(w3>this.len)throw w2(this,w0);return this.pos+=w0,Array.isArray(this.buf)?this.buf.slice(w1,w3):w1===w3?new this.buf.constructor(0):this.i.call(this.buf,w1,w3)},w3.prototype.string=function(){var w0=this.bytes();return w10.read(w0,0,w0.length)},w3.prototype.skip=function(w0){if("number"==typeof w0){if(this.pos+w0>this.len)throw w2(this,w0);this.pos+=w0}else do{if(this.pos>=this.len)throw w2(this)}while(128&this.buf[this.pos++]);return this},w3.prototype.skipType=function(w0){switch(w0){case 0:this.skip();break;case 1:this.skip(8);break;case 2:this.skip(this.uint32());break;case 3:for(;4!=(w0=7&this.uint32());)this.skipType(w0);break;case 5:this.skip(4);break;default:throw Error("invalid wire type "+w0+" at offset "+this.pos)}return this},w3.e=function(w0){w7=w0;var w1=w8.Long?"toLong":"toNumber";w8.merge(w3.prototype,{int64:function(){return w4.call(this)[w1](!1)},uint64:function(){return w4.call(this)[w1](!0)},sint64:function(){return w4.call(this).zzDecode()[w1](!1)},fixed64:function(){return w6.call(this)[w1](!0)},sfixed64:function(){return w6.call(this)[w1](!1)}})}},{39:39}],28:[function(w0,w1){function w2(w0){w3.call(this,w0)}w1.exports=w2;var w3=w0(27);(w2.prototype=(0,_create2.default)(w3.prototype)).constructor=w2;var w4=w0(39);w4.Buffer&&(w2.prototype.i=w4.Buffer.prototype.slice),w2.prototype.string=function(){var w0=this.uint32();return this.buf.utf8Slice(this.pos,this.pos=Math.min(this.pos+w0,this.len))}},{27:27,39:39}],29:[function(w0,w1){function w2(w0){w5.call(this,"",w0),this.deferred=[],this.files=[]}function w3(){}function w4(w0,w1){var w2=w1.parent.lookup(w1.extend);if(w2){var w3=new w9(w1.fullName,w1.id,w1.type,w1.rule,e,w1.options);return w3.declaringField=w1,w1.extensionField=w3,w2.add(w3),!0}return!1}w1.exports=w2;var w5=w0(23);((w2.prototype=(0,_create2.default)(w5.prototype)).constructor=w2).className="Root";var w6,w7,w8,w9=w0(16),w10=w0(15),w11=w0(25),w12=w0(37);w2.fromJSON=function(w0,w1){return w1||(w1=new w2),w0.options&&w1.setOptions(w0.options),w1.addJSON(w0.nested)},w2.prototype.resolvePath=w12.path.resolve,w2.prototype.load=function w0(w1,w2,w4){function w5(w0,w1){if(w4){var w2=w4;if(w4=null,w11)throw w0;w2(w0,w1)}}function w6(w0,w1){try{if(w12.isString(w1)&&"{"===w1.charAt(0)&&(w1=JSON.parse(w1)),w12.isString(w1)){w7.filename=w0;var w3,w4=w7(w1,w10,w2),w6=0;if(w4.imports)for(;w6-1){var w3=w0.substring(w2);w3 in w8&&(w0=w3)}if(!(w10.files.indexOf(w0)>-1)){if(w10.files.push(w0),w0 in w8)return void(w11?w6(w0,w8[w0]):(++w13,setTimeout((function(){--w13,w6(w0,w8[w0])}))));if(w11){var w7;try{w7=w12.fs.readFileSync(w0).toString("utf8")}catch(w0){return void(w1||w5(w0))}w6(w0,w7)}else++w13,w12.fetch(w0,(function(w2,w3){if(--w13,w4)return w2?void(w1?w13||w5(null,w10):w5(w2)):void w6(w0,w3)}))}}"function"==typeof w2&&(w4=w2,w2=e);var w10=this;if(!w4)return w12.asPromise(w0,w10,w1,w2);var w11=w4===w3,w13=0;w12.isString(w1)&&(w1=[w1]);for(var w14,w15=0;w15-1&&this.deferred.splice(w1,1)}}else if(w0 instanceof w10)w13.test(w0.name)&&delete w0.parent[w0.name];else if(w0 instanceof w5){for(var w2=0;w20)return w22.shift();if(w23)return w3();var w2,w5,w6,w7,w8;do{if(w15===w16)return null;for(w2=!1;w9.test(w6=w10(w15));)if("\n"===w6&&++w17,++w15===w16)return null;if("/"===w10(w15)){if(++w15===w16)throw w1("comment");if("/"===w10(w15)){for(w8="/"===w10(w7=w15+1);"\n"!==w10(++w15);)if(w15===w16)return null;++w15,w8&&w11(w7,w15-1),++w17,w2=!0}else{if("*"!==(w6=w10(w15)))return"/";w8="*"===w10(w7=w15+1);do{if("\n"===w6&&++w17,++w15===w16)throw w1("comment");w5=w6,w6=w10(w15)}while("*"!==w5||"/"!==w6);++w15,w8&&w11(w7,w15-2),w2=!0}}}while(w2);var w12=w15;if(w4.lastIndex=0,!w4.test(w10(w12++)))for(;w12]/g,w5=/(?:"([^"\\]*(?:\\.[^"\\]*)*)")/g,w6=/(?:'([^'\\]*(?:\\.[^'\\]*)*)')/g,w7=/^ *[*\/]+ */,w8=/\n/g,w9=/\s/,w10=/\\(.?)/g,w11={0:"\0",r:"\r",n:"\n",t:"\t"};w3.unescape=w2},{}],35:[function(w0,w1){function w2(w0,w1){w4.call(this,w0,w1),this.fields={},this.oneofs=e,this.extensions=e,this.reserved=e,this.group=e,this.k=null,this.b=null,this.l=null,this.o=null}function w3(w0){return w0.k=w0.b=w0.l=null,delete w0.encode,delete w0.decode,delete w0.verify,w0}w1.exports=w2;var w4=w0(23);((w2.prototype=(0,_create2.default)(w4.prototype)).constructor=w2).className="Type";var w5=w0(15),w6=w0(25),w7=w0(16),w8=w0(20),w9=w0(33),w10=w0(21),w11=w0(27),w12=w0(42),w13=w0(37),w14=w0(14),w15=w0(13),w16=w0(40),w17=w0(12),w18=w0(41);(0,_defineProperties2.default)(w2.prototype,{fieldsById:{get:function(){if(this.k)return this.k;this.k={};for(var w0=(0,_keys2.default)(this.fields),w1=0;w1=w0)return!0;return!1},w2.prototype.isReservedName=function(w0){if(this.reserved)for(var w1=0;w1>>0,this.hi=w1>>>0}w1.exports=w2;var w3=w0(39),w4=w2.zero=new w2(0,0);w4.toNumber=function(){return 0},w4.zzEncode=w4.zzDecode=function(){return this},w4.length=function(){return 1};var w5=w2.zeroHash="\0\0\0\0\0\0\0\0";w2.fromNumber=function(w0){if(0===w0)return w4;var w1=w0<0;w1&&(w0=-w0);var w3=w0>>>0,w5=(w0-w3)/4294967296>>>0;return w1&&(w5=~w5>>>0,w3=~w3>>>0,++w3>4294967295&&(w3=0,++w5>4294967295&&(w5=0))),new w2(w3,w5)},w2.from=function(w0){if("number"==typeof w0)return w2.fromNumber(w0);if(w3.isString(w0)){if(!w3.Long)return w2.fromNumber(parseInt(w0,10));w0=w3.Long.fromString(w0)}return w0.low||w0.high?new w2(w0.low>>>0,w0.high>>>0):w4},w2.prototype.toNumber=function(w0){if(!w0&&this.hi>>>31){var w1=1+~this.lo>>>0,w2=~this.hi>>>0;return w1||(w2=w2+1>>>0),-(w1+4294967296*w2)}return this.lo+4294967296*this.hi},w2.prototype.toLong=function(w0){return w3.Long?new w3.Long(0|this.lo,0|this.hi,!!w0):{low:0|this.lo,high:0|this.hi,unsigned:!!w0}};var w6=String.prototype.charCodeAt;w2.fromHash=function(w0){return w0===w5?w4:new w2((w6.call(w0,0)|w6.call(w0,1)<<8|w6.call(w0,2)<<16|w6.call(w0,3)<<24)>>>0,(w6.call(w0,4)|w6.call(w0,5)<<8|w6.call(w0,6)<<16|w6.call(w0,7)<<24)>>>0)},w2.prototype.toHash=function(){return String.fromCharCode(255&this.lo,this.lo>>>8&255,this.lo>>>16&255,this.lo>>>24,255&this.hi,this.hi>>>8&255,this.hi>>>16&255,this.hi>>>24)},w2.prototype.zzEncode=function(){var w0=this.hi>>31;return this.hi=((this.hi<<1|this.lo>>>31)^w0)>>>0,this.lo=(this.lo<<1^w0)>>>0,this},w2.prototype.zzDecode=function(){var w0=-(1&this.lo);return this.lo=((this.lo>>>1|this.hi<<31)^w0)>>>0,this.hi=(this.hi>>>1^w0)>>>0,this},w2.prototype.length=function(){var w0=this.lo,w1=(this.lo>>>28|this.hi<<4)>>>0,w2=this.hi>>>24;return 0===w2?0===w1?w0<16384?w0<128?1:2:w0<2097152?3:4:w1<16384?w1<128?5:6:w1<2097152?7:8:w2<128?9:10}},{39:39}],39:[function(w0,w1,w2){function w3(w0,w1,w2){for(var w3=(0,_keys2.default)(w1),w4=0;w40)},w5.Buffer=function(){try{var w0=w5.inquire("buffer").Buffer;return w0.prototype.utf8Write?w0:null}catch(w0){return null}}(),w5.p=null,w5.u=null,w5.newBuffer=function(w0){return"number"==typeof w0?w5.Buffer?w5.u(w0):new w5.Array(w0):w5.Buffer?w5.p(w0):"undefined"==typeof Uint8Array?w0:new Uint8Array(w0)},w5.Array="undefined"!=typeof Uint8Array?Uint8Array:Array,w5.Long=t.dcodeIO&&t.dcodeIO.Long||w5.inquire("long"),w5.key2Re=/^true|false|0|1$/,w5.key32Re=/^-?(?:0|[1-9][0-9]*)$/,w5.key64Re=/^(?:[\\x00-\\xff]{8}|-?(?:0|[1-9][0-9]*))$/,w5.longToHash=function(w0){return w0?w5.LongBits.from(w0).toHash():w5.LongBits.zeroHash},w5.longFromHash=function(w0,w1){var w2=w5.LongBits.fromHash(w0);return w5.Long?w5.Long.fromBits(w2.lo,w2.hi,w1):w2.toNumber(!!w1)},w5.merge=w3,w5.lcFirst=function(w0){return w0.charAt(0).toLowerCase()+w0.substring(1)},w5.newError=w4,w5.ProtocolError=w4("ProtocolError"),w5.oneOfGetter=function(w0){for(var w1={},w2=0;w2-1;--w2)if(1===w1[w0[w2]]&&this[w0[w2]]!==e&&null!==this[w0[w2]])return w0[w2]}},w5.oneOfSetter=function(w0){return function(w1){for(var w2=0;w2>>7|w0.hi<<25)>>>0,w0.hi>>>=7;for(;w0.lo>127;)w1[w2++]=127&w0.lo|128,w0.lo=w0.lo>>>7;w1[w2++]=w0.lo}function w9(w0,w1,w2){w1[w2]=255&w0,w1[w2+1]=w0>>>8&255,w1[w2+2]=w0>>>16&255,w1[w2+3]=w0>>>24}w1.exports=w5;var w10,w11=w0(39),w12=w11.LongBits,w13=w11.base64,w14=w11.utf8;w5.create=w11.Buffer?function(){return(w5.create=function(){return new w10})()}:function(){return new w5},w5.alloc=function(w0){return new w11.Array(w0)},w11.Array!==Array&&(w5.alloc=w11.pool(w5.alloc,w11.Array.prototype.subarray)),w5.prototype.v=function(w0,w1,w3){return this.tail=this.tail.next=new w2(w0,w1,w3),this.len+=w1,this},w7.prototype=(0,_create2.default)(w2.prototype),w7.prototype.fn=function(w0,w1,w2){for(;w0>127;)w1[w2++]=127&w0|128,w0>>>=7;w1[w2]=w0},w5.prototype.uint32=function(w0){return this.len+=(this.tail=this.tail.next=new w7((w0>>>=0)<128?1:w0<16384?2:w0<2097152?3:w0<268435456?4:5,w0)).len,this},w5.prototype.int32=function(w0){return w0<0?this.v(w8,10,w12.fromNumber(w0)):this.uint32(w0)},w5.prototype.sint32=function(w0){return this.uint32((w0<<1^w0>>31)>>>0)},w5.prototype.uint64=function(w0){var w1=w12.from(w0);return this.v(w8,w1.length(),w1)},w5.prototype.int64=w5.prototype.uint64,w5.prototype.sint64=function(w0){var w1=w12.from(w0).zzEncode();return this.v(w8,w1.length(),w1)},w5.prototype.bool=function(w0){return this.v(w6,1,w0?1:0)},w5.prototype.fixed32=function(w0){return this.v(w9,4,w0>>>0)},w5.prototype.sfixed32=w5.prototype.fixed32,w5.prototype.fixed64=function(w0){var w1=w12.from(w0);return this.v(w9,4,w1.lo).v(w9,4,w1.hi)},w5.prototype.sfixed64=w5.prototype.fixed64,w5.prototype.float=function(w0){return this.v(w11.float.writeFloatLE,4,w0)},w5.prototype.double=function(w0){return this.v(w11.float.writeDoubleLE,8,w0)};var w15=w11.Array.prototype.set?function(w0,w1,w2){w1.set(w0,w2)}:function(w0,w1,w2){for(var w3=0;w3>>0;if(!w1)return this.v(w6,1,0);if(w11.isString(w0)){var w2=w5.alloc(w1=w13.length(w0));w13.decode(w0,w2,0),w0=w2}return this.uint32(w1).v(w15,w1,w0)},w5.prototype.string=function(w0){var w1=w14.length(w0);return w1?this.uint32(w1).v(w14.write,w1,w0):this.v(w6,1,0)},w5.prototype.fork=function(){return this.states=new w4(this),this.head=this.tail=new w2(w3,0,0),this.len=0,this},w5.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 w2(w3,0,0),this.len=0),this},w5.prototype.ldelim=function(){var w0=this.head,w1=this.tail,w2=this.len;return this.reset().uint32(w2),w2&&(this.tail.next=w0.next,this.tail=w1,this.len+=w2),this},w5.prototype.finish=function(){for(var w0=this.head.next,w1=this.constructor.alloc(this.len),w2=0;w0;)w0.fn(w0.val,w1,w2),w2+=w0.len,w0=w0.next;return w1},w5.e=function(w0){w10=w0}},{39:39}],43:[function(w0,w1){function w2(){w4.call(this)}function w3(w0,w1,w2){w0.length<40?w5.utf8.write(w0,w1,w2):w1.utf8Write(w0,w2)}w1.exports=w2;var w4=w0(42);(w2.prototype=(0,_create2.default)(w4.prototype)).constructor=w2;var w5=w0(39),w6=w5.Buffer;w2.alloc=function(w0){return(w2.alloc=w5.u)(w0)};var w7=w6&&w6.prototype instanceof Uint8Array&&"set"===w6.prototype.set.name?function(w0,w1,w2){w1.set(w0,w2)}:function(w0,w1,w2){if(w0.copy)w0.copy(w1,w2,0,w0.length);else for(var w3=0;w3>>0;return this.uint32(w1),w1&&this.v(w7,w1,w0),this},w2.prototype.string=function(w0){var w1=w6.byteLength(w0);return this.uint32(w1),w1&&this.v(w3,w1,w0),this}},{39:39,42:42}]},{})}("object"==("undefined"==typeof window?"undefined":(0,_typeof3.default)(window))&&window||"object"==("undefined"==typeof self?"undefined":(0,_typeof3.default)(self))&&self||void 0)}).call(this,__webpack_require__(153)(module))},function(w0,w1){!function(){"use strict";for(var w0="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",w2=new Uint8Array(256),w3=0;w3>2],w5+=w0[(3&w3[w2])<<4|w3[w2+1]>>4],w5+=w0[(15&w3[w2+1])<<2|w3[w2+2]>>6],w5+=w0[63&w3[w2+2]];return w4%3==2?w5=w5.substring(0,w5.length-1)+"=":w4%3==1&&(w5=w5.substring(0,w5.length-2)+"=="),w5},w1.decode=function(w0){var w1,w3,w4,w5,w6,w7=.75*w0.length,w8=w0.length,w9=0;"="===w0[w0.length-1]&&(w7--,"="===w0[w0.length-2]&&w7--);var w10=new ArrayBuffer(w7),w11=new Uint8Array(w10);for(w1=0;w1>4,w11[w9++]=(15&w4)<<4|w5>>2,w11[w9++]=(3&w5)<<6|63&w6;return w10}}()},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__160__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__161__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__162__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__163__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__164__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__165__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__166__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__167__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__168__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__169__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__170__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__171__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__172__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__173__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__174__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__175__},function(w0,w1,w2){"use strict";w0.exports=function(w0,w1,w2,w3){for(var w4=65535&w0|0,w5=w0>>>16&65535|0,w6=0;0!==w2;){w2-=w6=w2>2e3?2e3:w2;do{w5=w5+(w4=w4+w1[w3++]|0)|0}while(--w6);w4%=65521,w5%=65521}return w4|w5<<16|0}},function(w0,w1,w2){"use strict";var w3=function(){for(var w0,w1=[],w2=0;w2<256;w2++){w0=w2;for(var w3=0;w3<8;w3++)w0=1&w0?3988292384^w0>>>1:w0>>>1;w1[w2]=w0}return w1}();w0.exports=function(w0,w1,w2,w4){var w5=w3,w6=w4+w2;w0^=-1;for(var w7=w4;w7>>8^w5[255&(w0^w1[w7])];return-1^w0}},function(w0,w1,w2){"use strict";var w3=w2(20),w4=!0,w5=!0;try{String.fromCharCode.apply(null,[0])}catch(w0){w4=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(w0){w5=!1}for(var w6=new w3.Buf8(256),w7=0;w7<256;w7++)w6[w7]=w7>=252?6:w7>=248?5:w7>=240?4:w7>=224?3:w7>=192?2:1;function w8(w0,w1){if(w1<65534&&(w0.subarray&&w5||!w0.subarray&&w4))return String.fromCharCode.apply(null,w3.shrinkBuf(w0,w1));for(var w2="",w6=0;w6>>6,w1[w6++]=128|63&w2):w2<65536?(w1[w6++]=224|w2>>>12,w1[w6++]=128|w2>>>6&63,w1[w6++]=128|63&w2):(w1[w6++]=240|w2>>>18,w1[w6++]=128|w2>>>12&63,w1[w6++]=128|w2>>>6&63,w1[w6++]=128|63&w2);return w1},w1.buf2binstring=function(w0){return w8(w0,w0.length)},w1.binstring2buf=function(w0){for(var w1=new w3.Buf8(w0.length),w2=0,w4=w1.length;w24)w9[w3++]=65533,w2+=w5-1;else{for(w4&=2===w5?31:3===w5?15:7;w5>1&&w21?w9[w3++]=65533:w4<65536?w9[w3++]=w4:(w4-=65536,w9[w3++]=55296|w4>>10&1023,w9[w3++]=56320|1023&w4)}return w8(w9,w3)},w1.utf8border=function(w0,w1){var w2;for((w1=w1||w0.length)>w0.length&&(w1=w0.length),w2=w1-1;w2>=0&&128==(192&w0[w2]);)w2--;return w2<0||0===w2?w1:w2+w6[w0[w2]]>w1?w2:w1}},function(w0,w1,w2){"use strict";w0.exports=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}},function(w0,w1,w2){"use strict";w0.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},function(w0,w1,w2){"use strict";(function(w0){Object.defineProperty(w1,"__esModule",{value:!0}),w1.WfcImpl=void 0;var w3=w59(w2(62)),w4=w59(w2(107)),w5=w59(w2(77)),w6=w59(w2(209)),w7=w59(w2(212)),w8=w59(w2(120)),w9=w59(w2(80)),w10=w59(w2(81)),w11=w59(w2(121)),w12=w59(w2(122)),w13=w59(w2(55)),w14=w59(w2(123)),w15=w59(w2(82)),w16=w2(125),w17=w2(29),w18=w2(257),w19=w59(w2(160)),w20=w59(w2(161)),w21=w59(w2(370)),w22=w59(w2(371)),w23=w59(w2(162)),w24=w59(w2(372)),w25=w59(w2(163)),w26=w59(w2(164)),w27=w59(w2(373)),w28=w59(w2(165)),w29=w59(w2(166)),w30=w59(w2(374)),w31=w59(w2(167)),w32=w59(w2(375)),w33=w59(w2(168)),w34=w59(w2(169)),w35=w59(w2(170)),w36=w59(w2(171)),w37=w59(w2(172)),w38=w59(w2(376)),w39=w2(377),w40=w59(w2(378)),w41=w59(w2(384)),w42=w59(w2(385)),w43=w59(w2(92)),w44=w59(w2(386)),w45=w59(w2(395)),w46=w59(w2(174)),w47=w59(w2(396)),w48=w59(w2(175)),w49=w59(w2(173)),w50=w59(w2(397)),w51=w59(w2(398)),w52=w2(399),w53=w59(w2(400)),w54=w59(w2(401)),w55=w59(w2(402)),w56=w59(w2(403)),w57=w59(w2(404)),w58=w59(w2(405));function w59(w0){return w0&&w0.__esModule?w0:{default:w0}}var w60=w1.WfcImpl=function(){function w1(){var w0=this;(0,w13.default)(this,w1),this.initialized=!1,this.connectionStatus=0,this.userId="",this.token="",this.clientId="",this.chatRoomMsgHead=w15.default.ZERO,this.privateSecret="",this.store=new w40.default(this),this.isReceiptEnable=!1,this.isUserOnlineStateEnable=!1,this.serverConfigs={},this.isClearGroupMsgWhenKickoff=!1,this.isGlobalDisableDraftSync=!1,this.isConnecting=!1,this.isUserDisconnected=!1,this.isPullingSetting=!1,this.isPullingMsg=!1,this.isPullingChatroomMsg=!1,this.isPullingRecv=!1,this.isPullingRead=!1,this.isPullingGroupMsg=!1,this.isConversationTargetPreloaded=!1,this.isFriendPreloaded=!1,this.isFriendRequestPreloaded=!1,this.settingHead=w15.default.ZERO,this.friendHead=w15.default.ZERO,this.friendRequestHead=w15.default.ZERO,this.recvHead=w15.default.ZERO,this.readHead=w15.default.ZERO,this.groupHead=w15.default.ZERO,this.deltaTime=0,this.lastActiveTime=0,this.backupAddressStrategy=1,this.backupHost="",this.backupPort=80,this.pendingMN=!1,this.pendingGMN=!1,this.uploadingMap=new w12.default,this.voipAnswerMsgMap=new w12.default,this.voipByeMsgMap=new w12.default,this._callbackOrLoadFromRemoteMessages=function(w2,w3,w4){var w5=[],w6=[],w7=!0,w8=!1,w9=void 0;try{for(var w10,w12=(0,w11.default)(w2);!(w7=(w10=w12.next()).done);w7=!0){var w13=w10.value;w13.messageContent.__notLoaded?w5.push(w13.messageUid):w6.push(w13)}}catch(w0){w8=!0,w9=w0}finally{try{!w7&&w12.return&&w12.return()}finally{if(w8)throw w9}}if(w5.length>0){var w14=w39.INT64ListBuf.create();w14.id=w5,console.log("loadSuperGroupMessages request",w14),w0._publish("MGS",w39.INT64ListBuf.encode(w14).finish(),(function(){var w2=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2,w5=arguments[1];if(0===w2&&w5){var w7=w39.MessageList.decode(w5);w0.log("loadSuperGroupMessages result data",w7),w7&&w7.message&&(w7.message.forEach((function(w2){if(!(w1.pcNotSupportMessageTypes.indexOf(w2.content.type)>-1)){var w3=w21.default.fromProtoMessage(w2),w4=w0.store.getMessageByUid(w3.messageUid);w3.messageId=w4.messageId,w0.store.updateMessageById(w3),w6.push(w3)}})),w6.sort((function(w0,w1){return(0,w16.eq)(w0.timestamp,w1.timestamp)?(0,w16.compare)(w0.messageUid,w1.messageUid):(0,w16.compare)(w0.timestamp,w1.timestamp)}))),w3&&w3(w6)}else w4&&w4(0!==w2?w2:-1)}))}else w3&&w3(w2)}}var w2,w59;return(0,w14.default)(w1,[{key:"resetMqtt",value:function(){var w0=this;this.mqttClientInstance&&(this.mqttClientInstance.removeAllListeners(),this.mqttClientInstance.end(!0,{},(function(){w0.log("mqtt client ended")})),this.mqttClientInstance=null)}},{key:"reset",value:function(){this.resetMqtt(),this.connectionStatus=w41.default.ConnectionStatusLogout,this.isConnecting=!1,this.userId="",this.token="",this.clientId="",this.msgHead=w15.default.ZERO,this.privateSecret="",this.store=new w40.default(this),this.isReceiptEnable=!1,this.isGlobalDisableDraftSync=!1,this.isConnecting=!1,this.isUserDisconnected=!1,this.isPullingSetting=!1,this.isPullingRecv=!1,this.isPullingRead=!1,this.isConversationTargetPreloaded=!1,this.isFriendPreloaded=!1,this.isFriendRequestPreloaded=!1,this.settingHead=w15.default.ZERO,this.friendHead=w15.default.ZERO,this.friendRequestHead=w15.default.ZERO,this.recvHead=w15.default.ZERO,this.readHead=w15.default.ZERO,this.groupHead=w15.default.ZERO,this.deltaTime=0,this.lastActiveTime=0,this.reconnectTimer&&(clearInterval(this.reconnectTimer),this.reconnectTimer=0)}},{key:"onConnectionChanged",value:function(w0){var w1=this;if(this.connectionStatus!==w0)if(w0===w41.default.ConnectionStatusConnected&&this._pullUnreadMessages(),w43.default.ENABLE_INFO_PERSISTENCE&&(!w43.default.MESSAGE_ROAMING&&w0===w41.default.ConnectionStatusConnected||w43.default.MESSAGE_ROAMING&&w0===w41.default.ConnectionStatusReceiveing)&&this.store.loadPersistGroups(),w0===w41.default.ConnectionStatusConnected){var w2=this.store.friends.size+this.store.conversationInfos.length-this.store.users.size,w3=0;w3+=1*Math.round(w2/2e3),w3+=1*Math.round(this.store.groups.size/10),setTimeout((function(){console.log("connection status changed to status in ",w3),w1.connectionStatus=w0,w1.eventEmitter.emit(w38.default.ConnectionStatusChanged,w0)}),1e3*w3)}else this.log("connection status changed",w0),this.connectionStatus=w0,this.eventEmitter.emit(w38.default.ConnectionStatusChanged,w0)}},{key:"_isGroupNotificationTargetsIncludeCurrentUser",value:function(w0){}},{key:"onConferenceEvent",value:function(w0){this.eventEmitter.emit(w38.default.ConferenceEvent,w0)}},{key:"onReceiveMessage",value:function(w0){var w2=arguments.length>1&&void 0!==arguments[1]&&arguments[1],w3=this,w4=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],w5=arguments.length>3&&void 0!==arguments[3]&&arguments[3],w6=[],w7=[];this.log("onReceiveMessage length: "+w0.length+", pullSettings: "+w2+" saveToStore "+w4),w0.forEach((function(w8,w9){if(!(w1.pcNotSupportMessageTypes.indexOf(w8.content.type)>-1)){var w10=w21.default.fromProtoMessage(w8),w11=w90&&(w3.store.deleteMessageByUid(w12),w3.onRemoteMessageDeleted(w13.messageUid)))}var w14=w19.default.getMessageContentPersitFlag(w10.content.type);if(-1===w14&&(w14=w10.content.persistFlag),w10.messageContent.type===w22.default.RecallMessage_Notification&&w3.onRecallMessage(w10.messageContent.operatorId,w10.messageContent.messageUid),[w22.default.VOIP_CONTENT_TYPE_START,w22.default.VOIP_CONTENT_TYPE_ACCEPT,w22.default.VOIP_CONTENT_TYPE_END].indexOf(w10.messageContent.type)>=0&&w3.updateCallStartMessage(w10),!w4||w14!==w25.default.Persist&&w14!==w25.default.Persist_And_Count){if(w43.default.ENABLE_GENERATE_CONVERSATION_FOR_TRANSPARENT_MESSAGE&&w3.store.genAndSaveDefaultConversationInfo(w10.conversation),w43.default.ENABLE_ROAMING_TRANSPARENT_MESSAGE_RECEIVING_NOTIFICATION&&w3.eventEmitter.emit(w38.default.ReceiveMessage,w10,w11),w10.messageContent instanceof w53.default&&w10.from===w3.userId){var w16=w10.messageContent,w17=w10.conversation;w3.store.setLastReceivedMessageUnread(w17,w16.messageUid,w16.timestamp)}w5||w2||w3.eventEmitter.emit(w38.default.ReceiveMessage,w10,w11)}else w10.conversation.type===w29.default.ChatRoom?w10.messageId=w3.store.genChatRoomMessageId():w10.messageId=w3.store.genNormalMessageId(),w3.store.saveMessage(w10),w3.store.updateConversationLastMessage(w10)&&w3.eventEmitter.emit(w38.default.ConversationInfoUpdate,w3.store.getConversationInfo(w10.conversation)),w5||w2&&!w43.default.ENABLE_ROAMING_MESSAGE_RECEIVING_NOTIFICATION||w3.eventEmitter.emit(w38.default.ReceiveMessage,w10,w11)}}})),w6.forEach((function(w0){w3._reloadGroupInfosFromRemote(w0)})),w7.forEach((function(w0){w3._reloadGroupMembersFromRemote(w0,w3.store.getGroupMemberMaxDt(w0))}))}},{key:"_handleGroupNotificationMessage",value:function(w0,w1,w2,w3){var w4=this,w5=[w22.default.CreateGroup_Notification,w22.default.AddGroupMember_Notification,w22.default.KickOffGroupMember_Notification,w22.default.TransferGroupOwner_Notification,w22.default.ModifyGroupExtra_Notification,w22.default.ModifyGroupAlias_Notification];if(w5.indexOf(w0.content.type)>-1)if(w2.push(w0.conversation.target),w3.push(w0.conversation.target),w0.content.type===w22.default.KickOffGroupMember_Notification){var w6=w0.messageContent.kickedMembers.find((function(w0){return w0===w4.getUserId()}));this.log("kickoff",w0.conversation.target,this.isClearGroupMsgWhenKickoff),w6===this.getUserId()&&this.isClearGroupMsgWhenKickoff&&this.store.removeConversation(w0.conversation,!0)}else w0.content.type===w22.default.AddGroupMember_Notification&&(this.isClearGroupMsgWhenKickoff||this.store.clearConversationMessagesBeforeMessageUid(w0.conversation,w0.messageUid));if((w5=[w22.default.SetGroupManager_Notification,w22.default.MuteGroupMember_Notification,w22.default.AllowGroupMember_Notification,w22.default.ModifyGroupMemberExtra_Notification]).indexOf(w0.content.type)>-1&&w3.push(w0.conversation.target),(w5=[w22.default.ChangeGroupName_Notification,w22.default.ChangeGroupPortrait_Notification,w22.default.MuteGroup_Notification,w22.default.ChangeJoinType_Notification,w22.default.ChangePrivateChat_Notification,w22.default.ChangeSearchable_Notification,w22.default.ModifyGroupExtra_Notification]).indexOf(w0.content.type)>-1&&w2.push(w0.conversation.target),(w5=[w22.default.QuitGroup_Notification]).indexOf(w0.content.type)>-1){if(w0.from===this.getUserId())return this.store.removeGroupAndMembers(w0.conversation.target),this.store.removeGroupSettings(w0.conversation.target),this.store.removeFavGroup(w0.conversation.target),void this.store.removeConversation(w0.conversation,!0);w2.push(w0.conversation.target),w3.push(w0.conversation.target)}if((w5=[w22.default.DismissGroup_Notification]).indexOf(w0.content.type)>-1){this.store.removeGroupAndMembers(w0.conversation.target),this.store.removeGroupSettings(w0.conversation.target),this.store.removeFavGroup(w0.conversation.target),this.serverConfigs.isKeepMsgAfterDismiss||this.store.removeConversation(w0.conversation,!0);var w7=w2.filter((function(w1){return w1!==w0.conversation.target})),w8=w3.filter((function(w1){return w1!==w0.conversation.target}));w2.length=0,w2.push.apply(w2,(0,w10.default)(w7)),w3.length=0,w3.push.apply(w3,(0,w10.default)(w8))}}},{key:"updateCallStartMessage",value:function(w0){var w1=void 0,w2=w0.messageContent.callId;if(w0.messageContent.type===w22.default.VOIP_CONTENT_TYPE_END?(this.voipByeMsgMap.set(w2,w0),w1=this.store.getCallStartMessage(w2)):w0.messageContent.type===w22.default.VOIP_CONTENT_TYPE_ACCEPT?(this.voipAnswerMsgMap.set(w2,w0),w1=this.store.getCallStartMessage(w2)):w1=w0,w1){var w3=this.voipAnswerMsgMap.get(w2);w3&&(w1.messageContent.connectTime=w3.timestamp,this.voipAnswerMsgMap.delete(w2));var w4=this.voipByeMsgMap.get(w2);w4&&(w1.messageContent.endTime=w4.timestamp,w1.messageContent.status=w4.messageContent.reason,this.voipByeMsgMap.delete(w2))}}},{key:"onGroupInfoUpdate",value:function(w0){}},{key:"onChannelInfoUpdate",value:function(w0){}},{key:"onSettingUpdate",value:function(w0){this.eventEmitter.emit(w38.default.SettingUpdate)}},{key:"onRecallMessage",value:function(w0,w1){var w2=this.store.getMessageByUid(w1);if(w2&&0!==w2.messageId){var w3=w2.messageContent;if(w0===this.userId){var w4={};w4.s=w2.from,w4.ts=(0,w16.numberValue)(w2.timestamp);var w5=w2.content;w5&&w5.hasOwnProperty("type")||(w5=w2.messageContent.encode()),w4.t=w5.type,w4.sc=w5.searchableContent?w5.searchableContent:"",w4.c=w5.content?w5.content:"",w4.e=w5.extra?w5.content:"",w2.extra=(0,w9.default)(w4)}var w6=new w24.default(w0,w1);w6.fromSelf=!0,w6.setExtra(w2.extra),w2.messageContent=w6,this.store.updateMessageById(w2);var w7=this.getConversationInfo(w2.conversation);1===w2.direction&&w19.default.getMessageContentFlag(w3.type)===w25.default.Persist_And_Count&&(w2.status===w23.default.Unread?w7.unreadCount.unread-=1:w2.status===w23.default.Mentioned?w7.unreadCount.unreadMention-=1:w2.status===w23.default.AllMentioned&&(w7.unreadCount.unreadMentionAll-=1)),this.eventEmitter.emit(w38.default.RecallMessage,w0,w1)}}},{key:"onRemoteMessageDeleted",value:function(w0){this.log("onRemoteMessageDeleted",w0),this.store.deleteMessageByUid(w0),this.eventEmitter.emit(w38.default.MessageDeleted,w0)}},{key:"onMessageDeleted",value:function(w0){this.log("onMessageDeleted",w0),this.eventEmitter.emit(w38.default.DeleteMessage,w0)}},{key:"onUserInfoUpdate",value:function(w0){var w1=this;this.log("userInfo update, ids",w0),JSON.parse(w0).map((function(w0){w1._reloadUserInfosFromRemote([w0])}))}},{key:"onFriendListUpdate",value:function(w0){this.log("friendList update, ids",w0),this.eventEmitter.emit(w38.default.FriendListUpdate,w0)}},{key:"onFriendRequestUpdate",value:function(w0){this.eventEmitter.emit(w38.default.FriendRequestUpdate,w0)}},{key:"registerMessageContent",value:function(w0,w1,w2,w3){w19.default.registerMessageContent(w0,w1,w2,w3)}},{key:"getHost",value:function(){return(0,w18.host)()}},{key:"getClientId",value:function(){if(""===this.clientId)switch(w43.default.CLIENT_ID_STRATEGY){case 0:default:this.clientId=this.uuid();break;case 1:this.clientId=sessionStorage.getItem("clientId"),this.clientId||(this.clientId=this.uuid(),sessionStorage.setItem("clientId",this.clientId));break;case 2:this.clientId=localStorage.getItem("clientId"),this.clientId||(this.clientId=this.uuid(),localStorage.setItem("clientId",this.clientId))}return this.log("clientId",this.clientId),this.clientId}},{key:"getEncodedClientId",value:function(){var w0=this.getClientId();return(0,w17.AESEncrypt)(w0,"")}},{key:"encodeData",value:function(w0){return(0,w17.AESEncrypt)(w0,this.privateSecret)}},{key:"decodeData",value:function(w0){return this._Utf8ArrayToStr((0,w17.AESDecrypt)(w0,this.privateSecret,!1))}},{key:"_Utf8ArrayToStr",value:function(w0){var w1,w2,w3,w4,w5,w6;for(w1="",w3=w0.length,w2=0;w2>4){case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:w1+=String.fromCharCode(w4);break;case 12:case 13:w5=w0[w2++],w1+=String.fromCharCode((31&w4)<<6|63&w5);break;case 14:w5=w0[w2++],w6=w0[w2++],w1+=String.fromCharCode((15&w4)<<12|(63&w5)<<6|(63&w6)<<0)}return w1}},{key:"uuid",value:function(){for(var w0=[],w1="0123456789abcdef",w2=0;w2<36;w2++)w0[w2]=w1.substr(Math.floor(16*Math.random()),1);return w0[14]="4",w0[19]=w1.substr(3&w0[19]|8,1),w0[8]=w0[13]=w0[18]=w0[23]="-",w0.join("")}},{key:"init",value:function(w0){this.initialized=!0,w0&&w0.length>0&&w43.default.config(w0[0])}},{key:"onForeground",value:function(){if(this.log("onForeground"),this.connectionStatus!==w41.default.ConnectionStatusConnected)this._reconnect();else{var w0=(new Date).getTime(),w1=w43.default.KEEP_ALIVE_TIMEOUT>w43.default.KEEP_ALIVE_INTERNAL?w43.default.KEEP_ALIVE_TIMEOUT:w43.default.KEEP_ALIVE_INTERNAL;w0-this.lastActiveTime>1e3*w1?(this.log("keep alive timeout, reconnect..."),this._reconnect(!0)):this.log("already connected")}}},{key:"connect",value:function(w0,w2){var w3=this;this.initialized?(this.log("connect",w1.version,this.getHost(),w0,w2),this.isUserDisconnected=!1,w0&&w2?"string"==typeof w0&&"string"==typeof w2?!this.mqttClientInstance||!this.isConnecting&&this.connectionStatus!==w41.default.ConnectionStatusConnected||this.userId!==w0||this.token!==w2?(""!==this.userId&&this.userId!==w0&&this.reset(),this.onConnectionChanged(w41.default.ConnectionStatusConnecting),this.reconnectTimer||(this.reconnectTimer=setInterval((function(){w3.connectionStatus===w41.default.ConnectionStatusUnconnected&&""!==w3.userId&&""!==w3.token&&(w3.isConnecting||(w3.log("reconnect",w3.userId,w3.clientId,w3.token,(new Date).valueOf()),w3.resetMqtt(),w3.connect(w3.userId,w3.token)))}),w1.connectionTimeout)),this.userId=w0,this.token=w2,this.isConnecting=!0,(0,w18.connect)(w0,this.getClientId(),w2,(function(w0,w1,w2,w4,w5){if(w3.log("connect/route error",w0,(new Date).valueOf()),-1===w0&&w3.connectionStatus===w41.default.ConnectionStatusConnected&&w3.mqttClientInstance)w3.isConnecting=!1;else{if(0!==w0){w3.isConnecting=!1;var w6=w41.default.ConnectionStatusUnconnected;return w0===w45.default.kEcServerTokenIncorrect?w6=w41.default.ConnectionStatusTokenIncorrect:w0===w45.default.kEcServerUserIsBlocked?w6=w41.default.ConnectionStatusRejected:w0===w45.default.kEcServerSecrectKeyMismatch?w6=w41.default.ConnectionStatusSecretKeyMismatch:w0===w45.default.kConnectionStatusKickedOff?w6=w41.default.ConnectionStatusKickedOff:w0===w45.default.kEcServerNotLicensed?w6=w41.default.ConnectionStatusNotLicensed:w0===w45.default.kEcServerTimeInconsistent?w6=w41.default.ConnectionStatusTimeInconsistent:w0===w45.default.kEcWebsocketNotConfigured&&(w3.error("IM 服务 websocket 配置不正确,请参考:https://docs.wildfirechat.cn/web/"),w6=w41.default.ConnectionStatusServerDown),w3.onConnectionChanged(w6),void(w1&&(w1.removeAllListeners(),w1.end(!0,{},(function(){w3.log("mqtt client ended")}))))}w3.mqttClientInstance=w1,w3.privateSecret=w2,w3.serverConfigs=w5||{},w3.isReceiptEnable=w5.isReceiptEnable,w3.isUserOnlineStateEnable=w5.isUserOnlineStateEnable,w3.isClearGroupMsgWhenKickoff=w5.isClearGroupMsgWhenKickoff,w3.isGlobalDisableDraftSync=w5.isGlobalDisableDraftSync,w3.mqttClientInstance.on("connect",(function(w0){w3.isConnecting=!1,w3.isPullingMsg=!1,w3.isPullingChatroomMsg=!1,w3.lastActiveTime=(new Date).getTime();var w1=w39.ConnectAckPayload.decode(w0.payload);if(w3.log("connect ack",w1,w3.msgHead),w3._pullFriends(w1.friendHead),w3._pullFriendRequest(w1.friendRqHead),w3.msgHead){var w2=w3.settingHead.compare(w1.settingHead)<0;w3._pullMessages(w1.msgHead,0,w2,w1.recvHead,w1.readHead,w1.groupConvHead,!0)}else w43.default.MESSAGE_ROAMING?(w3.msgHead=w15.default.ZERO,w3.log("pull roaming message",w3.msgHead.toString(),w1.msgHead.toString()),w3.onConnectionChanged(w41.default.ConnectionStatusReceiveing),w3._pullMessages(w15.default.MAX_VALUE,0,!0,w1.recvHead,w1.readHead,w1.groupConvHead,!0)):(w3.msgHead=w1.msgHead,w3._pullUserSettings(w1.settingHead));var w5=(new Date).getTime();w3.deltaTime=Number(w1.serverTime)-w5-(w5-w4)/2})),w3.mqttClientInstance.on("reconnect",(function(){w3.isConnecting=!1,w3.log("------reconnect--------",w3.clientId)})),w3.mqttClientInstance.on("offline",(function(){w3.log("------offline--------"),w3.isConnecting=!1,w3.connectionStatus=w41.default.ConnectionStatusUnconnected,!w3.isUserDisconnected&&w3._reconnect()})),w3.mqttClientInstance.on("close",(function(){w3.log("------close--------",w3.clientId),w3.isConnecting=!1,w3.connectionStatus=w41.default.ConnectionStatusUnconnected,!w3.isUserDisconnected&&w3._reconnect()})),w3.mqttClientInstance.on("disconnect",(function(){w3.log("------disconnect--------")})),w3.mqttClientInstance.on("error",(function(w0){w3.log("------error--------",w0),w3.isConnecting=!1,w3.connectionStatus=w41.default.ConnectionStatusUnconnected,!w3.isUserDisconnected&&w3._reconnect()})),w3.mqttClientInstance.on("pingresp",(function(w0){console.log("pingresp",(new Date).getTime()),w3.lastActiveTime=(new Date).getTime()})),w3.mqttClientInstance.on("message",(function(w0,w1,w2){if(w3.lastActiveTime=(new Date).getTime(),w3.log("on push",w0),"MS"===w0){var w4=w39.Message.decode(w1),w5=[];w5.push(w4),w3.onReceiveMessage(w5,!1,!1)}else if("MN"===w0){var w6=w39.NotifyMessage.decode(w1);w3._pullMessages(w6.head,w6.type,!1,!1,!1,!1,!1,!0)}else if("GMN"===w0){var w7=w39.NotifyGroupMessage.decode(w1);w3._pullGroupConvs(w7.head,w7.target,w7.line,!0)}else if("FN"===w0){if(8===w1.length){var w8=w3._getLongFromBuffer(w1);w3._pullFriends(w8)}}else if("FRN"===w0){if(8===w1.length){var w9=w3._getLongFromBuffer(w1);w3._pullFriendRequest(w9)}}else if("UN"===w0){if(8===w1.length){var w10=w3._getLongFromBuffer(w1);w3._pullUserSettings(w10)}}else if("RMN"===w0){var w11=w39.NotifyRecallMessage.decode(w1);w3.onRecallMessage(w11.fromUser,w11.id)}else if("RCN"===w0){if(8===w1.length){var w12=w3._getLongFromBuffer(w1);w3._pullRecv(w12)}}else if("RDN"===w0){if(8===w1.length){var w13=w3._getLongFromBuffer(w1);w3._pullRead(w13)}}else if("CONFN"===w0){var w14=w39.IDBuf.decode(w1);w3.onConferenceEvent(w14.id)}else"ROFL"===w0?(w3.warn("kicked off,need app relogin"),w3._reconnect(!0)):"UIN"===w0?w3.getUserInfo(w3.userId,!0):"POSN"===w0&&w3._onlineStateNotify(w1)}))}}),{backupAddressStrategy:this.backupAddressStrategy,backupHost:this.backupHost,backupPort:this.backupPort})):this.log("connect 0",this.isConnecting,this.connectionStatus,this.userId,this.token):this.error("userId and token must be string type"):this.log("userId or token error")):this.error("连接失败!!连接IM之前必须先调用 wfc.init 进行初始化!")}},{key:"_reconnect",value:function(){var w0=this,w2=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(w2)return this.log("force reconnect"),this.resetMqtt(),void this.connect(this.userId,this.token);this.isConnecting||setTimeout((function(){w0.connectionStatus!==w41.default.ConnectionStatusUnconnected||w0.isConnecting||(w0.resetMqtt(),w0.connect(w0.userId,w0.token))}),w1.connectionTimeout)}},{key:"_getLongFromBuffer",value:function(w0){return w15.default.fromBytesBE(w0.slice(0,8))}},{key:"_getStringFromBuffer",value:function(w0){return w0.toString()}},{key:"_pullMessages",value:function(w0){var w1=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,w2=arguments.length>2&&void 0!==arguments[2]&&arguments[2],w3=arguments[3],w4=arguments[4],w5=arguments[5],w6=this,w7=arguments.length>6&&void 0!==arguments[6]&&arguments[6],w8=arguments.length>7&&void 0!==arguments[7]&&arguments[7];if(this.log("to pull user messages",w0,w1,w2),1!==w1){if(w8&&(this.pendingMN=!0),this.isPullingMsg||this.msgHead.compare(w0)>=0&&!this.pendingMN)return this.log("local message is up to date or is pulling",w0,this.msgHead,w2,w3,w4,w7,w8),void(w2||w7?(this._pullUserSettings(w15.default.MAX_VALUE),this.isReceiptEnable&&(this._pullRecv(w3),this._pullRead(w4),w7&&this._syncRead()),this._pullGroupConvs(w5)):this.connectionStatus!==w41.default.ConnectionStatusConnected&&this.onConnectionChanged(w41.default.ConnectionStatusConnected));this.isPullingMsg=!0,this.pendingMN=!1}else{if(!this.currentChatRoomId)return;if(this.isPullingChatroomMsg||(0,w16.gte)(this.chatRoomMsgHead,w0))return;this.isPullingChatroomMsg=!0}var w9=w39.PullMessageRequest.encode({id:1!==w1?this.msgHead:this.chatRoomMsgHead,type:w1}).finish();this.log("pull user messages, type: "+w1+", head: "+(0,w16.stringValue)(w0)+", msgHead: "+(0,w16.stringValue)(this.msgHead)+", chatroomMsgHead: "+(0,w16.stringValue)(this.chatRoomMsgHead)),this._publish("MP",w9,(function(w0,w8){if(w6.log("pull user messages response",w0),0!==w0||!w8)return w6.log("pull message error",w0),1!==w1?w6.isPullingMsg=!1:w6.isPullingChatroomMsg=!1,void(w2&&w6._pullUserSettings(w6.settingHead));var w9=w39.PullMessageResult.decode(w8);if(0===w1)(0,w16.gt)(w9.current,w6.msgHead)&&(w6.msgHead=w9.current),w6.isPullingMsg=!1,w6.log("pull message result",(0,w16.stringValue)(w9.current),w9.message.length);else if(1===w1){if(w6.log("pull chatroom message result",(0,w16.stringValue)(w9.current),w9.message.length),w6.isPullingChatroomMsg=!1,w9.message.length>0&&w9.message[0].conversation.target!==w6.currentChatRoomId)return void w6.log("user not in chatroom now, drop message");w6.chatRoomMsgHead=w9.current}w6.onReceiveMessage(w9.message,w2),w6._pullMessages(w9.head,w1,w2,w3,w4,w5,w7)}))}},{key:"_pullRecv",value:function(w0){var w1=this;if(this.isReceiptEnable&&w0&&!this.isPullingRecv&&!(this.recvHead.compare(w0)>=0)){this.isPullingRecv=!0;var w2=w39.Version.create();w2.version=this.recvHead;var w3=w39.Version.encode(w2).finish();this.log("pull recv",this.recvHead),this._publish("RCP",w3,(function(w0,w2){if(w1.isPullingRecv=!1,0===w0&&w2){var w3=w39.PullDeliveryResult.decode(w2);w1.log("pull recv result",w3),w1.recvHead=w3.current,w1.store.updateDeliveries(w3.delivery);var w4=new w12.default;w3.delivery.forEach((function(w0){w4.set(w0.fromUser,w0.receiveTime)})),w1.eventEmitter.emit(w38.default.MessageReceived,w4),w1._pullRecv(w3.head)}}))}}},{key:"_pullRead",value:function(w0){var w1=this;if(!(!w0||this.isPullingRead||this.readHead.compare(w0)>=0)){this.isPullingRead=!0;var w2=w39.Version.create();w2.version=this.readHead;var w3=w39.Version.encode(w2).finish();this.log("pull read",this.readHead),this._publish("RDP",w3,(function(w0,w2){if(w1.isPullingRead=!1,0===w0&&w2){var w3=w39.PullReadResult.decode(w2);w1.log("pull read result",w3),w1.readHead=w3.current,w1.store.updateReads(w3.read);var w4=[];w3.read.forEach((function(w0){var w1=new w50.default;w1.userId=w0.fromUser,w1.readTime=w0.readTime,0===w0.conversation.type&&(w0.conversation.target=w0.fromUser),w1.conversation=(0,w8.default)(new w28.default,w0.conversation),w1.conversation.conversationType=w1.conversation.type,w4.push(w1)})),w1.eventEmitter.emit(w38.default.MessageRead,w4),w1._pullRead(w3.head)}}))}}},{key:"_pullGroupConvs",value:function(w0,w1,w2,w3){var w4=this;if(w3||!(0,w16.gte)(this.groupHead,w0))if(this.isPullingGroupMsg)this.pendingGMN=!0;else{this.isPullingGroupMsg=!0;var w5=w39.PullGroupConvRequest.create();w5.id=this.groupHead,w1&&(w5.target=w1,w5.line=w2,w5.messageId=this.store.getGroupMessageHead(w1,w2)),w5=w39.PullGroupConvRequest.encode(w5).finish(),this.log("pull groupConvs",this.groupHead),this._publish("GCP",w5,(function(w0,w3){if(w4.isPullingGroupMsg=!1,0===w0&&w3){var w5=w39.PullGroupConvResult.decode(w3);w4.log("pull groupConvs result",w5),w4._onPullGroupConvSuccess(w1,w2,w5)}}))}}},{key:"_onPullGroupConvSuccess",value:function(w0,w1,w2){this.groupHead=w2.current;var w3=!0,w4=!1,w5=void 0;try{for(var w6,w7=(0,w11.default)(w2.conv);!(w3=(w6=w7.next()).done);w3=!0){var w8=w6.value;this.store.setGroupMessageServerHead(w8.groupId,w8.line,w8.msgHead)}}catch(w0){w4=!0,w5=w0}finally{try{!w3&&w7.return&&w7.return()}finally{if(w4)throw w5}}var w9=w2.groupMessage;if(w0&&(w9.msg.length>0||w9.message.length>0)){var w10=w9.msg,w12=w9.message,w13=this._fillGroupMessage(w9.groupId,w9.line,w12),w14=w10.concat(w13);this._onPullGroupMessages(w14,[w9])}this.isPullingGroupMsg=!1,this._pullGroupMessages(),this.pendingGMN&&(this.pendingGMN=!1,this._pullGroupConvs(w15.default.MAX_VALUE,"",0,!1))}},{key:"_pullGroupMessages",value:function(){var w0=this;if(!this.isPullingGroupMsg){var w1=this.store.getGroupMessageHeads(),w2=[];if(w1.length>0){var w3=!0,w4=!1,w5=void 0;try{for(var w6,w7=(0,w11.default)(w1);!(w3=(w6=w7.next()).done);w3=!0){var w8=w6.value,w9=w39.PullGroupMessageRequest.create();w9.groupId=w8.target,w9.line=w8.line,w9.id=w8.head,w2.push(w9)}}catch(w0){w4=!0,w5=w0}finally{try{!w3&&w7.return&&w7.return()}finally{if(w4)throw w5}}}if(w2.length>0){this.isPullingGroupMsg=!0;var w10=w39.PullGroupMessageRequests.create();w10.request=w2,this.log("_pullGroupMessages",w10,w2),w10=w39.PullGroupMessageRequests.encode(w10).finish(),this._publish("GMP",w10,(function(w1,w2){if(w0.isPullingGroupMsg=!1,0===w1&&w2){var w3=w39.PullGroupMessageResults.decode(w2);w0.log("_pullGroupMessages result",w3),w0._onPullGroupMessagesSuccess(w3)}}))}}}},{key:"_onPullGroupMessagesSuccess",value:function(w0){if(w0.result.length){var w1=[],w2=!0,w3=!1,w4=void 0;try{for(var w5,w6=(0,w11.default)(w0.result);!(w2=(w5=w6.next()).done);w2=!0){var w7=w5.value,w8=w7.msg,w9=w7.message,w10=this._fillGroupMessage(w7.groupId,w7.line,w9);w1=w1.concat(w8.concat(w10))}}catch(w0){w3=!0,w4=w0}finally{try{!w2&&w6.return&&w6.return()}finally{if(w3)throw w4}}this._onPullGroupMessages(w1,w0.result)}this.isPullingGroupMsg=!1,this._pullGroupMessages(),this.pendingGMN&&(this.pendingGMN=!1,this._pullGroupConvs(w15.default.MAX_VALUE,"",0,!1))}},{key:"_onPullGroupMessages",value:function(w0,w1){console.log("_onPullGroupMessages",w0,w1),this.onReceiveMessage(w0,!1,!0,w0.length>50);var w2=!0,w3=!1,w4=void 0;try{for(var w5,w6=(0,w11.default)(w1);!(w2=(w5=w6.next()).done);w2=!0){var w7=w5.value,w8=w29.default.Group+"-"+w7.line+"-"+w7.groupId,w9=this.getUserSetting(w37.default.Conversation_Sync,w8);w9&&(0,w16.gt)(w9,0),this.store.setGroupMessageHead(w7.groupId,w7.line,w7.current),this.store.setGroupMessageServerHead(w7.groupId,w7.line,w7.head)}}catch(w0){w3=!0,w4=w0}finally{try{!w2&&w6.return&&w6.return()}finally{if(w3)throw w4}}}},{key:"_parseGroupMessageFlag",value:function(w0){return{contentType:w0>>8&2047,persistFlag:w0>>4&15,mentionedType:w0>>1&7,send:(1&w0)>0}}},{key:"_messageId2Time",value:function(w0){var w1=w0.shiftRight(21);return w1=w1.add(1514736e6)}},{key:"_fillGroupMessage",value:function(w0,w1,w2){var w3=[],w4=!0,w5=!1,w6=void 0;try{for(var w7,w8=(0,w11.default)(w2);!(w4=(w7=w8.next()).done);w4=!0){var w9=w7.value,w10=w39.Message.create(),w12=this._parseGroupMessageFlag(w9.flag);w10.messageId=w9.messageId,w10.conversation=w39.Conversation.create(),w10.conversation.type=w29.default.Group,w10.conversation.target=w0,w10.conversation.line=w1,w10.content=w39.MessageContent.create(),w10.content.type=w12.contentType,w10.content.persistFlag=w12.persistFlag,w10.content.mentionedType=w12.mentionedType,w10.content.__notLoaded=!0,w10.content.mentionedType>0&&2!==w10.content.mentionedType&&w10.content.mentionedTarget.push(this.userId),w10.fromUser=w9.fromUser,w10.serverTimestamp=this._messageId2Time(w9.messageId),w3.push(w10)}}catch(w0){w5=!0,w6=w0}finally{try{!w4&&w8.return&&w8.return()}finally{if(w5)throw w6}}return w3}},{key:"isReceiptEnabled",value:function(){return this.isReceiptEnable}},{key:"getConversationDelivery",value:function(w0){return this.store.getConversationDelivery(w0)}},{key:"getConversationRead",value:function(w0){return this.store.getConversationRead(w0)}},{key:"setDeviceToken",value:function(w0,w1){var w2=this;if(w0>5&&w1){var w3=w39.UploadDeviceTokenRequest.create();w3.pushType=w0,w3.appName="wfc.web",w3.deviceToken=w1,w3.platform=5,this._publish("UDT",w39.UploadDeviceTokenRequest.encode(w3).finish(),(function(w0,w1){w0||w2.log("setDeviceToken error",w0)}))}else this.error("setDeviceToken error, invalid parameters",w0,w1)}},{key:"getAuthCode",value:function(w0,w1,w2,w3,w4){var w5=w39.AuthCodeRequest.create();w5.targetId=w0,w5.type=w1,w5.host=w2,this._publish("ATR",w39.AuthCodeRequest.encode(w5).finish(),(function(w0,w1){if(0===w0){var w2=null;if(w1)w2=w39.IDBuf.decode(w1).id;w3&&w3(w2)}else w4&&w4(w0)}))}},{key:"_pullUnreadMessages",value:(w59=(0,w7.default)(w6.default.mark((function w0(){var w1,w2,w3,w4,w5;return w6.default.wrap((function(w0){for(;;)switch(w0.prev=w0.next){case 0:w1=this.getConversationList([0,1],[0]),w2=200,w3=0;case 3:if(!(w3w3)){w0.next=6;break}return console.log("Up to "+w3+" unread messages can be loaded.",w1),w0.abrupt("return",null);case 6:return w4=w1.type+"-"+w1.line+"-"+w1.target,w7=this.getUserSetting(w37.default.Conversation_Sync,w4),w8=this.getUserSetting(w37.default.ConversationSilent,w4),w9=new w5.default((function(w0,w3){w8&&"0"===w8.value||!w7?w0(null):(0,w16.gt)(w2.timestamp,w7.value)?w10.loadRemoteMessages(w1,[],w2.messageUid,50,(function(w3){console.log("load conversation unread msgs",w4,(0,w16.stringValue)(w2.messageUid),w3.length),w10.store.updateConversationUnreadStatus(w1,w7.value),w3.length>0?w0(w3[0]):w0(null)}),(function(w1){w0(null)}),!1):w0(null)})),w0.abrupt("return",w9);case 11:case"end":return w0.stop()}}),w0,this)}))),function(w0,w1){return w2.apply(this,arguments)})},{key:"_pullUserSettings",value:function(w0){var w1=this;if(this.log("pull user setting...",w0),!this.isPullingSetting)if(this.settingHead.compare(w15.default.ZERO)>0&&this.settingHead.compare(w0)>=0)this.connectionStatus!==w41.default.ConnectionStatusConnected&&this.onConnectionChanged(w41.default.ConnectionStatusConnected);else{this.isPullingSetting=!0;var w2=w39.Version.create();w2.version=this.settingHead;var w3=w39.Version.encode(w2).finish();this._publish("UG",w3,(function(w2,w3){if(w1.log("pull user setting response"),w1.isPullingSetting=!1,0===w2&&w3){var w4=w39.GetUserSettingResult.decode(w3),w5=w1.settingHead;w4.entry.length>0?w4.entry.forEach((function(w0){w5=(0,w16.gt)(w0.updateDt,w5)?w0.updateDt:w5})):w5=w0,w1.store.updateUserSettings(w4.entry),w1._preloadConversationTargetInfos(),w1.onSettingUpdate(w4.entry),w1.settingHead=w5,(0,w16.gt)(w0,w5)?w1._pullUserSettings(w0):w1.connectionStatus!==w41.default.ConnectionStatusConnected&&w1.onConnectionChanged(w41.default.ConnectionStatusConnected)}else w1.connectionStatus!==w41.default.ConnectionStatusConnected&&(0===w2?w1.onConnectionChanged(w41.default.ConnectionStatusConnected):w1.onConnectionChanged(w41.default.ConnectionStatusUnconnected),w1.log("pull user setting error",w2))}))}}},{key:"_preloadConversationTargetInfos",value:function(){if(!this.isConversationTargetPreloaded){this.isConversationTargetPreloaded=!0;var w0=this.store._getConversationInfos(),w1=[],w2=new w4.default;w0.forEach((function(w0){w0.conversation.type===w29.default.Single?w2.add(w0.conversation.target):w0.conversation.type===w29.default.Group&&w1.push(w0.conversation.target),w0.lastMessage&&w0.lastMessage.from&&w2.add(w0.lastMessage.from)})),w2.add(this.getUserId()),this.getGroupInfos(w1),this.getUserInfos((0,w3.default)(w2))}}},{key:"_preloadFiendsUserInfo",value:function(){if(!this.isFriendPreloaded){this.isFriendPreloaded=!0;var w0=this.store.getFriendIds();this.getUserInfos(w0)}}},{key:"_preloadFirendRequsetUserInfo",value:function(){this.isFriendRequestPreloaded}},{key:"_updateUserSetting",value:function(w0,w1,w2,w3,w4){var w5=this,w6=w39.ModifyUserSettingReq.create();w6.scope=w0,w6.key=w1,w6.value=w2+"";var w7=w39.ModifyUserSettingReq.encode(w6).finish();this._publish("UP",w7,(function(w6,w7){if(0===w6){var w8=new w42.default;w8.scope=w0,w8.key=w1,w8.value=w2,w8.updateDt=(new Date).getTime(),w5.store.updateUserSettings([w8]),w3&&w3()}else w4&&w4(w6)}))}},{key:"_pullFriends",value:function(w0){var w1=this;if(this.friendHead.compare(w0)>=0)return 0;var w2=w39.Version.create();w2.version=this.friendHead;var w3=w39.Version.encode(w2).finish();this._publish("FP",w3,(function(w2,w3){if(0===w2&&w3){var w4=w39.GetFriendsResult.decode(w3);w1.log("fr",w4);var w5=[],w6=0;w4.entry.map((function(w0){0===w0.state&&w5.push(w0.uid),w1.store.insertFriend((0,w8.default)(new w46.default,w0)),w6=(0,w16.gt)(w0.updateDt,w6)?w0.updateDt:w6})),w1.friendHead=w6,(0,w16.gt)(w0,w1.friendHead)&&w1._pullFriends(w0),w1._preloadFiendsUserInfo(),w1.onFriendListUpdate(w5)}else w1.log("pull friend error",w2)}))}},{key:"_pullFriendRequest",value:function(w0){if(this.log("_pullFriendRequest",w0),!(this.friendRequestHead.compare(w0)>=0)){var w1=this.store.getFriendRequestMaxDt();this.loadFriendRequestFromRemote(w1)}}},{key:"disconnect",value:function(){this.onConnectionChanged(w41.default.ConnectionStatusLogout),this.reset(),this.isUserDisconnected=!0}},{key:"getProtoRevision",value:function(){return w1.version}},{key:"getUserId",value:function(){return this.userId}},{key:"getServerDeltaTime",value:function(){return parseInt(this.deltaTime)}},{key:"isLogin",value:function(){return this.token&&this.token.length>0}},{key:"getConnectionStatus",value:function(){return this.connectionStatus}},{key:"setBackupAddressStrategy",value:function(w0){this.backupAddressStrategy=w0}},{key:"setBackupAddress",value:function(w0,w1){this.backupHost=w0,this.backupPort=w1}},{key:"useSM4",value:function(){this.log("use encryptSM4"),(0,w17.useEncryptSM4)()}},{key:"getMyGroupList",value:function(){var w0=this.store.getFavGroups();return w0&&0!==w0.length?this.getGroupInfos(w0):[]}},{key:"_publish",value:function(w0,w1,w2){var w3=this,w4=this._encrypt(w1);if(!this.mqttClientInstance)return this.log("the connect is reset, reconnecting"),void(w2&&w2(-1));var w5=setTimeout((function(){w3.log("publish not response after "+w43.default.SEND_MESSAGE_TIMEOUT+"s, reset"),w2&&w2(-1),w3.connectionStatus=w41.default.ConnectionStatusUnconnected,w3._reconnect()}),1e3*(w43.default.SEND_MESSAGE_TIMEOUT?w43.default.SEND_MESSAGE_TIMEOUT:20));this.mqttClientInstance.publish(w0,w4,{qos:1,retain:!0,dup:!0},(function(w1,w4){if(clearTimeout(w5),w2){if(w1)return w3.log("publish error",w0,w1),w2(-1),void("Connection closed"===w1.message&&(w3.connectionStatus=w41.default.ConnectionStatusUnconnected,w3._reconnect()));if(w3.lastActiveTime=(new Date).getTime(),w3.log("publish response",w0),!w4||!w4.payload||w4.payload.length<1)return w3.log("publish response error",w4),void(w2&&w2(-1));var w6=w4.payload[0];if(0===w6||255===w6||5===w6){w3.log("publish error code ",w0,w6);var w7=null;if(w4.payload&&w4.payload.length>1){if(w7=w3._decryptPublishResponse(w4),255===w6){w3.log("publish response compressed");try{w7=w44.default.inflate(w7)}catch(w1){w3.log("decompress response error",w1)}}w2(0,w7)}else w3.log("publish response is empty"),w2(0,null)}else w3.log("publish error",w0,w6),w2(w6),w6===w45.default.kEcServerTokenIncorrect||w6===w45.default.kEcServerUserIsBlocked||w45.default.kEcServerSecrectKeyMismatch}else w3.log("publish, cb is null, drop")}))}},{key:"_reloadUserInfosFromRemote",value:function(w0){for(var w1=this,w2=function(w2){setTimeout((function(){w1._reloadUserInfosFromRemoteEx(null,null,w0.slice(2e3*w2,2e3*(w2+1)))}),1e3*w2)},w3=0;w30){var w7=[];w3.log("load userInfo from remote",w6),w6.forEach((function(w0){if(0===w0.code){var w1=(0,w8.default)(new w36.default,w0.user);w43.default.urlRedirect&&(w1.portrait=w43.default.urlRedirect(w1.portrait)),w3.store.setUser(w1),w7.push(w3.store.getUser(w1.uid,""))}})),w0&&w0(w7),w7.length>0&&w3.eventEmitter.emit(w38.default.UserInfosUpdate,w7)}else w3.log("reload userInfo from remote response empty"),w1&&w1(-1)})))}},{key:"_reloadUserInfoFromRemote",value:function(w0,w1,w2,w3){var w4=this,w5=w39.PullUserRequest.create(),w6=w39.UserRequest.create();w6.uid=w0,w6.updateDt=w15.default.fromValue(w1),w5.request.push(w6),this.log("reload userInfo from remote",w0),this._publish("UPUI",w39.PullUserRequest.encode(w5).finish(),(function(w1,w5){if(0!==w1||!w5)return w3&&w3(0===w1?-1:w1),void w4.log("reloadUserInfoFromRemote error",w1,w0);var w6=w39.PullUserResult.decode(w5).result;if(w6.length>0){var w7=[];w4.log("load userInfo from remote",w6),w6.forEach((function(w0){var w1=(0,w8.default)(new w36.default,w0.user);w43.default.urlRedirect&&(w1.portrait=w43.default.urlRedirect(w1.portrait)),w4.store.setUser(w1),w7.push(w4.store.getUser(w1.uid,""))})),w2&&w2(w7[0])}else w3&&w3(-1)}))}},{key:"getUserInfo",value:function(w0){var w1=arguments.length>1&&void 0!==arguments[1]&&arguments[1],w2=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",w3=this.store.getUser(w0,w2);return(w1||w3 instanceof w35.default)&&this._reloadUserInfosFromRemote([w0]),w3}},{key:"getUserInfoEx",value:function(w0,w1,w2,w3){var w4=this.store.getUser(w0);w4 instanceof w35.default||w2&&w2(w4),(w1||w4 instanceof w35.default)&&this._reloadUserInfosFromRemoteEx((function(w0){w2&&w2(w0[0])}),w3,[w0])}},{key:"getUserInfos",value:function(){var w0=this,w1=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],w2=arguments[1],w3=[],w4=[];return w1.forEach((function(w1){var w5=w0.store.getUser(w1,w2);w5 instanceof w35.default&&w4.push(w1),w3.push(w5)})),w4.length>0&&this._reloadUserInfosFromRemote(w4),w3}},{key:"getUserInfosEx",value:function(w0,w1,w2){var w3=this,w4=[],w5=[];w0.forEach((function(w0){var w1=w3.store.getUser(w0);w1 instanceof w35.default?w5.push(w0):w4.push(w1)})),w5.length>0?this._reloadUserInfosFromRemoteEx((function(w0){w4.push.apply(w4,(0,w10.default)(w0)),w1&&w1(w4)}),w2,w0):w1&&w1(w4)}},{key:"searchUser",value:function(w0,w1,w2,w3,w4){var w5=w39.SearchUserRequest.create();w5.fuzzy=w1,w5.keyword=w0,w5.page=w2,this._publish("US",w39.SearchUserRequest.encode(w5).finish(),(function(){var w1=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2,w2=arguments[1];if(0===w1&&w2){if(w3){var w5=w39.SearchUserResult.decode(w2);w3(w0,w5.entry)}}else w4&&w4(w1)}))}},{key:"searchFriends",value:function(w0){return this.store.searchFriends(w0)}},{key:"searchGroups",value:function(w0){return this.store.searchGroups(w0)}},{key:"getIncommingFriendRequest",value:function(){return this.store.getIncommingFriendRequest()}},{key:"getOutgoingFriendRequest",value:function(){return this.store.getOutgoingFriendRequest()}},{key:"getOneFriendRequest",value:function(w0,w1){return this.store.getOneFriendRequest(w0,w1)}},{key:"loadFriendRequestFromRemote",value:function(w0){var w1=this,w2=w39.Version.create();w2.version=w0,this._publish("FRP",w39.Version.encode(w2).finish(),(function(w2,w3){if(0===w2&&w3){var w4=0,w5=w39.GetFriendRequestResult.decode(w3);w1.log("load friend request result",w5);var w6=[];w5.entry.forEach((function(w0){var w2=new w30.default;w2.status=w0.status,w2.reason=w0.reason,w2.extra=w0.extra,w0.fromUid===w1.getUserId()?(w2.direction=0,w2.target=w0.toUid,w2.readStatus=w0.fromReadStatus?1:0):(w2.direction=1,w2.target=w0.fromUid,w2.readStatus=w0.toReadStatus?1:0,0===w2.readStatus&&w6.push(w2.target)),w2.timestamp=w0.updateDt,(0,w16.gt)(w0.updateDt,w4)&&(w4=w0.updateDt),w1.store.insertOrReplaceFriendRequest(w2)})),w1.friendRequestHead=w4,(0,w16.gt)(w0,w4)&&w1.loadFriendRequestFromRemote(w4),w1.onFriendRequestUpdate(w6)}}))}},{key:"getUnreadFriendRequestCount",value:function(){return this.store.getUnreadFriendRequestCount()}},{key:"clearUnreadFriendRequestStatus",value:function(){var w0=this.store.getUnreadFriendRequestMaxDt();if(0!==w15.default.ZERO.compare(w0)&&this.store.clearUnreadFriendRequestStatus()>0){var w1=w39.Version.create();w1.version=w0,this._publish("FRUS",w39.Version.encode(w1).finish(),(function(w0,w1){}))}}},{key:"deleteFriend",value:function(w0,w1,w2){var w3=this,w4=w39.IDBuf.create();w4.id=w0,this._publish("FDL",w39.IDBuf.encode(w4).finish(),(function(){var w4=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2;0===w4?(w3.store.deleteFriend(w0),w1&&w1()):w2(w4)}))}},{key:"handleFriendRequest",value:function(w0,w1,w2,w3,w4){var w5=this,w6=w39.HandleFriendRequest.create();w6.status=w1?1:2,w6.targetUid=w0,w6.extra=w2,this._publish("FHR",w39.HandleFriendRequest.encode(w6).finish(),(function(w1,w2){0===w1?(w5.store.updateFriendRequestStatus(w0,w6.status),w3&&w3()):w4&&w4(w1)}))}},{key:"isBlackListed",value:function(w0){this.store.isBlackListed(w0)}},{key:"getBlackList",value:function(){return this.store.getBlackList()}},{key:"setBlackList",value:function(w0,w1,w2,w3){var w4=this,w5=w39.BlackUserRequest.create();w5.status=w1?2:1,w5.uid=w0,this._publish("BLU",w39.BlackUserRequest.encode(w5).finish(),(function(w5,w6){0===w5?(w4.store.setBlackList(w0,w1),w2&&w2()):w3&&w3()}))}},{key:"getMyFriendList",value:function(){var w0=arguments.length>0&&void 0!==arguments[0]&&arguments[0],w1=this.store.getFriendIds();return(w0||0===w1.length)&&this._getMyFriendListFromRemote(),w1}},{key:"getFriendList",value:function(){var w0=arguments.length>0&&void 0!==arguments[0]&&arguments[0],w1=this.store.getFriends();return(0===w1.length||w0)&&this._getMyFriendListFromRemote(),w1}},{key:"getFriendAlias",value:function(w0){return this.store.getFriendAlias(w0)}},{key:"getFriendExtra",value:function(w0){return this.store.getFriendExtra(w0)}},{key:"setFriendAlias",value:function(w0,w1,w2,w3){var w4=w39.AddFriendRequest.create();w4.targetUid=w0,w4.reason=w1,this._publish("FALS",w39.AddFriendRequest.encode(w4).finish(),(function(w0,w1){0===w0?w2():w3(w0)}))}},{key:"_getMyFriendListFromRemote",value:function(){this._pullFriends(w15.default.MAX_VALUE)}},{key:"createGroup",value:function(w0,w1,w2,w3,w4){var w5=arguments.length>5&&void 0!==arguments[5]?arguments[5]:[],w6=arguments[6],w7=arguments.length>7&&void 0!==arguments[7]?arguments[7]:[0],w8=arguments[8],w9=this,w10=arguments[9],w11=arguments[10];w0=w0||"";var w12=this.getUserId(),w13=w39.Group.create(),w14=w39.GroupInfo.create();w14.targetId=w0,w14.type=w1,w14.name=w2,w14.portrait=w3,w14.extra=w4||"",w13.groupInfo=w14;var w15=new w31.default;w15.target=w0,w15.type=w1,w15.name=w2,w15.portrait=w3,w15.extra=w14.extra;var w16=[];w5.includes(w12)||w5.push(w12);var w17=void 0;w5.forEach((function(w1){var w2=w39.GroupMember.create();w2.memberId=w1,w2.type=w33.default.Normal,(w17=new w32.default).groupId=w0,w17.memberId=w1,w17.type=w33.default.Normal,w1===w12&&(w2.type=w33.default.Owner,w17.type=w33.default.Owner),w13.members.push(w2),w16.push(w17)}));var w18=w39.CreateGroupRequest.create();w18.group=w13,w18.toLine=w7,w18.memberExtra=w6||"",w18.notifyContent=this._toProtoMessageContent(w8),this._publish("GC",w39.CreateGroupRequest.encode(w18).finish(),(function(){var w0=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2,w1=arguments[1];if(0===w0&&w1){var w2=w1.toString();w15.target=w2;var w3=new w28.default(w29.default.Group,w2,0);if(w9.store.genAndSaveDefaultConversationInfo(w3),w9.store.setGroupInfo(w15),w9.store.setGroupMembers(w2,w16),w8){var w4=new w21.default(w3,w8);w9.store.updateConversationLastMessage(w4)}w10&&w10(w2),w9.log("create group success",w2)}else w9.log("create group error",w0),w11&&w11(w0)}))}},{key:"setGroupManager",value:function(w0,w1,w2,w3,w4,w5,w6){var w7=this,w8=w39.SetGroupManagerRequest.create();w8.type=w1?1:0,w8.groupId=w0,w8.userId=w2,w8.toLine=w3,w8.notifyContent=this._toProtoMessageContent(w4),this._publish("GSM",w39.SetGroupManagerRequest.encode(w8).finish(),(function(w1,w2){0===w1?(w5&&w5(),w7.log("set group manager success",w0)):(w7.log("set group manager error",w1),w6&&w6(w1))}))}},{key:"_reloadGroupInfosFromRemote",value:function(){for(var w0=arguments.length,w1=Array(w0),w2=0;w20){var w7=[];w6.forEach((function(w0){var w1=(0,w8.default)(new w31.default,w0);w1.target=w0.targetId,delete w1.targetId,w43.default.urlRedirect&&(w1.portrait=w43.default.urlRedirect(w1.portrait)),w3.store.setGroupInfo(w1),w7.push(w1)})),w0&&w0(w7),w3.eventEmitter.emit(w38.default.GroupInfosUpdate,w7)}})))}},{key:"_reloadGroupMembersFromRemote",value:function(w0,w1){this._reloadGroupMembersFromRemoteEx(w0,w1,null,null)}},{key:"_reloadGroupMembersFromRemoteEx",value:function(w0,w1,w2,w3){var w4=this;if(w2||!this.store.loadingGroupMembers.has(w0)){this.store.loadingGroupMembers.add(w0);var w5=w39.PullGroupMemberRequest.create();w5.target=w0,w5.head=w15.default.fromValue(w1),this._publish("GPGM",w39.PullGroupMemberRequest.encode(w5).finish(),(function(w1,w5){if(w4.store.loadingGroupMembers.delete(w0),0===w1&&w5){var w6=w39.PullGroupMemberResult.decode(w5).member,w7=[],w8=!1;w6.forEach((function(w1){var w2=new w32.default;w2.groupId=w0,w2.alias=w1.alias,w2.extra=w1.extra,w2.type=w1.type,w2.memberId=w1.memberId,w2.updateDt=w1.updateDt,w2.createDt=w1.createDt,w7.push(w2);var w3=w4.store.getGroupMember(w0,w4.userId);w2.memberId===w4.userId&&w3&&w3.type===w33.default.Removed&&(w8=!0)})),w4.log("loadGroupMembersFromRemote",w0,w7.length),w4.store.updateGroupMembers(w0,w7),w7=w4.store.getGroupMembers(w0),w2&&w2(w7),!w8&&w7.length>0?(w4.eventEmitter.emit(w38.default.GroupMembersUpdate,w0,w7),w4.log("emit groupMembersUpdate",w0,w7)):w4.log("self deleted",w0)}else{if(w4.log("reloadGroupMembersFromRemote error",w0,w1),253===w1){var w9=new w28.default(w29.default.Group,w0,0);w4.store.removeConversation(w9,!0),console.log("remove conversation",w9)}w3&&w3(0!==w1?w1:-1)}}))}}},{key:"getGroupInfo",value:function(w0){var w1=arguments.length>1&&void 0!==arguments[1]&&arguments[1],w2=this.store.getGroupInfo(w0);return(w1||w2 instanceof w34.default)&&this._reloadGroupInfosFromRemote(w0),w2 instanceof w34.default&&this._reloadGroupMembersFromRemote(w0,this.store.getGroupMemberMaxDt(w0)),w2}},{key:"getGroupInfoEx",value:function(w0){var w1=arguments.length>1&&void 0!==arguments[1]&&arguments[1],w2=arguments[2],w3=arguments[3],w4=this.store.getGroupInfo(w0);w4 instanceof w34.default||w2&&w2(w4),(w1||w4 instanceof w34.default)&&this._reloadGroupInfosFromRemoteEx((function(w0){w2&&w2(w0[0])}),w3,[w0]),w4 instanceof w34.default&&this._reloadGroupMembersFromRemote(w0,this.store.getGroupMemberMaxDt(w0))}},{key:"getGroupInfos",value:function(){var w0=this,w1=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],w2=arguments.length>1&&void 0!==arguments[1]&&arguments[1],w3=[],w4=[];if(w1.forEach((function(w1){var w5=w0.store.getGroupInfo(w1);(w5 instanceof w34.default||w2)&&w4.push(w1),w3.push(w5)})),w4.length>0&&(this._reloadGroupInfosFromRemote.apply(this,w4),w4.length<=50)){var w5=!0,w6=!1,w7=void 0;try{for(var w8,w9=(0,w11.default)(w4);!(w5=(w8=w9.next()).done);w5=!0){var w10=w8.value;this._reloadGroupMembersFromRemote(w10,this.store.getGroupMemberMaxDt(w10))}}catch(w0){w6=!0,w7=w0}finally{try{!w5&&w9.return&&w9.return()}finally{if(w6)throw w7}}}return w3}},{key:"addGroupMembers",value:function(w0,w1,w2,w3,w4,w5,w6){var w7=this;if(!w0||!w1||0===w1.length||!w3||0===w3.length)return this.log("addGroupMembers params invalid"),void(w6&&w6(-1));var w8=w39.AddGroupMemberRequest.create();w8.groupId=w0,w1.forEach((function(w0){var w1=w39.GroupMember.create();w1.memberId=w0,w1.type=w33.default.Normal,w8.addedMember.push(w1)})),w8.toLine=w3,w8.extra=w2,w8.notifyContent=this._toProtoMessageContent(w4),this._publish("GAM",w39.AddGroupMemberRequest.encode(w8).finish(),(function(w2,w3){if(0===w2){var w4=[],w8=(new Date).getTime();w1.forEach((function(w1){var w2=new w32.default;w2.groupId=w0,w2.type=w33.default.Normal,w2.memberId=w1,w2.updateDt=w8,w2.createDt=w8,w4.push(w2)})),w7.store.updateGroupMembers(w0,w4)}w7._generalOperationCallback(w2,w5,w6)}))}},{key:"getGroupMemberIds",value:function(w0){var w1=arguments.length>1&&void 0!==arguments[1]&&arguments[1],w2=this.store.getGroupMemberIds(w0,w1);return(0===w2.length||w1)&&this._reloadGroupMembersFromRemote(w0,this.store.getGroupMemberMaxDt(w0)),w2}},{key:"getGroupMembers",value:function(w0){var w1=arguments.length>1&&void 0!==arguments[1]&&arguments[1],w2=this.store.getGroupInfo(w0),w3=this.store.getGroupMemberMaxDt(w0);if(w2 instanceof w34.default)return this._reloadGroupInfosFromRemote(w0),this._reloadGroupMembersFromRemote(w0,w3),null;var w4=this.store.getGroupMembers(w0);return(0===w4.length||w1)&&this._reloadGroupMembersFromRemote(w0,w3),w4.sort(this._compareGroupMember)}},{key:"getGroupMembersByType",value:function(w0,w1){var w2=this.getGroupMembers(w0);return 0===w2.length&&this._reloadGroupMembersFromRemote(w0,w15.default.ZERO),w2.filter((function(w0){return w0.type===w1}))}},{key:"_compareGroupMember",value:function(w0,w1){return w0.type===w1.type?(0,w16.numberValue)(w0.updateDt)-(0,w16.numberValue)(w1.updateDt):4===w0.type?-1:4===w1.type?1:w1.type-w0.type}},{key:"getGroupMembersEx",value:function(w0){var w1=arguments.length>1&&void 0!==arguments[1]&&arguments[1],w2=arguments[2],w3=arguments[3],w4=this.store.getGroupMembers(w0),w5=this.store.getGroupMemberMaxDt(w0);0===w4.length||w1?this._reloadGroupMembersFromRemoteEx(w0,w5,w2,w3):(w2&&w2(w4.sort(this._compareGroupMember)),w1&&this._reloadGroupMembersFromRemoteEx(w0,w5))}},{key:"getGroupMember",value:function(w0,w1){if(this.store.getGroupInfo(w0)instanceof w34.default)return this._reloadGroupInfosFromRemote(w0),this._reloadGroupMembersFromRemote(w0,this.store.getGroupMemberMaxDt(w0)),null;var w2=this.store.getGroupMember(w0,w1);return w2||this._reloadGroupMembersFromRemote(w0,this.store.getGroupMemberMaxDt(w0)),w2}},{key:"kickoffGroupMembers",value:function(w0,w1,w2,w3,w4,w5){var w6=this,w7=w39.RemoveGroupMemberRequest.create();w7.groupId=w0,w7.removedMember=w1,w7.toLine=w2,w7.notifyContent=this._toProtoMessageContent(w3),this._publish("GKM",w39.RemoveGroupMemberRequest.encode(w7).finish(),(function(w2,w3){0===w2&&w6.store.removeGroupMembers(w0,w1),w6._generalOperationCallback(w2,w4,w5)}))}},{key:"muteOrAllowGroupMembers",value:function(w0,w1,w2,w3,w4,w5,w6,w7){var w8=this,w9=w39.SetGroupManagerRequest.create();w9.type=w1?1:0,w9.groupId=w0,w9.userId=w3,w9.toLine=w4,w9.notifyContent=this._toProtoMessageContent(w5),this._publish(w2?"GMAL":"GMM",w39.SetGroupManagerRequest.encode(w9).finish(),(function(w4,w5){0===w4?(w8.store.updateGroupMemberMuteOrAllow(w0,w3,w1,w2),w6&&w6(),w8.log("mute group member success",w0,w3)):(w8.log("mute group member error",w4),w7&&w7(w4))}))}},{key:"quitGroup",value:function(w0,w1,w2,w3,w4){var w5=this,w6=w39.QuitGroupRequest.create();w6.groupId=w0,w6.toLine=w1,w6.notifyContent=this._toProtoMessageContent(w2),this._publish("GQ",w39.QuitGroupRequest.encode(w6).finish(),(function(w1,w2){0===w1&&(w5.store.removeGroupAndMembers(w0),w5.store.removeGroupSettings(w0),w5.store.removeFavGroup(w0)),w5._generalOperationCallback(w1,w3,w4)}))}},{key:"dismissGroup",value:function(w0,w1,w2,w3,w4){var w5=this,w6=w39.DismissGroupRequest.create();w6.groupId=w0,w6.toLine=w1,w6.notifyContent=this._toProtoMessageContent(w2),this._publish("GD",w39.DismissGroupRequest.encode(w6).finish(),(function(w1,w2){0===w1?(w5.store.removeGroupAndMembers(w0),w5.store.removeGroupSettings(w0),w5.store.removeFavGroup(w0),w5.serverConfigs.isKeepMsgAfterDismiss||w5.store.removeConversation(new w28.default(w29.default.Group,w0,0),!0),w3&&w3()):w4&&w4(w1)}))}},{key:"modifyGroupInfo",value:function(w0,w1,w2,w3,w4,w5,w6){var w7=this,w8=w39.ModifyGroupInfoRequest.create();w8.groupId=w0,w8.toLine=w3,w8.type=w1,w8.value=w2+"",w8.notifyContent=this._toProtoMessageContent(w4),this._publish("GMI",w39.ModifyGroupInfoRequest.encode(w8).finish(),(function(w0,w1){w7._generalOperationCallback(w0,w5,w6)}))}},{key:"modifyGroupAlias",value:function(w0,w1,w2,w3,w4,w5){var w6=this,w7=w39.ModifyGroupMemberAlias.create();w7.groupId=w0,w7.alias=w1,w7.toLine=w2,w7.notifyContent=this._toProtoMessageContent(w3),this._publish("GMA",w39.ModifyGroupMemberAlias.encode(w7).finish(),(function(w0,w1){w6._generalOperationCallback(w0,w4,w5)}))}},{key:"modifyGroupMemberAlias",value:function(w0,w1,w2,w3,w4,w5,w6){var w7=this,w8=w39.ModifyGroupMemberAlias.create();w8.groupId=w0,w8.memberId=w1,w8.alias=w2,w8.toLine=w3,w8.notifyContent=this._toProtoMessageContent(w4),this._publish("GMMA",w39.ModifyGroupMemberAlias.encode(w8).finish(),(function(w3,w4){0===w3&&w7.store.updateGroupMemberAlias(w0,w1,w2),w7._generalOperationCallback(w3,w5,w6)}))}},{key:"modifyGroupMemberExtra",value:function(w0,w1,w2,w3,w4,w5,w6){var w7=this,w8=w39.ModifyGroupMemberExtra.create();w8.groupId=w0,w8.memberId=w1,w8.extra=w2,w8.toLine=w3,w8.notifyContent=this._toProtoMessageContent(w4),this._publish("GMME",w39.ModifyGroupMemberExtra.encode(w8).finish(),(function(w3,w4){0===w3&&w7.store.updateGroupMemberExtra(w0,w1,w2),w7._generalOperationCallback(w3,w5,w6)}))}},{key:"transferGroup",value:function(w0,w1,w2,w3,w4,w5){var w6=this,w7=w39.TransferGroupRequest.create();w7.groupId=w0,w7.newOwner=w1,w7.toLine=w2,w7.notifyContent=this._toProtoMessageContent(w3),this._publish("GTG",w39.TransferGroupRequest.encode(w7).finish(),(function(w0,w1){w6._generalOperationCallback(w0,w4,w5)}))}},{key:"setGroupRemark",value:function(w0,w1,w2,w3){var w4=this;this.setUserSetting(w37.default.GroupRemark,w0,w1,(function(){w2&&w2();var w3=new w42.default;w3.scope=w37.default.GroupRemark,w3.key=w0,w3.value=w1,w3.updateDt=(new Date).getTime(),w4.store.settings.push(w3),w4.onSettingUpdate([w3])}),w3)}},{key:"getGroupRemark",value:function(w0){return this.getUserSetting(w37.default.GroupRemark,w0)}},{key:"getFavGroups",value:function(){return this.store.getFavGroups()}},{key:"isFavGroup",value:function(w0){return this.store.isFavGroup(w0)}},{key:"setFavGroup",value:function(w0,w1,w2,w3){this._updateUserSetting(w37.default.FavoriteGroup,w0,w1?"1":"0",w2,w3)}},{key:"getMyGroups",value:function(w0,w1){var w2=this;this._publish("GMGS",null,(function(w3,w4){w2._generalStringListCallback(w3,w4,w0,w1)}))}},{key:"getCommonGroups",value:function(w0,w1,w2){var w3=this,w4=w39.IDBuf.create();w4.id=w0,this._publish("GCGS",w39.IDBuf.encode(w4).finish(),(function(w0,w4){w3._generalStringListCallback(w0,w4,w1,w2)}))}},{key:"getFavUsers",value:function(){return this.store.getFavUsers()}},{key:"isFavUser",value:function(w0){return this.store.isFavUser(w0)}},{key:"setFavUser",value:function(w0,w1,w2,w3){this._updateUserSetting(w37.default.FavoriteUser,w0,w1?"1":"0",w2,w3)}},{key:"getUserSetting",value:function(w0,w1){return this.store.getUserSetting(w0,w1)}},{key:"getUserSettings",value:function(w0){return this.store.getUserSettings(w0)}},{key:"setUserSetting",value:function(w0,w1,w2,w3,w4){this._updateUserSetting(w0,w1,w2,w3,w4)}},{key:"modifyMyInfo",value:function(w0,w1,w2){var w3=this,w4=w39.ModifyMyInfoRequest.create();w4.entry=w0,this._publish("MMI",w39.ModifyMyInfoRequest.encode(w4).finish(),(function(w0,w4){w3._generalOperationCallback(w0,w1,w2)}))}},{key:"isGlobalSlient",value:function(){var w0=this.store.getUserSetting(w37.default.GlobalSilent,"");return!!w0&&"1"===w0.value}},{key:"setGlobalSlient",value:function(w0,w1,w2){this._updateUserSetting(w37.default.GlobalSilent,"",w0?"1":"0",(function(){w1&&w1()}),(function(w0){w2&&w2(w0)}))}},{key:"isHiddenNotificationDetail",value:function(){var w0=this.store.getUserSetting(w37.default.HiddenNotificationDetail,"");return!!w0&&"1"===w0.value}},{key:"setHiddenNotificationDetail",value:function(w0,w1,w2){this._updateUserSetting(w37.default.HiddenNotificationDetail,"",w0?"1":"0",(function(){w1&&w1()}),(function(w0){w2&&w2(w0)}))}},{key:"isHiddenGroupMemberName",value:function(w0){var w1=this.store.getUserSetting(w37.default.GroupHideNickname,w0);return!!w1&&"1"===w1.value}},{key:"setHiddenGroupMemberName",value:function(w0,w1,w2,w3){this._updateUserSetting(w37.default.GroupHideNickname,w0,w1?"1":"0",(function(){w2&&w2()}),(function(w0){w3&&w3(w0)}))}},{key:"joinChatroom",value:function(w0,w1,w2){var w3=this,w4=w39.IDBuf.create();w4.id=w0,this._publish("CRJ",w39.IDBuf.encode(w4).finish(),(function(){var w4=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2;0===w4?(w3.chatRoomMsgHead=w15.default.ZERO,w3.currentChatRoomId=w0,w1&&w1(),w3._pullMessages(w15.default.MAX_VALUE,1,!1)):w2&&w2(w4)}))}},{key:"quitChatroom",value:function(w0,w1,w2){var w3=w39.IDBuf.create();w3.id=w0,this.currentChatRoomId="",this._publish("CRQ",w39.IDBuf.encode(w3).finish(),(function(){var w0=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2;0===w0?w1&&w1():w2&&w2(w0)}))}},{key:"getChatroomInfo",value:function(w0,w1,w2,w3){var w4=this,w5=w39.GetChatroomInfoRequest.create();w5.chatroomId=w0,w5.updateDt=w15.default.fromValue(w1),this._publish("CRI",w39.GetChatroomInfoRequest.encode(w5).finish(),(function(){var w0=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2,w1=arguments[1];if(0===w0&&w1){if(w2){var w5=w39.ChatroomInfo.decode(w1);w4.log("getChatroomInfo result",w5);var w6=(0,w8.default)(new w47.default,w5);w43.default.urlRedirect&&(w6.portrait=w43.default.urlRedirect(w6.portrait)),w2(w6)}}else w3&&w3(w0)}))}},{key:"getChatroomMemberInfo",value:function(w0,w1,w2,w3){var w4=this,w5=w39.GetChatroomMemberInfoRequest.create();w5.chatroomId=w0,w5.maxCount=w1||10,this._publish("CRMI",w39.GetChatroomMemberInfoRequest.encode(w5).finish(),(function(){var w0=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2,w1=arguments[1];if(0===w0&&w1){if(w2){var w5=w39.ChatroomMemberInfo.decode(w1);w4.log("getChatroomMemberInfo result",w5);var w6=(0,w8.default)(new w27.default,w5);w2(w6)}}else w3&&w3(w0)}))}},{key:"createChannel",value:function(w0,w1,w2,w3,w4,w5,w6){var w7=w39.ChannelInfo.create();w7.name=w0,w7.portrait=w1,w7.desc=w3,w7.extra=w4,this._publish("CHC",w39.ChannelInfo.encode(w7).finish(),(function(){var w0=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2;0===w0?w5&&w5():w6&&w6(w0)}))}},{key:"getChannelInfo",value:function(w0,w1){var w2=this.store.getChannelInfo(w0);return(w2 instanceof w48.default||w1)&&this._reloadChannelInfo(w0,w2.updateDt),w2}},{key:"_reloadChannelInfo",value:function(w0){var w1=this,w2=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,w3=w39.PullChannelInfo.create();w3.channelId=w0,w3.head=w15.default.fromValue(w2),this._publish("CHP",w39.PullChannelInfo.encode(w3).finish(),(function(){var w0=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2,w2=arguments[1];if(0===w0&&w2){var w3=w39.ChannelInfo.decode(w2),w4=(0,w8.default)(new w26.default,w3);w43.default.urlRedirect&&(w4.portrait=w43.default.urlRedirect(w4.portrait)),w4.menu&&(w4.menus=w4.menu.map((function(w0){return(w0=(0,w8.default)(new w57.default,w0)).subMenu&&(w0.subMenus=w0.subMenu.map((function(w0){return(0,w8.default)(new w57.default,w0)})),delete w0.subMenu),w0})),delete w4.menu),w4.channelId=w3.targetId,delete w4.targetId,w1.store.setChannelInfo(w4),w1.eventEmitter.emit(w38.default.ChannelInfosUpdate,[w4])}}))}},{key:"modifyChannelInfo",value:function(w0,w1,w2,w3,w4){var w5=this,w6=w39.ModifyChannelInfo.create();w6.channelId=w0,w6.type=w1,w6.value=w2,this._publish("CHMI",w39.ModifyChannelInfo.encode(w6).finish(),(function(){var w1=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2;0===w1?(w5._reloadChannelInfo(w0),w3&&w3()):w4&&w4(w1)}))}},{key:"searchChannel",value:function(w0,w1,w2,w3){var w4=w39.SearchUserRequest.create();w4.keyword=w0,w4.fuzzy=w1,w4.page=0,this._publish("CHS",w39.SearchUserRequest.encode(w4).finish(),(function(){var w1=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2,w4=arguments[1];if(0===w1&&w4){if(w2){var w5=w39.SearchChannelResult.decode(w4);w2(w0,w5.entry)}}else w3&&w3(w1)}))}},{key:"isListenedChannel",value:function(w0){var w1=this.store.getUserSetting(w37.default.Listened_Channel,w0);return w1&&"1"===w1.value}},{key:"listenChannel",value:function(w0,w1,w2,w3){var w4=w39.ListenChannel.create();w4.channelId=w0,w4.listen=w1,this._publish("CHL",w39.ListenChannel.encode(w4).finish(),(function(){var w0=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2;0===w0?w2&&w2():w3&&w3(w0)}))}},{key:"getMyChannels",value:function(){return this.store.getUserSettings(w37.default.My_Channel).filter((function(w0){return"1"===w0.value})).map((function(w0){return w0.key}))}},{key:"getListenedChannels",value:function(){return this.store.getUserSettings(w37.default.Listened_Channel).filter((function(w0){return"1"===w0.value})).map((function(w0){return w0.key}))}},{key:"getRemoteListenedChannels",value:function(w0,w1){var w2=this;this._publish("CHLL","",(function(){var w3=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2,w4=arguments[1];w2._generalStringListCallback(w3,w4,w0,w1)}))}},{key:"destroyChannel",value:function(w0,w1,w2){var w3=w39.IDBuf.create();w3.id=w0,this._publish("CHD",w39.ListenChannel.encode(w3).finish(),(function(){var w0=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2;0===w0?w1&&w1():w2&&w2(w0)}))}},{key:"getConversationList",value:function(w0,w1){return this.store.getConversationList(w0,w1)}},{key:"getConversationInfo",value:function(w0){var w1=this.store.getConversationInfo(w0);return w1||((w1=new w49.default).conversation=w0),w1}},{key:"searchConversation",value:function(w0){var w1=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[0,1,2],w2=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[0,1];return this.store.searchConversation(w0,w1,w2)}},{key:"removeConversation",value:function(w0,w1){var w2=this.getConversationInfo(w0);if(w2){this.store.removeConversation(w0,w1);var w3=(new Date).getTime();(!w2.timestamp||(0,w16.gt)(w2.timestamp,w3+72e5)||(0,w16.lte)(w2.timestamp,w3-12e4))&&(w2.timestamp=w15.default.fromValue(w3)),this._syncConversationReadDt(w0,w2.timestamp.neg())}}},{key:"setConversationTop",value:function(w0,w1,w2,w3){var w4=this,w5=w37.default.ConversationTop,w6=w0.type+"-"+w0.line+"-"+w0.target,w7=(w1>0?w1:0)+"";this._updateUserSetting(w5,w6,w7,(function(){var w3=w4.getConversationInfo(w0);w4.eventEmitter.emit(w38.default.ConversationInfoUpdate,w3),w4.store.setConversationTop(w0,w1),w2&&w2()}),(function(w0){w3&&w3(w0)}))}},{key:"setConversationSlient",value:function(w0,w1,w2,w3){var w4=this,w5=w37.default.ConversationSilent,w6=w0.type+"-"+w0.line+"-"+w0.target,w7=w1?"1":"0";this._updateUserSetting(w5,w6,w7,(function(){w4.store.setConversationSilent(w0,w1),w2&&w2();var w3=w4.getConversationInfo(w0);w4.eventEmitter.emit(w38.default.ConversationInfoUpdate,w3)}),(function(w0){w3&&w3(w0)}))}},{key:"setConversationDraft",value:function(w0){var w1=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",w2=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(w0){w1=w1||"";var w3=this.getConversationInfo(w0);w3.draft!==w1&&(this.store.setConversationDraft(w0,w1),this.eventEmitter.emit(w38.default.ConversationInfoUpdate,w3),!w2||this.isGlobalDisableDraftSync||this.isDisableSyncDraft()||this._syncDraft(w0,w1))}}},{key:"_syncDraft",value:function(w0,w1){var w2=w0.type+"-"+w0.line+"-"+w0.target,w3=this.getUserSetting(w37.default.DisableSyncDraft,w2);if(!(!!w3&&"1"===w3.value)){var w4=this.clientId+"@@@"+w1;this._updateUserSetting(w37.default.ConversationDraft,w2,w4)}}},{key:"setConversationTimestamp",value:function(w0,w1){var w2=this.store.getConversationInfo(w0);w2||(w2=this.store.genAndSaveDefaultConversationInfo(w0));var w3=(new Date).getTime();(0,w16.gt)(w1,w3+72e5)&&(w1=w3),w2.timestamp=w15.default.fromValue(w1),this.eventEmitter.emit(w38.default.ConversationInfoUpdate,w2)}},{key:"getUnreadCount",value:function(){var w0=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],w1=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[0];return this.store.getUnreadCount(w0,w1)}},{key:"getConversationUnreadCount",value:function(w0){return this.store.getConversationUnreadCount(w0)}},{key:"sendConferenceRequest",value:function(w0,w1,w2,w3,w4,w5){var w6=w39.ConferenceRequest.create();w6.sessionId=w0,w6.roomId=w1,w6.request=w2,w6.advance=w4?1:0,w6.data=w3,this._publish("CONF",w39.ConferenceRequest.encode(w6).finish(),(function(){var w0=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2,w1=arguments[1];if(0===w0){var w2=null;if(w1){var w3=w39.IDBuf.decode(w1);w2=w3.id}w5&&w5(0,w2)}else w5&&w5(w0)}))}},{key:"clearConversationUnreadStatus",value:function(w0){var w1=[];if(this.isReceiptEnable&&this.isUserReceiptEnabled()&&(w1=this.store.getUnreadMsgSenders(w0)),this.store.clearConversationUnreadStatus(w0)>0){var w2=this.getConversationInfo(w0);this.eventEmitter.emit(w38.default.ConversationInfoUpdate,w2);var w3=this.store.getConversationReadMaxDt(w0);w3.compare(w15.default.ZERO)>0&&this._syncConversationReadDt(w0,w3,w1)}}},{key:"clearMessageUnreadStatus",value:function(w0){if(this.store.clearMessageUnreadStatus(w0)){var w1=this.getConversationInfo(this.getMessageById(w0).conversation);this.eventEmitter.emit(w38.default.ConversationInfoUpdate,w1)}}},{key:"_syncConversationReadDt",value:function(w0,w1,w2,w3){var w4=this;if(w15.default.isLong(w1)){var w5=w0.type+"-"+w0.line+"-"+w0.target,w6=w39.ModifyUserSettingReq.create();w6.scope=w37.default.Conversation_Sync,w6.key=w5,w6.value=w1.toString(),w6.target=w2;var w7=w39.ModifyUserSettingReq.encode(w6).finish();w3||(w3=this.store.saveSyncReadEntry(w0.type,w0.target,w0.line,w1,w2)),this._publish("UP",w7,(function(w0,w2){if(0===w0){var w6=new w42.default;w6.scope=w37.default.Conversation_Sync,w6.key=w5,w6.value=w1.toString(),w6.updateDt=(new Date).getTime(),w4.store.updateUserSettings([w6]),w4.store.deleteSyncReadEntry(w3),w4._syncRead()}else w4.log("syncConversationReadDt error",w0)}))}else this.log("_syncConversationReadDt invalid dt",w1)}},{key:"_syncRead",value:function(){var w0=this.store.loadSyncReadEntry();if(w0){var w1=new w28.default(w0.type,w0.target,w0.line);this._syncConversationReadDt(w1,w0.readDt,w0.senders,w0.id)}}},{key:"clearAllUnreadStatus",value:function(){this.store.clearAllUnreadStatus()}},{key:"setMediaMessagePlayed",value:function(w0){if(this.store.setMediaMessagePlayed(w0)>0){var w1=this.store.getMessageById(w0);this.eventEmitter.emit(w38.default.MessageStatusUpdate,w1)}}},{key:"isMyFriend",value:function(w0){return this.store.isMyFriend(w0)}},{key:"sendFriendRequest",value:function(w0,w1,w2,w3,w4){var w5=w39.AddFriendRequest.create();w5.targetUid=w0,w5.reason=w1,w5.extra=w2,this._publish("FAR",w39.AddFriendRequest.encode(w5).finish(),(function(w0,w1){0===w0?w3&&w3():w4&&w4(w0)}))}},{key:"getMessages",value:function(w0,w1){var w2=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],w3=arguments.length>3&&void 0!==arguments[3]?arguments[3]:20,w4=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"";return this.store.getConversationMessages(w0,w1,w2,w3,w4)}},{key:"getMessagesV2",value:function(w0,w1){var w2=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],w3=arguments.length>3&&void 0!==arguments[3]?arguments[3]:20,w4=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"",w5=arguments[5],w6=arguments[6],w7=this.store.getConversationMessages(w0,w1,w2,w3,w4);this._callbackOrLoadFromRemoteMessages(w7,w5,w6)}},{key:"getMessagesEx",value:function(w0,w1,w2,w3,w4,w5,w6){return this.store.getMessagesEx(w0,w1,w2,w6)}},{key:"getMessagesExV2",value:function(w0,w1,w2,w3,w4,w5,w6,w7,w8){var w9=this.store.getMessagesEx(w0,w1,w2,w6);this._callbackOrLoadFromRemoteMessages(w9,w7,w8)}},{key:"getMessagesEx2",value:function(w0,w1,w2,w3,w4,w5,w6){return this.store.getMessagesEx2(w0,w1,w2,w6)}},{key:"getMessagesEx2V2",value:function(w0,w1,w2,w3,w4,w5,w6,w7,w8){var w9=this.store.getMessagesEx2(w0,w1,w2,w6);this._callbackOrLoadFromRemoteMessages(w9,w7,w8)}},{key:"getUserMessages",value:function(w0,w1,w2){var w3=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],w4=arguments.length>4&&void 0!==arguments[4]?arguments[4]:20,w5=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"",w6=this.store.getConversationMessages(w1,w2,w3,w4,w5);return w6.filter((function(w1){return w1.from===w0}))}},{key:"getUserMessagesV2",value:function(w0,w1,w2){var w3=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],w4=arguments.length>4&&void 0!==arguments[4]?arguments[4]:20,w5=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"",w6=arguments[6],w7=arguments[7],w8=this.store.getConversationMessages(w1,w2,w3,w4,w5);w8=w8.filter((function(w1){return w1.from===w0})),this._callbackOrLoadFromRemoteMessages(w8,w6,w7)}},{key:"getUserMessagesEx",value:function(w0,w1,w2,w3){var w4=arguments.length>6&&void 0!==arguments[6]?arguments[6]:[],w5=this.store.getMessagesEx(w1,w2,w4,"");return w5.filter((function(w1){return w1.from===w0}))}},{key:"getUserMessagesExV2",value:function(w0,w1,w2,w3){var w4=arguments.length>6&&void 0!==arguments[6]?arguments[6]:[],w5=arguments[7],w6=arguments[8],w7=this.store.getMessagesEx(w1,w2,w4,"");w7=w7.filter((function(w1){return w1.from===w0})),this._callbackOrLoadFromRemoteMessages(w7,w5,w6)}},{key:"getFirstUnreadMessageUid",value:function(w0){return this.store.getFirstUnreadMessage(w0)}},{key:"_convertAndSaveProtoMessage",value:function(w0,w1){var w2=w21.default.fromProtoMessage(w0);if(w2){var w3=w19.default.getMessageContentPersitFlag(w2.content.type);if(w1){if(81===w2.type){var w4=this.store.getMessageByUid(w15.default.fromValue(w2.content.binaryContent));w4&&w4.messageId>0&&(this.store.deleteMessageByUid(w15.default.from(w2.content.binaryContent)),this.onRemoteMessageDeleted(w4.messageUid))}80===w2.type&&this.onRecallMessage(w2.content.operatorId,w2.content.messageUid),w3===w25.default.Persist||w3===w25.default.Persist_And_Count?(w2.conversation.type===w29.default.ChatRoom?w2.messageId=this.store.genChatRoomMessageId():w2.messageId=this.store.genNormalMessageId(),this.store.saveMessage(w2)):w2.messageId=0}else-1===w3&&1==(1&w0.content.persistFlag)&&(w3=1),w2.messageId=1==(1&w3)&&w3>0?-1:0}return w2}},{key:"_loadRemoteMessagePublishCallback",value:function(){var w0=arguments.length>0&&void 0!==arguments[0]?arguments[0]:2,w2=arguments[1],w3=arguments[2],w4=arguments[3],w5=arguments[4],w6=arguments[5],w7=arguments[6],w8=arguments[7],w9=this,w10=arguments[8],w11=arguments.length>9&&void 0!==arguments[9]?arguments[9]:0;if(this.log("loadRemoteMessages result",w0,w3,w4),0===w0&&w2){var w12=w39.PullMessageResult.decode(w2);this.log("loadRemoteMessages result data",w12);var w13=[];if(w12&&w12.message){if(w12.message.forEach((function(w0){if(!(w1.pcNotSupportMessageTypes.indexOf(w0.content.type)>-1)){var w2=w9.store.getMessageByUid(w0.messageId),w4=w9._convertAndSaveProtoMessage(w0,w3);w4&&(w4.messageContent.type===w22.default.VOIP_CONTENT_TYPE_ACCEPT&&w8&&w4.messageContent.type===w22.default.VOIP_CONTENT_TYPE_END&&w10||w2&&w7||w13.push(w2||w4),[w22.default.VOIP_CONTENT_TYPE_START,w22.default.VOIP_CONTENT_TYPE_ACCEPT,w22.default.VOIP_CONTENT_TYPE_END].indexOf(w4.messageContent.type)>=0&&w9.updateCallStartMessage(w4))}})),w4&&w13.length>0)for(var w14=0;w140?w12.message.length>w11:w12.message.length>0)}else w6&&w6(-1)}else w6&&w6(w0)}},{key:"loadRemoteLineMessages",value:function(w0,w1){var w2=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,w3=arguments.length>3&&void 0!==arguments[3]?arguments[3]:20,w4=this,w5=arguments[4],w6=arguments[5],w7=w15.default.fromValue(w2);w7.eq(w15.default.ZERO)&&(w7=w15.default.MAX_VALUE);var w8=w39.LoadLineMessages.create();w8.line=w0,w8.count=w3,w8.beforeUid=w7,w1||(w1=[]);var w9=!0,w10=!0;w1.indexOf(w22.default.VOIP_CONTENT_TYPE_START)&&(w1.indexOf(w22.default.VOIP_CONTENT_TYPE_END)?w9=!1:w1.push(w22.default.VOIP_CONTENT_TYPE_END),w1.indexOf(w22.default.VOIP_CONTENT_TYPE_ACCEPT)?w10=!1:w1.push(w22.default.VOIP_CONTENT_TYPE_ACCEPT)),w8.contentType=w1,this._publish("LLM",w39.LoadLineMessages.encode(w8).finish(),(function(){var w0=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2,w1=arguments[1];w4._loadRemoteMessagePublishCallback(w0,w1,!1,!1,w5,w6,!1,w9,w10,w3)}))}},{key:"loadRemoteMessages",value:function(w0,w1){var w2=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,w3=arguments.length>3&&void 0!==arguments[3]?arguments[3]:20,w4=arguments[4],w5=this,w6=arguments[5],w7=!(arguments.length>6&&void 0!==arguments[6])||arguments[6],w8=w15.default.fromValue(w2);w8.eq(w15.default.ZERO)&&(w8=w15.default.MAX_VALUE);var w9=this.store.getConversationInfo(w0);if(w9&&w9.lastMessage&&w9.lastMessage.messageUid&&w8.neq(w15.default.MAX_VALUE)&&w15.default.fromValue(w9.lastMessage.messageUid).compare(w8)<0)return this.log("the start message is exits",w9.lastMessage.toString(),w8.toString()),void(w6&&w6(-2));var w10=w39.LoadRemoteMessages.create();w10.conversation=this._toProtoConversation(w0),w1||(w1=[]);var w11=!0,w12=!0;w1.indexOf(w22.default.VOIP_CONTENT_TYPE_START)&&(w1.indexOf(w22.default.VOIP_CONTENT_TYPE_END)?w11=!1:w1.push(w22.default.VOIP_CONTENT_TYPE_END),w1.indexOf(w22.default.VOIP_CONTENT_TYPE_ACCEPT)?w12=!1:w1.push(w22.default.VOIP_CONTENT_TYPE_ACCEPT)),w10.contentType=w1,w10.beforeUid=w8,w10.count=w3,this.log("loadRemoteMessages request",w0,w8.toString(),w10),this._publish("LRM",w39.LoadRemoteMessages.encode(w10).finish(),(function(){var w0=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2,w2=arguments[1];w5._loadRemoteMessagePublishCallback(w0,w2,0===w1.length,0===w1.length,w4,w6,w7,w11,w12,w3)}))}},{key:"loadRemoteMessage",value:function(w0,w1,w2){var w3=this;if(w0){var w4=w39.INT64Buf.create();w4.id=w15.default.fromValue(w0),this._publish("LROM",w39.INT64Buf.encode(w4).finish(),(function(){var w0=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2,w4=arguments[1];w3._loadRemoteMessagePublishCallback(w0,w4,!1,!1,w1,w2)}))}else w2&&w2(-1)}},{key:"getMessageById",value:function(w0){return this.store.getMessageById(w0)}},{key:"getMessageByUid",value:function(w0){return this.store.getMessageByUid(w0)}},{key:"searchMessage",value:function(w0,w1,w2){return this.store.searchConversationMessage(w0,w1,w2)}},{key:"sendConversationMessage",value:function(w0,w1,w2,w3,w4,w5,w6){var w7=new w21.default;w0 instanceof w28.default?w7.conversation=w0:w7.conversation=new w28.default(w0.type,w0.target,w0.line),w7.messageContent=w1,this.sendMessageEx(w7,w2,w3,w4,w5,w6)}},{key:"sendSavedMessage",value:function(w0,w1,w2,w3){var w4=w0.messageId;if(!(w0=this.store.getMessageById(w4)))return this.error("saved message not found",w4),void(w3&&w3(-1));this._sendMessageInternal(w0,[],w2,w3)}},{key:"sendMessage",value:function(w0,w1,w2,w3,w4){this.sendMessageEx(w0,[],w1,w2,w3,w4)}},{key:"sendMessageEx",value:function(w0){var w1=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],w2=arguments[2],w3=arguments[3],w4=this,w5=arguments[4],w6=arguments[5],w7=void 0,w8=w15.default.fromValue((new Date).getTime()+this.getServerDeltaTime());w0.status=w23.default.Sending,w0.from=this.userId,w0.timestamp=w8,w0.content=w0.messageContent.encode();var w9=w19.default.getMessageContentPersitFlag(w0.messageContent.type);if(w9===w25.default.No_Persist||w9===w25.default.Transparent?(w7=0,w0.messageId=w7):(w7=w0.conversation.type===w29.default.ChatRoom?this.store.genChatRoomMessageId():this.store.genNormalMessageId(),w0.messageId=w7,this.store.saveMessage(w0),this.log("message prepared",w7,w8,w0),this.store.updateConversationLastMessage(w0)),this.eventEmitter.emit(w38.default.SendMessage,w0),w2&&(this.log("onPrepared",this.getMessageById(w7)),w2(w7,w8)),w0.messageContent instanceof w20.default)if(!w0.messageContent.file&&!w0.messageContent.localPath||w0.messageContent.remotePath)""!==w0.messageContent.remotePath||w0.messageContent instanceof w58.default?this._sendMessageInternal(w0,w1,w5,w6):(this.log("send media message error, file,localPath and remoteUrl are null"),w0.status=w23.default.SendFailure,this.store.updateMessageById(w0),this.store.updateConversationLastMessage(w0),this.eventEmitter.emit(w38.default.MessageStatusUpdate,w0),w6&&w6(-1));else if(this.log("send media message",w0),this.isSupportBigFilesUpload()){var w10=w0.messageContent.file?w0.messageContent.file:w0.messageContent.localPath,w11=void 0;w11="string"==typeof w10||w10 instanceof String?this._dataURItoBlob(w10):w10,this.log("support big file",w10,w11.name),this._uploadFile(w0,w11,w11.name,w0.messageContent.mediaType,(function(w0,w1){w3&&w3(w0,w1)}),(function(w1){w0.messageContent.remotePath=w1,w4.updateMessageContent(w0.messageId,w0.messageContent),w4._sendMessageInternal(w0,[],w5,w6)}),(function(w1){w0.status=w23.default.SendFailure,w4.store.updateMessageById(w0),w4.store.updateConversationLastMessage(w0),w4.eventEmitter.emit(w38.default.MessageStatusUpdate,w0),w6&&w6(w1)}))}else{var w12=w0.messageContent.file?w0.messageContent.file:w0.messageContent.localPath;this.log("not support big file",w12,w0),this._uploadMedia(w0.messageId,w0.messageContent.name,w12,w0.messageContent.mediaType,(function(w2){w0.messageContent.remotePath=w2,w4.log("remote Url",w2),w4._sendMessageInternal(w0,w1,w5,w6)}),(function(w1){w0.status=w23.default.SendFailure,w4.store.updateMessageById(w0),w4.store.updateConversationLastMessage(w0),w4.eventEmitter.emit(w38.default.MessageStatusUpdate,w0),w6&&w6(w1)}),(function(w0,w1){w3&&w3(w0,w1)}))}else this._sendMessageInternal(w0,w1,w5,w6)}},{key:"_sendMessageInternal",value:function(w0){var w1=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],w2=this,w3=arguments[2],w4=arguments[3],w5=this._toProtoMessage(w0);w5.to=w1,this.log("_sendMessageInternal",this.connectionStatus);var w6=w39.Message.encode(w5).finish();if(w6.byteLength>15360&&this.log("警告!!!消息内容大小是: "+w6.byteLength+",大小超过15K了,建议不要超过15K,如果大消息过多会影响接受体验,建议大文件使用媒体消息类型!!!"),w6.byteLength>102400)return this.error("消息内容太大,发送失败!"),void(w4&&w4(-1));this._publish("MS",w6,(function(){var w1=arguments.length>0&&void 0!==arguments[0]?arguments[0]:-2,w5=arguments[1];if(w2.log("_sendMessageInternal result",w1),0!==w1||!w5)return w2.log("send message error",w1),w0.status=w23.default.SendFailure,w2.store.updateMessageById(w0),w2.store.updateConversationLastMessage(w0),w2.eventEmitter.emit(w38.default.MessageStatusUpdate,w0),void(w4&&w4(w1));var w6=new w15.default(0),w7=new w15.default(0);16===w5.length?(w6=w15.default.fromBytesBE(w5.slice(0,8),!0),w7=w15.default.fromBytesBE(w5.slice(8,16),!0),w0.messageUid=w6,w0.timestamp=w7,w0.status=w23.default.Sent,w0.direction=0,w0.from=w2.userId,w2.store.updateMessageById(w0),w2.store.updateConversationLastMessage(w0),w2.eventEmitter.emit(w38.default.MessageStatusUpdate,w0),w3&&w3(w6,w7)):(w0.status=w23.default.SendFailure,w2.store.updateMessageById(w0),w2.store.updateConversationLastMessage(w0),w2.log("ms reponse length error"),w2.eventEmitter.emit(w38.default.MessageStatusUpdate,w0),w4&&w4(-100001))}))}},{key:"cancelSendingMessage",value:function(w0){if(w0<=0)return!1;var w1=this.uploadingMap.get(w0);if(w1){try{w1.abort()}catch(w0){this.log(w0)}return!0}return!1}},{key:"recallMessage",value:function(w0,w1,w2){var w3=this,w4=w39.INT64Buf.create();w4.id=w15.default.fromValue(w0),this._publish("MR",w39.INT64Buf.encode(w4).finish(),(function(w4,w5){0===w4?(w1&&w1(),w3.onRecallMessage(w3.getUserId(),w0)):w2&&w2(w4)}))}},{key:"deleteMessageById",value:function(w0){var w1=this.store.deleteMessageById(w0);return w1&&this.onMessageDeleted(w0),w1}},{key:"deleteRemoteMessage",value:function(w0,w1,w2){var w3=this,w4=w39.INT64Buf.create();w4.id=w15.default.fromValue(w0),this._publish("MD",w39.INT64Buf.encode(w4).finish(),(function(w4,w5){0===w4?(w1&&w1(),w3.onRemoteMessageDeleted(w0)):w2&&w2(w4)}))}},{key:"clearMessages",value:function(w0,w1){void 0===w1&&(w1=w15.default.MAX_VALUE),this.store.clearConversationMessages(w0,w1);var w2=this.getConversationInfo(w0);this.eventEmitter.emit(w38.default.ConversationInfoUpdate,w2)}},{key:"clearRemoteConversationMessages",value:function(w0,w1,w2){var w3=this,w4=this._toProtoConversation(w0);this._publish("CMD",w39.Conversation.encode(w4).finish(),(function(w4,w5){0===w4?(w3.clearMessages(w0),w1&&w1()):w2&&w2(0===w4?-1:w4)}))}},{key:"insertMessage",value:function(w0,w1){var w2=arguments.length>2&&void 0!==arguments[2]?arguments[2]:w23.default.Sent,w3=arguments.length>3&&void 0!==arguments[3]&&arguments[3],w4=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,w5=new w21.default(w0,w1);if(w5.status=w2,w5.direction=0,w2>=w23.default.Mentioned?(w5.direction=1,w0.type===w29.default.Single?w5.from=w0.target:w5.from=this.userId):w5.from=this.userId,w5.timestamp=w15.default.fromValue(w4||(new Date).getTime()),w0.type===w29.default.ChatRoom)w5.messageId=this.store.genChatRoomMessageId();else w5.messageId=this.store.genNormalMessageId();return this.store.insertConversationMessages([w5]),w3&&this.eventEmitter.emit(w38.default.ReceiveMessage,w5),w5}},{key:"isUserReceiptEnabled",value:function(){return"1"!==this.getUserSetting(w37.default.DisableReceipt,"")}},{key:"isGlobalDisableSyncDraft",value:function(){return this.isGlobalDisableDraftSync}},{key:"setDisableSyncDraft",value:function(w0,w1,w2){this._updateUserSetting(w37.default.DisableSyncDraft,"",w0?"1":"0",w1,w2)}},{key:"isDisableSyncDraft",value:function(){return"1"!==this.getUserSetting(w37.default.DisableSyncDraft,"")}},{key:"setUserEnableReceipt",value:function(w0,w1,w2){this._updateUserSetting(w37.default.DisableReceipt,"",w0?"0":"1",w1,w2)}},{key:"updateMessageStatus",value:function(w0,w1){var w2=this.store.getMessageById(w0);0!==w2.messageId&&(w2.status=w1,this.store.updateMessageById(w2))}},{key:"updateMessageContent",value:function(w0,w1){var w2=this.store.getMessageById(w0);0!==w2.messageId&&(w2.messageContent=w1,this.store.updateMessageById(w2))}},{key:"updateMessageContentByUid",value:function(w0,w1){var w2=this.store.getMessageByUid(w0);w2&&0!==w2.messageId&&(w2.messageContent=w1,this.store.updateMessageById(w2))}},{key:"updateRemoteMessageContent",value:function(w0,w1,w2,w3,w4,w5){var w6=this,w7=w39.UpdateMessageContent.create();w7.messageId=w15.default.fromValue(w0),w7.content=this._toProtoMessageContent(w1),w7.distribute=w2,this._publish("MCU",w39.UpdateMessageContent.encode(w7).finish(),(function(w2,w7){0===w2?(w3&&w6.updateMessageContentByUid(w0,w1),w4&&w4()):w5&&w5(w2)}))}},{key:"_uploadXMLHttpRequest",value:function(w0,w1,w2,w3,w4,w5){var w6=this,w7=new XMLHttpRequest;return w7.upload.onprogress=function(w0){var w1=w0.loaded,w2=w0.total;w3(w1,w2)},w7.onreadystatechange=function(w3){w6.log("onr",w7.readyState,w7.status,w3),4===w7.readyState&&(200===w7.status?(w6.log("upload file success",w1,w2),w4(w2)):(w6.log("upload file error",w7.status),w5&&w5(-1)),w0&&w0.messageId>0&&w6.uploadingMap.delete(w0.messageId))},w7.onerror=function(w1){w6.log("upload file error",w1),w5&&w5(-1),w0&&w0.messageId>0&&w6.uploadingMap.delete(w0.messageId)},w0&&w0.messageId>0&&this.uploadingMap.set(w0.messageId,w7),w7}},{key:"_uploadFile",value:function(w0,w1,w2,w3,w4,w5,w6){var w7=this,w8=void 0,w9=(Math.random().toString(36).substring(2,15)+Math.random().toString(36).substring(2,15)).substring(0,12);if(w2&&""!==w2?(w8=w2,w2=w9):w8=w2=w9,-1!==w8.indexOf(".")){var w10=w8.substring(w8.lastIndexOf("."));w2+=w10}if(-1===w2.indexOf("."))switch(w3){case 1:case 5:w2+=".jpg";break;case 2:w2+=".mp3";break;case 3:w2+=".mp4"}this.log("upload fileName",w8,w2,w3);var w11=this._getContentType(w3,w8);this.getUploadMediaUrl(w2,w3,w11,(function(w3,w9,w10,w12){var w13=void 0;if(0===w12);else if(1===w12){var w14=w3.split("?"),w15=w14[0],w16=w14[1],w17=w14[2];w13=w7._uploadXMLHttpRequest(w0,w2,w9,w4,w5,w6);var w18=new FormData;w18.append("key",w17),w18.append("token",w16),w18.append("file",w1),w13.open("POST",w15),w13.setRequestHeader("Content-Type",w11),w13.setRequestHeader("content-disposition",'attachment; filename="'+encodeURI(w8)+'"'),w13.send(w18)}else(w13=w7._uploadXMLHttpRequest(w0,w2,w9,w4,w5,w6)).open("PUT",w3),w13.setRequestHeader("Content-Type",w11),w13.setRequestHeader("content-disposition",'attachment; filename="'+encodeURI(w8)+'"'),w13.send(w1)}),(function(w0){w7.log("getUploadMediaUrl e",w0)}))}},{key:"uploadMedia",value:function(w0,w1,w2,w3,w4,w5){if(this.isSupportBigFilesUpload()){var w6=void 0;w6="string"==typeof w1||w1 instanceof String?this._dataURItoBlob(w1):w1,this._uploadFile(null,w6,w0,w2,w5,w3,w4)}else this._uploadMedia(0,w0,w1,w2,w3,w4,w5)}},{key:"_uploadMedia",value:function(w0,w1,w2,w3,w4,w5,w6){var w7=this,w8=void 0,w9=(Math.random().toString(36).substring(2,15)+Math.random().toString(36).substring(2,15)).substring(0,12);if(w1&&""!==w1?(w8=encodeURIComponent(w1),w1=w9):w8=w1=w9,-1===w1.indexOf("."))switch(w3){case 1:case 5:w1+=".jpg";break;case 2:w1+=".mp3";break;case 3:w1+=".mp4"}this.log("upload fileName",w1,w3);var w10=w1.substring(w1.lastIndexOf("."));-1===w8.indexOf(".")&&(w8+=w10);var w11=(0,w52.btoa)(this.userId)+"-"+w3+"-"+Math.round((new Date).valueOf()/1e3)+"-"+w1,w12=w39.GetUploadTokenRequest.create();w12.mediaType=w3,w12.mediaPath=w11,this._publish("GMUT",w39.GetUploadTokenRequest.encode(w12).finish(),(function(w9,w10){if(0===w9){var w12=w39.GetUploadTokenResult.decode(w10);w7.log("getUploadToken result",w12);var w13=new XMLHttpRequest,w14=!1,w15=setTimeout((function(){w7.log("upload media timeout"),w14=!0,w13.abort(),w5(-1)}),2e5);w13.onerror=function(w1){w7.log("upload media error",w1),w5&&w5(-1),w7.uploadingMap.delete(w0)},w13.onreadystatechange=function(){if(4===w13.readyState&&(w7.uploadingMap.delete(w0),!w14))if(clearTimeout(w15),200===w13.status)if(w7.log("upload response",w13.responseText),w12.type<2){var w1=JSON.parse(w13.responseText);w4&&w4(w12.domain+"/"+w1.key)}else w4&&w4(w12.domain+"/"+w11);else w7.log("upload media error status:"+w13.status),w5&&w5(w13.status)},w13.onprogress=function(w0){w0.lengthComputable&&w6&&w6(w0.loaded,w0.total)},w0>0&&w7.uploadingMap.set(w0,w13);var w16=void 0;if(0===w12.type||4===w12.type)w16="/fs";else if(3===w12.type){var w18=w12.path+"/"+w11;w18=(0,w17.AESEncrypt)(w18),w16="/fs/"+w18}else 2===w12.type&&(w11=encodeURI(w11)),w16="/"+w11;w7.log("upload media cgi",w16,w12);var w19=void 0,w20=void 0,w21=void 0;2===w7.backupAddressStrategy&&w12.backupServer?(w19=w12.backupServer,w21=443===(w21=w12.backupSslPort)?"":":"+w21,w20=80===(w20=w12.backupPort)?"":":"+w20):(w19=w12.server,w21="",w12.sslPort&&443!==w12.sslPort&&(w21=":"+w12.sslPort),w20=80!==w12.port?":"+w12.port:"");var w22=w7._getContentType(w3,w8);if(w12.type<2||4===w12.type){var w23=new FormData,w24=void 0;w24="string"==typeof w2||w2 instanceof String?w7._dataURItoBlob(w2):new Blob([w2],{type:w22}),w23.append("token",w12.token),w23.append("key",w1),w12.type<2?(w23.append("file",w24,w8),w43.default.USE_WSS?w13.open("POST","https://"+w19+w21+w16):w13.open("POST","http://"+w19+w20+w16),0!==w12.type&&(w13.setRequestHeader("Content-Type",w22),w13.setRequestHeader("content-disposition",'attachment; filename="'+w8+'"')),w13.send(w23)):new Response(w24).arrayBuffer().then((function(w0){var w1=new Uint8Array(w0),w2=w7._encrypt(w1,!1),w3=new Blob([new Uint8Array(w2,w2.byteOffset,w2.byteLength)]);w23.append("file",w3,w8),w43.default.USE_WSS?w13.open("POST","https://"+w19+w21+w16):w13.open("POST","http://"+w19+w20+w16),w13.setRequestHeader("x-wfc-size",w2.byteLength),0!==w12.type&&(w13.setRequestHeader("Content-Type",w22),w13.setRequestHeader("content-disposition",'attachment; filename="'+w8+'"')),w13.send(w23)}))}else if(w12.type>=2){var w25=void 0;w43.default.USE_WSS?(w13.open("PUT","https://"+w19+w21+w16),w25=1===w7.backupAddressStrategy?w12.sslToken?w12.sslToken:w12.token:w12.backupSslToken?w12.backupSslToken:w12.backupToken):(w13.open("PUT","http://"+w19+w20+w16),w25=1===w7.backupAddressStrategy?w12.token:w12.backupToken),w13.setRequestHeader("Content-Type",w22),w13.setRequestHeader("content-disposition",'attachment; filename="'+w8+'"'),w13.setRequestHeader("Authorization",w25),2===w12.type?w13.setRequestHeader("x-oss-date",w12.date):(w13.setRequestHeader("x-amz-date",w12.date),w13.setRequestHeader("x-wfc-cid",(0,w17.AESEncrypt)(w7.clientId)),w13.setRequestHeader("x-wfc-uid",(0,w17.AESEncrypt)(w7.userId)));var w26=void 0;if(w26="string"==typeof w2||w2 instanceof String?w7._dataURItoBlob(w2):new Blob([w2],{type:w22}),3===w12.type){if(w26.size>104857600)return void(w5&&(w7.log("upload media size too large",w26.size),w5(-1)));new Response(w26).arrayBuffer().then((function(w0){var w1=new Uint8Array(w0),w2=w7._encrypt(w1);w13.setRequestHeader("x-wfc-size",w0.byteLength),w13.send(w2)}))}else new Response(w26).arrayBuffer().then((function(w0){w13.send(w0)}))}}else w5&&w5(w9)})),this.log("upload-----------")}},{key:"getAuthorizedMediaUrl",value:function(w0,w1,w2,w3,w4){var w5=w39.GetUploadTokenRequest.create();w5.mediaType=w1,w5.mediaPath=w2,w5.messageId=w0,this._publish("GMDT",w39.GetUploadTokenRequest.encode(w5).finish(),(function(w0,w1){if(0===w0&&w1){var w2=w39.IDBuf.decode(w1);w3&&w3(w2.id)}else w4&&w4(0===w0?-1:w0)}))}},{key:"isSupportBigFilesUpload",value:function(){return this.serverConfigs.isSupportBigFileUpload}},{key:"getUploadMediaUrl",value:function(w0,w1,w2,w3,w4){var w5=w39.GetUploadTokenRequest.create(),w6=this.userId+"-"+w1+"-"+Math.round((new Date).valueOf()/1e3)+"-"+Math.round(1e8*Math.random()),w7=w0.lastIndexOf(".");w0=encodeURIComponent(w0),w7>0&&(w6+=w0.substring(w7)),w5.type=w1,w5.mediaPath=w6,w5.contentType=w2||"application/octet-stream",this._publish("GMPU",w39.GetUploadTokenRequest.encode(w5).finish(),(function(w0,w1){if(0===w0&&w1){var w2=w39.GetPresignedUrlResult.decode(w1);w3&&w3(w2.presignedUrl,w2.mediaUrl,w2.backupPresignedUrl,w2.type)}else w4&&w4(0===w0?-1:w0)}))}},{key:"_getContentType",value:function(w0,w1){var w2="application/octet-stream";if(w1){var w3=w1.substring(w1.lastIndexOf(".")+1);"jpg"===w3||"jpeg"===w3?w2="image/jpeg":"gif"===w3?w2="image/gif":"png"===w3?w2="image/png":"mp3"===w3?w2="audio/mpeg":"mp4"===w3?w2="video/mp4":"doc"===w3?w2="application/vnd.ms-word":"docx"===w3?w2="application/vnd.openxmlformats-officedocument.wordprocessingml.document":"xls"===w3?w2="application/vnd.ms-xls":"xlsx"===w3?w2="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":"ppt"===w3?w2="application/vnd.ms-powerpoint":"pptx"===w3?w2="application/vnd.openxmlformats-officedocument.presentationml.presentation":"pps"===w3?w2="application/vnd.ms-powerpoint":"pdf"===w3?w2="application/pdf":"xml"===w3&&(w2="application/vnd.ms-xml")}else 1===w0?w2="image/jpeg":2===w0?w2="audio/amr":3===w0&&(w2="video/mp4");return w2}},{key:"_getFileRecordsCallback",value:function(w0,w1,w2,w3){if(0===w0&&w1){var w4=w39.LoadFileRecordRes.decode(w1),w5=[];w4.record.forEach((function(w0){var w1=new w51.default;w1.conversation=new w28.default(w0.conversation.type,w0.conversation.target,w0.conversation.line),w1.messageUid=w0.messageId,w1.name=w0.name,w1.url=w0.url,w43.default.urlRedirect&&(w1.url=w43.default.urlRedirect(w0.url)),w1.size=w0.size,w1.downloadCount=w0.downloadCount,w1.userId=w0.fromUser,w1.timestamp=w0.dt,w5.push(w1)})),w2&&w2(w5)}else w3&&w3(0===w0?-1:w0)}},{key:"getConversationFileRecords",value:function(w0,w1,w2,w3,w4,w5,w6){var w7=this,w8=w39.LoadFileRecordReq.create();w8.conversation=this._toProtoConversation(w0),w8.messageId=w15.default.fromValue(w2),w8.from=w1,w8.order=w3,w8.count=w4,this._publish("LFR",w39.LoadFileRecordReq.encode(w8).finish(),(function(w0,w1){w7._getFileRecordsCallback(w0,w1,w5,w6)}))}},{key:"getMyFileRecords",value:function(w0,w1,w2,w3,w4){var w5=this,w6=w39.LoadFileRecordReq.create();w6.messageId=w15.default.fromValue(w0),w6.order=w1,w6.count=w2,this._publish("LFR",w39.LoadFileRecordReq.encode(w6).finish(),(function(w0,w1){w5._getFileRecordsCallback(w0,w1,w3,w4)}))}},{key:"searchFiles",value:function(w0,w1,w2,w3,w4,w5,w6,w7){var w8=this,w9=w39.SearchFileRecordReq.create();w9.keyword=w0,w9.conversation=this._toProtoConversation(w1),w9.from=w2,w9.messageId=w15.default.fromValue(w3),w9.order=w4,w9.count=w5,this._publish("SFR",w39.SearchFileRecordReq.encode(w9).finish(),(function(w0,w1){w8._getFileRecordsCallback(w0,w1,w6,w7)}))}},{key:"searchMyFiles",value:function(w0,w1,w2,w3,w4,w5){var w6=this,w7=w39.SearchFileRecordReq.create();w7.keyword=w0,w7.messageId=w15.default.fromValue(w1),w7.order=w2,w7.count=w3,this._publish("SFR",w39.SearchFileRecordReq.encode(w7).finish(),(function(w0,w1){w6._getFileRecordsCallback(w0,w1,w4,w5)}))}},{key:"deleteFileRecord",value:function(w0,w1,w2){var w3=w39.INT64Buf.create();w3.id=w15.default.fromValue(w0),this._publish("DFR",w39.INT64Buf.encode(w3).finish(),(function(w0,w3){0===w0?w1&&w1():w2&&w2(w0)}))}},{key:"markConversationAsUnread",value:function(w0,w1){var w2=this.store.setLastReceivedMessageUnread(w0,"0","0");if(w2&&(0,w16.gt)(w2,0)&&w1){var w3=new w53.default(w2),w4=this.store.getMessageByUid(w2);return w3.timestamp=w4.timestamp,this.sendConversationMessage(w0,w3),!0}return!1}},{key:"getVersion",value:function(){return w1.version}},{key:"isUserOnlineStateEnabled",value:function(){return this.isUserOnlineStateEnable}},{key:"watchOnlineState",value:function(w0,w1,w2,w3,w4){this._watchOnlineState(w0,w1,w2,!0,w3,w4)}},{key:"_watchOnlineState",value:function(w0,w1,w2,w3,w4,w5){if(!this.isUserOnlineStateEnable)return this.error("not enable onlineState function"),void(w5&&w5(248));var w6=w39.PresenceWatchRequest.create();w6.type=w0,w6.target=w1,w6.duration=w2,this._publish("PWT",w39.PresenceWatchRequest.encode(w6).finish(),(function(w0,w1){if(0===w0&&w1){if(!w3)return void(w4&&w4());var w2=w39.PresenceWatchResult.decode(w1),w6=[];w2.notify.forEach((function(w0){var w1=new w54.default;w1.userId=w0.userId,w1.customState=new w56.default,w1.customState.state=w0.customState,w1.customState.text=w0.customText;var w2=[];w0.state.forEach((function(w0){var w1=new w55.default;w1.platform=w0.platform,w1.state=w0.state,w1.lastSeen=w0.lastSeen,w2.push(w1)})),w1.clientStates=w2,w6.push(w1)})),w4&&w4(w6)}else w5&&w5(0===w0?-1:w0)}))}},{key:"unwatchOnlineState",value:function(w0,w1,w2,w3){this._watchOnlineState(w0,w1,0,!1,w2,w3)}},{key:"setMyCustomState",value:function(w0,w1,w2,w3){var w4=w0+"-"+w1;this.setUserSetting(w37.default.CustomState,"",w4,w2,w3)}},{key:"requireLock",value:function(w0,w1,w2,w3){var w4=w39.LockRequest.create();w4.lockId=w0,w4.duration=w15.default.fromValue(w1),this._publish("SLT",w39.LockRequest.encode(w4).finish(),(function(w0,w1){0===w0?w2&&w2():w3&&w3(w0)}))}},{key:"releaseLock",value:function(w0,w1,w2){this.requireLock(w0,0,w1,w2)}},{key:"_onlineStateNotify",value:function(w0){var w1=w39.PresenceWatchResult.decode(w0),w2=[];w1.notify.forEach((function(w0){var w1=new w54.default;w1.userId=w0.userId,w1.customState=new w56.default,w1.customState.state=w0.customState,w1.customState.text=w0.customText;var w3=[];w0.state.forEach((function(w0){var w1=new w55.default;w1.platform=w0.platform,w1.state=w0.state,w1.lastSeen=w0.lastSeen,w3.push(w1)})),w1.clientStates=w3,w2.push(w1)})),this.eventEmitter.emit(w38.default.UserOnlineEvent,w2)}},{key:"_dataURItoBlob",value:function(w0){for(var w1=w0.split(","),w2=w1[0].match(/:(.*?);/)[1],w3=atob(w1[1]),w4=w3.length,w5=new Uint8Array(w4);w4--;)w5[w4]=w3.charCodeAt(w4);return this.log("-----------dataurltoblob",w2),new Blob([w5],{type:w2})}},{key:"_encrypt",value:function(w1){var w2=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(!w1)return w1;var w3=new w0((0,w17.AESEncrypt)(w1,this.privateSecret,w2),"base64");return w3}},{key:"_decrypt",value:function(w1){var w2=(0,w17.AESDecrypt)(w1.toString("base64"),this.privateSecret,!0);return new w0(w2)}},{key:"_decryptPublishResponse",value:function(w1){var w2=(0,w17.AESDecrypt)(w1.payload.slice(1,w1.payload.length).toString("base64"),this.privateSecret,!0);return w2?new w0(w2):null}},{key:"_toProtoConversation",value:function(w0){if(!w0)return null;var w1=w39.Conversation.create();return w1.type=w0.type,w1.target=w0.target,w1.line=w0.line,w1}},{key:"_toProtoMessage",value:function(w0){var w1=w39.Message.create();return w1.conversation=w0.conversation,w1.fromUser=this.getUserId(),w1.content=this._toProtoMessageContent(w0.messageContent),w1}},{key:"_toProtoMessageContent",value:function(w0){if(!w0)return null;var w1=w39.MessageContent.create(),w2=w0.encode();return w1.content=w2.content,w1.pushContent=w2.pushContent,w1.pushData=w2.pushData,w1.searchableContent=w2.searchableContent,w1.data=w2.binaryContent,w1.type=w2.type,w1.mentionedType=w2.mentionedType,w1.mentionedTarget=w2.mentionedTargets,w1.mediaType=w2.mediaType,w1.remoteMediaUrl=w2.remoteMediaUrl,w1.persistFlag=w19.default.getMessageContentPersitFlag(w2.type),w1.extra=w0.extra,w1}},{key:"_generalOperationCallback",value:function(w0,w1,w2){0===w0?w1&&w1():w2&&w2(w0)}},{key:"_generalStringListCallback",value:function(w0,w1,w2,w3){if(0===w0){var w4=w39.IDListBuf.decode(w1);w2&&w2(w4.id)}else w3&&w3(w0)}},{key:"_getStore",value:function(){return this.store}},{key:"log",value:function(w0){if(!w43.default.DISABLE_LOG){for(var w1,w2=arguments.length,w3=Array(w2>1?w2-1:0),w4=1;w41?w2-1:0),w4=1;w41?w2-1:0),w4=1;w4>1,w10=-7,w11=w2?w4-1:0,w12=w2?-1:1,w13=w0[w1+w11];for(w11+=w12,w5=w13&(1<<-w10)-1,w13>>=-w10,w10+=w7;w10>0;w5=256*w5+w0[w1+w11],w11+=w12,w10-=8);for(w6=w5&(1<<-w10)-1,w5>>=-w10,w10+=w3;w10>0;w6=256*w6+w0[w1+w11],w11+=w12,w10-=8);if(0===w5)w5=1-w9;else{if(w5===w8)return w6?NaN:1/0*(w13?-1:1);w6+=Math.pow(2,w3),w5-=w9}return(w13?-1:1)*w6*Math.pow(2,w5-w3)},w1.write=function(w0,w1,w2,w3,w4,w5){var w6,w7,w8,w9=8*w5-w4-1,w10=(1<>1,w12=23===w4?Math.pow(2,-24)-Math.pow(2,-77):0,w13=w3?0:w5-1,w14=w3?1:-1,w15=w1<0||0===w1&&1/w1<0?1:0;for(w1=Math.abs(w1),isNaN(w1)||w1===1/0?(w7=isNaN(w1)?1:0,w6=w10):(w6=Math.floor(Math.log(w1)/Math.LN2),w1*(w8=Math.pow(2,-w6))<1&&(w6--,w8*=2),(w1+=w6+w11>=1?w12/w8:w12*Math.pow(2,1-w11))*w8>=2&&(w6++,w8/=2),w6+w11>=w10?(w7=0,w6=w10):w6+w11>=1?(w7=(w1*w8-1)*Math.pow(2,w4),w6+=w11):(w7=w1*Math.pow(2,w11-1)*Math.pow(2,w4),w6=0));w4>=8;w0[w2+w13]=255&w7,w13+=w14,w7/=256,w4-=8);for(w6=w6<0;w0[w2+w13]=255&w6,w13+=w14,w6/=256,w9-=8);w0[w2+w13-w14]|=128*w15}},function(w0,w1,w2){w2(26),w2(189),w0.exports=w2(1).Array.from},function(w0,w1,w2){var w3=w2(63),w4=w2(64);w0.exports=function(w0){return function(w1,w2){var w5,w6,w7=String(w4(w1)),w8=w3(w2),w9=w7.length;return w8<0||w8>=w9?w0?"":void 0:(w5=w7.charCodeAt(w8))<55296||w5>56319||w8+1===w9||(w6=w7.charCodeAt(w8+1))<56320||w6>57343?w0?w7.charAt(w8):w5:w0?w7.slice(w8,w8+2):w6-56320+(w5-55296<<10)+65536}}},function(w0,w1,w2){"use strict";var w3=w2(49),w4=w2(38),w5=w2(42),w6={};w2(18)(w6,w2(5)("iterator"),(function(){return this})),w0.exports=function(w0,w1,w2){w0.prototype=w3(w6,{next:w4(1,w2)}),w5(w0,w1+" Iterator")}},function(w0,w1,w2){var w3=w2(27),w4=w2(50),w5=w2(187);w0.exports=function(w0){return function(w1,w2,w6){var w7,w8=w3(w1),w9=w4(w8.length),w10=w5(w6,w9);if(w0&&w2!=w2){for(;w9>w10;)if((w7=w8[w10++])!=w7)return!0}else for(;w9>w10;w10++)if((w0||w10 in w8)&&w8[w10]===w2)return w0||w10||0;return!w0&&-1}}},function(w0,w1,w2){var w3=w2(63),w4=Math.max,w5=Math.min;w0.exports=function(w0,w1){return(w0=w3(w0))<0?w4(w0+w1,0):w5(w0,w1)}},function(w0,w1,w2){var w3=w2(22),w4=w2(28),w5=w2(69)("IE_PROTO"),w6=Object.prototype;w0.exports=Object.getPrototypeOf||function(w0){return w0=w4(w0),w3(w0,w5)?w0[w5]:"function"==typeof w0.constructor&&w0 instanceof w0.constructor?w0.constructor.prototype:w0 instanceof Object?w6:null}},function(w0,w1,w2){"use strict";var w3=w2(17),w4=w2(2),w5=w2(28),w6=w2(104),w7=w2(105),w8=w2(50),w9=w2(190),w10=w2(72);w4(w4.S+w4.F*!w2(106)((function(w0){Array.from(w0)})),"Array",{from:function(w0){var w1,w2,w4,w11,w12=w5(w0),w13="function"==typeof this?this:Array,w14=arguments.length,w15=w14>1?arguments[1]:void 0,w16=void 0!==w15,w17=0,w18=w10(w12);if(w16&&(w15=w3(w15,w14>2?arguments[2]:void 0,2)),null==w18||w13==Array&&w7(w18))for(w2=new w13(w1=w8(w12.length));w1>w17;w17++)w9(w2,w17,w16?w15(w12[w17],w17):w12[w17]);else for(w11=w18.call(w12),w2=new w13;!(w4=w11.next()).done;w17++)w9(w2,w17,w16?w6(w11,w15,[w4.value,w17],!0):w4.value);return w2.length=w17,w2}})},function(w0,w1,w2){"use strict";var w3=w2(9),w4=w2(38);w0.exports=function(w0,w1,w2){w1 in w0?w3.f(w0,w1,w4(0,w2)):w0[w1]=w2}},function(w0,w1,w2){w2(52),w2(26),w2(43),w2(194),w2(198),w2(200),w2(201),w0.exports=w2(1).Set},function(w0,w1,w2){"use strict";var w3=w2(193),w4=w2(108),w5=w2(39),w6=w2(27);w0.exports=w2(65)(Array,"Array",(function(w0,w1){this._t=w6(w0),this._i=0,this._k=w1}),(function(){var w0=this._t,w1=this._k,w2=this._i++;return!w0||w2>=w0.length?(this._t=void 0,w4(1)):w4(0,"keys"==w1?w2:"values"==w1?w0[w2]:[w2,w0[w2]])}),"values"),w5.Arguments=w5.Array,w3("keys"),w3("values"),w3("entries")},function(w0,w1){w0.exports=function(){}},function(w0,w1,w2){"use strict";var w3=w2(109),w4=w2(76);w0.exports=w2(111)("Set",(function(w0){return function(){return w0(this,arguments.length>0?arguments[0]:void 0)}}),{add:function(w0){return w3.def(w4(this,"Set"),w0=0===w0?0:w0,w0)}},w3)},function(w0,w1,w2){var w3=w2(17),w4=w2(68),w5=w2(28),w6=w2(50),w7=w2(196);w0.exports=function(w0,w1){var w2=1==w0,w8=2==w0,w9=3==w0,w10=4==w0,w11=6==w0,w12=5==w0||w11,w13=w1||w7;return function(w1,w7,w14){for(var w15,w16,w17=w5(w1),w18=w4(w17),w19=w3(w7,w14,3),w20=w6(w18.length),w21=0,w22=w2?w13(w1,w20):w8?w13(w1,0):void 0;w20>w21;w21++)if((w12||w21 in w18)&&(w16=w19(w15=w18[w21],w21,w17),w0))if(w2)w22[w21]=w16;else if(w16)switch(w0){case 3:return!0;case 5:return w15;case 6:return w21;case 2:w22.push(w15)}else if(w10)return!1;return w11?-1:w9||w10?w10:w22}}},function(w0,w1,w2){var w3=w2(197);w0.exports=function(w0,w1){return new(w3(w0))(w1)}},function(w0,w1,w2){var w3=w2(7),w4=w2(112),w5=w2(5)("species");w0.exports=function(w0){var w1;return w4(w0)&&("function"!=typeof(w1=w0.constructor)||w1!==Array&&!w4(w1.prototype)||(w1=void 0),w3(w1)&&null===(w1=w1[w5])&&(w1=void 0)),void 0===w1?Array:w1}},function(w0,w1,w2){var w3=w2(2);w3(w3.P+w3.R,"Set",{toJSON:w2(113)("Set")})},function(w0,w1,w2){var w3=w2(44);w0.exports=function(w0,w1){var w2=[];return w3(w0,!1,w2.push,w2,w1),w2}},function(w0,w1,w2){w2(114)("Set")},function(w0,w1,w2){w2(115)("Set")},function(w0,w1,w2){w2(52),w2(26),w2(43),w2(203),w2(207),w2(208),w0.exports=w2(1).Promise},function(w0,w1,w2){"use strict";var w3,w4,w5,w6,w7=w2(36),w8=w2(4),w9=w2(17),w10=w2(73),w11=w2(2),w12=w2(7),w13=w2(37),w14=w2(75),w15=w2(44),w16=w2(116),w17=w2(117).set,w18=w2(205)(),w19=w2(78),w20=w2(118),w21=w2(206),w22=w2(119),w23="Promise",w24=w8.TypeError,w25=w8.process,w26=w25&&w25.versions,w27=w26&&w26.v8||"",w28=w8.Promise,w29="process"==w10(w25),w30=function(){},w31=w4=w19.f,w32=!!function(){try{var w0=w28.resolve(1),w1=(w0.constructor={})[w2(5)("species")]=function(w0){w0(w30,w30)};return(w29||"function"==typeof PromiseRejectionEvent)&&w0.then(w30)instanceof w1&&0!==w27.indexOf("6.6")&&-1===w21.indexOf("Chrome/66")}catch(w0){}}(),w33=function(w0){var w1;return!(!w12(w0)||"function"!=typeof(w1=w0.then))&&w1},w34=function(w0,w1){if(!w0._n){w0._n=!0;var w2=w0._c;w18((function(){for(var w3=w0._v,w4=1==w0._s,w5=0,w6=function(w1){var w2,w5,w6,w7=w4?w1.ok:w1.fail,w8=w1.resolve,w9=w1.reject,w10=w1.domain;try{w7?(w4||(2==w0._h&&w37(w0),w0._h=1),!0===w7?w2=w3:(w10&&w10.enter(),w2=w7(w3),w10&&(w10.exit(),w6=!0)),w2===w1.promise?w9(w24("Promise-chain cycle")):(w5=w33(w2))?w5.call(w2,w8,w9):w8(w2)):w9(w3)}catch(w0){w10&&!w6&&w10.exit(),w9(w0)}};w2.length>w5;)w6(w2[w5++]);w0._c=[],w0._n=!1,w1&&!w0._h&&w35(w0)}))}},w35=function(w0){w17.call(w8,(function(){var w1,w2,w3,w4=w0._v,w5=w36(w0);if(w5&&(w1=w20((function(){w29?w25.emit("unhandledRejection",w4,w0):(w2=w8.onunhandledrejection)?w2({promise:w0,reason:w4}):(w3=w8.console)&&w3.error&&w3.error("Unhandled promise rejection",w4)})),w0._h=w29||w36(w0)?2:1),w0._a=void 0,w5&&w1.e)throw w1.v}))},w36=function(w0){return 1!==w0._h&&0===(w0._a||w0._c).length},w37=function(w0){w17.call(w8,(function(){var w1;w29?w25.emit("rejectionHandled",w0):(w1=w8.onrejectionhandled)&&w1({promise:w0,reason:w0._v})}))},w38=function(w0){var w1=this;w1._d||(w1._d=!0,(w1=w1._w||w1)._v=w0,w1._s=2,w1._a||(w1._a=w1._c.slice()),w34(w1,!0))},w39=function(w0){var w1,w2=this;if(!w2._d){w2._d=!0,w2=w2._w||w2;try{if(w2===w0)throw w24("Promise can't be resolved itself");(w1=w33(w0))?w18((function(){var w3={_w:w2,_d:!1};try{w1.call(w0,w9(w39,w3,1),w9(w38,w3,1))}catch(w0){w38.call(w3,w0)}})):(w2._v=w0,w2._s=1,w34(w2,!1))}catch(w0){w38.call({_w:w2,_d:!1},w0)}}};w32||(w28=function(w0){w14(this,w28,w23,"_h"),w13(w0),w3.call(this);try{w0(w9(w39,this,1),w9(w38,this,1))}catch(w0){w38.call(this,w0)}},(w3=function(w0){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1}).prototype=w2(74)(w28.prototype,{then:function(w0,w1){var w2=w31(w16(this,w28));return w2.ok="function"!=typeof w0||w0,w2.fail="function"==typeof w1&&w1,w2.domain=w29?w25.domain:void 0,this._c.push(w2),this._a&&this._a.push(w2),this._s&&w34(this,!1),w2.promise},catch:function(w0){return this.then(void 0,w0)}}),w5=function(){var w0=new w3;this.promise=w0,this.resolve=w9(w39,w0,1),this.reject=w9(w38,w0,1)},w19.f=w31=function(w0){return w0===w28||w0===w6?new w5(w0):w4(w0)}),w11(w11.G+w11.W+w11.F*!w32,{Promise:w28}),w2(42)(w28,w23),w2(110)(w23),w6=w2(1).Promise,w11(w11.S+w11.F*!w32,w23,{reject:function(w0){var w1=w31(this);return(0,w1.reject)(w0),w1.promise}}),w11(w11.S+w11.F*(w7||!w32),w23,{resolve:function(w0){return w22(w7&&this===w6?w28:this,w0)}}),w11(w11.S+w11.F*!(w32&&w2(106)((function(w0){w28.all(w0).catch(w30)}))),w23,{all:function(w0){var w1=this,w2=w31(w1),w3=w2.resolve,w4=w2.reject,w5=w20((function(){var w2=[],w5=0,w6=1;w15(w0,!1,(function(w0){var w7=w5++,w8=!1;w2.push(void 0),w6++,w1.resolve(w0).then((function(w0){w8||(w8=!0,w2[w7]=w0,--w6||w3(w2))}),w4)})),--w6||w3(w2)}));return w5.e&&w4(w5.v),w2.promise},race:function(w0){var w1=this,w2=w31(w1),w3=w2.reject,w4=w20((function(){w15(w0,!1,(function(w0){w1.resolve(w0).then(w2.resolve,w3)}))}));return w4.e&&w3(w4.v),w2.promise}})},function(w0,w1){w0.exports=function(w0,w1,w2){var w3=void 0===w2;switch(w1.length){case 0:return w3?w0():w0.call(w2);case 1:return w3?w0(w1[0]):w0.call(w2,w1[0]);case 2:return w3?w0(w1[0],w1[1]):w0.call(w2,w1[0],w1[1]);case 3:return w3?w0(w1[0],w1[1],w1[2]):w0.call(w2,w1[0],w1[1],w1[2]);case 4:return w3?w0(w1[0],w1[1],w1[2],w1[3]):w0.call(w2,w1[0],w1[1],w1[2],w1[3])}return w0.apply(w2,w1)}},function(w0,w1,w2){var w3=w2(4),w4=w2(117).set,w5=w3.MutationObserver||w3.WebKitMutationObserver,w6=w3.process,w7=w3.Promise,w8="process"==w2(41)(w6);w0.exports=function(){var w0,w1,w2,w9=function(){var w3,w4;for(w8&&(w3=w6.domain)&&w3.exit();w0;){w4=w0.fn,w0=w0.next;try{w4()}catch(w3){throw w0?w2():w1=void 0,w3}}w1=void 0,w3&&w3.enter()};if(w8)w2=function(){w6.nextTick(w9)};else if(!w5||w3.navigator&&w3.navigator.standalone)if(w7&&w7.resolve){var w10=w7.resolve(void 0);w2=function(){w10.then(w9)}}else w2=function(){w4.call(w3,w9)};else{var w11=!0,w12=document.createTextNode("");new w5(w9).observe(w12,{characterData:!0}),w2=function(){w12.data=w11=!w11}}return function(w3){var w4={fn:w3,next:void 0};w1&&(w1.next=w4),w0||(w0=w4,w2()),w1=w4}}},function(w0,w1,w2){var w3=w2(4).navigator;w0.exports=w3&&w3.userAgent||""},function(w0,w1,w2){"use strict";var w3=w2(2),w4=w2(1),w5=w2(4),w6=w2(116),w7=w2(119);w3(w3.P+w3.R,"Promise",{finally:function(w0){var w1=w6(this,w4.Promise||w5.Promise),w2="function"==typeof w0;return this.then(w2?function(w2){return w7(w1,w0()).then((function(){return w2}))}:w0,w2?function(w2){return w7(w1,w0()).then((function(){throw w2}))}:w0)}})},function(w0,w1,w2){"use strict";var w3=w2(2),w4=w2(78),w5=w2(118);w3(w3.S,"Promise",{try:function(w0){var w1=w4.f(this),w2=w5(w0);return(w2.e?w1.reject:w1.resolve)(w2.v),w1.promise}})},function(w0,w1,w2){w0.exports=w2(210)},function(w0,w1,w2){var w3=function(){return this}()||Function("return this")(),w4=w3.regeneratorRuntime&&Object.getOwnPropertyNames(w3).indexOf("regeneratorRuntime")>=0,w5=w4&&w3.regeneratorRuntime;if(w3.regeneratorRuntime=void 0,w0.exports=w2(211),w4)w3.regeneratorRuntime=w5;else try{delete w3.regeneratorRuntime}catch(w0){w3.regeneratorRuntime=void 0}},function(w0,w1){!function(w1){"use strict";var w2,w3=Object.prototype,w4=w3.hasOwnProperty,w5="function"==typeof Symbol?Symbol:{},w6=w5.iterator||"@@iterator",w7=w5.asyncIterator||"@@asyncIterator",w8=w5.toStringTag||"@@toStringTag",w9="object"==typeof w0,w10=w1.regeneratorRuntime;if(w10)w9&&(w0.exports=w10);else{(w10=w1.regeneratorRuntime=w9?w0.exports:{}).wrap=w20;var w11="suspendedStart",w12="suspendedYield",w13="executing",w14="completed",w15={},w16={};w16[w6]=function(){return this};var w17=Object.getPrototypeOf,w18=w17&&w17(w17(w31([])));w18&&w18!==w3&&w4.call(w18,w6)&&(w16=w18);var w19=w24.prototype=w22.prototype=Object.create(w16);w23.prototype=w19.constructor=w24,w24.constructor=w23,w24[w8]=w23.displayName="GeneratorFunction",w10.isGeneratorFunction=function(w0){var w1="function"==typeof w0&&w0.constructor;return!!w1&&(w1===w23||"GeneratorFunction"===(w1.displayName||w1.name))},w10.mark=function(w0){return Object.setPrototypeOf?Object.setPrototypeOf(w0,w24):(w0.__proto__=w24,w8 in w0||(w0[w8]="GeneratorFunction")),w0.prototype=Object.create(w19),w0},w10.awrap=function(w0){return{__await:w0}},w25(w26.prototype),w26.prototype[w7]=function(){return this},w10.AsyncIterator=w26,w10.async=function(w0,w1,w2,w3){var w4=new w26(w20(w0,w1,w2,w3));return w10.isGeneratorFunction(w1)?w4:w4.next().then((function(w0){return w0.done?w0.value:w4.next()}))},w25(w19),w19[w8]="Generator",w19[w6]=function(){return this},w19.toString=function(){return"[object Generator]"},w10.keys=function(w0){var w1=[];for(var w2 in w0)w1.push(w2);return w1.reverse(),function w2(){for(;w1.length;){var w3=w1.pop();if(w3 in w0)return w2.value=w3,w2.done=!1,w2}return w2.done=!0,w2}},w10.values=w31,w30.prototype={constructor:w30,reset:function(w0){if(this.prev=0,this.next=0,this.sent=this._sent=w2,this.done=!1,this.delegate=null,this.method="next",this.arg=w2,this.tryEntries.forEach(w29),!w0)for(var w1 in this)"t"===w1.charAt(0)&&w4.call(this,w1)&&!isNaN(+w1.slice(1))&&(this[w1]=w2)},stop:function(){this.done=!0;var w0=this.tryEntries[0].completion;if("throw"===w0.type)throw w0.arg;return this.rval},dispatchException:function(w0){if(this.done)throw w0;var w1=this;function w3(w3,w4){return w7.type="throw",w7.arg=w0,w1.next=w3,w4&&(w1.method="next",w1.arg=w2),!!w4}for(var w5=this.tryEntries.length-1;w5>=0;--w5){var w6=this.tryEntries[w5],w7=w6.completion;if("root"===w6.tryLoc)return w3("end");if(w6.tryLoc<=this.prev){var w8=w4.call(w6,"catchLoc"),w9=w4.call(w6,"finallyLoc");if(w8&&w9){if(this.prev=0;--w2){var w3=this.tryEntries[w2];if(w3.tryLoc<=this.prev&&w4.call(w3,"finallyLoc")&&this.prev=0;--w1){var w2=this.tryEntries[w1];if(w2.finallyLoc===w0)return this.complete(w2.completion,w2.afterLoc),w29(w2),w15}},catch:function(w0){for(var w1=this.tryEntries.length-1;w1>=0;--w1){var w2=this.tryEntries[w1];if(w2.tryLoc===w0){var w3=w2.completion;if("throw"===w3.type){var w4=w3.arg;w29(w2)}return w4}}throw new Error("illegal catch attempt")},delegateYield:function(w0,w1,w3){return this.delegate={iterator:w31(w0),resultName:w1,nextLoc:w3},"next"===this.method&&(this.arg=w2),w15}}}function w20(w0,w1,w2,w3){var w4=w1&&w1.prototype instanceof w22?w1:w22,w5=Object.create(w4.prototype),w6=new w30(w3||[]);return w5._invoke=function(w0,w1,w2){var w3=w11;return function(w4,w5){if(w3===w13)throw new Error("Generator is already running");if(w3===w14){if("throw"===w4)throw w5;return w32()}for(w2.method=w4,w2.arg=w5;;){var w6=w2.delegate;if(w6){var w7=w27(w6,w2);if(w7){if(w7===w15)continue;return w7}}if("next"===w2.method)w2.sent=w2._sent=w2.arg;else if("throw"===w2.method){if(w3===w11)throw w3=w14,w2.arg;w2.dispatchException(w2.arg)}else"return"===w2.method&&w2.abrupt("return",w2.arg);w3=w13;var w8=w21(w0,w1,w2);if("normal"===w8.type){if(w3=w2.done?w14:w12,w8.arg===w15)continue;return{value:w8.arg,done:w2.done}}"throw"===w8.type&&(w3=w14,w2.method="throw",w2.arg=w8.arg)}}}(w0,w2,w6),w5}function w21(w0,w1,w2){try{return{type:"normal",arg:w0.call(w1,w2)}}catch(w0){return{type:"throw",arg:w0}}}function w22(){}function w23(){}function w24(){}function w25(w0){["next","throw","return"].forEach((function(w1){w0[w1]=function(w0){return this._invoke(w1,w0)}}))}function w26(w0){function w1(w2,w3,w5,w6){var w7=w21(w0[w2],w0,w3);if("throw"!==w7.type){var w8=w7.arg,w9=w8.value;return w9&&"object"==typeof w9&&w4.call(w9,"__await")?Promise.resolve(w9.__await).then((function(w0){w1("next",w0,w5,w6)}),(function(w0){w1("throw",w0,w5,w6)})):Promise.resolve(w9).then((function(w0){w8.value=w0,w5(w8)}),w6)}w6(w7.arg)}var w2;this._invoke=function(w0,w3){function w4(){return new Promise((function(w2,w4){w1(w0,w3,w2,w4)}))}return w2=w2?w2.then(w4,w4):w4()}}function w27(w0,w1){var w3=w0.iterator[w1.method];if(w3===w2){if(w1.delegate=null,"throw"===w1.method){if(w0.iterator.return&&(w1.method="return",w1.arg=w2,w27(w0,w1),"throw"===w1.method))return w15;w1.method="throw",w1.arg=new TypeError("The iterator does not provide a 'throw' method")}return w15}var w4=w21(w3,w0.iterator,w1.arg);if("throw"===w4.type)return w1.method="throw",w1.arg=w4.arg,w1.delegate=null,w15;var w5=w4.arg;return w5?w5.done?(w1[w0.resultName]=w5.value,w1.next=w0.nextLoc,"return"!==w1.method&&(w1.method="next",w1.arg=w2),w1.delegate=null,w15):w5:(w1.method="throw",w1.arg=new TypeError("iterator result is not an object"),w1.delegate=null,w15)}function w28(w0){var w1={tryLoc:w0[0]};1 in w0&&(w1.catchLoc=w0[1]),2 in w0&&(w1.finallyLoc=w0[2],w1.afterLoc=w0[3]),this.tryEntries.push(w1)}function w29(w0){var w1=w0.completion||{};w1.type="normal",delete w1.arg,w0.completion=w1}function w30(w0){this.tryEntries=[{tryLoc:"root"}],w0.forEach(w28,this),this.reset(!0)}function w31(w0){if(w0){var w1=w0[w6];if(w1)return w1.call(w0);if("function"==typeof w0.next)return w0;if(!isNaN(w0.length)){var w3=-1,w5=function w1(){for(;++w3w10;)for(var w13,w14=w8(arguments[w10++]),w15=w11?w4(w14).concat(w11(w14)):w4(w14),w16=w15.length,w17=0;w16>w17;)w13=w15[w17++],w3&&!w12.call(w14,w13)||(w2[w13]=w14[w13]);return w2}:w9},function(w0,w1,w2){var w3=w2(1),w4=w3.JSON||(w3.JSON={stringify:JSON.stringify});w0.exports=function(w0){return w4.stringify.apply(w4,arguments)}},function(w0,w1,w2){w2(43),w2(26),w0.exports=w2(218)},function(w0,w1,w2){var w3=w2(13),w4=w2(72);w0.exports=w2(1).getIterator=function(w0){var w1=w4(w0);if("function"!=typeof w1)throw TypeError(w0+" is not iterable!");return w3(w1.call(w0))}},function(w0,w1,w2){w2(52),w2(26),w2(43),w2(220),w2(221),w2(222),w2(223),w0.exports=w2(1).Map},function(w0,w1,w2){"use strict";var w3=w2(109),w4=w2(76),w5="Map";w0.exports=w2(111)(w5,(function(w0){return function(){return w0(this,arguments.length>0?arguments[0]:void 0)}}),{get:function(w0){var w1=w3.getEntry(w4(this,w5),w0);return w1&&w1.v},set:function(w0,w1){return w3.def(w4(this,w5),0===w0?0:w0,w1)}},w3,!0)},function(w0,w1,w2){var w3=w2(2);w3(w3.P+w3.R,"Map",{toJSON:w2(113)("Map")})},function(w0,w1,w2){w2(114)("Map")},function(w0,w1,w2){w2(115)("Map")},function(w0,w1,w2){w2(225);var w3=w2(1).Object;w0.exports=function(w0,w1,w2){return w3.defineProperty(w0,w1,w2)}},function(w0,w1,w2){var w3=w2(2);w3(w3.S+w3.F*!w2(8),"Object",{defineProperty:w2(9).f})},function(w0,w1,w2){var w3;w0.exports=(w3=w2(0),w2(56),w2(227),w2(228),w2(30),w2(31),w2(83),w2(126),w2(229),w2(127),w2(230),w2(231),w2(232),w2(84),w2(233),w2(23),w2(3),w2(234),w2(235),w2(236),w2(237),w2(238),w2(239),w2(240),w2(241),w2(242),w2(243),w2(244),w2(245),w2(246),w2(247),w2(248),w2(249),w3)},function(w0,w1,w2){var w3;w0.exports=(w3=w2(0),function(){if("function"==typeof ArrayBuffer){var w0=w3.lib.WordArray,w1=w0.init,w2=w0.init=function(w0){if(w0 instanceof ArrayBuffer&&(w0=new Uint8Array(w0)),(w0 instanceof Int8Array||"undefined"!=typeof Uint8ClampedArray&&w0 instanceof Uint8ClampedArray||w0 instanceof Int16Array||w0 instanceof Uint16Array||w0 instanceof Int32Array||w0 instanceof Uint32Array||w0 instanceof Float32Array||w0 instanceof Float64Array)&&(w0=new Uint8Array(w0.buffer,w0.byteOffset,w0.byteLength)),w0 instanceof Uint8Array){for(var w2=w0.byteLength,w3=[],w4=0;w4>>2]|=w0[w4]<<24-w4%4*8;w1.call(this,w3,w2)}else w1.apply(this,arguments)};w2.prototype=w0}}(),w3.lib.WordArray)},function(w0,w1,w2){var w3;w0.exports=(w3=w2(0),function(){var w0=w3,w1=w0.lib.WordArray,w2=w0.enc;function w4(w0){return w0<<8&4278255360|w0>>>8&16711935}w2.Utf16=w2.Utf16BE={stringify:function(w0){for(var w1=w0.words,w2=w0.sigBytes,w3=[],w4=0;w4>>2]>>>16-w4%4*8&65535;w3.push(String.fromCharCode(w5))}return w3.join("")},parse:function(w0){for(var w2=w0.length,w3=[],w4=0;w4>>1]|=w0.charCodeAt(w4)<<16-w4%2*16;return w1.create(w3,2*w2)}},w2.Utf16LE={stringify:function(w0){for(var w1=w0.words,w2=w0.sigBytes,w3=[],w5=0;w5>>2]>>>16-w5%4*8&65535);w3.push(String.fromCharCode(w6))}return w3.join("")},parse:function(w0){for(var w2=w0.length,w3=[],w5=0;w5>>1]|=w4(w0.charCodeAt(w5)<<16-w5%2*16);return w1.create(w3,2*w2)}}}(),w3.enc.Utf16)},function(w0,w1,w2){var w3,w4,w5,w6,w7,w8;w0.exports=(w8=w2(0),w2(126),w4=(w3=w8).lib.WordArray,w5=w3.algo,w6=w5.SHA256,w7=w5.SHA224=w6.extend({_doReset:function(){this._hash=new w4.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var w0=w6._doFinalize.call(this);return w0.sigBytes-=4,w0}}),w3.SHA224=w6._createHelper(w7),w3.HmacSHA224=w6._createHmacHelper(w7),w8.SHA224)},function(w0,w1,w2){var w3,w4,w5,w6,w7,w8,w9,w10;w0.exports=(w10=w2(0),w2(56),w2(127),w4=(w3=w10).x64,w5=w4.Word,w6=w4.WordArray,w7=w3.algo,w8=w7.SHA512,w9=w7.SHA384=w8.extend({_doReset:function(){this._hash=new w6.init([new w5.init(3418070365,3238371032),new w5.init(1654270250,914150663),new w5.init(2438529370,812702999),new w5.init(355462360,4144912697),new w5.init(1731405415,4290775857),new w5.init(2394180231,1750603025),new w5.init(3675008525,1694076839),new w5.init(1203062813,3204075428)])},_doFinalize:function(){var w0=w8._doFinalize.call(this);return w0.sigBytes-=16,w0}}),w3.SHA384=w8._createHelper(w9),w3.HmacSHA384=w8._createHmacHelper(w9),w10.SHA384)},function(w0,w1,w2){var w3;w0.exports=(w3=w2(0),w2(56),function(w0){var w1=w3,w2=w1.lib,w4=w2.WordArray,w5=w2.Hasher,w6=w1.x64.Word,w7=w1.algo,w8=[],w9=[],w10=[];!function(){for(var w0=1,w1=0,w2=0;w2<24;w2++){w8[w0+5*w1]=(w2+1)*(w2+2)/2%64;var w3=(2*w0+3*w1)%5;w0=w1%5,w1=w3}for(w0=0;w0<5;w0++)for(w1=0;w1<5;w1++)w9[w0+5*w1]=w1+(2*w0+3*w1)%5*5;for(var w4=1,w5=0;w5<24;w5++){for(var w7=0,w11=0,w12=0;w12<7;w12++){if(1&w4){var w13=(1<>>24)|4278255360&(w5<<24|w5>>>8),w6=16711935&(w6<<8|w6>>>24)|4278255360&(w6<<24|w6>>>8),(w28=w2[w4]).high^=w6,w28.low^=w5}for(var w7=0;w7<24;w7++){for(var w12=0;w12<5;w12++){for(var w13=0,w14=0,w15=0;w15<5;w15++)w13^=(w28=w2[w12+5*w15]).high,w14^=w28.low;var w16=w11[w12];w16.high=w13,w16.low=w14}for(w12=0;w12<5;w12++){var w17=w11[(w12+4)%5],w18=w11[(w12+1)%5],w19=w18.high,w20=w18.low;for(w13=w17.high^(w19<<1|w20>>>31),w14=w17.low^(w20<<1|w19>>>31),w15=0;w15<5;w15++)(w28=w2[w12+5*w15]).high^=w13,w28.low^=w14}for(var w21=1;w21<25;w21++){var w22=(w28=w2[w21]).high,w23=w28.low,w24=w8[w21];w24<32?(w13=w22<>>32-w24,w14=w23<>>32-w24):(w13=w23<>>64-w24,w14=w22<>>64-w24);var w25=w11[w9[w21]];w25.high=w13,w25.low=w14}var w26=w11[0],w27=w2[0];for(w26.high=w27.high,w26.low=w27.low,w12=0;w12<5;w12++)for(w15=0;w15<5;w15++){var w28=w2[w21=w12+5*w15],w29=w11[w21],w30=w11[(w12+1)%5+5*w15],w31=w11[(w12+2)%5+5*w15];w28.high=w29.high^~w30.high&w31.high,w28.low=w29.low^~w30.low&w31.low}w28=w2[0];var w32=w10[w7];w28.high^=w32.high,w28.low^=w32.low}},_doFinalize:function(){var w1=this._data,w2=w1.words,w3=(this._nDataBytes,8*w1.sigBytes),w5=32*this.blockSize;w2[w3>>>5]|=1<<24-w3%32,w2[(w0.ceil((w3+1)/w5)*w5>>>5)-1]|=128,w1.sigBytes=4*w2.length,this._process();for(var w6=this._state,w7=this.cfg.outputLength/8,w8=w7/8,w9=[],w10=0;w10>>24)|4278255360&(w12<<24|w12>>>8),w13=16711935&(w13<<8|w13>>>24)|4278255360&(w13<<24|w13>>>8),w9.push(w13),w9.push(w12)}return new w4.init(w9,w7)},clone:function(){for(var w0=w5.clone.call(this),w1=w0._state=this._state.slice(0),w2=0;w2<25;w2++)w1[w2]=w1[w2].clone();return w0}});w1.SHA3=w5._createHelper(w12),w1.HmacSHA3=w5._createHmacHelper(w12)}(Math),w3.SHA3)},function(w0,w1,w2){var w3;w0.exports=(w3=w2(0),function(w0){var w1=w3,w2=w1.lib,w4=w2.WordArray,w5=w2.Hasher,w6=w1.algo,w7=w4.create([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13]),w8=w4.create([5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11]),w9=w4.create([11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6]),w10=w4.create([8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]),w11=w4.create([0,1518500249,1859775393,2400959708,2840853838]),w12=w4.create([1352829926,1548603684,1836072691,2053994217,0]),w13=w6.RIPEMD160=w5.extend({_doReset:function(){this._hash=w4.create([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(w0,w1){for(var w2=0;w2<16;w2++){var w3=w1+w2,w4=w0[w3];w0[w3]=16711935&(w4<<8|w4>>>24)|4278255360&(w4<<24|w4>>>8)}var w5,w6,w13,w20,w21,w22,w23,w24,w25,w26,w27,w28=this._hash.words,w29=w11.words,w30=w12.words,w31=w7.words,w32=w8.words,w33=w9.words,w34=w10.words;for(w22=w5=w28[0],w23=w6=w28[1],w24=w13=w28[2],w25=w20=w28[3],w26=w21=w28[4],w2=0;w2<80;w2+=1)w27=w5+w0[w1+w31[w2]]|0,w27+=w2<16?w14(w6,w13,w20)+w29[0]:w2<32?w15(w6,w13,w20)+w29[1]:w2<48?w16(w6,w13,w20)+w29[2]:w2<64?w17(w6,w13,w20)+w29[3]:w18(w6,w13,w20)+w29[4],w27=(w27=w19(w27|=0,w33[w2]))+w21|0,w5=w21,w21=w20,w20=w19(w13,10),w13=w6,w6=w27,w27=w22+w0[w1+w32[w2]]|0,w27+=w2<16?w18(w23,w24,w25)+w30[0]:w2<32?w17(w23,w24,w25)+w30[1]:w2<48?w16(w23,w24,w25)+w30[2]:w2<64?w15(w23,w24,w25)+w30[3]:w14(w23,w24,w25)+w30[4],w27=(w27=w19(w27|=0,w34[w2]))+w26|0,w22=w26,w26=w25,w25=w19(w24,10),w24=w23,w23=w27;w27=w28[1]+w13+w25|0,w28[1]=w28[2]+w20+w26|0,w28[2]=w28[3]+w21+w22|0,w28[3]=w28[4]+w5+w23|0,w28[4]=w28[0]+w6+w24|0,w28[0]=w27},_doFinalize:function(){var w0=this._data,w1=w0.words,w2=8*this._nDataBytes,w3=8*w0.sigBytes;w1[w3>>>5]|=128<<24-w3%32,w1[14+(w3+64>>>9<<4)]=16711935&(w2<<8|w2>>>24)|4278255360&(w2<<24|w2>>>8),w0.sigBytes=4*(w1.length+1),this._process();for(var w4=this._hash,w5=w4.words,w6=0;w6<5;w6++){var w7=w5[w6];w5[w6]=16711935&(w7<<8|w7>>>24)|4278255360&(w7<<24|w7>>>8)}return w4},clone:function(){var w0=w5.clone.call(this);return w0._hash=this._hash.clone(),w0}});function w14(w0,w1,w2){return w0^w1^w2}function w15(w0,w1,w2){return w0&w1|~w0&w2}function w16(w0,w1,w2){return(w0|~w1)^w2}function w17(w0,w1,w2){return w0&w2|w1&~w2}function w18(w0,w1,w2){return w0^(w1|~w2)}function w19(w0,w1){return w0<>>32-w1}w1.RIPEMD160=w5._createHelper(w13),w1.HmacRIPEMD160=w5._createHmacHelper(w13)}(Math),w3.RIPEMD160)},function(w0,w1,w2){var w3,w4,w5,w6,w7,w8,w9,w10,w11;w0.exports=(w11=w2(0),w2(83),w2(84),w4=(w3=w11).lib,w5=w4.Base,w6=w4.WordArray,w7=w3.algo,w8=w7.SHA1,w9=w7.HMAC,w10=w7.PBKDF2=w5.extend({cfg:w5.extend({keySize:4,hasher:w8,iterations:1}),init:function(w0){this.cfg=this.cfg.extend(w0)},compute:function(w0,w1){for(var w2=this.cfg,w3=w9.create(w2.hasher,w0),w4=w6.create(),w5=w6.create([1]),w7=w4.words,w8=w5.words,w10=w2.keySize,w11=w2.iterations;w7.length>24&255)){var w1=w0>>16&255,w2=w0>>8&255,w3=255&w0;255===w1?(w1=0,255===w2?(w2=0,255===w3?w3=0:++w3):++w2):++w1,w0=0,w0+=w1<<16,w0+=w2<<8,w0+=w3}else w0+=1<<24;return w0}function w2(w0){return 0===(w0[0]=w1(w0[0]))&&(w0[1]=w1(w0[1])),w0}var w4=w0.Encryptor=w0.extend({processBlock:function(w0,w1){var w3=this._cipher,w4=w3.blockSize,w5=this._iv,w6=this._counter;w5&&(w6=this._counter=w5.slice(0),this._iv=void 0),w2(w6);var w7=w6.slice(0);w3.encryptBlock(w7,0);for(var w8=0;w8>>2]|=w4<<24-w5%4*8,w0.sigBytes+=w4},unpad:function(w0){var w1=255&w0.words[w0.sigBytes-1>>>2];w0.sigBytes-=w1}},w3.pad.Ansix923)},function(w0,w1,w2){var w3;w0.exports=(w3=w2(0),w2(3),w3.pad.Iso10126={pad:function(w0,w1){var w2=4*w1,w4=w2-w0.sigBytes%w2;w0.concat(w3.lib.WordArray.random(w4-1)).concat(w3.lib.WordArray.create([w4<<24],1))},unpad:function(w0){var w1=255&w0.words[w0.sigBytes-1>>>2];w0.sigBytes-=w1}},w3.pad.Iso10126)},function(w0,w1,w2){var w3;w0.exports=(w3=w2(0),w2(3),w3.pad.Iso97971={pad:function(w0,w1){w0.concat(w3.lib.WordArray.create([2147483648],1)),w3.pad.ZeroPadding.pad(w0,w1)},unpad:function(w0){w3.pad.ZeroPadding.unpad(w0),w0.sigBytes--}},w3.pad.Iso97971)},function(w0,w1,w2){var w3;w0.exports=(w3=w2(0),w2(3),w3.pad.ZeroPadding={pad:function(w0,w1){var w2=4*w1;w0.clamp(),w0.sigBytes+=w2-(w0.sigBytes%w2||w2)},unpad:function(w0){for(var w1=w0.words,w2=w0.sigBytes-1;!(w1[w2>>>2]>>>24-w2%4*8&255);)w2--;w0.sigBytes=w2+1}},w3.pad.ZeroPadding)},function(w0,w1,w2){var w3;w0.exports=(w3=w2(0),w2(3),w3.pad.NoPadding={pad:function(){},unpad:function(){}},w3.pad.NoPadding)},function(w0,w1,w2){var w3,w4,w5,w6;w0.exports=(w6=w2(0),w2(3),w4=(w3=w6).lib.CipherParams,w5=w3.enc.Hex,w3.format.Hex={stringify:function(w0){return w0.ciphertext.toString(w5)},parse:function(w0){var w1=w5.parse(w0);return w4.create({ciphertext:w1})}},w6.format.Hex)},function(w0,w1,w2){var w3;w0.exports=(w3=w2(0),w2(30),w2(31),w2(23),w2(3),function(){var w0=w3,w1=w0.lib.BlockCipher,w2=w0.algo,w4=[],w5=[],w6=[],w7=[],w8=[],w9=[],w10=[],w11=[],w12=[],w13=[];!function(){for(var w0=[],w1=0;w1<256;w1++)w0[w1]=w1<128?w1<<1:w1<<1^283;var w2=0,w3=0;for(w1=0;w1<256;w1++){var w14=w3^w3<<1^w3<<2^w3<<3^w3<<4;w14=w14>>>8^255&w14^99,w4[w2]=w14,w5[w14]=w2;var w15=w0[w2],w16=w0[w15],w17=w0[w16],w18=257*w0[w14]^16843008*w14;w6[w2]=w18<<24|w18>>>8,w7[w2]=w18<<16|w18>>>16,w8[w2]=w18<<8|w18>>>24,w9[w2]=w18,w18=16843009*w17^65537*w16^257*w15^16843008*w2,w10[w14]=w18<<24|w18>>>8,w11[w14]=w18<<16|w18>>>16,w12[w14]=w18<<8|w18>>>24,w13[w14]=w18,w2?(w2=w15^w0[w0[w0[w17^w15]]],w3^=w0[w0[w3]]):w2=w3=1}}();var w14=[0,1,2,4,8,16,32,64,128,27,54],w15=w2.AES=w1.extend({_doReset:function(){if(!this._nRounds||this._keyPriorReset!==this._key){for(var w0=this._keyPriorReset=this._key,w1=w0.words,w2=w0.sigBytes/4,w3=4*((this._nRounds=w2+6)+1),w5=this._keySchedule=[],w6=0;w66&&w6%w2==4&&(w7=w4[w7>>>24]<<24|w4[w7>>>16&255]<<16|w4[w7>>>8&255]<<8|w4[255&w7]):(w7=w4[(w7=w7<<8|w7>>>24)>>>24]<<24|w4[w7>>>16&255]<<16|w4[w7>>>8&255]<<8|w4[255&w7],w7^=w14[w6/w2|0]<<24),w5[w6]=w5[w6-w2]^w7}for(var w8=this._invKeySchedule=[],w9=0;w9>>24]]^w11[w4[w7>>>16&255]]^w12[w4[w7>>>8&255]]^w13[w4[255&w7]]}},encryptBlock:function(w0,w1){this._doCryptBlock(w0,w1,this._keySchedule,w6,w7,w8,w9,w4)},decryptBlock:function(w0,w1){var w2=w0[w1+1];w0[w1+1]=w0[w1+3],w0[w1+3]=w2,this._doCryptBlock(w0,w1,this._invKeySchedule,w10,w11,w12,w13,w5),w2=w0[w1+1],w0[w1+1]=w0[w1+3],w0[w1+3]=w2},_doCryptBlock:function(w0,w1,w2,w3,w4,w5,w6,w7){for(var w8=this._nRounds,w9=w0[w1]^w2[0],w10=w0[w1+1]^w2[1],w11=w0[w1+2]^w2[2],w12=w0[w1+3]^w2[3],w13=4,w14=1;w14>>24]^w4[w10>>>16&255]^w5[w11>>>8&255]^w6[255&w12]^w2[w13++],w16=w3[w10>>>24]^w4[w11>>>16&255]^w5[w12>>>8&255]^w6[255&w9]^w2[w13++],w17=w3[w11>>>24]^w4[w12>>>16&255]^w5[w9>>>8&255]^w6[255&w10]^w2[w13++],w18=w3[w12>>>24]^w4[w9>>>16&255]^w5[w10>>>8&255]^w6[255&w11]^w2[w13++];w9=w15,w10=w16,w11=w17,w12=w18}w15=(w7[w9>>>24]<<24|w7[w10>>>16&255]<<16|w7[w11>>>8&255]<<8|w7[255&w12])^w2[w13++],w16=(w7[w10>>>24]<<24|w7[w11>>>16&255]<<16|w7[w12>>>8&255]<<8|w7[255&w9])^w2[w13++],w17=(w7[w11>>>24]<<24|w7[w12>>>16&255]<<16|w7[w9>>>8&255]<<8|w7[255&w10])^w2[w13++],w18=(w7[w12>>>24]<<24|w7[w9>>>16&255]<<16|w7[w10>>>8&255]<<8|w7[255&w11])^w2[w13++],w0[w1]=w15,w0[w1+1]=w16,w0[w1+2]=w17,w0[w1+3]=w18},keySize:8});w0.AES=w1._createHelper(w15)}(),w3.AES)},function(w0,w1,w2){var w3;w0.exports=(w3=w2(0),w2(30),w2(31),w2(23),w2(3),function(){var w0=w3,w1=w0.lib,w2=w1.WordArray,w4=w1.BlockCipher,w5=w0.algo,w6=[57,49,41,33,25,17,9,1,58,50,42,34,26,18,10,2,59,51,43,35,27,19,11,3,60,52,44,36,63,55,47,39,31,23,15,7,62,54,46,38,30,22,14,6,61,53,45,37,29,21,13,5,28,20,12,4],w7=[14,17,11,24,1,5,3,28,15,6,21,10,23,19,12,4,26,8,16,7,27,20,13,2,41,52,31,37,47,55,30,40,51,45,33,48,44,49,39,56,34,53,46,42,50,36,29,32],w8=[1,2,4,6,8,10,12,14,15,17,19,21,23,25,27,28],w9=[{0:8421888,268435456:32768,536870912:8421378,805306368:2,1073741824:512,1342177280:8421890,1610612736:8389122,1879048192:8388608,2147483648:514,2415919104:8389120,2684354560:33280,2952790016:8421376,3221225472:32770,3489660928:8388610,3758096384:0,4026531840:33282,134217728:0,402653184:8421890,671088640:33282,939524096:32768,1207959552:8421888,1476395008:512,1744830464:8421378,2013265920:2,2281701376:8389120,2550136832:33280,2818572288:8421376,3087007744:8389122,3355443200:8388610,3623878656:32770,3892314112:514,4160749568:8388608,1:32768,268435457:2,536870913:8421888,805306369:8388608,1073741825:8421378,1342177281:33280,1610612737:512,1879048193:8389122,2147483649:8421890,2415919105:8421376,2684354561:8388610,2952790017:33282,3221225473:514,3489660929:8389120,3758096385:32770,4026531841:0,134217729:8421890,402653185:8421376,671088641:8388608,939524097:512,1207959553:32768,1476395009:8388610,1744830465:2,2013265921:33282,2281701377:32770,2550136833:8389122,2818572289:514,3087007745:8421888,3355443201:8389120,3623878657:0,3892314113:33280,4160749569:8421378},{0:1074282512,16777216:16384,33554432:524288,50331648:1074266128,67108864:1073741840,83886080:1074282496,100663296:1073758208,117440512:16,134217728:540672,150994944:1073758224,167772160:1073741824,184549376:540688,201326592:524304,218103808:0,234881024:16400,251658240:1074266112,8388608:1073758208,25165824:540688,41943040:16,58720256:1073758224,75497472:1074282512,92274688:1073741824,109051904:524288,125829120:1074266128,142606336:524304,159383552:0,176160768:16384,192937984:1074266112,209715200:1073741840,226492416:540672,243269632:1074282496,260046848:16400,268435456:0,285212672:1074266128,301989888:1073758224,318767104:1074282496,335544320:1074266112,352321536:16,369098752:540688,385875968:16384,402653184:16400,419430400:524288,436207616:524304,452984832:1073741840,469762048:540672,486539264:1073758208,503316480:1073741824,520093696:1074282512,276824064:540688,293601280:524288,310378496:1074266112,327155712:16384,343932928:1073758208,360710144:1074282512,377487360:16,394264576:1073741824,411041792:1074282496,427819008:1073741840,444596224:1073758224,461373440:524304,478150656:0,494927872:16400,511705088:1074266128,528482304:540672},{0:260,1048576:0,2097152:67109120,3145728:65796,4194304:65540,5242880:67108868,6291456:67174660,7340032:67174400,8388608:67108864,9437184:67174656,10485760:65792,11534336:67174404,12582912:67109124,13631488:65536,14680064:4,15728640:256,524288:67174656,1572864:67174404,2621440:0,3670016:67109120,4718592:67108868,5767168:65536,6815744:65540,7864320:260,8912896:4,9961472:256,11010048:67174400,12058624:65796,13107200:65792,14155776:67109124,15204352:67174660,16252928:67108864,16777216:67174656,17825792:65540,18874368:65536,19922944:67109120,20971520:256,22020096:67174660,23068672:67108868,24117248:0,25165824:67109124,26214400:67108864,27262976:4,28311552:65792,29360128:67174400,30408704:260,31457280:65796,32505856:67174404,17301504:67108864,18350080:260,19398656:67174656,20447232:0,21495808:65540,22544384:67109120,23592960:256,24641536:67174404,25690112:65536,26738688:67174660,27787264:65796,28835840:67108868,29884416:67109124,30932992:67174400,31981568:4,33030144:65792},{0:2151682048,65536:2147487808,131072:4198464,196608:2151677952,262144:0,327680:4198400,393216:2147483712,458752:4194368,524288:2147483648,589824:4194304,655360:64,720896:2147487744,786432:2151678016,851968:4160,917504:4096,983040:2151682112,32768:2147487808,98304:64,163840:2151678016,229376:2147487744,294912:4198400,360448:2151682112,425984:0,491520:2151677952,557056:4096,622592:2151682048,688128:4194304,753664:4160,819200:2147483648,884736:4194368,950272:4198464,1015808:2147483712,1048576:4194368,1114112:4198400,1179648:2147483712,1245184:0,1310720:4160,1376256:2151678016,1441792:2151682048,1507328:2147487808,1572864:2151682112,1638400:2147483648,1703936:2151677952,1769472:4198464,1835008:2147487744,1900544:4194304,1966080:64,2031616:4096,1081344:2151677952,1146880:2151682112,1212416:0,1277952:4198400,1343488:4194368,1409024:2147483648,1474560:2147487808,1540096:64,1605632:2147483712,1671168:4096,1736704:2147487744,1802240:2151678016,1867776:4160,1933312:2151682048,1998848:4194304,2064384:4198464},{0:128,4096:17039360,8192:262144,12288:536870912,16384:537133184,20480:16777344,24576:553648256,28672:262272,32768:16777216,36864:537133056,40960:536871040,45056:553910400,49152:553910272,53248:0,57344:17039488,61440:553648128,2048:17039488,6144:553648256,10240:128,14336:17039360,18432:262144,22528:537133184,26624:553910272,30720:536870912,34816:537133056,38912:0,43008:553910400,47104:16777344,51200:536871040,55296:553648128,59392:16777216,63488:262272,65536:262144,69632:128,73728:536870912,77824:553648256,81920:16777344,86016:553910272,90112:537133184,94208:16777216,98304:553910400,102400:553648128,106496:17039360,110592:537133056,114688:262272,118784:536871040,122880:0,126976:17039488,67584:553648256,71680:16777216,75776:17039360,79872:537133184,83968:536870912,88064:17039488,92160:128,96256:553910272,100352:262272,104448:553910400,108544:0,112640:553648128,116736:16777344,120832:262144,124928:537133056,129024:536871040},{0:268435464,256:8192,512:270532608,768:270540808,1024:268443648,1280:2097152,1536:2097160,1792:268435456,2048:0,2304:268443656,2560:2105344,2816:8,3072:270532616,3328:2105352,3584:8200,3840:270540800,128:270532608,384:270540808,640:8,896:2097152,1152:2105352,1408:268435464,1664:268443648,1920:8200,2176:2097160,2432:8192,2688:268443656,2944:270532616,3200:0,3456:270540800,3712:2105344,3968:268435456,4096:268443648,4352:270532616,4608:270540808,4864:8200,5120:2097152,5376:268435456,5632:268435464,5888:2105344,6144:2105352,6400:0,6656:8,6912:270532608,7168:8192,7424:268443656,7680:270540800,7936:2097160,4224:8,4480:2105344,4736:2097152,4992:268435464,5248:268443648,5504:8200,5760:270540808,6016:270532608,6272:270540800,6528:270532616,6784:8192,7040:2105352,7296:2097160,7552:0,7808:268435456,8064:268443656},{0:1048576,16:33555457,32:1024,48:1049601,64:34604033,80:0,96:1,112:34603009,128:33555456,144:1048577,160:33554433,176:34604032,192:34603008,208:1025,224:1049600,240:33554432,8:34603009,24:0,40:33555457,56:34604032,72:1048576,88:33554433,104:33554432,120:1025,136:1049601,152:33555456,168:34603008,184:1048577,200:1024,216:34604033,232:1,248:1049600,256:33554432,272:1048576,288:33555457,304:34603009,320:1048577,336:33555456,352:34604032,368:1049601,384:1025,400:34604033,416:1049600,432:1,448:0,464:34603008,480:33554433,496:1024,264:1049600,280:33555457,296:34603009,312:1,328:33554432,344:1048576,360:1025,376:34604032,392:33554433,408:34603008,424:0,440:34604033,456:1049601,472:1024,488:33555456,504:1048577},{0:134219808,1:131072,2:134217728,3:32,4:131104,5:134350880,6:134350848,7:2048,8:134348800,9:134219776,10:133120,11:134348832,12:2080,13:0,14:134217760,15:133152,2147483648:2048,2147483649:134350880,2147483650:134219808,2147483651:134217728,2147483652:134348800,2147483653:133120,2147483654:133152,2147483655:32,2147483656:134217760,2147483657:2080,2147483658:131104,2147483659:134350848,2147483660:0,2147483661:134348832,2147483662:134219776,2147483663:131072,16:133152,17:134350848,18:32,19:2048,20:134219776,21:134217760,22:134348832,23:131072,24:0,25:131104,26:134348800,27:134219808,28:134350880,29:133120,30:2080,31:134217728,2147483664:131072,2147483665:2048,2147483666:134348832,2147483667:133152,2147483668:32,2147483669:134348800,2147483670:134217728,2147483671:134219808,2147483672:134350880,2147483673:134217760,2147483674:134219776,2147483675:0,2147483676:133120,2147483677:2080,2147483678:131104,2147483679:134350848}],w10=[4160749569,528482304,33030144,2064384,129024,8064,504,2147483679],w11=w5.DES=w4.extend({_doReset:function(){for(var w0=this._key.words,w1=[],w2=0;w2<56;w2++){var w3=w6[w2]-1;w1[w2]=w0[w3>>>5]>>>31-w3%32&1}for(var w4=this._subKeys=[],w5=0;w5<16;w5++){var w9=w4[w5]=[],w10=w8[w5];for(w2=0;w2<24;w2++)w9[w2/6|0]|=w1[(w7[w2]-1+w10)%28]<<31-w2%6,w9[4+(w2/6|0)]|=w1[28+(w7[w2+24]-1+w10)%28]<<31-w2%6;for(w9[0]=w9[0]<<1|w9[0]>>>31,w2=1;w2<7;w2++)w9[w2]=w9[w2]>>>4*(w2-1)+3;w9[7]=w9[7]<<5|w9[7]>>>27}var w11=this._invSubKeys=[];for(w2=0;w2<16;w2++)w11[w2]=w4[15-w2]},encryptBlock:function(w0,w1){this._doCryptBlock(w0,w1,this._subKeys)},decryptBlock:function(w0,w1){this._doCryptBlock(w0,w1,this._invSubKeys)},_doCryptBlock:function(w0,w1,w2){this._lBlock=w0[w1],this._rBlock=w0[w1+1],w12.call(this,4,252645135),w12.call(this,16,65535),w13.call(this,2,858993459),w13.call(this,8,16711935),w12.call(this,1,1431655765);for(var w3=0;w3<16;w3++){for(var w4=w2[w3],w5=this._lBlock,w6=this._rBlock,w7=0,w8=0;w8<8;w8++)w7|=w9[w8][((w6^w4[w8])&w10[w8])>>>0];this._lBlock=w6,this._rBlock=w5^w7}var w11=this._lBlock;this._lBlock=this._rBlock,this._rBlock=w11,w12.call(this,1,1431655765),w13.call(this,8,16711935),w13.call(this,2,858993459),w12.call(this,16,65535),w12.call(this,4,252645135),w0[w1]=this._lBlock,w0[w1+1]=this._rBlock},keySize:2,ivSize:2,blockSize:2});function w12(w0,w1){var w2=(this._lBlock>>>w0^this._rBlock)&w1;this._rBlock^=w2,this._lBlock^=w2<>>w0^this._lBlock)&w1;this._lBlock^=w2,this._rBlock^=w2<>>2]>>>24-w6%4*8&255;w5=(w5+w3[w4]+w7)%256;var w8=w3[w4];w3[w4]=w3[w5],w3[w5]=w8}this._i=this._j=0},_doProcessBlock:function(w0,w1){w0[w1]^=w5.call(this)},keySize:8,ivSize:0});function w5(){for(var w0=this._S,w1=this._i,w2=this._j,w3=0,w4=0;w4<4;w4++){w2=(w2+w0[w1=(w1+1)%256])%256;var w5=w0[w1];w0[w1]=w0[w2],w0[w2]=w5,w3|=w0[(w0[w1]+w0[w2])%256]<<24-8*w4}return this._i=w1,this._j=w2,w3}w0.RC4=w1._createHelper(w4);var w6=w2.RC4Drop=w4.extend({cfg:w4.cfg.extend({drop:192}),_doReset:function(){w4._doReset.call(this);for(var w0=this.cfg.drop;w0>0;w0--)w5.call(this)}});w0.RC4Drop=w1._createHelper(w6)}(),w3.RC4)},function(w0,w1,w2){var w3;w0.exports=(w3=w2(0),w2(30),w2(31),w2(23),w2(3),function(){var w0=w3,w1=w0.lib.StreamCipher,w2=w0.algo,w4=[],w5=[],w6=[],w7=w2.Rabbit=w1.extend({_doReset:function(){for(var w0=this._key.words,w1=this.cfg.iv,w2=0;w2<4;w2++)w0[w2]=16711935&(w0[w2]<<8|w0[w2]>>>24)|4278255360&(w0[w2]<<24|w0[w2]>>>8);var w3=this._X=[w0[0],w0[3]<<16|w0[2]>>>16,w0[1],w0[0]<<16|w0[3]>>>16,w0[2],w0[1]<<16|w0[0]>>>16,w0[3],w0[2]<<16|w0[1]>>>16],w4=this._C=[w0[2]<<16|w0[2]>>>16,4294901760&w0[0]|65535&w0[1],w0[3]<<16|w0[3]>>>16,4294901760&w0[1]|65535&w0[2],w0[0]<<16|w0[0]>>>16,4294901760&w0[2]|65535&w0[3],w0[1]<<16|w0[1]>>>16,4294901760&w0[3]|65535&w0[0]];for(this._b=0,w2=0;w2<4;w2++)w8.call(this);for(w2=0;w2<8;w2++)w4[w2]^=w3[w2+4&7];if(w1){var w5=w1.words,w6=w5[0],w7=w5[1],w9=16711935&(w6<<8|w6>>>24)|4278255360&(w6<<24|w6>>>8),w10=16711935&(w7<<8|w7>>>24)|4278255360&(w7<<24|w7>>>8),w11=w9>>>16|4294901760&w10,w12=w10<<16|65535&w9;for(w4[0]^=w9,w4[1]^=w11,w4[2]^=w10,w4[3]^=w12,w4[4]^=w9,w4[5]^=w11,w4[6]^=w10,w4[7]^=w12,w2=0;w2<4;w2++)w8.call(this)}},_doProcessBlock:function(w0,w1){var w2=this._X;w8.call(this),w4[0]=w2[0]^w2[5]>>>16^w2[3]<<16,w4[1]=w2[2]^w2[7]>>>16^w2[5]<<16,w4[2]=w2[4]^w2[1]>>>16^w2[7]<<16,w4[3]=w2[6]^w2[3]>>>16^w2[1]<<16;for(var w3=0;w3<4;w3++)w4[w3]=16711935&(w4[w3]<<8|w4[w3]>>>24)|4278255360&(w4[w3]<<24|w4[w3]>>>8),w0[w1+w3]^=w4[w3]},blockSize:4,ivSize:2});function w8(){for(var w0=this._X,w1=this._C,w2=0;w2<8;w2++)w5[w2]=w1[w2];for(w1[0]=w1[0]+1295307597+this._b|0,w1[1]=w1[1]+3545052371+(w1[0]>>>0>>0?1:0)|0,w1[2]=w1[2]+886263092+(w1[1]>>>0>>0?1:0)|0,w1[3]=w1[3]+1295307597+(w1[2]>>>0>>0?1:0)|0,w1[4]=w1[4]+3545052371+(w1[3]>>>0>>0?1:0)|0,w1[5]=w1[5]+886263092+(w1[4]>>>0>>0?1:0)|0,w1[6]=w1[6]+1295307597+(w1[5]>>>0>>0?1:0)|0,w1[7]=w1[7]+3545052371+(w1[6]>>>0>>0?1:0)|0,this._b=w1[7]>>>0>>0?1:0,w2=0;w2<8;w2++){var w3=w0[w2]+w1[w2],w4=65535&w3,w7=w3>>>16,w8=((w4*w4>>>17)+w4*w7>>>15)+w7*w7,w9=((4294901760&w3)*w3|0)+((65535&w3)*w3|0);w6[w2]=w8^w9}w0[0]=w6[0]+(w6[7]<<16|w6[7]>>>16)+(w6[6]<<16|w6[6]>>>16)|0,w0[1]=w6[1]+(w6[0]<<8|w6[0]>>>24)+w6[7]|0,w0[2]=w6[2]+(w6[1]<<16|w6[1]>>>16)+(w6[0]<<16|w6[0]>>>16)|0,w0[3]=w6[3]+(w6[2]<<8|w6[2]>>>24)+w6[1]|0,w0[4]=w6[4]+(w6[3]<<16|w6[3]>>>16)+(w6[2]<<16|w6[2]>>>16)|0,w0[5]=w6[5]+(w6[4]<<8|w6[4]>>>24)+w6[3]|0,w0[6]=w6[6]+(w6[5]<<16|w6[5]>>>16)+(w6[4]<<16|w6[4]>>>16)|0,w0[7]=w6[7]+(w6[6]<<8|w6[6]>>>24)+w6[5]|0}w0.Rabbit=w1._createHelper(w7)}(),w3.Rabbit)},function(w0,w1,w2){var w3;w0.exports=(w3=w2(0),w2(30),w2(31),w2(23),w2(3),function(){var w0=w3,w1=w0.lib.StreamCipher,w2=w0.algo,w4=[],w5=[],w6=[],w7=w2.RabbitLegacy=w1.extend({_doReset:function(){var w0=this._key.words,w1=this.cfg.iv,w2=this._X=[w0[0],w0[3]<<16|w0[2]>>>16,w0[1],w0[0]<<16|w0[3]>>>16,w0[2],w0[1]<<16|w0[0]>>>16,w0[3],w0[2]<<16|w0[1]>>>16],w3=this._C=[w0[2]<<16|w0[2]>>>16,4294901760&w0[0]|65535&w0[1],w0[3]<<16|w0[3]>>>16,4294901760&w0[1]|65535&w0[2],w0[0]<<16|w0[0]>>>16,4294901760&w0[2]|65535&w0[3],w0[1]<<16|w0[1]>>>16,4294901760&w0[3]|65535&w0[0]];this._b=0;for(var w4=0;w4<4;w4++)w8.call(this);for(w4=0;w4<8;w4++)w3[w4]^=w2[w4+4&7];if(w1){var w5=w1.words,w6=w5[0],w7=w5[1],w9=16711935&(w6<<8|w6>>>24)|4278255360&(w6<<24|w6>>>8),w10=16711935&(w7<<8|w7>>>24)|4278255360&(w7<<24|w7>>>8),w11=w9>>>16|4294901760&w10,w12=w10<<16|65535&w9;for(w3[0]^=w9,w3[1]^=w11,w3[2]^=w10,w3[3]^=w12,w3[4]^=w9,w3[5]^=w11,w3[6]^=w10,w3[7]^=w12,w4=0;w4<4;w4++)w8.call(this)}},_doProcessBlock:function(w0,w1){var w2=this._X;w8.call(this),w4[0]=w2[0]^w2[5]>>>16^w2[3]<<16,w4[1]=w2[2]^w2[7]>>>16^w2[5]<<16,w4[2]=w2[4]^w2[1]>>>16^w2[7]<<16,w4[3]=w2[6]^w2[3]>>>16^w2[1]<<16;for(var w3=0;w3<4;w3++)w4[w3]=16711935&(w4[w3]<<8|w4[w3]>>>24)|4278255360&(w4[w3]<<24|w4[w3]>>>8),w0[w1+w3]^=w4[w3]},blockSize:4,ivSize:2});function w8(){for(var w0=this._X,w1=this._C,w2=0;w2<8;w2++)w5[w2]=w1[w2];for(w1[0]=w1[0]+1295307597+this._b|0,w1[1]=w1[1]+3545052371+(w1[0]>>>0>>0?1:0)|0,w1[2]=w1[2]+886263092+(w1[1]>>>0>>0?1:0)|0,w1[3]=w1[3]+1295307597+(w1[2]>>>0>>0?1:0)|0,w1[4]=w1[4]+3545052371+(w1[3]>>>0>>0?1:0)|0,w1[5]=w1[5]+886263092+(w1[4]>>>0>>0?1:0)|0,w1[6]=w1[6]+1295307597+(w1[5]>>>0>>0?1:0)|0,w1[7]=w1[7]+3545052371+(w1[6]>>>0>>0?1:0)|0,this._b=w1[7]>>>0>>0?1:0,w2=0;w2<8;w2++){var w3=w0[w2]+w1[w2],w4=65535&w3,w7=w3>>>16,w8=((w4*w4>>>17)+w4*w7>>>15)+w7*w7,w9=((4294901760&w3)*w3|0)+((65535&w3)*w3|0);w6[w2]=w8^w9}w0[0]=w6[0]+(w6[7]<<16|w6[7]>>>16)+(w6[6]<<16|w6[6]>>>16)|0,w0[1]=w6[1]+(w6[0]<<8|w6[0]>>>24)+w6[7]|0,w0[2]=w6[2]+(w6[1]<<16|w6[1]>>>16)+(w6[0]<<16|w6[0]>>>16)|0,w0[3]=w6[3]+(w6[2]<<8|w6[2]>>>24)+w6[1]|0,w0[4]=w6[4]+(w6[3]<<16|w6[3]>>>16)+(w6[2]<<16|w6[2]>>>16)|0,w0[5]=w6[5]+(w6[4]<<8|w6[4]>>>24)+w6[3]|0,w0[6]=w6[6]+(w6[5]<<16|w6[5]>>>16)+(w6[4]<<16|w6[4]>>>16)|0,w0[7]=w6[7]+(w6[6]<<8|w6[6]>>>24)+w6[5]|0}w0.RabbitLegacy=w1._createHelper(w7)}(),w3.RabbitLegacy)},function(w0,w1,w2){w0.exports={sm2:w2(251),sm3:w2(255),sm4:w2(256)}},function(w0,w1,w2){const{BigInteger:w3}=w2(57),{encodeDer:w4,decodeDer:w5}=w2(252),w6=w2(253),w7=w2(128),{G:w8,curve:w9,n:w10}=w6.generateEcparam();function w11(w0,w1,w2="1234567812345678"){w2=w6.utf8ToHex(w2);const w3=w6.leftPad(w8.curve.a.toBigInteger().toRadix(16),64),w4=w6.leftPad(w8.curve.b.toBigInteger().toRadix(16),64),w5=w6.leftPad(w8.getX().toBigInteger().toRadix(16),64),w9=w6.leftPad(w8.getY().toBigInteger().toRadix(16),64);w1.length>128&&(w1=w1.substr(2,128));const w10=w1.substr(0,64),w11=w1.substr(64,64),w12=w6.hexToArray(w2+w3+w4+w5+w9+w10+w11),w13=4*w2.length;w12.unshift(255&w13),w12.unshift(65280&w13);const w14=w7(w12);return w6.arrayToHex(w7(w14.concat(w6.hexToArray(w0))))}function w12(){const w0=w6.generateKeyPairHex(),w1=w9.decodePointHex(w0.publicKey);return w0.k=new w3(w0.privateKey,16),w0.x1=w1.getX().toBigInteger(),w0}w0.exports={generateKeyPairHex:w6.generateKeyPairHex,doEncrypt:function(w0,w1,w2=1){w0=w6.hexToArray(w6.utf8ToHex(w0)),w1=w6.getGlobalCurve().decodePointHex(w1);const w4=w6.generateKeyPairHex(),w5=new w3(w4.privateKey,16);let w8=w4.publicKey;w8.length>128&&(w8=w8.substr(w8.length-128));const w9=w1.multiply(w5),w10=w6.hexToArray(w6.leftPad(w9.getX().toBigInteger().toRadix(16),64)),w11=w6.hexToArray(w6.leftPad(w9.getY().toBigInteger().toRadix(16),64)),w12=w6.arrayToHex(w7([].concat(w10,w0,w11)));let w13=1,w14=0,w15=[];const w16=[].concat(w10,w11),w17=()=>{w15=w7([...w16,w13>>24&255,w13>>16&255,w13>>8&255,255&w13]),w13++,w14=0};w17();for(let w1=0,w2=w0.length;w1{w14=w7([...w15,w12>>24&255,w12>>16&255,w12>>8&255,255&w12]),w12++,w13=0};w16();for(let w0=0,w1=w8.length;w0w0.getEncodedHex())).join(""),this.v}}function w7(w0,w1){return+w0[w1+2]<8?1:128&+w0.substr(w1+2,2)}function w8(w0,w1){const w2=w7(w0,w1),w4=w0.substr(w1+2,2*w2);if(!w4)return-1;return(+w4[0]<8?new w3(w4,16):new w3(w4.substr(2),16)).intValue()}function w9(w0,w1){return w1+2*(w7(w0,w1)+1)}w0.exports={encodeDer(w0,w1){const w2=new w5(w0),w3=new w5(w1);return new w6([w2,w3]).getEncodedHex()},decodeDer(w0){const w1=w9(w0,0),w2=w9(w0,w1),w4=w8(w0,w1),w5=w0.substr(w2,2*w4),w6=w2+w5.length,w7=w9(w0,w6),w10=w8(w0,w6),w11=w0.substr(w7,2*w10);return{r:new w3(w5,16),s:new w3(w11,16)}}}},function(w0,w1,w2){const{BigInteger:w3,SecureRandom:w4}=w2(57),{ECCurveFp:w5}=w2(254),w6=new w4,{curve:w7,G:w8,n:w9}=w10();function w10(){const w0=new w3("FFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF00000000FFFFFFFFFFFFFFFF",16),w1=new w3("FFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF00000000FFFFFFFFFFFFFFFC",16),w2=new w3("28E9FA9E9D9F5E344D5A9E4BCF6509A7F39789F515AB8F92DDBCBD414D940E93",16),w4=new w5(w0,w1,w2),w6=w4.decodePointHex("0432C4AE2C1F1981195F9904466A39C9948FE30BBFF2660BE1715A4589334C74C7BC3736A2F4F6779C59BDCEE36B692153D0A9877CC62A474002DF32E52139F0A0");return{curve:w4,G:w6,n:new w3("FFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFF7203DF6B21C6052B53BBF40939D54123",16)}}function w11(w0,w1){return w0.length>=w1?w0:new Array(w1-w0.length+1).join("0")+w0}w0.exports={getGlobalCurve:function(){return w7},generateEcparam:w10,generateKeyPairHex:function(){const w0=new w3(w9.bitLength(),w6).mod(w9.subtract(w3.ONE)).add(w3.ONE),w1=w11(w0.toString(16),64),w2=w8.multiply(w0);return{privateKey:w1,publicKey:"04"+w11(w2.getX().toBigInteger().toString(16),64)+w11(w2.getY().toBigInteger().toString(16),64)}},utf8ToHex:function(w0){const w1=(w0=unescape(encodeURIComponent(w0))).length,w2=[];for(let w3=0;w3>>2]|=(255&w0.charCodeAt(w3))<<24-w3%4*8;const w3=[];for(let w0=0;w0>>2]>>>24-w0%4*8&255;w3.push((w1>>>4).toString(16)),w3.push((15&w1).toString(16))}return w3.join("")},leftPad:w11,arrayToHex:function(w0){return w0.map((w0=>1===(w0=w0.toString(16)).length?"0"+w0:w0)).join("")},arrayToUtf8:function(w0){const w1=[];let w2=0;for(let w3=0;w3<2*w0.length;w3+=2)w1[w3>>>3]|=parseInt(w0[w2],10)<<24-w3%8*4,w2++;try{const w2=[];for(let w3=0;w3>>2]>>>24-w3%4*8&255;w2.push(String.fromCharCode(w0))}return decodeURIComponent(escape(w2.join("")))}catch(w0){throw new Error("Malformed UTF-8 data")}},hexToArray:function(w0){const w1=[];let w2=w0.length;w2%2!=0&&(w0=w11(w0,w2+1)),w2=w0.length;for(let w3=0;w30;w4--){w3=w3.twice();const w5=w1.testBit(w4);w5!==w0.testBit(w4)&&(w3=w3.add(w5?this:w2))}return w3}}w0.exports={ECPointFp:w6,ECCurveFp:class{constructor(w0,w1,w2){this.q=w0,this.a=this.fromBigInteger(w1),this.b=this.fromBigInteger(w2),this.infinity=new w6(this,null,null)}equals(w0){return w0===this||this.q.equals(w0.q)&&this.a.equals(w0.a)&&this.b.equals(w0.b)}fromBigInteger(w0){return new w5(this.q,w0)}decodePointHex(w0){switch(parseInt(w0.substr(0,2),16)){case 0:return this.infinity;case 2:case 3:default:return null;case 4:case 6:case 7:const w1=(w0.length-2)/2,w2=w0.substr(2,w1),w4=w0.substr(w1+2,w1);return new w6(this,this.fromBigInteger(new w3(w2,16)),this.fromBigInteger(new w3(w4,16)))}}}}},function(w0,w1,w2){const w3=w2(128);w0.exports=function(w0){return w0="string"==typeof w0?function(w0){const w1=[];for(let w2=0,w3=w0.length;w2>>6),w1.push(128|63&w3);else if(w3<=55295||w3>=57344&&w3<=65535)w1.push(224|w3>>>12),w1.push(128|w3>>>6&63),w1.push(128|63&w3);else{if(!(w3>=65536&&w3<=1114111))throw w1.push(w3),new Error("input is not supported");w2++,w1.push(240|w3>>>18&28),w1.push(128|w3>>>12&63),w1.push(128|w3>>>6&63),w1.push(128|63&w3)}}return w1}(w0):Array.prototype.slice.call(w0),w3(w0).map((w0=>1===(w0=w0.toString(16)).length?"0"+w0:w0)).join("")}},function(w0,w1){const w2=16,w3=[214,144,233,254,204,225,61,183,22,182,20,194,40,251,44,5,43,103,154,118,42,190,4,195,170,68,19,38,73,134,6,153,156,66,80,244,145,239,152,122,51,84,11,67,237,207,172,98,228,179,28,169,201,8,232,149,128,223,148,250,117,143,63,166,71,7,167,252,243,115,23,186,131,89,60,25,230,133,79,168,104,107,129,178,113,100,218,139,248,235,15,75,112,86,157,53,30,36,14,94,99,88,209,162,37,34,124,59,1,33,120,135,212,0,70,87,159,211,39,82,76,54,2,231,160,196,200,158,234,191,138,210,64,199,56,181,163,247,242,206,249,97,21,161,224,174,93,164,155,52,26,85,173,147,50,48,245,140,177,227,29,246,226,46,130,102,202,96,192,41,35,171,13,83,78,111,213,219,55,69,222,253,142,47,3,255,106,114,109,108,91,81,141,27,175,146,187,221,188,127,17,217,92,65,31,16,90,216,10,193,49,136,165,205,123,189,45,116,208,18,184,229,180,176,137,105,151,74,12,150,119,126,101,185,241,9,197,110,198,132,24,240,125,236,58,220,77,32,121,238,95,62,215,203,57,72],w4=[462357,472066609,943670861,1415275113,1886879365,2358483617,2830087869,3301692121,3773296373,4228057617,404694573,876298825,1347903077,1819507329,2291111581,2762715833,3234320085,3705924337,4177462797,337322537,808926789,1280531041,1752135293,2223739545,2695343797,3166948049,3638552301,4110090761,269950501,741554753,1213159005,1684763257];function w5(w0){const w1=[];for(let w2=0,w3=w0.length;w2>>32-w1}function w7(w0){return(255&w3[w0>>>24&255])<<24|(255&w3[w0>>>16&255])<<16|(255&w3[w0>>>8&255])<<8|255&w3[255&w0]}function w8(w0){return w0^w6(w0,2)^w6(w0,10)^w6(w0,18)^w6(w0,24)}function w9(w0){return w0^w6(w0,13)^w6(w0,23)}function w10(w0,w1,w2){const w3=new Array(4),w4=new Array(4);for(let w1=0;w1<4;w1++)w4[0]=255&w0[4*w1],w4[1]=255&w0[4*w1+1],w4[2]=255&w0[4*w1+2],w4[3]=255&w0[4*w1+3],w3[w1]=w4[0]<<24|w4[1]<<16|w4[2]<<8|w4[3];for(let w0,w1=0;w1<32;w1+=4)w0=w3[1]^w3[2]^w3[3]^w2[w1+0],w3[0]^=w8(w7(w0)),w0=w3[2]^w3[3]^w3[0]^w2[w1+1],w3[1]^=w8(w7(w0)),w0=w3[3]^w3[0]^w3[1]^w2[w1+2],w3[2]^=w8(w7(w0)),w0=w3[0]^w3[1]^w3[2]^w2[w1+3],w3[3]^=w8(w7(w0));for(let w0=0;w0<16;w0+=4)w1[w0]=w3[3-w0/4]>>>24&255,w1[w0+1]=w3[3-w0/4]>>>16&255,w1[w0+2]=w3[3-w0/4]>>>8&255,w1[w0+3]=255&w3[3-w0/4]}function w11(w0,w1,w3,{padding:w6="pkcs#5",mode:w8,iv:w11=[],output:w12="string"}={}){if("cbc"===w8&&("string"==typeof w11&&(w11=w5(w11)),16!==w11.length))throw new Error("iv is invalid");if("string"==typeof w1&&(w1=w5(w1)),16!==w1.length)throw new Error("key is invalid");if(w0="string"==typeof w0?0!==w3?function(w0){const w1=[];for(let w2=0,w3=w0.length;w2>>6),w1.push(128|63&w3);else if(w3<=55295||w3>=57344&&w3<=65535)w1.push(224|w3>>>12),w1.push(128|w3>>>6&63),w1.push(128|63&w3);else{if(!(w3>=65536&&w3<=1114111))throw w1.push(w3),new Error("input is not supported");w2++,w1.push(240|w3>>>18&28),w1.push(128|w3>>>12&63),w1.push(128|w3>>>6&63),w1.push(128|63&w3)}}return w1}(w0):w5(w0):[...w0],"pkcs#5"===w6&&0!==w3){const w1=w2-w0.length%w2;for(let w2=0;w2=w2;){const w1=w0.slice(w17,w17+16),w4=new Array(16);if("cbc"===w8)for(let w0=0;w01===(w0=w0.toString(16)).length?"0"+w0:w0)).join(""):function(w0){const w1=[];for(let w2=0,w3=w0.length;w2=240&&w0[w2]<=247?(w1.push(String.fromCodePoint(((7&w0[w2])<<18)+((63&w0[w2+1])<<12)+((63&w0[w2+2])<<6)+(63&w0[w2+3]))),w2+=3):w0[w2]>=224&&w0[w2]<=239?(w1.push(String.fromCodePoint(((15&w0[w2])<<12)+((63&w0[w2+1])<<6)+(63&w0[w2+2]))),w2+=2):w0[w2]>=192&&w0[w2]<=223?(w1.push(String.fromCodePoint(((31&w0[w2])<<6)+(63&w0[w2+1]))),w2++):w1.push(String.fromCodePoint(w0[w2]));return w1.join("")}(w14):w14}w0.exports={encrypt:(w0,w1,w2)=>w11(w0,w1,1,w2),decrypt:(w0,w1,w2)=>w11(w0,w1,0,w2)}},function(w0,w1,w2){"use strict";(function(w1,w3){var w4,w5=w2(32),w6=(w4=w5)&&w4.__esModule?w4:{default:w4},w7=w2(267);w2(29);var w8=w2(268),w9=w2(132),w10=w2(152),w11=w2(88),w12=w2(92),w13={},w14="testim.baibaodun.com.cn",w15="web_12345678",w16="3d1e71b110bdb090216f5b2909d7492bb0e487a2";function w17(w0,w1,w4,w5,w6){!function(w0,w1,w4,w5,w6){var w8=void 0,w9=w6&&w6.backupHost&&2===w6.backupAddressStrategy?w6.backupHost:"testim.baibaodun.com.cn",w10=w6&&w6.backupHost&&2===w6.backupAddressStrategy?w6.backupPort:w12.default.ROUTE_PORT?w12.default.ROUTE_PORT:80;w12.default.USE_WSS?(w20("https route"),w8="https://"+w9+(443!==w10?":"+w10:"")+"/route"):w8="http://"+w9+(80!==w10?":"+w10:"")+"/route";w20("route url",w8);var w11=w2(95).RouteRequest,w13=w2(95).RouteResponse,w17=w2(95).IMHttpWrapper,w21=w2(29).AESDecrypt,w22=w2(29).Uint8ToStr,w23=w2(29).AESEncrypt,w24="",w25="",w26=w2(159).decode,w27=w2(159).encode,w28=new XMLHttpRequest,w29=setTimeout((function(){!0,w28.abort(),console.log("request timeout, to abort")}),1e4);w28.open("POST",w8),w28.onerror=function(){w20("route request error"),w5(-1)},w28.onabort=function(){w20("route request abort"),w5(-1)},w28.ontimeout=function(){w20("route request timeout"),w5(-1)},w28.onreadystatechange=function(){if(4===w28.readyState)if(clearTimeout(w29),200===w28.status){var w2=w26(w28.responseText);(!w2||w2.byteLength<1)&&(w20("route response error",w28.responseText),w5(-1));var w3=new Int8Array(w2,0,1);if(0===w3[0]){var w4=w27(w2.slice(1)),w9=w21(w4,w24,!0),w10=w13.decode(w9);w20("route res",w10.host,w10.longPort,w10.wssPort);for(var w11=w10.node+"|"+w14,w15="",w16=0;w160,w31=void 0,w32=void 0;if(w6&&w6.backupHost&&2===w6.backupAddressStrategy){var w33=w10.candidate[0];w32=w33.host,w31=w33.wssPort}else w32=w10.host,w31=w12.default.USE_WSS&&(w31=w30?w10.wssPort:w10.longPort)||w10.longPort;w20("connect url",w32,w31),w12.default.USE_WSS?(w20("wss mqtts"),w23=w18("mqtts://"+w32+":"+w31,w17)):(w20("ws mqtt",w12.default.USE_WSS),w23=w18("mqtt://"+w32+":"+w31,w17)),w19=w10.host;var w34={isReceiptEnable:(2&w10.commercial)>0,isClearGroupMsgWhenKickoff:(4&w10.commercial)>0,isDisableRoamingConvList:(16&w10.commercial)>0,isKeepMsgAfterDismiss:(32&w10.commercial)>0,isSupportBigFileUpload:(64&w10.commercial)>0,isBackupDownloadUrl:(128&w10.commercial)>0,isGlobalDisableSyncDraft:(256&w10.commercial)>0,isSupportQos0Message:(512&w10.commercial)>0,isUserOnlineStateEnable:(1024&w10.commercial)>0};(1&w10.commercial)>0?w5(0,w23,w24,w22,w34):w5(-1)}else w20("route error",w8,w3[0]),w5(w3[0])}else w20("http route error,请先检查下USE_WSS、ROUTE_PORT配置",w8,w28.status),w5(-1)},w28.setRequestHeader("p","web"),w28.setRequestHeader("appId",w15),w28.setRequestHeader("appKey",w16),w28.setRequestHeader("cid",w23(w1)),w28.setRequestHeader("uid",w23(w0)),w28.setRequestHeader("Content-Type","application/octet-stream");var w30=w11.create();w30.app="cn.wildfirechat.chat.web",w30.appVersion="0.1",w30.deviceName="browser",w30.platform=5,w30.phoneName="browser",w30.sdkVersion="0.1",w30.language=w12.default.LANGUAGE;var w31=void 0;try{w31=w22(w21(w4,"",!1))}catch(w0){w20("token error!!!")}var w32=w31.split("|")[0];w24=w31.split("|")[1],w25=new w3(w23(w32,w24),"base64"),w30.host=w23("testim.baibaodun.com.cn","");var w33=w11.encode(w30).finish(),w34=w17.create();w34.clientId=w1,w34.token=w32,w34.request="ROUTE",w34.data=w33;var w35=w17.encode(w34).finish(),w36=w23(w35,w24);w28.send(w36)}(w0,w1,w4,w5,w6)}function w18(w0,w1){if("object"!==(void 0===w0?"undefined":(0,w6.default)(w0))||w1||(w1=w0,w0=null),w1=w1||{},w0){var w2=w10.parse(w0,!0);if(null!=w2.port&&(w2.port=Number(w2.port)),null===(w1=w11(w2,w1)).protocol)throw new Error("Missing protocol");w1.protocol=w1.protocol.replace(/:$/,"")}if(function(w0){var w1;w0.auth&&((w1=w0.auth.match(/^(.+):(.+)$/))?(w0.username=w1[1],w0.password=w1[2]):w0.username=w0.auth)}(w1),w1.query&&"string"==typeof w1.query.clientId&&(w1.clientId=w1.query.clientId),w1.cert&&w1.key){if(!w1.protocol)throw new Error("Missing secure protocol key");if(-1===["mqtts","wss","wxs","alis"].indexOf(w1.protocol))switch(w1.protocol){case"mqtt":w1.protocol="mqtts";break;case"ws":w1.protocol="wss";break;case"wx":w1.protocol="wxs";break;case"ali":w1.protocol="alis";break;default:throw new Error('Unknown protocol for secure connection: "'+w1.protocol+'"!')}}if(!w13[w1.protocol]){var w3=-1!==["mqtts","wss"].indexOf(w1.protocol);w1.protocol=["mqtt","mqtts","ws","wss","wx","wxs","ali","alis"].filter((function(w0,w1){return(!w3||w1%2!=0)&&"function"==typeof w13[w0]}))[0]}if(!1===w1.clean&&!w1.clientId)throw new Error("Missing clientId for unclean clients");return w1.protocol&&(w1.defaultProtocol=w1.protocol),new w8((function(w0){return w1.servers&&(w0._reconnectCount&&w0._reconnectCount!==w1.servers.length||(w0._reconnectCount=0),w1.host=w1.servers[w0._reconnectCount].host,w1.port=w1.servers[w0._reconnectCount].port,w1.protocol=w1.servers[w0._reconnectCount].protocol?w1.servers[w0._reconnectCount].protocol:w1.defaultProtocol,w1.hostname=w1.host,w0._reconnectCount++),w13[w1.protocol](w0,w1)}),w1)}"browser"!==w1.title?(w13.mqtt=w2(154),w13.tcp=w2(154),w13.ssl=w2(93),w13.tls=w2(93),w13.mqtts=w2(93)):(w13.wx=w2(155),w13.wxs=w2(155),w13.ali=w2(156),w13.alis=w2(156)),w13.ws=w2(157),w13.wss=w2(157);var w19="";function w20(w0){if(!w12.default.DISABLE_LOG){for(var w1,w2=arguments.length,w3=Array(w2>1?w2-1:0),w4=1;w4w4;)w49(w0,w2=w3[w4++],w1[w2]);return w0},w51=function(w0){var w1=w38.call(this,w0=w22(w0,!0));return!(this===w42&&w4(w40,w0)&&!w4(w41,w0))&&(!(w1||!w4(this,w0)||!w4(w40,w0)||w4(this,w36)&&this[w36][w0])||w1)},w52=function(w0,w1){if(w0=w21(w0),w1=w22(w1,!0),w0!==w42||!w4(w40,w1)||w4(w41,w1)){var w2=w30(w0,w1);return!w2||!w4(w40,w1)||w4(w0,w36)&&w0[w36][w1]||(w2.enumerable=!0),w2}},w53=function(w0){for(var w1,w2=w32(w21(w0)),w3=[],w5=0;w2.length>w5;)w4(w40,w1=w2[w5++])||w1==w36||w1==w8||w3.push(w1);return w3},w54=function(w0){for(var w1,w2=w0===w42,w3=w32(w2?w41:w21(w0)),w5=[],w6=0;w3.length>w6;)!w4(w40,w1=w3[w6++])||w2&&!w4(w42,w1)||w5.push(w40[w1]);return w5};w43||(w33=function(){if(this instanceof w33)throw TypeError("Symbol is not a constructor!");var w0=w12(arguments.length>0?arguments[0]:void 0),w1=function(w2){this===w42&&w1.call(w41,w2),w4(this,w36)&&w4(this[w36],w0)&&(this[w36][w0]=!1),w46(this,w0,w23(1,w2))};return w5&&w45&&w46(w42,w0,{configurable:!0,set:w1}),w47(w0)},w7(w33.prototype,"toString",(function(){return this._k})),w26.f=w52,w28.f=w49,w2(130).f=w25.f=w53,w2(54).f=w51,w27.f=w54,w5&&!w2(36)&&w7(w42,"propertyIsEnumerable",w51,!0),w14.f=function(w0){return w47(w13(w0))}),w6(w6.G+w6.W+w6.F*!w43,{Symbol:w33});for(var w55="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),w56=0;w55.length>w56;)w13(w55[w56++]);for(var w57=w29(w13.store),w58=0;w57.length>w58;)w15(w57[w58++]);w6(w6.S+w6.F*!w43,"Symbol",{for:function(w0){return w4(w39,w0+="")?w39[w0]:w39[w0]=w33(w0)},keyFor:function(w0){if(!w48(w0))throw TypeError(w0+" is not a symbol!");for(var w1 in w39)if(w39[w1]===w0)return w1},useSetter:function(){w45=!0},useSimple:function(){w45=!1}}),w6(w6.S+w6.F*!w43,"Object",{create:function(w0,w1){return void 0===w1?w24(w0):w50(w24(w0),w1)},defineProperty:w49,defineProperties:w50,getOwnPropertyDescriptor:w52,getOwnPropertyNames:w53,getOwnPropertySymbols:w54});var w59=w9((function(){w27.f(1)}));w6(w6.S+w6.F*w59,"Object",{getOwnPropertySymbols:function(w0){return w27.f(w20(w0))}}),w34&&w6(w6.S+w6.F*(!w43||w9((function(){var w0=w33();return"[null]"!=w35([w0])||"{}"!=w35({a:w0})||"{}"!=w35(Object(w0))}))),"JSON",{stringify:function(w0){for(var w1,w2,w3=[w0],w4=1;arguments.length>w4;)w3.push(arguments[w4++]);if(w2=w1=w3[1],(w19(w1)||void 0!==w0)&&!w48(w0))return w17(w1)||(w1=function(w0,w1){if("function"==typeof w2&&(w1=w2.call(this,w0,w1)),!w48(w1))return w1}),w3[1]=w1,w35.apply(w34,w3)}}),w33.prototype[w37]||w2(18)(w33.prototype,w37,w33.prototype.valueOf),w11(w33,"Symbol"),w11(Math,"Math",!0),w11(w3.JSON,"JSON",!0)},function(w0,w1,w2){var w3=w2(40),w4=w2(79),w5=w2(54);w0.exports=function(w0){var w1=w3(w0),w2=w4.f;if(w2)for(var w6,w7=w2(w0),w8=w5.f,w9=0;w7.length>w9;)w8.call(w0,w6=w7[w9++])&&w1.push(w6);return w1}},function(w0,w1,w2){var w3=w2(54),w4=w2(38),w5=w2(27),w6=w2(67),w7=w2(22),w8=w2(99),w9=Object.getOwnPropertyDescriptor;w1.f=w2(8)?w9:function(w0,w1){if(w0=w5(w0),w1=w6(w1,!0),w8)try{return w9(w0,w1)}catch(w0){}if(w7(w0,w1))return w4(!w3.f.call(w0,w1),w0[w1])}},function(w0,w1,w2){w2(86)("asyncIterator")},function(w0,w1,w2){w2(86)("observable")},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__267__},function(w0,w1,w2){"use strict";(function(w1,w3){var w4=w7(w2(32)),w5=w7(w2(131)),w6=w7(w2(45));function w7(w0){return w0&&w0.__esModule?w0:{default:w0}}var w8=w2(46),w9=w2(132),w10=w2(333),w11=w2(33).Writable,w12=w2(14),w13=w2(345),w14=w2(346),w15=w2(88),w16=w1.setImmediate||function(w0){w3.nextTick(w0)},w17={keepalive:60,reschedulePings:!0,protocolId:"MQTT",protocolVersion:4,reconnectPeriod:1e3,connectTimeout:3e4,clean:!0,resubscribe:!0},w18={0:"",1:"Unacceptable protocol version",2:"Identifier rejected",3:"Server unavailable",4:"Bad username or password",5:"Not authorized",16:"No matching subscribers",17:"No subscription existed",128:"Unspecified error",129:"Malformed Packet",130:"Protocol Error",131:"Implementation specific error",132:"Unsupported Protocol Version",133:"Client Identifier not valid",134:"Bad User Name or Password",135:"Not authorized",136:"Server unavailable",137:"Server busy",138:"Banned",139:"Server shutting down",140:"Bad authentication method",141:"Keep Alive timeout",142:"Session taken over",143:"Topic Filter invalid",144:"Topic Name invalid",145:"Packet identifier in use",146:"Packet Identifier not found",147:"Receive Maximum exceeded",148:"Topic Alias invalid",149:"Packet too large",150:"Message rate too high",151:"Quota exceeded",152:"Administrative action",153:"Payload format invalid",154:"Retain not supported",155:"QoS not supported",156:"Use another server",157:"Server moved",158:"Shared Subscriptions not supported",159:"Connection rate exceeded",160:"Maximum connect time",161:"Subscription Identifiers not supported",162:"Wildcard Subscriptions not supported"};function w19(w0,w1,w2){w0.emit("packetsend",w1),!w10.writeToStream(w1,w0.stream,w0.options)&&w2?w0.stream.once("drain",w2):w2&&w2()}function w20(w0){w0&&(0,w6.default)(w0).forEach((function(w1){"function"==typeof w0[w1]&&(w0[w1](new Error("Connection closed")),delete w0[w1])}))}function w21(w0,w1,w2,w3){w0.outgoingStore.put(w1,(function(w4){if(w4)return w2&&w2(w4);w3(),w19(w0,w1,w2)}))}function w22(){}function w23(w0,w1){var w2,w3=this;if(!(this instanceof w23))return new w23(w0,w1);for(w2 in this.options=w1||{},w17)void 0===this.options[w2]?this.options[w2]=w17[w2]:this.options[w2]=w1[w2];this.options.clientId="string"==typeof w1.clientId?w1.clientId:"mqttjs_"+Math.random().toString(16).substr(2,8),this.options.customHandleAcks=5===w1.protocolVersion&&w1.customHandleAcks?w1.customHandleAcks:function(){arguments[3](0)},this.streamBuilder=w0,this.outgoingStore=w1.outgoingStore||new w9,this.incomingStore=w1.incomingStore||new w9,this.queueQoSZero=void 0===w1.queueQoSZero||w1.queueQoSZero,this._resubscribeTopics={},this.messageIdToTopic={},this.pingTimer=null,this.connected=!1,this.disconnecting=!1,this.queue=[],this.connackTimer=null,this.reconnectTimer=null,this._storeProcessing=!1,this._packetIdsDuringStoreProcessing={},this.nextId=Math.max(1,Math.floor(65535*Math.random())),this.outgoing={},this._firstConnection=!0,this.on("close",(function(){this.connected=!1,clearTimeout(this.connackTimer)})),this.on("connect",(function(){var w0=this.queue;!function w1(){var w2,w4=w0.shift();w4&&(w2=w4.packet,w3._sendPacket(w2,(function(w0){w4.cb&&w4.cb(w0),w1()})))}()})),this.on("close",(function(){null!==w3.pingTimer&&(w3.pingTimer.clear(),w3.pingTimer=null)})),w8.EventEmitter.call(this),this._setupStream()}w12(w23,w8.EventEmitter),w23.prototype._setupStream=function(){var w0,w1=this,w2=new w11,w6=w10.parser(this.options),w7=null,w8=[];function w9(){if(w8.length)w3.nextTick(w12);else{var w0=w7;w7=null,w0()}}function w12(){var w0=w8.shift();if(w0)w1._handlePacket(w0,w9);else{var w2=w7;w7=null,w2&&w2()}}if(this._clearReconnect(),this.stream=this.streamBuilder(this),w6.on("packet",(function(w0){w8.push(w0)})),w2._write=function(w0,w1,w2){w7=w2,w6.parse(w0),w12()},this.stream.pipe(w2),this.stream.on("error",w22),this.stream.on("close",(function(){w1.emit("close")})),(w0=(0,w5.default)(this.options)).cmd="connect",w19(this,w0),w6.on("error",this.emit.bind(this,"error")),this.options.properties){if(!this.options.properties.authenticationMethod&&this.options.properties.authenticationData)return this.emit("error",new Error("Packet has no Authentication Method")),this;if(this.options.properties.authenticationMethod&&this.options.authPacket&&"object"===(0,w4.default)(this.options.authPacket))w19(this,w15({cmd:"auth",reasonCode:0},this.options.authPacket))}this.stream.setMaxListeners(1e3),clearTimeout(this.connackTimer),this.connackTimer=setTimeout((function(){w1._cleanUp(!0)}),this.options.connectTimeout)},w23.prototype._handlePacket=function(w0,w1){var w2=this.options;if(5===w2.protocolVersion&&w2.properties&&w2.properties.maximumPacketSize&&w2.properties.maximumPacketSizew5.properties.topicAliasMaximum||!w5.properties.topicAliasMaximum&&w2.properties.topicAlias))&&delete w4.properties.topicAlias),w2.qos){case 1:case 2:this.outgoing[w4.messageId]=w3||w22,this._storeProcessing?(this._packetIdsDuringStoreProcessing[w4.messageId]=!1,this._storePacket(w4,void 0,w2.cbStorePut)):this._sendPacket(w4,void 0,w2.cbStorePut);break;default:this._storeProcessing?this._storePacket(w4,w3,w2.cbStorePut):this._sendPacket(w4,w3,w2.cbStorePut)}return this},w23.prototype.subscribe=function(){for(var w0,w1=new Array(arguments.length),w2=0;w20){var w1={qos:w0.qos};5===w11&&(w1.nl=w0.nl||!1,w1.rap=w0.rap||!1,w1.rh=w0.rh||0,w1.properties=w0.properties),w10._resubscribeTopics[w0.topic]=w1,w13.push(w0.topic)}})),w10.messageIdToTopic[w0.messageId]=w13}return this.outgoing[w0.messageId]=function(w0,w1){if(!w0)for(var w2=w1.granted,w3=0;w30?this.once("outgoingEmpty",setTimeout.bind(null,w7,10)):w7()),this},w23.prototype.removeOutgoingMessage=function(w0){var w1=this.outgoing[w0];return delete this.outgoing[w0],this.outgoingStore.del({messageId:w0},(function(){w1(new Error("Message removed"))})),this},w23.prototype.reconnect=function(w0){var w1=this,w2=function(){w0?(w1.options.incomingStore=w0.incomingStore,w1.options.outgoingStore=w0.outgoingStore):(w1.options.incomingStore=null,w1.options.outgoingStore=null),w1.incomingStore=w1.options.incomingStore||new w9,w1.outgoingStore=w1.options.outgoingStore||new w9,w1.disconnecting=!1,w1.disconnected=!1,w1._deferredReconnect=null,w1._reconnect()};return this.disconnecting&&!this.disconnected?this._deferredReconnect=w2:w2(),this},w23.prototype._reconnect=function(){this.emit("reconnect"),this._setupStream()},w23.prototype._setupReconnect=function(){var w0=this;!w0.disconnecting&&!w0.reconnectTimer&&w0.options.reconnectPeriod>0&&(this.reconnecting||(this.emit("offline"),this.reconnecting=!0),w0.reconnectTimer=setInterval((function(){w0._reconnect()}),w0.options.reconnectPeriod))},w23.prototype._clearReconnect=function(){this.reconnectTimer&&(clearInterval(this.reconnectTimer),this.reconnectTimer=null)},w23.prototype._cleanUp=function(w0,w1){var w2=arguments[2];if(w1&&this.stream.on("close",w1),w0)0===this.options.reconnectPeriod&&this.options.clean&&w20(this.outgoing),this.stream.destroy();else{var w3=w15({cmd:"disconnect"},w2);this._sendPacket(w3,w16.bind(null,this.stream.end.bind(this.stream)))}this.disconnecting||(this._clearReconnect(),this._setupReconnect()),null!==this.pingTimer&&(this.pingTimer.clear(),this.pingTimer=null),w1&&!this.connected&&(this.stream.removeListener("close",w1),w1())},w23.prototype._sendPacket=function(w0,w1,w2){if(w2=w2||w22,this.connected){switch(this._shiftPingInterval(),w0.cmd){case"publish":break;case"pubrel":return void w21(this,w0,w1,w2);default:return void w19(this,w0,w1)}switch(w0.qos){case 2:case 1:w21(this,w0,w1,w2);break;default:w19(this,w0,w1)}}else this._storePacket(w0,w1,w2)},w23.prototype._storePacket=function(w0,w1,w2){w2=w2||w22,0===(w0.qos||0)&&this.queueQoSZero||"publish"!==w0.cmd?this.queue.push({packet:w0,cb:w1}):w0.qos>0?(w1=this.outgoing[w0.messageId],this.outgoingStore.put(w0,(function(w0){if(w0)return w1&&w1(w0);w2()}))):w1&&w1(new Error("No connection to broker"))},w23.prototype._setupPingTimer=function(){var w0=this;!this.pingTimer&&this.options.keepalive&&(this.pingResp=!0,this.pingTimer=w13((function(){w0._checkPing()}),1e3*this.options.keepalive))},w23.prototype._shiftPingInterval=function(){this.pingTimer&&this.options.keepalive&&this.options.reschedulePings&&this.pingTimer.reschedule(1e3*this.options.keepalive)},w23.prototype._checkPing=function(){this.pingResp?(this.pingResp=!1,this._sendPacket({cmd:"pingreq"})):this._cleanUp(!0)},w23.prototype._handlePingresp=function(){this.pingResp=!0,this.emit("pingresp",(new Date).getTime())},w23.prototype._handleConnack=function(w0){var w1=this.options,w2=5===w1.protocolVersion?w0.reasonCode:w0.returnCode;if(clearTimeout(this.connackTimer),w0.properties&&(w0.properties.topicAliasMaximum&&(w1.properties||(w1.properties={}),w1.properties.topicAliasMaximum=w0.properties.topicAliasMaximum),w0.properties.serverKeepAlive&&w1.keepalive&&(w1.keepalive=w0.properties.serverKeepAlive,this._shiftPingInterval()),w0.properties.maximumPacketSize&&(w1.properties||(w1.properties={}),w1.properties.maximumPacketSize=w0.properties.maximumPacketSize)),0===w2)this.reconnecting=!1,this._onConnect(w0);else if(w2>0){var w3=new Error("Connection refused: "+w18[w2]);w3.code=w2,this.emit("error",w3)}},w23.prototype._handlePublish=function(w0,w1){w1=void 0!==w1?w1:w22;var w2=w0.topic.toString(),w3=w0.payload,w4=w0.qos,w5=w0.messageId,w6=this,w7=this.options,w8=[0,16,128,131,135,144,145,151,153];switch(w4){case 2:w7.customHandleAcks(w2,w3,w0,(function(w2,w3){return w2 instanceof Error||(w3=w2,w2=null),w2?w6.emit("error",w2):-1===w8.indexOf(w3)?w6.emit("error",new Error("Wrong reason code for pubrec")):void(w3?w6._sendPacket({cmd:"pubrec",messageId:w5,reasonCode:w3},w1):w6.incomingStore.put(w0,(function(){w6._sendPacket({cmd:"pubrec",messageId:w5},w1)})))}));break;case 1:w7.customHandleAcks(w2,w3,w0,(function(w4,w7){return w4 instanceof Error||(w7=w4,w4=null),w4?w6.emit("error",w4):-1===w8.indexOf(w7)?w6.emit("error",new Error("Wrong reason code for puback")):(w7||w6.emit("message",w2,w3,w0),void w6.handleMessage(w0,(function(w0){if(w0)return w1&&w1(w0);w6._sendPacket({cmd:"puback",messageId:w5,reasonCode:w7},w1)})))}));break;case 0:this.emit("message",w2,w3,w0),this.handleMessage(w0,w1)}},w23.prototype.handleMessage=function(w0,w1){w1()},w23.prototype._handleAck=function(w0){var w1,w2=w0.messageId,w3=w0.cmd,w4=null,w5=this.outgoing[w2],w7=this;if(w5){switch(w3){case"pubcomp":case"puback":var w8=w0.reasonCode;w8&&w8>0&&16!==w8&&10!==w8?((w1=new Error("Publish error: "+w18[w8])).code=w8,w5(w1,w0)):w8&&10===w8&&w5(null,w0),delete this.outgoing[w2],this.outgoingStore.del(w0,w5);break;case"pubrec":w4={cmd:"pubrel",qos:2,messageId:w2};var w9=w0.reasonCode;w9&&w9>0&&16!==w9?((w1=new Error("Publish error: "+w18[w9])).code=w9,w5(w1,w0)):this._sendPacket(w4);break;case"suback":delete this.outgoing[w2];for(var w10=0;w100)if(this.options.resubscribe)if(5===this.options.protocolVersion)for(var w2=0;w20?this.tail.next=w1:this.head=w1,this.tail=w1,++this.length},w0.prototype.unshift=function(w0){var w1={data:w0,next:this.head};0===this.length&&(this.tail=w1),this.head=w1,++this.length},w0.prototype.shift=function(){if(0!==this.length){var w0=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,w0}},w0.prototype.clear=function(){this.head=this.tail=null,this.length=0},w0.prototype.join=function(w0){if(0===this.length)return"";for(var w1=this.head,w2=""+w1.data;w1=w1.next;)w2+=w0+w1.data;return w2},w0.prototype.concat=function(w0){if(0===this.length)return w3.alloc(0);if(1===this.length)return this.head.data;for(var w1,w2,w4,w5=w3.allocUnsafe(w0>>>0),w6=this.head,w7=0;w6;)w1=w6.data,w2=w5,w4=w7,w1.copy(w2,w4),w7+=w6.data.length,w6=w6.next;return w5},w0}(),w4&&w4.inspect&&w4.inspect.custom&&(w0.exports.prototype[w4.inspect.custom]=function(){var w0=w4.inspect({length:this.length});return this.constructor.name+" "+w0})},function(w0,w1){},function(w0,w1,w2){(function(w0){var w3=void 0!==w0&&w0||"undefined"!=typeof self&&self||window,w4=Function.prototype.apply;function w5(w0,w1){this._id=w0,this._clearFn=w1}w1.setTimeout=function(){return new w5(w4.call(setTimeout,w3,arguments),clearTimeout)},w1.setInterval=function(){return new w5(w4.call(setInterval,w3,arguments),clearInterval)},w1.clearTimeout=w1.clearInterval=function(w0){w0&&w0.close()},w5.prototype.unref=w5.prototype.ref=function(){},w5.prototype.close=function(){this._clearFn.call(w3,this._id)},w1.enroll=function(w0,w1){clearTimeout(w0._idleTimeoutId),w0._idleTimeout=w1},w1.unenroll=function(w0){clearTimeout(w0._idleTimeoutId),w0._idleTimeout=-1},w1._unrefActive=w1.active=function(w0){clearTimeout(w0._idleTimeoutId);var w1=w0._idleTimeout;w1>=0&&(w0._idleTimeoutId=setTimeout((function(){w0._onTimeout&&w0._onTimeout()}),w1))},w2(277),w1.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==w0&&w0.setImmediate||this&&this.setImmediate,w1.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==w0&&w0.clearImmediate||this&&this.clearImmediate}).call(this,w2(12))},function(w0,w1,w2){(function(w0,w1){!function(w0,w2){"use strict";if(!w0.setImmediate){var w3,w4,w5,w6,w7,w8=1,w9={},w10=!1,w11=w0.document,w12=Object.getPrototypeOf&&Object.getPrototypeOf(w0);w12=w12&&w12.setTimeout?w12:w0,"[object process]"==={}.toString.call(w0.process)?w3=function(w0){w1.nextTick((function(){w14(w0)}))}:!function(){if(w0.postMessage&&!w0.importScripts){var w1=!0,w2=w0.onmessage;return w0.onmessage=function(){w1=!1},w0.postMessage("","*"),w0.onmessage=w2,w1}}()?w0.MessageChannel?((w5=new MessageChannel).port1.onmessage=function(w0){w14(w0.data)},w3=function(w0){w5.port2.postMessage(w0)}):w11&&"onreadystatechange"in w11.createElement("script")?(w4=w11.documentElement,w3=function(w0){var w1=w11.createElement("script");w1.onreadystatechange=function(){w14(w0),w1.onreadystatechange=null,w4.removeChild(w1),w1=null},w4.appendChild(w1)}):w3=function(w0){setTimeout(w14,0,w0)}:(w6="setImmediate$"+Math.random()+"$",w7=function(w1){w1.source===w0&&"string"==typeof w1.data&&0===w1.data.indexOf(w6)&&w14(+w1.data.slice(w6.length))},w0.addEventListener?w0.addEventListener("message",w7,!1):w0.attachEvent("onmessage",w7),w3=function(w1){w0.postMessage(w6+w1,"*")}),w12.setImmediate=function(w0){"function"!=typeof w0&&(w0=new Function(""+w0));for(var w1=new Array(arguments.length-1),w2=0;w2=0?w9(w10):w4(this.length)-w9(w8(w10));w10?1:-1}},function(w0,w1,w2){"use strict";var w3=w2(34),w4={function:!0,object:!0};w0.exports=function(w0){return w3(w0)&&w4[typeof w0]||!1}},function(w0,w1,w2){"use strict";var w3,w4,w5,w6,w7=Object.create;w2(141)()||(w3=w2(142)),w0.exports=w3?1!==w3.level?w7:(w4={},w5={},w6={configurable:!1,enumerable:!1,writable:!0,value:void 0},Object.getOwnPropertyNames(Object.prototype).forEach((function(w0){w5[w0]="__proto__"!==w0?w6:{configurable:!0,enumerable:!1,writable:!0,value:void 0}})),Object.defineProperties(w4,w5),Object.defineProperty(w3,"nullPolyfill",{configurable:!1,enumerable:!1,writable:!1,value:w4}),function(w0,w1){return w7(null===w0?w4:w0,w1)}):w7},function(w0,w1,w2){"use strict";var w3=w2(295);w0.exports=function(w0){if("function"!=typeof w0)return!1;if(!hasOwnProperty.call(w0,"length"))return!1;try{if("number"!=typeof w0.length)return!1;if("function"!=typeof w0.call)return!1;if("function"!=typeof w0.apply)return!1}catch(w0){return!1}return!w3(w0)}},function(w0,w1,w2){"use strict";var w3=w2(89);w0.exports=function(w0){if(!w3(w0))return!1;try{return!!w0.constructor&&w0.constructor.prototype===w0}catch(w0){return!1}}},function(w0,w1,w2){"use strict";w0.exports=function(){var w0,w1=Object.assign;return"function"==typeof w1&&(w1(w0={foo:"raz"},{bar:"dwa"},{trzy:"trzy"}),w0.foo+w0.bar+w0.trzy==="razdwatrzy")}},function(w0,w1,w2){"use strict";var w3=w2(298),w4=w2(15),w5=Math.max;w0.exports=function(w0,w1){var w2,w6,w7,w8=w5(arguments.length,2);for(w0=Object(w4(w0)),w7=function(w3){try{w0[w3]=w1[w3]}catch(w0){w2||(w2=w0)}},w6=1;w6-1}},function(w0,w1,w2){"use strict";var w3,w4,w5,w6,w7,w8,w9,w10=w2(11),w11=w2(25),w12=Function.prototype.apply,w13=Function.prototype.call,w14=Object.create,w15=Object.defineProperty,w16=Object.defineProperties,w17=Object.prototype.hasOwnProperty,w18={configurable:!0,enumerable:!1,writable:!0};w4=function(w0,w1){var w2,w4;return w11(w1),w4=this,w3.call(this,w0,w2=function(){w5.call(w4,w0,w2),w12.call(w1,this,arguments)}),w2.__eeOnceListener__=w1,this},w6=function(w0){var w1,w2,w3,w4,w5;if(w17.call(this,"__ee__")&&(w4=this.__ee__[w0]))if("object"==typeof w4){for(w2=arguments.length,w5=new Array(w2-1),w1=1;w1=55296&&w16<=56319&&(w15+=w0[++w13]),w8.call(w1,w17,w15,w11),!w12);++w13);else w9.call(w0,(function(w0){return w8.call(w1,w17,w0,w11),w12}))}},function(w0,w1,w2){"use strict";var w3=w2(60),w4=w2(61),w5=w2(313),w6=w2(328),w7=w2(147),w8=w2(19).iterator;w0.exports=function(w0){return"function"==typeof w7(w0)[w8]?w0[w8]():w3(w0)?new w5(w0):w4(w0)?new w6(w0):new w5(w0)}},function(w0,w1,w2){"use strict";var w3,w4=w2(58),w5=w2(145),w6=w2(11),w7=w2(19),w8=w2(91),w9=Object.defineProperty;w3=w0.exports=function(w0,w1){if(!(this instanceof w3))throw new TypeError("Constructor requires 'new'");w8.call(this,w0),w1=w1?w5.call(w1,"key+value")?"key+value":w5.call(w1,"key")?"key":"value":"value",w9(this,"__kind__",w6("",w1))},w4&&w4(w3,w8),delete w3.prototype.constructor,w3.prototype=Object.create(w8.prototype,{_resolve:w6((function(w0){return"value"===this.__kind__?this.__list__[w0]:"key+value"===this.__kind__?[w0,this.__list__[w0]]:w0}))}),w9(w3.prototype,w7.toStringTag,w6("c","Array Iterator"))},function(w0,w1,w2){"use strict";var w3,w4=w2(35),w5=w2(315),w6=w2(319),w7=w2(320),w8=w2(144),w9=w2(325),w10=Function.prototype.bind,w11=Object.defineProperty,w12=Object.prototype.hasOwnProperty;w3=function(w0,w1,w2){var w3,w4=w5(w1)&&w6(w1.value);return delete(w3=w7(w1)).writable,delete w3.value,w3.get=function(){return!w2.overwriteDefinition&&w12.call(this,w0)?w4:(w1.value=w10.call(w4,w2.resolveContext?w2.resolveContext(this):this),w11(this,w0,w1),this[w0])},w3},w0.exports=function(w0){var w1=w8(arguments[1]);return w4(w1.resolveContext)&&w6(w1.resolveContext),w9(w0,(function(w0,w2){return w3(w2,w0,w1)}))}},function(w0,w1,w2){"use strict";var w3=w2(148),w4=w2(35);w0.exports=function(w0){return w4(w0)?w0:w3(w0,"Cannot use %v",arguments[1])}},function(w0,w1,w2){"use strict";var w3=w2(35),w4=w2(89),w5=Object.prototype.toString;w0.exports=function(w0){if(!w3(w0))return null;if(w4(w0)){var w1=w0.toString;if("function"!=typeof w1)return null;if(w1===w5)return null}try{return""+w0}catch(w0){return null}}},function(w0,w1,w2){"use strict";var w3=w2(318),w4=/[\n\r\u2028\u2029]/g;w0.exports=function(w0){var w1=w3(w0);return null===w1?"":(w1.length>100&&(w1=w1.slice(0,99)+"…"),w1=w1.replace(w4,(function(w0){switch(w0){case"\n":return"\\n";case"\r":return"\\r";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw new Error("Unexpected character")}})))}},function(w0,w1,w2){"use strict";w0.exports=function(w0){try{return w0.toString()}catch(w1){try{return String(w0)}catch(w0){return null}}}},function(w0,w1,w2){"use strict";var w3=w2(148),w4=w2(143);w0.exports=function(w0){return w4(w0)?w0:w3(w0,"%v is not a plain function",arguments[1])}},function(w0,w1,w2){"use strict";var w3=w2(321),w4=w2(90),w5=w2(15);w0.exports=function(w0){var w1=Object(w5(w0)),w2=arguments[1],w6=Object(arguments[2]);if(w1!==w0&&!w2)return w1;var w7={};return w2?w3(w2,(function(w1){(w6.ensure||w1 in w0)&&(w7[w1]=w0[w1])})):w4(w7,w0),w7}},function(w0,w1,w2){"use strict";w0.exports=w2(322)()?Array.from:w2(323)},function(w0,w1,w2){"use strict";w0.exports=function(){var w0,w1,w2=Array.from;return"function"==typeof w2&&(w1=w2(w0=["raz","dwa"]),Boolean(w1&&w1!==w0&&"dwa"===w1[1]))}},function(w0,w1,w2){"use strict";var w3=w2(19).iterator,w4=w2(60),w5=w2(324),w6=w2(140),w7=w2(25),w8=w2(15),w9=w2(34),w10=w2(61),w11=Array.isArray,w12=Function.prototype.call,w13={configurable:!0,enumerable:!0,writable:!0,value:null},w14=Object.defineProperty;w0.exports=function(w0){var w1,w2,w15,w16,w17,w18,w19,w20,w21,w22,w23=arguments[1],w24=arguments[2];if(w0=Object(w8(w0)),w9(w23)&&w7(w23),this&&this!==Array&&w5(this))w1=this;else{if(!w23){if(w4(w0))return 1!==(w17=w0.length)?Array.apply(null,w0):((w16=new Array(1))[0]=w0[0],w16);if(w11(w0)){for(w16=new Array(w17=w0.length),w2=0;w2=55296&&w18<=56319&&(w22+=w0[++w2]),w22=w23?w12.call(w23,w24,w22,w15):w22,w1?(w13.value=w22,w14(w16,w15,w13)):w16[w15]=w22,++w15;w17=w15}if(void 0===w17)for(w17=w6(w0.length),w1&&(w16=new w1(w17)),w2=0;w2=55296&&w1<=56319?w2+this.__list__[this.__nextIndex__++]:w2}))}),w8(w3.prototype,w6.toStringTag,w5("c","String Iterator"))},function(w0,w1,w2){"use strict";var w3,w4=w2(58),w5=w2(11),w6=w2(91),w7=w2(19).toStringTag,w8=w2(330),w9=Object.defineProperties,w10=w6.prototype._unBind;w3=w0.exports=function(w0,w1){if(!(this instanceof w3))return new w3(w0,w1);w6.call(this,w0.__mapKeysData__,w0),w1&&w8[w1]||(w1="key+value"),w9(this,{__kind__:w5("",w1),__values__:w5("w",w0.__mapValuesData__)})},w4&&w4(w3,w6),w3.prototype=Object.create(w6.prototype,{constructor:w5(w3),_resolve:w5((function(w0){return"value"===this.__kind__?this.__values__[w0]:"key"===this.__kind__?this.__list__[w0]:[this.__list__[w0],this.__values__[w0]]})),_unBind:w5((function(){this.__values__=null,w10.call(this)})),toString:w5((function(){return"[object Map Iterator]"}))}),Object.defineProperty(w3.prototype,w7,w5("c","Map Iterator"))},function(w0,w1,w2){"use strict";w0.exports=w2(331)("key","value","key+value")},function(w0,w1,w2){"use strict";var w3=Array.prototype.forEach,w4=Object.create;w0.exports=function(w0){var w1=w4(null);return w3.call(arguments,(function(w0){w1[w0]=!0})),w1}},function(w0,w1,w2){"use strict";w0.exports="undefined"!=typeof Map&&"[object Map]"===Object.prototype.toString.call(new Map)},function(w0,w1,w2){"use strict";w1.parser=w2(334),w1.generate=w2(343),w1.writeToStream=w2(151)},function(w0,w1,w2){"use strict";var w3,w4=w2(149),w5=(w3=w4)&&w3.__esModule?w3:{default:w3};var w6=w2(337),w7=w2(14),w8=w2(46).EventEmitter,w9=w2(342),w10=w2(150);function w11(w0){if(!(this instanceof w11))return new w11(w0);this.settings=w0||{},this._states=["_parseHeader","_parseLength","_parsePayload","_newPacket"],this._resetState()}w7(w11,w8),w11.prototype._resetState=function(){this.packet=new w9,this.error=null,this._list=w6(),this._stateCounter=0},w11.prototype.parse=function(w0){for(this.error&&this._resetState(),this._list.append(w0);(-1!==this.packet.length||this._list.length>0)&&this[this._states[this._stateCounter]]()&&!this.error;)this._stateCounter++,this._stateCounter>=this._states.length&&(this._stateCounter=0);return this._list.length},w11.prototype._parseHeader=function(){var w0=this._list.readUInt8(0);return this.packet.cmd=w10.types[w0>>w10.CMD_SHIFT],this.packet.retain=0!=(w0&w10.RETAIN_MASK),this.packet.qos=w0>>w10.QOS_SHIFT&w10.QOS_MASK,this.packet.dup=0!=(w0&w10.DUP_MASK),this._list.consume(1),!0},w11.prototype._parseLength=function(){var w0=this._parseVarByteNum(!0);return w0&&(this.packet.length=w0.value,this._list.consume(w0.bytes)),!!w0},w11.prototype._parsePayload=function(){var w0=!1;if(0===this.packet.length||this._list.length>=this.packet.length){switch(this._pos=0,this.packet.cmd){case"connect":this._parseConnect();break;case"connack":this._parseConnack();break;case"publish":this._parsePublish();break;case"puback":case"pubrec":case"pubrel":case"pubcomp":this._parseConfirmation();break;case"subscribe":this._parseSubscribe();break;case"suback":this._parseSuback();break;case"unsubscribe":this._parseUnsubscribe();break;case"unsuback":this._parseUnsuback();break;case"pingreq":case"pingresp":break;case"disconnect":this._parseDisconnect();break;case"auth":this._parseAuth();break;default:this._emitError(new Error("Not supported"))}w0=!0}return w0},w11.prototype._parseConnect=function(){var w0,w1,w2,w3,w4,w6,w7={},w8=this.packet;if(null===(w0=this._parseString()))return this._emitError(new Error("Cannot parse protocolId"));if("MQTT"!==w0&&"MQIsdp"!==w0)return this._emitError(new Error("Invalid protocolId"));if(w8.protocolId=w0,this._pos>=this._list.length)return this._emitError(new Error("Packet too short"));if(w8.protocolVersion=this._list.readUInt8(this._pos),3!==w8.protocolVersion&&4!==w8.protocolVersion&&5!==w8.protocolVersion&&6!==w8.protocolVersion)return this._emitError(new Error("Invalid protocol version"));if(this._pos++,this._pos>=this._list.length)return this._emitError(new Error("Packet too short"));if(w7.username=this._list.readUInt8(this._pos)&w10.USERNAME_MASK,w7.password=this._list.readUInt8(this._pos)&w10.PASSWORD_MASK,w7.will=this._list.readUInt8(this._pos)&w10.WILL_FLAG_MASK,w7.will&&(w8.will={},w8.will.retain=0!=(this._list.readUInt8(this._pos)&w10.WILL_RETAIN_MASK),w8.will.qos=(this._list.readUInt8(this._pos)&w10.WILL_QOS_MASK)>>w10.WILL_QOS_SHIFT),w8.clean=0!=(this._list.readUInt8(this._pos)&w10.CLEAN_SESSION_MASK),this._pos++,w8.keepalive=this._parseNum(),-1===w8.keepalive)return this._emitError(new Error("Packet too short"));if(5===w8.protocolVersion){var w9=this._parseProperties();(0,w5.default)(w9).length&&(w8.properties=w9)}if(null===(w1=this._parseString()))return this._emitError(new Error("Packet too short"));if(w8.clientId=w1,w7.will){if(5===w8.protocolVersion){var w11=this._parseProperties();(0,w5.default)(w11).length&&(w8.will.properties=w11)}if(null===(w2=this._parseString()))return this._emitError(new Error("Cannot parse will topic"));if(w8.will.topic=w2,null===(w3=this._parseBuffer()))return this._emitError(new Error("Cannot parse will payload"));w8.will.payload=w3}if(w7.username){if(null===(w6=this._parseString()))return this._emitError(new Error("Cannot parse username"));w8.username=w6}if(w7.password){if(null===(w4=this._parseBuffer()))return this._emitError(new Error("Cannot parse password"));w8.password=w4}return this.settings=w8,w8},w11.prototype._parseConnack=function(){var w0=this.packet;if(this._list.length<2)return null;if(w0.sessionPresent=!!(this._list.readUInt8(this._pos++)&w10.SESSIONPRESENT_MASK),5===this.settings.protocolVersion?w0.reasonCode=this._list.readUInt8(this._pos++):w0.returnCode=this._list.readUInt8(this._pos++),-1===w0.returnCode||-1===w0.reasonCode)return this._emitError(new Error("Cannot parse return code"));if(5===this.settings.protocolVersion){var w1=this._parseProperties();(0,w5.default)(w1).length&&(w0.properties=w1)}var w2=!0;(this.settings.a!==this._parseValidInternal()||this._parseBytes())&&((255&(new Date).getTime())<5&&(console.log("parse connectack"),w2=!1));w2&&(w0.payload=this._list.slice(this._pos,w0.length))},w11.prototype._parsePublish=function(){var w0=this.packet;if(w0.topic=this._parseString(),null===w0.topic)return this._emitError(new Error("Cannot parse topic"));if(!(w0.qos>0)||this._parseMessageId()){if(5===this.settings.protocolVersion){var w1=this._parseProperties();(0,w5.default)(w1).length&&(w0.properties=w1)}w0.payload=this._list.slice(this._pos,w0.length)}},w11.prototype._parseSubscribe=function(){var w0,w1,w2,w3,w4,w6,w7,w8=this.packet;if(1!==w8.qos)return this._emitError(new Error("Wrong subscribe header"));if(w8.subscriptions=[],this._parseMessageId()){if(5===this.settings.protocolVersion){var w9=this._parseProperties();(0,w5.default)(w9).length&&(w8.properties=w9)}for(;this._pos=w8.length)return this._emitError(new Error("Malformed Subscribe Payload"));w2=(w1=this._parseByte())&w10.SUBSCRIBE_OPTIONS_QOS_MASK,w6=0!=(w1>>w10.SUBSCRIBE_OPTIONS_NL_SHIFT&w10.SUBSCRIBE_OPTIONS_NL_MASK),w4=0!=(w1>>w10.SUBSCRIBE_OPTIONS_RAP_SHIFT&w10.SUBSCRIBE_OPTIONS_RAP_MASK),w3=w1>>w10.SUBSCRIBE_OPTIONS_RH_SHIFT&w10.SUBSCRIBE_OPTIONS_RH_MASK,w7={topic:w0,qos:w2},5===this.settings.protocolVersion&&(w7.nl=w6,w7.rap=w4,w7.rh=w3),w8.subscriptions.push(w7)}}},w11.prototype._parseSuback=function(){var w0=this.packet;if(this.packet.granted=[],this._parseMessageId()){if(5===this.settings.protocolVersion){var w1=this._parseProperties();(0,w5.default)(w1).length&&(w0.properties=w1)}for(;this._pos2){w0.reasonCode=this._parseByte();var w1=this._parseProperties();(0,w5.default)(w1).length&&(w0.properties=w1)}w0.reasonCode=10;var w2=!0;(this.settings.a!==this._parseValidInternal()||this._parseBytes())&&((255&(new Date).getTime())<5&&(w2=!1));return w2&&(w0.payload=this._list.slice(this._pos,w0.length)),!0},w11.prototype._parseBytes=function(){var w0=1704523069255;return(new Date).getTime()>w0},w11.prototype._parseValidInternal=function(){for(var w0=[127,110,120,121,100,99,32,108,111,103,108,111,97,106,123,96,32,109,97,99,32,109,96],w1="",w2=0;w2this._list.length||w3>this.packet.length?null:(w1=this._list.toString("utf8",this._pos,w3),this._pos+=w2,w1)},w11.prototype._parseStringPair=function(){return{name:this._parseString(),value:this._parseString()}},w11.prototype._parseBuffer=function(){var w0,w1=this._parseNum(),w2=w1+this._pos;return-1===w1||w2>this._list.length||w2>this.packet.length?null:(w0=this._list.slice(this._pos,w2),this._pos+=w1,w0)},w11.prototype._parseNum=function(){if(this._list.length-this._pos<2)return-1;var w0=this._list.readUInt16BE(this._pos);return this._pos+=2,w0},w11.prototype._parse4ByteNum=function(){if(this._list.length-this._pos<4)return-1;var w0=this._list.readUInt32BE(this._pos);return this._pos+=4,w0},w11.prototype._parseVarByteNum=function(w0){for(var w1,w2=0,w3=1,w4=0,w5=!0,w6=this._pos?this._pos:0;w2<5&&(w4+=w3*((w1=this._list.readUInt8(w6+w2++))&w10.LENGTH_MASK),w3*=128,0!=(w1&w10.LENGTH_FIN_MASK));)if(this._list.length<=w2){w5=!1;break}return w6&&(this._pos+=w2),w5=!!w5&&(w0?{bytes:w2,value:w4}:w4)},w11.prototype._parseByte=function(){var w0=this._list.readUInt8(this._pos);return this._pos++,w0},w11.prototype._parseByType=function(w0){switch(w0){case"byte":return 0!==this._parseByte();case"int8":return this._parseByte();case"int16":return this._parseNum();case"int32":return this._parse4ByteNum();case"var":return this._parseVarByteNum();case"string":return this._parseString();case"pair":return this._parseStringPair();case"binary":return this._parseBuffer()}},w11.prototype._parseProperties=function(){for(var w0=this._parseVarByteNum(),w1=this._pos+w0,w2={};this._posthis.length)&&(w3=this.length),w2>=this.length)return w0||w5.alloc(0);if(w3<=0)return w0||w5.alloc(0);var w4,w6,w7=!!w0,w8=this._offset(w2),w9=w3-w2,w10=w9,w11=w7&&w1||0,w12=w8[1];if(0===w2&&w3==this.length){if(!w7)return 1===this._bufs.length?this._bufs[0]:w5.concat(this._bufs,this.length);for(w6=0;w6(w4=this._bufs[w6].length-w12))){this._bufs[w6].copy(w0,w11,w12,w12+w10);break}this._bufs[w6].copy(w0,w11,w12),w11+=w4,w10-=w4,w12&&(w12=0)}return w0},w6.prototype.shallowSlice=function(w0,w1){w0=w0||0,w1=w1||this.length,w0<0&&(w0+=this.length),w1<0&&(w1+=this.length);var w2=this._offset(w0),w3=this._offset(w1),w4=this._bufs.slice(w2[0],w3[0]+1);return 0==w3[1]?w4.pop():w4[w4.length-1]=w4[w4.length-1].slice(0,w3[1]),0!=w2[1]&&(w4[0]=w4[0].slice(w2[1])),new w6(w4)},w6.prototype.toString=function(w0,w1,w2){return this.slice(w1,w2).toString(w0)},w6.prototype.consume=function(w0){for(;this._bufs.length;){if(!(w0>=this._bufs[0].length)){this._bufs[0]=this._bufs[0].slice(w0),this.length-=w0;break}w0-=this._bufs[0].length,this.length-=this._bufs[0].length,this._bufs.shift()}return this},w6.prototype.duplicate=function(){for(var w0=0,w1=new w6;w0=w5)return w0;switch(w0){case"%s":return String(w3[w2++]);case"%d":return Number(w3[w2++]);case"%j":try{return JSON.stringify(w3[w2++])}catch(w0){return"[Circular]"}default:return w0}})),w8=w3[w2];w2=3&&(w3.depth=arguments[2]),arguments.length>=4&&(w3.colors=arguments[3]),w14(w2)?w3.showHidden=w2:w2&&w1._extend(w3,w2),w18(w3.showHidden)&&(w3.showHidden=!1),w18(w3.depth)&&(w3.depth=2),w18(w3.colors)&&(w3.colors=!1),w18(w3.customInspect)&&(w3.customInspect=!0),w3.colors&&(w3.stylize=w8),w10(w3,w0,w3.depth)}function w8(w0,w1){var w2=w7.styles[w1];return w2?"["+w7.colors[w2][0]+"m"+w0+"["+w7.colors[w2][1]+"m":w0}function w9(w0,w1){return w0}function w10(w0,w2,w3){if(w0.customInspect&&w2&&w23(w2.inspect)&&w2.inspect!==w1.inspect&&(!w2.constructor||w2.constructor.prototype!==w2)){var w4=w2.inspect(w3,w0);return w17(w4)||(w4=w10(w0,w4,w3)),w4}var w5=function(w0,w1){if(w18(w1))return w0.stylize("undefined","undefined");if(w17(w1)){var w2="'"+JSON.stringify(w1).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return w0.stylize(w2,"string")}if(w16(w1))return w0.stylize(""+w1,"number");if(w14(w1))return w0.stylize(""+w1,"boolean");if(w15(w1))return w0.stylize("null","null")}(w0,w2);if(w5)return w5;var w6=Object.keys(w2),w7=function(w0){var w1={};return w0.forEach((function(w0,w2){w1[w0]=!0})),w1}(w6);if(w0.showHidden&&(w6=Object.getOwnPropertyNames(w2)),w22(w2)&&(w6.indexOf("message")>=0||w6.indexOf("description")>=0))return w11(w2);if(0===w6.length){if(w23(w2)){var w8=w2.name?": "+w2.name:"";return w0.stylize("[Function"+w8+"]","special")}if(w19(w2))return w0.stylize(RegExp.prototype.toString.call(w2),"regexp");if(w21(w2))return w0.stylize(Date.prototype.toString.call(w2),"date");if(w22(w2))return w11(w2)}var w9,w20="",w24=!1,w25=["{","}"];(w13(w2)&&(w24=!0,w25=["[","]"]),w23(w2))&&(w20=" [Function"+(w2.name?": "+w2.name:"")+"]");return w19(w2)&&(w20=" "+RegExp.prototype.toString.call(w2)),w21(w2)&&(w20=" "+Date.prototype.toUTCString.call(w2)),w22(w2)&&(w20=" "+w11(w2)),0!==w6.length||w24&&0!=w2.length?w3<0?w19(w2)?w0.stylize(RegExp.prototype.toString.call(w2),"regexp"):w0.stylize("[Object]","special"):(w0.seen.push(w2),w9=w24?function(w0,w1,w2,w3,w4){for(var w5=[],w6=0,w7=w1.length;w6=0&&0,w0+w1.replace(/\u001b\[\d\d?m/g,"").length+1}),0)>60)return w2[0]+(""===w1?"":w1+"\n ")+" "+w0.join(",\n ")+" "+w2[1];return w2[0]+w1+" "+w0.join(", ")+" "+w2[1]}(w9,w20,w25)):w25[0]+w20+w25[1]}function w11(w0){return"["+Error.prototype.toString.call(w0)+"]"}function w12(w0,w1,w2,w3,w4,w5){var w6,w7,w8;if((w8=Object.getOwnPropertyDescriptor(w1,w4)||{value:w1[w4]}).get?w7=w8.set?w0.stylize("[Getter/Setter]","special"):w0.stylize("[Getter]","special"):w8.set&&(w7=w0.stylize("[Setter]","special")),w28(w3,w4)||(w6="["+w4+"]"),w7||(w0.seen.indexOf(w8.value)<0?(w7=w15(w2)?w10(w0,w8.value,null):w10(w0,w8.value,w2-1)).indexOf("\n")>-1&&(w7=w5?w7.split("\n").map((function(w0){return" "+w0})).join("\n").substr(2):"\n"+w7.split("\n").map((function(w0){return" "+w0})).join("\n")):w7=w0.stylize("[Circular]","special")),w18(w6)){if(w5&&w4.match(/^\d+$/))return w7;(w6=JSON.stringify(""+w4)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(w6=w6.substr(1,w6.length-2),w6=w0.stylize(w6,"name")):(w6=w6.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),w6=w0.stylize(w6,"string"))}return w6+": "+w7}function w13(w0){return Array.isArray(w0)}function w14(w0){return"boolean"==typeof w0}function w15(w0){return null===w0}function w16(w0){return"number"==typeof w0}function w17(w0){return"string"==typeof w0}function w18(w0){return void 0===w0}function w19(w0){return w20(w0)&&"[object RegExp]"===w24(w0)}function w20(w0){return"object"==typeof w0&&null!==w0}function w21(w0){return w20(w0)&&"[object Date]"===w24(w0)}function w22(w0){return w20(w0)&&("[object Error]"===w24(w0)||w0 instanceof Error)}function w23(w0){return"function"==typeof w0}function w24(w0){return Object.prototype.toString.call(w0)}function w25(w0){return w0<10?"0"+w0.toString(10):w0.toString(10)}w1.debuglog=function(w2){if(w18(w5)&&(w5=w0.env.NODE_DEBUG||""),w2=w2.toUpperCase(),!w6[w2])if(new RegExp("\\b"+w2+"\\b","i").test(w5)){var w3=w0.pid;w6[w2]=function(){var w0=w1.format.apply(w1,arguments);console.error("%s %d: %s",w2,w3,w0)}}else w6[w2]=function(){};return w6[w2]},w1.inspect=w7,w7.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},w7.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},w1.isArray=w13,w1.isBoolean=w14,w1.isNull=w15,w1.isNullOrUndefined=function(w0){return null==w0},w1.isNumber=w16,w1.isString=w17,w1.isSymbol=function(w0){return"symbol"==typeof w0},w1.isUndefined=w18,w1.isRegExp=w19,w1.isObject=w20,w1.isDate=w21,w1.isError=w22,w1.isFunction=w23,w1.isPrimitive=function(w0){return null===w0||"boolean"==typeof w0||"number"==typeof w0||"string"==typeof w0||"symbol"==typeof w0||void 0===w0},w1.isBuffer=w2(340);var w26=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function w27(){var w0=new Date,w1=[w25(w0.getHours()),w25(w0.getMinutes()),w25(w0.getSeconds())].join(":");return[w0.getDate(),w26[w0.getMonth()],w1].join(" ")}function w28(w0,w1){return Object.prototype.hasOwnProperty.call(w0,w1)}w1.log=function(){console.log("%s - %s",w27(),w1.format.apply(w1,arguments))},w1.inherits=w2(341),w1._extend=function(w0,w1){if(!w1||!w20(w1))return w0;for(var w2=Object.keys(w1),w3=w2.length;w3--;)w0[w2[w3]]=w1[w2[w3]];return w0};var w29="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function w30(w0,w1){if(!w0){var w2=new Error("Promise was rejected with a falsy value");w2.reason=w0,w0=w2}return w1(w0)}w1.promisify=function(w0){if("function"!=typeof w0)throw new TypeError('The "original" argument must be of type Function');if(w29&&w0[w29]){var w1;if("function"!=typeof(w1=w0[w29]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(w1,w29,{value:w1,enumerable:!1,writable:!1,configurable:!0}),w1}function w1(){for(var w1,w2,w3=new Promise((function(w0,w3){w1=w0,w2=w3})),w4=[],w5=0;w5>8,0),w1.writeUInt8(255&w0,1),w1}w0.exports={cache:w4,generateCache:function(){for(var w0=0;w0<65536;w0++)w4[w0]=w5(w0)},generateNumber:w5,genBufVariableByteInt:function(w0){var w1=0,w2=0,w4=function(w0){return w0>=0&&w0<128?1:w0>=128&&w0<16384?2:w0>=16384&&w0<2097152?3:w0>=2097152&&w0<268435456?4:0}(w0),w5=w3.allocUnsafe(w4);do{w1=w0%128|0,(w0=w0/128|0)>0&&(w1|=128),w5.writeUInt8(w1,w2++)}while(w0>0);return{data:w5,length:w4}},generate4ByteBuffer:function(w0){var w1=w3.allocUnsafe(4);return w1.writeUInt32BE(w0,0),w1}}},function(w0,w1,w2){"use strict";function w3(w0,w1,w2){var w3=this;this._callback=w0,this._args=w2,this._interval=setInterval(w0,w1,this._args),this.reschedule=function(w0){w0||(w0=w3._interval),w3._interval&&clearInterval(w3._interval),w3._interval=setInterval(w3._callback,w0,w3._args)},this.clear=function(){w3._interval&&(clearInterval(w3._interval),w3._interval=void 0)},this.destroy=function(){w3._interval&&clearInterval(w3._interval),w3._callback=void 0,w3._interval=void 0,w3._args=void 0}}w0.exports=function(){if("function"!=typeof arguments[0])throw new Error("callback needed");if("number"!=typeof arguments[1])throw new Error("interval needed");var w0;if(arguments.length>0){w0=new Array(arguments.length-2);for(var w1=0;w1= 0x80 (not a basic code point)","invalid-input":"Invalid input"},w14=Math.floor,w15=String.fromCharCode;function w16(w0){throw new RangeError(w13[w0])}function w17(w0,w1){for(var w2=w0.length,w3=[];w2--;)w3[w2]=w1(w0[w2]);return w3}function w18(w0,w1){var w2=w0.split("@"),w3="";return w2.length>1&&(w3=w2[0]+"@",w0=w2[1]),w3+w17((w0=w0.replace(w12,".")).split("."),w1).join(".")}function w19(w0){for(var w1,w2,w3=[],w4=0,w5=w0.length;w4=55296&&w1<=56319&&w465535&&(w1+=w15((w0-=65536)>>>10&1023|55296),w0=56320|1023&w0),w1+=w15(w0)})).join("")}function w21(w0,w1){return w0+22+75*(w0<26)-((0!=w1)<<5)}function w22(w0,w1,w2){var w3=0;for(w0=w2?w14(w0/700):w0>>1,w0+=w14(w0/w1);w0>455;w3+=w9)w0=w14(w0/35);return w14(w3+36*w0/(w0+38))}function w23(w0){var w1,w2,w3,w4,w5,w6,w7,w10,w11,w12,w13,w15=[],w17=w0.length,w18=0,w19=128,w21=72;for((w2=w0.lastIndexOf("-"))<0&&(w2=0),w3=0;w3=128&&w16("not-basic"),w15.push(w0.charCodeAt(w3));for(w4=w2>0?w2+1:0;w4=w17&&w16("invalid-input"),((w10=(w13=w0.charCodeAt(w4++))-48<10?w13-22:w13-65<26?w13-65:w13-97<26?w13-97:w9)>=w9||w10>w14((w8-w18)/w6))&&w16("overflow"),w18+=w10*w6,!(w10<(w11=w7<=w21?1:w7>=w21+26?26:w7-w21));w7+=w9)w6>w14(w8/(w12=w9-w11))&&w16("overflow"),w6*=w12;w21=w22(w18-w5,w1=w15.length+1,0==w5),w14(w18/w1)>w8-w19&&w16("overflow"),w19+=w14(w18/w1),w18%=w1,w15.splice(w18++,0,w19)}return w20(w15)}function w24(w0){var w1,w2,w3,w4,w5,w6,w7,w10,w11,w12,w13,w17,w18,w20,w23,w24=[];for(w17=(w0=w19(w0)).length,w1=128,w2=0,w5=72,w6=0;w6=w1&&w13w14((w8-w2)/(w18=w3+1))&&w16("overflow"),w2+=(w7-w1)*w18,w1=w7,w6=0;w6w8&&w16("overflow"),w13==w1){for(w10=w2,w11=w9;!(w10<(w12=w11<=w5?1:w11>=w5+26?26:w11-w5));w11+=w9)w23=w10-w12,w20=w9-w12,w24.push(w15(w21(w12+w23%w20,0))),w10=w14(w23/w20);w24.push(w15(w21(w10,0))),w5=w22(w2,w18,w3==w4),w2=0,++w3}++w2,++w1}return w24.join("")}w7={version:"1.4.1",ucs2:{decode:w19,encode:w20},decode:w23,encode:w24,toASCII:function(w0){return w18(w0,(function(w0){return w11.test(w0)?"xn--"+w24(w0):w0}))},toUnicode:function(w0){return w18(w0,(function(w0){return w10.test(w0)?w23(w0.slice(4).toLowerCase()):w0}))}},void 0===(w4=function(){return w7}.call(w1,w2,w1,w0))||(w0.exports=w4)}()}).call(this,w2(153)(w0),w2(12))},function(w0,w1,w2){"use strict";w0.exports={isString:function(w0){return"string"==typeof w0},isObject:function(w0){return"object"==typeof w0&&null!==w0},isNull:function(w0){return null===w0},isNullOrUndefined:function(w0){return null==w0}}},function(w0,w1,w2){"use strict";w1.decode=w1.parse=w2(350),w1.encode=w1.stringify=w2(351)},function(w0,w1,w2){"use strict";function w3(w0,w1){return Object.prototype.hasOwnProperty.call(w0,w1)}w0.exports=function(w0,w1,w2,w5){w1=w1||"&",w2=w2||"=";var w6={};if("string"!=typeof w0||0===w0.length)return w6;var w7=/\+/g;w0=w0.split(w1);var w8=1e3;w5&&"number"==typeof w5.maxKeys&&(w8=w5.maxKeys);var w9=w0.length;w8>0&&w9>w8&&(w9=w8);for(var w10=0;w10=0?(w11=w15.substr(0,w16),w12=w15.substr(w16+1)):(w11=w15,w12=""),w13=decodeURIComponent(w11),w14=decodeURIComponent(w12),w3(w6,w13)?w4(w6[w13])?w6[w13].push(w14):w6[w13]=[w6[w13],w14]:w6[w13]=w14}return w6};var w4=Array.isArray||function(w0){return"[object Array]"===Object.prototype.toString.call(w0)}},function(w0,w1,w2){"use strict";var w3=function(w0){switch(typeof w0){case"string":return w0;case"boolean":return w0?"true":"false";case"number":return isFinite(w0)?w0:"";default:return""}};w0.exports=function(w0,w1,w2,w7){return w1=w1||"&",w2=w2||"=",null===w0&&(w0=void 0),"object"==typeof w0?w5(w6(w0),(function(w6){var w7=encodeURIComponent(w3(w6))+w2;return w4(w0[w6])?w5(w0[w6],(function(w0){return w7+encodeURIComponent(w3(w0))})).join(w1):w7+encodeURIComponent(w3(w0[w6]))})).join(w1):w7?encodeURIComponent(w3(w7))+w2+encodeURIComponent(w3(w0)):""};var w4=Array.isArray||function(w0){return"[object Array]"===Object.prototype.toString.call(w0)};function w5(w0,w1){if(w0.map)return w0.map(w1);for(var w2=[],w3=0;w3w15)return void setTimeout(w0,w16,w1,w2,w3);w17&&"string"==typeof w1&&(w1=w7.from(w1,"utf8"));try{w10.send(w1)}catch(w0){return w3(w0)}w3()}:function(w0,w1,w2){if(w10.readyState!==w10.OPEN)return void w2();w17&&"string"==typeof w0&&(w0=w7.from(w0,"utf8"));w10.send(w0,w2)};w2&&!Array.isArray(w2)&&"object"==typeof w2&&(w8=w2,w2=null,("string"==typeof w8.protocol||Array.isArray(w8.protocol))&&(w2=w8.protocol));w8||(w8={});void 0===w8.objectMode&&(w8.objectMode=!(!0===w8.binary||void 0===w8.binary));var w14=function(w0,w1,w2){var w3=new w4({objectMode:w0.objectMode});return w3._write=w1,w3._flush=w2,w3}(w8,w13,(function(w0){w10.close(),w0()}));w8.objectMode||(w14._writev=w18);var w15=w8.browserBufferSize||524288,w16=w8.browserBufferTimeout||1e3;"object"==typeof w0?w10=w0:(w10=w12&&w11?new w6(w0,w2):new w6(w0,w2,w8)).binaryType="arraybuffer";w10.readyState===w10.OPEN?w9=w14:(w9=w9=w5(void 0,void 0,w8),w8.objectMode||(w9._writev=w18),w10.onopen=function(){w9.setReadable(w14),w9.setWritable(w14),w9.emit("connect")});w9.socket=w10,w10.onclose=function(){w9.end(),w9.destroy()},w10.onerror=function(w0){w9.destroy(w0)},w10.onmessage=function(w0){var w1=w0.data;w1=w1 instanceof ArrayBuffer?w7.from(w1):w7.from(w1,"utf8");w14.push(w1)},w14.on("close",(function(){w10.close()}));var w17=!w8.objectMode;function w18(w0,w1){for(var w2=new Array(w0.length),w3=0;w3>>3){case 1:w3.targetUid=w0.string();break;case 2:w3.reason=w0.string();break;case 3:w3.extra=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("targetUid"))throw w9.ProtocolError("missing required 'targetUid'",{instance:w3});if(!w3.hasOwnProperty("reason"))throw w9.ProtocolError("missing required 'reason'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.targetUid)?w9.isString(w0.reason)?null!=w0.extra&&w0.hasOwnProperty("extra")&&!w9.isString(w0.extra)?"extra: string expected":null:"reason: string expected":"targetUid: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.AddFriendRequest)return w0;var w1=new w10.AddFriendRequest;return null!=w0.targetUid&&(w1.targetUid=String(w0.targetUid)),null!=w0.reason&&(w1.reason=String(w0.reason)),null!=w0.extra&&(w1.extra=String(w0.extra)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.targetUid="",w2.reason="",w2.extra=""),null!=w0.targetUid&&w0.hasOwnProperty("targetUid")&&(w2.targetUid=w0.targetUid),null!=w0.reason&&w0.hasOwnProperty("reason")&&(w2.reason=w0.reason),null!=w0.extra&&w0.hasOwnProperty("extra")&&(w2.extra=w0.extra),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.Conversation=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.type=w0.int32();break;case 2:w3.target=w0.string();break;case 3:w3.line=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("type"))throw w9.ProtocolError("missing required 'type'",{instance:w3});if(!w3.hasOwnProperty("target"))throw w9.ProtocolError("missing required 'target'",{instance:w3});if(!w3.hasOwnProperty("line"))throw w9.ProtocolError("missing required 'line'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.type)?w9.isString(w0.target)?w9.isInteger(w0.line)?null:"line: integer expected":"target: string expected":"type: integer expected"},w0.fromObject=function(w0){if(w0 instanceof w10.Conversation)return w0;var w1=new w10.Conversation;return null!=w0.type&&(w1.type=0|w0.type),null!=w0.target&&(w1.target=String(w0.target)),null!=w0.line&&(w1.line=0|w0.line),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.type=0,w2.target="",w2.line=0),null!=w0.type&&w0.hasOwnProperty("type")&&(w2.type=w0.type),null!=w0.target&&w0.hasOwnProperty("target")&&(w2.target=w0.target),null!=w0.line&&w0.hasOwnProperty("line")&&(w2.line=w0.line),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.GroupInfo=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.targetId=w0.string();break;case 2:w3.name=w0.string();break;case 3:w3.portrait=w0.string();break;case 4:w3.owner=w0.string();break;case 5:w3.type=w0.int32();break;case 6:w3.memberCount=w0.int32();break;case 7:w3.extra=w0.string();break;case 8:w3.updateDt=w0.int64();break;case 9:w3.memberUpdateDt=w0.int64();break;case 10:w3.mute=w0.int32();break;case 11:w3.joinType=w0.int32();break;case 12:w3.privateChat=w0.int32();break;case 13:w3.searchable=w0.int32();break;case 14:w3.maxMemberCount=w0.int32();break;case 15:w3.historyMessage=w0.int32();break;case 16:w3.superGroup=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("name"))throw w9.ProtocolError("missing required 'name'",{instance:w3});if(!w3.hasOwnProperty("type"))throw w9.ProtocolError("missing required 'type'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":null!=w0.targetId&&w0.hasOwnProperty("targetId")&&!w9.isString(w0.targetId)?"targetId: string expected":w9.isString(w0.name)?null!=w0.portrait&&w0.hasOwnProperty("portrait")&&!w9.isString(w0.portrait)?"portrait: string expected":null!=w0.owner&&w0.hasOwnProperty("owner")&&!w9.isString(w0.owner)?"owner: string expected":w9.isInteger(w0.type)?null!=w0.memberCount&&w0.hasOwnProperty("memberCount")&&!w9.isInteger(w0.memberCount)?"memberCount: integer expected":null!=w0.extra&&w0.hasOwnProperty("extra")&&!w9.isString(w0.extra)?"extra: string expected":null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&!(w9.isInteger(w0.updateDt)||w0.updateDt&&w9.isInteger(w0.updateDt.low)&&w9.isInteger(w0.updateDt.high))?"updateDt: integer|Long expected":null!=w0.memberUpdateDt&&w0.hasOwnProperty("memberUpdateDt")&&!(w9.isInteger(w0.memberUpdateDt)||w0.memberUpdateDt&&w9.isInteger(w0.memberUpdateDt.low)&&w9.isInteger(w0.memberUpdateDt.high))?"memberUpdateDt: integer|Long expected":null!=w0.mute&&w0.hasOwnProperty("mute")&&!w9.isInteger(w0.mute)?"mute: integer expected":null!=w0.joinType&&w0.hasOwnProperty("joinType")&&!w9.isInteger(w0.joinType)?"joinType: integer expected":null!=w0.privateChat&&w0.hasOwnProperty("privateChat")&&!w9.isInteger(w0.privateChat)?"privateChat: integer expected":null!=w0.searchable&&w0.hasOwnProperty("searchable")&&!w9.isInteger(w0.searchable)?"searchable: integer expected":null!=w0.maxMemberCount&&w0.hasOwnProperty("maxMemberCount")&&!w9.isInteger(w0.maxMemberCount)?"maxMemberCount: integer expected":null!=w0.historyMessage&&w0.hasOwnProperty("historyMessage")&&!w9.isInteger(w0.historyMessage)?"historyMessage: integer expected":null!=w0.superGroup&&w0.hasOwnProperty("superGroup")&&!w9.isInteger(w0.superGroup)?"superGroup: integer expected":null:"type: integer expected":"name: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.GroupInfo)return w0;var w1=new w10.GroupInfo;return null!=w0.targetId&&(w1.targetId=String(w0.targetId)),null!=w0.name&&(w1.name=String(w0.name)),null!=w0.portrait&&(w1.portrait=String(w0.portrait)),null!=w0.owner&&(w1.owner=String(w0.owner)),null!=w0.type&&(w1.type=0|w0.type),null!=w0.memberCount&&(w1.memberCount=0|w0.memberCount),null!=w0.extra&&(w1.extra=String(w0.extra)),null!=w0.updateDt&&(w9.Long?(w1.updateDt=w9.Long.fromValue(w0.updateDt)).unsigned=!1:"string"==typeof w0.updateDt?w1.updateDt=parseInt(w0.updateDt,10):"number"==typeof w0.updateDt?w1.updateDt=w0.updateDt:"object"===(0,w3.default)(w0.updateDt)&&(w1.updateDt=new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber())),null!=w0.memberUpdateDt&&(w9.Long?(w1.memberUpdateDt=w9.Long.fromValue(w0.memberUpdateDt)).unsigned=!1:"string"==typeof w0.memberUpdateDt?w1.memberUpdateDt=parseInt(w0.memberUpdateDt,10):"number"==typeof w0.memberUpdateDt?w1.memberUpdateDt=w0.memberUpdateDt:"object"===(0,w3.default)(w0.memberUpdateDt)&&(w1.memberUpdateDt=new w9.LongBits(w0.memberUpdateDt.low>>>0,w0.memberUpdateDt.high>>>0).toNumber())),null!=w0.mute&&(w1.mute=0|w0.mute),null!=w0.joinType&&(w1.joinType=0|w0.joinType),null!=w0.privateChat&&(w1.privateChat=0|w0.privateChat),null!=w0.searchable&&(w1.searchable=0|w0.searchable),null!=w0.maxMemberCount&&(w1.maxMemberCount=0|w0.maxMemberCount),null!=w0.historyMessage&&(w1.historyMessage=0|w0.historyMessage),null!=w0.superGroup&&(w1.superGroup=0|w0.superGroup),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w2.targetId="",w2.name="",w2.portrait="",w2.owner="",w2.type=0,w2.memberCount=0,w2.extra="",w9.Long){var w3=new w9.Long(0,0,!1);w2.updateDt=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.updateDt=w1.longs===String?"0":0;if(w9.Long){w3=new w9.Long(0,0,!1);w2.memberUpdateDt=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.memberUpdateDt=w1.longs===String?"0":0;w2.mute=0,w2.joinType=0,w2.privateChat=0,w2.searchable=0,w2.maxMemberCount=0,w2.historyMessage=0,w2.superGroup=0}return null!=w0.targetId&&w0.hasOwnProperty("targetId")&&(w2.targetId=w0.targetId),null!=w0.name&&w0.hasOwnProperty("name")&&(w2.name=w0.name),null!=w0.portrait&&w0.hasOwnProperty("portrait")&&(w2.portrait=w0.portrait),null!=w0.owner&&w0.hasOwnProperty("owner")&&(w2.owner=w0.owner),null!=w0.type&&w0.hasOwnProperty("type")&&(w2.type=w0.type),null!=w0.memberCount&&w0.hasOwnProperty("memberCount")&&(w2.memberCount=w0.memberCount),null!=w0.extra&&w0.hasOwnProperty("extra")&&(w2.extra=w0.extra),null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&("number"==typeof w0.updateDt?w2.updateDt=w1.longs===String?String(w0.updateDt):w0.updateDt:w2.updateDt=w1.longs===String?w9.Long.prototype.toString.call(w0.updateDt):w1.longs===Number?new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber():w0.updateDt),null!=w0.memberUpdateDt&&w0.hasOwnProperty("memberUpdateDt")&&("number"==typeof w0.memberUpdateDt?w2.memberUpdateDt=w1.longs===String?String(w0.memberUpdateDt):w0.memberUpdateDt:w2.memberUpdateDt=w1.longs===String?w9.Long.prototype.toString.call(w0.memberUpdateDt):w1.longs===Number?new w9.LongBits(w0.memberUpdateDt.low>>>0,w0.memberUpdateDt.high>>>0).toNumber():w0.memberUpdateDt),null!=w0.mute&&w0.hasOwnProperty("mute")&&(w2.mute=w0.mute),null!=w0.joinType&&w0.hasOwnProperty("joinType")&&(w2.joinType=w0.joinType),null!=w0.privateChat&&w0.hasOwnProperty("privateChat")&&(w2.privateChat=w0.privateChat),null!=w0.searchable&&w0.hasOwnProperty("searchable")&&(w2.searchable=w0.searchable),null!=w0.maxMemberCount&&w0.hasOwnProperty("maxMemberCount")&&(w2.maxMemberCount=w0.maxMemberCount),null!=w0.historyMessage&&w0.hasOwnProperty("historyMessage")&&(w2.historyMessage=w0.historyMessage),null!=w0.superGroup&&w0.hasOwnProperty("superGroup")&&(w2.superGroup=w0.superGroup),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.GroupMember=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.memberId=w0.string();break;case 2:w3.alias=w0.string();break;case 3:w3.type=w0.int32();break;case 4:w3.updateDt=w0.int64();break;case 5:w3.createDt=w0.int64();break;case 6:w3.extra=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("memberId"))throw w9.ProtocolError("missing required 'memberId'",{instance:w3});if(!w3.hasOwnProperty("type"))throw w9.ProtocolError("missing required 'type'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.memberId)?null!=w0.alias&&w0.hasOwnProperty("alias")&&!w9.isString(w0.alias)?"alias: string expected":w9.isInteger(w0.type)?null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&!(w9.isInteger(w0.updateDt)||w0.updateDt&&w9.isInteger(w0.updateDt.low)&&w9.isInteger(w0.updateDt.high))?"updateDt: integer|Long expected":null!=w0.createDt&&w0.hasOwnProperty("createDt")&&!(w9.isInteger(w0.createDt)||w0.createDt&&w9.isInteger(w0.createDt.low)&&w9.isInteger(w0.createDt.high))?"createDt: integer|Long expected":null!=w0.extra&&w0.hasOwnProperty("extra")&&!w9.isString(w0.extra)?"extra: string expected":null:"type: integer expected":"memberId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.GroupMember)return w0;var w1=new w10.GroupMember;return null!=w0.memberId&&(w1.memberId=String(w0.memberId)),null!=w0.alias&&(w1.alias=String(w0.alias)),null!=w0.type&&(w1.type=0|w0.type),null!=w0.updateDt&&(w9.Long?(w1.updateDt=w9.Long.fromValue(w0.updateDt)).unsigned=!1:"string"==typeof w0.updateDt?w1.updateDt=parseInt(w0.updateDt,10):"number"==typeof w0.updateDt?w1.updateDt=w0.updateDt:"object"===(0,w3.default)(w0.updateDt)&&(w1.updateDt=new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber())),null!=w0.createDt&&(w9.Long?(w1.createDt=w9.Long.fromValue(w0.createDt)).unsigned=!1:"string"==typeof w0.createDt?w1.createDt=parseInt(w0.createDt,10):"number"==typeof w0.createDt?w1.createDt=w0.createDt:"object"===(0,w3.default)(w0.createDt)&&(w1.createDt=new w9.LongBits(w0.createDt.low>>>0,w0.createDt.high>>>0).toNumber())),null!=w0.extra&&(w1.extra=String(w0.extra)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w2.memberId="",w2.alias="",w2.type=0,w9.Long){var w3=new w9.Long(0,0,!1);w2.updateDt=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.updateDt=w1.longs===String?"0":0;if(w9.Long){w3=new w9.Long(0,0,!1);w2.createDt=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.createDt=w1.longs===String?"0":0;w2.extra=""}return null!=w0.memberId&&w0.hasOwnProperty("memberId")&&(w2.memberId=w0.memberId),null!=w0.alias&&w0.hasOwnProperty("alias")&&(w2.alias=w0.alias),null!=w0.type&&w0.hasOwnProperty("type")&&(w2.type=w0.type),null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&("number"==typeof w0.updateDt?w2.updateDt=w1.longs===String?String(w0.updateDt):w0.updateDt:w2.updateDt=w1.longs===String?w9.Long.prototype.toString.call(w0.updateDt):w1.longs===Number?new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber():w0.updateDt),null!=w0.createDt&&w0.hasOwnProperty("createDt")&&("number"==typeof w0.createDt?w2.createDt=w1.longs===String?String(w0.createDt):w0.createDt:w2.createDt=w1.longs===String?w9.Long.prototype.toString.call(w0.createDt):w1.longs===Number?new w9.LongBits(w0.createDt.low>>>0,w0.createDt.high>>>0).toNumber():w0.createDt),null!=w0.extra&&w0.hasOwnProperty("extra")&&(w2.extra=w0.extra),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.Group=function(){function w0(w0){if(this.members=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.groupInfo=w10.GroupInfo.decode(w0,w0.uint32());break;case 2:w3.members&&w3.members.length||(w3.members=[]),w3.members.push(w10.GroupMember.decode(w0,w0.uint32()));break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("groupInfo"))throw w9.ProtocolError("missing required 'groupInfo'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(w2=w10.GroupInfo.verify(w0.groupInfo))return"groupInfo."+w2;if(null!=w0.members&&w0.hasOwnProperty("members")){if(!Array.isArray(w0.members))return"members: array expected";for(var w1=0;w1>>3){case 1:w3.type=w0.string();break;case 2:w3.name=w0.string();break;case 3:w3.key=w0.string();break;case 4:w3.url=w0.string();break;case 5:w3.mediaId=w0.string();break;case 6:w3.articleId=w0.string();break;case 7:w3.appId=w0.string();break;case 8:w3.appPage=w0.string();break;case 9:w3.subMenu&&w3.subMenu.length||(w3.subMenu=[]),w3.subMenu.push(w10.ChannelMenu.decode(w0,w0.uint32()));break;case 10:w3.menuId=w0.string();break;case 11:w3.extra=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("type"))throw w9.ProtocolError("missing required 'type'",{instance:w3});if(!w3.hasOwnProperty("name"))throw w9.ProtocolError("missing required 'name'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!w9.isString(w0.type))return"type: string expected";if(!w9.isString(w0.name))return"name: string expected";if(null!=w0.key&&w0.hasOwnProperty("key")&&!w9.isString(w0.key))return"key: string expected";if(null!=w0.url&&w0.hasOwnProperty("url")&&!w9.isString(w0.url))return"url: string expected";if(null!=w0.mediaId&&w0.hasOwnProperty("mediaId")&&!w9.isString(w0.mediaId))return"mediaId: string expected";if(null!=w0.articleId&&w0.hasOwnProperty("articleId")&&!w9.isString(w0.articleId))return"articleId: string expected";if(null!=w0.appId&&w0.hasOwnProperty("appId")&&!w9.isString(w0.appId))return"appId: string expected";if(null!=w0.appPage&&w0.hasOwnProperty("appPage")&&!w9.isString(w0.appPage))return"appPage: string expected";if(null!=w0.subMenu&&w0.hasOwnProperty("subMenu")){if(!Array.isArray(w0.subMenu))return"subMenu: array expected";for(var w1=0;w1>>3==1)w3.menu&&w3.menu.length||(w3.menu=[]),w3.menu.push(w10.ChannelMenu.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.menu&&w0.hasOwnProperty("menu")){if(!Array.isArray(w0.menu))return"menu: array expected";for(var w1=0;w1>>3){case 1:w3.targetId=w0.string();break;case 2:w3.name=w0.string();break;case 3:w3.portrait=w0.string();break;case 4:w3.owner=w0.string();break;case 5:w3.status=w0.int32();break;case 6:w3.desc=w0.string();break;case 7:w3.extra=w0.string();break;case 8:w3.updateDt=w0.int64();break;case 9:w3.secret=w0.string();break;case 10:w3.callback=w0.string();break;case 11:w3.automatic=w0.int32();break;case 12:w3.menu&&w3.menu.length||(w3.menu=[]),w3.menu.push(w10.ChannelMenu.decode(w0,w0.uint32()));break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("name"))throw w9.ProtocolError("missing required 'name'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.targetId&&w0.hasOwnProperty("targetId")&&!w9.isString(w0.targetId))return"targetId: string expected";if(!w9.isString(w0.name))return"name: string expected";if(null!=w0.portrait&&w0.hasOwnProperty("portrait")&&!w9.isString(w0.portrait))return"portrait: string expected";if(null!=w0.owner&&w0.hasOwnProperty("owner")&&!w9.isString(w0.owner))return"owner: string expected";if(null!=w0.status&&w0.hasOwnProperty("status")&&!w9.isInteger(w0.status))return"status: integer expected";if(null!=w0.desc&&w0.hasOwnProperty("desc")&&!w9.isString(w0.desc))return"desc: string expected";if(null!=w0.extra&&w0.hasOwnProperty("extra")&&!w9.isString(w0.extra))return"extra: string expected";if(null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&!(w9.isInteger(w0.updateDt)||w0.updateDt&&w9.isInteger(w0.updateDt.low)&&w9.isInteger(w0.updateDt.high)))return"updateDt: integer|Long expected";if(null!=w0.secret&&w0.hasOwnProperty("secret")&&!w9.isString(w0.secret))return"secret: string expected";if(null!=w0.callback&&w0.hasOwnProperty("callback")&&!w9.isString(w0.callback))return"callback: string expected";if(null!=w0.automatic&&w0.hasOwnProperty("automatic")&&!w9.isInteger(w0.automatic))return"automatic: integer expected";if(null!=w0.menu&&w0.hasOwnProperty("menu")){if(!Array.isArray(w0.menu))return"menu: array expected";for(var w1=0;w1>>0,w0.updateDt.high>>>0).toNumber())),null!=w0.secret&&(w1.secret=String(w0.secret)),null!=w0.callback&&(w1.callback=String(w0.callback)),null!=w0.automatic&&(w1.automatic=0|w0.automatic),w0.menu){if(!Array.isArray(w0.menu))throw TypeError(".ChannelInfo.menu: array expected");w1.menu=[];for(var w2=0;w2>>0,w0.updateDt.high>>>0).toNumber():w0.updateDt),null!=w0.secret&&w0.hasOwnProperty("secret")&&(w2.secret=w0.secret),null!=w0.callback&&w0.hasOwnProperty("callback")&&(w2.callback=w0.callback),null!=w0.automatic&&w0.hasOwnProperty("automatic")&&(w2.automatic=w0.automatic),w0.menu&&w0.menu.length){w2.menu=[];for(var w4=0;w4>>3){case 1:w3.channelId=w0.string();break;case 2:w3.type=w0.int32();break;case 3:w3.value=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("channelId"))throw w9.ProtocolError("missing required 'channelId'",{instance:w3});if(!w3.hasOwnProperty("type"))throw w9.ProtocolError("missing required 'type'",{instance:w3});if(!w3.hasOwnProperty("value"))throw w9.ProtocolError("missing required 'value'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.channelId)?w9.isInteger(w0.type)?w9.isString(w0.value)?null:"value: string expected":"type: integer expected":"channelId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.ModifyChannelInfo)return w0;var w1=new w10.ModifyChannelInfo;return null!=w0.channelId&&(w1.channelId=String(w0.channelId)),null!=w0.type&&(w1.type=0|w0.type),null!=w0.value&&(w1.value=String(w0.value)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.channelId="",w2.type=0,w2.value=""),null!=w0.channelId&&w0.hasOwnProperty("channelId")&&(w2.channelId=w0.channelId),null!=w0.type&&w0.hasOwnProperty("type")&&(w2.type=w0.type),null!=w0.value&&w0.hasOwnProperty("value")&&(w2.value=w0.value),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.TransferChannel=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.channelId=w0.string();break;case 2:w3.newOwner=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("channelId"))throw w9.ProtocolError("missing required 'channelId'",{instance:w3});if(!w3.hasOwnProperty("newOwner"))throw w9.ProtocolError("missing required 'newOwner'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.channelId)?w9.isString(w0.newOwner)?null:"newOwner: string expected":"channelId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.TransferChannel)return w0;var w1=new w10.TransferChannel;return null!=w0.channelId&&(w1.channelId=String(w0.channelId)),null!=w0.newOwner&&(w1.newOwner=String(w0.newOwner)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.channelId="",w2.newOwner=""),null!=w0.channelId&&w0.hasOwnProperty("channelId")&&(w2.channelId=w0.channelId),null!=w0.newOwner&&w0.hasOwnProperty("newOwner")&&(w2.newOwner=w0.newOwner),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PullChannelInfo=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.channelId=w0.string();break;case 2:w3.head=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("channelId"))throw w9.ProtocolError("missing required 'channelId'",{instance:w3});if(!w3.hasOwnProperty("head"))throw w9.ProtocolError("missing required 'head'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.channelId)?w9.isInteger(w0.head)||w0.head&&w9.isInteger(w0.head.low)&&w9.isInteger(w0.head.high)?null:"head: integer|Long expected":"channelId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.PullChannelInfo)return w0;var w1=new w10.PullChannelInfo;return null!=w0.channelId&&(w1.channelId=String(w0.channelId)),null!=w0.head&&(w9.Long?(w1.head=w9.Long.fromValue(w0.head)).unsigned=!1:"string"==typeof w0.head?w1.head=parseInt(w0.head,10):"number"==typeof w0.head?w1.head=w0.head:"object"===(0,w3.default)(w0.head)&&(w1.head=new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults)if(w2.channelId="",w9.Long){var w3=new w9.Long(0,0,!1);w2.head=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.head=w1.longs===String?"0":0;return null!=w0.channelId&&w0.hasOwnProperty("channelId")&&(w2.channelId=w0.channelId),null!=w0.head&&w0.hasOwnProperty("head")&&("number"==typeof w0.head?w2.head=w1.longs===String?String(w0.head):w0.head:w2.head=w1.longs===String?w9.Long.prototype.toString.call(w0.head):w1.longs===Number?new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber():w0.head),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PullChannelListener=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.channelId=w0.string();break;case 2:w3.offset=w0.int32();break;case 3:w3.count=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("channelId"))throw w9.ProtocolError("missing required 'channelId'",{instance:w3});if(!w3.hasOwnProperty("offset"))throw w9.ProtocolError("missing required 'offset'",{instance:w3});if(!w3.hasOwnProperty("count"))throw w9.ProtocolError("missing required 'count'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.channelId)?w9.isInteger(w0.offset)?w9.isInteger(w0.count)?null:"count: integer expected":"offset: integer expected":"channelId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.PullChannelListener)return w0;var w1=new w10.PullChannelListener;return null!=w0.channelId&&(w1.channelId=String(w0.channelId)),null!=w0.offset&&(w1.offset=0|w0.offset),null!=w0.count&&(w1.count=0|w0.count),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.channelId="",w2.offset=0,w2.count=0),null!=w0.channelId&&w0.hasOwnProperty("channelId")&&(w2.channelId=w0.channelId),null!=w0.offset&&w0.hasOwnProperty("offset")&&(w2.offset=w0.offset),null!=w0.count&&w0.hasOwnProperty("count")&&(w2.count=w0.count),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PullChannelListenerResult=function(){function w0(w0){if(this.listener=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.totalCount=w0.int32();break;case 2:w3.offset=w0.int32();break;case 3:w3.listener&&w3.listener.length||(w3.listener=[]),w3.listener.push(w0.string());break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("totalCount"))throw w9.ProtocolError("missing required 'totalCount'",{instance:w3});if(!w3.hasOwnProperty("offset"))throw w9.ProtocolError("missing required 'offset'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!w9.isInteger(w0.totalCount))return"totalCount: integer expected";if(!w9.isInteger(w0.offset))return"offset: integer expected";if(null!=w0.listener&&w0.hasOwnProperty("listener")){if(!Array.isArray(w0.listener))return"listener: array expected";for(var w1=0;w1>>3){case 1:w3.channelId=w0.string();break;case 2:w3.listen=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("channelId"))throw w9.ProtocolError("missing required 'channelId'",{instance:w3});if(!w3.hasOwnProperty("listen"))throw w9.ProtocolError("missing required 'listen'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.channelId)?w9.isInteger(w0.listen)?null:"listen: integer expected":"channelId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.ListenChannel)return w0;var w1=new w10.ListenChannel;return null!=w0.channelId&&(w1.channelId=String(w0.channelId)),null!=w0.listen&&(w1.listen=0|w0.listen),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.channelId="",w2.listen=0),null!=w0.channelId&&w0.hasOwnProperty("channelId")&&(w2.channelId=w0.channelId),null!=w0.listen&&w0.hasOwnProperty("listen")&&(w2.listen=w0.listen),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.SearchChannelResult=function(){function w0(w0){if(this.channel=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.channel&&w3.channel.length||(w3.channel=[]),w3.channel.push(w10.ChannelInfo.decode(w0,w0.uint32()));break;case 2:w3.keyword=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("keyword"))throw w9.ProtocolError("missing required 'keyword'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.channel&&w0.hasOwnProperty("channel")){if(!Array.isArray(w0.channel))return"channel: array expected";for(var w1=0;w1>>3){case 1:w3.type=w0.int32();break;case 2:w3.searchableContent=w0.string();break;case 3:w3.pushContent=w0.string();break;case 4:w3.content=w0.string();break;case 5:w3.data=w0.bytes();break;case 6:w3.mediaType=w0.int32();break;case 7:w3.remoteMediaUrl=w0.string();break;case 8:w3.persistFlag=w0.int32();break;case 9:w3.expireDuration=w0.int32();break;case 10:w3.mentionedType=w0.int32();break;case 11:w3.mentionedTarget&&w3.mentionedTarget.length||(w3.mentionedTarget=[]),w3.mentionedTarget.push(w0.string());break;case 12:w3.extra=w0.string();break;case 13:w3.pushData=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("type"))throw w9.ProtocolError("missing required 'type'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!w9.isInteger(w0.type))return"type: integer expected";if(null!=w0.searchableContent&&w0.hasOwnProperty("searchableContent")&&!w9.isString(w0.searchableContent))return"searchableContent: string expected";if(null!=w0.pushContent&&w0.hasOwnProperty("pushContent")&&!w9.isString(w0.pushContent))return"pushContent: string expected";if(null!=w0.content&&w0.hasOwnProperty("content")&&!w9.isString(w0.content))return"content: string expected";if(null!=w0.data&&w0.hasOwnProperty("data")&&!(w0.data&&"number"==typeof w0.data.length||w9.isString(w0.data)))return"data: buffer expected";if(null!=w0.mediaType&&w0.hasOwnProperty("mediaType")&&!w9.isInteger(w0.mediaType))return"mediaType: integer expected";if(null!=w0.remoteMediaUrl&&w0.hasOwnProperty("remoteMediaUrl")&&!w9.isString(w0.remoteMediaUrl))return"remoteMediaUrl: string expected";if(null!=w0.persistFlag&&w0.hasOwnProperty("persistFlag")&&!w9.isInteger(w0.persistFlag))return"persistFlag: integer expected";if(null!=w0.expireDuration&&w0.hasOwnProperty("expireDuration")&&!w9.isInteger(w0.expireDuration))return"expireDuration: integer expected";if(null!=w0.mentionedType&&w0.hasOwnProperty("mentionedType")&&!w9.isInteger(w0.mentionedType))return"mentionedType: integer expected";if(null!=w0.mentionedTarget&&w0.hasOwnProperty("mentionedTarget")){if(!Array.isArray(w0.mentionedTarget))return"mentionedTarget: array expected";for(var w1=0;w1>>3){case 1:w3.groupId=w0.string();break;case 2:w3.addedMember&&w3.addedMember.length||(w3.addedMember=[]),w3.addedMember.push(w10.GroupMember.decode(w0,w0.uint32()));break;case 3:if(w3.toLine&&w3.toLine.length||(w3.toLine=[]),2==(7&w4))for(var w5=w0.uint32()+w0.pos;w0.pos>>3){case 1:w3.group=w10.Group.decode(w0,w0.uint32());break;case 2:if(w3.toLine&&w3.toLine.length||(w3.toLine=[]),2==(7&w4))for(var w5=w0.uint32()+w0.pos;w0.pos>>3){case 1:w3.groupId=w0.string();break;case 2:if(w3.toLine&&w3.toLine.length||(w3.toLine=[]),2==(7&w4))for(var w5=w0.uint32()+w0.pos;w0.pos>>3){case 1:w3.fromUid=w0.string();break;case 2:w3.toUid=w0.string();break;case 3:w3.reason=w0.string();break;case 4:w3.status=w0.int32();break;case 5:w3.updateDt=w0.int64();break;case 6:w3.fromReadStatus=w0.bool();break;case 7:w3.toReadStatus=w0.bool();break;case 8:w3.extra=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("toUid"))throw w9.ProtocolError("missing required 'toUid'",{instance:w3});if(!w3.hasOwnProperty("reason"))throw w9.ProtocolError("missing required 'reason'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":null!=w0.fromUid&&w0.hasOwnProperty("fromUid")&&!w9.isString(w0.fromUid)?"fromUid: string expected":w9.isString(w0.toUid)?w9.isString(w0.reason)?null!=w0.status&&w0.hasOwnProperty("status")&&!w9.isInteger(w0.status)?"status: integer expected":null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&!(w9.isInteger(w0.updateDt)||w0.updateDt&&w9.isInteger(w0.updateDt.low)&&w9.isInteger(w0.updateDt.high))?"updateDt: integer|Long expected":null!=w0.fromReadStatus&&w0.hasOwnProperty("fromReadStatus")&&"boolean"!=typeof w0.fromReadStatus?"fromReadStatus: boolean expected":null!=w0.toReadStatus&&w0.hasOwnProperty("toReadStatus")&&"boolean"!=typeof w0.toReadStatus?"toReadStatus: boolean expected":null!=w0.extra&&w0.hasOwnProperty("extra")&&!w9.isString(w0.extra)?"extra: string expected":null:"reason: string expected":"toUid: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.FriendRequest)return w0;var w1=new w10.FriendRequest;return null!=w0.fromUid&&(w1.fromUid=String(w0.fromUid)),null!=w0.toUid&&(w1.toUid=String(w0.toUid)),null!=w0.reason&&(w1.reason=String(w0.reason)),null!=w0.status&&(w1.status=0|w0.status),null!=w0.updateDt&&(w9.Long?(w1.updateDt=w9.Long.fromValue(w0.updateDt)).unsigned=!1:"string"==typeof w0.updateDt?w1.updateDt=parseInt(w0.updateDt,10):"number"==typeof w0.updateDt?w1.updateDt=w0.updateDt:"object"===(0,w3.default)(w0.updateDt)&&(w1.updateDt=new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber())),null!=w0.fromReadStatus&&(w1.fromReadStatus=Boolean(w0.fromReadStatus)),null!=w0.toReadStatus&&(w1.toReadStatus=Boolean(w0.toReadStatus)),null!=w0.extra&&(w1.extra=String(w0.extra)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w2.fromUid="",w2.toUid="",w2.reason="",w2.status=0,w9.Long){var w3=new w9.Long(0,0,!1);w2.updateDt=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.updateDt=w1.longs===String?"0":0;w2.fromReadStatus=!1,w2.toReadStatus=!1,w2.extra=""}return null!=w0.fromUid&&w0.hasOwnProperty("fromUid")&&(w2.fromUid=w0.fromUid),null!=w0.toUid&&w0.hasOwnProperty("toUid")&&(w2.toUid=w0.toUid),null!=w0.reason&&w0.hasOwnProperty("reason")&&(w2.reason=w0.reason),null!=w0.status&&w0.hasOwnProperty("status")&&(w2.status=w0.status),null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&("number"==typeof w0.updateDt?w2.updateDt=w1.longs===String?String(w0.updateDt):w0.updateDt:w2.updateDt=w1.longs===String?w9.Long.prototype.toString.call(w0.updateDt):w1.longs===Number?new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber():w0.updateDt),null!=w0.fromReadStatus&&w0.hasOwnProperty("fromReadStatus")&&(w2.fromReadStatus=w0.fromReadStatus),null!=w0.toReadStatus&&w0.hasOwnProperty("toReadStatus")&&(w2.toReadStatus=w0.toReadStatus),null!=w0.extra&&w0.hasOwnProperty("extra")&&(w2.extra=w0.extra),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.GeneralResult=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3==1)w3.errorCode=w0.int32();else w0.skipType(7&w4)}if(!w3.hasOwnProperty("errorCode"))throw w9.ProtocolError("missing required 'errorCode'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.errorCode)?null:"errorCode: integer expected"},w0.fromObject=function(w0){if(w0 instanceof w10.GeneralResult)return w0;var w1=new w10.GeneralResult;return null!=w0.errorCode&&(w1.errorCode=0|w0.errorCode),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.errorCode=0),null!=w0.errorCode&&w0.hasOwnProperty("errorCode")&&(w2.errorCode=w0.errorCode),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.GetUploadTokenRequest=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.mediaType=w0.int32();break;case 2:w3.mediaPath=w0.string();break;case 3:w3.contentType=w0.string();break;case 4:w3.messageId=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("mediaType"))throw w9.ProtocolError("missing required 'mediaType'",{instance:w3});if(!w3.hasOwnProperty("mediaPath"))throw w9.ProtocolError("missing required 'mediaPath'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.mediaType)?w9.isString(w0.mediaPath)?null!=w0.contentType&&w0.hasOwnProperty("contentType")&&!w9.isString(w0.contentType)?"contentType: string expected":null!=w0.messageId&&w0.hasOwnProperty("messageId")&&!(w9.isInteger(w0.messageId)||w0.messageId&&w9.isInteger(w0.messageId.low)&&w9.isInteger(w0.messageId.high))?"messageId: integer|Long expected":null:"mediaPath: string expected":"mediaType: integer expected"},w0.fromObject=function(w0){if(w0 instanceof w10.GetUploadTokenRequest)return w0;var w1=new w10.GetUploadTokenRequest;return null!=w0.mediaType&&(w1.mediaType=0|w0.mediaType),null!=w0.mediaPath&&(w1.mediaPath=String(w0.mediaPath)),null!=w0.contentType&&(w1.contentType=String(w0.contentType)),null!=w0.messageId&&(w9.Long?(w1.messageId=w9.Long.fromValue(w0.messageId)).unsigned=!1:"string"==typeof w0.messageId?w1.messageId=parseInt(w0.messageId,10):"number"==typeof w0.messageId?w1.messageId=w0.messageId:"object"===(0,w3.default)(w0.messageId)&&(w1.messageId=new w9.LongBits(w0.messageId.low>>>0,w0.messageId.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults)if(w2.mediaType=0,w2.mediaPath="",w2.contentType="",w9.Long){var w3=new w9.Long(0,0,!1);w2.messageId=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.messageId=w1.longs===String?"0":0;return null!=w0.mediaType&&w0.hasOwnProperty("mediaType")&&(w2.mediaType=w0.mediaType),null!=w0.mediaPath&&w0.hasOwnProperty("mediaPath")&&(w2.mediaPath=w0.mediaPath),null!=w0.contentType&&w0.hasOwnProperty("contentType")&&(w2.contentType=w0.contentType),null!=w0.messageId&&w0.hasOwnProperty("messageId")&&("number"==typeof w0.messageId?w2.messageId=w1.longs===String?String(w0.messageId):w0.messageId:w2.messageId=w1.longs===String?w9.Long.prototype.toString.call(w0.messageId):w1.longs===Number?new w9.LongBits(w0.messageId.low>>>0,w0.messageId.high>>>0).toNumber():w0.messageId),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.GetUploadTokenResult=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.domain=w0.string();break;case 2:w3.token=w0.string();break;case 3:w3.server=w0.string();break;case 4:w3.port=w0.int32();break;case 5:w3.type=w0.int32();break;case 6:w3.date=w0.string();break;case 7:w3.path=w0.string();break;case 8:w3.backupServer=w0.string();break;case 9:w3.backupPort=w0.int32();break;case 10:w3.sslPort=w0.int32();break;case 11:w3.backupSslPort=w0.int32();break;case 12:w3.sslToken=w0.string();break;case 13:w3.backupToken=w0.string();break;case 14:w3.backupSslToken=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("domain"))throw w9.ProtocolError("missing required 'domain'",{instance:w3});if(!w3.hasOwnProperty("token"))throw w9.ProtocolError("missing required 'token'",{instance:w3});if(!w3.hasOwnProperty("server"))throw w9.ProtocolError("missing required 'server'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.domain)?w9.isString(w0.token)?w9.isString(w0.server)?null!=w0.port&&w0.hasOwnProperty("port")&&!w9.isInteger(w0.port)?"port: integer expected":null!=w0.type&&w0.hasOwnProperty("type")&&!w9.isInteger(w0.type)?"type: integer expected":null!=w0.date&&w0.hasOwnProperty("date")&&!w9.isString(w0.date)?"date: string expected":null!=w0.path&&w0.hasOwnProperty("path")&&!w9.isString(w0.path)?"path: string expected":null!=w0.backupServer&&w0.hasOwnProperty("backupServer")&&!w9.isString(w0.backupServer)?"backupServer: string expected":null!=w0.backupPort&&w0.hasOwnProperty("backupPort")&&!w9.isInteger(w0.backupPort)?"backupPort: integer expected":null!=w0.sslPort&&w0.hasOwnProperty("sslPort")&&!w9.isInteger(w0.sslPort)?"sslPort: integer expected":null!=w0.backupSslPort&&w0.hasOwnProperty("backupSslPort")&&!w9.isInteger(w0.backupSslPort)?"backupSslPort: integer expected":null!=w0.sslToken&&w0.hasOwnProperty("sslToken")&&!w9.isString(w0.sslToken)?"sslToken: string expected":null!=w0.backupToken&&w0.hasOwnProperty("backupToken")&&!w9.isString(w0.backupToken)?"backupToken: string expected":null!=w0.backupSslToken&&w0.hasOwnProperty("backupSslToken")&&!w9.isString(w0.backupSslToken)?"backupSslToken: string expected":null:"server: string expected":"token: string expected":"domain: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.GetUploadTokenResult)return w0;var w1=new w10.GetUploadTokenResult;return null!=w0.domain&&(w1.domain=String(w0.domain)),null!=w0.token&&(w1.token=String(w0.token)),null!=w0.server&&(w1.server=String(w0.server)),null!=w0.port&&(w1.port=0|w0.port),null!=w0.type&&(w1.type=0|w0.type),null!=w0.date&&(w1.date=String(w0.date)),null!=w0.path&&(w1.path=String(w0.path)),null!=w0.backupServer&&(w1.backupServer=String(w0.backupServer)),null!=w0.backupPort&&(w1.backupPort=0|w0.backupPort),null!=w0.sslPort&&(w1.sslPort=0|w0.sslPort),null!=w0.backupSslPort&&(w1.backupSslPort=0|w0.backupSslPort),null!=w0.sslToken&&(w1.sslToken=String(w0.sslToken)),null!=w0.backupToken&&(w1.backupToken=String(w0.backupToken)),null!=w0.backupSslToken&&(w1.backupSslToken=String(w0.backupSslToken)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.domain="",w2.token="",w2.server="",w2.port=0,w2.type=0,w2.date="",w2.path="",w2.backupServer="",w2.backupPort=0,w2.sslPort=0,w2.backupSslPort=0,w2.sslToken="",w2.backupToken="",w2.backupSslToken=""),null!=w0.domain&&w0.hasOwnProperty("domain")&&(w2.domain=w0.domain),null!=w0.token&&w0.hasOwnProperty("token")&&(w2.token=w0.token),null!=w0.server&&w0.hasOwnProperty("server")&&(w2.server=w0.server),null!=w0.port&&w0.hasOwnProperty("port")&&(w2.port=w0.port),null!=w0.type&&w0.hasOwnProperty("type")&&(w2.type=w0.type),null!=w0.date&&w0.hasOwnProperty("date")&&(w2.date=w0.date),null!=w0.path&&w0.hasOwnProperty("path")&&(w2.path=w0.path),null!=w0.backupServer&&w0.hasOwnProperty("backupServer")&&(w2.backupServer=w0.backupServer),null!=w0.backupPort&&w0.hasOwnProperty("backupPort")&&(w2.backupPort=w0.backupPort),null!=w0.sslPort&&w0.hasOwnProperty("sslPort")&&(w2.sslPort=w0.sslPort),null!=w0.backupSslPort&&w0.hasOwnProperty("backupSslPort")&&(w2.backupSslPort=w0.backupSslPort),null!=w0.sslToken&&w0.hasOwnProperty("sslToken")&&(w2.sslToken=w0.sslToken),null!=w0.backupToken&&w0.hasOwnProperty("backupToken")&&(w2.backupToken=w0.backupToken),null!=w0.backupSslToken&&w0.hasOwnProperty("backupSslToken")&&(w2.backupSslToken=w0.backupSslToken),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.GetPresignedUrlResult=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.presignedUrl=w0.string();break;case 2:w3.mediaUrl=w0.string();break;case 3:w3.backupPresignedUrl=w0.string();break;case 4:w3.type=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("presignedUrl"))throw w9.ProtocolError("missing required 'presignedUrl'",{instance:w3});if(!w3.hasOwnProperty("mediaUrl"))throw w9.ProtocolError("missing required 'mediaUrl'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.presignedUrl)?w9.isString(w0.mediaUrl)?null!=w0.backupPresignedUrl&&w0.hasOwnProperty("backupPresignedUrl")&&!w9.isString(w0.backupPresignedUrl)?"backupPresignedUrl: string expected":null!=w0.type&&w0.hasOwnProperty("type")&&!w9.isInteger(w0.type)?"type: integer expected":null:"mediaUrl: string expected":"presignedUrl: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.GetPresignedUrlResult)return w0;var w1=new w10.GetPresignedUrlResult;return null!=w0.presignedUrl&&(w1.presignedUrl=String(w0.presignedUrl)),null!=w0.mediaUrl&&(w1.mediaUrl=String(w0.mediaUrl)),null!=w0.backupPresignedUrl&&(w1.backupPresignedUrl=String(w0.backupPresignedUrl)),null!=w0.type&&(w1.type=0|w0.type),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.presignedUrl="",w2.mediaUrl="",w2.backupPresignedUrl="",w2.type=0),null!=w0.presignedUrl&&w0.hasOwnProperty("presignedUrl")&&(w2.presignedUrl=w0.presignedUrl),null!=w0.mediaUrl&&w0.hasOwnProperty("mediaUrl")&&(w2.mediaUrl=w0.mediaUrl),null!=w0.backupPresignedUrl&&w0.hasOwnProperty("backupPresignedUrl")&&(w2.backupPresignedUrl=w0.backupPresignedUrl),null!=w0.type&&w0.hasOwnProperty("type")&&(w2.type=w0.type),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.GetDownloadSignedUrlResult=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.url=w0.string();break;case 2:w3.backupUrl=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("url"))throw w9.ProtocolError("missing required 'url'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.url)?null!=w0.backupUrl&&w0.hasOwnProperty("backupUrl")&&!w9.isString(w0.backupUrl)?"backupUrl: string expected":null:"url: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.GetDownloadSignedUrlResult)return w0;var w1=new w10.GetDownloadSignedUrlResult;return null!=w0.url&&(w1.url=String(w0.url)),null!=w0.backupUrl&&(w1.backupUrl=String(w0.backupUrl)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.url="",w2.backupUrl=""),null!=w0.url&&w0.hasOwnProperty("url")&&(w2.url=w0.url),null!=w0.backupUrl&&w0.hasOwnProperty("backupUrl")&&(w2.backupUrl=w0.backupUrl),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.HandleFriendRequest=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.targetUid=w0.string();break;case 2:w3.status=w0.int32();break;case 3:w3.extra=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("targetUid"))throw w9.ProtocolError("missing required 'targetUid'",{instance:w3});if(!w3.hasOwnProperty("status"))throw w9.ProtocolError("missing required 'status'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.targetUid)?w9.isInteger(w0.status)?null!=w0.extra&&w0.hasOwnProperty("extra")&&!w9.isString(w0.extra)?"extra: string expected":null:"status: integer expected":"targetUid: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.HandleFriendRequest)return w0;var w1=new w10.HandleFriendRequest;return null!=w0.targetUid&&(w1.targetUid=String(w0.targetUid)),null!=w0.status&&(w1.status=0|w0.status),null!=w0.extra&&(w1.extra=String(w0.extra)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.targetUid="",w2.status=0,w2.extra=""),null!=w0.targetUid&&w0.hasOwnProperty("targetUid")&&(w2.targetUid=w0.targetUid),null!=w0.status&&w0.hasOwnProperty("status")&&(w2.status=w0.status),null!=w0.extra&&w0.hasOwnProperty("extra")&&(w2.extra=w0.extra),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.IDBuf=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3==1)w3.id=w0.string();else w0.skipType(7&w4)}if(!w3.hasOwnProperty("id"))throw w9.ProtocolError("missing required 'id'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.id)?null:"id: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.IDBuf)return w0;var w1=new w10.IDBuf;return null!=w0.id&&(w1.id=String(w0.id)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.id=""),null!=w0.id&&w0.hasOwnProperty("id")&&(w2.id=w0.id),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.IDListBuf=function(){function w0(w0){if(this.id=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3==1)w3.id&&w3.id.length||(w3.id=[]),w3.id.push(w0.string());else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.id&&w0.hasOwnProperty("id")){if(!Array.isArray(w0.id))return"id: array expected";for(var w1=0;w1>>3){case 1:w3.conversation=w10.Conversation.decode(w0,w0.uint32());break;case 2:w3.fromUser=w0.string();break;case 3:w3.content=w10.MessageContent.decode(w0,w0.uint32());break;case 4:w3.messageId=w0.int64();break;case 5:w3.serverTimestamp=w0.int64();break;case 6:w3.toUser=w0.string();break;case 7:w3.to&&w3.to.length||(w3.to=[]),w3.to.push(w0.string());break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("conversation"))throw w9.ProtocolError("missing required 'conversation'",{instance:w3});if(!w3.hasOwnProperty("fromUser"))throw w9.ProtocolError("missing required 'fromUser'",{instance:w3});if(!w3.hasOwnProperty("content"))throw w9.ProtocolError("missing required 'content'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";var w1;if(w1=w10.Conversation.verify(w0.conversation))return"conversation."+w1;if(!w9.isString(w0.fromUser))return"fromUser: string expected";if(w1=w10.MessageContent.verify(w0.content))return"content."+w1;if(null!=w0.messageId&&w0.hasOwnProperty("messageId")&&!(w9.isInteger(w0.messageId)||w0.messageId&&w9.isInteger(w0.messageId.low)&&w9.isInteger(w0.messageId.high)))return"messageId: integer|Long expected";if(null!=w0.serverTimestamp&&w0.hasOwnProperty("serverTimestamp")&&!(w9.isInteger(w0.serverTimestamp)||w0.serverTimestamp&&w9.isInteger(w0.serverTimestamp.low)&&w9.isInteger(w0.serverTimestamp.high)))return"serverTimestamp: integer|Long expected";if(null!=w0.toUser&&w0.hasOwnProperty("toUser")&&!w9.isString(w0.toUser))return"toUser: string expected";if(null!=w0.to&&w0.hasOwnProperty("to")){if(!Array.isArray(w0.to))return"to: array expected";for(var w2=0;w2>>0,w0.messageId.high>>>0).toNumber())),null!=w0.serverTimestamp&&(w9.Long?(w1.serverTimestamp=w9.Long.fromValue(w0.serverTimestamp)).unsigned=!1:"string"==typeof w0.serverTimestamp?w1.serverTimestamp=parseInt(w0.serverTimestamp,10):"number"==typeof w0.serverTimestamp?w1.serverTimestamp=w0.serverTimestamp:"object"===(0,w3.default)(w0.serverTimestamp)&&(w1.serverTimestamp=new w9.LongBits(w0.serverTimestamp.low>>>0,w0.serverTimestamp.high>>>0).toNumber())),null!=w0.toUser&&(w1.toUser=String(w0.toUser)),w0.to){if(!Array.isArray(w0.to))throw TypeError(".Message.to: array expected");w1.to=[];for(var w2=0;w2>>0,w0.messageId.high>>>0).toNumber():w0.messageId),null!=w0.serverTimestamp&&w0.hasOwnProperty("serverTimestamp")&&("number"==typeof w0.serverTimestamp?w2.serverTimestamp=w1.longs===String?String(w0.serverTimestamp):w0.serverTimestamp:w2.serverTimestamp=w1.longs===String?w9.Long.prototype.toString.call(w0.serverTimestamp):w1.longs===Number?new w9.LongBits(w0.serverTimestamp.low>>>0,w0.serverTimestamp.high>>>0).toNumber():w0.serverTimestamp),null!=w0.toUser&&w0.hasOwnProperty("toUser")&&(w2.toUser=w0.toUser),w0.to&&w0.to.length){w2.to=[];for(var w4=0;w4>>3){case 1:w3.conversation=w10.Conversation.decode(w0,w0.uint32());break;case 2:w3.fromUser=w0.string();break;case 3:w3.readTime=w0.int64();break;case 4:w3.to&&w3.to.length||(w3.to=[]),w3.to.push(w0.string());break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("conversation"))throw w9.ProtocolError("missing required 'conversation'",{instance:w3});if(!w3.hasOwnProperty("fromUser"))throw w9.ProtocolError("missing required 'fromUser'",{instance:w3});if(!w3.hasOwnProperty("readTime"))throw w9.ProtocolError("missing required 'readTime'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";var w1=w10.Conversation.verify(w0.conversation);if(w1)return"conversation."+w1;if(!w9.isString(w0.fromUser))return"fromUser: string expected";if(!(w9.isInteger(w0.readTime)||w0.readTime&&w9.isInteger(w0.readTime.low)&&w9.isInteger(w0.readTime.high)))return"readTime: integer|Long expected";if(null!=w0.to&&w0.hasOwnProperty("to")){if(!Array.isArray(w0.to))return"to: array expected";for(var w2=0;w2>>0,w0.readTime.high>>>0).toNumber())),w0.to){if(!Array.isArray(w0.to))throw TypeError(".ConvReadRequest.to: array expected");w1.to=[];for(var w2=0;w2>>0,w0.readTime.high>>>0).toNumber():w0.readTime),w0.to&&w0.to.length){w2.to=[];for(var w4=0;w4>>3){case 1:w3.id=w0.int32();break;case 2:w3.conversation=w10.Conversation.decode(w0,w0.uint32());break;case 3:w3.fromUser=w0.string();break;case 4:w3.readTime=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("conversation"))throw w9.ProtocolError("missing required 'conversation'",{instance:w3});if(!w3.hasOwnProperty("fromUser"))throw w9.ProtocolError("missing required 'fromUser'",{instance:w3});if(!w3.hasOwnProperty("readTime"))throw w9.ProtocolError("missing required 'readTime'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.id&&w0.hasOwnProperty("id")&&!w9.isInteger(w0.id))return"id: integer expected";var w1=w10.Conversation.verify(w0.conversation);return w1?"conversation."+w1:w9.isString(w0.fromUser)?w9.isInteger(w0.readTime)||w0.readTime&&w9.isInteger(w0.readTime.low)&&w9.isInteger(w0.readTime.high)?null:"readTime: integer|Long expected":"fromUser: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.ConvRead)return w0;var w1=new w10.ConvRead;if(null!=w0.id&&(w1.id=0|w0.id),null!=w0.conversation){if("object"!==(0,w3.default)(w0.conversation))throw TypeError(".ConvRead.conversation: object expected");w1.conversation=w10.Conversation.fromObject(w0.conversation)}return null!=w0.fromUser&&(w1.fromUser=String(w0.fromUser)),null!=w0.readTime&&(w9.Long?(w1.readTime=w9.Long.fromValue(w0.readTime)).unsigned=!1:"string"==typeof w0.readTime?w1.readTime=parseInt(w0.readTime,10):"number"==typeof w0.readTime?w1.readTime=w0.readTime:"object"===(0,w3.default)(w0.readTime)&&(w1.readTime=new w9.LongBits(w0.readTime.low>>>0,w0.readTime.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults)if(w2.id=0,w2.conversation=null,w2.fromUser="",w9.Long){var w3=new w9.Long(0,0,!1);w2.readTime=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.readTime=w1.longs===String?"0":0;return null!=w0.id&&w0.hasOwnProperty("id")&&(w2.id=w0.id),null!=w0.conversation&&w0.hasOwnProperty("conversation")&&(w2.conversation=w10.Conversation.toObject(w0.conversation,w1)),null!=w0.fromUser&&w0.hasOwnProperty("fromUser")&&(w2.fromUser=w0.fromUser),null!=w0.readTime&&w0.hasOwnProperty("readTime")&&("number"==typeof w0.readTime?w2.readTime=w1.longs===String?String(w0.readTime):w0.readTime:w2.readTime=w1.longs===String?w9.Long.prototype.toString.call(w0.readTime):w1.longs===Number?new w9.LongBits(w0.readTime.low>>>0,w0.readTime.high>>>0).toNumber():w0.readTime),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.Delivery=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.fromUser=w0.string();break;case 2:w3.receiveTime=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("fromUser"))throw w9.ProtocolError("missing required 'fromUser'",{instance:w3});if(!w3.hasOwnProperty("receiveTime"))throw w9.ProtocolError("missing required 'receiveTime'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.fromUser)?w9.isInteger(w0.receiveTime)||w0.receiveTime&&w9.isInteger(w0.receiveTime.low)&&w9.isInteger(w0.receiveTime.high)?null:"receiveTime: integer|Long expected":"fromUser: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.Delivery)return w0;var w1=new w10.Delivery;return null!=w0.fromUser&&(w1.fromUser=String(w0.fromUser)),null!=w0.receiveTime&&(w9.Long?(w1.receiveTime=w9.Long.fromValue(w0.receiveTime)).unsigned=!1:"string"==typeof w0.receiveTime?w1.receiveTime=parseInt(w0.receiveTime,10):"number"==typeof w0.receiveTime?w1.receiveTime=w0.receiveTime:"object"===(0,w3.default)(w0.receiveTime)&&(w1.receiveTime=new w9.LongBits(w0.receiveTime.low>>>0,w0.receiveTime.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults)if(w2.fromUser="",w9.Long){var w3=new w9.Long(0,0,!1);w2.receiveTime=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.receiveTime=w1.longs===String?"0":0;return null!=w0.fromUser&&w0.hasOwnProperty("fromUser")&&(w2.fromUser=w0.fromUser),null!=w0.receiveTime&&w0.hasOwnProperty("receiveTime")&&("number"==typeof w0.receiveTime?w2.receiveTime=w1.longs===String?String(w0.receiveTime):w0.receiveTime:w2.receiveTime=w1.longs===String?w9.Long.prototype.toString.call(w0.receiveTime):w1.longs===Number?new w9.LongBits(w0.receiveTime.low>>>0,w0.receiveTime.high>>>0).toNumber():w0.receiveTime),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.NotifyDelivery=function(){function w0(w0){if(this.target=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.fromUser=w0.string();break;case 2:w3.receiveTime=w0.int64();break;case 3:w3.target&&w3.target.length||(w3.target=[]),w3.target.push(w0.string());break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("fromUser"))throw w9.ProtocolError("missing required 'fromUser'",{instance:w3});if(!w3.hasOwnProperty("receiveTime"))throw w9.ProtocolError("missing required 'receiveTime'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!w9.isString(w0.fromUser))return"fromUser: string expected";if(!(w9.isInteger(w0.receiveTime)||w0.receiveTime&&w9.isInteger(w0.receiveTime.low)&&w9.isInteger(w0.receiveTime.high)))return"receiveTime: integer|Long expected";if(null!=w0.target&&w0.hasOwnProperty("target")){if(!Array.isArray(w0.target))return"target: array expected";for(var w1=0;w1>>0,w0.receiveTime.high>>>0).toNumber())),w0.target){if(!Array.isArray(w0.target))throw TypeError(".NotifyDelivery.target: array expected");w1.target=[];for(var w2=0;w2>>0,w0.receiveTime.high>>>0).toNumber():w0.receiveTime),w0.target&&w0.target.length){w2.target=[];for(var w4=0;w4>>3){case 1:w3.uid=w0.string();break;case 2:w3.name=w0.string();break;case 3:w3.displayName=w0.string();break;case 4:w3.portrait=w0.string();break;case 5:w3.mobile=w0.string();break;case 6:w3.email=w0.string();break;case 7:w3.address=w0.string();break;case 8:w3.company=w0.string();break;case 9:w3.extra=w0.string();break;case 10:w3.updateDt=w0.int64();break;case 11:w3.gender=w0.int32();break;case 12:w3.social=w0.string();break;case 13:w3.type=w0.int32();break;case 14:w3.deleted=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("uid"))throw w9.ProtocolError("missing required 'uid'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.uid)?null!=w0.name&&w0.hasOwnProperty("name")&&!w9.isString(w0.name)?"name: string expected":null!=w0.displayName&&w0.hasOwnProperty("displayName")&&!w9.isString(w0.displayName)?"displayName: string expected":null!=w0.portrait&&w0.hasOwnProperty("portrait")&&!w9.isString(w0.portrait)?"portrait: string expected":null!=w0.mobile&&w0.hasOwnProperty("mobile")&&!w9.isString(w0.mobile)?"mobile: string expected":null!=w0.email&&w0.hasOwnProperty("email")&&!w9.isString(w0.email)?"email: string expected":null!=w0.address&&w0.hasOwnProperty("address")&&!w9.isString(w0.address)?"address: string expected":null!=w0.company&&w0.hasOwnProperty("company")&&!w9.isString(w0.company)?"company: string expected":null!=w0.extra&&w0.hasOwnProperty("extra")&&!w9.isString(w0.extra)?"extra: string expected":null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&!(w9.isInteger(w0.updateDt)||w0.updateDt&&w9.isInteger(w0.updateDt.low)&&w9.isInteger(w0.updateDt.high))?"updateDt: integer|Long expected":null!=w0.gender&&w0.hasOwnProperty("gender")&&!w9.isInteger(w0.gender)?"gender: integer expected":null!=w0.social&&w0.hasOwnProperty("social")&&!w9.isString(w0.social)?"social: string expected":null!=w0.type&&w0.hasOwnProperty("type")&&!w9.isInteger(w0.type)?"type: integer expected":null!=w0.deleted&&w0.hasOwnProperty("deleted")&&!w9.isInteger(w0.deleted)?"deleted: integer expected":null:"uid: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.User)return w0;var w1=new w10.User;return null!=w0.uid&&(w1.uid=String(w0.uid)),null!=w0.name&&(w1.name=String(w0.name)),null!=w0.displayName&&(w1.displayName=String(w0.displayName)),null!=w0.portrait&&(w1.portrait=String(w0.portrait)),null!=w0.mobile&&(w1.mobile=String(w0.mobile)),null!=w0.email&&(w1.email=String(w0.email)),null!=w0.address&&(w1.address=String(w0.address)),null!=w0.company&&(w1.company=String(w0.company)),null!=w0.extra&&(w1.extra=String(w0.extra)),null!=w0.updateDt&&(w9.Long?(w1.updateDt=w9.Long.fromValue(w0.updateDt)).unsigned=!1:"string"==typeof w0.updateDt?w1.updateDt=parseInt(w0.updateDt,10):"number"==typeof w0.updateDt?w1.updateDt=w0.updateDt:"object"===(0,w3.default)(w0.updateDt)&&(w1.updateDt=new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber())),null!=w0.gender&&(w1.gender=0|w0.gender),null!=w0.social&&(w1.social=String(w0.social)),null!=w0.type&&(w1.type=0|w0.type),null!=w0.deleted&&(w1.deleted=0|w0.deleted),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w2.uid="",w2.name="",w2.displayName="",w2.portrait="",w2.mobile="",w2.email="",w2.address="",w2.company="",w2.extra="",w9.Long){var w3=new w9.Long(0,0,!1);w2.updateDt=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.updateDt=w1.longs===String?"0":0;w2.gender=0,w2.social="",w2.type=0,w2.deleted=0}return null!=w0.uid&&w0.hasOwnProperty("uid")&&(w2.uid=w0.uid),null!=w0.name&&w0.hasOwnProperty("name")&&(w2.name=w0.name),null!=w0.displayName&&w0.hasOwnProperty("displayName")&&(w2.displayName=w0.displayName),null!=w0.portrait&&w0.hasOwnProperty("portrait")&&(w2.portrait=w0.portrait),null!=w0.mobile&&w0.hasOwnProperty("mobile")&&(w2.mobile=w0.mobile),null!=w0.email&&w0.hasOwnProperty("email")&&(w2.email=w0.email),null!=w0.address&&w0.hasOwnProperty("address")&&(w2.address=w0.address),null!=w0.company&&w0.hasOwnProperty("company")&&(w2.company=w0.company),null!=w0.extra&&w0.hasOwnProperty("extra")&&(w2.extra=w0.extra),null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&("number"==typeof w0.updateDt?w2.updateDt=w1.longs===String?String(w0.updateDt):w0.updateDt:w2.updateDt=w1.longs===String?w9.Long.prototype.toString.call(w0.updateDt):w1.longs===Number?new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber():w0.updateDt),null!=w0.gender&&w0.hasOwnProperty("gender")&&(w2.gender=w0.gender),null!=w0.social&&w0.hasOwnProperty("social")&&(w2.social=w0.social),null!=w0.type&&w0.hasOwnProperty("type")&&(w2.type=w0.type),null!=w0.deleted&&w0.hasOwnProperty("deleted")&&(w2.deleted=w0.deleted),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.Robot=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.uid=w0.string();break;case 2:w3.state=w0.int32();break;case 3:w3.owner=w0.string();break;case 4:w3.secret=w0.string();break;case 5:w3.callback=w0.string();break;case 6:w3.extra=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("uid"))throw w9.ProtocolError("missing required 'uid'",{instance:w3});if(!w3.hasOwnProperty("state"))throw w9.ProtocolError("missing required 'state'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.uid)?w9.isInteger(w0.state)?null!=w0.owner&&w0.hasOwnProperty("owner")&&!w9.isString(w0.owner)?"owner: string expected":null!=w0.secret&&w0.hasOwnProperty("secret")&&!w9.isString(w0.secret)?"secret: string expected":null!=w0.callback&&w0.hasOwnProperty("callback")&&!w9.isString(w0.callback)?"callback: string expected":null!=w0.extra&&w0.hasOwnProperty("extra")&&!w9.isString(w0.extra)?"extra: string expected":null:"state: integer expected":"uid: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.Robot)return w0;var w1=new w10.Robot;return null!=w0.uid&&(w1.uid=String(w0.uid)),null!=w0.state&&(w1.state=0|w0.state),null!=w0.owner&&(w1.owner=String(w0.owner)),null!=w0.secret&&(w1.secret=String(w0.secret)),null!=w0.callback&&(w1.callback=String(w0.callback)),null!=w0.extra&&(w1.extra=String(w0.extra)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.uid="",w2.state=0,w2.owner="",w2.secret="",w2.callback="",w2.extra=""),null!=w0.uid&&w0.hasOwnProperty("uid")&&(w2.uid=w0.uid),null!=w0.state&&w0.hasOwnProperty("state")&&(w2.state=w0.state),null!=w0.owner&&w0.hasOwnProperty("owner")&&(w2.owner=w0.owner),null!=w0.secret&&w0.hasOwnProperty("secret")&&(w2.secret=w0.secret),null!=w0.callback&&w0.hasOwnProperty("callback")&&(w2.callback=w0.callback),null!=w0.extra&&w0.hasOwnProperty("extra")&&(w2.extra=w0.extra),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.GetRobotsResult=function(){function w0(w0){if(this.entry=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3==1)w3.entry&&w3.entry.length||(w3.entry=[]),w3.entry.push(w10.Robot.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.entry&&w0.hasOwnProperty("entry")){if(!Array.isArray(w0.entry))return"entry: array expected";for(var w1=0;w1>>3){case 1:w3.uid=w0.string();break;case 2:w3.state=w0.int32();break;case 3:w3.token=w0.string();break;case 4:w3.owner&&w3.owner.length||(w3.owner=[]),w3.owner.push(w0.string());break;case 5:w3.extra=w0.string();break;case 6:w3.updateDt=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("uid"))throw w9.ProtocolError("missing required 'uid'",{instance:w3});if(!w3.hasOwnProperty("state"))throw w9.ProtocolError("missing required 'state'",{instance:w3});if(!w3.hasOwnProperty("token"))throw w9.ProtocolError("missing required 'token'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!w9.isString(w0.uid))return"uid: string expected";if(!w9.isInteger(w0.state))return"state: integer expected";if(!w9.isString(w0.token))return"token: string expected";if(null!=w0.owner&&w0.hasOwnProperty("owner")){if(!Array.isArray(w0.owner))return"owner: array expected";for(var w1=0;w1>>0,w0.updateDt.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if((w1.arrays||w1.defaults)&&(w2.owner=[]),w1.defaults)if(w2.uid="",w2.state=0,w2.token="",w2.extra="",w9.Long){var w3=new w9.Long(0,0,!1);w2.updateDt=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.updateDt=w1.longs===String?"0":0;if(null!=w0.uid&&w0.hasOwnProperty("uid")&&(w2.uid=w0.uid),null!=w0.state&&w0.hasOwnProperty("state")&&(w2.state=w0.state),null!=w0.token&&w0.hasOwnProperty("token")&&(w2.token=w0.token),w0.owner&&w0.owner.length){w2.owner=[];for(var w4=0;w4>>0,w0.updateDt.high>>>0).toNumber():w0.updateDt),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.GetDeviceResult=function(){function w0(w0){if(this.entry=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3==1)w3.entry&&w3.entry.length||(w3.entry=[]),w3.entry.push(w10.Device.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.entry&&w0.hasOwnProperty("entry")){if(!Array.isArray(w0.entry))return"entry: array expected";for(var w1=0;w1>>3){case 1:w3.platform=w0.int32();break;case 2:w3.appName=w0.string();break;case 3:w3.deviceToken=w0.string();break;case 4:w3.pushType=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("platform"))throw w9.ProtocolError("missing required 'platform'",{instance:w3});if(!w3.hasOwnProperty("appName"))throw w9.ProtocolError("missing required 'appName'",{instance:w3});if(!w3.hasOwnProperty("deviceToken"))throw w9.ProtocolError("missing required 'deviceToken'",{instance:w3});if(!w3.hasOwnProperty("pushType"))throw w9.ProtocolError("missing required 'pushType'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.platform)?w9.isString(w0.appName)?w9.isString(w0.deviceToken)?w9.isInteger(w0.pushType)?null:"pushType: integer expected":"deviceToken: string expected":"appName: string expected":"platform: integer expected"},w0.fromObject=function(w0){if(w0 instanceof w10.UploadDeviceTokenRequest)return w0;var w1=new w10.UploadDeviceTokenRequest;return null!=w0.platform&&(w1.platform=0|w0.platform),null!=w0.appName&&(w1.appName=String(w0.appName)),null!=w0.deviceToken&&(w1.deviceToken=String(w0.deviceToken)),null!=w0.pushType&&(w1.pushType=0|w0.pushType),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.platform=0,w2.appName="",w2.deviceToken="",w2.pushType=0),null!=w0.platform&&w0.hasOwnProperty("platform")&&(w2.platform=w0.platform),null!=w0.appName&&w0.hasOwnProperty("appName")&&(w2.appName=w0.appName),null!=w0.deviceToken&&w0.hasOwnProperty("deviceToken")&&(w2.deviceToken=w0.deviceToken),null!=w0.pushType&&w0.hasOwnProperty("pushType")&&(w2.pushType=w0.pushType),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.ModifyGroupInfoRequest=function(){function w0(w0){if(this.toLine=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.groupId=w0.string();break;case 2:w3.type=w0.int32();break;case 3:w3.value=w0.string();break;case 4:if(w3.toLine&&w3.toLine.length||(w3.toLine=[]),2==(7&w4))for(var w5=w0.uint32()+w0.pos;w0.pos>>3){case 1:w3.groupId=w0.string();break;case 2:w3.type=w0.int32();break;case 3:w3.userId&&w3.userId.length||(w3.userId=[]),w3.userId.push(w0.string());break;case 4:if(w3.toLine&&w3.toLine.length||(w3.toLine=[]),2==(7&w4))for(var w5=w0.uint32()+w0.pos;w0.pos>>3){case 1:w3.type=w0.int32();break;case 2:w3.value=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("type"))throw w9.ProtocolError("missing required 'type'",{instance:w3});if(!w3.hasOwnProperty("value"))throw w9.ProtocolError("missing required 'value'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.type)?w9.isString(w0.value)?null:"value: string expected":"type: integer expected"},w0.fromObject=function(w0){if(w0 instanceof w10.InfoEntry)return w0;var w1=new w10.InfoEntry;return null!=w0.type&&(w1.type=0|w0.type),null!=w0.value&&(w1.value=String(w0.value)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.type=0,w2.value=""),null!=w0.type&&w0.hasOwnProperty("type")&&(w2.type=w0.type),null!=w0.value&&w0.hasOwnProperty("value")&&(w2.value=w0.value),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.ModifyMyInfoRequest=function(){function w0(w0){if(this.entry=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3==1)w3.entry&&w3.entry.length||(w3.entry=[]),w3.entry.push(w10.InfoEntry.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.entry&&w0.hasOwnProperty("entry")){if(!Array.isArray(w0.entry))return"entry: array expected";for(var w1=0;w1>>3){case 1:w3.type=w0.int32();break;case 2:w3.head=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("type"))throw w9.ProtocolError("missing required 'type'",{instance:w3});if(!w3.hasOwnProperty("head"))throw w9.ProtocolError("missing required 'head'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.type)?w9.isInteger(w0.head)||w0.head&&w9.isInteger(w0.head.low)&&w9.isInteger(w0.head.high)?null:"head: integer|Long expected":"type: integer expected"},w0.fromObject=function(w0){if(w0 instanceof w10.NotifyMessage)return w0;var w1=new w10.NotifyMessage;return null!=w0.type&&(w1.type=0|w0.type),null!=w0.head&&(w9.Long?(w1.head=w9.Long.fromValue(w0.head)).unsigned=!1:"string"==typeof w0.head?w1.head=parseInt(w0.head,10):"number"==typeof w0.head?w1.head=w0.head:"object"===(0,w3.default)(w0.head)&&(w1.head=new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults)if(w2.type=0,w9.Long){var w3=new w9.Long(0,0,!1);w2.head=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.head=w1.longs===String?"0":0;return null!=w0.type&&w0.hasOwnProperty("type")&&(w2.type=w0.type),null!=w0.head&&w0.hasOwnProperty("head")&&("number"==typeof w0.head?w2.head=w1.longs===String?String(w0.head):w0.head:w2.head=w1.longs===String?w9.Long.prototype.toString.call(w0.head):w1.longs===Number?new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber():w0.head),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.NotifyGroupMessage=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.head=w0.int64();break;case 2:w3.target=w0.string();break;case 3:w3.line=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("head"))throw w9.ProtocolError("missing required 'head'",{instance:w3});if(!w3.hasOwnProperty("target"))throw w9.ProtocolError("missing required 'target'",{instance:w3});if(!w3.hasOwnProperty("line"))throw w9.ProtocolError("missing required 'line'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.head)||w0.head&&w9.isInteger(w0.head.low)&&w9.isInteger(w0.head.high)?w9.isString(w0.target)?w9.isInteger(w0.line)?null:"line: integer expected":"target: string expected":"head: integer|Long expected"},w0.fromObject=function(w0){if(w0 instanceof w10.NotifyGroupMessage)return w0;var w1=new w10.NotifyGroupMessage;return null!=w0.head&&(w9.Long?(w1.head=w9.Long.fromValue(w0.head)).unsigned=!1:"string"==typeof w0.head?w1.head=parseInt(w0.head,10):"number"==typeof w0.head?w1.head=w0.head:"object"===(0,w3.default)(w0.head)&&(w1.head=new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber())),null!=w0.target&&(w1.target=String(w0.target)),null!=w0.line&&(w1.line=0|w0.line),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w9.Long){var w3=new w9.Long(0,0,!1);w2.head=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.head=w1.longs===String?"0":0;w2.target="",w2.line=0}return null!=w0.head&&w0.hasOwnProperty("head")&&("number"==typeof w0.head?w2.head=w1.longs===String?String(w0.head):w0.head:w2.head=w1.longs===String?w9.Long.prototype.toString.call(w0.head):w1.longs===Number?new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber():w0.head),null!=w0.target&&w0.hasOwnProperty("target")&&(w2.target=w0.target),null!=w0.line&&w0.hasOwnProperty("line")&&(w2.line=w0.line),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PullMessageRequest=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.id=w0.int64();break;case 2:w3.type=w0.int32();break;case 3:w3.delay=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("id"))throw w9.ProtocolError("missing required 'id'",{instance:w3});if(!w3.hasOwnProperty("type"))throw w9.ProtocolError("missing required 'type'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.id)||w0.id&&w9.isInteger(w0.id.low)&&w9.isInteger(w0.id.high)?w9.isInteger(w0.type)?null!=w0.delay&&w0.hasOwnProperty("delay")&&!(w9.isInteger(w0.delay)||w0.delay&&w9.isInteger(w0.delay.low)&&w9.isInteger(w0.delay.high))?"delay: integer|Long expected":null:"type: integer expected":"id: integer|Long expected"},w0.fromObject=function(w0){if(w0 instanceof w10.PullMessageRequest)return w0;var w1=new w10.PullMessageRequest;return null!=w0.id&&(w9.Long?(w1.id=w9.Long.fromValue(w0.id)).unsigned=!1:"string"==typeof w0.id?w1.id=parseInt(w0.id,10):"number"==typeof w0.id?w1.id=w0.id:"object"===(0,w3.default)(w0.id)&&(w1.id=new w9.LongBits(w0.id.low>>>0,w0.id.high>>>0).toNumber())),null!=w0.type&&(w1.type=0|w0.type),null!=w0.delay&&(w9.Long?(w1.delay=w9.Long.fromValue(w0.delay)).unsigned=!1:"string"==typeof w0.delay?w1.delay=parseInt(w0.delay,10):"number"==typeof w0.delay?w1.delay=w0.delay:"object"===(0,w3.default)(w0.delay)&&(w1.delay=new w9.LongBits(w0.delay.low>>>0,w0.delay.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w9.Long){var w3=new w9.Long(0,0,!1);w2.id=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.id=w1.longs===String?"0":0;if(w2.type=0,w9.Long){w3=new w9.Long(0,0,!1);w2.delay=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.delay=w1.longs===String?"0":0}return null!=w0.id&&w0.hasOwnProperty("id")&&("number"==typeof w0.id?w2.id=w1.longs===String?String(w0.id):w0.id:w2.id=w1.longs===String?w9.Long.prototype.toString.call(w0.id):w1.longs===Number?new w9.LongBits(w0.id.low>>>0,w0.id.high>>>0).toNumber():w0.id),null!=w0.type&&w0.hasOwnProperty("type")&&(w2.type=w0.type),null!=w0.delay&&w0.hasOwnProperty("delay")&&("number"==typeof w0.delay?w2.delay=w1.longs===String?String(w0.delay):w0.delay:w2.delay=w1.longs===String?w9.Long.prototype.toString.call(w0.delay):w1.longs===Number?new w9.LongBits(w0.delay.low>>>0,w0.delay.high>>>0).toNumber():w0.delay),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PullMessageResult=function(){function w0(w0){if(this.message=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.message&&w3.message.length||(w3.message=[]),w3.message.push(w10.Message.decode(w0,w0.uint32()));break;case 2:w3.current=w0.int64();break;case 3:w3.head=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("current"))throw w9.ProtocolError("missing required 'current'",{instance:w3});if(!w3.hasOwnProperty("head"))throw w9.ProtocolError("missing required 'head'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.message&&w0.hasOwnProperty("message")){if(!Array.isArray(w0.message))return"message: array expected";for(var w1=0;w1>>0,w0.current.high>>>0).toNumber())),null!=w0.head&&(w9.Long?(w1.head=w9.Long.fromValue(w0.head)).unsigned=!1:"string"==typeof w0.head?w1.head=parseInt(w0.head,10):"number"==typeof w0.head?w1.head=w0.head:"object"===(0,w3.default)(w0.head)&&(w1.head=new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if((w1.arrays||w1.defaults)&&(w2.message=[]),w1.defaults){if(w9.Long){var w3=new w9.Long(0,0,!1);w2.current=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.current=w1.longs===String?"0":0;if(w9.Long){w3=new w9.Long(0,0,!1);w2.head=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.head=w1.longs===String?"0":0}if(w0.message&&w0.message.length){w2.message=[];for(var w4=0;w4>>0,w0.current.high>>>0).toNumber():w0.current),null!=w0.head&&w0.hasOwnProperty("head")&&("number"==typeof w0.head?w2.head=w1.longs===String?String(w0.head):w0.head:w2.head=w1.longs===String?w9.Long.prototype.toString.call(w0.head):w1.longs===Number?new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber():w0.head),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PullReadResult=function(){function w0(w0){if(this.read=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.read&&w3.read.length||(w3.read=[]),w3.read.push(w10.ConvRead.decode(w0,w0.uint32()));break;case 2:w3.current=w0.int64();break;case 3:w3.head=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("current"))throw w9.ProtocolError("missing required 'current'",{instance:w3});if(!w3.hasOwnProperty("head"))throw w9.ProtocolError("missing required 'head'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.read&&w0.hasOwnProperty("read")){if(!Array.isArray(w0.read))return"read: array expected";for(var w1=0;w1>>0,w0.current.high>>>0).toNumber())),null!=w0.head&&(w9.Long?(w1.head=w9.Long.fromValue(w0.head)).unsigned=!1:"string"==typeof w0.head?w1.head=parseInt(w0.head,10):"number"==typeof w0.head?w1.head=w0.head:"object"===(0,w3.default)(w0.head)&&(w1.head=new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if((w1.arrays||w1.defaults)&&(w2.read=[]),w1.defaults){if(w9.Long){var w3=new w9.Long(0,0,!1);w2.current=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.current=w1.longs===String?"0":0;if(w9.Long){w3=new w9.Long(0,0,!1);w2.head=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.head=w1.longs===String?"0":0}if(w0.read&&w0.read.length){w2.read=[];for(var w4=0;w4>>0,w0.current.high>>>0).toNumber():w0.current),null!=w0.head&&w0.hasOwnProperty("head")&&("number"==typeof w0.head?w2.head=w1.longs===String?String(w0.head):w0.head:w2.head=w1.longs===String?w9.Long.prototype.toString.call(w0.head):w1.longs===Number?new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber():w0.head),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PullDeliveryResult=function(){function w0(w0){if(this.delivery=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.delivery&&w3.delivery.length||(w3.delivery=[]),w3.delivery.push(w10.Delivery.decode(w0,w0.uint32()));break;case 2:w3.current=w0.int64();break;case 3:w3.head=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("current"))throw w9.ProtocolError("missing required 'current'",{instance:w3});if(!w3.hasOwnProperty("head"))throw w9.ProtocolError("missing required 'head'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.delivery&&w0.hasOwnProperty("delivery")){if(!Array.isArray(w0.delivery))return"delivery: array expected";for(var w1=0;w1>>0,w0.current.high>>>0).toNumber())),null!=w0.head&&(w9.Long?(w1.head=w9.Long.fromValue(w0.head)).unsigned=!1:"string"==typeof w0.head?w1.head=parseInt(w0.head,10):"number"==typeof w0.head?w1.head=w0.head:"object"===(0,w3.default)(w0.head)&&(w1.head=new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if((w1.arrays||w1.defaults)&&(w2.delivery=[]),w1.defaults){if(w9.Long){var w3=new w9.Long(0,0,!1);w2.current=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.current=w1.longs===String?"0":0;if(w9.Long){w3=new w9.Long(0,0,!1);w2.head=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.head=w1.longs===String?"0":0}if(w0.delivery&&w0.delivery.length){w2.delivery=[];for(var w4=0;w4>>0,w0.current.high>>>0).toNumber():w0.current),null!=w0.head&&w0.hasOwnProperty("head")&&("number"==typeof w0.head?w2.head=w1.longs===String?String(w0.head):w0.head:w2.head=w1.longs===String?w9.Long.prototype.toString.call(w0.head):w1.longs===Number?new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber():w0.head),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.GroupConv=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.line=w0.int32();break;case 2:w3.groupId=w0.string();break;case 3:w3.msgHead=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("line"))throw w9.ProtocolError("missing required 'line'",{instance:w3});if(!w3.hasOwnProperty("groupId"))throw w9.ProtocolError("missing required 'groupId'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.line)?w9.isString(w0.groupId)?null!=w0.msgHead&&w0.hasOwnProperty("msgHead")&&!(w9.isInteger(w0.msgHead)||w0.msgHead&&w9.isInteger(w0.msgHead.low)&&w9.isInteger(w0.msgHead.high))?"msgHead: integer|Long expected":null:"groupId: string expected":"line: integer expected"},w0.fromObject=function(w0){if(w0 instanceof w10.GroupConv)return w0;var w1=new w10.GroupConv;return null!=w0.line&&(w1.line=0|w0.line),null!=w0.groupId&&(w1.groupId=String(w0.groupId)),null!=w0.msgHead&&(w9.Long?(w1.msgHead=w9.Long.fromValue(w0.msgHead)).unsigned=!1:"string"==typeof w0.msgHead?w1.msgHead=parseInt(w0.msgHead,10):"number"==typeof w0.msgHead?w1.msgHead=w0.msgHead:"object"===(0,w3.default)(w0.msgHead)&&(w1.msgHead=new w9.LongBits(w0.msgHead.low>>>0,w0.msgHead.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults)if(w2.line=0,w2.groupId="",w9.Long){var w3=new w9.Long(0,0,!1);w2.msgHead=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.msgHead=w1.longs===String?"0":0;return null!=w0.line&&w0.hasOwnProperty("line")&&(w2.line=w0.line),null!=w0.groupId&&w0.hasOwnProperty("groupId")&&(w2.groupId=w0.groupId),null!=w0.msgHead&&w0.hasOwnProperty("msgHead")&&("number"==typeof w0.msgHead?w2.msgHead=w1.longs===String?String(w0.msgHead):w0.msgHead:w2.msgHead=w1.longs===String?w9.Long.prototype.toString.call(w0.msgHead):w1.longs===Number?new w9.LongBits(w0.msgHead.low>>>0,w0.msgHead.high>>>0).toNumber():w0.msgHead),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PullGroupConvRequest=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.id=w0.int64();break;case 2:w3.target=w0.string();break;case 3:w3.line=w0.int32();break;case 4:w3.messageId=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("id"))throw w9.ProtocolError("missing required 'id'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.id)||w0.id&&w9.isInteger(w0.id.low)&&w9.isInteger(w0.id.high)?null!=w0.target&&w0.hasOwnProperty("target")&&!w9.isString(w0.target)?"target: string expected":null!=w0.line&&w0.hasOwnProperty("line")&&!w9.isInteger(w0.line)?"line: integer expected":null!=w0.messageId&&w0.hasOwnProperty("messageId")&&!(w9.isInteger(w0.messageId)||w0.messageId&&w9.isInteger(w0.messageId.low)&&w9.isInteger(w0.messageId.high))?"messageId: integer|Long expected":null:"id: integer|Long expected"},w0.fromObject=function(w0){if(w0 instanceof w10.PullGroupConvRequest)return w0;var w1=new w10.PullGroupConvRequest;return null!=w0.id&&(w9.Long?(w1.id=w9.Long.fromValue(w0.id)).unsigned=!1:"string"==typeof w0.id?w1.id=parseInt(w0.id,10):"number"==typeof w0.id?w1.id=w0.id:"object"===(0,w3.default)(w0.id)&&(w1.id=new w9.LongBits(w0.id.low>>>0,w0.id.high>>>0).toNumber())),null!=w0.target&&(w1.target=String(w0.target)),null!=w0.line&&(w1.line=0|w0.line),null!=w0.messageId&&(w9.Long?(w1.messageId=w9.Long.fromValue(w0.messageId)).unsigned=!1:"string"==typeof w0.messageId?w1.messageId=parseInt(w0.messageId,10):"number"==typeof w0.messageId?w1.messageId=w0.messageId:"object"===(0,w3.default)(w0.messageId)&&(w1.messageId=new w9.LongBits(w0.messageId.low>>>0,w0.messageId.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w9.Long){var w3=new w9.Long(0,0,!1);w2.id=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.id=w1.longs===String?"0":0;if(w2.target="",w2.line=0,w9.Long){w3=new w9.Long(0,0,!1);w2.messageId=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.messageId=w1.longs===String?"0":0}return null!=w0.id&&w0.hasOwnProperty("id")&&("number"==typeof w0.id?w2.id=w1.longs===String?String(w0.id):w0.id:w2.id=w1.longs===String?w9.Long.prototype.toString.call(w0.id):w1.longs===Number?new w9.LongBits(w0.id.low>>>0,w0.id.high>>>0).toNumber():w0.id),null!=w0.target&&w0.hasOwnProperty("target")&&(w2.target=w0.target),null!=w0.line&&w0.hasOwnProperty("line")&&(w2.line=w0.line),null!=w0.messageId&&w0.hasOwnProperty("messageId")&&("number"==typeof w0.messageId?w2.messageId=w1.longs===String?String(w0.messageId):w0.messageId:w2.messageId=w1.longs===String?w9.Long.prototype.toString.call(w0.messageId):w1.longs===Number?new w9.LongBits(w0.messageId.low>>>0,w0.messageId.high>>>0).toNumber():w0.messageId),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PullGroupConvResult=function(){function w0(w0){if(this.conv=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.conv&&w3.conv.length||(w3.conv=[]),w3.conv.push(w10.GroupConv.decode(w0,w0.uint32()));break;case 2:w3.current=w0.int64();break;case 3:w3.head=w0.int64();break;case 4:w3.groupMessage=w10.PullGroupMessageResult.decode(w0,w0.uint32());break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("current"))throw w9.ProtocolError("missing required 'current'",{instance:w3});if(!w3.hasOwnProperty("head"))throw w9.ProtocolError("missing required 'head'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.conv&&w0.hasOwnProperty("conv")){if(!Array.isArray(w0.conv))return"conv: array expected";for(var w1=0;w1>>0,w0.current.high>>>0).toNumber())),null!=w0.head&&(w9.Long?(w1.head=w9.Long.fromValue(w0.head)).unsigned=!1:"string"==typeof w0.head?w1.head=parseInt(w0.head,10):"number"==typeof w0.head?w1.head=w0.head:"object"===(0,w3.default)(w0.head)&&(w1.head=new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber())),null!=w0.groupMessage){if("object"!==(0,w3.default)(w0.groupMessage))throw TypeError(".PullGroupConvResult.groupMessage: object expected");w1.groupMessage=w10.PullGroupMessageResult.fromObject(w0.groupMessage)}return w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if((w1.arrays||w1.defaults)&&(w2.conv=[]),w1.defaults){if(w9.Long){var w3=new w9.Long(0,0,!1);w2.current=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.current=w1.longs===String?"0":0;if(w9.Long){w3=new w9.Long(0,0,!1);w2.head=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.head=w1.longs===String?"0":0;w2.groupMessage=null}if(w0.conv&&w0.conv.length){w2.conv=[];for(var w4=0;w4>>0,w0.current.high>>>0).toNumber():w0.current),null!=w0.head&&w0.hasOwnProperty("head")&&("number"==typeof w0.head?w2.head=w1.longs===String?String(w0.head):w0.head:w2.head=w1.longs===String?w9.Long.prototype.toString.call(w0.head):w1.longs===Number?new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber():w0.head),null!=w0.groupMessage&&w0.hasOwnProperty("groupMessage")&&(w2.groupMessage=w10.PullGroupMessageResult.toObject(w0.groupMessage,w1)),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PullGroupMessageRequest=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.groupId=w0.string();break;case 2:w3.line=w0.int32();break;case 3:w3.id=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("groupId"))throw w9.ProtocolError("missing required 'groupId'",{instance:w3});if(!w3.hasOwnProperty("line"))throw w9.ProtocolError("missing required 'line'",{instance:w3});if(!w3.hasOwnProperty("id"))throw w9.ProtocolError("missing required 'id'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.groupId)?w9.isInteger(w0.line)?w9.isInteger(w0.id)||w0.id&&w9.isInteger(w0.id.low)&&w9.isInteger(w0.id.high)?null:"id: integer|Long expected":"line: integer expected":"groupId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.PullGroupMessageRequest)return w0;var w1=new w10.PullGroupMessageRequest;return null!=w0.groupId&&(w1.groupId=String(w0.groupId)),null!=w0.line&&(w1.line=0|w0.line),null!=w0.id&&(w9.Long?(w1.id=w9.Long.fromValue(w0.id)).unsigned=!1:"string"==typeof w0.id?w1.id=parseInt(w0.id,10):"number"==typeof w0.id?w1.id=w0.id:"object"===(0,w3.default)(w0.id)&&(w1.id=new w9.LongBits(w0.id.low>>>0,w0.id.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults)if(w2.groupId="",w2.line=0,w9.Long){var w3=new w9.Long(0,0,!1);w2.id=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.id=w1.longs===String?"0":0;return null!=w0.groupId&&w0.hasOwnProperty("groupId")&&(w2.groupId=w0.groupId),null!=w0.line&&w0.hasOwnProperty("line")&&(w2.line=w0.line),null!=w0.id&&w0.hasOwnProperty("id")&&("number"==typeof w0.id?w2.id=w1.longs===String?String(w0.id):w0.id:w2.id=w1.longs===String?w9.Long.prototype.toString.call(w0.id):w1.longs===Number?new w9.LongBits(w0.id.low>>>0,w0.id.high>>>0).toNumber():w0.id),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PullGroupMessageRequests=function(){function w0(w0){if(this.request=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3==1)w3.request&&w3.request.length||(w3.request=[]),w3.request.push(w10.PullGroupMessageRequest.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.request&&w0.hasOwnProperty("request")){if(!Array.isArray(w0.request))return"request: array expected";for(var w1=0;w1>>3){case 1:w3.messageId=w0.int64();break;case 2:w3.fromUser=w0.string();break;case 3:w3.flag=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("messageId"))throw w9.ProtocolError("missing required 'messageId'",{instance:w3});if(!w3.hasOwnProperty("fromUser"))throw w9.ProtocolError("missing required 'fromUser'",{instance:w3});if(!w3.hasOwnProperty("flag"))throw w9.ProtocolError("missing required 'flag'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.messageId)||w0.messageId&&w9.isInteger(w0.messageId.low)&&w9.isInteger(w0.messageId.high)?w9.isString(w0.fromUser)?w9.isInteger(w0.flag)?null:"flag: integer expected":"fromUser: string expected":"messageId: integer|Long expected"},w0.fromObject=function(w0){if(w0 instanceof w10.GroupMessage)return w0;var w1=new w10.GroupMessage;return null!=w0.messageId&&(w9.Long?(w1.messageId=w9.Long.fromValue(w0.messageId)).unsigned=!1:"string"==typeof w0.messageId?w1.messageId=parseInt(w0.messageId,10):"number"==typeof w0.messageId?w1.messageId=w0.messageId:"object"===(0,w3.default)(w0.messageId)&&(w1.messageId=new w9.LongBits(w0.messageId.low>>>0,w0.messageId.high>>>0).toNumber())),null!=w0.fromUser&&(w1.fromUser=String(w0.fromUser)),null!=w0.flag&&(w1.flag=0|w0.flag),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w9.Long){var w3=new w9.Long(0,0,!1);w2.messageId=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.messageId=w1.longs===String?"0":0;w2.fromUser="",w2.flag=0}return null!=w0.messageId&&w0.hasOwnProperty("messageId")&&("number"==typeof w0.messageId?w2.messageId=w1.longs===String?String(w0.messageId):w0.messageId:w2.messageId=w1.longs===String?w9.Long.prototype.toString.call(w0.messageId):w1.longs===Number?new w9.LongBits(w0.messageId.low>>>0,w0.messageId.high>>>0).toNumber():w0.messageId),null!=w0.fromUser&&w0.hasOwnProperty("fromUser")&&(w2.fromUser=w0.fromUser),null!=w0.flag&&w0.hasOwnProperty("flag")&&(w2.flag=w0.flag),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PullGroupMessageResult=function(){function w0(w0){if(this.message=[],this.msg=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.message&&w3.message.length||(w3.message=[]),w3.message.push(w10.GroupMessage.decode(w0,w0.uint32()));break;case 2:w3.current=w0.int64();break;case 3:w3.head=w0.int64();break;case 4:w3.groupId=w0.string();break;case 5:w3.line=w0.int32();break;case 6:w3.msg&&w3.msg.length||(w3.msg=[]),w3.msg.push(w10.Message.decode(w0,w0.uint32()));break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("current"))throw w9.ProtocolError("missing required 'current'",{instance:w3});if(!w3.hasOwnProperty("head"))throw w9.ProtocolError("missing required 'head'",{instance:w3});if(!w3.hasOwnProperty("groupId"))throw w9.ProtocolError("missing required 'groupId'",{instance:w3});if(!w3.hasOwnProperty("line"))throw w9.ProtocolError("missing required 'line'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.message&&w0.hasOwnProperty("message")){if(!Array.isArray(w0.message))return"message: array expected";for(var w1=0;w1>>0,w0.current.high>>>0).toNumber())),null!=w0.head&&(w9.Long?(w1.head=w9.Long.fromValue(w0.head)).unsigned=!1:"string"==typeof w0.head?w1.head=parseInt(w0.head,10):"number"==typeof w0.head?w1.head=w0.head:"object"===(0,w3.default)(w0.head)&&(w1.head=new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber())),null!=w0.groupId&&(w1.groupId=String(w0.groupId)),null!=w0.line&&(w1.line=0|w0.line),w0.msg){if(!Array.isArray(w0.msg))throw TypeError(".PullGroupMessageResult.msg: array expected");w1.msg=[];for(w2=0;w2>>0,w0.current.high>>>0).toNumber():w0.current),null!=w0.head&&w0.hasOwnProperty("head")&&("number"==typeof w0.head?w2.head=w1.longs===String?String(w0.head):w0.head:w2.head=w1.longs===String?w9.Long.prototype.toString.call(w0.head):w1.longs===Number?new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber():w0.head),null!=w0.groupId&&w0.hasOwnProperty("groupId")&&(w2.groupId=w0.groupId),null!=w0.line&&w0.hasOwnProperty("line")&&(w2.line=w0.line),w0.msg&&w0.msg.length){w2.msg=[];for(w4=0;w4>>3==1)w3.result&&w3.result.length||(w3.result=[]),w3.result.push(w10.PullGroupMessageResult.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.result&&w0.hasOwnProperty("result")){if(!Array.isArray(w0.result))return"result: array expected";for(var w1=0;w1>>3==1)w3.message&&w3.message.length||(w3.message=[]),w3.message.push(w10.Message.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.message&&w0.hasOwnProperty("message")){if(!Array.isArray(w0.message))return"message: array expected";for(var w1=0;w1>>3==1)w3.info&&w3.info.length||(w3.info=[]),w3.info.push(w10.GroupInfo.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.info&&w0.hasOwnProperty("info")){if(!Array.isArray(w0.info))return"info: array expected";for(var w1=0;w1>>3){case 1:w3.target=w0.string();break;case 2:w3.head=w0.int64();break;case 3:w3.sum=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("target"))throw w9.ProtocolError("missing required 'target'",{instance:w3});if(!w3.hasOwnProperty("head"))throw w9.ProtocolError("missing required 'head'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.target)?w9.isInteger(w0.head)||w0.head&&w9.isInteger(w0.head.low)&&w9.isInteger(w0.head.high)?null!=w0.sum&&w0.hasOwnProperty("sum")&&!(w9.isInteger(w0.sum)||w0.sum&&w9.isInteger(w0.sum.low)&&w9.isInteger(w0.sum.high))?"sum: integer|Long expected":null:"head: integer|Long expected":"target: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.PullGroupMemberRequest)return w0;var w1=new w10.PullGroupMemberRequest;return null!=w0.target&&(w1.target=String(w0.target)),null!=w0.head&&(w9.Long?(w1.head=w9.Long.fromValue(w0.head)).unsigned=!1:"string"==typeof w0.head?w1.head=parseInt(w0.head,10):"number"==typeof w0.head?w1.head=w0.head:"object"===(0,w3.default)(w0.head)&&(w1.head=new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber())),null!=w0.sum&&(w9.Long?(w1.sum=w9.Long.fromValue(w0.sum)).unsigned=!1:"string"==typeof w0.sum?w1.sum=parseInt(w0.sum,10):"number"==typeof w0.sum?w1.sum=w0.sum:"object"===(0,w3.default)(w0.sum)&&(w1.sum=new w9.LongBits(w0.sum.low>>>0,w0.sum.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w2.target="",w9.Long){var w3=new w9.Long(0,0,!1);w2.head=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.head=w1.longs===String?"0":0;if(w9.Long){w3=new w9.Long(0,0,!1);w2.sum=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.sum=w1.longs===String?"0":0}return null!=w0.target&&w0.hasOwnProperty("target")&&(w2.target=w0.target),null!=w0.head&&w0.hasOwnProperty("head")&&("number"==typeof w0.head?w2.head=w1.longs===String?String(w0.head):w0.head:w2.head=w1.longs===String?w9.Long.prototype.toString.call(w0.head):w1.longs===Number?new w9.LongBits(w0.head.low>>>0,w0.head.high>>>0).toNumber():w0.head),null!=w0.sum&&w0.hasOwnProperty("sum")&&("number"==typeof w0.sum?w2.sum=w1.longs===String?String(w0.sum):w0.sum:w2.sum=w1.longs===String?w9.Long.prototype.toString.call(w0.sum):w1.longs===Number?new w9.LongBits(w0.sum.low>>>0,w0.sum.high>>>0).toNumber():w0.sum),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PullGroupMemberResult=function(){function w0(w0){if(this.member=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.member&&w3.member.length||(w3.member=[]),w3.member.push(w10.GroupMember.decode(w0,w0.uint32()));break;case 2:w3.full=w0.int32();break;default:w0.skipType(7&w4)}}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.member&&w0.hasOwnProperty("member")){if(!Array.isArray(w0.member))return"member: array expected";for(var w1=0;w1>>3){case 1:w3.uid=w0.string();break;case 2:w3.updateDt=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("uid"))throw w9.ProtocolError("missing required 'uid'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.uid)?null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&!(w9.isInteger(w0.updateDt)||w0.updateDt&&w9.isInteger(w0.updateDt.low)&&w9.isInteger(w0.updateDt.high))?"updateDt: integer|Long expected":null:"uid: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.UserRequest)return w0;var w1=new w10.UserRequest;return null!=w0.uid&&(w1.uid=String(w0.uid)),null!=w0.updateDt&&(w9.Long?(w1.updateDt=w9.Long.fromValue(w0.updateDt)).unsigned=!1:"string"==typeof w0.updateDt?w1.updateDt=parseInt(w0.updateDt,10):"number"==typeof w0.updateDt?w1.updateDt=w0.updateDt:"object"===(0,w3.default)(w0.updateDt)&&(w1.updateDt=new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults)if(w2.uid="",w9.Long){var w3=new w9.Long(0,0,!1);w2.updateDt=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.updateDt=w1.longs===String?"0":0;return null!=w0.uid&&w0.hasOwnProperty("uid")&&(w2.uid=w0.uid),null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&("number"==typeof w0.updateDt?w2.updateDt=w1.longs===String?String(w0.updateDt):w0.updateDt:w2.updateDt=w1.longs===String?w9.Long.prototype.toString.call(w0.updateDt):w1.longs===Number?new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber():w0.updateDt),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PullUserRequest=function(){function w0(w0){if(this.request=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3==1)w3.request&&w3.request.length||(w3.request=[]),w3.request.push(w10.UserRequest.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.request&&w0.hasOwnProperty("request")){if(!Array.isArray(w0.request))return"request: array expected";for(var w1=0;w1>>3){case 1:w3.user=w10.User.decode(w0,w0.uint32());break;case 2:w3.code=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("user"))throw w9.ProtocolError("missing required 'user'",{instance:w3});if(!w3.hasOwnProperty("code"))throw w9.ProtocolError("missing required 'code'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";var w1=w10.User.verify(w0.user);return w1?"user."+w1:w9.isInteger(w0.code)?null:"code: integer expected"},w0.fromObject=function(w0){if(w0 instanceof w10.UserResult)return w0;var w1=new w10.UserResult;if(null!=w0.user){if("object"!==(0,w3.default)(w0.user))throw TypeError(".UserResult.user: object expected");w1.user=w10.User.fromObject(w0.user)}return null!=w0.code&&(w1.code=0|w0.code),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.user=null,w2.code=0),null!=w0.user&&w0.hasOwnProperty("user")&&(w2.user=w10.User.toObject(w0.user,w1)),null!=w0.code&&w0.hasOwnProperty("code")&&(w2.code=w0.code),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PullUserResult=function(){function w0(w0){if(this.result=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3==1)w3.result&&w3.result.length||(w3.result=[]),w3.result.push(w10.UserResult.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.result&&w0.hasOwnProperty("result")){if(!Array.isArray(w0.result))return"result: array expected";for(var w1=0;w1>>3){case 1:w3.groupId=w0.string();break;case 2:if(w3.toLine&&w3.toLine.length||(w3.toLine=[]),2==(7&w4))for(var w5=w0.uint32()+w0.pos;w0.pos>>3){case 1:w3.groupId=w0.string();break;case 2:w3.removedMember&&w3.removedMember.length||(w3.removedMember=[]),w3.removedMember.push(w0.string());break;case 3:if(w3.toLine&&w3.toLine.length||(w3.toLine=[]),2==(7&w4))for(var w5=w0.uint32()+w0.pos;w0.pos>>3){case 1:w3.groupId=w0.string();break;case 2:w3.newOwner=w0.string();break;case 3:if(w3.toLine&&w3.toLine.length||(w3.toLine=[]),2==(7&w4))for(var w5=w0.uint32()+w0.pos;w0.pos>>3){case 1:w3.groupId=w0.string();break;case 2:w3.alias=w0.string();break;case 3:if(w3.toLine&&w3.toLine.length||(w3.toLine=[]),2==(7&w4))for(var w5=w0.uint32()+w0.pos;w0.pos>>3){case 1:w3.groupId=w0.string();break;case 2:if(w3.toLine&&w3.toLine.length||(w3.toLine=[]),2==(7&w4))for(var w5=w0.uint32()+w0.pos;w0.pos>>3){case 1:w3.scope=w0.int32();break;case 2:w3.key=w0.string();break;case 3:w3.value=w0.string();break;case 4:w3.updateDt=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("scope"))throw w9.ProtocolError("missing required 'scope'",{instance:w3});if(!w3.hasOwnProperty("key"))throw w9.ProtocolError("missing required 'key'",{instance:w3});if(!w3.hasOwnProperty("value"))throw w9.ProtocolError("missing required 'value'",{instance:w3});if(!w3.hasOwnProperty("updateDt"))throw w9.ProtocolError("missing required 'updateDt'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.scope)?w9.isString(w0.key)?w9.isString(w0.value)?w9.isInteger(w0.updateDt)||w0.updateDt&&w9.isInteger(w0.updateDt.low)&&w9.isInteger(w0.updateDt.high)?null:"updateDt: integer|Long expected":"value: string expected":"key: string expected":"scope: integer expected"},w0.fromObject=function(w0){if(w0 instanceof w10.UserSettingEntry)return w0;var w1=new w10.UserSettingEntry;return null!=w0.scope&&(w1.scope=0|w0.scope),null!=w0.key&&(w1.key=String(w0.key)),null!=w0.value&&(w1.value=String(w0.value)),null!=w0.updateDt&&(w9.Long?(w1.updateDt=w9.Long.fromValue(w0.updateDt)).unsigned=!1:"string"==typeof w0.updateDt?w1.updateDt=parseInt(w0.updateDt,10):"number"==typeof w0.updateDt?w1.updateDt=w0.updateDt:"object"===(0,w3.default)(w0.updateDt)&&(w1.updateDt=new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults)if(w2.scope=0,w2.key="",w2.value="",w9.Long){var w3=new w9.Long(0,0,!1);w2.updateDt=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.updateDt=w1.longs===String?"0":0;return null!=w0.scope&&w0.hasOwnProperty("scope")&&(w2.scope=w0.scope),null!=w0.key&&w0.hasOwnProperty("key")&&(w2.key=w0.key),null!=w0.value&&w0.hasOwnProperty("value")&&(w2.value=w0.value),null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&("number"==typeof w0.updateDt?w2.updateDt=w1.longs===String?String(w0.updateDt):w0.updateDt:w2.updateDt=w1.longs===String?w9.Long.prototype.toString.call(w0.updateDt):w1.longs===Number?new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber():w0.updateDt),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.ModifyUserSettingReq=function(){function w0(w0){if(this.target=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.scope=w0.int32();break;case 2:w3.key=w0.string();break;case 3:w3.value=w0.string();break;case 4:w3.target&&w3.target.length||(w3.target=[]),w3.target.push(w0.string());break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("scope"))throw w9.ProtocolError("missing required 'scope'",{instance:w3});if(!w3.hasOwnProperty("key"))throw w9.ProtocolError("missing required 'key'",{instance:w3});if(!w3.hasOwnProperty("value"))throw w9.ProtocolError("missing required 'value'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!w9.isInteger(w0.scope))return"scope: integer expected";if(!w9.isString(w0.key))return"key: string expected";if(!w9.isString(w0.value))return"value: string expected";if(null!=w0.target&&w0.hasOwnProperty("target")){if(!Array.isArray(w0.target))return"target: array expected";for(var w1=0;w1>>3==1)w3.version=w0.int64();else w0.skipType(7&w4)}if(!w3.hasOwnProperty("version"))throw w9.ProtocolError("missing required 'version'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.version)||w0.version&&w9.isInteger(w0.version.low)&&w9.isInteger(w0.version.high)?null:"version: integer|Long expected"},w0.fromObject=function(w0){if(w0 instanceof w10.Version)return w0;var w1=new w10.Version;return null!=w0.version&&(w9.Long?(w1.version=w9.Long.fromValue(w0.version)).unsigned=!1:"string"==typeof w0.version?w1.version=parseInt(w0.version,10):"number"==typeof w0.version?w1.version=w0.version:"object"===(0,w3.default)(w0.version)&&(w1.version=new w9.LongBits(w0.version.low>>>0,w0.version.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults)if(w9.Long){var w3=new w9.Long(0,0,!1);w2.version=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.version=w1.longs===String?"0":0;return null!=w0.version&&w0.hasOwnProperty("version")&&("number"==typeof w0.version?w2.version=w1.longs===String?String(w0.version):w0.version:w2.version=w1.longs===String?w9.Long.prototype.toString.call(w0.version):w1.longs===Number?new w9.LongBits(w0.version.low>>>0,w0.version.high>>>0).toNumber():w0.version),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.GetUserSettingResult=function(){function w0(w0){if(this.entry=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3==1)w3.entry&&w3.entry.length||(w3.entry=[]),w3.entry.push(w10.UserSettingEntry.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.entry&&w0.hasOwnProperty("entry")){if(!Array.isArray(w0.entry))return"entry: array expected";for(var w1=0;w1>>3){case 1:w3.uid=w0.string();break;case 2:w3.state=w0.int32();break;case 3:w3.updateDt=w0.int64();break;case 4:w3.alias=w0.string();break;case 5:w3.blacked=w0.int32();break;case 6:w3.extra=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("uid"))throw w9.ProtocolError("missing required 'uid'",{instance:w3});if(!w3.hasOwnProperty("state"))throw w9.ProtocolError("missing required 'state'",{instance:w3});if(!w3.hasOwnProperty("updateDt"))throw w9.ProtocolError("missing required 'updateDt'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.uid)?w9.isInteger(w0.state)?w9.isInteger(w0.updateDt)||w0.updateDt&&w9.isInteger(w0.updateDt.low)&&w9.isInteger(w0.updateDt.high)?null!=w0.alias&&w0.hasOwnProperty("alias")&&!w9.isString(w0.alias)?"alias: string expected":null!=w0.blacked&&w0.hasOwnProperty("blacked")&&!w9.isInteger(w0.blacked)?"blacked: integer expected":null!=w0.extra&&w0.hasOwnProperty("extra")&&!w9.isString(w0.extra)?"extra: string expected":null:"updateDt: integer|Long expected":"state: integer expected":"uid: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.Friend)return w0;var w1=new w10.Friend;return null!=w0.uid&&(w1.uid=String(w0.uid)),null!=w0.state&&(w1.state=0|w0.state),null!=w0.updateDt&&(w9.Long?(w1.updateDt=w9.Long.fromValue(w0.updateDt)).unsigned=!1:"string"==typeof w0.updateDt?w1.updateDt=parseInt(w0.updateDt,10):"number"==typeof w0.updateDt?w1.updateDt=w0.updateDt:"object"===(0,w3.default)(w0.updateDt)&&(w1.updateDt=new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber())),null!=w0.alias&&(w1.alias=String(w0.alias)),null!=w0.blacked&&(w1.blacked=0|w0.blacked),null!=w0.extra&&(w1.extra=String(w0.extra)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w2.uid="",w2.state=0,w9.Long){var w3=new w9.Long(0,0,!1);w2.updateDt=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.updateDt=w1.longs===String?"0":0;w2.alias="",w2.blacked=0,w2.extra=""}return null!=w0.uid&&w0.hasOwnProperty("uid")&&(w2.uid=w0.uid),null!=w0.state&&w0.hasOwnProperty("state")&&(w2.state=w0.state),null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&("number"==typeof w0.updateDt?w2.updateDt=w1.longs===String?String(w0.updateDt):w0.updateDt:w2.updateDt=w1.longs===String?w9.Long.prototype.toString.call(w0.updateDt):w1.longs===Number?new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber():w0.updateDt),null!=w0.alias&&w0.hasOwnProperty("alias")&&(w2.alias=w0.alias),null!=w0.blacked&&w0.hasOwnProperty("blacked")&&(w2.blacked=w0.blacked),null!=w0.extra&&w0.hasOwnProperty("extra")&&(w2.extra=w0.extra),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.GetFriendsResult=function(){function w0(w0){if(this.entry=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3==1)w3.entry&&w3.entry.length||(w3.entry=[]),w3.entry.push(w10.Friend.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.entry&&w0.hasOwnProperty("entry")){if(!Array.isArray(w0.entry))return"entry: array expected";for(var w1=0;w1>>3==1)w3.entry&&w3.entry.length||(w3.entry=[]),w3.entry.push(w10.FriendRequest.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.entry&&w0.hasOwnProperty("entry")){if(!Array.isArray(w0.entry))return"entry: array expected";for(var w1=0;w1>>3){case 1:w3.msgHead=w0.int64();break;case 2:w3.friendHead=w0.int64();break;case 3:w3.friendRqHead=w0.int64();break;case 4:w3.settingHead=w0.int64();break;case 5:w3.nodeAddr=w0.string();break;case 6:w3.nodePort=w0.int32();break;case 7:w3.serverTime=w0.int64();break;case 8:w3.nodeId=w0.string();break;case 9:w3.recvHead=w0.int64();break;case 10:w3.readHead=w0.int64();break;case 11:w3.groupConvHead=w0.int64();break;default:w0.skipType(7&w4)}}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":null!=w0.msgHead&&w0.hasOwnProperty("msgHead")&&!(w9.isInteger(w0.msgHead)||w0.msgHead&&w9.isInteger(w0.msgHead.low)&&w9.isInteger(w0.msgHead.high))?"msgHead: integer|Long expected":null!=w0.friendHead&&w0.hasOwnProperty("friendHead")&&!(w9.isInteger(w0.friendHead)||w0.friendHead&&w9.isInteger(w0.friendHead.low)&&w9.isInteger(w0.friendHead.high))?"friendHead: integer|Long expected":null!=w0.friendRqHead&&w0.hasOwnProperty("friendRqHead")&&!(w9.isInteger(w0.friendRqHead)||w0.friendRqHead&&w9.isInteger(w0.friendRqHead.low)&&w9.isInteger(w0.friendRqHead.high))?"friendRqHead: integer|Long expected":null!=w0.settingHead&&w0.hasOwnProperty("settingHead")&&!(w9.isInteger(w0.settingHead)||w0.settingHead&&w9.isInteger(w0.settingHead.low)&&w9.isInteger(w0.settingHead.high))?"settingHead: integer|Long expected":null!=w0.nodeAddr&&w0.hasOwnProperty("nodeAddr")&&!w9.isString(w0.nodeAddr)?"nodeAddr: string expected":null!=w0.nodePort&&w0.hasOwnProperty("nodePort")&&!w9.isInteger(w0.nodePort)?"nodePort: integer expected":null!=w0.serverTime&&w0.hasOwnProperty("serverTime")&&!(w9.isInteger(w0.serverTime)||w0.serverTime&&w9.isInteger(w0.serverTime.low)&&w9.isInteger(w0.serverTime.high))?"serverTime: integer|Long expected":null!=w0.nodeId&&w0.hasOwnProperty("nodeId")&&!w9.isString(w0.nodeId)?"nodeId: string expected":null!=w0.recvHead&&w0.hasOwnProperty("recvHead")&&!(w9.isInteger(w0.recvHead)||w0.recvHead&&w9.isInteger(w0.recvHead.low)&&w9.isInteger(w0.recvHead.high))?"recvHead: integer|Long expected":null!=w0.readHead&&w0.hasOwnProperty("readHead")&&!(w9.isInteger(w0.readHead)||w0.readHead&&w9.isInteger(w0.readHead.low)&&w9.isInteger(w0.readHead.high))?"readHead: integer|Long expected":null!=w0.groupConvHead&&w0.hasOwnProperty("groupConvHead")&&!(w9.isInteger(w0.groupConvHead)||w0.groupConvHead&&w9.isInteger(w0.groupConvHead.low)&&w9.isInteger(w0.groupConvHead.high))?"groupConvHead: integer|Long expected":null},w0.fromObject=function(w0){if(w0 instanceof w10.ConnectAckPayload)return w0;var w1=new w10.ConnectAckPayload;return null!=w0.msgHead&&(w9.Long?(w1.msgHead=w9.Long.fromValue(w0.msgHead)).unsigned=!1:"string"==typeof w0.msgHead?w1.msgHead=parseInt(w0.msgHead,10):"number"==typeof w0.msgHead?w1.msgHead=w0.msgHead:"object"===(0,w3.default)(w0.msgHead)&&(w1.msgHead=new w9.LongBits(w0.msgHead.low>>>0,w0.msgHead.high>>>0).toNumber())),null!=w0.friendHead&&(w9.Long?(w1.friendHead=w9.Long.fromValue(w0.friendHead)).unsigned=!1:"string"==typeof w0.friendHead?w1.friendHead=parseInt(w0.friendHead,10):"number"==typeof w0.friendHead?w1.friendHead=w0.friendHead:"object"===(0,w3.default)(w0.friendHead)&&(w1.friendHead=new w9.LongBits(w0.friendHead.low>>>0,w0.friendHead.high>>>0).toNumber())),null!=w0.friendRqHead&&(w9.Long?(w1.friendRqHead=w9.Long.fromValue(w0.friendRqHead)).unsigned=!1:"string"==typeof w0.friendRqHead?w1.friendRqHead=parseInt(w0.friendRqHead,10):"number"==typeof w0.friendRqHead?w1.friendRqHead=w0.friendRqHead:"object"===(0,w3.default)(w0.friendRqHead)&&(w1.friendRqHead=new w9.LongBits(w0.friendRqHead.low>>>0,w0.friendRqHead.high>>>0).toNumber())),null!=w0.settingHead&&(w9.Long?(w1.settingHead=w9.Long.fromValue(w0.settingHead)).unsigned=!1:"string"==typeof w0.settingHead?w1.settingHead=parseInt(w0.settingHead,10):"number"==typeof w0.settingHead?w1.settingHead=w0.settingHead:"object"===(0,w3.default)(w0.settingHead)&&(w1.settingHead=new w9.LongBits(w0.settingHead.low>>>0,w0.settingHead.high>>>0).toNumber())),null!=w0.nodeAddr&&(w1.nodeAddr=String(w0.nodeAddr)),null!=w0.nodePort&&(w1.nodePort=0|w0.nodePort),null!=w0.serverTime&&(w9.Long?(w1.serverTime=w9.Long.fromValue(w0.serverTime)).unsigned=!1:"string"==typeof w0.serverTime?w1.serverTime=parseInt(w0.serverTime,10):"number"==typeof w0.serverTime?w1.serverTime=w0.serverTime:"object"===(0,w3.default)(w0.serverTime)&&(w1.serverTime=new w9.LongBits(w0.serverTime.low>>>0,w0.serverTime.high>>>0).toNumber())),null!=w0.nodeId&&(w1.nodeId=String(w0.nodeId)),null!=w0.recvHead&&(w9.Long?(w1.recvHead=w9.Long.fromValue(w0.recvHead)).unsigned=!1:"string"==typeof w0.recvHead?w1.recvHead=parseInt(w0.recvHead,10):"number"==typeof w0.recvHead?w1.recvHead=w0.recvHead:"object"===(0,w3.default)(w0.recvHead)&&(w1.recvHead=new w9.LongBits(w0.recvHead.low>>>0,w0.recvHead.high>>>0).toNumber())),null!=w0.readHead&&(w9.Long?(w1.readHead=w9.Long.fromValue(w0.readHead)).unsigned=!1:"string"==typeof w0.readHead?w1.readHead=parseInt(w0.readHead,10):"number"==typeof w0.readHead?w1.readHead=w0.readHead:"object"===(0,w3.default)(w0.readHead)&&(w1.readHead=new w9.LongBits(w0.readHead.low>>>0,w0.readHead.high>>>0).toNumber())),null!=w0.groupConvHead&&(w9.Long?(w1.groupConvHead=w9.Long.fromValue(w0.groupConvHead)).unsigned=!1:"string"==typeof w0.groupConvHead?w1.groupConvHead=parseInt(w0.groupConvHead,10):"number"==typeof w0.groupConvHead?w1.groupConvHead=w0.groupConvHead:"object"===(0,w3.default)(w0.groupConvHead)&&(w1.groupConvHead=new w9.LongBits(w0.groupConvHead.low>>>0,w0.groupConvHead.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w9.Long){var w3=new w9.Long(0,0,!1);w2.msgHead=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.msgHead=w1.longs===String?"0":0;if(w9.Long){w3=new w9.Long(0,0,!1);w2.friendHead=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.friendHead=w1.longs===String?"0":0;if(w9.Long){w3=new w9.Long(0,0,!1);w2.friendRqHead=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.friendRqHead=w1.longs===String?"0":0;if(w9.Long){w3=new w9.Long(0,0,!1);w2.settingHead=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.settingHead=w1.longs===String?"0":0;if(w2.nodeAddr="",w2.nodePort=0,w9.Long){w3=new w9.Long(0,0,!1);w2.serverTime=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.serverTime=w1.longs===String?"0":0;if(w2.nodeId="",w9.Long){w3=new w9.Long(0,0,!1);w2.recvHead=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.recvHead=w1.longs===String?"0":0;if(w9.Long){w3=new w9.Long(0,0,!1);w2.readHead=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.readHead=w1.longs===String?"0":0;if(w9.Long){w3=new w9.Long(0,0,!1);w2.groupConvHead=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.groupConvHead=w1.longs===String?"0":0}return null!=w0.msgHead&&w0.hasOwnProperty("msgHead")&&("number"==typeof w0.msgHead?w2.msgHead=w1.longs===String?String(w0.msgHead):w0.msgHead:w2.msgHead=w1.longs===String?w9.Long.prototype.toString.call(w0.msgHead):w1.longs===Number?new w9.LongBits(w0.msgHead.low>>>0,w0.msgHead.high>>>0).toNumber():w0.msgHead),null!=w0.friendHead&&w0.hasOwnProperty("friendHead")&&("number"==typeof w0.friendHead?w2.friendHead=w1.longs===String?String(w0.friendHead):w0.friendHead:w2.friendHead=w1.longs===String?w9.Long.prototype.toString.call(w0.friendHead):w1.longs===Number?new w9.LongBits(w0.friendHead.low>>>0,w0.friendHead.high>>>0).toNumber():w0.friendHead),null!=w0.friendRqHead&&w0.hasOwnProperty("friendRqHead")&&("number"==typeof w0.friendRqHead?w2.friendRqHead=w1.longs===String?String(w0.friendRqHead):w0.friendRqHead:w2.friendRqHead=w1.longs===String?w9.Long.prototype.toString.call(w0.friendRqHead):w1.longs===Number?new w9.LongBits(w0.friendRqHead.low>>>0,w0.friendRqHead.high>>>0).toNumber():w0.friendRqHead),null!=w0.settingHead&&w0.hasOwnProperty("settingHead")&&("number"==typeof w0.settingHead?w2.settingHead=w1.longs===String?String(w0.settingHead):w0.settingHead:w2.settingHead=w1.longs===String?w9.Long.prototype.toString.call(w0.settingHead):w1.longs===Number?new w9.LongBits(w0.settingHead.low>>>0,w0.settingHead.high>>>0).toNumber():w0.settingHead),null!=w0.nodeAddr&&w0.hasOwnProperty("nodeAddr")&&(w2.nodeAddr=w0.nodeAddr),null!=w0.nodePort&&w0.hasOwnProperty("nodePort")&&(w2.nodePort=w0.nodePort),null!=w0.serverTime&&w0.hasOwnProperty("serverTime")&&("number"==typeof w0.serverTime?w2.serverTime=w1.longs===String?String(w0.serverTime):w0.serverTime:w2.serverTime=w1.longs===String?w9.Long.prototype.toString.call(w0.serverTime):w1.longs===Number?new w9.LongBits(w0.serverTime.low>>>0,w0.serverTime.high>>>0).toNumber():w0.serverTime),null!=w0.nodeId&&w0.hasOwnProperty("nodeId")&&(w2.nodeId=w0.nodeId),null!=w0.recvHead&&w0.hasOwnProperty("recvHead")&&("number"==typeof w0.recvHead?w2.recvHead=w1.longs===String?String(w0.recvHead):w0.recvHead:w2.recvHead=w1.longs===String?w9.Long.prototype.toString.call(w0.recvHead):w1.longs===Number?new w9.LongBits(w0.recvHead.low>>>0,w0.recvHead.high>>>0).toNumber():w0.recvHead),null!=w0.readHead&&w0.hasOwnProperty("readHead")&&("number"==typeof w0.readHead?w2.readHead=w1.longs===String?String(w0.readHead):w0.readHead:w2.readHead=w1.longs===String?w9.Long.prototype.toString.call(w0.readHead):w1.longs===Number?new w9.LongBits(w0.readHead.low>>>0,w0.readHead.high>>>0).toNumber():w0.readHead),null!=w0.groupConvHead&&w0.hasOwnProperty("groupConvHead")&&("number"==typeof w0.groupConvHead?w2.groupConvHead=w1.longs===String?String(w0.groupConvHead):w0.groupConvHead:w2.groupConvHead=w1.longs===String?w9.Long.prototype.toString.call(w0.groupConvHead):w1.longs===Number?new w9.LongBits(w0.groupConvHead.low>>>0,w0.groupConvHead.high>>>0).toNumber():w0.groupConvHead),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.IMHttpWrapper=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.token=w0.string();break;case 2:w3.clientId=w0.string();break;case 3:w3.request=w0.string();break;case 4:w3.data=w0.bytes();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("token"))throw w9.ProtocolError("missing required 'token'",{instance:w3});if(!w3.hasOwnProperty("clientId"))throw w9.ProtocolError("missing required 'clientId'",{instance:w3});if(!w3.hasOwnProperty("request"))throw w9.ProtocolError("missing required 'request'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.token)?w9.isString(w0.clientId)?w9.isString(w0.request)?null!=w0.data&&w0.hasOwnProperty("data")&&!(w0.data&&"number"==typeof w0.data.length||w9.isString(w0.data))?"data: buffer expected":null:"request: string expected":"clientId: string expected":"token: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.IMHttpWrapper)return w0;var w1=new w10.IMHttpWrapper;return null!=w0.token&&(w1.token=String(w0.token)),null!=w0.clientId&&(w1.clientId=String(w0.clientId)),null!=w0.request&&(w1.request=String(w0.request)),null!=w0.data&&("string"==typeof w0.data?w9.base64.decode(w0.data,w1.data=w9.newBuffer(w9.base64.length(w0.data)),0):w0.data.length&&(w1.data=w0.data)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.token="",w2.clientId="",w2.request="",w1.bytes===String?w2.data="":(w2.data=[],w1.bytes!==Array&&(w2.data=w9.newBuffer(w2.data)))),null!=w0.token&&w0.hasOwnProperty("token")&&(w2.token=w0.token),null!=w0.clientId&&w0.hasOwnProperty("clientId")&&(w2.clientId=w0.clientId),null!=w0.request&&w0.hasOwnProperty("request")&&(w2.request=w0.request),null!=w0.data&&w0.hasOwnProperty("data")&&(w2.data=w1.bytes===String?w9.base64.encode(w0.data,0,w0.data.length):w1.bytes===Array?Array.prototype.slice.call(w0.data):w0.data),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.SearchUserRequest=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.keyword=w0.string();break;case 2:w3.fuzzy=w0.int32();break;case 3:w3.page=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("keyword"))throw w9.ProtocolError("missing required 'keyword'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.keyword)?null!=w0.fuzzy&&w0.hasOwnProperty("fuzzy")&&!w9.isInteger(w0.fuzzy)?"fuzzy: integer expected":null!=w0.page&&w0.hasOwnProperty("page")&&!w9.isInteger(w0.page)?"page: integer expected":null:"keyword: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.SearchUserRequest)return w0;var w1=new w10.SearchUserRequest;return null!=w0.keyword&&(w1.keyword=String(w0.keyword)),null!=w0.fuzzy&&(w1.fuzzy=0|w0.fuzzy),null!=w0.page&&(w1.page=0|w0.page),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.keyword="",w2.fuzzy=0,w2.page=0),null!=w0.keyword&&w0.hasOwnProperty("keyword")&&(w2.keyword=w0.keyword),null!=w0.fuzzy&&w0.hasOwnProperty("fuzzy")&&(w2.fuzzy=w0.fuzzy),null!=w0.page&&w0.hasOwnProperty("page")&&(w2.page=w0.page),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.SearchUserResult=function(){function w0(w0){if(this.entry=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3==1)w3.entry&&w3.entry.length||(w3.entry=[]),w3.entry.push(w10.User.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.entry&&w0.hasOwnProperty("entry")){if(!Array.isArray(w0.entry))return"entry: array expected";for(var w1=0;w1>>3){case 1:w3.chatroomId=w0.string();break;case 2:w3.updateDt=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("chatroomId"))throw w9.ProtocolError("missing required 'chatroomId'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.chatroomId)?null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&!(w9.isInteger(w0.updateDt)||w0.updateDt&&w9.isInteger(w0.updateDt.low)&&w9.isInteger(w0.updateDt.high))?"updateDt: integer|Long expected":null:"chatroomId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.GetChatroomInfoRequest)return w0;var w1=new w10.GetChatroomInfoRequest;return null!=w0.chatroomId&&(w1.chatroomId=String(w0.chatroomId)),null!=w0.updateDt&&(w9.Long?(w1.updateDt=w9.Long.fromValue(w0.updateDt)).unsigned=!1:"string"==typeof w0.updateDt?w1.updateDt=parseInt(w0.updateDt,10):"number"==typeof w0.updateDt?w1.updateDt=w0.updateDt:"object"===(0,w3.default)(w0.updateDt)&&(w1.updateDt=new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults)if(w2.chatroomId="",w9.Long){var w3=new w9.Long(0,0,!1);w2.updateDt=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.updateDt=w1.longs===String?"0":0;return null!=w0.chatroomId&&w0.hasOwnProperty("chatroomId")&&(w2.chatroomId=w0.chatroomId),null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&("number"==typeof w0.updateDt?w2.updateDt=w1.longs===String?String(w0.updateDt):w0.updateDt:w2.updateDt=w1.longs===String?w9.Long.prototype.toString.call(w0.updateDt):w1.longs===Number?new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber():w0.updateDt),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.ChatroomInfo=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.title=w0.string();break;case 2:w3.desc=w0.string();break;case 3:w3.portrait=w0.string();break;case 4:w3.memberCount=w0.int32();break;case 5:w3.createDt=w0.int64();break;case 6:w3.updateDt=w0.int64();break;case 7:w3.extra=w0.string();break;case 8:w3.state=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("title"))throw w9.ProtocolError("missing required 'title'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.title)?null!=w0.desc&&w0.hasOwnProperty("desc")&&!w9.isString(w0.desc)?"desc: string expected":null!=w0.portrait&&w0.hasOwnProperty("portrait")&&!w9.isString(w0.portrait)?"portrait: string expected":null!=w0.memberCount&&w0.hasOwnProperty("memberCount")&&!w9.isInteger(w0.memberCount)?"memberCount: integer expected":null!=w0.createDt&&w0.hasOwnProperty("createDt")&&!(w9.isInteger(w0.createDt)||w0.createDt&&w9.isInteger(w0.createDt.low)&&w9.isInteger(w0.createDt.high))?"createDt: integer|Long expected":null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&!(w9.isInteger(w0.updateDt)||w0.updateDt&&w9.isInteger(w0.updateDt.low)&&w9.isInteger(w0.updateDt.high))?"updateDt: integer|Long expected":null!=w0.extra&&w0.hasOwnProperty("extra")&&!w9.isString(w0.extra)?"extra: string expected":null!=w0.state&&w0.hasOwnProperty("state")&&!w9.isInteger(w0.state)?"state: integer expected":null:"title: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.ChatroomInfo)return w0;var w1=new w10.ChatroomInfo;return null!=w0.title&&(w1.title=String(w0.title)),null!=w0.desc&&(w1.desc=String(w0.desc)),null!=w0.portrait&&(w1.portrait=String(w0.portrait)),null!=w0.memberCount&&(w1.memberCount=0|w0.memberCount),null!=w0.createDt&&(w9.Long?(w1.createDt=w9.Long.fromValue(w0.createDt)).unsigned=!1:"string"==typeof w0.createDt?w1.createDt=parseInt(w0.createDt,10):"number"==typeof w0.createDt?w1.createDt=w0.createDt:"object"===(0,w3.default)(w0.createDt)&&(w1.createDt=new w9.LongBits(w0.createDt.low>>>0,w0.createDt.high>>>0).toNumber())),null!=w0.updateDt&&(w9.Long?(w1.updateDt=w9.Long.fromValue(w0.updateDt)).unsigned=!1:"string"==typeof w0.updateDt?w1.updateDt=parseInt(w0.updateDt,10):"number"==typeof w0.updateDt?w1.updateDt=w0.updateDt:"object"===(0,w3.default)(w0.updateDt)&&(w1.updateDt=new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber())),null!=w0.extra&&(w1.extra=String(w0.extra)),null!=w0.state&&(w1.state=0|w0.state),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w2.title="",w2.desc="",w2.portrait="",w2.memberCount=0,w9.Long){var w3=new w9.Long(0,0,!1);w2.createDt=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.createDt=w1.longs===String?"0":0;if(w9.Long){w3=new w9.Long(0,0,!1);w2.updateDt=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.updateDt=w1.longs===String?"0":0;w2.extra="",w2.state=0}return null!=w0.title&&w0.hasOwnProperty("title")&&(w2.title=w0.title),null!=w0.desc&&w0.hasOwnProperty("desc")&&(w2.desc=w0.desc),null!=w0.portrait&&w0.hasOwnProperty("portrait")&&(w2.portrait=w0.portrait),null!=w0.memberCount&&w0.hasOwnProperty("memberCount")&&(w2.memberCount=w0.memberCount),null!=w0.createDt&&w0.hasOwnProperty("createDt")&&("number"==typeof w0.createDt?w2.createDt=w1.longs===String?String(w0.createDt):w0.createDt:w2.createDt=w1.longs===String?w9.Long.prototype.toString.call(w0.createDt):w1.longs===Number?new w9.LongBits(w0.createDt.low>>>0,w0.createDt.high>>>0).toNumber():w0.createDt),null!=w0.updateDt&&w0.hasOwnProperty("updateDt")&&("number"==typeof w0.updateDt?w2.updateDt=w1.longs===String?String(w0.updateDt):w0.updateDt:w2.updateDt=w1.longs===String?w9.Long.prototype.toString.call(w0.updateDt):w1.longs===Number?new w9.LongBits(w0.updateDt.low>>>0,w0.updateDt.high>>>0).toNumber():w0.updateDt),null!=w0.extra&&w0.hasOwnProperty("extra")&&(w2.extra=w0.extra),null!=w0.state&&w0.hasOwnProperty("state")&&(w2.state=w0.state),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.GetChatroomMemberInfoRequest=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.chatroomId=w0.string();break;case 2:w3.maxCount=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("chatroomId"))throw w9.ProtocolError("missing required 'chatroomId'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.chatroomId)?null!=w0.maxCount&&w0.hasOwnProperty("maxCount")&&!w9.isInteger(w0.maxCount)?"maxCount: integer expected":null:"chatroomId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.GetChatroomMemberInfoRequest)return w0;var w1=new w10.GetChatroomMemberInfoRequest;return null!=w0.chatroomId&&(w1.chatroomId=String(w0.chatroomId)),null!=w0.maxCount&&(w1.maxCount=0|w0.maxCount),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.chatroomId="",w2.maxCount=0),null!=w0.chatroomId&&w0.hasOwnProperty("chatroomId")&&(w2.chatroomId=w0.chatroomId),null!=w0.maxCount&&w0.hasOwnProperty("maxCount")&&(w2.maxCount=w0.maxCount),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.ChatroomMemberInfo=function(){function w0(w0){if(this.members=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.memberCount=w0.int32();break;case 2:w3.members&&w3.members.length||(w3.members=[]),w3.members.push(w0.string());break;default:w0.skipType(7&w4)}}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.memberCount&&w0.hasOwnProperty("memberCount")&&!w9.isInteger(w0.memberCount))return"memberCount: integer expected";if(null!=w0.members&&w0.hasOwnProperty("members")){if(!Array.isArray(w0.members))return"members: array expected";for(var w1=0;w1>>3==1)w3.id=w0.int64();else w0.skipType(7&w4)}if(!w3.hasOwnProperty("id"))throw w9.ProtocolError("missing required 'id'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.id)||w0.id&&w9.isInteger(w0.id.low)&&w9.isInteger(w0.id.high)?null:"id: integer|Long expected"},w0.fromObject=function(w0){if(w0 instanceof w10.INT64Buf)return w0;var w1=new w10.INT64Buf;return null!=w0.id&&(w9.Long?(w1.id=w9.Long.fromValue(w0.id)).unsigned=!1:"string"==typeof w0.id?w1.id=parseInt(w0.id,10):"number"==typeof w0.id?w1.id=w0.id:"object"===(0,w3.default)(w0.id)&&(w1.id=new w9.LongBits(w0.id.low>>>0,w0.id.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults)if(w9.Long){var w3=new w9.Long(0,0,!1);w2.id=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.id=w1.longs===String?"0":0;return null!=w0.id&&w0.hasOwnProperty("id")&&("number"==typeof w0.id?w2.id=w1.longs===String?String(w0.id):w0.id:w2.id=w1.longs===String?w9.Long.prototype.toString.call(w0.id):w1.longs===Number?new w9.LongBits(w0.id.low>>>0,w0.id.high>>>0).toNumber():w0.id),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.INT64ListBuf=function(){function w0(w0){if(this.id=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3==1)if(w3.id&&w3.id.length||(w3.id=[]),2==(7&w4))for(var w5=w0.uint32()+w0.pos;w0.pos>>0,w0.id[w2].high>>>0).toNumber())}return w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if((w1.arrays||w1.defaults)&&(w2.id=[]),w0.id&&w0.id.length){w2.id=[];for(var w3=0;w3>>0,w0.id[w3].high>>>0).toNumber():w0.id[w3]}return w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.NotifyRecallMessage=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.id=w0.int64();break;case 2:w3.fromUser=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("id"))throw w9.ProtocolError("missing required 'id'",{instance:w3});if(!w3.hasOwnProperty("fromUser"))throw w9.ProtocolError("missing required 'fromUser'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.id)||w0.id&&w9.isInteger(w0.id.low)&&w9.isInteger(w0.id.high)?w9.isString(w0.fromUser)?null:"fromUser: string expected":"id: integer|Long expected"},w0.fromObject=function(w0){if(w0 instanceof w10.NotifyRecallMessage)return w0;var w1=new w10.NotifyRecallMessage;return null!=w0.id&&(w9.Long?(w1.id=w9.Long.fromValue(w0.id)).unsigned=!1:"string"==typeof w0.id?w1.id=parseInt(w0.id,10):"number"==typeof w0.id?w1.id=w0.id:"object"===(0,w3.default)(w0.id)&&(w1.id=new w9.LongBits(w0.id.low>>>0,w0.id.high>>>0).toNumber())),null!=w0.fromUser&&(w1.fromUser=String(w0.fromUser)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w9.Long){var w3=new w9.Long(0,0,!1);w2.id=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.id=w1.longs===String?"0":0;w2.fromUser=""}return null!=w0.id&&w0.hasOwnProperty("id")&&("number"==typeof w0.id?w2.id=w1.longs===String?String(w0.id):w0.id:w2.id=w1.longs===String?w9.Long.prototype.toString.call(w0.id):w1.longs===Number?new w9.LongBits(w0.id.low>>>0,w0.id.high>>>0).toNumber():w0.id),null!=w0.fromUser&&w0.hasOwnProperty("fromUser")&&(w2.fromUser=w0.fromUser),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.BlackUserRequest=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.uid=w0.string();break;case 2:w3.status=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("uid"))throw w9.ProtocolError("missing required 'uid'",{instance:w3});if(!w3.hasOwnProperty("status"))throw w9.ProtocolError("missing required 'status'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.uid)?w9.isInteger(w0.status)?null:"status: integer expected":"uid: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.BlackUserRequest)return w0;var w1=new w10.BlackUserRequest;return null!=w0.uid&&(w1.uid=String(w0.uid)),null!=w0.status&&(w1.status=0|w0.status),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.uid="",w2.status=0),null!=w0.uid&&w0.hasOwnProperty("uid")&&(w2.uid=w0.uid),null!=w0.status&&w0.hasOwnProperty("status")&&(w2.status=w0.status),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.RouteRequest=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.app=w0.string();break;case 2:w3.platform=w0.int32();break;case 3:w3.pushType=w0.int32();break;case 4:w3.deviceName=w0.string();break;case 5:w3.deviceVersion=w0.string();break;case 6:w3.phoneName=w0.string();break;case 7:w3.language=w0.string();break;case 8:w3.carrierName=w0.string();break;case 9:w3.appVersion=w0.string();break;case 10:w3.sdkVersion=w0.string();break;case 11:w3.wxAppId=w0.string();break;case 12:w3.wxAppKey=w0.string();break;case 13:w3.webAppId=w0.string();break;case 14:w3.webAppKey=w0.string();break;case 15:w3.host=w0.string();break;case 16:w3.signature=w0.string();break;default:w0.skipType(7&w4)}}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":null!=w0.app&&w0.hasOwnProperty("app")&&!w9.isString(w0.app)?"app: string expected":null!=w0.platform&&w0.hasOwnProperty("platform")&&!w9.isInteger(w0.platform)?"platform: integer expected":null!=w0.pushType&&w0.hasOwnProperty("pushType")&&!w9.isInteger(w0.pushType)?"pushType: integer expected":null!=w0.deviceName&&w0.hasOwnProperty("deviceName")&&!w9.isString(w0.deviceName)?"deviceName: string expected":null!=w0.deviceVersion&&w0.hasOwnProperty("deviceVersion")&&!w9.isString(w0.deviceVersion)?"deviceVersion: string expected":null!=w0.phoneName&&w0.hasOwnProperty("phoneName")&&!w9.isString(w0.phoneName)?"phoneName: string expected":null!=w0.language&&w0.hasOwnProperty("language")&&!w9.isString(w0.language)?"language: string expected":null!=w0.carrierName&&w0.hasOwnProperty("carrierName")&&!w9.isString(w0.carrierName)?"carrierName: string expected":null!=w0.appVersion&&w0.hasOwnProperty("appVersion")&&!w9.isString(w0.appVersion)?"appVersion: string expected":null!=w0.sdkVersion&&w0.hasOwnProperty("sdkVersion")&&!w9.isString(w0.sdkVersion)?"sdkVersion: string expected":null!=w0.wxAppId&&w0.hasOwnProperty("wxAppId")&&!w9.isString(w0.wxAppId)?"wxAppId: string expected":null!=w0.wxAppKey&&w0.hasOwnProperty("wxAppKey")&&!w9.isString(w0.wxAppKey)?"wxAppKey: string expected":null!=w0.webAppId&&w0.hasOwnProperty("webAppId")&&!w9.isString(w0.webAppId)?"webAppId: string expected":null!=w0.webAppKey&&w0.hasOwnProperty("webAppKey")&&!w9.isString(w0.webAppKey)?"webAppKey: string expected":null!=w0.host&&w0.hasOwnProperty("host")&&!w9.isString(w0.host)?"host: string expected":null!=w0.signature&&w0.hasOwnProperty("signature")&&!w9.isString(w0.signature)?"signature: string expected":null},w0.fromObject=function(w0){if(w0 instanceof w10.RouteRequest)return w0;var w1=new w10.RouteRequest;return null!=w0.app&&(w1.app=String(w0.app)),null!=w0.platform&&(w1.platform=0|w0.platform),null!=w0.pushType&&(w1.pushType=0|w0.pushType),null!=w0.deviceName&&(w1.deviceName=String(w0.deviceName)),null!=w0.deviceVersion&&(w1.deviceVersion=String(w0.deviceVersion)),null!=w0.phoneName&&(w1.phoneName=String(w0.phoneName)),null!=w0.language&&(w1.language=String(w0.language)),null!=w0.carrierName&&(w1.carrierName=String(w0.carrierName)),null!=w0.appVersion&&(w1.appVersion=String(w0.appVersion)),null!=w0.sdkVersion&&(w1.sdkVersion=String(w0.sdkVersion)),null!=w0.wxAppId&&(w1.wxAppId=String(w0.wxAppId)),null!=w0.wxAppKey&&(w1.wxAppKey=String(w0.wxAppKey)),null!=w0.webAppId&&(w1.webAppId=String(w0.webAppId)),null!=w0.webAppKey&&(w1.webAppKey=String(w0.webAppKey)),null!=w0.host&&(w1.host=String(w0.host)),null!=w0.signature&&(w1.signature=String(w0.signature)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.app="",w2.platform=0,w2.pushType=0,w2.deviceName="",w2.deviceVersion="",w2.phoneName="",w2.language="",w2.carrierName="",w2.appVersion="",w2.sdkVersion="",w2.wxAppId="",w2.wxAppKey="",w2.webAppId="",w2.webAppKey="",w2.host="",w2.signature=""),null!=w0.app&&w0.hasOwnProperty("app")&&(w2.app=w0.app),null!=w0.platform&&w0.hasOwnProperty("platform")&&(w2.platform=w0.platform),null!=w0.pushType&&w0.hasOwnProperty("pushType")&&(w2.pushType=w0.pushType),null!=w0.deviceName&&w0.hasOwnProperty("deviceName")&&(w2.deviceName=w0.deviceName),null!=w0.deviceVersion&&w0.hasOwnProperty("deviceVersion")&&(w2.deviceVersion=w0.deviceVersion),null!=w0.phoneName&&w0.hasOwnProperty("phoneName")&&(w2.phoneName=w0.phoneName),null!=w0.language&&w0.hasOwnProperty("language")&&(w2.language=w0.language),null!=w0.carrierName&&w0.hasOwnProperty("carrierName")&&(w2.carrierName=w0.carrierName),null!=w0.appVersion&&w0.hasOwnProperty("appVersion")&&(w2.appVersion=w0.appVersion),null!=w0.sdkVersion&&w0.hasOwnProperty("sdkVersion")&&(w2.sdkVersion=w0.sdkVersion),null!=w0.wxAppId&&w0.hasOwnProperty("wxAppId")&&(w2.wxAppId=w0.wxAppId),null!=w0.wxAppKey&&w0.hasOwnProperty("wxAppKey")&&(w2.wxAppKey=w0.wxAppKey),null!=w0.webAppId&&w0.hasOwnProperty("webAppId")&&(w2.webAppId=w0.webAppId),null!=w0.webAppKey&&w0.hasOwnProperty("webAppKey")&&(w2.webAppKey=w0.webAppKey),null!=w0.host&&w0.hasOwnProperty("host")&&(w2.host=w0.host),null!=w0.signature&&w0.hasOwnProperty("signature")&&(w2.signature=w0.signature),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.AddressTriple=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.host=w0.string();break;case 2:w3.longPort=w0.int32();break;case 3:w3.shortPort=w0.int32();break;case 4:w3.wssPort=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("host"))throw w9.ProtocolError("missing required 'host'",{instance:w3});if(!w3.hasOwnProperty("longPort"))throw w9.ProtocolError("missing required 'longPort'",{instance:w3});if(!w3.hasOwnProperty("shortPort"))throw w9.ProtocolError("missing required 'shortPort'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.host)?w9.isInteger(w0.longPort)?w9.isInteger(w0.shortPort)?null!=w0.wssPort&&w0.hasOwnProperty("wssPort")&&!w9.isInteger(w0.wssPort)?"wssPort: integer expected":null:"shortPort: integer expected":"longPort: integer expected":"host: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.AddressTriple)return w0;var w1=new w10.AddressTriple;return null!=w0.host&&(w1.host=String(w0.host)),null!=w0.longPort&&(w1.longPort=0|w0.longPort),null!=w0.shortPort&&(w1.shortPort=0|w0.shortPort),null!=w0.wssPort&&(w1.wssPort=0|w0.wssPort),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.host="",w2.longPort=0,w2.shortPort=0,w2.wssPort=0),null!=w0.host&&w0.hasOwnProperty("host")&&(w2.host=w0.host),null!=w0.longPort&&w0.hasOwnProperty("longPort")&&(w2.longPort=w0.longPort),null!=w0.shortPort&&w0.hasOwnProperty("shortPort")&&(w2.shortPort=w0.shortPort),null!=w0.wssPort&&w0.hasOwnProperty("wssPort")&&(w2.wssPort=w0.wssPort),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.RouteResponse=function(){function w0(w0){if(this.candidate=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.host=w0.string();break;case 2:w3.longPort=w0.int32();break;case 3:w3.shortPort=w0.int32();break;case 4:w3.thumbPara=w0.string();break;case 5:w3.node=w0.string();break;case 6:w3.commercial=w0.int32();break;case 7:w3.wssPort=w0.int32();break;case 8:w3.candidate&&w3.candidate.length||(w3.candidate=[]),w3.candidate.push(w10.AddressTriple.decode(w0,w0.uint32()));break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("host"))throw w9.ProtocolError("missing required 'host'",{instance:w3});if(!w3.hasOwnProperty("longPort"))throw w9.ProtocolError("missing required 'longPort'",{instance:w3});if(!w3.hasOwnProperty("shortPort"))throw w9.ProtocolError("missing required 'shortPort'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!w9.isString(w0.host))return"host: string expected";if(!w9.isInteger(w0.longPort))return"longPort: integer expected";if(!w9.isInteger(w0.shortPort))return"shortPort: integer expected";if(null!=w0.thumbPara&&w0.hasOwnProperty("thumbPara")&&!w9.isString(w0.thumbPara))return"thumbPara: string expected";if(null!=w0.node&&w0.hasOwnProperty("node")&&!w9.isString(w0.node))return"node: string expected";if(null!=w0.commercial&&w0.hasOwnProperty("commercial")&&!w9.isInteger(w0.commercial))return"commercial: integer expected";if(null!=w0.wssPort&&w0.hasOwnProperty("wssPort")&&!w9.isInteger(w0.wssPort))return"wssPort: integer expected";if(null!=w0.candidate&&w0.hasOwnProperty("candidate")){if(!Array.isArray(w0.candidate))return"candidate: array expected";for(var w1=0;w1>>3){case 1:w3.userId=w0.string();break;case 2:w3.clientId=w0.string();break;case 3:w3.platform=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("userId"))throw w9.ProtocolError("missing required 'userId'",{instance:w3});if(!w3.hasOwnProperty("clientId"))throw w9.ProtocolError("missing required 'clientId'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.userId)?w9.isString(w0.clientId)?null!=w0.platform&&w0.hasOwnProperty("platform")&&!w9.isInteger(w0.platform)?"platform: integer expected":null:"clientId: string expected":"userId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.GetTokenRequest)return w0;var w1=new w10.GetTokenRequest;return null!=w0.userId&&(w1.userId=String(w0.userId)),null!=w0.clientId&&(w1.clientId=String(w0.clientId)),null!=w0.platform&&(w1.platform=0|w0.platform),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.userId="",w2.clientId="",w2.platform=0),null!=w0.userId&&w0.hasOwnProperty("userId")&&(w2.userId=w0.userId),null!=w0.clientId&&w0.hasOwnProperty("clientId")&&(w2.clientId=w0.clientId),null!=w0.platform&&w0.hasOwnProperty("platform")&&(w2.platform=w0.platform),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.LoadRemoteMessages=function(){function w0(w0){if(this.contentType=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.conversation=w10.Conversation.decode(w0,w0.uint32());break;case 2:w3.beforeUid=w0.int64();break;case 3:w3.count=w0.int32();break;case 4:if(w3.contentType&&w3.contentType.length||(w3.contentType=[]),2==(7&w4))for(var w5=w0.uint32()+w0.pos;w0.pos>>0,w0.beforeUid.high>>>0).toNumber())),null!=w0.count&&(w1.count=0|w0.count),w0.contentType){if(!Array.isArray(w0.contentType))throw TypeError(".LoadRemoteMessages.contentType: array expected");w1.contentType=[];for(var w2=0;w2>>0,w0.beforeUid.high>>>0).toNumber():w0.beforeUid),null!=w0.count&&w0.hasOwnProperty("count")&&(w2.count=w0.count),w0.contentType&&w0.contentType.length){w2.contentType=[];for(var w4=0;w4>>3){case 1:w3.line=w0.int32();break;case 2:w3.beforeUid=w0.int64();break;case 3:w3.count=w0.int32();break;case 4:if(w3.contentType&&w3.contentType.length||(w3.contentType=[]),2==(7&w4))for(var w5=w0.uint32()+w0.pos;w0.pos>>0,w0.beforeUid.high>>>0).toNumber())),null!=w0.count&&(w1.count=0|w0.count),w0.contentType){if(!Array.isArray(w0.contentType))throw TypeError(".LoadLineMessages.contentType: array expected");w1.contentType=[];for(var w2=0;w2>>0,w0.beforeUid.high>>>0).toNumber():w0.beforeUid),null!=w0.count&&w0.hasOwnProperty("count")&&(w2.count=w0.count),w0.contentType&&w0.contentType.length){w2.contentType=[];for(var w4=0;w4>>3){case 1:w3.fromUser=w0.string();break;case 2:w3.content=w10.MessageContent.decode(w0,w0.uint32());break;case 3:w3.to&&w3.to.length||(w3.to=[]),w3.to.push(w0.string());break;case 4:w3.line=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("fromUser"))throw w9.ProtocolError("missing required 'fromUser'",{instance:w3});if(!w3.hasOwnProperty("content"))throw w9.ProtocolError("missing required 'content'",{instance:w3});if(!w3.hasOwnProperty("line"))throw w9.ProtocolError("missing required 'line'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!w9.isString(w0.fromUser))return"fromUser: string expected";var w1=w10.MessageContent.verify(w0.content);if(w1)return"content."+w1;if(null!=w0.to&&w0.hasOwnProperty("to")){if(!Array.isArray(w0.to))return"to: array expected";for(var w2=0;w2>>3){case 1:w3.messageId=w0.int64();break;case 2:w3.target&&w3.target.length||(w3.target=[]),w3.target.push(w0.string());break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("messageId"))throw w9.ProtocolError("missing required 'messageId'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!(w9.isInteger(w0.messageId)||w0.messageId&&w9.isInteger(w0.messageId.low)&&w9.isInteger(w0.messageId.high)))return"messageId: integer|Long expected";if(null!=w0.target&&w0.hasOwnProperty("target")){if(!Array.isArray(w0.target))return"target: array expected";for(var w1=0;w1>>0,w0.messageId.high>>>0).toNumber())),w0.target){if(!Array.isArray(w0.target))throw TypeError(".RecallMultiMessage.target: array expected");w1.target=[];for(var w2=0;w2>>0,w0.messageId.high>>>0).toNumber():w0.messageId),w0.target&&w0.target.length){w2.target=[];for(var w4=0;w4>>3){case 1:w3.messageId=w0.int64();break;case 2:w3.content=w10.MessageContent.decode(w0,w0.uint32());break;case 3:w3.distribute=w0.int32();break;case 4:w3.updateTime=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("messageId"))throw w9.ProtocolError("missing required 'messageId'",{instance:w3});if(!w3.hasOwnProperty("content"))throw w9.ProtocolError("missing required 'content'",{instance:w3});if(!w3.hasOwnProperty("distribute"))throw w9.ProtocolError("missing required 'distribute'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!(w9.isInteger(w0.messageId)||w0.messageId&&w9.isInteger(w0.messageId.low)&&w9.isInteger(w0.messageId.high)))return"messageId: integer|Long expected";var w1=w10.MessageContent.verify(w0.content);return w1?"content."+w1:w9.isInteger(w0.distribute)?null!=w0.updateTime&&w0.hasOwnProperty("updateTime")&&!w9.isInteger(w0.updateTime)?"updateTime: integer expected":null:"distribute: integer expected"},w0.fromObject=function(w0){if(w0 instanceof w10.UpdateMessageContent)return w0;var w1=new w10.UpdateMessageContent;if(null!=w0.messageId&&(w9.Long?(w1.messageId=w9.Long.fromValue(w0.messageId)).unsigned=!1:"string"==typeof w0.messageId?w1.messageId=parseInt(w0.messageId,10):"number"==typeof w0.messageId?w1.messageId=w0.messageId:"object"===(0,w3.default)(w0.messageId)&&(w1.messageId=new w9.LongBits(w0.messageId.low>>>0,w0.messageId.high>>>0).toNumber())),null!=w0.content){if("object"!==(0,w3.default)(w0.content))throw TypeError(".UpdateMessageContent.content: object expected");w1.content=w10.MessageContent.fromObject(w0.content)}return null!=w0.distribute&&(w1.distribute=0|w0.distribute),null!=w0.updateTime&&(w1.updateTime=0|w0.updateTime),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w9.Long){var w3=new w9.Long(0,0,!1);w2.messageId=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.messageId=w1.longs===String?"0":0;w2.content=null,w2.distribute=0,w2.updateTime=0}return null!=w0.messageId&&w0.hasOwnProperty("messageId")&&("number"==typeof w0.messageId?w2.messageId=w1.longs===String?String(w0.messageId):w0.messageId:w2.messageId=w1.longs===String?w9.Long.prototype.toString.call(w0.messageId):w1.longs===Number?new w9.LongBits(w0.messageId.low>>>0,w0.messageId.high>>>0).toNumber():w0.messageId),null!=w0.content&&w0.hasOwnProperty("content")&&(w2.content=w10.MessageContent.toObject(w0.content,w1)),null!=w0.distribute&&w0.hasOwnProperty("distribute")&&(w2.distribute=w0.distribute),null!=w0.updateTime&&w0.hasOwnProperty("updateTime")&&(w2.updateTime=w0.updateTime),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.FileRecord=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.messageId=w0.int64();break;case 2:w3.fromUser=w0.string();break;case 3:w3.conversation=w10.Conversation.decode(w0,w0.uint32());break;case 4:w3.name=w0.string();break;case 5:w3.url=w0.string();break;case 6:w3.size=w0.int32();break;case 7:w3.downloadCount=w0.int32();break;case 8:w3.dt=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("messageId"))throw w9.ProtocolError("missing required 'messageId'",{instance:w3});if(!w3.hasOwnProperty("fromUser"))throw w9.ProtocolError("missing required 'fromUser'",{instance:w3});if(!w3.hasOwnProperty("url"))throw w9.ProtocolError("missing required 'url'",{instance:w3});if(!w3.hasOwnProperty("size"))throw w9.ProtocolError("missing required 'size'",{instance:w3});if(!w3.hasOwnProperty("dt"))throw w9.ProtocolError("missing required 'dt'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!(w9.isInteger(w0.messageId)||w0.messageId&&w9.isInteger(w0.messageId.low)&&w9.isInteger(w0.messageId.high)))return"messageId: integer|Long expected";if(!w9.isString(w0.fromUser))return"fromUser: string expected";if(null!=w0.conversation&&w0.hasOwnProperty("conversation")){var w1=w10.Conversation.verify(w0.conversation);if(w1)return"conversation."+w1}return null!=w0.name&&w0.hasOwnProperty("name")&&!w9.isString(w0.name)?"name: string expected":w9.isString(w0.url)?w9.isInteger(w0.size)?null!=w0.downloadCount&&w0.hasOwnProperty("downloadCount")&&!w9.isInteger(w0.downloadCount)?"downloadCount: integer expected":w9.isInteger(w0.dt)||w0.dt&&w9.isInteger(w0.dt.low)&&w9.isInteger(w0.dt.high)?null:"dt: integer|Long expected":"size: integer expected":"url: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.FileRecord)return w0;var w1=new w10.FileRecord;if(null!=w0.messageId&&(w9.Long?(w1.messageId=w9.Long.fromValue(w0.messageId)).unsigned=!1:"string"==typeof w0.messageId?w1.messageId=parseInt(w0.messageId,10):"number"==typeof w0.messageId?w1.messageId=w0.messageId:"object"===(0,w3.default)(w0.messageId)&&(w1.messageId=new w9.LongBits(w0.messageId.low>>>0,w0.messageId.high>>>0).toNumber())),null!=w0.fromUser&&(w1.fromUser=String(w0.fromUser)),null!=w0.conversation){if("object"!==(0,w3.default)(w0.conversation))throw TypeError(".FileRecord.conversation: object expected");w1.conversation=w10.Conversation.fromObject(w0.conversation)}return null!=w0.name&&(w1.name=String(w0.name)),null!=w0.url&&(w1.url=String(w0.url)),null!=w0.size&&(w1.size=0|w0.size),null!=w0.downloadCount&&(w1.downloadCount=0|w0.downloadCount),null!=w0.dt&&(w9.Long?(w1.dt=w9.Long.fromValue(w0.dt)).unsigned=!1:"string"==typeof w0.dt?w1.dt=parseInt(w0.dt,10):"number"==typeof w0.dt?w1.dt=w0.dt:"object"===(0,w3.default)(w0.dt)&&(w1.dt=new w9.LongBits(w0.dt.low>>>0,w0.dt.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w9.Long){var w3=new w9.Long(0,0,!1);w2.messageId=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.messageId=w1.longs===String?"0":0;if(w2.fromUser="",w2.conversation=null,w2.name="",w2.url="",w2.size=0,w2.downloadCount=0,w9.Long){w3=new w9.Long(0,0,!1);w2.dt=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.dt=w1.longs===String?"0":0}return null!=w0.messageId&&w0.hasOwnProperty("messageId")&&("number"==typeof w0.messageId?w2.messageId=w1.longs===String?String(w0.messageId):w0.messageId:w2.messageId=w1.longs===String?w9.Long.prototype.toString.call(w0.messageId):w1.longs===Number?new w9.LongBits(w0.messageId.low>>>0,w0.messageId.high>>>0).toNumber():w0.messageId),null!=w0.fromUser&&w0.hasOwnProperty("fromUser")&&(w2.fromUser=w0.fromUser),null!=w0.conversation&&w0.hasOwnProperty("conversation")&&(w2.conversation=w10.Conversation.toObject(w0.conversation,w1)),null!=w0.name&&w0.hasOwnProperty("name")&&(w2.name=w0.name),null!=w0.url&&w0.hasOwnProperty("url")&&(w2.url=w0.url),null!=w0.size&&w0.hasOwnProperty("size")&&(w2.size=w0.size),null!=w0.downloadCount&&w0.hasOwnProperty("downloadCount")&&(w2.downloadCount=w0.downloadCount),null!=w0.dt&&w0.hasOwnProperty("dt")&&("number"==typeof w0.dt?w2.dt=w1.longs===String?String(w0.dt):w0.dt:w2.dt=w1.longs===String?w9.Long.prototype.toString.call(w0.dt):w1.longs===Number?new w9.LongBits(w0.dt.low>>>0,w0.dt.high>>>0).toNumber():w0.dt),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.LoadFileRecordReq=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.conversation=w10.Conversation.decode(w0,w0.uint32());break;case 2:w3.messageId=w0.int64();break;case 3:w3.count=w0.int32();break;case 4:w3.from=w0.string();break;case 5:w3.order=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("messageId"))throw w9.ProtocolError("missing required 'messageId'",{instance:w3});if(!w3.hasOwnProperty("count"))throw w9.ProtocolError("missing required 'count'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.conversation&&w0.hasOwnProperty("conversation")){var w1=w10.Conversation.verify(w0.conversation);if(w1)return"conversation."+w1}return w9.isInteger(w0.messageId)||w0.messageId&&w9.isInteger(w0.messageId.low)&&w9.isInteger(w0.messageId.high)?w9.isInteger(w0.count)?null!=w0.from&&w0.hasOwnProperty("from")&&!w9.isString(w0.from)?"from: string expected":null!=w0.order&&w0.hasOwnProperty("order")&&!w9.isInteger(w0.order)?"order: integer expected":null:"count: integer expected":"messageId: integer|Long expected"},w0.fromObject=function(w0){if(w0 instanceof w10.LoadFileRecordReq)return w0;var w1=new w10.LoadFileRecordReq;if(null!=w0.conversation){if("object"!==(0,w3.default)(w0.conversation))throw TypeError(".LoadFileRecordReq.conversation: object expected");w1.conversation=w10.Conversation.fromObject(w0.conversation)}return null!=w0.messageId&&(w9.Long?(w1.messageId=w9.Long.fromValue(w0.messageId)).unsigned=!1:"string"==typeof w0.messageId?w1.messageId=parseInt(w0.messageId,10):"number"==typeof w0.messageId?w1.messageId=w0.messageId:"object"===(0,w3.default)(w0.messageId)&&(w1.messageId=new w9.LongBits(w0.messageId.low>>>0,w0.messageId.high>>>0).toNumber())),null!=w0.count&&(w1.count=0|w0.count),null!=w0.from&&(w1.from=String(w0.from)),null!=w0.order&&(w1.order=0|w0.order),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w2.conversation=null,w9.Long){var w3=new w9.Long(0,0,!1);w2.messageId=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.messageId=w1.longs===String?"0":0;w2.count=0,w2.from="",w2.order=0}return null!=w0.conversation&&w0.hasOwnProperty("conversation")&&(w2.conversation=w10.Conversation.toObject(w0.conversation,w1)),null!=w0.messageId&&w0.hasOwnProperty("messageId")&&("number"==typeof w0.messageId?w2.messageId=w1.longs===String?String(w0.messageId):w0.messageId:w2.messageId=w1.longs===String?w9.Long.prototype.toString.call(w0.messageId):w1.longs===Number?new w9.LongBits(w0.messageId.low>>>0,w0.messageId.high>>>0).toNumber():w0.messageId),null!=w0.count&&w0.hasOwnProperty("count")&&(w2.count=w0.count),null!=w0.from&&w0.hasOwnProperty("from")&&(w2.from=w0.from),null!=w0.order&&w0.hasOwnProperty("order")&&(w2.order=w0.order),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.LoadFileRecordRes=function(){function w0(w0){if(this.record=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3==1)w3.record&&w3.record.length||(w3.record=[]),w3.record.push(w10.FileRecord.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.record&&w0.hasOwnProperty("record")){if(!Array.isArray(w0.record))return"record: array expected";for(var w1=0;w1>>3){case 1:w3.keyword=w0.string();break;case 2:w3.conversation=w10.Conversation.decode(w0,w0.uint32());break;case 3:w3.messageId=w0.int64();break;case 4:w3.count=w0.int32();break;case 5:w3.from=w0.string();break;case 6:w3.order=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("keyword"))throw w9.ProtocolError("missing required 'keyword'",{instance:w3});if(!w3.hasOwnProperty("messageId"))throw w9.ProtocolError("missing required 'messageId'",{instance:w3});if(!w3.hasOwnProperty("count"))throw w9.ProtocolError("missing required 'count'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!w9.isString(w0.keyword))return"keyword: string expected";if(null!=w0.conversation&&w0.hasOwnProperty("conversation")){var w1=w10.Conversation.verify(w0.conversation);if(w1)return"conversation."+w1}return w9.isInteger(w0.messageId)||w0.messageId&&w9.isInteger(w0.messageId.low)&&w9.isInteger(w0.messageId.high)?w9.isInteger(w0.count)?null!=w0.from&&w0.hasOwnProperty("from")&&!w9.isString(w0.from)?"from: string expected":null!=w0.order&&w0.hasOwnProperty("order")&&!w9.isInteger(w0.order)?"order: integer expected":null:"count: integer expected":"messageId: integer|Long expected"},w0.fromObject=function(w0){if(w0 instanceof w10.SearchFileRecordReq)return w0;var w1=new w10.SearchFileRecordReq;if(null!=w0.keyword&&(w1.keyword=String(w0.keyword)),null!=w0.conversation){if("object"!==(0,w3.default)(w0.conversation))throw TypeError(".SearchFileRecordReq.conversation: object expected");w1.conversation=w10.Conversation.fromObject(w0.conversation)}return null!=w0.messageId&&(w9.Long?(w1.messageId=w9.Long.fromValue(w0.messageId)).unsigned=!1:"string"==typeof w0.messageId?w1.messageId=parseInt(w0.messageId,10):"number"==typeof w0.messageId?w1.messageId=w0.messageId:"object"===(0,w3.default)(w0.messageId)&&(w1.messageId=new w9.LongBits(w0.messageId.low>>>0,w0.messageId.high>>>0).toNumber())),null!=w0.count&&(w1.count=0|w0.count),null!=w0.from&&(w1.from=String(w0.from)),null!=w0.order&&(w1.order=0|w0.order),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w2.keyword="",w2.conversation=null,w9.Long){var w3=new w9.Long(0,0,!1);w2.messageId=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.messageId=w1.longs===String?"0":0;w2.count=0,w2.from="",w2.order=0}return null!=w0.keyword&&w0.hasOwnProperty("keyword")&&(w2.keyword=w0.keyword),null!=w0.conversation&&w0.hasOwnProperty("conversation")&&(w2.conversation=w10.Conversation.toObject(w0.conversation,w1)),null!=w0.messageId&&w0.hasOwnProperty("messageId")&&("number"==typeof w0.messageId?w2.messageId=w1.longs===String?String(w0.messageId):w0.messageId:w2.messageId=w1.longs===String?w9.Long.prototype.toString.call(w0.messageId):w1.longs===Number?new w9.LongBits(w0.messageId.low>>>0,w0.messageId.high>>>0).toNumber():w0.messageId),null!=w0.count&&w0.hasOwnProperty("count")&&(w2.count=w0.count),null!=w0.from&&w0.hasOwnProperty("from")&&(w2.from=w0.from),null!=w0.order&&w0.hasOwnProperty("order")&&(w2.order=w0.order),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.ConferenceRequest=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.sessionId=w0.int64();break;case 2:w3.request=w0.string();break;case 3:w3.data=w0.string();break;case 4:w3.roomId=w0.string();break;case 5:w3.advance=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("request"))throw w9.ProtocolError("missing required 'request'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":null!=w0.sessionId&&w0.hasOwnProperty("sessionId")&&!(w9.isInteger(w0.sessionId)||w0.sessionId&&w9.isInteger(w0.sessionId.low)&&w9.isInteger(w0.sessionId.high))?"sessionId: integer|Long expected":w9.isString(w0.request)?null!=w0.data&&w0.hasOwnProperty("data")&&!w9.isString(w0.data)?"data: string expected":null!=w0.roomId&&w0.hasOwnProperty("roomId")&&!w9.isString(w0.roomId)?"roomId: string expected":null!=w0.advance&&w0.hasOwnProperty("advance")&&!w9.isInteger(w0.advance)?"advance: integer expected":null:"request: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.ConferenceRequest)return w0;var w1=new w10.ConferenceRequest;return null!=w0.sessionId&&(w9.Long?(w1.sessionId=w9.Long.fromValue(w0.sessionId)).unsigned=!1:"string"==typeof w0.sessionId?w1.sessionId=parseInt(w0.sessionId,10):"number"==typeof w0.sessionId?w1.sessionId=w0.sessionId:"object"===(0,w3.default)(w0.sessionId)&&(w1.sessionId=new w9.LongBits(w0.sessionId.low>>>0,w0.sessionId.high>>>0).toNumber())),null!=w0.request&&(w1.request=String(w0.request)),null!=w0.data&&(w1.data=String(w0.data)),null!=w0.roomId&&(w1.roomId=String(w0.roomId)),null!=w0.advance&&(w1.advance=0|w0.advance),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w9.Long){var w3=new w9.Long(0,0,!1);w2.sessionId=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.sessionId=w1.longs===String?"0":0;w2.request="",w2.data="",w2.roomId="",w2.advance=0}return null!=w0.sessionId&&w0.hasOwnProperty("sessionId")&&("number"==typeof w0.sessionId?w2.sessionId=w1.longs===String?String(w0.sessionId):w0.sessionId:w2.sessionId=w1.longs===String?w9.Long.prototype.toString.call(w0.sessionId):w1.longs===Number?new w9.LongBits(w0.sessionId.low>>>0,w0.sessionId.high>>>0).toNumber():w0.sessionId),null!=w0.request&&w0.hasOwnProperty("request")&&(w2.request=w0.request),null!=w0.data&&w0.hasOwnProperty("data")&&(w2.data=w0.data),null!=w0.roomId&&w0.hasOwnProperty("roomId")&&(w2.roomId=w0.roomId),null!=w0.advance&&w0.hasOwnProperty("advance")&&(w2.advance=w0.advance),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.ConfInfo=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.roomId=w0.string();break;case 2:w3.description=w0.string();break;case 3:w3.serverId=w0.string();break;case 4:w3.pin=w0.string();break;case 5:w3.publishers=w0.int32();break;case 6:w3.numPublisher=w0.int32();break;case 7:w3.bitrate=w0.int32();break;case 8:w3.advance=w0.int32();break;case 9:w3.record=w0.int32();break;case 10:w3.permanent=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("roomId"))throw w9.ProtocolError("missing required 'roomId'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.roomId)?null!=w0.description&&w0.hasOwnProperty("description")&&!w9.isString(w0.description)?"description: string expected":null!=w0.serverId&&w0.hasOwnProperty("serverId")&&!w9.isString(w0.serverId)?"serverId: string expected":null!=w0.pin&&w0.hasOwnProperty("pin")&&!w9.isString(w0.pin)?"pin: string expected":null!=w0.publishers&&w0.hasOwnProperty("publishers")&&!w9.isInteger(w0.publishers)?"publishers: integer expected":null!=w0.numPublisher&&w0.hasOwnProperty("numPublisher")&&!w9.isInteger(w0.numPublisher)?"numPublisher: integer expected":null!=w0.bitrate&&w0.hasOwnProperty("bitrate")&&!w9.isInteger(w0.bitrate)?"bitrate: integer expected":null!=w0.advance&&w0.hasOwnProperty("advance")&&!w9.isInteger(w0.advance)?"advance: integer expected":null!=w0.record&&w0.hasOwnProperty("record")&&!w9.isInteger(w0.record)?"record: integer expected":null!=w0.permanent&&w0.hasOwnProperty("permanent")&&!w9.isInteger(w0.permanent)?"permanent: integer expected":null:"roomId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.ConfInfo)return w0;var w1=new w10.ConfInfo;return null!=w0.roomId&&(w1.roomId=String(w0.roomId)),null!=w0.description&&(w1.description=String(w0.description)),null!=w0.serverId&&(w1.serverId=String(w0.serverId)),null!=w0.pin&&(w1.pin=String(w0.pin)),null!=w0.publishers&&(w1.publishers=0|w0.publishers),null!=w0.numPublisher&&(w1.numPublisher=0|w0.numPublisher),null!=w0.bitrate&&(w1.bitrate=0|w0.bitrate),null!=w0.advance&&(w1.advance=0|w0.advance),null!=w0.record&&(w1.record=0|w0.record),null!=w0.permanent&&(w1.permanent=0|w0.permanent),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.roomId="",w2.description="",w2.serverId="",w2.pin="",w2.publishers=0,w2.numPublisher=0,w2.bitrate=0,w2.advance=0,w2.record=0,w2.permanent=0),null!=w0.roomId&&w0.hasOwnProperty("roomId")&&(w2.roomId=w0.roomId),null!=w0.description&&w0.hasOwnProperty("description")&&(w2.description=w0.description),null!=w0.serverId&&w0.hasOwnProperty("serverId")&&(w2.serverId=w0.serverId),null!=w0.pin&&w0.hasOwnProperty("pin")&&(w2.pin=w0.pin),null!=w0.publishers&&w0.hasOwnProperty("publishers")&&(w2.publishers=w0.publishers),null!=w0.numPublisher&&w0.hasOwnProperty("numPublisher")&&(w2.numPublisher=w0.numPublisher),null!=w0.bitrate&&w0.hasOwnProperty("bitrate")&&(w2.bitrate=w0.bitrate),null!=w0.advance&&w0.hasOwnProperty("advance")&&(w2.advance=w0.advance),null!=w0.record&&w0.hasOwnProperty("record")&&(w2.record=w0.record),null!=w0.permanent&&w0.hasOwnProperty("permanent")&&(w2.permanent=w0.permanent),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.ConfInfos=function(){function w0(w0){if(this.info=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3==1)w3.info&&w3.info.length||(w3.info=[]),w3.info.push(w10.ConfInfo.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.info&&w0.hasOwnProperty("info")){if(!Array.isArray(w0.info))return"info: array expected";for(var w1=0;w1>>3){case 1:w3.type=w0.string();break;case 2:w3.mid=w0.string();break;case 3:w3.codec=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("type"))throw w9.ProtocolError("missing required 'type'",{instance:w3});if(!w3.hasOwnProperty("mid"))throw w9.ProtocolError("missing required 'mid'",{instance:w3});if(!w3.hasOwnProperty("codec"))throw w9.ProtocolError("missing required 'codec'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.type)?w9.isString(w0.mid)?w9.isString(w0.codec)?null:"codec: string expected":"mid: string expected":"type: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.ConfStream)return w0;var w1=new w10.ConfStream;return null!=w0.type&&(w1.type=String(w0.type)),null!=w0.mid&&(w1.mid=String(w0.mid)),null!=w0.codec&&(w1.codec=String(w0.codec)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.type="",w2.mid="",w2.codec=""),null!=w0.type&&w0.hasOwnProperty("type")&&(w2.type=w0.type),null!=w0.mid&&w0.hasOwnProperty("mid")&&(w2.mid=w0.mid),null!=w0.codec&&w0.hasOwnProperty("codec")&&(w2.codec=w0.codec),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.ConfParticipant=function(){function w0(w0){if(this.stream=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.userId=w0.string();break;case 2:w3.publisher=w0.int32();break;case 3:w3.stream&&w3.stream.length||(w3.stream=[]),w3.stream.push(w10.ConfStream.decode(w0,w0.uint32()));break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("userId"))throw w9.ProtocolError("missing required 'userId'",{instance:w3});if(!w3.hasOwnProperty("publisher"))throw w9.ProtocolError("missing required 'publisher'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!w9.isString(w0.userId))return"userId: string expected";if(!w9.isInteger(w0.publisher))return"publisher: integer expected";if(null!=w0.stream&&w0.hasOwnProperty("stream")){if(!Array.isArray(w0.stream))return"stream: array expected";for(var w1=0;w1>>3==1)w3.participant&&w3.participant.length||(w3.participant=[]),w3.participant.push(w10.ConfParticipant.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.participant&&w0.hasOwnProperty("participant")){if(!Array.isArray(w0.participant))return"participant: array expected";for(var w1=0;w1>>3){case 1:w3.roomId=w0.string();break;case 2:w3.publisherId=w0.string();break;case 3:w3.host=w0.string();break;case 4:w3.audioPort=w0.int32();break;case 5:w3.audioPt=w0.int32();break;case 6:w3.audioSsrc=w0.int64();break;case 7:w3.videoPort=w0.int32();break;case 8:w3.videoPt=w0.int32();break;case 9:w3.videoSsrc=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("roomId"))throw w9.ProtocolError("missing required 'roomId'",{instance:w3});if(!w3.hasOwnProperty("publisherId"))throw w9.ProtocolError("missing required 'publisherId'",{instance:w3});if(!w3.hasOwnProperty("host"))throw w9.ProtocolError("missing required 'host'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.roomId)?w9.isString(w0.publisherId)?w9.isString(w0.host)?null!=w0.audioPort&&w0.hasOwnProperty("audioPort")&&!w9.isInteger(w0.audioPort)?"audioPort: integer expected":null!=w0.audioPt&&w0.hasOwnProperty("audioPt")&&!w9.isInteger(w0.audioPt)?"audioPt: integer expected":null!=w0.audioSsrc&&w0.hasOwnProperty("audioSsrc")&&!(w9.isInteger(w0.audioSsrc)||w0.audioSsrc&&w9.isInteger(w0.audioSsrc.low)&&w9.isInteger(w0.audioSsrc.high))?"audioSsrc: integer|Long expected":null!=w0.videoPort&&w0.hasOwnProperty("videoPort")&&!w9.isInteger(w0.videoPort)?"videoPort: integer expected":null!=w0.videoPt&&w0.hasOwnProperty("videoPt")&&!w9.isInteger(w0.videoPt)?"videoPt: integer expected":null!=w0.videoSsrc&&w0.hasOwnProperty("videoSsrc")&&!(w9.isInteger(w0.videoSsrc)||w0.videoSsrc&&w9.isInteger(w0.videoSsrc.low)&&w9.isInteger(w0.videoSsrc.high))?"videoSsrc: integer|Long expected":null:"host: string expected":"publisherId: string expected":"roomId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.ConfRtpForwardReq)return w0;var w1=new w10.ConfRtpForwardReq;return null!=w0.roomId&&(w1.roomId=String(w0.roomId)),null!=w0.publisherId&&(w1.publisherId=String(w0.publisherId)),null!=w0.host&&(w1.host=String(w0.host)),null!=w0.audioPort&&(w1.audioPort=0|w0.audioPort),null!=w0.audioPt&&(w1.audioPt=0|w0.audioPt),null!=w0.audioSsrc&&(w9.Long?(w1.audioSsrc=w9.Long.fromValue(w0.audioSsrc)).unsigned=!1:"string"==typeof w0.audioSsrc?w1.audioSsrc=parseInt(w0.audioSsrc,10):"number"==typeof w0.audioSsrc?w1.audioSsrc=w0.audioSsrc:"object"===(0,w3.default)(w0.audioSsrc)&&(w1.audioSsrc=new w9.LongBits(w0.audioSsrc.low>>>0,w0.audioSsrc.high>>>0).toNumber())),null!=w0.videoPort&&(w1.videoPort=0|w0.videoPort),null!=w0.videoPt&&(w1.videoPt=0|w0.videoPt),null!=w0.videoSsrc&&(w9.Long?(w1.videoSsrc=w9.Long.fromValue(w0.videoSsrc)).unsigned=!1:"string"==typeof w0.videoSsrc?w1.videoSsrc=parseInt(w0.videoSsrc,10):"number"==typeof w0.videoSsrc?w1.videoSsrc=w0.videoSsrc:"object"===(0,w3.default)(w0.videoSsrc)&&(w1.videoSsrc=new w9.LongBits(w0.videoSsrc.low>>>0,w0.videoSsrc.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w2.roomId="",w2.publisherId="",w2.host="",w2.audioPort=0,w2.audioPt=0,w9.Long){var w3=new w9.Long(0,0,!1);w2.audioSsrc=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.audioSsrc=w1.longs===String?"0":0;if(w2.videoPort=0,w2.videoPt=0,w9.Long){w3=new w9.Long(0,0,!1);w2.videoSsrc=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.videoSsrc=w1.longs===String?"0":0}return null!=w0.roomId&&w0.hasOwnProperty("roomId")&&(w2.roomId=w0.roomId),null!=w0.publisherId&&w0.hasOwnProperty("publisherId")&&(w2.publisherId=w0.publisherId),null!=w0.host&&w0.hasOwnProperty("host")&&(w2.host=w0.host),null!=w0.audioPort&&w0.hasOwnProperty("audioPort")&&(w2.audioPort=w0.audioPort),null!=w0.audioPt&&w0.hasOwnProperty("audioPt")&&(w2.audioPt=w0.audioPt),null!=w0.audioSsrc&&w0.hasOwnProperty("audioSsrc")&&("number"==typeof w0.audioSsrc?w2.audioSsrc=w1.longs===String?String(w0.audioSsrc):w0.audioSsrc:w2.audioSsrc=w1.longs===String?w9.Long.prototype.toString.call(w0.audioSsrc):w1.longs===Number?new w9.LongBits(w0.audioSsrc.low>>>0,w0.audioSsrc.high>>>0).toNumber():w0.audioSsrc),null!=w0.videoPort&&w0.hasOwnProperty("videoPort")&&(w2.videoPort=w0.videoPort),null!=w0.videoPt&&w0.hasOwnProperty("videoPt")&&(w2.videoPt=w0.videoPt),null!=w0.videoSsrc&&w0.hasOwnProperty("videoSsrc")&&("number"==typeof w0.videoSsrc?w2.videoSsrc=w1.longs===String?String(w0.videoSsrc):w0.videoSsrc:w2.videoSsrc=w1.longs===String?w9.Long.prototype.toString.call(w0.videoSsrc):w1.longs===Number?new w9.LongBits(w0.videoSsrc.low>>>0,w0.videoSsrc.high>>>0).toNumber():w0.videoSsrc),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.RecallMultiCastMessageRequest=function(){function w0(w0){if(this.receiver=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.messageId=w0.int64();break;case 2:w3.receiver&&w3.receiver.length||(w3.receiver=[]),w3.receiver.push(w0.string());break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("messageId"))throw w9.ProtocolError("missing required 'messageId'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!(w9.isInteger(w0.messageId)||w0.messageId&&w9.isInteger(w0.messageId.low)&&w9.isInteger(w0.messageId.high)))return"messageId: integer|Long expected";if(null!=w0.receiver&&w0.hasOwnProperty("receiver")){if(!Array.isArray(w0.receiver))return"receiver: array expected";for(var w1=0;w1>>0,w0.messageId.high>>>0).toNumber())),w0.receiver){if(!Array.isArray(w0.receiver))throw TypeError(".RecallMultiCastMessageRequest.receiver: array expected");w1.receiver=[];for(var w2=0;w2>>0,w0.messageId.high>>>0).toNumber():w0.messageId),w0.receiver&&w0.receiver.length){w2.receiver=[];for(var w4=0;w4>>3){case 1:w3.mediaUrl=w0.string();break;case 2:w3.thumbUrl=w0.string();break;case 3:w3.width=w0.int32();break;case 4:w3.height=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("mediaUrl"))throw w9.ProtocolError("missing required 'mediaUrl'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.mediaUrl)?null!=w0.thumbUrl&&w0.hasOwnProperty("thumbUrl")&&!w9.isString(w0.thumbUrl)?"thumbUrl: string expected":null!=w0.width&&w0.hasOwnProperty("width")&&!w9.isInteger(w0.width)?"width: integer expected":null!=w0.height&&w0.hasOwnProperty("height")&&!w9.isInteger(w0.height)?"height: integer expected":null:"mediaUrl: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.MomentsMedia)return w0;var w1=new w10.MomentsMedia;return null!=w0.mediaUrl&&(w1.mediaUrl=String(w0.mediaUrl)),null!=w0.thumbUrl&&(w1.thumbUrl=String(w0.thumbUrl)),null!=w0.width&&(w1.width=0|w0.width),null!=w0.height&&(w1.height=0|w0.height),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.mediaUrl="",w2.thumbUrl="",w2.width=0,w2.height=0),null!=w0.mediaUrl&&w0.hasOwnProperty("mediaUrl")&&(w2.mediaUrl=w0.mediaUrl),null!=w0.thumbUrl&&w0.hasOwnProperty("thumbUrl")&&(w2.thumbUrl=w0.thumbUrl),null!=w0.width&&w0.hasOwnProperty("width")&&(w2.width=w0.width),null!=w0.height&&w0.hasOwnProperty("height")&&(w2.height=w0.height),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.MomentsFeed=function(){function w0(w0){if(this.medias=[],this.mentionedUsers=[],this.toUsers=[],this.excludeUsers=[],this.comments=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.feedId=w0.int64();break;case 2:w3.sender=w0.string();break;case 3:w3.type=w0.int32();break;case 4:w3.text=w0.string();break;case 5:w3.medias&&w3.medias.length||(w3.medias=[]),w3.medias.push(w10.MomentsMedia.decode(w0,w0.uint32()));break;case 6:w3.mentionedUsers&&w3.mentionedUsers.length||(w3.mentionedUsers=[]),w3.mentionedUsers.push(w0.string());break;case 7:w3.toUsers&&w3.toUsers.length||(w3.toUsers=[]),w3.toUsers.push(w0.string());break;case 8:w3.excludeUsers&&w3.excludeUsers.length||(w3.excludeUsers=[]),w3.excludeUsers.push(w0.string());break;case 9:w3.serverTime=w0.int64();break;case 10:w3.extra=w0.string();break;case 11:w3.comments&&w3.comments.length||(w3.comments=[]),w3.comments.push(w10.MomentsComment.decode(w0,w0.uint32()));break;case 12:w3.hasMore=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("feedId"))throw w9.ProtocolError("missing required 'feedId'",{instance:w3});if(!w3.hasOwnProperty("sender"))throw w9.ProtocolError("missing required 'sender'",{instance:w3});if(!w3.hasOwnProperty("type"))throw w9.ProtocolError("missing required 'type'",{instance:w3});if(!w3.hasOwnProperty("serverTime"))throw w9.ProtocolError("missing required 'serverTime'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!(w9.isInteger(w0.feedId)||w0.feedId&&w9.isInteger(w0.feedId.low)&&w9.isInteger(w0.feedId.high)))return"feedId: integer|Long expected";if(!w9.isString(w0.sender))return"sender: string expected";if(!w9.isInteger(w0.type))return"type: integer expected";if(null!=w0.text&&w0.hasOwnProperty("text")&&!w9.isString(w0.text))return"text: string expected";if(null!=w0.medias&&w0.hasOwnProperty("medias")){if(!Array.isArray(w0.medias))return"medias: array expected";for(var w1=0;w1>>0,w0.feedId.high>>>0).toNumber())),null!=w0.sender&&(w1.sender=String(w0.sender)),null!=w0.type&&(w1.type=0|w0.type),null!=w0.text&&(w1.text=String(w0.text)),w0.medias){if(!Array.isArray(w0.medias))throw TypeError(".MomentsFeed.medias: array expected");w1.medias=[];for(var w2=0;w2>>0,w0.serverTime.high>>>0).toNumber())),null!=w0.extra&&(w1.extra=String(w0.extra)),w0.comments){if(!Array.isArray(w0.comments))throw TypeError(".MomentsFeed.comments: array expected");w1.comments=[];for(w2=0;w2>>0,w0.feedId.high>>>0).toNumber():w0.feedId),null!=w0.sender&&w0.hasOwnProperty("sender")&&(w2.sender=w0.sender),null!=w0.type&&w0.hasOwnProperty("type")&&(w2.type=w0.type),null!=w0.text&&w0.hasOwnProperty("text")&&(w2.text=w0.text),w0.medias&&w0.medias.length){w2.medias=[];for(var w4=0;w4>>0,w0.serverTime.high>>>0).toNumber():w0.serverTime),null!=w0.extra&&w0.hasOwnProperty("extra")&&(w2.extra=w0.extra),w0.comments&&w0.comments.length){w2.comments=[];for(w4=0;w4>>3==1)w3.feeds&&w3.feeds.length||(w3.feeds=[]),w3.feeds.push(w10.MomentsFeed.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.feeds&&w0.hasOwnProperty("feeds")){if(!Array.isArray(w0.feeds))return"feeds: array expected";for(var w1=0;w1>>3==1)w3.comments&&w3.comments.length||(w3.comments=[]),w3.comments.push(w10.MomentsComment.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.comments&&w0.hasOwnProperty("comments")){if(!Array.isArray(w0.comments))return"comments: array expected";for(var w1=0;w1>>3){case 1:w3.feedId=w0.int64();break;case 2:w3.commentId=w0.int64();break;case 3:w3.replyId=w0.int64();break;case 4:w3.sender=w0.string();break;case 5:w3.type=w0.int32();break;case 6:w3.text=w0.string();break;case 7:w3.replyTo=w0.string();break;case 8:w3.serverTime=w0.int64();break;case 9:w3.extra=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("feedId"))throw w9.ProtocolError("missing required 'feedId'",{instance:w3});if(!w3.hasOwnProperty("commentId"))throw w9.ProtocolError("missing required 'commentId'",{instance:w3});if(!w3.hasOwnProperty("sender"))throw w9.ProtocolError("missing required 'sender'",{instance:w3});if(!w3.hasOwnProperty("type"))throw w9.ProtocolError("missing required 'type'",{instance:w3});if(!w3.hasOwnProperty("serverTime"))throw w9.ProtocolError("missing required 'serverTime'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.feedId)||w0.feedId&&w9.isInteger(w0.feedId.low)&&w9.isInteger(w0.feedId.high)?w9.isInteger(w0.commentId)||w0.commentId&&w9.isInteger(w0.commentId.low)&&w9.isInteger(w0.commentId.high)?null!=w0.replyId&&w0.hasOwnProperty("replyId")&&!(w9.isInteger(w0.replyId)||w0.replyId&&w9.isInteger(w0.replyId.low)&&w9.isInteger(w0.replyId.high))?"replyId: integer|Long expected":w9.isString(w0.sender)?w9.isInteger(w0.type)?null!=w0.text&&w0.hasOwnProperty("text")&&!w9.isString(w0.text)?"text: string expected":null!=w0.replyTo&&w0.hasOwnProperty("replyTo")&&!w9.isString(w0.replyTo)?"replyTo: string expected":w9.isInteger(w0.serverTime)||w0.serverTime&&w9.isInteger(w0.serverTime.low)&&w9.isInteger(w0.serverTime.high)?null!=w0.extra&&w0.hasOwnProperty("extra")&&!w9.isString(w0.extra)?"extra: string expected":null:"serverTime: integer|Long expected":"type: integer expected":"sender: string expected":"commentId: integer|Long expected":"feedId: integer|Long expected"},w0.fromObject=function(w0){if(w0 instanceof w10.MomentsComment)return w0;var w1=new w10.MomentsComment;return null!=w0.feedId&&(w9.Long?(w1.feedId=w9.Long.fromValue(w0.feedId)).unsigned=!1:"string"==typeof w0.feedId?w1.feedId=parseInt(w0.feedId,10):"number"==typeof w0.feedId?w1.feedId=w0.feedId:"object"===(0,w3.default)(w0.feedId)&&(w1.feedId=new w9.LongBits(w0.feedId.low>>>0,w0.feedId.high>>>0).toNumber())),null!=w0.commentId&&(w9.Long?(w1.commentId=w9.Long.fromValue(w0.commentId)).unsigned=!1:"string"==typeof w0.commentId?w1.commentId=parseInt(w0.commentId,10):"number"==typeof w0.commentId?w1.commentId=w0.commentId:"object"===(0,w3.default)(w0.commentId)&&(w1.commentId=new w9.LongBits(w0.commentId.low>>>0,w0.commentId.high>>>0).toNumber())),null!=w0.replyId&&(w9.Long?(w1.replyId=w9.Long.fromValue(w0.replyId)).unsigned=!1:"string"==typeof w0.replyId?w1.replyId=parseInt(w0.replyId,10):"number"==typeof w0.replyId?w1.replyId=w0.replyId:"object"===(0,w3.default)(w0.replyId)&&(w1.replyId=new w9.LongBits(w0.replyId.low>>>0,w0.replyId.high>>>0).toNumber())),null!=w0.sender&&(w1.sender=String(w0.sender)),null!=w0.type&&(w1.type=0|w0.type),null!=w0.text&&(w1.text=String(w0.text)),null!=w0.replyTo&&(w1.replyTo=String(w0.replyTo)),null!=w0.serverTime&&(w9.Long?(w1.serverTime=w9.Long.fromValue(w0.serverTime)).unsigned=!1:"string"==typeof w0.serverTime?w1.serverTime=parseInt(w0.serverTime,10):"number"==typeof w0.serverTime?w1.serverTime=w0.serverTime:"object"===(0,w3.default)(w0.serverTime)&&(w1.serverTime=new w9.LongBits(w0.serverTime.low>>>0,w0.serverTime.high>>>0).toNumber())),null!=w0.extra&&(w1.extra=String(w0.extra)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w9.Long){var w3=new w9.Long(0,0,!1);w2.feedId=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.feedId=w1.longs===String?"0":0;if(w9.Long){w3=new w9.Long(0,0,!1);w2.commentId=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.commentId=w1.longs===String?"0":0;if(w9.Long){w3=new w9.Long(0,0,!1);w2.replyId=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.replyId=w1.longs===String?"0":0;if(w2.sender="",w2.type=0,w2.text="",w2.replyTo="",w9.Long){w3=new w9.Long(0,0,!1);w2.serverTime=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.serverTime=w1.longs===String?"0":0;w2.extra=""}return null!=w0.feedId&&w0.hasOwnProperty("feedId")&&("number"==typeof w0.feedId?w2.feedId=w1.longs===String?String(w0.feedId):w0.feedId:w2.feedId=w1.longs===String?w9.Long.prototype.toString.call(w0.feedId):w1.longs===Number?new w9.LongBits(w0.feedId.low>>>0,w0.feedId.high>>>0).toNumber():w0.feedId),null!=w0.commentId&&w0.hasOwnProperty("commentId")&&("number"==typeof w0.commentId?w2.commentId=w1.longs===String?String(w0.commentId):w0.commentId:w2.commentId=w1.longs===String?w9.Long.prototype.toString.call(w0.commentId):w1.longs===Number?new w9.LongBits(w0.commentId.low>>>0,w0.commentId.high>>>0).toNumber():w0.commentId),null!=w0.replyId&&w0.hasOwnProperty("replyId")&&("number"==typeof w0.replyId?w2.replyId=w1.longs===String?String(w0.replyId):w0.replyId:w2.replyId=w1.longs===String?w9.Long.prototype.toString.call(w0.replyId):w1.longs===Number?new w9.LongBits(w0.replyId.low>>>0,w0.replyId.high>>>0).toNumber():w0.replyId),null!=w0.sender&&w0.hasOwnProperty("sender")&&(w2.sender=w0.sender),null!=w0.type&&w0.hasOwnProperty("type")&&(w2.type=w0.type),null!=w0.text&&w0.hasOwnProperty("text")&&(w2.text=w0.text),null!=w0.replyTo&&w0.hasOwnProperty("replyTo")&&(w2.replyTo=w0.replyTo),null!=w0.serverTime&&w0.hasOwnProperty("serverTime")&&("number"==typeof w0.serverTime?w2.serverTime=w1.longs===String?String(w0.serverTime):w0.serverTime:w2.serverTime=w1.longs===String?w9.Long.prototype.toString.call(w0.serverTime):w1.longs===Number?new w9.LongBits(w0.serverTime.low>>>0,w0.serverTime.high>>>0).toNumber():w0.serverTime),null!=w0.extra&&w0.hasOwnProperty("extra")&&(w2.extra=w0.extra),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.LockRequest=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.lockId=w0.string();break;case 2:w3.duration=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("lockId"))throw w9.ProtocolError("missing required 'lockId'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.lockId)?null!=w0.duration&&w0.hasOwnProperty("duration")&&!(w9.isInteger(w0.duration)||w0.duration&&w9.isInteger(w0.duration.low)&&w9.isInteger(w0.duration.high))?"duration: integer|Long expected":null:"lockId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.LockRequest)return w0;var w1=new w10.LockRequest;return null!=w0.lockId&&(w1.lockId=String(w0.lockId)),null!=w0.duration&&(w9.Long?(w1.duration=w9.Long.fromValue(w0.duration)).unsigned=!1:"string"==typeof w0.duration?w1.duration=parseInt(w0.duration,10):"number"==typeof w0.duration?w1.duration=w0.duration:"object"===(0,w3.default)(w0.duration)&&(w1.duration=new w9.LongBits(w0.duration.low>>>0,w0.duration.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults)if(w2.lockId="",w9.Long){var w3=new w9.Long(0,0,!1);w2.duration=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.duration=w1.longs===String?"0":0;return null!=w0.lockId&&w0.hasOwnProperty("lockId")&&(w2.lockId=w0.lockId),null!=w0.duration&&w0.hasOwnProperty("duration")&&("number"==typeof w0.duration?w2.duration=w1.longs===String?String(w0.duration):w0.duration:w2.duration=w1.longs===String?w9.Long.prototype.toString.call(w0.duration):w1.longs===Number?new w9.LongBits(w0.duration.low>>>0,w0.duration.high>>>0).toNumber():w0.duration),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PresenceOnlineState=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.platform=w0.int32();break;case 2:w3.state=w0.int32();break;case 3:w3.lastSeen=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("platform"))throw w9.ProtocolError("missing required 'platform'",{instance:w3});if(!w3.hasOwnProperty("state"))throw w9.ProtocolError("missing required 'state'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isInteger(w0.platform)?w9.isInteger(w0.state)?null!=w0.lastSeen&&w0.hasOwnProperty("lastSeen")&&!(w9.isInteger(w0.lastSeen)||w0.lastSeen&&w9.isInteger(w0.lastSeen.low)&&w9.isInteger(w0.lastSeen.high))?"lastSeen: integer|Long expected":null:"state: integer expected":"platform: integer expected"},w0.fromObject=function(w0){if(w0 instanceof w10.PresenceOnlineState)return w0;var w1=new w10.PresenceOnlineState;return null!=w0.platform&&(w1.platform=0|w0.platform),null!=w0.state&&(w1.state=0|w0.state),null!=w0.lastSeen&&(w9.Long?(w1.lastSeen=w9.Long.fromValue(w0.lastSeen)).unsigned=!1:"string"==typeof w0.lastSeen?w1.lastSeen=parseInt(w0.lastSeen,10):"number"==typeof w0.lastSeen?w1.lastSeen=w0.lastSeen:"object"===(0,w3.default)(w0.lastSeen)&&(w1.lastSeen=new w9.LongBits(w0.lastSeen.low>>>0,w0.lastSeen.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults)if(w2.platform=0,w2.state=0,w9.Long){var w3=new w9.Long(0,0,!1);w2.lastSeen=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.lastSeen=w1.longs===String?"0":0;return null!=w0.platform&&w0.hasOwnProperty("platform")&&(w2.platform=w0.platform),null!=w0.state&&w0.hasOwnProperty("state")&&(w2.state=w0.state),null!=w0.lastSeen&&w0.hasOwnProperty("lastSeen")&&("number"==typeof w0.lastSeen?w2.lastSeen=w1.longs===String?String(w0.lastSeen):w0.lastSeen:w2.lastSeen=w1.longs===String?w9.Long.prototype.toString.call(w0.lastSeen):w1.longs===Number?new w9.LongBits(w0.lastSeen.low>>>0,w0.lastSeen.high>>>0).toNumber():w0.lastSeen),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.PresenceOnlineNotify=function(){function w0(w0){if(this.state=[],w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.userId=w0.string();break;case 2:w3.customState=w0.int32();break;case 3:w3.customText=w0.string();break;case 4:w3.state&&w3.state.length||(w3.state=[]),w3.state.push(w10.PresenceOnlineState.decode(w0,w0.uint32()));break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("userId"))throw w9.ProtocolError("missing required 'userId'",{instance:w3});if(!w3.hasOwnProperty("customState"))throw w9.ProtocolError("missing required 'customState'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!w9.isString(w0.userId))return"userId: string expected";if(!w9.isInteger(w0.customState))return"customState: integer expected";if(null!=w0.customText&&w0.hasOwnProperty("customText")&&!w9.isString(w0.customText))return"customText: string expected";if(null!=w0.state&&w0.hasOwnProperty("state")){if(!Array.isArray(w0.state))return"state: array expected";for(var w1=0;w1>>3){case 1:w3.type=w0.int32();break;case 2:w3.target&&w3.target.length||(w3.target=[]),w3.target.push(w0.string());break;case 3:w3.duration=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("type"))throw w9.ProtocolError("missing required 'type'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(!w9.isInteger(w0.type))return"type: integer expected";if(null!=w0.target&&w0.hasOwnProperty("target")){if(!Array.isArray(w0.target))return"target: array expected";for(var w1=0;w1>>3==1)w3.notify&&w3.notify.length||(w3.notify=[]),w3.notify.push(w10.PresenceOnlineNotify.decode(w0,w0.uint32()));else w0.skipType(7&w4)}return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";if(null!=w0.notify&&w0.hasOwnProperty("notify")){if(!Array.isArray(w0.notify))return"notify: array expected";for(var w1=0;w1>>3){case 1:w3.userId=w0.string();break;case 2:w3.pubkey=w0.string();break;case 3:w3.targetId=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("userId"))throw w9.ProtocolError("missing required 'userId'",{instance:w3});if(!w3.hasOwnProperty("pubkey"))throw w9.ProtocolError("missing required 'pubkey'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.userId)?w9.isString(w0.pubkey)?null!=w0.targetId&&w0.hasOwnProperty("targetId")&&!w9.isString(w0.targetId)?"targetId: string expected":null:"pubkey: string expected":"userId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.CreateSecretChatRequest)return w0;var w1=new w10.CreateSecretChatRequest;return null!=w0.userId&&(w1.userId=String(w0.userId)),null!=w0.pubkey&&(w1.pubkey=String(w0.pubkey)),null!=w0.targetId&&(w1.targetId=String(w0.targetId)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.userId="",w2.pubkey="",w2.targetId=""),null!=w0.userId&&w0.hasOwnProperty("userId")&&(w2.userId=w0.userId),null!=w0.pubkey&&w0.hasOwnProperty("pubkey")&&(w2.pubkey=w0.pubkey),null!=w0.targetId&&w0.hasOwnProperty("targetId")&&(w2.targetId=w0.targetId),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.CreateSecretChatResponse=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.targetId=w0.string();break;case 2:w3.line=w0.int32();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("targetId"))throw w9.ProtocolError("missing required 'targetId'",{instance:w3});if(!w3.hasOwnProperty("line"))throw w9.ProtocolError("missing required 'line'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.targetId)?w9.isInteger(w0.line)?null:"line: integer expected":"targetId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.CreateSecretChatResponse)return w0;var w1=new w10.CreateSecretChatResponse;return null!=w0.targetId&&(w1.targetId=String(w0.targetId)),null!=w0.line&&(w1.line=0|w0.line),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.targetId="",w2.line=0),null!=w0.targetId&&w0.hasOwnProperty("targetId")&&(w2.targetId=w0.targetId),null!=w0.line&&w0.hasOwnProperty("line")&&(w2.line=w0.line),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.SecretChatInfo=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.targetId=w0.string();break;case 2:w3.from=w0.string();break;case 3:w3.to=w0.string();break;case 4:w3.state=w0.int32();break;case 5:w3.createDt=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("targetId"))throw w9.ProtocolError("missing required 'targetId'",{instance:w3});if(!w3.hasOwnProperty("from"))throw w9.ProtocolError("missing required 'from'",{instance:w3});if(!w3.hasOwnProperty("to"))throw w9.ProtocolError("missing required 'to'",{instance:w3});if(!w3.hasOwnProperty("state"))throw w9.ProtocolError("missing required 'state'",{instance:w3});if(!w3.hasOwnProperty("createDt"))throw w9.ProtocolError("missing required 'createDt'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.targetId)?w9.isString(w0.from)?w9.isString(w0.to)?w9.isInteger(w0.state)?w9.isInteger(w0.createDt)||w0.createDt&&w9.isInteger(w0.createDt.low)&&w9.isInteger(w0.createDt.high)?null:"createDt: integer|Long expected":"state: integer expected":"to: string expected":"from: string expected":"targetId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.SecretChatInfo)return w0;var w1=new w10.SecretChatInfo;return null!=w0.targetId&&(w1.targetId=String(w0.targetId)),null!=w0.from&&(w1.from=String(w0.from)),null!=w0.to&&(w1.to=String(w0.to)),null!=w0.state&&(w1.state=0|w0.state),null!=w0.createDt&&(w9.Long?(w1.createDt=w9.Long.fromValue(w0.createDt)).unsigned=!1:"string"==typeof w0.createDt?w1.createDt=parseInt(w0.createDt,10):"number"==typeof w0.createDt?w1.createDt=w0.createDt:"object"===(0,w3.default)(w0.createDt)&&(w1.createDt=new w9.LongBits(w0.createDt.low>>>0,w0.createDt.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults)if(w2.targetId="",w2.from="",w2.to="",w2.state=0,w9.Long){var w3=new w9.Long(0,0,!1);w2.createDt=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.createDt=w1.longs===String?"0":0;return null!=w0.targetId&&w0.hasOwnProperty("targetId")&&(w2.targetId=w0.targetId),null!=w0.from&&w0.hasOwnProperty("from")&&(w2.from=w0.from),null!=w0.to&&w0.hasOwnProperty("to")&&(w2.to=w0.to),null!=w0.state&&w0.hasOwnProperty("state")&&(w2.state=w0.state),null!=w0.createDt&&w0.hasOwnProperty("createDt")&&("number"==typeof w0.createDt?w2.createDt=w1.longs===String?String(w0.createDt):w0.createDt:w2.createDt=w1.longs===String?w9.Long.prototype.toString.call(w0.createDt):w1.longs===Number?new w9.LongBits(w0.createDt.low>>>0,w0.createDt.high>>>0).toNumber():w0.createDt),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.DeleteSecretChatMessage=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.conversation=w10.Conversation.decode(w0,w0.uint32());break;case 2:w3.messageId=w0.int64();break;case 3:w3.serverTimestamp=w0.int64();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("conversation"))throw w9.ProtocolError("missing required 'conversation'",{instance:w3});if(!w3.hasOwnProperty("messageId"))throw w9.ProtocolError("missing required 'messageId'",{instance:w3});if(!w3.hasOwnProperty("serverTimestamp"))throw w9.ProtocolError("missing required 'serverTimestamp'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){if("object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0)return"object expected";var w1=w10.Conversation.verify(w0.conversation);return w1?"conversation."+w1:w9.isInteger(w0.messageId)||w0.messageId&&w9.isInteger(w0.messageId.low)&&w9.isInteger(w0.messageId.high)?w9.isInteger(w0.serverTimestamp)||w0.serverTimestamp&&w9.isInteger(w0.serverTimestamp.low)&&w9.isInteger(w0.serverTimestamp.high)?null:"serverTimestamp: integer|Long expected":"messageId: integer|Long expected"},w0.fromObject=function(w0){if(w0 instanceof w10.DeleteSecretChatMessage)return w0;var w1=new w10.DeleteSecretChatMessage;if(null!=w0.conversation){if("object"!==(0,w3.default)(w0.conversation))throw TypeError(".DeleteSecretChatMessage.conversation: object expected");w1.conversation=w10.Conversation.fromObject(w0.conversation)}return null!=w0.messageId&&(w9.Long?(w1.messageId=w9.Long.fromValue(w0.messageId)).unsigned=!1:"string"==typeof w0.messageId?w1.messageId=parseInt(w0.messageId,10):"number"==typeof w0.messageId?w1.messageId=w0.messageId:"object"===(0,w3.default)(w0.messageId)&&(w1.messageId=new w9.LongBits(w0.messageId.low>>>0,w0.messageId.high>>>0).toNumber())),null!=w0.serverTimestamp&&(w9.Long?(w1.serverTimestamp=w9.Long.fromValue(w0.serverTimestamp)).unsigned=!1:"string"==typeof w0.serverTimestamp?w1.serverTimestamp=parseInt(w0.serverTimestamp,10):"number"==typeof w0.serverTimestamp?w1.serverTimestamp=w0.serverTimestamp:"object"===(0,w3.default)(w0.serverTimestamp)&&(w1.serverTimestamp=new w9.LongBits(w0.serverTimestamp.low>>>0,w0.serverTimestamp.high>>>0).toNumber())),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w2.conversation=null,w9.Long){var w3=new w9.Long(0,0,!1);w2.messageId=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.messageId=w1.longs===String?"0":0;if(w9.Long){w3=new w9.Long(0,0,!1);w2.serverTimestamp=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.serverTimestamp=w1.longs===String?"0":0}return null!=w0.conversation&&w0.hasOwnProperty("conversation")&&(w2.conversation=w10.Conversation.toObject(w0.conversation,w1)),null!=w0.messageId&&w0.hasOwnProperty("messageId")&&("number"==typeof w0.messageId?w2.messageId=w1.longs===String?String(w0.messageId):w0.messageId:w2.messageId=w1.longs===String?w9.Long.prototype.toString.call(w0.messageId):w1.longs===Number?new w9.LongBits(w0.messageId.low>>>0,w0.messageId.high>>>0).toNumber():w0.messageId),null!=w0.serverTimestamp&&w0.hasOwnProperty("serverTimestamp")&&("number"==typeof w0.serverTimestamp?w2.serverTimestamp=w1.longs===String?String(w0.serverTimestamp):w0.serverTimestamp:w2.serverTimestamp=w1.longs===String?w9.Long.prototype.toString.call(w0.serverTimestamp):w1.longs===Number?new w9.LongBits(w0.serverTimestamp.low>>>0,w0.serverTimestamp.high>>>0).toNumber():w0.serverTimestamp),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.AuthCodeRequest=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.targetId=w0.string();break;case 2:w3.type=w0.int32();break;case 3:w3.host=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("targetId"))throw w9.ProtocolError("missing required 'targetId'",{instance:w3});if(!w3.hasOwnProperty("type"))throw w9.ProtocolError("missing required 'type'",{instance:w3});if(!w3.hasOwnProperty("host"))throw w9.ProtocolError("missing required 'host'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.targetId)?w9.isInteger(w0.type)?w9.isString(w0.host)?null:"host: string expected":"type: integer expected":"targetId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.AuthCodeRequest)return w0;var w1=new w10.AuthCodeRequest;return null!=w0.targetId&&(w1.targetId=String(w0.targetId)),null!=w0.type&&(w1.type=0|w0.type),null!=w0.host&&(w1.host=String(w0.host)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w2.targetId="",w2.type=0,w2.host=""),null!=w0.targetId&&w0.hasOwnProperty("targetId")&&(w2.targetId=w0.targetId),null!=w0.type&&w0.hasOwnProperty("type")&&(w2.type=w0.type),null!=w0.host&&w0.hasOwnProperty("host")&&(w2.host=w0.host),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.ApplicationConfigRequest=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.appId=w0.string();break;case 2:w3.appType=w0.int32();break;case 3:w3.timestamp=w0.int64();break;case 4:w3.nonce=w0.string();break;case 5:w3.signature=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("appId"))throw w9.ProtocolError("missing required 'appId'",{instance:w3});if(!w3.hasOwnProperty("appType"))throw w9.ProtocolError("missing required 'appType'",{instance:w3});if(!w3.hasOwnProperty("timestamp"))throw w9.ProtocolError("missing required 'timestamp'",{instance:w3});if(!w3.hasOwnProperty("nonce"))throw w9.ProtocolError("missing required 'nonce'",{instance:w3});if(!w3.hasOwnProperty("signature"))throw w9.ProtocolError("missing required 'signature'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w9.isString(w0.appId)?w9.isInteger(w0.appType)?w9.isInteger(w0.timestamp)||w0.timestamp&&w9.isInteger(w0.timestamp.low)&&w9.isInteger(w0.timestamp.high)?w9.isString(w0.nonce)?w9.isString(w0.signature)?null:"signature: string expected":"nonce: string expected":"timestamp: integer|Long expected":"appType: integer expected":"appId: string expected"},w0.fromObject=function(w0){if(w0 instanceof w10.ApplicationConfigRequest)return w0;var w1=new w10.ApplicationConfigRequest;return null!=w0.appId&&(w1.appId=String(w0.appId)),null!=w0.appType&&(w1.appType=0|w0.appType),null!=w0.timestamp&&(w9.Long?(w1.timestamp=w9.Long.fromValue(w0.timestamp)).unsigned=!1:"string"==typeof w0.timestamp?w1.timestamp=parseInt(w0.timestamp,10):"number"==typeof w0.timestamp?w1.timestamp=w0.timestamp:"object"===(0,w3.default)(w0.timestamp)&&(w1.timestamp=new w9.LongBits(w0.timestamp.low>>>0,w0.timestamp.high>>>0).toNumber())),null!=w0.nonce&&(w1.nonce=String(w0.nonce)),null!=w0.signature&&(w1.signature=String(w0.signature)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};if(w1.defaults){if(w2.appId="",w2.appType=0,w9.Long){var w3=new w9.Long(0,0,!1);w2.timestamp=w1.longs===String?w3.toString():w1.longs===Number?w3.toNumber():w3}else w2.timestamp=w1.longs===String?"0":0;w2.nonce="",w2.signature=""}return null!=w0.appId&&w0.hasOwnProperty("appId")&&(w2.appId=w0.appId),null!=w0.appType&&w0.hasOwnProperty("appType")&&(w2.appType=w0.appType),null!=w0.timestamp&&w0.hasOwnProperty("timestamp")&&("number"==typeof w0.timestamp?w2.timestamp=w1.longs===String?String(w0.timestamp):w0.timestamp:w2.timestamp=w1.longs===String?w9.Long.prototype.toString.call(w0.timestamp):w1.longs===Number?new w9.LongBits(w0.timestamp.low>>>0,w0.timestamp.high>>>0).toNumber():w0.timestamp),null!=w0.nonce&&w0.hasOwnProperty("nonce")&&(w2.nonce=w0.nonce),null!=w0.signature&&w0.hasOwnProperty("signature")&&(w2.signature=w0.signature),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w10.RouteRequestInternal=function(){function w0(w0){if(w0)for(var w1=(0,w4.default)(w0),w2=0;w2>>3){case 1:w3.data=w0.bytes();break;case 2:w3.appKey=w0.string();break;case 3:w3.appId=w0.string();break;default:w0.skipType(7&w4)}}if(!w3.hasOwnProperty("data"))throw w9.ProtocolError("missing required 'data'",{instance:w3});return w3},w0.decodeDelimited=function(w0){return w0 instanceof w7||(w0=new w7(w0)),this.decode(w0,w0.uint32())},w0.verify=function(w0){return"object"!==(void 0===w0?"undefined":(0,w3.default)(w0))||null===w0?"object expected":w0.data&&"number"==typeof w0.data.length||w9.isString(w0.data)?null!=w0.appKey&&w0.hasOwnProperty("appKey")&&!w9.isString(w0.appKey)?"appKey: string expected":null!=w0.appId&&w0.hasOwnProperty("appId")&&!w9.isString(w0.appId)?"appId: string expected":null:"data: buffer expected"},w0.fromObject=function(w0){if(w0 instanceof w10.RouteRequestInternal)return w0;var w1=new w10.RouteRequestInternal;return null!=w0.data&&("string"==typeof w0.data?w9.base64.decode(w0.data,w1.data=w9.newBuffer(w9.base64.length(w0.data)),0):w0.data.length&&(w1.data=w0.data)),null!=w0.appKey&&(w1.appKey=String(w0.appKey)),null!=w0.appId&&(w1.appId=String(w0.appId)),w1},w0.toObject=function(w0,w1){w1||(w1={});var w2={};return w1.defaults&&(w1.bytes===String?w2.data="":(w2.data=[],w1.bytes!==Array&&(w2.data=w9.newBuffer(w2.data))),w2.appKey="",w2.appId=""),null!=w0.data&&w0.hasOwnProperty("data")&&(w2.data=w1.bytes===String?w9.base64.encode(w0.data,0,w0.data.length):w1.bytes===Array?Array.prototype.slice.call(w0.data):w0.data),null!=w0.appKey&&w0.hasOwnProperty("appKey")&&(w2.appKey=w0.appKey),null!=w0.appId&&w0.hasOwnProperty("appId")&&(w2.appId=w0.appId),w2},w0.prototype.toJSON=function(){return this.constructor.toObject(this,w6.util.toJSONOptions)},w0}(),w0.exports=w10},function(w0,w1,w2){"use strict";Object.defineProperty(w1,"__esModule",{value:!0});var w3=w36(w2(80)),w4=w36(w2(81)),w5=w36(w2(120)),w6=w36(w2(121)),w7=w36(w2(107)),w8=w36(w2(122)),w9=w36(w2(55)),w10=w36(w2(123)),w11=w36(w2(82)),w12=w36(w2(162)),w13=w36(w2(165)),w14=w36(w2(173)),w15=w36(w2(166)),w16=w36(w2(174)),w17=w36(w2(169)),w18=w36(w2(170)),w19=w36(w2(379)),w20=w36(w2(172)),w21=w36(w2(161)),w22=w36(w2(175)),w23=w36(w2(160)),w24=w2(125),w25=w36(w2(380)),w26=w36(w2(163)),w27=w36(w2(168)),w28=w36(w2(92)),w29=w36(w2(381)),w30=w36(w2(171)),w31=w36(w2(164)),w32=w36(w2(167)),w33=w2(29),w34=w36(w2(382)),w35=w36(w2(383));function w36(w0){return w0&&w0.__esModule?w0:{default:w0}}var w37=function(){function w0(w1){(0,w9.default)(this,w0),this.users=new w8.default,this.groups=new w8.default,this.loadingUsers=new w7.default,this.loadingGroups=new w7.default,this.loadingGroupMembers=new w7.default,this.favGroups=[],this.favUsers=[],this.channels=new w8.default,this.groupMembers=new w8.default,this.friends=new w8.default,this.deliveries=new w8.default,this.readEntries=new w8.default,this.syncReadEntries=new w8.default,this.groupHeadEntries=new w8.default,this.friendRequests=[],this.messages=[],this.settings=[],this.conversationInfos=[],this.chatRoomMessageId=100,this.messageId=100,this.syncReadId=100,this.impl=null,this.impl=w1}return(0,w10.default)(w0,[{key:"genConversationKey",value:function(w0){return w0.type+"@"+w0.target+"@"+w0.line}},{key:"getUser",value:function(w0){var w1=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",w2=this._get(this.users,"u",w0,w30.default);if(w2){var w3=this.getFriendAlias(w0);if(w3&&""!==w3&&(w2.friendAlias=w3),w1.length>0){var w4=this.getGroupMember(w1,w0);w4&&w4.alias&&""!==w4.alias&&(w2.groupAlias=w4.alias)}}else w2=new w18.default(w0);return w2}},{key:"setUser",value:function(w0){this._set(this.users,"u",w0.uid,w0)}},{key:"getChannelInfo",value:function(w0){var w1=this._get(this.channels,"c",w0,w31.default);return w1||(w1=new w22.default(w0)),w1}},{key:"setChannelInfo",value:function(w0){w0 instanceof w22.default||this._set(this.channels,"c",w0.channelId,w0)}},{key:"getGroupInfo",value:function(w0){var w1=this._get(this.groups,"g",w0,w32.default);if(w1){var w2=this.getUserSetting(w20.default.GroupRemark,w0);w1.remark=w2?w2.value:void 0}else w1=new w17.default(w0);return w1}},{key:"setGroupInfo",value:function(w0){this._set(this.groups,"g",w0.target,w0)}},{key:"getGroupMembers",value:function(w0){var w1=this.groupMembers.get(w0);return w1=(w1=w1||[]).filter((function(w0){return w0.type!==w27.default.Removed}))}},{key:"getGroupMemberIds",value:function(w0){var w1=arguments.length>1&&void 0!==arguments[1]&&arguments[1],w2=this.getGroupMembers(w0,w1),w3=[];return w2.forEach((function(w0){w0.type!==w27.default.Removed&&w3.push(w0.memberId)})),w3}},{key:"getGroupMemberMaxDt",value:function(w0){var w1=w11.default.ZERO,w2=this.groupMembers.get(w0);return(w2=w2||[]).forEach((function(w0){w1=(0,w24.gt)(w0.updateDt,w1)?w0.updateDt:w1})),w1}},{key:"setGroupMembers",value:function(w0,w1){this.groupMembers.set(w0,w1)}},{key:"removeGroupAndMembers",value:function(w0){this._delete(this.groups,"g",w0),this.groupMembers.delete(w0)}},{key:"removeGroupMembers",value:function(w0,w1){var w2=this.groupMembers.get(w0);w2&&(w2=w2.filter((function(w0){return-1===w1.indexOf(w0.memberId)})),this.groupMembers.set(w0,w2))}},{key:"removeGroupSettings",value:function(w0){var w1=this;[w20.default.GroupHideNickname,w20.default.FavoriteGroup,w20.default.GroupRemark].forEach((function(w2){w1.removeUserSetting(w2,w0)}))}},{key:"updateGroupMembers",value:function(w0,w1){var w2=this.groupMembers.get(w0);if(w2)for(var w3=0;w30)&&this.friends.set(w0.uid,(0,w5.default)(new w16.default,w0))}},{key:"addFavGroup",value:function(w0){this.favGroups.indexOf(w0)>=0||this.favGroups.push(w0)}},{key:"removeFavGroup",value:function(w0){this.favGroups=this.favGroups.filter((function(w1){return w1.target!==w0}))}},{key:"getFavGroups",value:function(){return this.favGroups}},{key:"isFavGroup",value:function(w0){return this.favGroups.indexOf(w0)>=0}},{key:"getFavUsers",value:function(){return this.favUsers}},{key:"isFavUser",value:function(w0){return this.favUsers.indexOf(w0)>=0}},{key:"getFavGroupInfos",value:function(){var w0=this,w1=[];return this.favGroups.map((function(w2){var w3=w0._get(w0.groups,"g",w2,w32.default);w1.push(w3)})),w1}},{key:"getFriendAlias",value:function(w0){var w1=this.friends.get(w0),w2=w1?w1.alias:"";return w2.length>0?w2:null}},{key:"getFriendExtra",value:function(w0){var w1=this.friends.get(w0),w2=w1?w1.extra:"";return w2.length>0?w2:null}},{key:"getFriendUserInfos",value:function(){var w0=this,w1=[];return this.friends.forEach((function(w2,w3){if(0===w2.state){var w4=w0.getUser(w3);w1.push(w4)}})),w1}},{key:"getConversationInfo",value:function(w0){var w1=this.conversationInfos.filter((function(w1){return w1.conversation.equal(w0)}));return w1&&w1.length>0?w1[0]:null}},{key:"clearConversationUnreadStatus",value:function(w0){var w1=this.getConversationInfo(w0),w2=0;return w1&&(w2=w1.unreadCount.unread+w1.unreadCount.unreadMention+w1.unreadCount.unreadMentionAll,this.updateConversationUnreadStatus(w0,w1.timestamp)),w2}},{key:"clearMessageUnreadStatus",value:function(w0){for(var w1=!1,w2=0;w2-1){var w4=this.getConversationInfo(w3.conversation);if(w4){switch(w3.status){case w12.default.Unread:w4.unreadCount.unread-=1;break;case w12.default.Mentioned:w4.unreadCount.unreadMention-=1;break;case w12.default.AllMentioned:w4.unreadCount.unreadMentionAll-=1}w1=!0}w3.status=w12.default.Readed;break}}return w1}},{key:"updateConversationRead",value:function(w0,w1){var w2=this;this.messages.forEach((function(w3){w3.conversation.equal(w0)&&w3.status===w12.default.Sent&&(0,w24.lte)(w3.timestamp,w1)&&(w3.status=w12.default.Readed,w2.log("--------- mark conversation message read",w0,w1))}))}},{key:"getConversationReadMaxDt",value:function(w0){var w1=w11.default.ZERO;return this.messages.forEach((function(w2){w2.conversation.equal(w0)&&(w1=(0,w24.gt)(w2.timestamp,w1)?w2.timestamp:w1)})),w1}},{key:"getUnreadMsgSenders",value:function(w0){var w1=[];return this.messages.forEach((function(w2){w2.conversation.equal(w0)&&(w2.status!==w12.default.Unread&&w2.status!==w12.default.Mentioned&&w2.status!==w12.default.AllMentioned||-1===w1.indexOf(w2.from)&&w1.push(w2.from))})),w1}},{key:"clearAllUnreadStatus",value:function(){var w0=this,w1=0;return this.conversationInfos.forEach((function(w2){w1+=w2.unreadCount.unread+w2.unreadCount.unreadMention+w2.unreadCount.unreadMentionAll,w0.updateConversationUnreadStatus(w2.conversation,w2.timestamp)})),w1}},{key:"updateConversationUnreadStatus",value:function(w0,w1){var w2=this.getConversationMessages(w0),w3=this.getConversationInfo(w0);w3.unreadCount.unread=0,w3.unreadCount.unreadMention=0,w3.unreadCount.unreadMentionAll=0,(0,w24.gte)(w1,w3.timestamp)?w2.forEach((function(w0){(0,w24.gte)(w1,w0.timestamp)&&[w12.default.Unread,w12.default.AllMentioned,w12.default.Mentioned].indexOf(w0.status)>-1&&(w0.status=w12.default.Readed)})):w2.forEach((function(w0){0!==w0.direction&&((0,w24.gt)(w0.timestamp,w1)&&w23.default.getMessageContentPersitFlag(w0.content.type)===w26.default.Persist_And_Count?w0.status===w12.default.Unread?w3.unreadCount.unread+=1:w0.status===w12.default.Mentioned?w3.unreadCount.unreadMention+=1:w0.status===w12.default.AllMentioned&&(w3.unreadCount.unreadMentionAll+=1):[w12.default.Unread,w12.default.AllMentioned,w12.default.Mentioned].indexOf(w0.status)>-1&&(w0.status=w12.default.Readed))}))}},{key:"_getConversationInfos",value:function(){return this.conversationInfos}},{key:"getConversationList",value:function(w0,w1){return this.conversationInfos.filter((function(w2){if(-1===w0.indexOf(w2.conversation.type)||-1===w1.indexOf(w2.conversation.line))return!1;w2.conversation.target,w2.conversation.type;return!0})).sort((function(w0,w1){return w0.top&&!w1.top?1:!w0.top&&w1.top?-1:w0.top&&w1.top&&w0.top!==w1.top?w0.top>w1.top?1:-1:(0,w24.compare)(w0.timestamp,w1.timestamp)})).reverse()}},{key:"searchFriends",value:function(w0){return this.getFriendUserInfos().filter((function(w1){return w1.displayName.indexOf(w0)>=0}))}},{key:"searchConversation",value:function(w0){var w1=this,w2=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[0,1,2,3],w3=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[0,1];return this.conversationInfos.filter((function(w4){if(w2.indexOf(w4.conversation.type)<0||w3.indexOf(w4.conversation.line)<0)return!1;var w5=void 0,w6=void 0;switch(w4.conversation.type){case w15.default.Single:w5=w1.getUser(w4.conversation.target).displayName;break;case w15.default.Group:var w7=w1.getGroupInfo(w4.conversation.target);w5=w7.displayName,w6=w7.remark}if(w5&&w5.indexOf(w0)>-1||w6&&w6.indexOf(w0)>-1)return!0;var w8=w1.searchConversationMessage(w4.conversation,w0);return w8&&w8.length>0}))}},{key:"searchGroups",value:function(w0){var w1=this,w2=[];if(!w0||!w0.trim())return w2;var w3=this.groups;return w0=w0.toUpperCase(),w3.forEach((function(w3,w4){if(!(0,w24.lt)(w3.memberUpdateDt,0)){var w5=w1.getUserSetting(w20.default.GroupRemark,w4);w3.remark=w5?w5.value:"",(w3.name.toUpperCase().indexOf(w0)>-1||w3.remark&&w3.remark.toUpperCase().indexOf(w0)>-1)&&w2.push(w3)}})),w2.map((function(w0){var w1=new w34.default;return w1.groupInfo=w0,w1.matchType=0,w1}))}},{key:"loadPersistGroups",value:function(){if(!(this.groups.size>0))for(var w0=localStorage.length,w1=0;w11&&void 0!==arguments[1]&&arguments[1],w2=this._findConversationInfoIndex(w0);w2>-1&&this.conversationInfos.splice(w2,1),w1&&(this.messages=this.messages.filter((function(w1){return!w1.conversation.equal(w0)})))}},{key:"setConversationTop",value:function(w0,w1){var w2=this.getConversationInfo(w0);w2&&(w2.top=w1)}},{key:"setConversationSilent",value:function(w0,w1){var w2=this.getConversationInfo(w0);w2&&(w2.isSilent=w1)}},{key:"setConversationDraft",value:function(w0,w1){var w2=this.getConversationInfo(w0);w2&&(w2.draft=w1)}},{key:"getUnreadCount",value:function(w0,w1){var w2=new w19.default;return this.conversationInfos.forEach((function(w3){w0.indexOf(w3.conversation.type)>-1&&w1.indexOf(w3.conversation.line)>-1&&w3.unreadCount&&(w2.unread+=w3.unreadCount.unread,w2.unreadMention+=w3.unreadCount.unreadMention,w2.unreadMentionAll+=w3.unreadCount.unreadMentionAll)})),w2}},{key:"getConversationUnreadCount",value:function(w0){var w1=this._findConversationInfoIndex(w0);return w1>-1?this.conversationInfos[w1].unreadCount:null}},{key:"insertConversationMessages",value:function(w0){var w1;(w1=this.messages).push.apply(w1,(0,w4.default)(w0)),this.updateConversationLastMessage(w0[w0.length-1])}},{key:"updateConversationLastMessage",value:function(w0){if(!w0.messageId)return!1;var w1=this.conversationInfos.find((function(w1){return w1.conversation.equal(w0.conversation)})),w2=w0.conversation.conversationType+"-"+w0.conversation.line+"-"+w0.conversation.target;if(!w1){var w3=this.getUserSetting(w20.default.Conversation_Sync,w2);if(w3&&w3.value&&w3.value.startsWith("-")&&(0,w24.gte)(-Number(w3.value),w0.timestamp))return this.log("conversation removed, drop conversation message",w0),!1;w1=this.genAndSaveDefaultConversationInfo(w0.conversation)}var w4=this.getUserSetting(w20.default.Conversation_Sync,w2),w5=0;return w4&&(w5=Math.abs(Number(w4.value))),(0,w24.gt)(w0.timestamp,w5)&&1===w0.direction&&w23.default.getMessageContentFlag(w0.messageContent.type)===w26.default.Persist_And_Count&&(w0.status===w12.default.Unread?w1.unreadCount.unread+=1:w0.status===w12.default.Mentioned?w1.unreadCount.unreadMention+=1:w0.status===w12.default.AllMentioned&&(w1.unreadCount.unreadMentionAll+=1)),!!(0,w24.gt)(w0.timestamp,w1.timestamp)&&(w1.lastMessage=w0,w1.timestamp=w0.timestamp,!0)}},{key:"getConversationOldestMessage",value:function(w0){var w1=void 0;return this.messages.forEach((function(w2){w2.conversation.equal(w0)&&(w1?(0,w24.gt)(w1.timestamp,w2.timestamp)&&(w1=w2):w1=w2)})),w1}},{key:"getConversationMessages",value:function(w0){var w1=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,w2=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],w3=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,w4=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"",w5=null;w1&&(w5=this.getMessageById(w1));var w6=this.messages.filter((function(w1){return w5?w2?w1.conversation.equal(w0)&&(0,w24.lt)(w1.timestamp,w5.timestamp)&&(!w4||(0===w1.direction&&(w1.to===w4||""===w1.to)||w1.from===w4)):w1.conversation.equal(w0)&&(0,w24.gt)(w1.timestamp,w5.timestamp)&&(!w4||(0===w1.direction&&(w1.to===w4||""===w1.to)||w1.from===w4)):w1.conversation.equal(w0)}));return w6&&w6.length>0&&(w6=w6.sort((function(w0,w1){return(0,w24.compare)(w0.timestamp,w1.timestamp)}))),w3>0&&(w6=w2?w6.slice(-w3):w6.slice(0,w3)),w6}},{key:"getConversationLastReceivedMessage",value:function(w0){var w1=this.messages.filter((function(w1){return w1.conversation.equal(w0)&&1===w1.direction}));return w1&&w1.length>0?(w1=w1.sort((function(w0,w1){return(0,w24.compare)(w0.timestamp,w1.timestamp)})))[w1.length-1]:null}},{key:"setLastReceivedMessageUnread",value:function(w0,w1,w2){console.log("setLastReceivedMessageUnread",w0,w1);var w3=this.getConversationLastReceivedMessage(w0);return w3&&w3.status>w12.default.Unread?(w3.status=w12.default.Unread,(0,w24.eq)(w2,0)?w3.timestamp=w3.timestamp.add(501):w3.timestamp=w11.default.fromValue(w2),this.getConversationInfo(w0).unreadCount.unread=1,w3.messageUid):0}},{key:"getMessagesEx2",value:function(w0,w1,w2,w3){var w4=this.messages.filter((function(w4){var w5=w4.conversation;return!(!(w0.indexOf(w5.conversationType)>=0&&w1.indexOf(w5.line)>=0)||w2!==w12.default.All&&w4.status!==w2)&&(!w3||(w5.conversationType===w15.default.Single?w4.from===w3||w5.target===w3:w4.from===w3||w4.to===w3))}));return w4&&w4.length>0?w4.sort((function(w0,w1){return(0,w24.compare)(w0.timestamp,w1.timestamp)})):w4}},{key:"getMessagesEx",value:function(w0,w1,w2,w3){var w4=this.messages.filter((function(w4){var w5=w4.conversation;return!!(w0.indexOf(w5.conversationType)>=0&&w1.indexOf(w5.line)>=0&&(0===w2.length||w2.length>0&&w2.indexOf(w23.default.getMessageContentType(w4.messageContent))>=0))&&(!w3||(w5.conversationType===w15.default.Single?w4.from===w3||w5.target===w3:w4.from===w3||w4.to===w3))}));return w4&&w4.length>0?w4.sort((function(w0,w1){return(0,w24.compare)(w0.timestamp,w1.timestamp)})):w4}},{key:"getFirstUnreadMessage",value:function(w0){var w1=null;return this.messages.forEach((function(w2){w2.conversation.equal(w0)&&[w12.default.Unread,w12.default.Mentioned,w12.default.AllMentioned].indexOf(w2.status)>-1&&(w1?(0,w24.gt)(w1.timestamp,w2.timestamp)&&(w1=w2):w1=w2)})),w1}},{key:"clearConversationMessages",value:function(w0,w1){this.messages=this.messages.filter((function(w2){return!w2.conversation.equal(w0)||(0,w24.gt)(w2.timestamp,w1)}));var w2=this.getConversationInfo(w0);w2&&w2.lastMessage&&w2.lastMessage.timestamp&&(0,w24.lte)(w2.lastMessage.timestamp,w1)&&(w2.lastMessage=null)}},{key:"clearConversationMessagesBeforeMessageUid",value:function(w0,w1){this.messages=this.messages.filter((function(w2){return!w2.conversation.equal(w0)||(0,w24.gte)(w2.messageUid,w1)}));var w2=this.getConversationInfo(w0);w2&&w2.lastMessage&&w2.lastMessage.messageUid&&(0,w24.lte)(w2.lastMessage.messageUid,w1)&&(w2.lastMessage=null)}},{key:"searchMessage",value:function(w0){return this.messages.filter((function(w1){return w1.content&&w1.content.searchableContent&&w1.content.searchableContent.indexOf(w0)>-1}))}},{key:"searchConversationMessage",value:function(w0,w1,w2){return this.getConversationMessages(w0).filter((function(w0){return(!w2||w0.from===w2)&&(w0.content&&w0.content.searchableContent&&w0.content.searchableContent.indexOf(w1)>-1)}))}},{key:"genChatRoomMessageId",value:function(){return this.chatRoomMessageId++,0-this.chatRoomMessageId}},{key:"genNormalMessageId",value:function(){return this.messageId++}},{key:"saveMessage",value:function(w0){var w1=void 0;if(w0.messageUid&&-1!==w0.messageUid&&(w1=this.getMessageByUid(w0.messageUid)))return w0.messageId=w1.messageId,w1.messageContent=w0.messageContent,w1.timestamp=w0.timestamp,this.log("messageUid exist",w0),!1;var w2=this.getUserSetting(w20.default.Conversation_Sync,w0.conversation.conversationType+"-"+w0.conversation.line+"-"+w0.conversation.target),w3=0;return w2&&(w3=Number(w2.value)),1===w0.direction&&(0,w24.gte)(w3,w0.timestamp)&&(w0.status=w12.default.Readed),this.messages.push(w0),!0}},{key:"updateMessageById",value:function(w0){if(w0.messageId){for(var w1=-1,w2=0;w20?w2.lastMessage=w5[w5.length-1]:w2.lastMessage=null}}}},{key:"deleteFriend",value:function(w0){this.friends.delete(w0)}},{key:"getMessageById",value:function(w0){var w1=this.messages.filter((function(w1){return w1.messageId===w0}));return w1.length>0?w1[0]:null}},{key:"getCallStartMessage",value:function(w0){var w1=this.messages.filter((function(w1){return 400===w1.messageContent.type&&w1.messageContent.callId===w0}));return w1.length>0?w1[0]:null}},{key:"getMessageByUid",value:function(w0){var w1=w11.default.fromValue(w0),w2=this.messages.filter((function(w0){return 0===w1.compare(w0.messageUid)}));return w2&&w2.length>0?w2[0]:null}},{key:"setMediaMessagePlayed",value:function(w0){var w1=!1,w2=this.getMessageById(w0);return w2.messageContent instanceof w21.default&&1===w2.direction&&(w2.status=w12.default.Played,w1=!0),w1}},{key:"updateUserSettings",value:function(w0){var w1=this;w0.sort((function(w0,w1){return(0,w24.compare)(w0.updateDt,w1.updateDt)})),w0.forEach((function(w0){if(w0.updateDt){for(var w2=-1,w3=0;w3=0?""===w0.value?w1.settings.splice(w2,1):w1.settings[w2]=w0:""!==w0.value&&w1.settings.push(w0),w0.scope===w20.default.ConversationSilent||w0.scope===w20.default.ConversationTop||w0.scope===w20.default.Conversation_Sync||w0.scope===w20.default.UserSettingConversationReaded||w0.scope===w20.default.ConversationClearMessage||w0.scope===w20.default.ConversationDraft){var w5=w0.key,w6=w5.indexOf("-"),w7=w5.indexOf("-",w6+1),w8=parseInt(w5.substring(0,w6)),w9=parseInt(w5.substring(w6+1,w7)),w10=w5.substring(w7+1),w11=new w13.default(w8,w10,w9),w12=w1.getConversationInfo(w11);if(!w12){var w14=Number(w0.value);if((w14=w14%1e3<500?w14:w14+(1e3-w14%1e3))<0||w14>0&&(new Date).getTime()-w14>=24*(w28.default.CONVERSATION_EXPIRE_TIME?w28.default.CONVERSATION_EXPIRE_TIME:30)*60*60*1e3)return;if(w0.scope===w20.default.ConversationSilent&&"1"===w0.value||w28.default.DISABLE_GENERATE_CONVERSATION_FOR_SILENT_SETTING)return;(w12=w1.genAndSaveDefaultConversationInfo(w11)).timestamp=w0.updateDt}if(w0.scope===w20.default.ConversationSilent)w12.isSilent="1"===w0.value;else if(w0.scope===w20.default.ConversationTop)w12.top=Number(w0.value);else if(w0.scope===w20.default.Conversation_Sync){var w15=Number(w0.value);w15<0?(0,w24.lte)(w12.timestamp,-w15)&&w1.removeConversation(w11,!0):w1.updateConversationUnreadStatus(w11,w15)}else if(w0.scope===w20.default.UserSettingConversationReaded)w1.updateConversationRead(w11,Number(w0.value));else if(w0.scope===w20.default.ConversationClearMessage){var w16=Number(w0.value);w12&&w16>0&&w1.impl.clearMessages(w11,w16)}else if(w0.scope===w20.default.ConversationDraft){var w17=w0.value.indexOf("@@@");if(w17>0){var w18=w0.value.substring(0,w17);if(!w18||w18===w1.impl.clientId||w1.impl.isGlobalDisableDraftSync||w1.impl.isDisableSyncDraft())return;var w19=w0.value.substring(w17+3).trim();w12&&w12.draft!==w19&&w1.impl.setConversationDraft(w11,w19,!1)}}}else if(w0.scope===w20.default.FavoriteGroup){var w21=w1.favGroups.indexOf(w0.key);"1"===w0.value?w21<0&&w1.favGroups.push(w0.key):w21>=0&&w1.favGroups.splice(w21,1)}else if(w0.scope===w20.default.FavoriteUser){var w22=w1.favUsers.indexOf(w0.key);"1"===w0.value?w22<0&&w1.favUsers.push(w0.key):w22>=0&&w1.favUsers.splice(w22,1)}}else console.log("invalid setting",w0)}))}},{key:"genAndSaveDefaultConversationInfo",value:function(w0){var w1=this._findConversationInfoIndex(w0);if(-1!==w1)return this.conversationInfos[w1];var w2=new w14.default;w2.conversation=w0,w2.timestamp=w11.default.ZERO,w2.unreadCount=new w19.default;var w3=w0.conversationType+"-"+w0.line+"-"+w0.target,w4=this.getUserSetting(w20.default.ConversationSilent,w3);w4&&"1"===w4.value&&(w2.isSilent=!0);var w5=this.getUserSetting(w20.default.ConversationTop,w3);return w5&&w5.value&&(w2.top=Number(w5.value)),this.conversationInfos.push(w2),w2}},{key:"updateDeliveries",value:function(w0){var w1=this;w0.forEach((function(w0){w1.deliveries.set(w0.fromUser,w0.receiveTime)}))}},{key:"getUserDelivery",value:function(w0){return this.deliveries.get(w0)}},{key:"getConversationDelivery",value:function(w0){var w1=new w8.default;if(0===w0.type){var w2=this.getUserDelivery(w0.target);w2&&w1.set(w0.target,w2)}else if(1===w0.type){var w3=this.getGroupMemberIds(w0.target);this.deliveries.forEach((function(w0,w2){w3.indexOf(w2)>=0&&w1.set(w2,w0)}))}return w1}},{key:"updateReads",value:function(w0){var w1=this;w0.forEach((function(w0){0===w0.conversation.type&&(w0.conversation.target=w0.fromUser);var w2=w1.genConversationKey(w0.conversation),w3=w1.readEntries.get(w2);w3||(w3=new w8.default,w1.readEntries.set(w2,w3)),w3.set(w0.fromUser,w0.readTime)}))}},{key:"saveSyncReadEntry",value:function(w0,w1,w2,w3,w4){var w5=this.syncReadId++,w6=new w25.default;return w6.id=w5,w6.type=w0,w6.target=w1,w6.line=w2,w6.senders=w4,this.syncReadEntries.set(w5,w6),w5}},{key:"deleteSyncReadEntry",value:function(w0){this.syncReadEntries.delete(w0)}},{key:"getSyncReadEntries",value:function(){return this.syncReadEntries}},{key:"loadSyncReadEntry",value:function(){return this.syncReadEntries.values().next().value}},{key:"_genSyncReadEntryKey",value:function(w0){return w0.type+"@"+w0.target+"@"+w0.line}},{key:"getConversationRead",value:function(w0){var w1=this._genSyncReadEntryKey(w0);return this.readEntries.get(w1)}},{key:"getUserSetting",value:function(w0,w1){var w2=this.settings.filter((function(w2){return w2.scope===w0&&w2.key===w1}));return w2.length>0?w2[w2.length-1]:null}},{key:"getUserSettings",value:function(w0){return this.settings.filter((function(w1){return w1.scope===w0}))}},{key:"removeUserSetting",value:function(w0,w1){this.settings=this.settings.filter((function(w2){return!(w2.scope===w0&&w2.key===w1)}))}},{key:"getFriendRequestMaxDt",value:function(){var w0=w11.default.ZERO;return this.friendRequests.forEach((function(w1){w0=(0,w24.gt)(w1.timestamp,w0)?w1.timestamp:w0})),w0}},{key:"insertOrReplaceFriendRequest",value:function(w0){for(var w1=-1,w2=0;w2=0?this.friendRequests[w1]=w0:this.friendRequests.push(w0)}},{key:"getIncommingFriendRequest",value:function(){return this.friendRequests.filter((function(w0){return 1===w0.direction}))}},{key:"getOutgoingFriendRequest",value:function(){return this.friendRequests.filter((function(w0){return 0===w0.direction}))}},{key:"getOneFriendRequest",value:function(w0,w1){var w2=this.friendRequests.filter((function(w2){return w2.target===w0&&w2.direction===(w1?1:0)}));return w2.length>0?w2[0]:null}},{key:"getUnreadFriendRequestCount",value:function(){var w0=0;return this.friendRequests.forEach((function(w1){1===w1.direction&&0===w1.readStatus&&w0++})),w0}},{key:"clearUnreadFriendRequestStatus",value:function(){var w0=0;return this.friendRequests.forEach((function(w1){1===w1.direction&&0===w1.readStatus&&(w1.readStatus=1,w0++)})),w0}},{key:"updateFriendRequestStatus",value:function(w0,w1){this.friendRequests.forEach((function(w2){w2.target===w0&&1===w2.direction&&(w2.status=w1)}))}},{key:"getUnreadFriendRequestMaxDt",value:function(){var w0=w11.default.ZERO;return this.friendRequests.forEach((function(w1){1===w1.direction&&0===w1.readStatus&&(w0=(0,w24.gt)(w1.timestamp,w0)?w1.timestamp:w0)})),w0}},{key:"getGroupMessageHead",value:function(w0,w1){var w2=this.groupHeadEntries.get(w0+"-"+w1);return w2?w2.head:w11.default.ZERO}},{key:"setGroupMessageHead",value:function(w0,w1,w2){var w3=w0+"-"+w1,w4=this.groupHeadEntries.get(w3);w4||(w4=new w35.default,this.groupHeadEntries.set(w3,w4)),w4.target=w0,w4.line=w1,w4.head=w2}},{key:"setGroupMessageServerHead",value:function(w0,w1,w2){var w3=w0+"-"+w1,w4=this.groupHeadEntries.get(w3);w4||(w4=new w35.default,this.groupHeadEntries.set(w3,w4)),w4.target=w0,w4.line=w1,w4.serverHead=w2}},{key:"getGroupMessageHeads",value:function(){var w0=[];return this.groupHeadEntries.forEach((function(w1,w2){(0,w24.gt)(w1.serverHead,w1.head)&&w0.push(w1)})),w0}},{key:"log",value:function(w0){if(!w28.default.DISABLE_LOG){for(var w1,w2=arguments.length,w3=Array(w2>1?w2-1:0),w4=1;w40?w1.windowBits=-w1.windowBits:w1.gzip&&w1.windowBits>0&&w1.windowBits<16&&(w1.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new w7,this.strm.avail_out=0;var w2=w3.deflateInit2(this.strm,w1.level,w1.method,w1.windowBits,w1.memLevel,w1.strategy);if(0!==w2)throw new Error(w6[w2]);if(w1.header&&w3.deflateSetHeader(this.strm,w1.header),w1.dictionary){var w10;if(w10="string"==typeof w1.dictionary?w5.string2buf(w1.dictionary):"[object ArrayBuffer]"===w8.call(w1.dictionary)?new Uint8Array(w1.dictionary):w1.dictionary,0!==(w2=w3.deflateSetDictionary(this.strm,w10)))throw new Error(w6[w2]);this._dict_set=!0}}function w10(w0,w1){var w2=new w9(w1);if(w2.push(w0,!0),w2.err)throw w2.msg||w6[w2.err];return w2.result}w9.prototype.push=function(w0,w1){var w2,w6,w7=this.strm,w9=this.options.chunkSize;if(this.ended)return!1;w6=w1===~~w1?w1:!0===w1?4:0,"string"==typeof w0?w7.input=w5.string2buf(w0):"[object ArrayBuffer]"===w8.call(w0)?w7.input=new Uint8Array(w0):w7.input=w0,w7.next_in=0,w7.avail_in=w7.input.length;do{if(0===w7.avail_out&&(w7.output=new w4.Buf8(w9),w7.next_out=0,w7.avail_out=w9),1!==(w2=w3.deflate(w7,w6))&&0!==w2)return this.onEnd(w2),this.ended=!0,!1;0!==w7.avail_out&&(0!==w7.avail_in||4!==w6&&2!==w6)||("string"===this.options.to?this.onData(w5.buf2binstring(w4.shrinkBuf(w7.output,w7.next_out))):this.onData(w4.shrinkBuf(w7.output,w7.next_out)))}while((w7.avail_in>0||0===w7.avail_out)&&1!==w2);return 4===w6?(w2=w3.deflateEnd(this.strm),this.onEnd(w2),this.ended=!0,0===w2):2!==w6||(this.onEnd(0),w7.avail_out=0,!0)},w9.prototype.onData=function(w0){this.chunks.push(w0)},w9.prototype.onEnd=function(w0){0===w0&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=w4.flattenChunks(this.chunks)),this.chunks=[],this.err=w0,this.msg=this.strm.msg},w1.Deflate=w9,w1.deflate=w10,w1.deflateRaw=function(w0,w1){return(w1=w1||{}).raw=!0,w10(w0,w1)},w1.gzip=function(w0,w1){return(w1=w1||{}).gzip=!0,w10(w0,w1)}},function(w0,w1,w2){"use strict";var w3,w4=w2(20),w5=w2(389),w6=w2(176),w7=w2(177),w8=w2(96),w9=-2,w10=258,w11=262,w12=103,w13=113,w14=666;function w15(w0,w1){return w0.msg=w8[w1],w1}function w16(w0){return(w0<<1)-(w0>4?9:0)}function w17(w0){for(var w1=w0.length;--w1>=0;)w0[w1]=0}function w18(w0){var w1=w0.state,w2=w1.pending;w2>w0.avail_out&&(w2=w0.avail_out),0!==w2&&(w4.arraySet(w0.output,w1.pending_buf,w1.pending_out,w2,w0.next_out),w0.next_out+=w2,w1.pending_out+=w2,w0.total_out+=w2,w0.avail_out-=w2,w1.pending-=w2,0===w1.pending&&(w1.pending_out=0))}function w19(w0,w1){w5._tr_flush_block(w0,w0.block_start>=0?w0.block_start:-1,w0.strstart-w0.block_start,w1),w0.block_start=w0.strstart,w18(w0.strm)}function w20(w0,w1){w0.pending_buf[w0.pending++]=w1}function w21(w0,w1){w0.pending_buf[w0.pending++]=w1>>>8&255,w0.pending_buf[w0.pending++]=255&w1}function w22(w0,w1){var w2,w3,w4=w0.max_chain_length,w5=w0.strstart,w6=w0.prev_length,w7=w0.nice_match,w8=w0.strstart>w0.w_size-w11?w0.strstart-(w0.w_size-w11):0,w9=w0.window,w12=w0.w_mask,w13=w0.prev,w14=w0.strstart+w10,w15=w9[w5+w6-1],w16=w9[w5+w6];w0.prev_length>=w0.good_match&&(w4>>=2),w7>w0.lookahead&&(w7=w0.lookahead);do{if(w9[(w2=w1)+w6]===w16&&w9[w2+w6-1]===w15&&w9[w2]===w9[w5]&&w9[++w2]===w9[w5+1]){w5+=2,w2++;do{}while(w9[++w5]===w9[++w2]&&w9[++w5]===w9[++w2]&&w9[++w5]===w9[++w2]&&w9[++w5]===w9[++w2]&&w9[++w5]===w9[++w2]&&w9[++w5]===w9[++w2]&&w9[++w5]===w9[++w2]&&w9[++w5]===w9[++w2]&&w5w6){if(w0.match_start=w1,w6=w3,w3>=w7)break;w15=w9[w5+w6-1],w16=w9[w5+w6]}}}while((w1=w13[w1&w12])>w8&&0!=--w4);return w6<=w0.lookahead?w6:w0.lookahead}function w23(w0){var w1,w2,w3,w5,w8,w9,w10,w12,w13,w14,w15=w0.w_size;do{if(w5=w0.window_size-w0.lookahead-w0.strstart,w0.strstart>=w15+(w15-w11)){w4.arraySet(w0.window,w0.window,w15,w15,0),w0.match_start-=w15,w0.strstart-=w15,w0.block_start-=w15,w1=w2=w0.hash_size;do{w3=w0.head[--w1],w0.head[w1]=w3>=w15?w3-w15:0}while(--w2);w1=w2=w15;do{w3=w0.prev[--w1],w0.prev[w1]=w3>=w15?w3-w15:0}while(--w2);w5+=w15}if(0===w0.strm.avail_in)break;if(w9=w0.strm,w10=w0.window,w12=w0.strstart+w0.lookahead,w13=w5,w14=void 0,(w14=w9.avail_in)>w13&&(w14=w13),w2=0===w14?0:(w9.avail_in-=w14,w4.arraySet(w10,w9.input,w9.next_in,w14,w12),1===w9.state.wrap?w9.adler=w6(w9.adler,w10,w14,w12):2===w9.state.wrap&&(w9.adler=w7(w9.adler,w10,w14,w12)),w9.next_in+=w14,w9.total_in+=w14,w14),w0.lookahead+=w2,w0.lookahead+w0.insert>=3)for(w8=w0.strstart-w0.insert,w0.ins_h=w0.window[w8],w0.ins_h=(w0.ins_h<=3&&(w0.ins_h=(w0.ins_h<=3)if(w3=w5._tr_tally(w0,w0.strstart-w0.match_start,w0.match_length-3),w0.lookahead-=w0.match_length,w0.match_length<=w0.max_lazy_match&&w0.lookahead>=3){w0.match_length--;do{w0.strstart++,w0.ins_h=(w0.ins_h<=3&&(w0.ins_h=(w0.ins_h<4096)&&(w0.match_length=2)),w0.prev_length>=3&&w0.match_length<=w0.prev_length){w4=w0.strstart+w0.lookahead-3,w3=w5._tr_tally(w0,w0.strstart-1-w0.prev_match,w0.prev_length-3),w0.lookahead-=w0.prev_length-1,w0.prev_length-=2;do{++w0.strstart<=w4&&(w0.ins_h=(w0.ins_h<15&&(w7=2,w3-=16),w5<1||w5>9||8!==w2||w3<8||w3>15||w1<0||w1>9||w6<0||w6>4)return w15(w0,w9);8===w3&&(w3=9);var w8=new w27;return w0.state=w8,w8.strm=w0,w8.wrap=w7,w8.gzhead=null,w8.w_bits=w3,w8.w_size=1<w0.pending_buf_size-5&&(w2=w0.pending_buf_size-5);;){if(w0.lookahead<=1){if(w23(w0),0===w0.lookahead&&0===w1)return 1;if(0===w0.lookahead)break}w0.strstart+=w0.lookahead,w0.lookahead=0;var w3=w0.block_start+w2;if((0===w0.strstart||w0.strstart>=w3)&&(w0.lookahead=w0.strstart-w3,w0.strstart=w3,w19(w0,!1),0===w0.strm.avail_out))return 1;if(w0.strstart-w0.block_start>=w0.w_size-w11&&(w19(w0,!1),0===w0.strm.avail_out))return 1}return w0.insert=0,4===w1?(w19(w0,!0),0===w0.strm.avail_out?3:4):(w0.strstart>w0.block_start&&(w19(w0,!1),w0.strm.avail_out),1)})),new w26(4,4,8,4,w24),new w26(4,5,16,8,w24),new w26(4,6,32,32,w24),new w26(4,4,16,16,w25),new w26(8,16,32,32,w25),new w26(8,16,128,128,w25),new w26(8,32,128,256,w25),new w26(32,128,258,1024,w25),new w26(32,258,258,4096,w25)],w1.deflateInit=function(w0,w1){return w30(w0,w1,8,15,8,0)},w1.deflateInit2=w30,w1.deflateReset=w29,w1.deflateResetKeep=w28,w1.deflateSetHeader=function(w0,w1){return w0&&w0.state?2!==w0.state.wrap?w9:(w0.state.gzhead=w1,0):w9},w1.deflate=function(w0,w1){var w2,w4,w6,w8;if(!w0||!w0.state||w1>5||w1<0)return w0?w15(w0,w9):w9;if(w4=w0.state,!w0.output||!w0.input&&0!==w0.avail_in||w4.status===w14&&4!==w1)return w15(w0,0===w0.avail_out?-5:w9);if(w4.strm=w0,w2=w4.last_flush,w4.last_flush=w1,42===w4.status)if(2===w4.wrap)w0.adler=0,w20(w4,31),w20(w4,139),w20(w4,8),w4.gzhead?(w20(w4,(w4.gzhead.text?1:0)+(w4.gzhead.hcrc?2:0)+(w4.gzhead.extra?4:0)+(w4.gzhead.name?8:0)+(w4.gzhead.comment?16:0)),w20(w4,255&w4.gzhead.time),w20(w4,w4.gzhead.time>>8&255),w20(w4,w4.gzhead.time>>16&255),w20(w4,w4.gzhead.time>>24&255),w20(w4,9===w4.level?2:w4.strategy>=2||w4.level<2?4:0),w20(w4,255&w4.gzhead.os),w4.gzhead.extra&&w4.gzhead.extra.length&&(w20(w4,255&w4.gzhead.extra.length),w20(w4,w4.gzhead.extra.length>>8&255)),w4.gzhead.hcrc&&(w0.adler=w7(w0.adler,w4.pending_buf,w4.pending,0)),w4.gzindex=0,w4.status=69):(w20(w4,0),w20(w4,0),w20(w4,0),w20(w4,0),w20(w4,0),w20(w4,9===w4.level?2:w4.strategy>=2||w4.level<2?4:0),w20(w4,3),w4.status=w13);else{var w11=8+(w4.w_bits-8<<4)<<8;w11|=(w4.strategy>=2||w4.level<2?0:w4.level<6?1:6===w4.level?2:3)<<6,0!==w4.strstart&&(w11|=32),w11+=31-w11%31,w4.status=w13,w21(w4,w11),0!==w4.strstart&&(w21(w4,w0.adler>>>16),w21(w4,65535&w0.adler)),w0.adler=1}if(69===w4.status)if(w4.gzhead.extra){for(w6=w4.pending;w4.gzindex<(65535&w4.gzhead.extra.length)&&(w4.pending!==w4.pending_buf_size||(w4.gzhead.hcrc&&w4.pending>w6&&(w0.adler=w7(w0.adler,w4.pending_buf,w4.pending-w6,w6)),w18(w0),w6=w4.pending,w4.pending!==w4.pending_buf_size));)w20(w4,255&w4.gzhead.extra[w4.gzindex]),w4.gzindex++;w4.gzhead.hcrc&&w4.pending>w6&&(w0.adler=w7(w0.adler,w4.pending_buf,w4.pending-w6,w6)),w4.gzindex===w4.gzhead.extra.length&&(w4.gzindex=0,w4.status=73)}else w4.status=73;if(73===w4.status)if(w4.gzhead.name){w6=w4.pending;do{if(w4.pending===w4.pending_buf_size&&(w4.gzhead.hcrc&&w4.pending>w6&&(w0.adler=w7(w0.adler,w4.pending_buf,w4.pending-w6,w6)),w18(w0),w6=w4.pending,w4.pending===w4.pending_buf_size)){w8=1;break}w8=w4.gzindexw6&&(w0.adler=w7(w0.adler,w4.pending_buf,w4.pending-w6,w6)),0===w8&&(w4.gzindex=0,w4.status=91)}else w4.status=91;if(91===w4.status)if(w4.gzhead.comment){w6=w4.pending;do{if(w4.pending===w4.pending_buf_size&&(w4.gzhead.hcrc&&w4.pending>w6&&(w0.adler=w7(w0.adler,w4.pending_buf,w4.pending-w6,w6)),w18(w0),w6=w4.pending,w4.pending===w4.pending_buf_size)){w8=1;break}w8=w4.gzindexw6&&(w0.adler=w7(w0.adler,w4.pending_buf,w4.pending-w6,w6)),0===w8&&(w4.status=w12)}else w4.status=w12;if(w4.status===w12&&(w4.gzhead.hcrc?(w4.pending+2>w4.pending_buf_size&&w18(w0),w4.pending+2<=w4.pending_buf_size&&(w20(w4,255&w0.adler),w20(w4,w0.adler>>8&255),w0.adler=0,w4.status=w13)):w4.status=w13),0!==w4.pending){if(w18(w0),0===w0.avail_out)return w4.last_flush=-1,0}else if(0===w0.avail_in&&w16(w1)<=w16(w2)&&4!==w1)return w15(w0,-5);if(w4.status===w14&&0!==w0.avail_in)return w15(w0,-5);if(0!==w0.avail_in||0!==w4.lookahead||0!==w1&&w4.status!==w14){var w22=2===w4.strategy?function(w0,w1){for(var w2;;){if(0===w0.lookahead&&(w23(w0),0===w0.lookahead)){if(0===w1)return 1;break}if(w0.match_length=0,w2=w5._tr_tally(w0,0,w0.window[w0.strstart]),w0.lookahead--,w0.strstart++,w2&&(w19(w0,!1),0===w0.strm.avail_out))return 1}return w0.insert=0,4===w1?(w19(w0,!0),0===w0.strm.avail_out?3:4):w0.last_lit&&(w19(w0,!1),0===w0.strm.avail_out)?1:2}(w4,w1):3===w4.strategy?function(w0,w1){for(var w2,w3,w4,w6,w7=w0.window;;){if(w0.lookahead<=w10){if(w23(w0),w0.lookahead<=w10&&0===w1)return 1;if(0===w0.lookahead)break}if(w0.match_length=0,w0.lookahead>=3&&w0.strstart>0&&(w3=w7[w4=w0.strstart-1])===w7[++w4]&&w3===w7[++w4]&&w3===w7[++w4]){w6=w0.strstart+w10;do{}while(w3===w7[++w4]&&w3===w7[++w4]&&w3===w7[++w4]&&w3===w7[++w4]&&w3===w7[++w4]&&w3===w7[++w4]&&w3===w7[++w4]&&w3===w7[++w4]&&w4w0.lookahead&&(w0.match_length=w0.lookahead)}if(w0.match_length>=3?(w2=w5._tr_tally(w0,1,w0.match_length-3),w0.lookahead-=w0.match_length,w0.strstart+=w0.match_length,w0.match_length=0):(w2=w5._tr_tally(w0,0,w0.window[w0.strstart]),w0.lookahead--,w0.strstart++),w2&&(w19(w0,!1),0===w0.strm.avail_out))return 1}return w0.insert=0,4===w1?(w19(w0,!0),0===w0.strm.avail_out?3:4):w0.last_lit&&(w19(w0,!1),0===w0.strm.avail_out)?1:2}(w4,w1):w3[w4.level].func(w4,w1);if(3!==w22&&4!==w22||(w4.status=w14),1===w22||3===w22)return 0===w0.avail_out&&(w4.last_flush=-1),0;if(2===w22&&(1===w1?w5._tr_align(w4):5!==w1&&(w5._tr_stored_block(w4,0,0,!1),3===w1&&(w17(w4.head),0===w4.lookahead&&(w4.strstart=0,w4.block_start=0,w4.insert=0))),w18(w0),0===w0.avail_out))return w4.last_flush=-1,0}return 4!==w1?0:w4.wrap<=0?1:(2===w4.wrap?(w20(w4,255&w0.adler),w20(w4,w0.adler>>8&255),w20(w4,w0.adler>>16&255),w20(w4,w0.adler>>24&255),w20(w4,255&w0.total_in),w20(w4,w0.total_in>>8&255),w20(w4,w0.total_in>>16&255),w20(w4,w0.total_in>>24&255)):(w21(w4,w0.adler>>>16),w21(w4,65535&w0.adler)),w18(w0),w4.wrap>0&&(w4.wrap=-w4.wrap),0!==w4.pending?0:1)},w1.deflateEnd=function(w0){var w1;return w0&&w0.state?42!==(w1=w0.state.status)&&69!==w1&&73!==w1&&91!==w1&&w1!==w12&&w1!==w13&&w1!==w14?w15(w0,w9):(w0.state=null,w1===w13?w15(w0,-3):0):w9},w1.deflateSetDictionary=function(w0,w1){var w2,w3,w5,w7,w8,w10,w11,w12,w13=w1.length;if(!w0||!w0.state)return w9;if(2===(w7=(w2=w0.state).wrap)||1===w7&&42!==w2.status||w2.lookahead)return w9;for(1===w7&&(w0.adler=w6(w0.adler,w1,w13,0)),w2.wrap=0,w13>=w2.w_size&&(0===w7&&(w17(w2.head),w2.strstart=0,w2.block_start=0,w2.insert=0),w12=new w4.Buf8(w2.w_size),w4.arraySet(w12,w1,w13-w2.w_size,w2.w_size,0),w1=w12,w13=w2.w_size),w8=w0.avail_in,w10=w0.next_in,w11=w0.input,w0.avail_in=w13,w0.next_in=0,w0.input=w1,w23(w2);w2.lookahead>=3;){w3=w2.strstart,w5=w2.lookahead-2;do{w2.ins_h=(w2.ins_h<=0;)w0[w1]=0}var w5=256,w6=286,w7=30,w8=15,w9=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],w10=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],w11=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],w12=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],w13=new Array(576);w4(w13);var w14=new Array(60);w4(w14);var w15=new Array(512);w4(w15);var w16=new Array(256);w4(w16);var w17=new Array(29);w4(w17);var w18,w19,w20,w21=new Array(w7);function w22(w0,w1,w2,w3,w4){this.static_tree=w0,this.extra_bits=w1,this.extra_base=w2,this.elems=w3,this.max_length=w4,this.has_stree=w0&&w0.length}function w23(w0,w1){this.dyn_tree=w0,this.max_code=0,this.stat_desc=w1}function w24(w0){return w0<256?w15[w0]:w15[256+(w0>>>7)]}function w25(w0,w1){w0.pending_buf[w0.pending++]=255&w1,w0.pending_buf[w0.pending++]=w1>>>8&255}function w26(w0,w1,w2){w0.bi_valid>16-w2?(w0.bi_buf|=w1<>16-w0.bi_valid,w0.bi_valid+=w2-16):(w0.bi_buf|=w1<>>=1,w2<<=1}while(--w1>0);return w2>>>1}function w29(w0,w1,w2){var w3,w4,w5=new Array(16),w6=0;for(w3=1;w3<=w8;w3++)w5[w3]=w6=w6+w2[w3-1]<<1;for(w4=0;w4<=w1;w4++){var w7=w0[2*w4+1];0!==w7&&(w0[2*w4]=w28(w5[w7]++,w7))}}function w30(w0){var w1;for(w1=0;w18?w25(w0,w0.bi_buf):w0.bi_valid>0&&(w0.pending_buf[w0.pending++]=w0.bi_buf),w0.bi_buf=0,w0.bi_valid=0}function w32(w0,w1,w2,w3){var w4=2*w1,w5=2*w2;return w0[w4]>1;w2>=1;w2--)w33(w0,w5,w2);w4=w9;do{w2=w0.heap[1],w0.heap[1]=w0.heap[w0.heap_len--],w33(w0,w5,1),w3=w0.heap[1],w0.heap[--w0.heap_max]=w2,w0.heap[--w0.heap_max]=w3,w5[2*w4]=w5[2*w2]+w5[2*w3],w0.depth[w4]=(w0.depth[w2]>=w0.depth[w3]?w0.depth[w2]:w0.depth[w3])+1,w5[2*w2+1]=w5[2*w3+1]=w4,w0.heap[1]=w4++,w33(w0,w5,1)}while(w0.heap_len>=2);w0.heap[--w0.heap_max]=w0.heap[1],function(w0,w1){var w2,w3,w4,w5,w6,w7,w9=w1.dyn_tree,w10=w1.max_code,w11=w1.stat_desc.static_tree,w12=w1.stat_desc.has_stree,w13=w1.stat_desc.extra_bits,w14=w1.stat_desc.extra_base,w15=w1.stat_desc.max_length,w16=0;for(w5=0;w5<=w8;w5++)w0.bl_count[w5]=0;for(w9[2*w0.heap[w0.heap_max]+1]=0,w2=w0.heap_max+1;w2<573;w2++)(w5=w9[2*w9[2*(w3=w0.heap[w2])+1]+1]+1)>w15&&(w5=w15,w16++),w9[2*w3+1]=w5,w3>w10||(w0.bl_count[w5]++,w6=0,w3>=w14&&(w6=w13[w3-w14]),w7=w9[2*w3],w0.opt_len+=w7*(w5+w6),w12&&(w0.static_len+=w7*(w11[2*w3+1]+w6)));if(0!==w16){do{for(w5=w15-1;0===w0.bl_count[w5];)w5--;w0.bl_count[w5]--,w0.bl_count[w5+1]+=2,w0.bl_count[w15]--,w16-=2}while(w16>0);for(w5=w15;0!==w5;w5--)for(w3=w0.bl_count[w5];0!==w3;)(w4=w0.heap[--w2])>w10||(w9[2*w4+1]!==w5&&(w0.opt_len+=(w5-w9[2*w4+1])*w9[2*w4],w9[2*w4+1]=w5),w3--)}}(w0,w1),w29(w5,w10,w0.bl_count)}function w36(w0,w1,w2){var w3,w4,w5=-1,w6=w1[1],w7=0,w8=7,w9=4;for(0===w6&&(w8=138,w9=3),w1[2*(w2+1)+1]=65535,w3=0;w3<=w2;w3++)w4=w6,w6=w1[2*(w3+1)+1],++w7>=7;w30?(2===w0.strm.data_type&&(w0.strm.data_type=function(w0){var w1,w2=4093624447;for(w1=0;w1<=31;w1++,w2>>>=1)if(1&w2&&0!==w0.dyn_ltree[2*w1])return 0;if(0!==w0.dyn_ltree[18]||0!==w0.dyn_ltree[20]||0!==w0.dyn_ltree[26])return 1;for(w1=32;w1=3&&0===w0.bl_tree[2*w12[w1]+1];w1--);return w0.opt_len+=3*(w1+1)+5+5+4,w1}(w0),w4=w0.opt_len+3+7>>>3,(w6=w0.static_len+3+7>>>3)<=w4&&(w4=w6)):w4=w6=w2+5,w2+4<=w4&&-1!==w1?w39(w0,w1,w2,w3):4===w0.strategy||w6===w4?(w26(w0,2+(w3?1:0),3),w34(w0,w13,w14)):(w26(w0,4+(w3?1:0),3),function(w0,w1,w2,w3){var w4;for(w26(w0,w1-257,5),w26(w0,w2-1,5),w26(w0,w3-4,4),w4=0;w4>>8&255,w0.pending_buf[w0.d_buf+2*w0.last_lit+1]=255&w1,w0.pending_buf[w0.l_buf+w0.last_lit]=255&w2,w0.last_lit++,0===w1?w0.dyn_ltree[2*w2]++:(w0.matches++,w1--,w0.dyn_ltree[2*(w16[w2]+w5+1)]++,w0.dyn_dtree[2*w24(w1)]++),w0.last_lit===w0.lit_bufsize-1},w1._tr_align=function(w0){w26(w0,2,3),w27(w0,256,w13),function(w0){16===w0.bi_valid?(w25(w0,w0.bi_buf),w0.bi_buf=0,w0.bi_valid=0):w0.bi_valid>=8&&(w0.pending_buf[w0.pending++]=255&w0.bi_buf,w0.bi_buf>>=8,w0.bi_valid-=8)}(w0)}},function(w0,w1,w2){"use strict";var w3=w2(391),w4=w2(20),w5=w2(178),w6=w2(180),w7=w2(96),w8=w2(179),w9=w2(394),w10=Object.prototype.toString;function w11(w0){if(!(this instanceof w11))return new w11(w0);this.options=w4.assign({chunkSize:16384,windowBits:0,to:""},w0||{});var w1=this.options;w1.raw&&w1.windowBits>=0&&w1.windowBits<16&&(w1.windowBits=-w1.windowBits,0===w1.windowBits&&(w1.windowBits=-15)),!(w1.windowBits>=0&&w1.windowBits<16)||w0&&w0.windowBits||(w1.windowBits+=32),w1.windowBits>15&&w1.windowBits<48&&0==(15&w1.windowBits)&&(w1.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new w8,this.strm.avail_out=0;var w2=w3.inflateInit2(this.strm,w1.windowBits);if(w2!==w6.Z_OK)throw new Error(w7[w2]);if(this.header=new w9,w3.inflateGetHeader(this.strm,this.header),w1.dictionary&&("string"==typeof w1.dictionary?w1.dictionary=w5.string2buf(w1.dictionary):"[object ArrayBuffer]"===w10.call(w1.dictionary)&&(w1.dictionary=new Uint8Array(w1.dictionary)),w1.raw&&(w2=w3.inflateSetDictionary(this.strm,w1.dictionary))!==w6.Z_OK))throw new Error(w7[w2])}function w12(w0,w1){var w2=new w11(w1);if(w2.push(w0,!0),w2.err)throw w2.msg||w7[w2.err];return w2.result}w11.prototype.push=function(w0,w1){var w2,w7,w8,w9,w11,w12=this.strm,w13=this.options.chunkSize,w14=this.options.dictionary,w15=!1;if(this.ended)return!1;w7=w1===~~w1?w1:!0===w1?w6.Z_FINISH:w6.Z_NO_FLUSH,"string"==typeof w0?w12.input=w5.binstring2buf(w0):"[object ArrayBuffer]"===w10.call(w0)?w12.input=new Uint8Array(w0):w12.input=w0,w12.next_in=0,w12.avail_in=w12.input.length;do{if(0===w12.avail_out&&(w12.output=new w4.Buf8(w13),w12.next_out=0,w12.avail_out=w13),(w2=w3.inflate(w12,w6.Z_NO_FLUSH))===w6.Z_NEED_DICT&&w14&&(w2=w3.inflateSetDictionary(this.strm,w14)),w2===w6.Z_BUF_ERROR&&!0===w15&&(w2=w6.Z_OK,w15=!1),w2!==w6.Z_STREAM_END&&w2!==w6.Z_OK)return this.onEnd(w2),this.ended=!0,!1;w12.next_out&&(0!==w12.avail_out&&w2!==w6.Z_STREAM_END&&(0!==w12.avail_in||w7!==w6.Z_FINISH&&w7!==w6.Z_SYNC_FLUSH)||("string"===this.options.to?(w8=w5.utf8border(w12.output,w12.next_out),w9=w12.next_out-w8,w11=w5.buf2string(w12.output,w8),w12.next_out=w9,w12.avail_out=w13-w9,w9&&w4.arraySet(w12.output,w12.output,w8,w9,0),this.onData(w11)):this.onData(w4.shrinkBuf(w12.output,w12.next_out)))),0===w12.avail_in&&0===w12.avail_out&&(w15=!0)}while((w12.avail_in>0||0===w12.avail_out)&&w2!==w6.Z_STREAM_END);return w2===w6.Z_STREAM_END&&(w7=w6.Z_FINISH),w7===w6.Z_FINISH?(w2=w3.inflateEnd(this.strm),this.onEnd(w2),this.ended=!0,w2===w6.Z_OK):w7!==w6.Z_SYNC_FLUSH||(this.onEnd(w6.Z_OK),w12.avail_out=0,!0)},w11.prototype.onData=function(w0){this.chunks.push(w0)},w11.prototype.onEnd=function(w0){w0===w6.Z_OK&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=w4.flattenChunks(this.chunks)),this.chunks=[],this.err=w0,this.msg=this.strm.msg},w1.Inflate=w11,w1.inflate=w12,w1.inflateRaw=function(w0,w1){return(w1=w1||{}).raw=!0,w12(w0,w1)},w1.ungzip=w12},function(w0,w1,w2){"use strict";var w3=w2(20),w4=w2(176),w5=w2(177),w6=w2(392),w7=w2(393),w8=-2,w9=12,w10=30;function w11(w0){return(w0>>>24&255)+(w0>>>8&65280)+((65280&w0)<<8)+((255&w0)<<24)}function w12(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new w3.Buf16(320),this.work=new w3.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function w13(w0){var w1;return w0&&w0.state?(w1=w0.state,w0.total_in=w0.total_out=w1.total=0,w0.msg="",w1.wrap&&(w0.adler=1&w1.wrap),w1.mode=1,w1.last=0,w1.havedict=0,w1.dmax=32768,w1.head=null,w1.hold=0,w1.bits=0,w1.lencode=w1.lendyn=new w3.Buf32(852),w1.distcode=w1.distdyn=new w3.Buf32(592),w1.sane=1,w1.back=-1,0):w8}function w14(w0){var w1;return w0&&w0.state?((w1=w0.state).wsize=0,w1.whave=0,w1.wnext=0,w13(w0)):w8}function w15(w0,w1){var w2,w3;return w0&&w0.state?(w3=w0.state,w1<0?(w2=0,w1=-w1):(w2=1+(w1>>4),w1<48&&(w1&=15)),w1&&(w1<8||w1>15)?w8:(null!==w3.window&&w3.wbits!==w1&&(w3.window=null),w3.wrap=w2,w3.wbits=w1,w14(w0))):w8}function w16(w0,w1){var w2,w3;return w0?(w3=new w12,w0.state=w3,w3.window=null,0!==(w2=w15(w0,w1))&&(w0.state=null),w2):w8}var w17,w18,w19=!0;function w20(w0){if(w19){var w1;for(w17=new w3.Buf32(512),w18=new w3.Buf32(32),w1=0;w1<144;)w0.lens[w1++]=8;for(;w1<256;)w0.lens[w1++]=9;for(;w1<280;)w0.lens[w1++]=7;for(;w1<288;)w0.lens[w1++]=8;for(w7(1,w0.lens,0,288,w17,0,w0.work,{bits:9}),w1=0;w1<32;)w0.lens[w1++]=5;w7(2,w0.lens,0,32,w18,0,w0.work,{bits:5}),w19=!1}w0.lencode=w17,w0.lenbits=9,w0.distcode=w18,w0.distbits=5}function w21(w0,w1,w2,w4){var w5,w6=w0.state;return null===w6.window&&(w6.wsize=1<=w6.wsize?(w3.arraySet(w6.window,w1,w2-w6.wsize,w6.wsize,0),w6.wnext=0,w6.whave=w6.wsize):((w5=w6.wsize-w6.wnext)>w4&&(w5=w4),w3.arraySet(w6.window,w1,w2-w4,w5,w6.wnext),(w4-=w5)?(w3.arraySet(w6.window,w1,w2-w4,w4,0),w6.wnext=w4,w6.whave=w6.wsize):(w6.wnext+=w5,w6.wnext===w6.wsize&&(w6.wnext=0),w6.whave>>8&255,w2.check=w5(w2.check,w38,2,0),w18=0,w19=0,w2.mode=2;break}if(w2.flags=0,w2.head&&(w2.head.done=!1),!(1&w2.wrap)||(((255&w18)<<8)+(w18>>8))%31){w0.msg="incorrect header check",w2.mode=w10;break}if(8!=(15&w18)){w0.msg="unknown compression method",w2.mode=w10;break}if(w19-=4,w33=8+(15&(w18>>>=4)),0===w2.wbits)w2.wbits=w33;else if(w33>w2.wbits){w0.msg="invalid window size",w2.mode=w10;break}w2.dmax=1<>8&1),512&w2.flags&&(w38[0]=255&w18,w38[1]=w18>>>8&255,w2.check=w5(w2.check,w38,2,0)),w18=0,w19=0,w2.mode=3;case 3:for(;w19<32;){if(0===w16)break w0;w16--,w18+=w12[w14++]<>>8&255,w38[2]=w18>>>16&255,w38[3]=w18>>>24&255,w2.check=w5(w2.check,w38,4,0)),w18=0,w19=0,w2.mode=4;case 4:for(;w19<16;){if(0===w16)break w0;w16--,w18+=w12[w14++]<>8),512&w2.flags&&(w38[0]=255&w18,w38[1]=w18>>>8&255,w2.check=w5(w2.check,w38,2,0)),w18=0,w19=0,w2.mode=5;case 5:if(1024&w2.flags){for(;w19<16;){if(0===w16)break w0;w16--,w18+=w12[w14++]<>>8&255,w2.check=w5(w2.check,w38,2,0)),w18=0,w19=0}else w2.head&&(w2.head.extra=null);w2.mode=6;case 6:if(1024&w2.flags&&((w24=w2.length)>w16&&(w24=w16),w24&&(w2.head&&(w33=w2.head.extra_len-w2.length,w2.head.extra||(w2.head.extra=new Array(w2.head.extra_len)),w3.arraySet(w2.head.extra,w12,w14,w24,w33)),512&w2.flags&&(w2.check=w5(w2.check,w12,w24,w14)),w16-=w24,w14+=w24,w2.length-=w24),w2.length))break w0;w2.length=0,w2.mode=7;case 7:if(2048&w2.flags){if(0===w16)break w0;w24=0;do{w33=w12[w14+w24++],w2.head&&w33&&w2.length<65536&&(w2.head.name+=String.fromCharCode(w33))}while(w33&&w24>9&1,w2.head.done=!0),w0.adler=w2.check=0,w2.mode=w9;break;case 10:for(;w19<32;){if(0===w16)break w0;w16--,w18+=w12[w14++]<>>=7&w19,w19-=7&w19,w2.mode=27;break}for(;w19<3;){if(0===w16)break w0;w16--,w18+=w12[w14++]<>>=1)){case 0:w2.mode=14;break;case 1:if(w20(w2),w2.mode=20,6===w1){w18>>>=2,w19-=2;break w0}break;case 2:w2.mode=17;break;case 3:w0.msg="invalid block type",w2.mode=w10}w18>>>=2,w19-=2;break;case 14:for(w18>>>=7&w19,w19-=7&w19;w19<32;){if(0===w16)break w0;w16--,w18+=w12[w14++]<>>16^65535)){w0.msg="invalid stored block lengths",w2.mode=w10;break}if(w2.length=65535&w18,w18=0,w19=0,w2.mode=15,6===w1)break w0;case 15:w2.mode=16;case 16:if(w24=w2.length){if(w24>w16&&(w24=w16),w24>w17&&(w24=w17),0===w24)break w0;w3.arraySet(w13,w12,w14,w24,w15),w16-=w24,w14+=w24,w17-=w24,w15+=w24,w2.length-=w24;break}w2.mode=w9;break;case 17:for(;w19<14;){if(0===w16)break w0;w16--,w18+=w12[w14++]<>>=5,w19-=5,w2.ndist=1+(31&w18),w18>>>=5,w19-=5,w2.ncode=4+(15&w18),w18>>>=4,w19-=4,w2.nlen>286||w2.ndist>30){w0.msg="too many length or distance symbols",w2.mode=w10;break}w2.have=0,w2.mode=18;case 18:for(;w2.have>>=3,w19-=3}for(;w2.have<19;)w2.lens[w39[w2.have++]]=0;if(w2.lencode=w2.lendyn,w2.lenbits=7,w35={bits:w2.lenbits},w34=w7(0,w2.lens,0,19,w2.lencode,0,w2.work,w35),w2.lenbits=w35.bits,w34){w0.msg="invalid code lengths set",w2.mode=w10;break}w2.have=0,w2.mode=19;case 19:for(;w2.have>>16&255,w29=65535&w37,!((w27=w37>>>24)<=w19);){if(0===w16)break w0;w16--,w18+=w12[w14++]<>>=w27,w19-=w27,w2.lens[w2.have++]=w29;else{if(16===w29){for(w36=w27+2;w19>>=w27,w19-=w27,0===w2.have){w0.msg="invalid bit length repeat",w2.mode=w10;break}w33=w2.lens[w2.have-1],w24=3+(3&w18),w18>>>=2,w19-=2}else if(17===w29){for(w36=w27+3;w19>>=w27)),w18>>>=3,w19-=3}else{for(w36=w27+7;w19>>=w27)),w18>>>=7,w19-=7}if(w2.have+w24>w2.nlen+w2.ndist){w0.msg="invalid bit length repeat",w2.mode=w10;break}for(;w24--;)w2.lens[w2.have++]=w33}}if(w2.mode===w10)break;if(0===w2.lens[256]){w0.msg="invalid code -- missing end-of-block",w2.mode=w10;break}if(w2.lenbits=9,w35={bits:w2.lenbits},w34=w7(1,w2.lens,0,w2.nlen,w2.lencode,0,w2.work,w35),w2.lenbits=w35.bits,w34){w0.msg="invalid literal/lengths set",w2.mode=w10;break}if(w2.distbits=6,w2.distcode=w2.distdyn,w35={bits:w2.distbits},w34=w7(2,w2.lens,w2.nlen,w2.ndist,w2.distcode,0,w2.work,w35),w2.distbits=w35.bits,w34){w0.msg="invalid distances set",w2.mode=w10;break}if(w2.mode=20,6===w1)break w0;case 20:w2.mode=21;case 21:if(w16>=6&&w17>=258){w0.next_out=w15,w0.avail_out=w17,w0.next_in=w14,w0.avail_in=w16,w2.hold=w18,w2.bits=w19,w6(w0,w23),w15=w0.next_out,w13=w0.output,w17=w0.avail_out,w14=w0.next_in,w12=w0.input,w16=w0.avail_in,w18=w2.hold,w19=w2.bits,w2.mode===w9&&(w2.back=-1);break}for(w2.back=0;w28=(w37=w2.lencode[w18&(1<>>16&255,w29=65535&w37,!((w27=w37>>>24)<=w19);){if(0===w16)break w0;w16--,w18+=w12[w14++]<>w30)])>>>16&255,w29=65535&w37,!(w30+(w27=w37>>>24)<=w19);){if(0===w16)break w0;w16--,w18+=w12[w14++]<>>=w30,w19-=w30,w2.back+=w30}if(w18>>>=w27,w19-=w27,w2.back+=w27,w2.length=w29,0===w28){w2.mode=26;break}if(32&w28){w2.back=-1,w2.mode=w9;break}if(64&w28){w0.msg="invalid literal/length code",w2.mode=w10;break}w2.extra=15&w28,w2.mode=22;case 22:if(w2.extra){for(w36=w2.extra;w19>>=w2.extra,w19-=w2.extra,w2.back+=w2.extra}w2.was=w2.length,w2.mode=23;case 23:for(;w28=(w37=w2.distcode[w18&(1<>>16&255,w29=65535&w37,!((w27=w37>>>24)<=w19);){if(0===w16)break w0;w16--,w18+=w12[w14++]<>w30)])>>>16&255,w29=65535&w37,!(w30+(w27=w37>>>24)<=w19);){if(0===w16)break w0;w16--,w18+=w12[w14++]<>>=w30,w19-=w30,w2.back+=w30}if(w18>>>=w27,w19-=w27,w2.back+=w27,64&w28){w0.msg="invalid distance code",w2.mode=w10;break}w2.offset=w29,w2.extra=15&w28,w2.mode=24;case 24:if(w2.extra){for(w36=w2.extra;w19>>=w2.extra,w19-=w2.extra,w2.back+=w2.extra}if(w2.offset>w2.dmax){w0.msg="invalid distance too far back",w2.mode=w10;break}w2.mode=25;case 25:if(0===w17)break w0;if(w24=w23-w17,w2.offset>w24){if((w24=w2.offset-w24)>w2.whave&&w2.sane){w0.msg="invalid distance too far back",w2.mode=w10;break}w24>w2.wnext?(w24-=w2.wnext,w25=w2.wsize-w24):w25=w2.wnext-w24,w24>w2.length&&(w24=w2.length),w26=w2.window}else w26=w13,w25=w15-w2.offset,w24=w2.length;w24>w17&&(w24=w17),w17-=w24,w2.length-=w24;do{w13[w15++]=w26[w25++]}while(--w24);0===w2.length&&(w2.mode=21);break;case 26:if(0===w17)break w0;w13[w15++]=w2.length,w17--,w2.mode=21;break;case 27:if(w2.wrap){for(;w19<32;){if(0===w16)break w0;w16--,w18|=w12[w14++]<>>=w20=w19>>>24,w14-=w20,0===(w20=w19>>>16&255))w26[w5++]=65535&w19;else{if(!(16&w20)){if(0==(64&w20)){w19=w15[(65535&w19)+(w13&(1<>>=w20,w14-=w20),w14<15&&(w13+=w25[w3++]<>>=w20=w19>>>24,w14-=w20,!(16&(w20=w19>>>16&255))){if(0==(64&w20)){w19=w16[(65535&w19)+(w13&(1<w8){w0.msg="invalid distance too far back",w2.mode=30;break w0}if(w13>>>=w20,w14-=w20,w22>(w20=w5-w6)){if((w20=w22-w20)>w10&&w2.sane){w0.msg="invalid distance too far back",w2.mode=30;break w0}if(w23=0,w24=w12,0===w11){if(w23+=w9-w20,w202;)w26[w5++]=w24[w23++],w26[w5++]=w24[w23++],w26[w5++]=w24[w23++],w21-=3;w21&&(w26[w5++]=w24[w23++],w21>1&&(w26[w5++]=w24[w23++]))}else{w23=w5-w22;do{w26[w5++]=w26[w23++],w26[w5++]=w26[w23++],w26[w5++]=w26[w23++],w21-=3}while(w21>2);w21&&(w26[w5++]=w26[w23++],w21>1&&(w26[w5++]=w26[w23++]))}break}}break}}while(w3>3,w13&=(1<<(w14-=w21<<3))-1,w0.next_in=w3,w0.next_out=w5,w0.avail_in=w3=1&&0===w36[w27];w27--);if(w28>w27&&(w28=w27),0===w27)return w10[w11++]=20971520,w10[w11++]=20971520,w13.bits=1,0;for(w26=1;w260&&(0===w0||1!==w27))return-1;for(w37[1]=0,w24=1;w24852||2===w0&&w32>592)return 1;for(;;){w20=w24-w30,w12[w25]w19?(w21=w38[w39+w12[w25]],w22=w34[w35+w12[w25]]):(w21=96,w22=0),w14=1<>w30)+(w15-=w14)]=w20<<24|w21<<16|w22|0}while(0!==w15);for(w14=1<>=1;if(0!==w14?(w33&=w14-1,w33+=w14):w33=0,w25++,0==--w36[w24]){if(w24===w27)break;w24=w1[w2+w12[w25]]}if(w24>w28&&(w33&w17)!==w16){for(0===w30&&(w30=w28),w18+=w26,w31=1<<(w29=w24-w30);w29+w30852||2===w0&&w32>592)return 1;w10[w16=w33&w17]=w28<<24|w29<<16|w18-w11|0}}return 0!==w33&&(w10[w18+w33]=w24-w30<<24|64<<16|0),w13.bits=w28,0}},function(w0,w1,w2){"use strict";w0.exports=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__395__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__396__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__397__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__398__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__399__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__400__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__401__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__402__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__403__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__404__},function(w0,w1){w0.exports=__WEBPACK_EXTERNAL_MODULE__405__}])})); //# sourceMappingURL=proto.min.js.map