From dfdfe15853c8d858de97666433048f3daf677fee Mon Sep 17 00:00:00 2001 From: Lucio Asnaghi Date: Sun, 14 Nov 2010 14:49:42 +0000 Subject: [PATCH] + avoid usage of static string where it's not needed --- plugins/input/shape/shape.cpp | 12 +++++------- plugins/input/shape/shape.hpp | 1 - 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/plugins/input/shape/shape.cpp b/plugins/input/shape/shape.cpp index ebefad64e..219d074d2 100644 --- a/plugins/input/shape/shape.cpp +++ b/plugins/input/shape/shape.cpp @@ -137,8 +137,6 @@ void shape_datasource::bind() const shape_datasource::~shape_datasource() {} -const std::string shape_datasource::name_="shape"; - void shape_datasource::init(shape_io& shape) const { //first read header from *.shp @@ -202,6 +200,11 @@ void shape_datasource::init(shape_io& shape) const } +std::string shape_datasource::name() +{ + return "shape"; +} + int shape_datasource::type() const { return type_; @@ -213,11 +216,6 @@ layer_descriptor shape_datasource::get_descriptor() const return desc_; } -std::string shape_datasource::name() -{ - return name_; -} - featureset_ptr shape_datasource::features(const query& q) const { if (!is_bound_) bind(); diff --git a/plugins/input/shape/shape.hpp b/plugins/input/shape/shape.hpp index b820aa0bf..f1938c10d 100644 --- a/plugins/input/shape/shape.hpp +++ b/plugins/input/shape/shape.hpp @@ -64,7 +64,6 @@ private: mutable box2d extent_; mutable bool indexed_; mutable layer_descriptor desc_; - static const std::string name_; }; #endif //SHAPE_HPP