COIN-OR::LEMON - Graph Library

source: lemon-0.x/src/work/alpar/emptygraph.h @ 146:c4adf922624f

Last change on this file since 146:c4adf922624f was 145:07c32a103bbb, checked in by Alpar Juttner, 17 years ago

next() -> getNext()
goNext() -> next()

File size: 2.2 KB
Line 
1// -*-mode: c++; -*-
2
3class EmptyGraph
4{
5public:
6
7  class EdgeIt {};
8 
9  class InEdgeIt : public EdgeIt {};
10  class OutEdgeIt : public EdgeIt {};
11  class SymEdgeIt : public EdgeIt {};
12  class EachEdgeIt : public EdgeIt {};
13
14  class NodeIt {};
15   
16  NodeIt &getFirst(NodeIt &) const {}
17  InEdgeIt &getFirst(InEdgeIt &, NodeIt) const {}
18  OutEdgeIt &getFirst(OutEdgeIt &, NodeIt) const {}
19  SymEdgeIt &getFirst(SymEdgeIt &, NodeIt) const {}
20  EachEdgeIt &getFirst(EachEdgeIt &) const {}
21
22  NodeIt getNext(NodeIt) const {}
23  InEdgeIt getNext(InEdgeIt) const {}
24  OutEdgeIt getNext(OutEdgeIt) const {}
25  SymEdgeIt getNext(SymEdgeIt) const {}
26  EachEdgeIt getNext(EachEdgeIt) const {}
27
28  NodeIt &next(NodeIt &) const {}
29  InEdgeIt &next(InEdgeIt &) const {}
30  OutEdgeIt &next(OutEdgeIt &) const {}
31  SymEdgeIt &next(SymEdgeIt &) const {}
32  EachEdgeIt &next(EachEdgeIt &) const {}
33
34  NodeIt head(EdgeIt) const {}
35  NodeIt tail(EdgeIt) const {}
36 
37  NodeIt aNode(InEdgeIt) const {}
38  NodeIt aNode(OutEdgeIt) const {}
39  NodeIt aNode(SymEdgeIt) const {}
40
41  NodeIt bNode(InEdgeIt) const {}
42  NodeIt bNode(OutEdgeIt) const {}
43  NodeIt bNode(SymEdgeIt) const {}
44
45  //bool valid(const NodeIt) const {};
46  //bool valid(const EdgeIt) const {};
47
48  //void setInvalid(NodeIt &) const {};
49  //void setInvalid(EdgeIt &) const {};
50 
51  NodeIt addNode() {}
52  EdgeIt addEdge(NodeIt tail, NodeIt head) {}
53   
54  void erase(NodeIt n) {}
55  void erase(EdgeIt e) {}
56
57  void clear() {}
58
59  template<class T> class NodeMap
60  {
61  public:
62    typedef T ValueType;
63    typedef NodeIt KeyType;
64    void set(NodeIt i, T t) {}
65    T get(NodeIt i) const {}
66    T &operator[](NodeIt i) {}
67     
68    NodeMap(const Graph &G) {}
69    NodeMap(const Graph &G, T t) {}
70  };
71
72  template<class T> class EdgeMap
73  {
74  public:
75    typedef T ValueType;
76    typedef EdgeIt KeyType;
77    void set(EdgeIt i, T t) {}
78    T get(EdgeIt i) const {}
79    T &operator[](EdgeIt i) {}
80     
81    EdgeMap(const Graph &G) {}
82    EdgeMap(const Graph &G, T t) {}
83  };
84};
85
86class EmptyBipGraph : public EmptyGraph
87{
88  class ANodeIt {};
89  class BNodeIt {};
90
91  ANodeIt &next(ANodeIt &) {}
92  BNodeIt &next(BNodeIt &) {}
93
94  ANodeIt &getFirst(ANodeIt &) const {}
95  BNodeIt &getFirst(BNodeIt &) const {}
96
97  enum NodeClass { A = 0, B = 1 };
98  NodeClass getClass(NodeIt n) {}
99
100}
Note: See TracBrowser for help on using the repository browser.