QGIS API Documentation  3.18.1-Zürich (202f1bf7e5)
Public Slots | Public Member Functions | List of all members
QgsQueryResultModel Class Reference

The QgsQueryResultModel class is a model for QgsAbstractDatabaseProviderConnection::QueryResult. More...

#include <qgsqueryresultmodel.h>

Inheritance diagram for QgsQueryResultModel:
Inheritance graph
[legend]

Public Slots

void cancel ()
 Cancels the row fetching. More...
 
void rowsReady (const QList< QList< QVariant > > &rows)
 Triggered when newRows have been fetched and can be added to the model. More...
 

Public Member Functions

 QgsQueryResultModel (const QgsAbstractDatabaseProviderConnection::QueryResult &queryResult, QObject *parent=nullptr)
 Constructs a QgsQueryResultModel from a queryResult with optional parent. More...
 
 ~QgsQueryResultModel ()
 
int columnCount (const QModelIndex &parent) const override
 
QVariant data (const QModelIndex &index, int role) const override
 
QVariant headerData (int section, Qt::Orientation orientation, int role) const override
 
int rowCount (const QModelIndex &parent) const override
 

Detailed Description

The QgsQueryResultModel class is a model for QgsAbstractDatabaseProviderConnection::QueryResult.

Since
QGIS 3.18

Definition at line 76 of file qgsqueryresultmodel.h.

Constructor & Destructor Documentation

◆ QgsQueryResultModel()

QgsQueryResultModel::QgsQueryResultModel ( const QgsAbstractDatabaseProviderConnection::QueryResult queryResult,
QObject *  parent = nullptr 
)

Constructs a QgsQueryResultModel from a queryResult with optional parent.

Definition at line 18 of file qgsqueryresultmodel.cpp.

◆ ~QgsQueryResultModel()

QgsQueryResultModel::~QgsQueryResultModel ( )

Definition at line 49 of file qgsqueryresultmodel.cpp.

Member Function Documentation

◆ cancel

void QgsQueryResultModel::cancel ( )
slot

Cancels the row fetching.

Definition at line 41 of file qgsqueryresultmodel.cpp.

◆ columnCount()

int QgsQueryResultModel::columnCount ( const QModelIndex &  parent) const
override

Definition at line 67 of file qgsqueryresultmodel.cpp.

◆ data()

QVariant QgsQueryResultModel::data ( const QModelIndex &  index,
int  role 
) const
override

Definition at line 74 of file qgsqueryresultmodel.cpp.

◆ headerData()

QVariant QgsQueryResultModel::headerData ( int  section,
Qt::Orientation  orientation,
int  role 
) const
override

Definition at line 95 of file qgsqueryresultmodel.cpp.

◆ rowCount()

int QgsQueryResultModel::rowCount ( const QModelIndex &  parent) const
override

Definition at line 60 of file qgsqueryresultmodel.cpp.

◆ rowsReady

void QgsQueryResultModel::rowsReady ( const QList< QList< QVariant > > &  rows)
slot

Triggered when newRows have been fetched and can be added to the model.

Definition at line 34 of file qgsqueryresultmodel.cpp.


The documentation for this class was generated from the following files: