Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
librealsense::platform::named_mutex Class Reference

#include <backend-v4l2.h>

Public Member Functions

void lock ()
 
void lock () const
 
 named_mutex (const std::string &device_path, unsigned timeout)
 
 named_mutex (const named_mutex &)=delete
 
 named_mutex (const char *id, unsigned timeout)
 
bool try_lock ()
 
bool try_lock () const
 
void unlock ()
 
void unlock () const
 
 ~named_mutex ()
 
 ~named_mutex ()
 

Private Member Functions

void acquire ()
 
void acquire () const
 
void close ()
 
create_and_open_status create_named_mutex (const char *camID)
 
create_and_open_status open_named_mutex (const char *camID)
 
void release ()
 
void release () const
 
void update_id (const char *id)
 

Private Attributes

std::string _device_path
 
int _fildes
 
std::mutex _mutex
 
int _object_lock_counter
 
uint32_t _timeout
 
unsigned _timeout
 
HANDLE _winusb_mutex
 

Static Private Attributes

static std::map< std::string, std::recursive_mutex > _dev_mutex
 
static std::map< std::string, int > _dev_mutex_cnt
 
static std::recursive_mutex _init_mutex
 

Detailed Description

Definition at line 90 of file backend-v4l2.h.

Constructor & Destructor Documentation

librealsense::platform::named_mutex::named_mutex ( const std::string device_path,
unsigned  timeout 
)

Definition at line 112 of file backend-v4l2.cpp.

librealsense::platform::named_mutex::named_mutex ( const named_mutex )
delete
librealsense::platform::named_mutex::~named_mutex ( )

Definition at line 127 of file backend-v4l2.cpp.

librealsense::platform::named_mutex::named_mutex ( const char *  id,
unsigned  timeout 
)

Definition at line 811 of file win-helpers.cpp.

librealsense::platform::named_mutex::~named_mutex ( )

Member Function Documentation

void librealsense::platform::named_mutex::acquire ( )
private

Definition at line 161 of file backend-v4l2.cpp.

void librealsense::platform::named_mutex::acquire ( ) const
private

Definition at line 978 of file win-helpers.cpp.

void librealsense::platform::named_mutex::close ( )
private

Definition at line 1000 of file win-helpers.cpp.

create_and_open_status librealsense::platform::named_mutex::create_named_mutex ( const char *  camID)
private

Definition at line 818 of file win-helpers.cpp.

void librealsense::platform::named_mutex::lock ( )

Definition at line 132 of file backend-v4l2.cpp.

void librealsense::platform::named_mutex::lock ( ) const
inline

Definition at line 159 of file win-helpers.h.

create_and_open_status librealsense::platform::named_mutex::open_named_mutex ( const char *  camID)
private

Definition at line 851 of file win-helpers.cpp.

void librealsense::platform::named_mutex::release ( )
private

Definition at line 187 of file backend-v4l2.cpp.

void librealsense::platform::named_mutex::release ( ) const
private

Definition at line 986 of file win-helpers.cpp.

bool librealsense::platform::named_mutex::try_lock ( )

Definition at line 144 of file backend-v4l2.cpp.

bool librealsense::platform::named_mutex::try_lock ( ) const

Definition at line 973 of file win-helpers.cpp.

void librealsense::platform::named_mutex::unlock ( )

Definition at line 138 of file backend-v4l2.cpp.

void librealsense::platform::named_mutex::unlock ( ) const
inline

Definition at line 160 of file win-helpers.h.

void librealsense::platform::named_mutex::update_id ( const char *  id)
private

Definition at line 876 of file win-helpers.cpp.

Member Data Documentation

std::map< std::string, std::recursive_mutex > librealsense::platform::named_mutex::_dev_mutex
staticprivate

Definition at line 113 of file backend-v4l2.h.

std::map< std::string, int > librealsense::platform::named_mutex::_dev_mutex_cnt
staticprivate

Definition at line 114 of file backend-v4l2.h.

std::string librealsense::platform::named_mutex::_device_path
private

Definition at line 109 of file backend-v4l2.h.

int librealsense::platform::named_mutex::_fildes
private

Definition at line 111 of file backend-v4l2.h.

std::recursive_mutex librealsense::platform::named_mutex::_init_mutex
staticprivate

Definition at line 112 of file backend-v4l2.h.

std::mutex librealsense::platform::named_mutex::_mutex
private

Definition at line 116 of file backend-v4l2.h.

int librealsense::platform::named_mutex::_object_lock_counter
private

Definition at line 115 of file backend-v4l2.h.

uint32_t librealsense::platform::named_mutex::_timeout
private

Definition at line 110 of file backend-v4l2.h.

unsigned librealsense::platform::named_mutex::_timeout
private

Definition at line 170 of file win-helpers.h.

HANDLE librealsense::platform::named_mutex::_winusb_mutex
private

Definition at line 171 of file win-helpers.h.


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


librealsense2
Author(s): Sergey Dorodnicov , Doron Hirshberg , Mark Horn , Reagan Lopez , Itay Carpis
autogenerated on Mon May 3 2021 02:50:39