//
//  Copyright (c) 2001, Reson, Inc. All Rights Reserved.
//
//  Filename:   CCritical.h
//
//  Project:    6046.
//
//  Author(s):  W. Arcus
//
//  Purpose:    Class definition file for critical section wrapper class.
//
//  Notes:      Default construtor and assignment operator are not implemented
//              therefore they're defined as private to flag compiler usage
//              behind our back; will generate a compiler error.
//

#if !defined(AFX_CRITICAL_H__F422D68C_24F9_42E5_957C_DF80A38C4FBC__INCLUDED_)
#define AFX_CRITICAL_H__F422D68C_24F9_42E5_957C_DF80A38C4FBC__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

class EXPORT_DLL CCritical  
{
public:

                        CCritical   (   void );
    virtual            ~CCritical   (   void );

    void                Enter       (   void );
    void                Leave       (   void );

private:

    CRITICAL_SECTION    m_sCriticalSection;

                        CCritical   (   const CCritical &rRhs );    // Not implemented.
    CCritical   &       operator =  (   const CCritical &rRhs );    // Not implemented.

};

#endif // !defined(AFX_CRITICAL_H__F422D68C_24F9_42E5_957C_DF80A38C4FBC__INCLUDED_)
