QGIS API Documentation
4.3.0-Master (52aa6503bed)
Toggle main menu visibility
Loading...
Searching...
No Matches
src
core
actions
qgsactionscope.h
Go to the documentation of this file.
1
/***************************************************************************
2
qgsactionscope.h - QgsActionScope
3
4
---------------------
5
begin : 1.11.2016
6
copyright : (C) 2016 by Matthias Kuhn
7
email : matthias@opengis.ch
8
***************************************************************************
9
* *
10
* This program is free software; you can redistribute it and/or modify *
11
* it under the terms of the GNU General Public License as published by *
12
* the Free Software Foundation; either version 2 of the License, or *
13
* (at your option) any later version. *
14
* *
15
***************************************************************************/
16
#ifndef QGSACTIONSCOPE_H
17
#define QGSACTIONSCOPE_H
18
19
#include "qgis_core.h"
20
#include "
qgsexpressioncontext.h
"
21
22
#include <QString>
23
49
class
CORE_EXPORT
QgsActionScope
50
{
51
public
:
52
#ifdef SIP_RUN
53
// clang-format off
54
% TypeCode
55
#include <QHash>
56
% End
57
// clang-format on
58
#endif
59
64
explicit
QgsActionScope
();
65
71
explicit
QgsActionScope
(
const
QString &
id
,
const
QString &
title
,
const
QString &
description
,
const
QgsExpressionContextScope
&
expressionContextScope
=
QgsExpressionContextScope
() );
72
73
bool
operator==
(
const
QgsActionScope
&other )
const
;
74
84
QgsExpressionContextScope
expressionContextScope
()
const
;
85
95
void
setExpressionContextScope
(
const
QgsExpressionContextScope
&
expressionContextScope
);
96
102
QString
id
()
const
;
103
109
void
setId
(
const
QString &
id
);
110
119
QString
title
()
const
;
120
129
void
setTitle
(
const
QString &
title
);
130
140
QString
description
()
const
;
141
151
void
setDescription
(
const
QString &
description
);
152
156
bool
isValid
()
const
;
157
158
// clang-format off
159
#ifdef SIP_RUN
160
long
__hash__();
161
% MethodCode
162
sipRes =
qHash
( *sipCpp );
163
% End
164
#endif
165
166
private
:
167
// clang-format on
168
QString mId;
169
QString mTitle;
170
QString mDescription;
171
QgsExpressionContextScope
mExpressionContextScope;
172
};
173
174
CORE_EXPORT
size_t
qHash
(
const
QgsActionScope
&key,
size_t
seed = 0 )
SIP_SKIP
;
175
176
#endif
// QGSACTIONSCOPE_H
QgsActionScope
An action scope defines a "place" for an action to be shown and may add additional expression variabl...
Definition
qgsactionscope.h:50
QgsActionScope::QgsActionScope
QgsActionScope()
Creates a new invalid action scope.
Definition
qgsactionscope.cpp:20
QgsActionScope::setTitle
void setTitle(const QString &title)
Sets the action scope's title.
Definition
qgsactionscope.cpp:66
QgsActionScope::description
QString description() const
Returns the action scope's description.
Definition
qgsactionscope.cpp:71
QgsActionScope::setDescription
void setDescription(const QString &description)
Sets the action scope's description.
Definition
qgsactionscope.cpp:76
QgsActionScope::expressionContextScope
QgsExpressionContextScope expressionContextScope() const
Returns the expression context scope for the action scope.
Definition
qgsactionscope.cpp:36
QgsActionScope::id
QString id() const
Returns the unique identifier for this action scope.
Definition
qgsactionscope.cpp:46
QgsActionScope::setId
void setId(const QString &id)
Sets the unique id for this action scope.
Definition
qgsactionscope.cpp:51
QgsActionScope::title
QString title() const
Returns the action scope's title.
Definition
qgsactionscope.cpp:61
QgsActionScope::isValid
bool isValid() const
Returns true if this scope is valid.
Definition
qgsactionscope.cpp:56
QgsActionScope::setExpressionContextScope
void setExpressionContextScope(const QgsExpressionContextScope &expressionContextScope)
Sets the expression context scope for the action scope.
Definition
qgsactionscope.cpp:41
QgsExpressionContextScope
Single scope for storing variables and functions for use within a QgsExpressionContext.
Definition
qgsexpressioncontext.h:119
qHash
size_t qHash(const QVariant &variant)
Hash for QVariant.
Definition
qgis.cpp:611
SIP_SKIP
#define SIP_SKIP
Definition
qgis_sip.h:138
qHash
CORE_EXPORT size_t qHash(const QgsActionScope &key, size_t seed=0)
Definition
qgsactionscope.cpp:81
qgsexpressioncontext.h
operator==
bool operator==(const QgsFeatureIterator &fi1, const QgsFeatureIterator &fi2)
Definition
qgsfeatureiterator.h:427
Generated on
for QGIS API Documentation by
1.17.0