libmove3d-planners
 All Classes Namespaces Files Functions Variables Enumerations Enumerator Friends Macros Groups Pages
Node.h
1 #ifndef NODE_H
2 #define NODE_H
3 
4 #include <vector>
5 #include <utility>
6 
7 #include "NodeInterface.h"
8 #include "GraphCommon.h"
9 
10 namespace mho {
11 
12 class Edge;
13 
14 class Node : public NodeInterface
15 {
16 public:
17  Node();
18  Node(int id);
19 // Node(NodeInterface &ni);
20  virtual ~Node();
21  void connect(EdgeInterface *e);
22  std::vector<EdgeInterface *> &sons(void);
23  int getId(void){return _id;}
24 
25  GraphInterface * getGraph(){return this->_graph;}
26  void setGraph(GraphInterface * g){this->_graph = g;}
27 
28  virtual NodeInterface* clone(void);
29 
30 
31 private:
32  std::vector<EdgeInterface*> _edges;
33  int _id;
34  GraphInterface * _graph;
35 
36  static int __current_id;
37 
38 };
39 
40 }
41 
42 #endif // NODE_H
Classe représentant une Edge d'un Graph.
Definition: edge.hpp:24
Definition: NodeInterface.h:11
Definition: EdgeInterface.h:12
template interface for a graph
Definition: GraphInterface.h:13
Definition: Node.h:14