QGIS API Documentation
3.26.3-Buenos Aires (65e4edfdad)
|
Go to the documentation of this file.
16 #ifndef QGSVECTORTILERENDERER_H
17 #define QGSVECTORTILERENDERER_H
19 #include "qgis_core.h"
56 void setFields(
const QMap<QString, QgsFields> &fields ) { mFields = fields; }
58 QMap<QString, QgsFields>
fields()
const {
return mFields; }
65 QStringList
layers()
const {
return mFeatures.keys(); }
67 QVector<QgsFeature>
layerFeatures(
const QString &layerName )
const {
return mFeatures[layerName]; }
73 QMap<QString, QgsFields> mFields;
77 QPolygon mTilePolygon;
98 const QString type = sipCpp->type();
100 if ( type == QLatin1String(
"basic" ) )
101 sipType = sipType_QgsVectorTileBasicRenderer;
111 virtual QString type()
const = 0;
133 virtual QSet< QString >
requiredLayers(
QgsRenderContext &context,
int tileZoom )
const { Q_UNUSED( context ); Q_UNUSED( tileZoom );
return QSet< QString >() << QString(); }
150 #endif // QGSVECTORTILERENDERER_H
Stores coordinates of a tile in a tile matrix set. Tile matrix is identified by the zoomLevel(),...
The class is used as a container of context for various read/write operations on other objects.
void setFields(const QMap< QString, QgsFields > &fields)
Sets per-layer fields.
Range of tiles in a tile matrix to be rendered. The selection is rectangular, given by start/end row ...
Contains information about the context of a rendering operation.
Contains decoded features of a single vector tile and any other data necessary for rendering of it.
QPolygon tilePolygon() const
Returns polygon (made out of four corners of the tile) in screen coordinates calculated from render c...
Encapsulates a QGIS project, including sets of map layers and their styles, layouts,...
QgsTileXYZ id() const
Returns coordinates of the tile.
QgsVectorTileRendererData(QgsTileXYZ id)
Constructs the object.
#define SIP_CONVERT_TO_SUBCLASS_CODE(code)
QMap< QString, QgsFields > fields() const
Returns per-layer fields.
Abstract base class for all vector tile renderer implementations.
void setFeatures(const QgsVectorTileFeatures &features)
Sets features of the tile.
virtual QMap< QString, QSet< QString > > usedAttributes(const QgsRenderContext &)
Returns field names of sub-layers that will be used for rendering. Must be called between startRender...
void setTilePolygon(QPolygon polygon)
Sets polygon of the tile.
QStringList layers() const
Returns list of layer names present in the tile.
QVector< QgsFeature > layerFeatures(const QString &layerName) const
Returns list of all features within a single sub-layer.
QgsVectorTileFeatures features() const
Returns features of the tile grouped by sub-layer names.
QMap< QString, QVector< QgsFeature > > QgsVectorTileFeatures
Features of a vector tile, grouped by sub-layer names (key of the map)
virtual void resolveReferences(const QgsProject &project)
Resolves references to other objects - second phase of loading - after readXml()
virtual QSet< QString > requiredLayers(QgsRenderContext &context, int tileZoom) const
Returns a list of the layers required for rendering.