<% const type = locals.type; const layoutProperties = locals.layoutProperties; const paintProperties = locals.paintProperties; -%> // This file is generated. Do not edit. #pragma once <% if (type === 'heatmap' || type === 'line') { -%> #include <% } -%> #include #include #include #include #include <% if (type === 'line' || type === 'symbol') { -%> #include <% } -%> namespace mbgl { namespace style { class TransitionOptions; class <%- camelize(type) %>Layer : public Layer { public: <% if (type === 'background') { -%> <%- camelize(type) %>Layer(const std::string& layerID); <% } else { -%> <%- camelize(type) %>Layer(const std::string& layerID, const std::string& sourceID); <% } -%> ~<%- camelize(type) %>Layer() final; // Dynamic properties optional setLayoutProperty(const std::string& name, const conversion::Convertible& value) final; optional setPaintProperty(const std::string& name, const conversion::Convertible& value) final; <% if (layoutProperties.length) { -%> // Layout properties <% for (const property of layoutProperties) { -%> static <%- propertyValueType(property) %> getDefault<%- camelize(property.name) %>(); <%- propertyValueType(property) %> get<%- camelize(property.name) %>() const; void set<%- camelize(property.name) %>(<%- propertyValueType(property) %>); <% } -%> <% } -%> // Paint properties <% for (const property of paintProperties) { -%> static <%- propertyValueType(property) %> getDefault<%- camelize(property.name) %>(); <%- propertyValueType(property) %> get<%- camelize(property.name) %>() const; void set<%- camelize(property.name) %>(<%- propertyValueType(property) %>); void set<%- camelize(property.name) %>Transition(const TransitionOptions&); TransitionOptions get<%- camelize(property.name) %>Transition() const; <% } -%> // Private implementation class Impl; const Impl& impl() const; Mutable mutableImpl() const; <%- camelize(type) %>Layer(Immutable); std::unique_ptr cloneRef(const std::string& id) const final; protected: Mutable mutableBaseImpl() const final; }; class <%- camelize(type) %>LayerFactory : public LayerFactory { public: <%- camelize(type) %>LayerFactory(); ~<%- camelize(type) %>LayerFactory() override; // LayerFactory overrides. const LayerTypeInfo* getTypeInfo() const noexcept final; std::unique_ptr createLayer(const std::string& id, const conversion::Convertible& value) final; }; } // namespace style } // namespace mbgl