Changeset 1411:b79ff94e27d9 in lemon
 Timestamp:
 10/07/17 16:17:34 (2 years ago)
 Branch:
 default
 Phase:
 public
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

lemon/vf2pp.h
r1410 r1411 25 25 #include <lemon/core.h> 26 26 #include <lemon/concepts/graph.h> 27 #include <lemon/dfs.h>28 #include <lemon/bfs.h>29 27 #include <lemon/bits/vf2_internals.h> 30 28 … … 34 32 35 33 namespace lemon { 36 namespace bits {37 namespace vf2pp {38 39 template <class G>40 class DfsLeaveOrder : public DfsVisitor<G> {41 int i;42 const G &_g;43 std::vector<typename G::Node> &_order;44 public:45 DfsLeaveOrder(const G &g, std::vector<typename G::Node> &order)46 : i(countNodes(g)), _g(g), _order(order) {47 }48 void leave(const typename G::Node &node) {49 _order[i]=node;50 }51 };52 53 template <class G>54 class BfsLeaveOrder : public BfsVisitor<G> {55 int i;56 const G &_g;57 std::vector<typename G::Node> &_order;58 public:59 BfsLeaveOrder(const G &g, std::vector<typename G::Node> &order) { }60 void process(const typename G::Node &node) {61 _order[i++]=node;62 }63 };64 }65 }66 67 34 68 35 ///%VF2 Plus Plus algorithm class.
Note: See TracChangeset
for help on using the changeset viewer.