COIN-OR::LEMON - Graph Library

Changeset 1717:75fe24093ded in lemon-0.x for lemon/concept


Ignore:
Timestamp:
10/14/05 12:40:00 (14 years ago)
Author:
Balazs Dezso
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@2244
Message:

Added clear function to heaps and concept

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lemon/concept/heap.h

    r1494 r1717  
    6262      explicit Heap(ItemIntMap &_iim) {}
    6363
    64       /// The number of items stored in the heap.
    65       ///
    66       /// \brief Returns the number of items stored in the heap.
     64      /// \brief The number of items stored in the heap.
     65      ///
     66      /// Returns the number of items stored in the heap.
    6767      int size() const { return 0; }
     68
    6869      /// \brief Checks if the heap stores no items.
    6970      ///
    7071      /// Returns \c true if and only if the heap stores no items.
    7172      bool empty() const { return false; }
     73
     74      /// \brief Makes empty this heap.
     75      ///
     76      /// Makes this heap empty.
     77      void clear();
    7278
    7379      /// \brief Insert an item into the heap with the given heap.
     
    190196          state = _Heap::IN_HEAP;
    191197          state = _Heap::POST_HEAP;
     198
     199          heap.clear();
    192200        }
    193201   
Note: See TracChangeset for help on using the changeset viewer.