Built motion from commit d9028345.|2.5.43
[motion2.git] / server / api / plugin / plugin.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 _0x84ff=['save','remove','update','emit','register','plugin:'];(function(_0x42cae2,_0x284ef8){var _0x5f256f=function(_0x41abc8){while(--_0x41abc8){_0x42cae2['push'](_0x42cae2['shift']());}};_0x5f256f(++_0x284ef8);}(_0x84ff,0x1aa));var _0xf84f=function(_0xc329b0,_0x1591a1){_0xc329b0=_0xc329b0-0x0;var _0x1e9e68=_0x84ff[_0xc329b0];return _0x1e9e68;};'use strict';var PluginEvents=require('./plugin.events');var events=[_0xf84f('0x0'),_0xf84f('0x1'),_0xf84f('0x2')];function createListener(_0x435904,_0x342bbc){return function(_0x312cd9){_0x342bbc[_0xf84f('0x3')](_0x435904,_0x312cd9);};}function removeListener(_0x1b6067,_0x790077){return function(){PluginEvents['removeListener'](_0x1b6067,_0x790077);};}exports[_0xf84f('0x4')]=function(_0x2f1e5f){for(var _0x1c609c=0x0,_0x42f686=events['length'];_0x1c609c<_0x42f686;_0x1c609c++){var _0x2af25a=events[_0x1c609c];var _0x5be59a=createListener(_0xf84f('0x5')+_0x2af25a,_0x2f1e5f);PluginEvents['on'](_0x2af25a,_0x5be59a);}};