virtual BOOL Lock( DWORD dwTimeout = INFINITE ); 参数 dwTimeout 以毫秒为单位指定时间等待同步对象可用(终止)。 如果 INFINITE,Lock 将等待,直到对象在返回之前终止状态。 返回值 非零,如果函数运行成功;否则为0。 备注 如果同步对象收到信号,Lock 将成功返回,并且该线程现在拥有对象。 如果同步对象nonsignal...
CSyncObject::Lock 获取对同步对象的访问权限。 CSyncObject::Unlock 获取对同步对象的访问权限。公共运算符展开表 “属性”描述 CSyncObject::operator HANDLE 提供对同步对象的访问权限。公共数据成员展开表 “属性”描述 CSyncObject::m_hObject 基础同步对象的句柄。备注...
CSyncObject::Lock 同步对象的访问权。 CSyncObject::Unlock 同步对象的访问权。 公共运算符 名称 说明 CSyncObject::operator处理 提供对同步对象。 公共数据成员 名称 说明 CSyncObject::m_hObject 对于基础同步对象的句柄。 备注 Microsoft基础选件类库提供从CSyncObject派生的几选件类。这些是CEvent、CMutex、CCriticalSec...
1、纯虚类,作为具体同步类的基类,它只作为一个接口使用 2、有两个关键的成员函数Lock()、UnLock(),CSyncObject后面的四类都通过这两个统一接口进行同步操作。 1)不带参数的 UnLock() 是纯虚函数,在CSyncObject类中没有实现,各子类必须根据需要给出各自的实现。 2)带参数的 UnLock(),默认情况下都返回TRUE。 3...
CSyncObjectConstructs aCSyncObjectobject. Methods LockGains access to the synchronization object. UnlockReleases access to the synchronization object. Attributes operator HANDLEGains access to the synchronization object. CSyncObject Overview|Base Class Members|Hierarchy Chart...
CSyncObject::Lock Gains access to the synchronization object. CSyncObject::Unlock Gains access to the synchronization object. Public Operators 展开表 NameDescription CSyncObject::operator HANDLE Provides access to the synchronization object. Public Data Members 展开表 NameDescription CSyncObject::m_hObject...
CSyncObject::m_hObject Remarks The Microsoft Foundation Class Library provides several classes derived fromCSyncObject. These areCEvent,CMutex,CCriticalSection, andCSemaphore. For information on how to use the synchronization objects, see the articleMultithreading: How to Use the Synchronization Classes. ...
CSyncObject Class Members Public Constructors Public Methods Public Operators Public Data Members Remarks The Microsoft Foundation Class Library provides several classes derived fromCSyncObject. These areCEvent,CMutex,CCriticalSection, andCSemaphore. For information on how to use the synchronization objects, ...
Public Data Members Remarks The Microsoft Foundation Class Library provides several classes derived fromCSyncObject. These areCEvent,CMutex,CCriticalSection, andCSemaphore. For information on how to use the synchronization objects, see the articleMultithreading: How to Use the Synchronization Classes. ...
Public Data Members Remarks The Microsoft Foundation Class Library provides several classes derived fromCSyncObject. These areCEvent,CMutex,CCriticalSection, andCSemaphore. For information on how to use the synchronization objects, see the articleMultithreading: How to Use the Synchronization Classes. ...