# HG changeset patch # User marci # Date 1082709138 0 # Node ID d72470496fbeb1b50d8458e327e2c97ac61b598a # Parent 6399494e30b1904b903df167c1ff34862601a304 misc diff -r 6399494e30b1 -r d72470496fbe src/work/marci/graph_wrapper.h --- a/src/work/marci/graph_wrapper.h Fri Apr 23 08:08:41 2004 +0000 +++ b/src/work/marci/graph_wrapper.h Fri Apr 23 08:32:18 2004 +0000 @@ -907,6 +907,8 @@ ClassNodeIt(const BipartiteGraphWrapper& _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 { 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& _G) : n(*(_G.graph)), spec(0) { + NodeIt(const stGraphWrapper& _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& _G, const Node& _n) { + OutEdgeIt(const stGraphWrapper& _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& _G, const Node& _n) { + InEdgeIt(const stGraphWrapper& _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& _G) : + EdgeIt(const stGraphWrapper& _G) : e(*(_G.graph)), spec(0), n(INVALID) { if (!_G.graph->valid(e)) { spec=1;