16#ifndef QGSVECTORTILEDATAPROVIDER_H
17#define QGSVECTORTILEDATAPROVIDER_H
25#include <QReadWriteLock>
85 QgsDataProvider::ReadFlags flags );
101 virtual Qgis::VectorTileProviderFlags providerFlags()
const;
107 virtual Qgis::VectorTileProviderCapabilities providerCapabilities()
const;
132 virtual bool supportsAsync()
const;
157 virtual QVariantMap styleDefinition()
const;
165 virtual QString styleUrl()
const;
173 virtual QVariantMap spriteDefinition()
const;
180 virtual QImage spriteImage()
const;
186 virtual QString htmlMetadata()
const;
190 std::shared_ptr<QgsVectorTileDataProviderSharedData>
mShared;
RendererUsage
Usage of the renderer.
@ Unknown
Renderer used for unknown usage.
Abstract base class for spatial data provider implementations.
virtual bool renderInPreview(const QgsDataProvider::PreviewContext &context)
Returns whether the layer must be rendered in preview jobs.
virtual QgsRectangle extent() const =0
Returns the extent of the layer.
Base class for feedback objects to be used for cancellation of something running in a worker thread.
A rectangle specified with double values.
Defines a set of tile matrices for multiple zoom levels.
Stores coordinates of a tile in a tile matrix set.
Shared data class for vector tile layer data providers.
QgsVectorTileDataProviderSharedData()
void storeCachedTileData(const QgsVectorTileRawData &data)
Stores raw tile data in the shared cache.
QCache< QgsTileXYZ, QgsVectorTileRawData > mTileCache
bool getCachedTileData(QgsVectorTileRawData &data, QgsTileXYZ id)
Retrieves previously cached raw tile data for a tile with matching id.
QMutex mMutex
Access to all data members is guarded by the mutex.
Base class for vector tile layer data providers.
virtual QString sourcePath() const =0
Returns the source path for the data.
virtual QgsVectorTileDataProvider * clone() const =0
Returns a clone of the data provider.
virtual QList< QgsVectorTileRawData > readTiles(const QgsTileMatrixSet &tileMatrixSet, const QVector< QgsTileXYZ > &tiles, QgsFeedback *feedback=nullptr, Qgis::RendererUsage usage=Qgis::RendererUsage::Unknown) const =0
Returns raw tile data for a range of tiles.
QgsVectorTileDataProvider & operator=(const QgsVectorTileDataProvider &other)=delete
QgsVectorTileDataProvider cannot be assigned.
virtual const QgsVectorTileMatrixSet & tileMatrixSet() const =0
Returns the tile matrix set associated with the provider.
virtual QgsVectorTileRawData readTile(const QgsTileMatrixSet &tileMatrixSet, const QgsTileXYZ &id, QgsFeedback *feedback=nullptr) const =0
Returns raw tile data for a single tile.
std::shared_ptr< QgsVectorTileDataProviderSharedData > mShared
Mutable data shared between provider instances.
Encapsulates properties of a vector tile matrix set, including tile origins and scaling information.
Keeps track of raw tile data that need to be decoded.
Stores settings related to the context in which a preview job runs.
Setting options for creating vector data providers.