16#ifndef QGSDEFAULTVALUE_H
17#define QGSDEFAULTVALUE_H
51 Q_PROPERTY( QString expression READ expression WRITE setExpression )
52 Q_PROPERTY(
bool applyOnUpdate READ applyOnUpdate WRITE setApplyOnUpdate )
60 explicit QgsDefaultValue(
const QString &expression = QString(),
bool applyOnUpdate =
false );
66 SIP_PYOBJECT __repr__();
68 const QString
str = sipCpp->isValid() ? QStringLiteral(
"<QgsDefaultValue: %1>" ).arg(
69 sipCpp->expression().length() > 1000 ? sipCpp->expression().left( 1000 ) + QStringLiteral(
"..." )
70 : sipCpp->expression() )
71 : QStringLiteral(
"<QgsDefaultValue: invalid>" );
72 sipRes = PyUnicode_FromString(
str.toUtf8().constData() );
80 QString expression()
const;
86 void setExpression(
const QString &expression );
92 bool applyOnUpdate()
const;
98 void setApplyOnUpdate(
bool applyOnUpdate );
104 bool isValid()
const;
114 bool mApplyOnUpdate = false;
The QgsDefaultValue class provides a container for managing client side default values for fields.
#define SIP_PYTHON_SPECIAL_BOOL(method_or_code)
Q_DECLARE_METATYPE(QgsDatabaseQueryLogEntry)
bool operator==(const QgsFeatureIterator &fi1, const QgsFeatureIterator &fi2)