00812da3197592924e49191f35d344e4808a9cba
[motion2.git] / server / api / voiceQueue / voiceQueue.socket.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 _0x5e25=['update','removeListener','register','length','voiceQueue:','./voiceQueue.events','save'];(function(_0x16f5d5,_0x184bb0){var _0x1b9f8c=function(_0x224d6d){while(--_0x224d6d){_0x16f5d5['push'](_0x16f5d5['shift']());}};_0x1b9f8c(++_0x184bb0);}(_0x5e25,0x1c5));var _0x55e2=function(_0x164d6f,_0x56f8c3){_0x164d6f=_0x164d6f-0x0;var _0x21777c=_0x5e25[_0x164d6f];return _0x21777c;};'use strict';var VoiceQueueEvents=require(_0x55e2('0x0'));var events=[_0x55e2('0x1'),'remove',_0x55e2('0x2')];function createListener(_0x3c7969,_0x4fea53){return function(_0x51df56){_0x4fea53['emit'](_0x3c7969,_0x51df56);};}function removeListener(_0x397060,_0x56cd8a){return function(){VoiceQueueEvents[_0x55e2('0x3')](_0x397060,_0x56cd8a);};}exports[_0x55e2('0x4')]=function(_0x4b1d64){for(var _0x1a2c94=0x0,_0x466147=events[_0x55e2('0x5')];_0x1a2c94<_0x466147;_0x1a2c94++){var _0x3746aa=events[_0x1a2c94];var _0x345247=createListener(_0x55e2('0x6')+_0x3746aa,_0x4b1d64);VoiceQueueEvents['on'](_0x3746aa,_0x345247);}};