#pragma once #include #include #include namespace mbgl { namespace style { class GeoJSONData; } // namespace style class RenderGeoJSONSource : public RenderSource { public: RenderGeoJSONSource(Immutable); ~RenderGeoJSONSource() final; bool isLoaded() const final; void update(Immutable, const std::vector>&, bool needsRendering, bool needsRelayout, const TileParameters&) final; void upload(gfx::UploadPass&) final; void prepare(PaintParameters&) final; void finishRender(PaintParameters&) final; std::vector> getRenderTiles() final; std::unordered_map> queryRenderedFeatures(const ScreenLineString& geometry, const TransformState& transformState, const std::vector& layers, const RenderedQueryOptions& options, const mat4& projMatrix) const final; std::vector querySourceFeatures(const SourceQueryOptions&) const final; FeatureExtensionValue queryFeatureExtensions(const Feature& feature, const std::string& extension, const std::string& extensionField, const optional>& args) const final; void reduceMemoryUse() final; void dumpDebugLogs() const final; private: const style::GeoJSONSource::Impl& impl() const; TilePyramid tilePyramid; std::weak_ptr data; }; template <> inline bool RenderSource::is() const { return baseImpl->type == style::SourceType::GeoJSON; } } // namespace mbgl