3701e085b83bfc125ef37f780cde999096674e5c
[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 _0x01bb=['remove','update','register','length','voiceQueue:','./voiceQueue.events','save'];(function(_0x20a584,_0xe384a5){var _0x4b41a8=function(_0x2127c6){while(--_0x2127c6){_0x20a584['push'](_0x20a584['shift']());}};_0x4b41a8(++_0xe384a5);}(_0x01bb,0x171));var _0xb01b=function(_0x3b0380,_0x1fa3d9){_0x3b0380=_0x3b0380-0x0;var _0x307d69=_0x01bb[_0x3b0380];return _0x307d69;};'use strict';var VoiceQueueEvents=require(_0xb01b('0x0'));var events=[_0xb01b('0x1'),_0xb01b('0x2'),_0xb01b('0x3')];function createListener(_0x8590b,_0x55e29f){return function(_0x164b39){_0x55e29f['emit'](_0x8590b,_0x164b39);};}function removeListener(_0x157a52,_0x4aee05){return function(){VoiceQueueEvents['removeListener'](_0x157a52,_0x4aee05);};}exports[_0xb01b('0x4')]=function(_0x13afdd){for(var _0x3e3360=0x0,_0xc9f593=events[_0xb01b('0x5')];_0x3e3360<_0xc9f593;_0x3e3360++){var _0x197515=events[_0x3e3360];var _0xb32053=createListener(_0xb01b('0x6')+_0x197515,_0x13afdd);VoiceQueueEvents['on'](_0x197515,_0xb32053);}};