summaryrefslogtreecommitdiff
path: root/include/mbgl
diff options
context:
space:
mode:
authorMikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com>2018-11-06 16:48:18 +0200
committerMikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com>2018-11-07 16:34:20 +0200
commit5a70f2b15081bede66a2d736dc3e8f90ba73d601 (patch)
treeea4ac754f100303760c0120e25474eaba0ab7b66 /include/mbgl
parent1ba1ead3eab5eb27c24163b93b04b49ffbdf2a3b (diff)
downloadqtlocation-mapboxgl-5a70f2b15081bede66a2d736dc3e8f90ba73d601.tar.gz
noexcept specifier for layer factory methods
Diffstat (limited to 'include/mbgl')
-rw-r--r--include/mbgl/style/layer.hpp10
-rw-r--r--include/mbgl/style/layers/background_layer.hpp4
-rw-r--r--include/mbgl/style/layers/circle_layer.hpp4
-rw-r--r--include/mbgl/style/layers/custom_layer.hpp4
-rw-r--r--include/mbgl/style/layers/fill_extrusion_layer.hpp4
-rw-r--r--include/mbgl/style/layers/fill_layer.hpp4
-rw-r--r--include/mbgl/style/layers/heatmap_layer.hpp4
-rw-r--r--include/mbgl/style/layers/hillshade_layer.hpp4
-rw-r--r--include/mbgl/style/layers/layer.hpp.ejs4
-rw-r--r--include/mbgl/style/layers/line_layer.hpp4
-rw-r--r--include/mbgl/style/layers/raster_layer.hpp4
-rw-r--r--include/mbgl/style/layers/symbol_layer.hpp4
12 files changed, 27 insertions, 27 deletions
diff --git a/include/mbgl/style/layer.hpp b/include/mbgl/style/layer.hpp
index c2aaaa6f48..1e1e97dd0d 100644
--- a/include/mbgl/style/layer.hpp
+++ b/include/mbgl/style/layer.hpp
@@ -98,13 +98,13 @@ class LayerFactory {
public:
virtual ~LayerFactory() = default;
/// Returns \c true if this factory can produce layers of the given type of the layers; returns \c false otherwise.
- virtual bool supportsType(const std::string& type) const = 0;
+ virtual bool supportsType(const std::string& type) const noexcept = 0;
/// Returns a new Layer instance on success call; returns `nulltptr` otherwise.
virtual std::unique_ptr<Layer> createLayer(const std::string& id, const conversion::Convertible& value) = 0;
protected:
- optional<std::string> getSource(const conversion::Convertible& value) const;
- bool initSourceLayerAndFilter(Layer*, const conversion::Convertible& value) const;
+ optional<std::string> getSource(const conversion::Convertible& value) const noexcept;
+ bool initSourceLayerAndFilter(Layer*, const conversion::Convertible& value) const noexcept;
};
/**
@@ -117,11 +117,11 @@ public:
*
* @return LayerManager*
*/
- static LayerManager* get();
+ static LayerManager* get() noexcept;
virtual ~LayerManager() = default;
/// Returns a new Layer instance on success call; returns `nulltptr` otherwise.
- virtual std::unique_ptr<Layer> createLayer(const std::string& type, const std::string& id, const conversion::Convertible& value, conversion::Error& error) = 0;
+ virtual std::unique_ptr<Layer> createLayer(const std::string& type, const std::string& id, const conversion::Convertible& value, conversion::Error& error) noexcept = 0;
protected:
LayerManager() = default;
diff --git a/include/mbgl/style/layers/background_layer.hpp b/include/mbgl/style/layers/background_layer.hpp
index 61e95d2273..639cb5154c 100644
--- a/include/mbgl/style/layers/background_layer.hpp
+++ b/include/mbgl/style/layers/background_layer.hpp
@@ -61,10 +61,10 @@ public:
BackgroundLayerFactory();
// LayerFactory overrides.
~BackgroundLayerFactory() override;
- bool supportsType(const std::string& type) const final;
+ bool supportsType(const std::string& type) const noexcept final;
std::unique_ptr<style::Layer> createLayer(const std::string& id, const conversion::Convertible& value) final;
- static BackgroundLayerFactory* get();
+ static BackgroundLayerFactory* get() noexcept;
private:
static BackgroundLayerFactory* instance;
diff --git a/include/mbgl/style/layers/circle_layer.hpp b/include/mbgl/style/layers/circle_layer.hpp
index 92a6bbd92e..4c134a58bf 100644
--- a/include/mbgl/style/layers/circle_layer.hpp
+++ b/include/mbgl/style/layers/circle_layer.hpp
@@ -109,10 +109,10 @@ public:
CircleLayerFactory();
// LayerFactory overrides.
~CircleLayerFactory() override;
- bool supportsType(const std::string& type) const final;
+ bool supportsType(const std::string& type) const noexcept final;
std::unique_ptr<style::Layer> createLayer(const std::string& id, const conversion::Convertible& value) final;
- static CircleLayerFactory* get();
+ static CircleLayerFactory* get() noexcept;
private:
static CircleLayerFactory* instance;
diff --git a/include/mbgl/style/layers/custom_layer.hpp b/include/mbgl/style/layers/custom_layer.hpp
index f58e41adf5..0d13001b91 100644
--- a/include/mbgl/style/layers/custom_layer.hpp
+++ b/include/mbgl/style/layers/custom_layer.hpp
@@ -90,10 +90,10 @@ public:
CustomLayerFactory();
// LayerFactory overrides.
~CustomLayerFactory() override;
- bool supportsType(const std::string& type) const final;
+ bool supportsType(const std::string& type) const noexcept final;
std::unique_ptr<style::Layer> createLayer(const std::string& id, const conversion::Convertible& value) final;
- static CustomLayerFactory* get();
+ static CustomLayerFactory* get() noexcept;
private:
static CustomLayerFactory* instance;
diff --git a/include/mbgl/style/layers/fill_extrusion_layer.hpp b/include/mbgl/style/layers/fill_extrusion_layer.hpp
index bc761f2bec..621eb45bc4 100644
--- a/include/mbgl/style/layers/fill_extrusion_layer.hpp
+++ b/include/mbgl/style/layers/fill_extrusion_layer.hpp
@@ -85,10 +85,10 @@ public:
FillExtrusionLayerFactory();
// LayerFactory overrides.
~FillExtrusionLayerFactory() override;
- bool supportsType(const std::string& type) const final;
+ bool supportsType(const std::string& type) const noexcept final;
std::unique_ptr<style::Layer> createLayer(const std::string& id, const conversion::Convertible& value) final;
- static FillExtrusionLayerFactory* get();
+ static FillExtrusionLayerFactory* get() noexcept;
private:
static FillExtrusionLayerFactory* instance;
diff --git a/include/mbgl/style/layers/fill_layer.hpp b/include/mbgl/style/layers/fill_layer.hpp
index 7ef6727691..aeb0ba988a 100644
--- a/include/mbgl/style/layers/fill_layer.hpp
+++ b/include/mbgl/style/layers/fill_layer.hpp
@@ -85,10 +85,10 @@ public:
FillLayerFactory();
// LayerFactory overrides.
~FillLayerFactory() override;
- bool supportsType(const std::string& type) const final;
+ bool supportsType(const std::string& type) const noexcept final;
std::unique_ptr<style::Layer> createLayer(const std::string& id, const conversion::Convertible& value) final;
- static FillLayerFactory* get();
+ static FillLayerFactory* get() noexcept;
private:
static FillLayerFactory* instance;
diff --git a/include/mbgl/style/layers/heatmap_layer.hpp b/include/mbgl/style/layers/heatmap_layer.hpp
index e38c6ab6e1..3630dafba9 100644
--- a/include/mbgl/style/layers/heatmap_layer.hpp
+++ b/include/mbgl/style/layers/heatmap_layer.hpp
@@ -74,10 +74,10 @@ public:
HeatmapLayerFactory();
// LayerFactory overrides.
~HeatmapLayerFactory() override;
- bool supportsType(const std::string& type) const final;
+ bool supportsType(const std::string& type) const noexcept final;
std::unique_ptr<style::Layer> createLayer(const std::string& id, const conversion::Convertible& value) final;
- static HeatmapLayerFactory* get();
+ static HeatmapLayerFactory* get() noexcept;
private:
static HeatmapLayerFactory* instance;
diff --git a/include/mbgl/style/layers/hillshade_layer.hpp b/include/mbgl/style/layers/hillshade_layer.hpp
index e1e9a4d0a1..a251956d01 100644
--- a/include/mbgl/style/layers/hillshade_layer.hpp
+++ b/include/mbgl/style/layers/hillshade_layer.hpp
@@ -79,10 +79,10 @@ public:
HillshadeLayerFactory();
// LayerFactory overrides.
~HillshadeLayerFactory() override;
- bool supportsType(const std::string& type) const final;
+ bool supportsType(const std::string& type) const noexcept final;
std::unique_ptr<style::Layer> createLayer(const std::string& id, const conversion::Convertible& value) final;
- static HillshadeLayerFactory* get();
+ static HillshadeLayerFactory* get() noexcept;
private:
static HillshadeLayerFactory* instance;
diff --git a/include/mbgl/style/layers/layer.hpp.ejs b/include/mbgl/style/layers/layer.hpp.ejs
index 6006352eee..d335829efb 100644
--- a/include/mbgl/style/layers/layer.hpp.ejs
+++ b/include/mbgl/style/layers/layer.hpp.ejs
@@ -77,10 +77,10 @@ public:
<%- camelize(type) %>LayerFactory();
// LayerFactory overrides.
~<%- camelize(type) %>LayerFactory() override;
- bool supportsType(const std::string& type) const final;
+ bool supportsType(const std::string& type) const noexcept final;
std::unique_ptr<style::Layer> createLayer(const std::string& id, const conversion::Convertible& value) final;
- static <%- camelize(type) %>LayerFactory* get();
+ static <%- camelize(type) %>LayerFactory* get() noexcept;
private:
static <%- camelize(type) %>LayerFactory* instance;
diff --git a/include/mbgl/style/layers/line_layer.hpp b/include/mbgl/style/layers/line_layer.hpp
index de1ed8eef1..26837f4d06 100644
--- a/include/mbgl/style/layers/line_layer.hpp
+++ b/include/mbgl/style/layers/line_layer.hpp
@@ -130,10 +130,10 @@ public:
LineLayerFactory();
// LayerFactory overrides.
~LineLayerFactory() override;
- bool supportsType(const std::string& type) const final;
+ bool supportsType(const std::string& type) const noexcept final;
std::unique_ptr<style::Layer> createLayer(const std::string& id, const conversion::Convertible& value) final;
- static LineLayerFactory* get();
+ static LineLayerFactory* get() noexcept;
private:
static LineLayerFactory* instance;
diff --git a/include/mbgl/style/layers/raster_layer.hpp b/include/mbgl/style/layers/raster_layer.hpp
index 5cf06a7d98..86f57f3d12 100644
--- a/include/mbgl/style/layers/raster_layer.hpp
+++ b/include/mbgl/style/layers/raster_layer.hpp
@@ -91,10 +91,10 @@ public:
RasterLayerFactory();
// LayerFactory overrides.
~RasterLayerFactory() override;
- bool supportsType(const std::string& type) const final;
+ bool supportsType(const std::string& type) const noexcept final;
std::unique_ptr<style::Layer> createLayer(const std::string& id, const conversion::Convertible& value) final;
- static RasterLayerFactory* get();
+ static RasterLayerFactory* get() noexcept;
private:
static RasterLayerFactory* instance;
diff --git a/include/mbgl/style/layers/symbol_layer.hpp b/include/mbgl/style/layers/symbol_layer.hpp
index 5dac5925dd..685e3cb4df 100644
--- a/include/mbgl/style/layers/symbol_layer.hpp
+++ b/include/mbgl/style/layers/symbol_layer.hpp
@@ -279,10 +279,10 @@ public:
SymbolLayerFactory();
// LayerFactory overrides.
~SymbolLayerFactory() override;
- bool supportsType(const std::string& type) const final;
+ bool supportsType(const std::string& type) const noexcept final;
std::unique_ptr<style::Layer> createLayer(const std::string& id, const conversion::Convertible& value) final;
- static SymbolLayerFactory* get();
+ static SymbolLayerFactory* get() noexcept;
private:
static SymbolLayerFactory* instance;