te::graph::GraphDataManager Class Reference

#include <GraphDataManager.h>

Public Member Functions

AbstractGraphLoaderStrategygetLoaderStrategy ()
 Function used to get the current loader strategy. More...
 
 GraphDataManager (te::graph::AbstractGraph *g)
 Default constructor. More...
 
void setLoaderStrategy (AbstractGraphLoaderStrategy *loaderStrategy)
 Function used to set a current loader strategy. More...
 
virtual ~GraphDataManager ()
 Default destructor. More...
 
Graph Data Manager Methods

Method used to manager a graph data

void loadGraphDataByVertexId (int vertexId, te::graph::GraphCache *gc=0)
 Load a set of vertex elements that includes the desired element. More...
 
void loadGraphDataByEdgeId (int edgeId, te::graph::GraphCache *gc=0)
 Load a set of edges elements that includes the desired element. More...
 
void saveGraphData (GraphData *data)
 Save the graph data structure in Data Source. More...
 
void removeEdge (int id)
 Function used to remove a edge from data source. More...
 
void removeVertex (int id)
 Function used to remove a vertex from data source. More...
 

Private Attributes

AbstractGraphm_graph
 Pointer to a graph object. More...
 
AbstractGraphLoaderStrategym_loadStrategy
 Pointer to a loader strategy object. More...
 

Detailed Description

Definition at line 58 of file GraphDataManager.h.

Constructor & Destructor Documentation

te::graph::GraphDataManager::GraphDataManager ( te::graph::AbstractGraph g)

Default constructor.

virtual te::graph::GraphDataManager::~GraphDataManager ( )
virtual

Default destructor.

Member Function Documentation

AbstractGraphLoaderStrategy* te::graph::GraphDataManager::getLoaderStrategy ( )

Function used to get the current loader strategy.

Returns
A valid pointer to a loader strategy if exist and a null pointer in other case
void te::graph::GraphDataManager::loadGraphDataByEdgeId ( int  edgeId,
te::graph::GraphCache gc = 0 
)

Load a set of edges elements that includes the desired element.

Parameters
edgeIdThe edge identifier of the desired element.
gcA Graph Cache used to verify if the element already in memory
void te::graph::GraphDataManager::loadGraphDataByVertexId ( int  vertexId,
te::graph::GraphCache gc = 0 
)

Load a set of vertex elements that includes the desired element.

Parameters
vertexIdThe vertex identifier of the desired element.
gcA Graph Cache used to verify if the element already in memory
void te::graph::GraphDataManager::removeEdge ( int  id)

Function used to remove a edge from data source.

Parameters
idThe edge Id
void te::graph::GraphDataManager::removeVertex ( int  id)

Function used to remove a vertex from data source.

Parameters
idThe vertex Id
void te::graph::GraphDataManager::saveGraphData ( GraphData data)

Save the graph data structure in Data Source.

Parameters
dataA graph data with a group of vertex and edge elements
Note
Only the elements with a flag new with true value will be saved and the elements with the flag dirty with true value will be updated the other elements will be ignored
void te::graph::GraphDataManager::setLoaderStrategy ( AbstractGraphLoaderStrategy loaderStrategy)

Function used to set a current loader strategy.

Parameters
loaderStrategyA pointer to loader strategy implementation

Member Data Documentation

AbstractGraph* te::graph::GraphDataManager::m_graph
private

Pointer to a graph object.

Definition at line 143 of file GraphDataManager.h.

AbstractGraphLoaderStrategy* te::graph::GraphDataManager::m_loadStrategy
private

Pointer to a loader strategy object.

Definition at line 142 of file GraphDataManager.h.


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