[Lemon-commits] [lemon_svn] marci: r511 - hugo/trunk/src/work/marci

Lemon SVN svn at lemon.cs.elte.hu
Mon Nov 6 20:39:52 CET 2006


Author: marci
Date: Fri Apr 23 10:32:18 2004
New Revision: 511

Modified:
   hugo/trunk/src/work/marci/graph_wrapper.h

Log:
misc


Modified: hugo/trunk/src/work/marci/graph_wrapper.h
==============================================================================
--- hugo/trunk/src/work/marci/graph_wrapper.h	(original)
+++ hugo/trunk/src/work/marci/graph_wrapper.h	Fri Apr 23 10:32:18 2004
@@ -907,6 +907,8 @@
       ClassNodeIt(const BipartiteGraphWrapper<Graph>& _G, bool _class) { 
 	_G.s_false_t_true_map->first(n, _class); 
       }
+      //FIXME needed in new concept, important here
+      ClassNodeIt(const Node& _n) : n(_n) { }
       operator Node() const { return n; }
     };
 //     class SNodeIt {
@@ -1011,10 +1013,10 @@
     }
 
     bool inSClass(const Node& n) const {
-      return !(this->s_false_t_true_map[n]);
+      return !(*(this->s_false_t_true_map))[n];
     }
     bool inTClass(const Node& n) const {
-      return (this->s_false_t_true_map[n]);
+      return (*(this->s_false_t_true_map))[n];
     }
   };
 
@@ -1026,26 +1028,32 @@
   class stGraphWrapper : public GraphWrapper<Graph> {
   public:
     class Node; 
+    friend class Node;
 //GN, int
 //0 normalis, 1 s, 2, true, ez az iteralasi sorrend, 
 //es a vege a false azaz (invalid, 3)    
     class NodeIt;
+    friend class NodeIt;
 //GNI, int
     class Edge;
+    friend class Edge;
 //GE, int, GN
 //0 normalis, 1 s->vmi, 2 vmi->t, ez a sorrend,
 //invalid: (invalid, 3, invalid)
     class OutEdgeIt;
+    friend class OutEdgeIt;
 //GO, int, GNI
 //normalis pontbol (first, 0, invalid), ..., (invalid, 2, vmi), ... (invalid, 3, invalid)
 //s-bol (invalid, 1, first), ... (invalid, 3, invalid)
 //t-bol (invalid, 3, invalid)
     class InEdgeIt;
+    friend class InEdgeIt;
 //GI, int, GNI
 //normalis pontbol (first, 0, invalid), ..., (invalid, 1, vmi), ... (invalid, 3, invalid)
 //s-be (invalid, 3, invalid)
 //t-be (invalid, 2, first), ... (invalid, 3, invalid)
     class EdgeIt;
+    friend class EdgeIt;
 //(first, 0, invalid) ...
 //(invalid, 1, vmi)
 //(invalid, 2, vmi)
@@ -1103,7 +1111,7 @@
       NodeIt(const typename Graph::NodeIt& _n, int _spec) : 
 	n(_n), spec(_spec) { }
       NodeIt(const Invalid& i) : n(i), spec(3) { }
-      NodeIt(const GraphWrapper<Graph>& _G) : n(*(_G.graph)), spec(0) { 
+      NodeIt(const stGraphWrapper<Graph>& _G) : n(*(_G.graph)), spec(0) { 
 	if (!_G->valid(n)) spec=1;
       }
       operator Node() const { return Node(n, spec); }
@@ -1148,10 +1156,10 @@
 	e(_e), spec(_spec), n(_n) { 
       }
       OutEdgeIt(const Invalid& i) : e(i), spec(3), n(i) { }
-      OutEdgeIt(const GraphWrapper<Graph>& _G, const Node& _n) {
+      OutEdgeIt(const stGraphWrapper<Graph>& _G, const Node& _n) {
 	switch (_n.spec) {
 	  case 0 : 
-	    if (_G.graph->inSClass) { //S, van normalis kiel 
+	    if (_G.graph->inSClass(_n)) { //S, van normalis kiel 
 	      e=typename Graph::OutEdgeIt(*(_G.graph), 
 					  typename Graph::Node(_n)); 
 	      spec=0;
@@ -1191,10 +1199,10 @@
 	e(_e), spec(_spec), n(_n) { 
       }
       InEdgeIt(const Invalid& i) : e(i), spec(3), n(i) { }
-      InEdgeIt(const GraphWrapper<Graph>& _G, const Node& _n) {
+      InEdgeIt(const stGraphWrapper<Graph>& _G, const Node& _n) {
 	switch (_n.spec) {
 	  case 0 : 
-	    if (_G.graph->inTClass) { //T, van normalis beel 
+	    if (_G.graph->inTClass(_n)) { //T, van normalis beel 
 	      e=typename Graph::InEdgeIt(*(_G.graph), 
 					 typename Graph::Node(_n)); 
 	      spec=0;
@@ -1232,7 +1240,7 @@
 	     const typename Graph::ClassNodeIt& _n) : 
 	e(_e), spec(_spec), n(_n) { }
       EdgeIt(const Invalid& i) : e(i), spec(3), n(i) { }
-      EdgeIt(const GraphWrapper<Graph>& _G) : 
+      EdgeIt(const stGraphWrapper<Graph>& _G) : 
 	e(*(_G.graph)), spec(0), n(INVALID) { 
 	if (!_G.graph->valid(e)) {
 	  spec=1;



More information about the Lemon-commits mailing list