te::graph::LDDGraphBuilder Class Reference

This strategy is based on Serio Rosim method, using this "mask" is possible extract a graph from a LDD image. More...

#include <LDDGraphBuilder.h>

Inheritance diagram for te::graph::LDDGraphBuilder:
te::graph::AbstractGraphBuilder

Public Member Functions

 LDDGraphBuilder ()
 Default constructor. More...
 
virtual ~LDDGraphBuilder ()
 Virtual destructor. More...
 
Methods

Methods used by this builder

bool build (te::rst::Raster *raster, const std::map< std::string, std::string > &dsInfo, const std::string &graphType, const std::map< std::string, std::string > &gInfo)
 Function used to build the output graph based on input parameters. More...
 
Abstract Methods

Method common to each graph builder

std::string getErrorMessage ()
 Get error message. More...
 
boost::shared_ptr< AbstractGraphgetGraph ()
 Get generated graph. More...
 

Protected Member Functions

int getEdgeId ()
 Function used to generated the edge id. More...
 
bool getVertexId (int row, int col, int &id)
 Function used to generated the vertex id based on raster coordenate. More...
 

Protected Attributes

std::string m_errorMessage
 Error message. More...
 
boost::shared_ptr< AbstractGraphm_graph
 Graph object. More...
 

Private Attributes

int m_edgeId
 Attribute used as a index counter for edge objects. More...
 
te::rst::Rasterm_raster
 Input raster with LDD information. More...
 

Detailed Description

This strategy is based on Serio Rosim method, using this "mask" is possible extract a graph from a LDD image.


| 32 | 64 | 128 |

| 16 | * | 1 |

| 8 | 4 | 2 |

See also
AbstractGraphBuilder

Definition at line 75 of file LDDGraphBuilder.h.

Constructor & Destructor Documentation

te::graph::LDDGraphBuilder::LDDGraphBuilder ( )

Default constructor.

virtual te::graph::LDDGraphBuilder::~LDDGraphBuilder ( )
virtual

Virtual destructor.

Member Function Documentation

bool te::graph::LDDGraphBuilder::build ( te::rst::Raster raster,
const std::map< std::string, std::string > &  dsInfo,
const std::string &  graphType,
const std::map< std::string, std::string > &  gInfo 
)

Function used to build the output graph based on input parameters.

Parameters
raster
dsInfoContainer with data source information
graphTypeAttribute used to define the output graph type
gInfoContainer with graph generation parameters
Returns
True if the graph was correctly generated and false in other case.
int te::graph::LDDGraphBuilder::getEdgeId ( )
protected

Function used to generated the edge id.

Returns
Integer value as ID
std::string te::graph::AbstractGraphBuilder::getErrorMessage ( )
inherited

Get error message.

boost::shared_ptr<AbstractGraph> te::graph::AbstractGraphBuilder::getGraph ( )
inherited

Get generated graph.

bool te::graph::LDDGraphBuilder::getVertexId ( int  row,
int  col,
int &  id 
)
protected

Function used to generated the vertex id based on raster coordenate.

Parameters
rowRow position over the raster
colColumn position over the raster
idUsed to set the id generated
Returns
True if a valid id was generated and false in other case

Member Data Documentation

int te::graph::LDDGraphBuilder::m_edgeId
private

Attribute used as a index counter for edge objects.

Definition at line 134 of file LDDGraphBuilder.h.

std::string te::graph::AbstractGraphBuilder::m_errorMessage
protectedinherited

Error message.

Definition at line 84 of file AbstractGraphBuilder.h.

boost::shared_ptr<AbstractGraph> te::graph::AbstractGraphBuilder::m_graph
protectedinherited

Graph object.

Definition at line 82 of file AbstractGraphBuilder.h.

te::rst::Raster* te::graph::LDDGraphBuilder::m_raster
private

Input raster with LDD information.

Definition at line 132 of file LDDGraphBuilder.h.


The documentation for this class was generated from the following file: