Public Member Functions | Private Attributes | List of all members
watchdog Class Reference

#include <concurrency.h>

Public Member Functions

void kick ()
 
bool running ()
 
void set_timeout (uint64_t timeout_ms)
 
void start ()
 
void stop ()
 
 watchdog (std::function< void()> operation, uint64_t timeout_ms)
 
 ~watchdog ()
 

Private Attributes

bool _kicked = false
 
std::mutex _m
 
std::function< void()> _operation
 
bool _running = false
 
uint64_t _timeout_ms
 
std::shared_ptr< active_object<> > _watcher
 

Detailed Description

Definition at line 427 of file concurrency.h.

Constructor & Destructor Documentation

watchdog::watchdog ( std::function< void()>  operation,
uint64_t  timeout_ms 
)
inline

Definition at line 430 of file concurrency.h.

watchdog::~watchdog ( )
inline

Definition at line 445 of file concurrency.h.

Member Function Documentation

void watchdog::kick ( )
inline

Definition at line 455 of file concurrency.h.

bool watchdog::running ( )
inline

Definition at line 453 of file concurrency.h.

void watchdog::set_timeout ( uint64_t  timeout_ms)
inline

Definition at line 454 of file concurrency.h.

void watchdog::start ( )
inline

Definition at line 451 of file concurrency.h.

void watchdog::stop ( )
inline

Definition at line 452 of file concurrency.h.

Member Data Documentation

bool watchdog::_kicked = false
private

Definition at line 460 of file concurrency.h.

std::mutex watchdog::_m
private

Definition at line 458 of file concurrency.h.

std::function<void()> watchdog::_operation
private

Definition at line 462 of file concurrency.h.

bool watchdog::_running = false
private

Definition at line 461 of file concurrency.h.

uint64_t watchdog::_timeout_ms
private

Definition at line 459 of file concurrency.h.

std::shared_ptr<active_object<> > watchdog::_watcher
private

Definition at line 463 of file concurrency.h.


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


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