97cc4b23b2dde78aeb0d2a2bf1b7429a58e61eef
[motion2.git] / server / services / agi / reply.js
1 // *************************************************************************
2 // *                                                                       *
3 // * xCALLY Motion -  The Omnichannel Contact Center                       *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved                     *
5 // *                                                                       *
6 // *************************************************************************
7 // *                                                                       *
8 // * Email: info@xcally.com                                                *
9 // * Website: https://www.xcally.com                                       *
10 // *                                                                       *
11 // *************************************************************************
12 // *                                                                       *
13 // * The SOFTWARE PRODUCT is protected by copyright laws and international *
14 // * copyright treaties, as well as other intellectual property laws and   *
15 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                         *
16 // *                                                                       *
17 // *************************************************************************
18 var _0x6de9=['line','exports','util','stream','Transform','call','_inBody','inherits','_transform','\x0d\x0a\x0d\x0a','_localBuffer','toString','indexOf','substring','length','split','trim','slice','emit'];(function(_0x25e0f0,_0x107a89){var _0x4b75c2=function(_0x1d7574){while(--_0x1d7574){_0x25e0f0['push'](_0x25e0f0['shift']());}};_0x4b75c2(++_0x107a89);}(_0x6de9,0xe6));var _0x96de=function(_0x3b380d,_0x4bf247){_0x3b380d=_0x3b380d-0x0;var _0x54502b=_0x6de9[_0x3b380d];return _0x54502b;};'use strict';var util=require(_0x96de('0x0'));var Transform=require(_0x96de('0x1'))[_0x96de('0x2')];function AGIReply(_0x69502){Transform[_0x96de('0x3')](this,_0x69502);this['_localBuffer']='';this[_0x96de('0x4')]=![];}util[_0x96de('0x5')](AGIReply,Transform);AGIReply['prototype'][_0x96de('0x6')]=function(_0x16c148,_0x4b61bc,_0x84f9b0){var _0x24da4e='\x0a',_0x20ed57=['\x0a\x0a',_0x96de('0x7')],_0x46afa4=-0x1,_0x48e213=-0x1,_0x8624be='',_0x14fad5=0x0,_0x272ac3='',_0x57c1b7='';this[_0x96de('0x8')]+=_0x16c148[_0x96de('0x9')]();_0x272ac3=this['_localBuffer'];if(!this['_inBody']){_0x14fad5=0x0;while(_0x20ed57[_0x14fad5]){while((_0x48e213=_0x272ac3[_0x96de('0xa')](_0x20ed57[_0x14fad5]))!=-0x1){_0x8624be=_0x20ed57[_0x14fad5];_0x57c1b7=_0x272ac3[_0x96de('0xb')](0x0,_0x48e213);_0x272ac3=_0x272ac3['substring'](_0x48e213+_0x8624be[_0x96de('0xc')]);var _0x2e82bd=_0x57c1b7[_0x96de('0xd')](_0x24da4e),_0x5c6b7a=0x0,_0x5cf3fe={},_0x402493='',_0x1ca945='',_0x54d1bf=-0x1;while(_0x2e82bd[_0x5c6b7a]){_0x54d1bf=_0x2e82bd[_0x5c6b7a]['indexOf'](':');if(_0x54d1bf!=-0x1){_0x402493=_0x2e82bd[_0x5c6b7a]['slice'](0x0,_0x54d1bf)[_0x96de('0xe')]();_0x1ca945=_0x2e82bd[_0x5c6b7a][_0x96de('0xf')](_0x54d1bf+0x1)[_0x96de('0xe')]();if(_0x402493[_0x96de('0xc')]>0x0){_0x5cf3fe[_0x402493]=_0x1ca945;}}else{}_0x5c6b7a++;}this[_0x96de('0x10')]('headers',_0x5cf3fe);this[_0x96de('0x4')]=!![];}_0x14fad5++;}this[_0x96de('0x8')]=_0x272ac3;}else{while((_0x46afa4=_0x272ac3[_0x96de('0xa')](_0x24da4e))!=-0x1){_0x57c1b7=_0x272ac3[_0x96de('0xb')](0x0,_0x46afa4);this[_0x96de('0x10')](_0x96de('0x11'),_0x57c1b7);_0x272ac3=_0x272ac3[_0x96de('0xb')](_0x46afa4+_0x24da4e[_0x96de('0xc')]);}this[_0x96de('0x8')]=_0x272ac3;}_0x84f9b0();};module[_0x96de('0x12')]=AGIReply;