#include <qgarlib/stl.H>
This struct is designed to delete objects, handled by a pointer, through STL algorithms. Below is a typical use of this struct:
#include <list> #include <algorithm> #include <qgarlib/Object.H> #include <qgarlib/stl.H> list<Object*> myList; ... // Clean up for_each(myList.begin(), myList.end(), qstlDeleteObject());
For further information, see item #7 in [Meyer, 2001].
Definition at line 89 of file stl.H.
Public Member Functions | |
| template<typename T> | |
| void | operator() (const T *ptr) const |
| Deletes an object via a passed pointer. | |
|
||||||||||
|
Deletes an object via a passed pointer.
|