00001 00004 #ifndef BPSGAUGEPLUGIN_H 00005 #define BPSGAUGEPLUGIN_H 00006 00007 #include "bpsgui_global.h" 00008 #include "bpsgauge.h" 00009 #include <QtPlugin> 00010 #include <QMap> 00011 00012 class BpsDatastore; 00013 class BpsConfigWidget; 00014 class BpsGaugeEditWidget; 00015 class BpsSettings; 00016 00021 class BPSGUI_EXPORT BpsGaugePlugin 00022 { 00023 public: 00027 virtual ~BpsGaugePlugin() {}; 00028 00032 virtual QString gaugeId() const = 0; 00033 00037 virtual QString gaugeName() const = 0; 00038 00042 virtual BpsGauge::Unit gaugeUnit() const = 0; 00043 00049 virtual bool check(BpsDatastore* aDatastore) const = 0; 00050 00058 virtual BpsConfigWidget* createConfigWidget(BpsDatastore* aDatastore, QWidget* aParent = 0) const = 0; 00059 00066 virtual BpsGauge* createGauge(BpsDatastore* aDatastore, QObject* aParent = 0) const = 0; 00067 00073 static QList<BpsGaugePlugin*> plugins(BpsDatastore* aDatastore); 00074 00081 static BpsGaugePlugin* plugin(BpsDatastore* aDatastore, const QString& aId); 00082 }; 00083 00084 Q_DECLARE_INTERFACE(BpsGaugePlugin, "com.ibk-software.BPS2.BpsGaugePlugin/1.0") 00085 00086 #endif // BPSGAUGEPLUGIN_H