COIN-OR::LEMON - Graph Library

Changeset 2529:93de38566e6c in lemon-0.x for lemon/graph_adaptor.h


Ignore:
Timestamp:
11/30/07 10:22:38 (16 years ago)
Author:
Balazs Dezso
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@3405
Message:

Minor changes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lemon/graph_adaptor.h

    r2422 r2529  
    3535#include <lemon/bits/graph_adaptor_extender.h>
    3636#include <lemon/bits/graph_extender.h>
    37 
    3837#include <lemon/tolerance.h>
    3938
     
    948947  ///Graph::EdgeMap<int> flow(g, 0);
    949948  ///
    950   ///Preflow<SubGA, int, ConstMap<Edge, int>, Graph::EdgeMap<int> >
    951   ///  preflow(ga, s, t, const_1_map, flow);
     949  ///Preflow<SubGA, ConstMap<Edge, int>, Graph::EdgeMap<int> >
     950  ///  preflow(ga, const_1_map, s, t);
    952951  ///preflow.run();
    953952  ///\endcode
     
    959958  ///     << endl;
    960959  ///for(EdgeIt e(g); e!=INVALID; ++e)
    961   ///  if (flow[e])
     960  ///  if (preflow.flow(e))
    962961  ///    cout << " " << g.id(g.source(e)) << "--"
    963962  ///         << length[e] << "->" << g.id(g.target(e)) << endl;
     
    20222021      return INVALID;
    20232022    }
     2023
    20242024   
    20252025    template <typename T>
     
    20312031      NodeMap(const SplitGraphAdaptorBase& _graph, const T& t)
    20322032        : inNodeMap(_graph, t), outNodeMap(_graph, t) {}
    2033      
     2033      NodeMap& operator=(const NodeMap& cmap) {
     2034        return operator=<NodeMap>(cmap);
     2035      }
     2036      template <typename CMap>
     2037      NodeMap& operator=(const CMap& cmap) {
     2038        Parent::operator=(cmap);
     2039        return *this;
     2040      }
     2041
    20342042      void set(const Node& key, const T& val) {
    20352043        if (SplitGraphAdaptorBase::inNode(key)) { inNodeMap.set(key, val); }
     
    20632071      EdgeMap(const SplitGraphAdaptorBase& _graph, const T& t)
    20642072        : edge_map(_graph, t), node_map(_graph, t) {}
     2073      EdgeMap& operator=(const EdgeMap& cmap) {
     2074        return operator=<EdgeMap>(cmap);
     2075      }
     2076      template <typename CMap>
     2077      EdgeMap& operator=(const CMap& cmap) {
     2078        Parent::operator=(cmap);
     2079        return *this;
     2080      }
    20652081     
    20662082      void set(const Edge& key, const T& val) {
     
    24712487  /// SGraph::EdgeMap<int> sflow(sgraph);
    24722488  ///
    2473   /// Preflow<SGraph, int, SCapacity>
    2474   ///   spreflow(sgraph, SGraph::outNode(source),SGraph::inNode(target),
    2475   ///            scapacity, sflow);
     2489  /// Preflow<SGraph, SCapacity>
     2490  ///   spreflow(sgraph, scapacity,
     2491  ///            SGraph::outNode(source), SGraph::inNode(target));
    24762492  ///                                           
    24772493  /// spreflow.run();
Note: See TracChangeset for help on using the changeset viewer.