BPS C++ API  2.24.4
bpsrfidplugin.h
Go to the documentation of this file.
1 
4 #ifndef BPSRFIDPLUGIN_H
5 #define BPSRFIDPLUGIN_H
6 
7 #include "bpsgui_global.h"
8 #include <QtPlugin>
9 #include <QMap>
10 
11 class BpsDatastore;
12 class BpsConfigWidget;
13 class BpsRfid;
14 class BpsRfidEditWidget;
15 class BpsSettings;
16 
22 {
23 public:
27  virtual ~BpsRfidPlugin() {};
28 
32  virtual QString rfidId() const = 0;
33 
37  virtual QString rfidName() const = 0;
38 
44  virtual bool check(BpsDatastore* aDatastore) const = 0;
45 
53  virtual BpsConfigWidget* createConfigWidget(BpsDatastore* aDatastore, QWidget* aParent = nullptr) const = 0;
54 
61  virtual BpsRfid* createRfid(BpsDatastore* aDatastore, QObject* aParent = nullptr) const = 0;
62 
69 
76  static BpsRfidPlugin* plugin(BpsDatastore* aDatastore, const QString& aId);
77 };
78 
82 #define BpsRfidPlugin_IID "com.ibk-software.BPS2.BpsRfidPlugin/1.0"
83 
84 Q_DECLARE_INTERFACE(BpsRfidPlugin, BpsRfidPlugin_IID)
85 
86 #endif // BPSRFIDPLUGIN_H
Public include file for BPS GUI library macros.
#define BPSGUI_EXPORT
Declare class an import from the shared library.
Definition: bpsgui_global.h:22
Abstract configuration widget.
Definition: bpsconfigwidget.h:16
BPS datastore class.
Definition: bpsdatastore.h:61
RFID interface.
Definition: bpsrfid.h:19
Virtual class for RFID plugin of BPS Workplace.
Definition: bpsrfidplugin.h:22
virtual BpsRfid * createRfid(BpsDatastore *aDatastore, QObject *aParent=nullptr) const =0
Create a RFID object and return a pointer to it.
static QList< BpsRfidPlugin * > plugins(BpsDatastore *aDatastore)
Get list of all RFID plugins available for usage.
virtual BpsConfigWidget * createConfigWidget(BpsDatastore *aDatastore, QWidget *aParent=nullptr) const =0
Create the config widget and return a pointer to it.
virtual QString rfidId() const =0
#define BpsRfidPlugin_IID
IID of the plugin.
Definition: bpsrfidplugin.h:82
virtual ~BpsRfidPlugin()
Virtual destructor.
Definition: bpsrfidplugin.h:27
virtual bool check(BpsDatastore *aDatastore) const =0
Check if plugin is available for usage, e.g.
static BpsRfidPlugin * plugin(BpsDatastore *aDatastore, const QString &aId)
Find the available RFID plugin with the given ID.
virtual QString rfidName() const =0
Query and edit settings.
Definition: bpssettings.h:17