FRWScopeLock

Keeps a FRWLock read- or write-locked while this scope lives

Windows
MacOS
Linux

References

Module

Core

Header

/Engine/Source/Runtime/Core/Public/Misc/ScopeRWLock.h

Include

#include "Misc/ScopeRWLock.h"

Syntax

class FRWScopeLock

Remarks

Keeps a FRWLock read- or write-locked while this scope lives

Notes:

  • PThreads and Win32 API's don't provide a mechanism for upgrading a ownership of a read lock to a write lock - to get round that this system unlocks then acquires a write lock so it can race between.

Constructors

Name Description

Public function

FRWScopeLock

(
    FRWLock& InLockObject,
    FRWScopeLockType InLockType
)

Destructors

Name Description

Public function

~FRWScopeLock()

Functions

Name Description

Public function

void

 

ReleaseReadOnlyLockAndAcquireWriteLock_USE_WITH_CAUTION()

It releases the read lock before acquiring a new write lock.

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss