ngc 1.5.0
 
Loading...
Searching...
No Matches
ngcdcsEDDM.hpp
Go to the documentation of this file.
1
8#ifndef ngcdcsEDDM_H
9#define ngcdcsEDDM_H
10
11
12#ifndef __cplusplus
13#error This is a C++ include file and cannot be used from plain C
14#endif
15
16#include <ngc/core/ngcbOBJ.hpp>
18
22class ngcdcsEDDM: public ngcbOBJ
23{
24public:
27
29 ngcdcsEDDM &operator=(const ngcdcsEDDM &other);
30
32 ngcdcsEDDM(const ngcdcsEDDM &other);
33
35 ngcdcsEDDM();
36
38 explicit ngcdcsEDDM(size_t maxDrv);
39
41 virtual ~ngcdcsEDDM();
42
44 int Register(ngcdcsFACTORY *f);
45
47 int Register(const char *name);
48
51
53 void *Unregister(const char *module);
54
57
60
62 ngcdcsFACTORY *Factory(const char *name);
63
65 ngcdcsFACTORY *Factory(const char *symbol, const char *module);
66
68 ngcdcsFACTORY *Select(const char *name);
69
71 ngcdcsFACTORY *Module(const char *module);
72
74 int Load(const char *module, const char *name = NULL);
75
77 int Unload(const char *name, const char *symbol = NULL);
78
80 int Unload();
81
83 void List(char *s);
84
86 void ModList(char *s);
87
88protected:
89private:
91 void Init_(size_t maxDrv);
92
94 size_t maxDrv_;
95
97 size_t ndrv_;
98
100 ngcdcsFACTORY **factory_;
101
103 ngcdcsFACTORY *current_;
104
106 void RemoveParam_(const char *module);
107
109 ssize_t GetSlot_(const char *name);
110};
111
112#endif
ngcbOBJ()
Constructor.
Definition ngcbOBJ.cpp:35
Definition ngcbPARAM.hpp:201
int Unload()
Unload all external exposure driver modules.
Definition ngcdcsEDDM.cpp:756
void ModList(char *s)
Copy list of driver module names to string.
Definition ngcdcsEDDM.cpp:473
ngcdcsFACTORY * Factory()
Return current factory.
Definition ngcdcsEDDM.cpp:318
virtual ~ngcdcsEDDM()
Destructor.
Definition ngcdcsEDDM.cpp:36
int Load(const char *module, const char *name=NULL)
Load external exposure driver module.
Definition ngcdcsEDDM.cpp:491
ngcdcsEDDM()
Constructor.
Definition ngcdcsEDDM.cpp:30
ngcdcsFACTORY * Next()
Return next dynamically loaded driver factory.
Definition ngcdcsEDDM.cpp:320
int Register(ngcdcsFACTORY *f)
Register a new factory.
Definition ngcdcsEDDM.cpp:147
ngcdcsFACTORY * Select(const char *name)
Select factory associated to driver name.
Definition ngcdcsEDDM.cpp:406
void List(char *s)
Copy list of driver factory names to string.
Definition ngcdcsEDDM.cpp:457
ngcbPARAM_LIST * paramList
Parameter list, from which modules need to detach during unload.
Definition ngcdcsEDDM.hpp:26
int Unregister(ngcdcsFACTORY *f)
Unregister factory.
Definition ngcdcsEDDM.cpp:201
ngcdcsEDDM(const ngcdcsEDDM &other)
Copy constructor.
Definition ngcdcsEDDM.cpp:34
ngcdcsEDDM & operator=(const ngcdcsEDDM &other)
Operator =.
Definition ngcdcsEDDM.cpp:24
ngcdcsFACTORY * Module(const char *module)
Select factory by module name.
Definition ngcdcsEDDM.cpp:432
Definition ngcdcsFACTORY.hpp:46