CVCL::ScopeWatcher Class Reference

A class which sets a boolean value to true when created, and resets to false when deleted. More...

#include <debug.h>

List of all members.

Public Member Functions

Private Attributes


Detailed Description

A class which sets a boolean value to true when created, and resets to false when deleted.

Useful for tracking when the control is within a certain method or not. For example, TheoryCore::addFact() uses d_inAddFact to check that certain other methods are only called from within addFact(). However, when an exception is thrown, this variable is not reset. The watcher class will reset the variable even in those cases.

Definition at line 98 of file debug.h.


Constructor & Destructor Documentation

CVCL::ScopeWatcher::ScopeWatcher bool *  flag  )  [inline]
 

Definition at line 102 of file debug.h.

References d_flag.

CVCL::ScopeWatcher::~ScopeWatcher  )  [inline]
 

Definition at line 103 of file debug.h.

References d_flag.


Member Data Documentation

bool* CVCL::ScopeWatcher::d_flag [private]
 

Definition at line 100 of file debug.h.

Referenced by ScopeWatcher(), and ~ScopeWatcher().


The documentation for this class was generated from the following file:
Generated on Thu Apr 13 16:57:43 2006 for CVC Lite by  doxygen 1.4.4