Version: 9.12.0
QtxPopupSelection Class Referenceabstract

This class is a part of the popup menu management system. More...

#include <QtxPopupMgr.h>

Inheritance diagram for QtxPopupSelection:
Inheritance graph

Public Member Functions

 QtxPopupSelection ()
 Constructor. More...
 
virtual ~QtxPopupSelection ()
 Destructor. More...
 
virtual int count () const =0
 Get number of the selected objects. More...
 
virtual QVariant parameter (const QString &) const
 Get the parameter value. More...
 
virtual QVariant parameter (const int, const QString &) const =0
 Get value of the parameter which is of list type. More...
 
QString option (const QString &) const
 Get an option value. More...
 
void setOption (const QString &, const QString &)
 Set an option value. More...
 
QtxPopupMgrpopupMgr () const
 
void setPopupMgr (QtxPopupMgr *)
 

Private Types

typedef QMap< QString, QString > OptionsMap
 
typedef QPointer< QtxPopupMgrPopupMgrPtr
 

Private Member Functions

QString equalityParam () const
 Get symbol which detects the name of the parameter list. More...
 
QString selCountParam () const
 Get name of the parameter, specifing number of selected objects. More...
 

Private Attributes

OptionsMap myOptions
 
PopupMgrPtr myPopupMgr
 

Detailed Description

This class is a part of the popup menu management system.

The QtxPopupSelection class is used as back-end for getting value of each parameter found in the rule by the expression parser.

For example, it can be used for the analyzing of the currently selected objects and defining the values of the parameters used in the rules syntax expression. Rules, in their turn, define each action state - visibility, enabled and toggled state.

Member Typedef Documentation

◆ OptionsMap

typedef QMap<QString, QString> QtxPopupSelection::OptionsMap
private

◆ PopupMgrPtr

typedef QPointer<QtxPopupMgr> QtxPopupSelection::PopupMgrPtr
private

Constructor & Destructor Documentation

◆ QtxPopupSelection()

QtxPopupSelection::QtxPopupSelection ( )

Constructor.

◆ ~QtxPopupSelection()

QtxPopupSelection::~QtxPopupSelection ( )
virtual

Destructor.

Member Function Documentation

◆ count()

int QtxPopupSelection::count ( ) const
pure virtual

Get number of the selected objects.

Returns
nb of selected objects

Implemented in LightApp_Selection.

◆ equalityParam()

QString QtxPopupSelection::equalityParam ( ) const
private

Get symbol which detects the name of the parameter list.

Returns
equality symbol (by default, "$")

References option().

◆ option()

QString QtxPopupSelection::option ( const QString &  optName) const

Get an option value.

Parameters
optNameoption name
Returns
option value or empty string if option is not found

References myOptions.

◆ parameter() [1/2]

QVariant QtxPopupSelection::parameter ( const int  idx,
const QString &  name 
) const
pure virtual

Get value of the parameter which is of list type.

Parameters
idxparameter index
nameparameter name
Returns
parameter value

Implemented in LightApp_Selection.

◆ parameter() [2/2]

QVariant QtxPopupSelection::parameter ( const QString &  str) const
virtual

Get the parameter value.

Parameters
strparameter name
Returns
parameter value

Reimplemented in LightApp_Selection.

References QtxEvalSetSets::add(), count(), equalityParam(), QtxPopupMgr::parameter(), popupMgr(), and selCountParam().

◆ popupMgr()

QtxPopupMgr * QtxPopupSelection::popupMgr ( ) const

References myPopupMgr.

◆ selCountParam()

QString QtxPopupSelection::selCountParam ( ) const
private

Get name of the parameter, specifing number of selected objects.

Returns
parameter name (by default, "selcount")

References option().

◆ setOption()

void QtxPopupSelection::setOption ( const QString &  optName,
const QString &  opt 
)

Set an option value.

Parameters
optNameoption name
optoption value

References myOptions.

◆ setPopupMgr()

void QtxPopupSelection::setPopupMgr ( QtxPopupMgr pm)

References myPopupMgr.

Member Data Documentation

◆ myOptions

OptionsMap QtxPopupSelection::myOptions
private

◆ myPopupMgr

PopupMgrPtr QtxPopupSelection::myPopupMgr
private

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