Main Page
Modules
Namespaces
Classes
Files
File List
File Members
BottomUpLoaderStrategy.h
Go to the documentation of this file.
1
/* Copyright (C) 2008 National Institute For Space Research (INPE) - Brazil.
2
3
This file is part of the TerraLib - a Framework for building GIS enabled applications.
4
5
TerraLib is free software: you can redistribute it and/or modify
6
it under the terms of the GNU Lesser General Public License as published by
7
the Free Software Foundation, either version 3 of the License,
8
or (at your option) any later version.
9
10
TerraLib is distributed in the hope that it will be useful,
11
but WITHOUT ANY WARRANTY; without even the implied warranty of
12
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
GNU Lesser General Public License for more details.
14
15
You should have received a copy of the GNU Lesser General Public License
16
along with TerraLib. See COPYING. If not, write to
17
TerraLib Team at <terralib-team@terralib.org>.
18
*/
19
20
/*!
21
\file BottomUpLoaderStrategy.h
22
23
\brief This class implements the main functions necessary to
24
save and load the graph data and metadata information
25
using as strategy the graph path.
26
27
\note TODO
28
*/
29
30
#ifndef __TERRALIB_GRAPH_INTERNAL_BOTTOMUPLOADERSTRATEGY_H
31
#define __TERRALIB_GRAPH_INTERNAL_BOTTOMUPLOADERSTRATEGY_H
32
33
// Terralib Includes
34
#include "../Config.h"
35
#include "Enums.h"
36
37
#include "
AbstractGraphLoaderStrategy.h
"
38
39
namespace
te
40
{
41
namespace
graph
42
{
43
//forward declarations
44
class
AbstractGraph;
45
class
Edge;
46
class
GraphCache;
47
class
GraphData;
48
class
GraphMetadata;
49
class
Vertex;
50
51
/*!
52
\class BottomUpLoaderStrategy
53
54
\brief This class implements the main functions necessary to
55
save and load the graph data and metadata information
56
using as strategy the graph path.
57
58
\note TODO
59
60
\sa AbstractGraphLoaderStrategy
61
*/
62
63
class
TEGRAPHEXPORT
BottomUpLoaderStrategy
:
public
AbstractGraphLoaderStrategy
64
{
65
public
:
66
67
/*! \brief Default constructor. */
68
BottomUpLoaderStrategy
(
te::graph::GraphMetadata
* metadata) :
AbstractGraphLoaderStrategy
(metadata) {};
69
70
/*! \brief Default destructor. */
71
virtual
~BottomUpLoaderStrategy
() {};
72
73
/** @name Top Down Graph Loader Strategy Methods
74
* Method used to manager a graph data
75
*/
76
//@{
77
78
/*!
79
\brief Functio used to load a group of vertex elements given a base element
80
81
\param vertexId Attribute used to identify the base element
82
83
\param g Pointer to a graph, parent of this element
84
85
\param gc This is a optional attribute, if present the cache will be check if the already been loaded
86
87
*/
88
virtual
void
loadDataByVertexId(
int
vertexId,
te::graph::AbstractGraph
* g,
te::graph::GraphCache
*
gc
= 0) = 0;
89
90
/*!
91
\brief Functio used to load a group of edges elements given a base element
92
93
\param edgeId Attribute used to identify the base element
94
95
\param g Pointer to a graph, parent of this element
96
97
\param gc This is a optional attribute, if present the cache will be check if the already been loaded
98
99
*/
100
virtual
void
loadDataByEdgeId(
int
edgeId,
te::graph::AbstractGraph
* g,
te::graph::GraphCache
*
gc
= 0) = 0;
101
102
/*!
103
\brief Save the graph data structure in Data Source
104
105
\param data Pointer to a valid graph data
106
107
*/
108
virtual
void
saveData(
GraphData
* data) = 0;
109
110
/*!
111
\brief Function used to remove a edge saved in a data source
112
113
\param id The edge identifier
114
115
*/
116
virtual
void
removeEdge(
int
id
) = 0;
117
118
/*!
119
\brief Function used to remove a vertex saved in a data source
120
121
\param id The vertex identifier
122
123
*/
124
virtual
void
removeVertex(
int
id
) = 0;
125
126
//@}
127
};
128
}
// end namespace graph
129
}
// end namespace te
130
131
#endif // __TERRALIB_GRAPH_INTERNAL_BOTTOMUPLOADERSTRATEGY_H
te::graph::BottomUpLoaderStrategy
This class implements the main functions necessary to save and load the graph data and metadata infor...
Definition:
BottomUpLoaderStrategy.h:63
te::graph::BottomUpLoaderStrategy::BottomUpLoaderStrategy
BottomUpLoaderStrategy(te::graph::GraphMetadata *metadata)
Default constructor.
Definition:
BottomUpLoaderStrategy.h:68
TEGRAPHEXPORT
#define TEGRAPHEXPORT
You can use this macro in order to export/import classes and functions from this module.
Definition:
src/terralib/graph/Config.h:178
gc
te::gm::GeometryCollection * gc
Definition:
examples/geometry/main.cpp:56
te::graph::AbstractGraph
Abstract class used to define the main functions of graph struct. All graph implementations must used...
Definition:
AbstractGraph.h:55
te
URI C++ Library.
Definition:
Attributes.h:37
te::graph::AbstractGraphLoaderStrategy
This class define the main functions necessary to save and load the graph data and metadata informati...
Definition:
AbstractGraphLoaderStrategy.h:55
te::graph::GraphCache
Class used to manager the graph data elements. This class uses a cache policy to control the elements...
Definition:
GraphCache.h:60
te::graph::GraphData
This class define a important struct used to group a map of vertex and edges. A flag is used to indic...
Definition:
GraphData.h:55
AbstractGraphLoaderStrategy.h
This class define the main functions necessary to save and load the graph data and metadata informati...
te::graph::GraphMetadata
Class used to define the graph metadata informations.
Definition:
GraphMetadata.h:56
te::graph::BottomUpLoaderStrategy::~BottomUpLoaderStrategy
virtual ~BottomUpLoaderStrategy()
Default destructor.
Definition:
BottomUpLoaderStrategy.h:71
terralib5_src
src
terralib
graph
loader
BottomUpLoaderStrategy.h
Generated on Wed Jun 6 2018 12:16:06 for TerraLib by
1.8.11