Revision efed924d custompackages/graph-parser/src/common.h

View differences:

custompackages/graph-parser/src/common.h
18 18

  
19 19
using namespace std;
20 20

  
21
class Router { // aka Vertex
21
class Router { // aka VertexProperties
22 22
public:
23 23
    string id;
24
    string name;
24
    string label;
25 25

  
26 26
    Router() { };
27
    Router(string id, string name) : id(id), name(name) { };
27
    Router(string i, string l) : id(i), label(l) { };
28 28

  
29 29
    bool operator<(const Router& rhs)
30 30
    {
......
36 36
   }
37 37
};
38 38

  
39
struct Link { // aka Edge
39
struct Link { // aka EdgeProperties
40 40
    double cost;
41 41

  
42 42
    Link() { };
43
    Link(double cost) : cost(cost) { };
43
    Link(double c) : cost(c) { };
44 44
};
45 45

  
46 46
// List typedefs
......
62 62
typedef map<Edge, size_t> StdEdgeIndexMap;
63 63
typedef boost::associative_property_map<StdEdgeIndexMap> EdgeIndexMap;
64 64

  
65

  
66 65
typedef std::vector<Vertex> VertexVec;
67 66
typedef std::vector<Vertex>::iterator VertexVecIter;
68 67

  
69 68
typedef std::map<Vertex, int> VertexMap;
70 69
typedef std::map<Vertex, int>::iterator VertexMapIter;
71 70

  
71
// TODO: this StringVec is currently un-used
72
typedef std::vector<std::string> StringVec;
73
typedef std::vector<std::string>::iterator StringVecIter;
74

  
75
typedef std::set<std::string> StringSet;
76
typedef std::set<std::string>::iterator StringSetIter;
72 77

  
73 78
typedef std::vector<double> CentralityVec;
74 79
typedef boost::iterator_property_map<CentralityVec::iterator, VertexIndexMap> CentralityMap;

Also available in: Unified diff