SRWLock::TryLockExclusive Method
Attempts to acquire a SRWLock object in exclusive mode for the current or specified SRWLock object. If the call is successful, the calling thread takes ownership of the lock.
SyncLockExclusive TryLockExclusive();
static SyncLockExclusive TryLockExclusive(
_In_ SRWLOCK* lock
);
Parameters
- lock
Pointer to an SRWLock object.
Return Value
If successful, an SRWLock object in exclusive mode and the calling thread takes ownership of the lock. Otherwise, an SRWLock object whose state is invalid.
Requirements
Header: corewrappers.h
Namespace: Microsoft::WRL::Wrappers