#include <common.h>
Collaboration diagram for AtScopeExit< T, X >:

Public Member Functions | |
| AtScopeExit (T func, X target) | |
| ~AtScopeExit () | |
Private Attributes | |
| T | m_func |
| X | m_target |
For example, to free a ptr using free() when a function exists create a object like this: AtScopeExit<void (*)(), void*> delPtr(free, ptr); Thus when delPtr is destroyed free(ptr) will be invoked.
| AtScopeExit< T, X >::AtScopeExit | ( | T | func, | |
| X | target | |||
| ) | [inline] |
| AtScopeExit< T, X >::~AtScopeExit | ( | ) | [inline] |
T AtScopeExit< T, X >::m_func [private] |
X AtScopeExit< T, X >::m_target [private] |
1.4.7