COIN-OR::LEMON - Graph Library

Changeset 1665:fdeb961110ac in lemon-0.x for lemon


Ignore:
Timestamp:
08/30/05 16:55:11 (19 years ago)
Author:
Alpar Juttner
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@2181
Message:

Functions to query the next node/edge to be processed.

Location:
lemon
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • lemon/bfs.h

    r1631 r1665  
    544544    }
    545545     
     546    ///Next node to be processed.
     547
     548    ///Next node to be processed.
     549    ///
     550    ///\return The next node to be processed or INVALID if the queue is
     551    /// empty.
     552    Node NextNode()
     553    {
     554      return _queue_tail<_queue_head?_queue[_queue_tail]:INVALID;
     555    }
     556 
    546557    ///\brief Returns \c false if there are nodes
    547558    ///to be processed in the queue
  • lemon/dfs.h

    r1664 r1665  
    553553      return e;
    554554    }
     555    ///Next edge to be processed.
     556
     557    ///Next edge to be processed.
     558    ///
     559    ///\return The next edge to be processed or INVALID if the stack is
     560    /// empty.
     561    OutEdgeIt NextEdge()
     562    {
     563      return _stack_head>=0?_stack[_stack_head]:INVALID;
     564    }
    555565     
    556566    ///\brief Returns \c false if there are nodes
     
    559569    ///Returns \c false if there are nodes
    560570    ///to be processed in the queue
     571    ///
     572    ///\todo This should be called emptyStack() or some "neutral" name.
    561573    bool emptyQueue() { return _stack_head<0; }
    562574    ///Returns the number of the nodes to be processed.
     
    564576    ///Returns the number of the nodes to be processed in the queue.
    565577    ///
     578    ///\todo This should be called stackSize() or some "neutral" name.
    566579    int queueSize() { return _stack_head+1; }
    567580   
  • lemon/dijkstra.h

    r1631 r1665  
    547547    }
    548548
     549    ///Next node to be processed.
     550   
     551    ///Next node to be processed.
     552    ///
     553    ///\return The next node to be processed or INVALID if the priority heap
     554    /// is empty.
     555    Node NextNode()
     556    {
     557      return _heap.empty()?_heap.top():INVALID;
     558    }
     559 
    549560    ///\brief Returns \c false if there are nodes
    550561    ///to be processed in the priority heap
Note: See TracChangeset for help on using the changeset viewer.