This class defines the RAG strategy to build a graph,. More...
#include <RAGGraphBuilder.h>
  
 Public Member Functions | |
| RAGGraphBuilder () | |
| Default constructor.  More... | |
| virtual | ~RAGGraphBuilder () | 
| Virtual destructor.  More... | |
Methods  | |
Methods used by this builder  | |
| bool | build (const std::string &shapeFileName, const std::string &linkColumn, const int &srid, const std::map< std::string, std::string > &dsInfo, const std::string &graphType, const std::map< std::string, std::string > &gInfo) | 
| Function used to generated the vertex id based on raster coordenate.  More... | |
Abstract Methods  | |
Method common to each graph builder  | |
| std::string | getErrorMessage () | 
| Get error message.  More... | |
| AbstractGraph * | getGraph () | 
| Get generated graph.  More... | |
Protected Member Functions | |
| bool | createEdgeObjects (const std::string &shapeFileName, const std::string &linkColumn) | 
| Function used to create all edges object based on vectorial data.  More... | |
| bool | createVertexObjects (const std::string &shapeFileName, const std::string &linkColumn, const int &srid) | 
| Function used to create all vertex object based on vectorial data.  More... | |
| std::auto_ptr< te::da::DataSet > | getDataSet (te::da::DataSource *ds) | 
| Function used to get the data set with the vectorial data.  More... | |
| std::auto_ptr< te::da::DataSource > | getDataSource (const std::string fileName) | 
| Function used to get the data source with the vectorial data.  More... | |
| int | getEdgeId () | 
| Function used to generated the edge id.  More... | |
| bool | getGeometryColumn (const std::string &shapeFileName, std::string &columnName) | 
| Function used to get the geometry column name.  More... | |
| boost::ptr_vector < te::dt::Property >  | getProperties (te::da::DataSource *ds) | 
| Function used to get the data source properties.  More... | |
Protected Attributes | |
| std::string | m_errorMessage | 
| Error message.  More... | |
| AbstractGraph * | m_graph | 
| Graph object.  More... | |
Private Attributes | |
| int | m_edgeId | 
| Attribute used as a index counter for edge objects.  More... | |
This class defines the RAG strategy to build a graph,.
This is strategy is based on adjacency of a region.
Definition at line 66 of file RAGGraphBuilder.h.
| te::graph::RAGGraphBuilder::RAGGraphBuilder | ( | ) | 
      
  | 
  virtual | 
Virtual destructor.
Definition at line 57 of file RAGGraphBuilder.cpp.
| bool te::graph::RAGGraphBuilder::build | ( | const std::string & | shapeFileName, | 
| const std::string & | linkColumn, | ||
| const int & | srid, | ||
| const std::map< std::string, std::string > & | dsInfo, | ||
| const std::string & | graphType, | ||
| const std::map< std::string, std::string > & | gInfo | ||
| ) | 
Function used to generated the vertex id based on raster coordenate.
| shapeFileName | File name wiht vectorial data | 
| linkColumn | Column name from vectorial data used as link column | 
| srid | Vectorial projection id | 
| dsInfo | Container with data source information | 
| graphType | Attribute used to define the output graph type | 
| gInfo | Container with graph generation parameters | 
Definition at line 61 of file RAGGraphBuilder.cpp.
References te::graph::AbstractGraphFactory::make().
      
  | 
  protected | 
Function used to create all edges object based on vectorial data.
| shapeFileName | File name wiht vectorial data | 
| linkColumn | Column name from vectorial data used as link column | 
Definition at line 201 of file RAGGraphBuilder.cpp.
References te::common::FreeContents(), te::gm::Geometry::getMBR(), te::sam::rtree::Index< DATATYPE, MAXNODES, MINNODES >::insert(), te::common::TaskProgress::pulse(), te::sam::rtree::Index< DATATYPE, MAXNODES, MINNODES >::search(), te::common::TaskProgress::setMessage(), and te::common::TaskProgress::setTotalSteps().
      
  | 
  protected | 
Function used to create all vertex object based on vectorial data.
| shapeFileName | File name wiht vectorial data | 
| linkColumn | Column name from vectorial data used as link column | 
| srid | Vectorial projection id | 
Definition at line 125 of file RAGGraphBuilder.cpp.
References te::graph::Vertex::addAttribute(), te::gm::CurvePolygon::getCentroid(), te::gm::Geometry::getGeomTypeId(), te::gm::MultiPolygonType, te::gm::PointType, te::gm::PolygonType, te::graph::Vertex::setAttributeVecSize(), te::gm::GeometryProperty::setGeometryType(), te::dt::Property::setId(), te::gm::GeometryProperty::setSRID(), te::gm::AbstractPoint::setSRID(), and te::gm::Geometry::setSRID().
      
  | 
  protected | 
Function used to get the data set with the vectorial data.
Definition at line 105 of file RAGGraphBuilder.cpp.
References te::da::DataSource::getDataSet(), and te::da::DataSource::getDataSetNames().
      
  | 
  protected | 
Function used to get the data source with the vectorial data.
Definition at line 93 of file RAGGraphBuilder.cpp.
References te::da::DataSourceFactory::make().
      
  | 
  protected | 
Function used to generated the edge id.
Definition at line 83 of file RAGGraphBuilder.cpp.
      
  | 
  inherited | 
Get error message.
Definition at line 13 of file AbstractGraphBuilder.cpp.
      
  | 
  protected | 
Function used to get the geometry column name.
| shapeFileName | File name wiht vectorial data | 
| columnName | Used to set the geometry column name | 
Definition at line 286 of file RAGGraphBuilder.cpp.
References te::dt::GEOMETRY_TYPE.
      
  | 
  inherited | 
Get generated graph.
Definition at line 18 of file AbstractGraphBuilder.cpp.
      
  | 
  protected | 
Function used to get the data source properties.
Definition at line 116 of file RAGGraphBuilder.cpp.
References te::da::DataSource::getDataSetNames(), and te::da::DataSource::getProperties().
      
  | 
  private | 
Attribute used as a index counter for edge objects.
Definition at line 171 of file RAGGraphBuilder.h.
Referenced by RAGGraphBuilder().
      
  | 
  protectedinherited | 
Error message.
Definition at line 85 of file AbstractGraphBuilder.h.
Referenced by te::graph::AbstractGraphBuilder::AbstractGraphBuilder().
      
  | 
  protectedinherited | 
Graph object.
Definition at line 83 of file AbstractGraphBuilder.h.
Referenced by te::graph::AbstractGraphBuilder::AbstractGraphBuilder().