<% const properties = locals.properties; -%> // This file is generated. Edit android/platform/scripts/generate-style-code.js, then run `make android-style-code`. #pragma once #include #include #include namespace mbgl { namespace android { namespace conversion { // visibility inline std::string toString(mbgl::style::VisibilityType value) { switch (value) { case mbgl::style::VisibilityType::Visible: return "visible"; break; case mbgl::style::VisibilityType::None: return "none"; break; default: throw std::runtime_error("Not implemented"); } } <% for (const property of properties) { -%> // <%- property.name %> inline std::string toString(mbgl::style::<%- propertyNativeType(property) %> value) { switch (value) { <% for (const value in property.values) { -%> case mbgl::style::<%- propertyNativeType(property) %>::<%- camelize(value) %>: return "<%- value %>"; break; <% } -%> default: throw std::runtime_error("Not implemented"); } } <% } -%> } // namespace conversion } // namespace android } // namespace mbgl