29 protected: |
29 protected: |
30 typedef IterableBoolMap< typename Graph::template NodeMap<int> > |
30 typedef IterableBoolMap< typename Graph::template NodeMap<int> > |
31 SFalseTTrueMap; |
31 SFalseTTrueMap; |
32 SFalseTTrueMap* s_false_t_true_map; |
32 SFalseTTrueMap* s_false_t_true_map; |
33 |
33 |
34 BipartiteGraphWrapper() : GraphWrapper<Graph>() { } |
34 BipartiteGraphWrapper() : GraphWrapper<Graph>()/*, |
|
35 S_CLASS(false), T_CLASS(true)*/ { } |
35 void setSFalseTTrueMap(SFalseTTrueMap& _s_false_t_true_map) { |
36 void setSFalseTTrueMap(SFalseTTrueMap& _s_false_t_true_map) { |
36 s_false_t_true_map=&_s_false_t_true_map; |
37 s_false_t_true_map=&_s_false_t_true_map; |
37 } |
38 } |
38 |
39 |
39 public: |
40 public: |
40 //marci |
41 //marci |
41 //FIXME vhogy igy kellene, csak az en forditom nem eszi meg |
42 //FIXME vhogy igy kellene, csak az en forditom nem eszi meg |
42 //static const bool S_CLASS=false; |
43 static const bool S_CLASS=false; |
43 //static const bool T_CLASS=true; |
44 static const bool T_CLASS=true; |
44 |
45 |
45 bool S_CLASS; |
46 //bool S_CLASS; |
46 bool T_CLASS; |
47 //bool T_CLASS; |
47 |
48 |
48 BipartiteGraphWrapper(Graph& _graph, SFalseTTrueMap& _s_false_t_true_map) |
49 BipartiteGraphWrapper(Graph& _graph, SFalseTTrueMap& _s_false_t_true_map) |
49 : GraphWrapper<Graph>(_graph), |
50 : GraphWrapper<Graph>(_graph), |
50 s_false_t_true_map(&_s_false_t_true_map), |
51 s_false_t_true_map(&_s_false_t_true_map)/*, |
51 S_CLASS(false), T_CLASS(true) { } |
52 S_CLASS(false), T_CLASS(true)*/ { } |
52 typedef typename GraphWrapper<Graph>::Node Node; |
53 typedef typename GraphWrapper<Graph>::Node Node; |
53 //using GraphWrapper<Graph>::NodeIt; |
54 //using GraphWrapper<Graph>::NodeIt; |
54 typedef typename GraphWrapper<Graph>::Edge Edge; |
55 typedef typename GraphWrapper<Graph>::Edge Edge; |
55 //using GraphWrapper<Graph>::EdgeIt; |
56 //using GraphWrapper<Graph>::EdgeIt; |
56 class ClassNodeIt; |
57 class ClassNodeIt; |
207 /// the \c bool parameter which can be \c S_Class or \c T_Class shows |
208 /// the \c bool parameter which can be \c S_Class or \c T_Class shows |
208 /// the color class where the new node is to be inserted. |
209 /// the color class where the new node is to be inserted. |
209 Node addNode(bool b) { |
210 Node addNode(bool b) { |
210 Node n=Parent::graph->addNode(); |
211 Node n=Parent::graph->addNode(); |
211 bipartite_map.update(); |
212 bipartite_map.update(); |
|
213 //bipartite_map.set(n, -1); |
212 s_false_t_true_map.insert(n, b); |
214 s_false_t_true_map.insert(n, b); |
213 return n; |
215 return n; |
214 } |
216 } |
215 |
217 |
216 /// A new edge is inserted. |
218 /// A new edge is inserted. |