mn::system::basic_critical_section_nested Class Reference

#include <mn_criticalsection.hpp>

+ Inheritance diagram for mn::system::basic_critical_section_nested:
+ Collaboration diagram for mn::system::basic_critical_section_nested:

Public Member Functions

virtual int lock (unsigned int timeout=UINT_MAX)
 
virtual int unlock ()
 
- Public Member Functions inherited from mn::system::ISystemLockObject
virtual int time_lock (const struct timespec *timeout)
 
virtual bool is_initialized ()
 
- Public Member Functions inherited from mn::ILockObject
 ILockObject ()
 
virtual bool try_lock ()
 
virtual bool is_initialized () const =0
 
virtual bool is_locked () const =0
 Is locked? More...
 

Protected Attributes

unsigned int m_iState
 

Additional Inherited Members

- Public Types inherited from mn::ILockObject
using this_type = ILockObject
 

Detailed Description

Wrapper class around FreeRTOS's implementation of a critical sections nested.

Member Function Documentation

◆ lock()

int mn::system::basic_critical_section_nested::lock ( unsigned int  timeout = UINT_MAX)
virtual

enter the critical section nested

Parameters
timeoutHow long to wait (in ticks) to get the lock until giving up. By a given UINT_MAX then then use no timeout
Returns
ERR_SYSTEM_OK if enter in the critical section and ERR_SYSTEM_LOCK if it timed out.

Implements mn::ILockObject.

◆ unlock()

int mn::system::basic_critical_section_nested::unlock ( )
virtual

leave the critical section nested

Returns
ERR_SYSTEM_NO_RETURN

Implements mn::ILockObject.

Member Data Documentation

◆ m_iState

unsigned int mn::system::basic_critical_section_nested::m_iState
protected

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