Built motion from commit e6806ed6.|2.6.0
[motion2.git] / server / api / cmList / cmList.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 _0x1f03=['update','removeListener','length','save','remove'];(function(_0x2c9780,_0x2f528d){var _0x3fafe5=function(_0x208c30){while(--_0x208c30){_0x2c9780['push'](_0x2c9780['shift']());}};_0x3fafe5(++_0x2f528d);}(_0x1f03,0xe9));var _0x31f0=function(_0xab69fa,_0x211436){_0xab69fa=_0xab69fa-0x0;var _0x5abb4c=_0x1f03[_0xab69fa];return _0x5abb4c;};'use strict';var CmListEvents=require('./cmList.events');var events=[_0x31f0('0x0'),_0x31f0('0x1'),_0x31f0('0x2')];function createListener(_0xdc89ce,_0x5ddf8e){return function(_0x401366){_0x5ddf8e['emit'](_0xdc89ce,_0x401366);};}function removeListener(_0x477d7c,_0x221823){return function(){CmListEvents[_0x31f0('0x3')](_0x477d7c,_0x221823);};}exports['register']=function(_0x4869a0){for(var _0x3064bb=0x0,_0x7ff6be=events[_0x31f0('0x4')];_0x3064bb<_0x7ff6be;_0x3064bb++){var _0x2ebce1=events[_0x3064bb];var _0x291253=createListener('cmList:'+_0x2ebce1,_0x4869a0);CmListEvents['on'](_0x2ebce1,_0x291253);}};