QGIS API Documentation
3.16.0-Hannover (43b64b13f3)
|
Go to the documentation of this file.
19 : mExpression( expression )
20 , mApplyOnUpdate( applyOnUpdate )
27 return mExpression == other.mExpression
28 && mApplyOnUpdate == other.mApplyOnUpdate;
43 return mApplyOnUpdate;
53 return !mExpression.isEmpty();
56 QgsDefaultValue::operator bool()
const
58 return !mExpression.isEmpty();
The QgsDefaultValue class provides a container for managing client side default values for fields.
void setExpression(const QString &expression)
The expression will be evaluated whenever a default value needs to be calculated for a field.
bool isValid() const
Returns if this default value should be applied.
void setApplyOnUpdate(bool applyOnUpdate)
The applyOnUpdate flag determines if this expression should also be applied when a feature is updated...
Q_GADGET QString expression
QgsDefaultValue(const QString &expression=QString(), bool applyOnUpdate=false)
Create a new default value with the given expression and applyOnUpdate flag.
bool operator==(const QgsDefaultValue &other) const