PLCnext API Documentation  22.9.0.33
Public Member Functions | List of all members
Arp::System::Commons::Threading::LockGuard Class Reference

Simple lock guard, acquiring lock on construction and release it on destruction. More...

#include <LockGuard.hpp>

Public Member Functions

 LockGuard (Mutex &mutex)
 Constructs an LockGuard instance and acquires the assgned lock. More...
 
 LockGuard (const LockGuard &arg)=delete
 Copy constructor. More...
 
LockGuardoperator= (const LockGuard &arg)=delete
 Assignment operator. More...
 
 ~LockGuard (void)
 Destructs this instance and releases the lock. More...
 

Detailed Description

Simple lock guard, acquiring lock on construction and release it on destruction.

Constructor & Destructor Documentation

◆ LockGuard() [1/2]

Arp::System::Commons::Threading::LockGuard::LockGuard ( Mutex mutex)
inline

Constructs an LockGuard instance and acquires the assgned lock.

Parameters
mutexInstance of mutex to lock.

◆ LockGuard() [2/2]

Arp::System::Commons::Threading::LockGuard::LockGuard ( const LockGuard arg)
delete

Copy constructor.

◆ ~LockGuard()

Arp::System::Commons::Threading::LockGuard::~LockGuard ( void  )
inline

Destructs this instance and releases the lock.

Member Function Documentation

◆ operator=()

LockGuard& Arp::System::Commons::Threading::LockGuard::operator= ( const LockGuard arg)
delete

Assignment operator.


The documentation for this class was generated from the following file: