Public Types | Public Member Functions | Private Member Functions | Private Attributes | List of all members
canopen::Timer Class Reference

#include <timer.h>

Public Types

typedef fastdelegate::FastDelegate0< bool > TimerDelegate
 

Public Member Functions

const boost::chrono::high_resolution_clock::duration & getPeriod ()
 
void restart ()
 
template<typename T >
void start (const TimerDelegate &del, const T &dur, bool start_now=true)
 
void stop ()
 
 Timer ()
 
 ~Timer ()
 

Private Member Functions

void handler (const boost::system::error_code &ec)
 

Private Attributes

TimerDelegate delegate
 
boost::asio::io_service io
 
boost::mutex mutex
 
boost::chrono::high_resolution_clock::duration period
 
boost::thread thread
 
boost::asio::basic_waitable_timer< boost::chrono::high_resolution_clock > timer
 
boost::asio::io_service::work work
 

Detailed Description

Definition at line 11 of file timer.h.

Member Typedef Documentation

Definition at line 13 of file timer.h.

Constructor & Destructor Documentation

canopen::Timer::Timer ( )
inline

Definition at line 14 of file timer.h.

canopen::Timer::~Timer ( )
inline

Definition at line 39 of file timer.h.

Member Function Documentation

const boost::chrono::high_resolution_clock::duration& canopen::Timer::getPeriod ( )
inline

Definition at line 35 of file timer.h.

void canopen::Timer::handler ( const boost::system::error_code &  ec)
inlineprivate

Definition at line 53 of file timer.h.

void canopen::Timer::restart ( )
inline

Definition at line 30 of file timer.h.

template<typename T >
void canopen::Timer::start ( const TimerDelegate del,
const T &  dur,
bool  start_now = true 
)
inline

Definition at line 21 of file timer.h.

void canopen::Timer::stop ( )
inline

Definition at line 17 of file timer.h.

Member Data Documentation

TimerDelegate canopen::Timer::delegate
private

Definition at line 52 of file timer.h.

boost::asio::io_service canopen::Timer::io
private

Definition at line 45 of file timer.h.

boost::mutex canopen::Timer::mutex
private

Definition at line 49 of file timer.h.

boost::chrono::high_resolution_clock::duration canopen::Timer::period
private

Definition at line 48 of file timer.h.

boost::thread canopen::Timer::thread
private

Definition at line 50 of file timer.h.

boost::asio::basic_waitable_timer<boost::chrono::high_resolution_clock> canopen::Timer::timer
private

Definition at line 47 of file timer.h.

boost::asio::io_service::work canopen::Timer::work
private

Definition at line 46 of file timer.h.


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


canopen_master
Author(s): Mathias L├╝dtke
autogenerated on Sat May 4 2019 02:40:43