Built motion from commit c738b9ac.|2.6.25
[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 _0x6ae1=['toString','indexOf','substring','slice','trim','emit','line','length','exports','stream','Transform','call','_localBuffer','_inBody','inherits','prototype','_transform','\x0d\x0a\x0d\x0a'];(function(_0x436cdc,_0x5ebb85){var _0xa95250=function(_0x5a0175){while(--_0x5a0175){_0x436cdc['push'](_0x436cdc['shift']());}};_0xa95250(++_0x5ebb85);}(_0x6ae1,0x15f));var _0x16ae=function(_0x253905,_0xad6f1){_0x253905=_0x253905-0x0;var _0x53c7ab=_0x6ae1[_0x253905];return _0x53c7ab;};'use strict';var util=require('util');var Transform=require(_0x16ae('0x0'))[_0x16ae('0x1')];function AGIReply(_0x330aa3){Transform[_0x16ae('0x2')](this,_0x330aa3);this[_0x16ae('0x3')]='';this[_0x16ae('0x4')]=![];}util[_0x16ae('0x5')](AGIReply,Transform);AGIReply[_0x16ae('0x6')][_0x16ae('0x7')]=function(_0x208d11,_0x547d74,_0x47e09d){var _0x219c25='\x0a',_0x47d3f8=['\x0a\x0a',_0x16ae('0x8')],_0x1ea9cf=-0x1,_0x401622=-0x1,_0x1ba690='',_0x41115f=0x0,_0x2d0005='',_0x46deae='';this[_0x16ae('0x3')]+=_0x208d11[_0x16ae('0x9')]();_0x2d0005=this[_0x16ae('0x3')];if(!this['_inBody']){_0x41115f=0x0;while(_0x47d3f8[_0x41115f]){while((_0x401622=_0x2d0005[_0x16ae('0xa')](_0x47d3f8[_0x41115f]))!=-0x1){_0x1ba690=_0x47d3f8[_0x41115f];_0x46deae=_0x2d0005[_0x16ae('0xb')](0x0,_0x401622);_0x2d0005=_0x2d0005[_0x16ae('0xb')](_0x401622+_0x1ba690['length']);var _0x1e7b9b=_0x46deae['split'](_0x219c25),_0x2151eb=0x0,_0x545000={},_0x38c19a='',_0x419cfb='',_0x5dc4a9=-0x1;while(_0x1e7b9b[_0x2151eb]){_0x5dc4a9=_0x1e7b9b[_0x2151eb][_0x16ae('0xa')](':');if(_0x5dc4a9!=-0x1){_0x38c19a=_0x1e7b9b[_0x2151eb][_0x16ae('0xc')](0x0,_0x5dc4a9)[_0x16ae('0xd')]();_0x419cfb=_0x1e7b9b[_0x2151eb][_0x16ae('0xc')](_0x5dc4a9+0x1)[_0x16ae('0xd')]();if(_0x38c19a['length']>0x0){_0x545000[_0x38c19a]=_0x419cfb;}}else{}_0x2151eb++;}this[_0x16ae('0xe')]('headers',_0x545000);this['_inBody']=!![];}_0x41115f++;}this['_localBuffer']=_0x2d0005;}else{while((_0x1ea9cf=_0x2d0005[_0x16ae('0xa')](_0x219c25))!=-0x1){_0x46deae=_0x2d0005[_0x16ae('0xb')](0x0,_0x1ea9cf);this[_0x16ae('0xe')](_0x16ae('0xf'),_0x46deae);_0x2d0005=_0x2d0005['substring'](_0x1ea9cf+_0x219c25[_0x16ae('0x10')]);}this[_0x16ae('0x3')]=_0x2d0005;}_0x47e09d();};module[_0x16ae('0x11')]=AGIReply;