Built motion from commit e1a315787.|1.0.21
[motion.git] / server / config / agi / lib / connection.js
1 var _0x1ecd=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x2E\x2F\x63\x68\x61\x6E\x6E\x65\x6C","\x61\x67\x69","\x2E\x2E\x2F\x2E\x2E\x2F\x6C\x6F\x67\x67\x65\x72\x2E\x6A\x73","\x63\x6F\x6E\x6E\x65\x63\x74\x69\x6F\x6E","\x6D\x61\x70\x70\x65\x72","\x62\x75\x66\x66\x65\x72","","\x64\x61\x74\x61","\x62\x69\x6E\x64","\x68\x61\x6E\x64\x6C\x65\x44\x61\x74\x61","\x6F\x6E","\x65\x6E\x64","\x68\x61\x6E\x64\x6C\x65\x45\x6E\x64","\x70\x72\x6F\x74\x6F\x74\x79\x70\x65","\x75\x74\x66\x38","\x48\x41\x4E\x47\x55\x50","\x69\x6E\x64\x65\x78\x4F\x66","\x68\x61\x6E\x64\x6C\x65\x72","\x68\x61\x6E\x67\x75\x70","\x74\x72\x69\x6D","\x0A\x0A","\x72\x65\x71\x75\x65\x73\x74","\x67\x65\x74\x56\x61\x72\x69\x61\x62\x6C\x65\x73","\x68\x61\x6E\x64\x6C\x65\x52\x65\x70\x6C\x79","\x68\x61\x6E\x64\x6C\x65\x52\x65\x71\x75\x65\x73\x74","\x63\x6F\x6D\x70\x6C\x65\x74\x65\x64","\x68\x61\x6E\x64\x6C\x65\x43\x6F\x6D\x70\x6C\x65\x74\x65\x64","\x64\x6F\x6E\x65","\x68\x61\x6E\x64\x6C\x65\x44\x6F\x6E\x65","\x65\x72\x72\x6F\x72","\x68\x61\x6E\x64\x6C\x65\x45\x72\x72\x6F\x72","\x68\x61\x6E\x64\x6C\x65\x54\x69\x6D\x65\x6F\x75\x74","\x54\x69\x6D\x65\x6F\x75\x74","\x69\x6E\x66\x6F","\x64\x65\x73\x74\x72\x6F\x79","\x45\x6E\x64","\x52\x65\x71\x75\x65\x73\x74","\x0A","\x77\x72\x69\x74\x65","\x45\x72\x72\x6F\x72\x3A","\x44\x6F\x6E\x65","\x43\x6F\x6D\x70\x6C\x65\x74\x65\x64","\x44\x65\x73\x74\x72\x6F\x79","\x73\x70\x6C\x69\x74","\x6C\x65\x6E\x67\x74\x68","\x61\x67\x69\x5F","\x73\x75\x62\x73\x74\x72\x69\x6E\x67","\x66\x6F\x72\x45\x61\x63\x68","\x65\x78\x70\x6F\x72\x74\x73"];_0x1ecd[0];var AGIChannel=require(_0x1ecd[1]);var logger=require(_0x1ecd[3])(_0x1ecd[2]);var AGIConnection=function(_0xd1b2x4,_0xd1b2x5){this[_0x1ecd[4]]= _0xd1b2x5;this[_0x1ecd[5]]= _0xd1b2x4;this[_0x1ecd[6]]= _0x1ecd[7];this[_0x1ecd[4]][_0x1ecd[11]](_0x1ecd[8],this[_0x1ecd[10]][_0x1ecd[9]](this));this[_0x1ecd[4]][_0x1ecd[11]](_0x1ecd[12],this[_0x1ecd[13]][_0x1ecd[9]](this))};AGIConnection[_0x1ecd[14]][_0x1ecd[10]]= function(_0xd1b2x6){var _0xd1b2x7=this;_0xd1b2x6= _0xd1b2x6.toString(_0x1ecd[15]);if(_0xd1b2x6[_0x1ecd[17]](_0x1ecd[16])=== 0){if(this[_0x1ecd[18]]){this[_0x1ecd[18]](_0x1ecd[19])};return};if(this[_0x1ecd[18]]){this[_0x1ecd[18]](_0xd1b2x6[_0x1ecd[20]]())}else {this[_0x1ecd[6]]+= _0xd1b2x6;if(this[_0x1ecd[6]][_0x1ecd[17]](_0x1ecd[21])>= 0){this[_0x1ecd[22]]= this[_0x1ecd[23]](this[_0x1ecd[6]]);var _0xd1b2x8= new AGIChannel(this[_0x1ecd[22]],this[_0x1ecd[5]]);this[_0x1ecd[18]]= _0xd1b2x8[_0x1ecd[24]][_0x1ecd[9]](_0xd1b2x8);_0xd1b2x8[_0x1ecd[11]](_0x1ecd[22],this[_0x1ecd[25]][_0x1ecd[9]](this));_0xd1b2x8[_0x1ecd[11]](_0x1ecd[26],this[_0x1ecd[27]][_0x1ecd[9]](this));_0xd1b2x8[_0x1ecd[11]](_0x1ecd[28],this[_0x1ecd[29]][_0x1ecd[9]](this));_0xd1b2x8[_0x1ecd[11]](_0x1ecd[30],this[_0x1ecd[31]][_0x1ecd[9]](this))}}};AGIConnection[_0x1ecd[14]][_0x1ecd[32]]= function(){logger[_0x1ecd[34]](_0x1ecd[33]);if(this[_0x1ecd[18]]){this[_0x1ecd[18]](_0x1ecd[19])};this[_0x1ecd[35]]()};AGIConnection[_0x1ecd[14]][_0x1ecd[13]]= function(){logger[_0x1ecd[34]](_0x1ecd[36]);if(this[_0x1ecd[18]]){this[_0x1ecd[18]](_0x1ecd[19])};this[_0x1ecd[35]]()};AGIConnection[_0x1ecd[14]][_0x1ecd[25]]= function(_0xd1b2x9){logger[_0x1ecd[34]](_0x1ecd[37],_0xd1b2x9);if(this[_0x1ecd[4]]){this[_0x1ecd[4]][_0x1ecd[39]](_0xd1b2x9+ _0x1ecd[38])}};AGIConnection[_0x1ecd[14]][_0x1ecd[31]]= function(_0xd1b2xa){logger[_0x1ecd[30]](_0x1ecd[40],_0xd1b2xa);this[_0x1ecd[35]]()};AGIConnection[_0x1ecd[14]][_0x1ecd[29]]= function(){logger[_0x1ecd[34]](_0x1ecd[41]);this[_0x1ecd[35]]()};AGIConnection[_0x1ecd[14]][_0x1ecd[27]]= function(){logger[_0x1ecd[34]](_0x1ecd[42])};AGIConnection[_0x1ecd[14]][_0x1ecd[35]]= function(){logger[_0x1ecd[34]](_0x1ecd[43]);if(this[_0x1ecd[4]]){this[_0x1ecd[4]][_0x1ecd[35]]();this[_0x1ecd[4]]= null}};AGIConnection[_0x1ecd[14]][_0x1ecd[23]]= function(_0xd1b2xb){var _0xd1b2xc={};var _0xd1b2x6=_0xd1b2xb.toString();_0xd1b2x6[_0x1ecd[44]](_0x1ecd[38])[_0x1ecd[48]](function(_0xd1b2xd){var _0xd1b2xe=_0xd1b2xd[_0x1ecd[44]](/:\s?/);if(_0xd1b2xe[_0x1ecd[45]]=== 2){var _0xd1b2xf=_0xd1b2xe[0][_0x1ecd[20]]();if(_0xd1b2xf[_0x1ecd[17]](_0x1ecd[46])=== 0){_0xd1b2xf= _0xd1b2xf[_0x1ecd[47]](4)};var _0xd1b2x10=_0xd1b2xe[1][_0x1ecd[20]]();_0xd1b2xc[_0xd1b2xf]= _0xd1b2x10}});return _0xd1b2xc};module[_0x1ecd[49]]= AGIConnection