|
HDK
|
#include <UT_Algorithm.h>
Public Member Functions | |
| AutoScope (UT_CycleDetect< T > *cycle) | |
| ~AutoScope () | |
| void | reset () |
Helper class for automatically saving and restoring the state of the cycle detection within a scope block.
Example:
T walk;
UT_CycleDetect<T> cycle;
.....
{
UT_CycleDetect<T>::AutoScope cycle_detect_scope(cycle);
if (!cycle.detect(<some_object>))
{
... do some work that may recursively update the cycle ...
}
else
{
... cycle detected. Do work to report/handle cycle ...
cycle_detect_scope.reset();
}
Definition at line 82 of file UT_Algorithm.h.
|
inline |
Definition at line 85 of file UT_Algorithm.h.
|
inline |
Definition at line 94 of file UT_Algorithm.h.
|
inline |
Definition at line 108 of file UT_Algorithm.h.