QgsSQLComposerDialog class
SQL composer dialog.
Contents
Public types
- struct Argument
- argument of a function
- struct Function
- description of server functions
- class SQLValidatorCallback
- Callback to do validation check on dialog validation.
- class TableSelectedCallback
- Callback to do actions on table selection.
- using PairNameTitle = QPair<QString, QString>
- pair (name, title)
- using PairNameType = QPair<QString, QString>
- pair (name, type)
Constructors, destructors, conversion operators
- QgsSQLComposerDialog(QWidget* parent = nullptr, Qt::WindowFlags fl = QgsGuiUtils::ModalDialogFlags) explicit
- constructor
Public functions
- void addApis(const QStringList& list)
- add a list of API for autocompletion
- void addColumnNames(const QStringList& list, const QString& tableName)
- add a list of column names
- void addColumnNames(const QList<PairNameType>& list, const QString& tableName)
- add a list of column names
- void addFunctions(const QStringList& list)
- add a list of functions
- void addFunctions(const QList<Function>& list)
- add a list of functions
- void addOperators(const QStringList& list)
- add a list of operators
- void addSpatialPredicates(const QStringList& list)
- add a list of spatial predicates
- void addSpatialPredicates(const QList<Function>& list)
- add a list of spatial predicates
- void addTableNames(const QStringList& list)
- add a list of table names
- void addTableNames(const QList<PairNameTitle>& listNameTitle)
- add a list of table names
- void setSql(const QString& sql)
- initialize the SQL statement
- void setSQLValidatorCallback(SQLValidatorCallback* sqlValidatorCallback)
- Set a callback that will be called when the OK button is pushed.
- void setSupportMultipleTables(bool bMultipleTables, const QString& mainTypename = QString())
- Sets if multiple tables/joins are supported. Default is false.
- void setTableSelectedCallback(TableSelectedCallback* tableSelectedCallback)
- Set a callback that will be called when a new table is selected, so that new column names can be added typically.
- auto sql() const -> QString
- Gets the SQL statement.
Function documentation
void QgsSQLComposerDialog:: setSQLValidatorCallback(SQLValidatorCallback* sqlValidatorCallback)
Set a callback that will be called when the OK button is pushed.
Ownership of the callback remains to the caller
void QgsSQLComposerDialog:: setTableSelectedCallback(TableSelectedCallback* tableSelectedCallback)
Set a callback that will be called when a new table is selected, so that new column names can be added typically.
Ownership of the callback remains to the caller