572babb730d47fc7ba14e4aab72108630386903f
[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 _0xdafa=['register','length','voiceQueue:','save','remove','update','emit','removeListener'];(function(_0x31aa93,_0x3a8893){var _0x5665c7=function(_0x4254ca){while(--_0x4254ca){_0x31aa93['push'](_0x31aa93['shift']());}};_0x5665c7(++_0x3a8893);}(_0xdafa,0x113));var _0xadaf=function(_0x2a827f,_0x54f5f6){_0x2a827f=_0x2a827f-0x0;var _0x51689a=_0xdafa[_0x2a827f];return _0x51689a;};'use strict';var VoiceQueueEvents=require('./voiceQueue.events');var events=[_0xadaf('0x0'),_0xadaf('0x1'),_0xadaf('0x2')];function createListener(_0x4c325c,_0xf860e5){return function(_0x9e9d5b){_0xf860e5[_0xadaf('0x3')](_0x4c325c,_0x9e9d5b);};}function removeListener(_0x1c4f48,_0xd745b1){return function(){VoiceQueueEvents[_0xadaf('0x4')](_0x1c4f48,_0xd745b1);};}exports[_0xadaf('0x5')]=function(_0x8dd02d){for(var _0x481c10=0x0,_0x283994=events[_0xadaf('0x6')];_0x481c10<_0x283994;_0x481c10++){var _0x2ac1e9=events[_0x481c10];var _0x3f3b44=createListener(_0xadaf('0x7')+_0x2ac1e9,_0x8dd02d);VoiceQueueEvents['on'](_0x2ac1e9,_0x3f3b44);}};