Blame view

src/ExternLib/StatisticFunctions/AMDAPlugin.cc 3.81 KB
74a11471   Benjamin Renard   Add min, max, var...
1
2
3
4
5
6
7
8
9
10
11
// Standard libraries include files
//-----------------------------------------------------------------------------
#include <iostream>

// Include oriented definitions 
//-----------------------------------------------------------------------------

// Module Kernel include files
//-----------------------------------------------------------------------------

#include "ProcessStatisticFunctions.hh"
e8db9c26   Hacene SI HADJ MOHAND   structure ok
12
#include "CorrelationProcess.hh"
74a11471   Benjamin Renard   Add min, max, var...
13
14
15
16
17
18
19
20
21
22
#include "ServicesServer.hh"
#include "PluginManager.hh"

using namespace AMDA::Parameters;

// Other modules include files
//-----------------------------------------------------------------------------

/**
   Retrieve the Plugin version we're going to expect
bf54b7d4   Hacene SI HADJ MOHAND   not woring yet
23
24
25
 */
extern "C" const char* getPluginVersion() {
    return "(Version)";
74a11471   Benjamin Renard   Add min, max, var...
26
27
28
29
}

/**
   Tells us to register our functionality to an engine kernel
bf54b7d4   Hacene SI HADJ MOHAND   not woring yet
30
 */
3caf58ee   Hacene SI HADJ MOHAND   compil mais march...
31
extern "C" void registerPlugin(AMDA::Plugins::PluginManager & pm) {
e8db9c26   Hacene SI HADJ MOHAND   structure ok
32
    std::string pluginPath = pm.getCurrentPluginPath();
bf54b7d4   Hacene SI HADJ MOHAND   not woring yet
33
34
    ProcessFactory factProcessMinFunc = boost::factory<ProcessMinFunc*>();
    ServicesServer::getInstance()->addProcessFactory("min", factProcessMinFunc);
3caf58ee   Hacene SI HADJ MOHAND   compil mais march...
35
    ServicesServer::getInstance()->linkProcessWithPlugin("min", pluginPath);
bf54b7d4   Hacene SI HADJ MOHAND   not woring yet
36
37
38

    ProcessFactory factProcessMinSmFunc = boost::factory<ProcessMinSmFunc*>();
    ServicesServer::getInstance()->addProcessFactory("min_sm", factProcessMinSmFunc);
3caf58ee   Hacene SI HADJ MOHAND   compil mais march...
39
    ServicesServer::getInstance()->linkProcessWithPlugin("min_sm", pluginPath);
bf54b7d4   Hacene SI HADJ MOHAND   not woring yet
40
41
42

    ProcessFactory factProcessMaxFunc = boost::factory<ProcessMaxFunc*>();
    ServicesServer::getInstance()->addProcessFactory("max", factProcessMaxFunc);
3caf58ee   Hacene SI HADJ MOHAND   compil mais march...
43
    ServicesServer::getInstance()->linkProcessWithPlugin("max", pluginPath);
bf54b7d4   Hacene SI HADJ MOHAND   not woring yet
44
45
46

    ProcessFactory factProcessMaxSmFunc = boost::factory<ProcessMaxSmFunc*>();
    ServicesServer::getInstance()->addProcessFactory("max_sm", factProcessMaxSmFunc);
3caf58ee   Hacene SI HADJ MOHAND   compil mais march...
47
    ServicesServer::getInstance()->linkProcessWithPlugin("max_sm", pluginPath);
bf54b7d4   Hacene SI HADJ MOHAND   not woring yet
48
49
50

    ProcessFactory factProcessVarFunc = boost::factory<ProcessVarFunc*>();
    ServicesServer::getInstance()->addProcessFactory("var", factProcessVarFunc);
3caf58ee   Hacene SI HADJ MOHAND   compil mais march...
51
    ServicesServer::getInstance()->linkProcessWithPlugin("var", pluginPath);
bf54b7d4   Hacene SI HADJ MOHAND   not woring yet
52
53
54

    ProcessFactory factProcessVarSmFunc = boost::factory<ProcessVarSmFunc*>();
    ServicesServer::getInstance()->addProcessFactory("var_sm", factProcessVarSmFunc);
3caf58ee   Hacene SI HADJ MOHAND   compil mais march...
55
    ServicesServer::getInstance()->linkProcessWithPlugin("var_sm", pluginPath);
bf54b7d4   Hacene SI HADJ MOHAND   not woring yet
56
57
58

    ProcessFactory factProcessRmsFunc = boost::factory<ProcessRmsFunc*>();
    ServicesServer::getInstance()->addProcessFactory("rms", factProcessRmsFunc);
3caf58ee   Hacene SI HADJ MOHAND   compil mais march...
59
    ServicesServer::getInstance()->linkProcessWithPlugin("rms", pluginPath);
bf54b7d4   Hacene SI HADJ MOHAND   not woring yet
60
61
62

    ProcessFactory factProcessRmsSmFunc = boost::factory<ProcessRmsSmFunc*>();
    ServicesServer::getInstance()->addProcessFactory("rms_sm", factProcessRmsSmFunc);
3caf58ee   Hacene SI HADJ MOHAND   compil mais march...
63
    ServicesServer::getInstance()->linkProcessWithPlugin("rms_sm", pluginPath);
bf54b7d4   Hacene SI HADJ MOHAND   not woring yet
64
65
66

    ProcessFactory factProcessSkewFunc = boost::factory<ProcessSkewFunc*>();
    ServicesServer::getInstance()->addProcessFactory("skew", factProcessSkewFunc);
3caf58ee   Hacene SI HADJ MOHAND   compil mais march...
67
    ServicesServer::getInstance()->linkProcessWithPlugin("skew", pluginPath);
bf54b7d4   Hacene SI HADJ MOHAND   not woring yet
68
69
70

    ProcessFactory factProcessSkewSmFunc = boost::factory<ProcessSkewSmFunc*>();
    ServicesServer::getInstance()->addProcessFactory("skew_sm", factProcessSkewSmFunc);
3caf58ee   Hacene SI HADJ MOHAND   compil mais march...
71
    ServicesServer::getInstance()->linkProcessWithPlugin("skew_sm", pluginPath);
bf54b7d4   Hacene SI HADJ MOHAND   not woring yet
72
73
74

    ProcessFactory factProcessMedianFunc = boost::factory<ProcessMedianFunc*>();
    ServicesServer::getInstance()->addProcessFactory("median", factProcessMedianFunc);
3caf58ee   Hacene SI HADJ MOHAND   compil mais march...
75
    ServicesServer::getInstance()->linkProcessWithPlugin("median", pluginPath);
e8db9c26   Hacene SI HADJ MOHAND   structure ok
76

e8db9c26   Hacene SI HADJ MOHAND   structure ok
77
78
79
    ProcessFactory factProcessCorrelation = boost::factory<CorrelationProcess*>();
    ServicesServer::getInstance()->addProcessFactory("statCorrelation", factProcessCorrelation);
    ServicesServer::getInstance()->linkProcessWithPlugin("statCorrelation", pluginPath);
74a11471   Benjamin Renard   Add min, max, var...
80
}