Public Member Functions

HoldSuspend Class Reference

Search for all occurrences

#include <hold.h>

Inheritance diagram for HoldSuspend:
Inheritance graph
[legend]

List of all members.

Public Member Functions

  HoldSuspend (BOOL suspendNow=TRUE)
  ~HoldSuspend ()
void  Suspend ()
void  Resume ()

Constructor & Destructor Documentation

HoldSuspend ( BOOL  suspendNow = TRUE ) [inline]
                                        : suspendCount(0) {
        if (suspendNow) {
            this->Suspend();
        }
    }
~HoldSuspend ( ) [inline]
                    {
        while(suspendCount > 0) {
            this->Resume();
        }
    }

Member Function Documentation

void Suspend ( ) [inline]
                   {
        if (suspendCount == 0) 
            theHold.Suspend ();
        suspendCount++;
    }
void Resume ( ) [inline]
                  {
        if (suspendCount == 1) 
            theHold.Resume();
        if (suspendCount > 0) 
            suspendCount--;
    }

HoldSuspend HoldSuspend HoldSuspend HoldSuspend HoldSuspend HoldSuspend HoldSuspend HoldSuspend HoldSuspend HoldSuspend
HoldSuspend HoldSuspend HoldSuspend HoldSuspend HoldSuspend HoldSuspend HoldSuspend HoldSuspend HoldSuspend HoldSuspend