GemaCoreLib
The GeMA Core library
gmPluginObjectFactory.h
Go to the documentation of this file.
1 /************************************************************************
2 **
3 ** Copyright (C) 2014 by Carlos Augusto Teixera Mendes
4 ** All rights reserved.
5 **
6 ** This file is part of the "GeMA" software. It's use should respect
7 ** the terms in the license agreement that can be found together
8 ** with this source code.
9 ** It is provided AS IS, with NO WARRANTY OF ANY KIND,
10 ** INCLUDING THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR
11 ** A PARTICULAR PURPOSE.
12 **
13 ************************************************************************/
14 
24 #ifndef _GEMA_PLUGIN_OBJECT_FACTORY_H_
25 #define _GEMA_PLUGIN_OBJECT_FACTORY_H_
26 
27 #include <QtPlugin>
28 
29 #include "gmLog.h"
30 
31 class QString;
32 class GmSimulationData;
33 class GmPluginObject;
34 
37 {
38 public:
40 
41  virtual ~GmPluginObjectFactory();
42 
60  virtual GmPluginObject* instance(QString category, QString objType, GmSimulationData* simulation, QString id, QString description) = 0;
61 
74  virtual const QStringList& versionInfo() const = 0;
75 
84  virtual const QStringList& depVersionInfo() const = 0;
85 
86 protected:
90  const GmLogCategory& logger() { return _logger; }
91 
92 private:
94 };
95 
97 #define GmPluginObjectFactoryInterfaceIID "Gema.PluginFactoryInterface.1.1"
98 
101 
102 #endif
103 
const GmLogCategory & logger()
Returns a reference to the internal logger that should be used by every object instanciated by this f...
Definition: gmPluginObjectFactory.h:90
Factory class exported by every plugin object.
Definition: gmPluginObjectFactory.h:36
Auxiliar class used to store the complete set of simulation data.
Definition: gmSimulationData.h:51
GmLogCategory _logger
Private logger used by every object instanced by this plugin to emmit messages.
Definition: gmPluginObjectFactory.h:93
Base interface class for all object plugins.
Definition: gmPluginObject.h:36
#define GMC_API_EXPORT
Macro for controling if the class is being exported (GEMA_CORE_LIB defined) or imported (GEMA_CORE_LI...
Definition: gmCoreConfig.h:35
Class representing a category with multiple logging levels.
Definition: gmLog.h:58
#define GmPluginObjectFactoryInterfaceIID
Macro used to identify this interface (and version)
Definition: gmPluginObjectFactory.h:97
Declaration of support functions and macros for information logging.