src/lemon/graph_to_eps.h
changeset 1410 dcfad73b3965
parent 1366 d00b85f8be45
child 1417 53c2a0ccc9a4
equal deleted inserted replaced
18:80ad16d54f02 19:34aa416a6163
   361     const Graph &g;
   361     const Graph &g;
   362   public:
   362   public:
   363     edgeLess(const Graph &_g) : g(_g) {}
   363     edgeLess(const Graph &_g) : g(_g) {}
   364     bool operator()(Edge a,Edge b) const 
   364     bool operator()(Edge a,Edge b) const 
   365     {
   365     {
   366       Node ai=min(g.source(a),g.target(a));
   366       Node ai=std::min(g.source(a),g.target(a));
   367       Node aa=max(g.source(a),g.target(a));
   367       Node aa=std::max(g.source(a),g.target(a));
   368       Node bi=min(g.source(b),g.target(b));
   368       Node bi=std::min(g.source(b),g.target(b));
   369       Node ba=max(g.source(b),g.target(b));
   369       Node ba=std::max(g.source(b),g.target(b));
   370       return ai<bi ||
   370       return ai<bi ||
   371 	(ai==bi && (aa < ba || 
   371 	(ai==bi && (aa < ba || 
   372 		    (aa==ba && ai==g.source(a) && bi==g.target(b))));
   372 		    (aa==ba && ai==g.source(a) && bi==g.target(b))));
   373     }
   373     }
   374   };
   374   };