MNE-CPP  beta 1.0
pluginscenemanager.h
Go to the documentation of this file.
1 //=============================================================================================================
36 #ifndef PLUGINSCENEMANAGER_H
37 #define PLUGINSCENEMANAGER_H
38 
39 //*************************************************************************************************************
40 //=============================================================================================================
41 // INCLUDES
42 //=============================================================================================================
43 
44 #include "../mne_x_global.h"
45 #include "../Interfaces/IPlugin.h"
47 
48 
49 //*************************************************************************************************************
50 //=============================================================================================================
51 // Qt INCLUDES
52 //=============================================================================================================
53 
54 #include <QObject>
55 #include <QSharedPointer>
56 #include <QList>
57 
58 
59 //*************************************************************************************************************
60 //=============================================================================================================
61 // DEFINE NAMESPACE MNEX
62 //=============================================================================================================
63 
64 namespace MNEX
65 {
66 
67 //=========================================================================================================
74 {
75  Q_OBJECT
76 public:
77  typedef QSharedPointer<PluginSceneManager> SPtr;
78  typedef QSharedPointer<const PluginSceneManager> ConstSPtr;
80  typedef QList< IPlugin::SPtr > PluginList;
81  typedef QList<PluginConnectorConnection::SPtr> PluginConnectorConnectionList;
83  //=========================================================================================================
87  explicit PluginSceneManager(QObject *parent = 0);
88 
89  //=========================================================================================================
94 
95  //=========================================================================================================
104  bool addPlugin(const IPlugin* pPlugin, IPlugin::SPtr &pAddedPlugin);
105 
106  inline PluginList& getPlugins();
107 
108  //=========================================================================================================
116  bool removePlugin(const IPlugin::SPtr pPlugin);
117 
118  //=========================================================================================================
124  bool startPlugins();
125 
126  //=========================================================================================================
132  bool startSensorPlugins();
133 
134  //=========================================================================================================
138  void startAlgorithmPlugins();
139 
140  //=========================================================================================================
144  void startIOPlugins();
145 
146  //=========================================================================================================
150  void stopPlugins();
151 
152  //=========================================================================================================
156  void clear();
157 
158 signals:
159 
160 
161 private:
162  PluginList m_pluginList;
163  PluginConnectorConnectionList m_conConList;
165 // QSharedPointer<PluginSet> m_pPluginSet; /**< The Plugin set of the stage -> ToDo: check, if more than one set on the stage is usefull. */
166 };
167 
168 //*************************************************************************************************************
169 //=============================================================================================================
170 // INLINE DEFINITIONS
171 //=============================================================================================================
172 
173 inline PluginSceneManager::PluginList& PluginSceneManager::getPlugins()
174 {
175  return m_pluginList;
176 }
177 
178 } //Namespace
179 
180 #endif // PLUGINSCENEMANAGER_H
QSharedPointer< PluginSceneManager > SPtr
The IPlugin class is the base interface class of all plugins.
Definition: IPlugin.h:92
Contains the declaration of the PluginConnectorConnection class.
#define MNE_X_SHARED_EXPORT
Definition: mne_x_global.h:55
QSharedPointer< IPlugin > SPtr
Definition: IPlugin.h:108
QList< PluginConnectorConnection::SPtr > PluginConnectorConnectionList
QSharedPointer< const PluginSceneManager > ConstSPtr
Definition: arrow.h:75
The PluginSceneManager class manages plugins and connections of a set of plugins. ...
QList< IPlugin::SPtr > PluginList