e75618d084f0da875a29e155315f9cfcfe14171c
[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 _0x70e7=['emit','removeListener','register','length','voiceQueue:','save','update'];(function(_0x1facfa,_0x1acf7d){var _0x9ec701=function(_0x115e37){while(--_0x115e37){_0x1facfa['push'](_0x1facfa['shift']());}};_0x9ec701(++_0x1acf7d);}(_0x70e7,0xc9));var _0x770e=function(_0x5e8909,_0x251263){_0x5e8909=_0x5e8909-0x0;var _0x12528d=_0x70e7[_0x5e8909];return _0x12528d;};'use strict';var VoiceQueueEvents=require('./voiceQueue.events');var events=[_0x770e('0x0'),'remove',_0x770e('0x1')];function createListener(_0x2b908b,_0x52a846){return function(_0x2e2836){_0x52a846[_0x770e('0x2')](_0x2b908b,_0x2e2836);};}function removeListener(_0x115c50,_0x54fb5e){return function(){VoiceQueueEvents[_0x770e('0x3')](_0x115c50,_0x54fb5e);};}exports[_0x770e('0x4')]=function(_0xf7951e){for(var _0x15d455=0x0,_0x1b2794=events[_0x770e('0x5')];_0x15d455<_0x1b2794;_0x15d455++){var _0x2d24ff=events[_0x15d455];var _0x5b8a81=createListener(_0x770e('0x6')+_0x2d24ff,_0xf7951e);VoiceQueueEvents['on'](_0x2d24ff,_0x5b8a81);}};