COIN-OR::LEMON - Graph Library

Changeset 987:87f7c54892df in lemon-0.x for src/work/alpar


Ignore:
Timestamp:
11/13/04 18:07:10 (20 years ago)
Author:
Alpar Juttner
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@1377
Message:

Naming changes:

Location:
src/work/alpar
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • src/work/alpar/boolmap_iter.cc

    r986 r987  
    1414  typedef typename GG::Edge Edge;
    1515 
    16   typedef Edge KeyType;
    17   typedef bool ValueType;
     16  typedef Edge Key;
     17  typedef bool Value;
    1818 
    1919  friend class RefType;
     
    6868    RefType(BoolIterEdgeMap &_M,Edge _e) : M(_M), e(_e) { }
    6969   
    70     operator ValueType() const
     70    operator Value() const
    7171    {
    7272      return M.isTrue(e);
    7373     
    7474    }
    75     ValueType operator = (ValueType v) const
     75    Value operator = (Value v) const
    7676    {
    7777      if(v) M.setTrue(e);
  • src/work/alpar/dijkstra.h

    r986 r987  
    4747    typedef LM LengthMap;
    4848    //The type of the length of the edges.
    49     typedef typename LM::ValueType ValueType;
     49    typedef typename LM::Value Value;
    5050    ///The heap type used by Dijkstra algorithm.
    5151
     
    5555    ///\sa Dijkstra
    5656    typedef BinHeap<typename Graph::Node,
    57                     typename LM::ValueType,
     57                    typename LM::Value,
    5858                    typename GR::template NodeMap<int>,
    59                     std::less<ValueType> > Heap;
     59                    std::less<Value> > Heap;
    6060
    6161    ///\brief The type of the map that stores the last
     
    9191    ///It must meet the \ref concept::WriteMap "WriteMap" concept.
    9292    ///
    93     typedef typename Graph::template NodeMap<typename LM::ValueType> DistMap;
     93    typedef typename Graph::template NodeMap<typename LM::Value> DistMap;
    9494    ///Instantiates a DistMap.
    9595 
     
    110110  ///
    111111  ///The type of the length is determined by the
    112   ///\ref concept::ReadMap::ValueType "ValueType" of the length map.
     112  ///\ref concept::ReadMap::Value "Value" of the length map.
    113113  ///
    114114  ///It is also possible to change the underlying priority heap.
     
    159159   
    160160    ///The type of the length of the edges.
    161     typedef typename TR::LengthMap::ValueType ValueType;
     161    typedef typename TR::LengthMap::Value Value;
    162162    ///The type of the map that stores the edge lengths.
    163163    typedef typename TR::LengthMap LengthMap;
     
    388388       
    389389        Node v=heap.top();
    390         ValueType oldvalue=heap[v];
     390        Value oldvalue=heap[v];
    391391        heap.pop();
    392392        distance->set(v, oldvalue);
     
    421421    ///\warning If node \c v in unreachable from the root the return value
    422422    ///of this funcion is undefined.
    423     ValueType dist(Node v) const { return (*distance)[v]; }
     423    Value dist(Node v) const { return (*distance)[v]; }
    424424
    425425    ///Returns the 'previous edge' of the shortest path tree.
     
    498498    typedef typename TR::LengthMap LengthMap;
    499499    ///The type of the length of the edges.
    500     typedef typename LengthMap::ValueType ValueType;
     500    typedef typename LengthMap::Value Value;
    501501    ///\brief The type of the map that stores the last
    502502    ///edges of the shortest paths.
  • src/work/alpar/f_ed_ka.h

    r986 r987  
    1414namespace lemon {
    1515  template <typename Graph, typename FlowMap, typename CapacityMap>
    16   typename FlowMap::ValueType maxFlow(Graph &G,
     16  typename FlowMap::Value maxFlow(Graph &G,
    1717                                      FlowMap &f,
    1818                                      CapacityMap &c,
     
    2626    typedef typename Graph::OutEdgeIt OutEdgeIt;
    2727    typedef typename Graph::InEdgeIt InEdgeIt;
    28     typedef typename FlowMap::ValueType T;
     28    typedef typename FlowMap::Value T;
    2929   
    3030    T flow_val = 0;
  • src/work/alpar/rw_nonref_map.cc

    r986 r987  
    1111  typedef typename GG::Edge Edge;
    1212 
    13   typedef Edge KeyType;
    14   typedef TT ValueType;
     13  typedef Edge Key;
     14  typedef TT Value;
    1515 
    1616  class RefType
     
    2121    RefType(Graph &_G,Edge _e) : G(_G), e(_e) { }
    2222   
    23     operator ValueType() const
     23    operator Value() const
    2424    {
    25       ValueType tmp;
     25      Value tmp;
    2626      std::cout << G.id(G.source(e)) << "->"
    2727                << G.id(G.target(e)) << ": ";
     
    2929      return tmp;
    3030    }
    31     ValueType operator = (ValueType v) const
     31    Value operator = (Value v) const
    3232    {
    3333      std::cout << G.id(G.source(e)) << "->"
     
    4848{
    4949public:
    50   typedef K KeyType;
    51   typedef T ValueType;
     50  typedef K Key;
     51  typedef T Value;
    5252 
    5353  class RefType
    5454  {
    55     ValueType val;
     55    Value val;
    5656  public:
    57     RefType(ValueType v) : val(v) { }   
    58     operator ValueType() const { return val; }
    59     ValueType operator = (ValueType v) const { return val; }
     57    RefType(Value v) : val(v) { }   
     58    operator Value() const { return val; }
     59    Value operator = (Value v) const { return val; }
    6060  };
    6161 
    6262private:
    63   ValueType val;
     63  Value val;
    6464public:
    65   NullMap(ValueType v) : val(v) { }
    66   RefType operator[] (KeyType e) const { return RefType(v);} 
     65  NullMap(Value v) : val(v) { }
     66  RefType operator[] (Key e) const { return RefType(v);} 
    6767};
    6868
Note: See TracChangeset for help on using the changeset viewer.