COIN-OR::LEMON - Graph Library

Changeset 1220:20b26ee5812b in lemon-0.x for src/lemon/dfs.h


Ignore:
Timestamp:
03/16/05 17:40:21 (16 years ago)
Author:
Alpar Juttner
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@1640
Message:
  • Add compilation tests for the function type interface of BFS/DFS/Dijkstra
  • Fix the bugs covered up by these tests
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/lemon/dfs.h

    r1218 r1220  
    432432    }
    433433
     434    ///Sets the map indicating if a node is reached.
     435
     436    ///Sets the map indicating if a node is reached.
     437    ///If you don't use this function before calling \ref run(),
     438    ///it will allocate one. The destuctor deallocates this
     439    ///automatically allocated map, of course.
     440    ///\return <tt> (*this) </tt>
     441    Dfs &reachedMap(ReachedMap &m)
     442    {
     443      if(local_reached) {
     444        delete _reached;
     445        local_reached=false;
     446      }
     447      _reached = &m;
     448      return *this;
     449    }
     450
     451    ///Sets the map indicating if a node is processed.
     452
     453    ///Sets the map indicating if a node is processed.
     454    ///If you don't use this function before calling \ref run(),
     455    ///it will allocate one. The destuctor deallocates this
     456    ///automatically allocated map, of course.
     457    ///\return <tt> (*this) </tt>
     458    Dfs &processedMap(ProcessedMap &m)
     459    {
     460      if(local_processed) {
     461        delete _processed;
     462        local_processed=false;
     463      }
     464      _processed = &m;
     465      return *this;
     466    }
     467
    434468  public:
    435469    ///\name Execution control
Note: See TracChangeset for help on using the changeset viewer.