eVaf
pluginmanager.h
Go to the documentation of this file.
1 
19 #ifndef __PLUGINS_PLUGINMANAGER_H
20 #define __PLUGINS_PLUGINMANAGER_H
21 
22 #include "libplugins.h"
23 
24 #include <version_rc.h>
25 
26 #include <QObject>
27 #include <QString>
28 
29 namespace eVaf {
30 
41 namespace Plugins {
42 
46 namespace Internal {
48 }
49 
58 inline QString expandPluginName(QString const & name)
59 {
60 #ifdef Q_OS_WIN32
61 # ifdef Q_CC_MINGW
62  return "lib" + name + ".dll";
63 # else
64  return name + ".dll";
65 # endif
66 #elif defined Q_OS_LINUX
67  return "lib" + name + ".so";
68 #elif defined Q_OS_CYGWIN
69  return "cyg" + name + ".dll";
70 #else
71  return name;
72 #endif
73 }
74 
79 {
80  Q_OBJECT
81 
82 public:
83 
85  PluginManager();
86 
88  virtual ~PluginManager();
89 
93  static PluginManager * instance();
94 
102  bool init();
103 
110  void done();
111 
112 
113 signals:
114 
120  void pluginsLoaded();
121 
127  void pluginsUnloaded();
128 
129 
130 private:
131 
133 
134 };
135 
136 } // namespace eVaf::Plugins
137 } // namespace eVaf
138 
139 #endif // pluginmanager.h
Internal implementation of the plugin manager.
QString expandPluginName(QString const &name)
Expands plugin names for the selected platform.
Definition: pluginmanager.h:58
Plugin manager for eVaf applications.
Definition: pluginmanager.h:78
bool COMMON_EXPORT init()
eVaf common library initialized
Global version information for eVaf applications and modules.
#define PLUGINS_EXPORT
Definition: libplugins.h:27
Global eVaf namespace.
Definition: engine.h:37