BPS C++ API  2.24.4
BpsLabelerPlugin Class Referenceabstract

Virtual class for labeler plugin of BPS Workplace. More...

#include <bpslabelerplugin.h>

Public Member Functions

virtual bool check (BpsDatastore *aDatastore) const =0
 Check if plugin is available for usage, e.g. More...
 
virtual BpsConfigWidgetcreateConfigWidget (BpsDatastore *aDatastore, QWidget *aParent=nullptr) const =0
 Create the config widget and return a pointer to it. More...
 
virtual BpsLabelerEditWidgetcreateEditWidget (BpsDatastore *aDatastore, QWidget *aParent=nullptr) const =0
 Create the edit widget and return a pointer to it. More...
 
virtual BpsLabelercreateLabeler (BpsDatastore *aDatastore, QObject *aParent=nullptr) const =0
 Create a labeler object and return a pointer to it. More...
 
virtual QString labelerId () const =0
 
virtual QString labelerName () const =0
 
virtual ~BpsLabelerPlugin ()
 Virtual destructor.
 

Static Public Member Functions

static BpsLabelerPluginplugin (BpsDatastore *aDatastore, const QString &aId)
 Find the available labeler plugin with the given ID. More...
 
static QMap< BpsLabelerPlugin *, QVariantplugins (BpsDatastore *aDatastore)
 Get map of all labeler plugins and matching keys in table t_labelers available for usage. More...
 

Related Functions

(Note that these are not member functions.)

#define BpsLabelerPlugin_IID   "com.ibk-software.BPS2.BpsLabelerPlugin/1.0"
 IID of the plugin.
 

Detailed Description

Virtual class for labeler plugin of BPS Workplace.

Place the dynamic library in the plugins/bpslblr folder.

Member Function Documentation

◆ check()

virtual bool BpsLabelerPlugin::check ( BpsDatastore aDatastore) const
pure virtual

Check if plugin is available for usage, e.g.

its ID is present in t_labelers and it is licensed.

Parameters
aDatastoreThe datastore to use.
Returns
True when labeler plugin is available, false when not.

◆ createConfigWidget()

virtual BpsConfigWidget* BpsLabelerPlugin::createConfigWidget ( BpsDatastore aDatastore,
QWidget aParent = nullptr 
) const
pure virtual

Create the config widget and return a pointer to it.

The widget is owned by the caller.

Parameters
aDatastoreThe datastore to use.
aParentThe parent widget.
Returns
Pointer to the new widget, or 0 if labeler plugin is not available for use (see check).

◆ createEditWidget()

virtual BpsLabelerEditWidget* BpsLabelerPlugin::createEditWidget ( BpsDatastore aDatastore,
QWidget aParent = nullptr 
) const
pure virtual

Create the edit widget and return a pointer to it.

The widget is owned by the caller.

Parameters
aDatastoreThe datastore to use.
aParentThe parent for the new widget.
Returns
Pointer to the new widget, or 0 if labeler plugin is not available for use (see check).

◆ createLabeler()

virtual BpsLabeler* BpsLabelerPlugin::createLabeler ( BpsDatastore aDatastore,
QObject aParent = nullptr 
) const
pure virtual

Create a labeler object and return a pointer to it.

Parameters
aDatastoreThe datastore to use.
aParentThe parent object.
Returns
Pointer to the new object, or 0 if labeler plugin is not available for use, the settings parameters are invalid, or the labeler can not be opened.

◆ labelerId()

virtual QString BpsLabelerPlugin::labelerId ( ) const
pure virtual
Returns
The labeler ID, for example "generic" or "lm2000".

◆ labelerName()

virtual QString BpsLabelerPlugin::labelerName ( ) const
pure virtual
Returns
The labelers name in current language, for example "Generic Text" or "Leich and Mehl PAW 2000"

◆ plugin()

static BpsLabelerPlugin* BpsLabelerPlugin::plugin ( BpsDatastore aDatastore,
const QString aId 
)
static

Find the available labeler plugin with the given ID.

Parameters
aDatastoreThe datastore to use.
aIdThe labeler ID, for example "generic" or "lm2000".
Returns
The plugin, or 0 if no labeler plugin with this id was found or it is not available for use.

◆ plugins()

static QMap<BpsLabelerPlugin*,QVariant> BpsLabelerPlugin::plugins ( BpsDatastore aDatastore)
static

Get map of all labeler plugins and matching keys in table t_labelers available for usage.

Parameters
aDatastoreThe datastore to use.
Returns
List of available labeler plugins, where key is the labeler plugin and value is t_labelers.c_key.

The documentation for this class was generated from the following file: