QGIS API Documentation  3.14.0-Pi (9f7028fd23)
Public Types | Public Member Functions | Public Attributes | List of all members
QgsStoredExpression Struct Reference

#include <qgsstoredexpressionmanager.h>

Public Types

enum  Category { FilterExpression = 1 << 0, DefaultValueExpression = 1 << 1, All = FilterExpression | DefaultValueExpression }
 Categories of use cases FilterExpression for stored expressions to filter attribute table DefaultValueExpression for stored expressions to use for default values (not yet used) More...
 

Public Member Functions

 QgsStoredExpression ()=default
 Constructor for QgsStoredExpression. More...
 
 QgsStoredExpression (QString name, QString expression, Category tag=Category::FilterExpression)
 Create a new QgsStoredExpression with a generated uuid as id. More...
 

Public Attributes

QString expression
 expression text More...
 
QString id
 generated uuid used for identification More...
 
QString name
 descriptive name of the expression More...
 
Category tag
 category of the expression use case More...
 

Detailed Description

Stored expression containing name, content (expression text) and a category tag.

Since
QGIS 3.10

Definition at line 41 of file qgsstoredexpressionmanager.h.

Member Enumeration Documentation

◆ Category

Categories of use cases FilterExpression for stored expressions to filter attribute table DefaultValueExpression for stored expressions to use for default values (not yet used)

Enumerator
FilterExpression 

Expressions to filter features.

DefaultValueExpression 

Expressions to determine default values (not yet used)

All 

Definition at line 49 of file qgsstoredexpressionmanager.h.

Constructor & Destructor Documentation

◆ QgsStoredExpression() [1/2]

QgsStoredExpression::QgsStoredExpression ( )
default

Constructor for QgsStoredExpression.

◆ QgsStoredExpression() [2/2]

QgsStoredExpression::QgsStoredExpression ( QString  name,
QString  expression,
Category  tag = Category::FilterExpression 
)
inline

Create a new QgsStoredExpression with a generated uuid as id.

Parameters
namedescriptive name of the expression
expressionexpression text
tagcategory of the expression use case - default FilterExpression

Definition at line 70 of file qgsstoredexpressionmanager.h.

Member Data Documentation

◆ expression

QString QgsStoredExpression::expression

expression text

Definition at line 83 of file qgsstoredexpressionmanager.h.

◆ id

QString QgsStoredExpression::id

generated uuid used for identification

Definition at line 79 of file qgsstoredexpressionmanager.h.

◆ name

QString QgsStoredExpression::name

descriptive name of the expression

Definition at line 81 of file qgsstoredexpressionmanager.h.

◆ tag

Category QgsStoredExpression::tag

category of the expression use case

Definition at line 85 of file qgsstoredexpressionmanager.h.


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