Public Member Functions

wali::Worklist< T > Class Template Reference

List of all members.

Public Member Functions

 Worklist ()
virtual ~Worklist ()
virtual bool put (T *item)=0
virtual T * get ()=0
virtual bool empty () const =0
virtual void clear ()=0

Detailed Description

template<typename T>
class wali::Worklist< T >

Worklist defines the interface of a worklist. All items must subclass wali::Markable. When an item is placed on a worklist, the worklist treats the item's "marked" state as only being modified by the worklist (i.e., do not place a Markable item on two worklists at the same time).


Constructor & Destructor Documentation

template<typename T>
wali::Worklist< T >::Worklist (  ) 
template<typename T>
virtual wali::Worklist< T >::~Worklist (  )  [virtual]

Member Function Documentation

template<typename T>
virtual bool wali::Worklist< T >::put ( T *  item  )  [pure virtual]

put

Put a Trans * in the Worklist. This method should be idempotent but it really does not matter.

Returns:
true if the item was added, false if not A false return value means the item was already "marked" and hence, is already on this worklist.

Implemented in wali::DefaultWorklist< T >, wali::PriorityWorklist, and wali::RankedWorklist.

Referenced by wali::wfa::WFA::path_summary(), and wali::wfa::WFA::setupFixpoint().

template<typename T>
virtual T* wali::Worklist< T >::get (  )  [pure virtual]

get

Return an item from the worklist. Guaranteed only to be called if Worklist is not empty. May throw an exception or return NULL if the worklist is not empty.

Returns:
Trans *

Implemented in wali::DefaultWorklist< T >, wali::PriorityWorklist, wali::RankedWorklist, and wali::wfa::epr::StatePriorityWorklist.

Referenced by wali::wfa::WFA::path_summary().

template<typename T>
virtual bool wali::Worklist< T >::empty (  )  const [pure virtual]
template<typename T>
virtual void wali::Worklist< T >::clear (  )  [pure virtual]

clear

Remove and unmark each item in this worklist.

Implemented in wali::DefaultWorklist< T >, wali::PriorityWorklist, wali::RankedWorklist, and wali::wfa::epr::StatePriorityWorklist.


The documentation for this class was generated from the following file: