Fire Core  8.0.0.alpha
GIS framework per tutti gli usi
 Tutto Classi Namespace Funzioni Variabili Ridefinizioni di tipo (typedef) Tipi enumerati (enum) Valori del tipo enumerato Friend
Utility.hpp
1 // Copyright 2015 GEOSYSTEMS SRL
2 // All Rights Reserved.
3 
4 #ifndef FIRE_GEAR_OP_UTILITY_HPP_INCLUDED
5 #define FIRE_GEAR_OP_UTILITY_HPP_INCLUDED
6 
7 #include <exception>
8 #include <vector>
9 
10 #include "fire/export.hpp"
11 
12 #include "fire/gear/geom/Geometry.hpp"
13 
14 namespace fire {
15 namespace gear {
16 class Group;
17 } // namespace gear
18 } // namespace fire
19 
20 namespace fire {
21 namespace gear {
22 namespace geom {
23 class Polygon;
24 } // namespace geom
25 } // namespace gear
26 } // namespace fire
27 
32 namespace fire {
37 namespace gear {
42 namespace op {
47 class FIRE_ENGINE_DLL Utility {
48  public:
90  geom::Geometry* polymerge(const std::vector< geom::Polygon* >& polys);
132  geom::Geometry* polymerge(const Group& group);
164  geom::Geometry* geometrymerge(const std::vector< geom::Geometry* >& geometries);
165  geom::Geometry* geometrymerge(std::size_t geometriesSize, geom::Geometry* geometries[]) {
166  geom::Geometry* value = NULL;
167  try {
168  std::vector< geom::Geometry* > geometriesVector;
169  for (std::size_t geometryIndex = 0 ; geometryIndex < geometriesSize ; geometryIndex++) {
170  geometriesVector.push_back(geometries[geometryIndex]);
171  }
172  value = this->geometrymerge(geometriesVector);
173  } catch (const std::exception& exception) {
174  throw;
175  }
176  return value;
177  }
206  geom::Geometry* geometrymerge(const Group& group);
207 };
208 } // namespace op
209 } // namespace gear
210 } // namespace fire
211 
212 #endif
Definition: Group.hpp:48
classe che implementa le operazioni di merge di piu' geoemtrie o piu' poligoni
Definition: Utility.hpp:47
Definition: Geometry.hpp:69