1.1 --- a/lemon/core.h Thu Mar 05 10:13:20 2009 +0000
1.2 +++ b/lemon/core.h Sun Mar 29 23:08:20 2009 +0200
1.3 @@ -1034,11 +1034,11 @@
1.4 ///
1.5 ///\sa findArc()
1.6 ///\sa ArcLookUp, AllArcLookUp, DynArcLookUp
1.7 - template <typename _Graph>
1.8 - class ConArcIt : public _Graph::Arc {
1.9 + template <typename GR>
1.10 + class ConArcIt : public GR::Arc {
1.11 public:
1.12
1.13 - typedef _Graph Graph;
1.14 + typedef GR Graph;
1.15 typedef typename Graph::Arc Parent;
1.16
1.17 typedef typename Graph::Arc Arc;
1.18 @@ -1157,11 +1157,11 @@
1.19 ///\endcode
1.20 ///
1.21 ///\sa findEdge()
1.22 - template <typename _Graph>
1.23 - class ConEdgeIt : public _Graph::Edge {
1.24 + template <typename GR>
1.25 + class ConEdgeIt : public GR::Edge {
1.26 public:
1.27
1.28 - typedef _Graph Graph;
1.29 + typedef GR Graph;
1.30 typedef typename Graph::Edge Parent;
1.31
1.32 typedef typename Graph::Edge Edge;
1.33 @@ -1211,29 +1211,29 @@
1.34 ///optimal time bound in a constant factor for any distribution of
1.35 ///queries.
1.36 ///
1.37 - ///\tparam G The type of the underlying digraph.
1.38 + ///\tparam GR The type of the underlying digraph.
1.39 ///
1.40 ///\sa ArcLookUp
1.41 ///\sa AllArcLookUp
1.42 - template<class G>
1.43 + template <typename GR>
1.44 class DynArcLookUp
1.45 - : protected ItemSetTraits<G, typename G::Arc>::ItemNotifier::ObserverBase
1.46 + : protected ItemSetTraits<GR, typename GR::Arc>::ItemNotifier::ObserverBase
1.47 {
1.48 public:
1.49 - typedef typename ItemSetTraits<G, typename G::Arc>
1.50 + typedef typename ItemSetTraits<GR, typename GR::Arc>
1.51 ::ItemNotifier::ObserverBase Parent;
1.52
1.53 - TEMPLATE_DIGRAPH_TYPEDEFS(G);
1.54 - typedef G Digraph;
1.55 + TEMPLATE_DIGRAPH_TYPEDEFS(GR);
1.56 + typedef GR Digraph;
1.57
1.58 protected:
1.59
1.60 - class AutoNodeMap : public ItemSetTraits<G, Node>::template Map<Arc>::Type {
1.61 + class AutoNodeMap : public ItemSetTraits<GR, Node>::template Map<Arc>::Type {
1.62 public:
1.63
1.64 - typedef typename ItemSetTraits<G, Node>::template Map<Arc>::Type Parent;
1.65 + typedef typename ItemSetTraits<GR, Node>::template Map<Arc>::Type Parent;
1.66
1.67 - AutoNodeMap(const G& digraph) : Parent(digraph, INVALID) {}
1.68 + AutoNodeMap(const GR& digraph) : Parent(digraph, INVALID) {}
1.69
1.70 virtual void add(const Node& node) {
1.71 Parent::add(node);
1.72 @@ -1623,16 +1623,16 @@
1.73 ///digraph changes. This is a time consuming (superlinearly proportional
1.74 ///(<em>O</em>(<em>m</em> log<em>m</em>)) to the number of arcs).
1.75 ///
1.76 - ///\tparam G The type of the underlying digraph.
1.77 + ///\tparam GR The type of the underlying digraph.
1.78 ///
1.79 ///\sa DynArcLookUp
1.80 ///\sa AllArcLookUp
1.81 - template<class G>
1.82 + template<class GR>
1.83 class ArcLookUp
1.84 {
1.85 public:
1.86 - TEMPLATE_DIGRAPH_TYPEDEFS(G);
1.87 - typedef G Digraph;
1.88 + TEMPLATE_DIGRAPH_TYPEDEFS(GR);
1.89 + typedef GR Digraph;
1.90
1.91 protected:
1.92 const Digraph &_g;
1.93 @@ -1733,20 +1733,20 @@
1.94 ///digraph changes. This is a time consuming (superlinearly proportional
1.95 ///(<em>O</em>(<em>m</em> log<em>m</em>)) to the number of arcs).
1.96 ///
1.97 - ///\tparam G The type of the underlying digraph.
1.98 + ///\tparam GR The type of the underlying digraph.
1.99 ///
1.100 ///\sa DynArcLookUp
1.101 ///\sa ArcLookUp
1.102 - template<class G>
1.103 - class AllArcLookUp : public ArcLookUp<G>
1.104 + template<class GR>
1.105 + class AllArcLookUp : public ArcLookUp<GR>
1.106 {
1.107 - using ArcLookUp<G>::_g;
1.108 - using ArcLookUp<G>::_right;
1.109 - using ArcLookUp<G>::_left;
1.110 - using ArcLookUp<G>::_head;
1.111 + using ArcLookUp<GR>::_g;
1.112 + using ArcLookUp<GR>::_right;
1.113 + using ArcLookUp<GR>::_left;
1.114 + using ArcLookUp<GR>::_head;
1.115
1.116 - TEMPLATE_DIGRAPH_TYPEDEFS(G);
1.117 - typedef G Digraph;
1.118 + TEMPLATE_DIGRAPH_TYPEDEFS(GR);
1.119 + typedef GR Digraph;
1.120
1.121 typename Digraph::template ArcMap<Arc> _next;
1.122
1.123 @@ -1773,7 +1773,7 @@
1.124 ///
1.125 ///It builds up the search database, which remains valid until the digraph
1.126 ///changes.
1.127 - AllArcLookUp(const Digraph &g) : ArcLookUp<G>(g), _next(g) {refreshNext();}
1.128 + AllArcLookUp(const Digraph &g) : ArcLookUp<GR>(g), _next(g) {refreshNext();}
1.129
1.130 ///Refresh the data structure at a node.
1.131
1.132 @@ -1783,7 +1783,7 @@
1.133 ///the number of the outgoing arcs of \c n.
1.134 void refresh(Node n)
1.135 {
1.136 - ArcLookUp<G>::refresh(n);
1.137 + ArcLookUp<GR>::refresh(n);
1.138 refreshNext(_head[n]);
1.139 }
1.140
1.141 @@ -1830,7 +1830,7 @@
1.142 #ifdef DOXYGEN
1.143 Arc operator()(Node s, Node t, Arc prev=INVALID) const {}
1.144 #else
1.145 - using ArcLookUp<G>::operator() ;
1.146 + using ArcLookUp<GR>::operator() ;
1.147 Arc operator()(Node s, Node t, Arc prev) const
1.148 {
1.149 return prev==INVALID?(*this)(s,t):_next[prev];