YARP
Yet Another Robot Platform
yarp::os::impl::ThreadImpl Class Reference

An abstraction for a thread of execution. More...

#include <yarp/os/impl/ThreadImpl.h>

+ Inheritance diagram for yarp::os::impl::ThreadImpl:

Public Member Functions

virtual ~ThreadImpl ()
 
int join (double seconds=-1)
 
virtual void run ()
 
virtual void close ()
 
void askToClose ()
 
virtual bool start ()
 
bool isClosing ()
 
bool isRunning ()
 
virtual void beforeStart ()
 
virtual void afterStart (bool success)
 
virtual bool threadInit ()
 
virtual void threadRelease ()
 
long int getKey ()
 
void notify (bool s)
 
void notifyOpened (bool s)
 
void synchroWait ()
 
void synchroPost ()
 
int setPriority (int priority=-1, int policy=-1)
 
int getPriority ()
 
int getPolicy ()
 
long getTid ()
 

Static Public Member Functions

static int getCount ()
 
static long int getKeyOfCaller ()
 
static void yield ()
 

Public Attributes

long tid {-1}
 
std::thread::id id
 

Detailed Description

An abstraction for a thread of execution.

Definition at line 25 of file ThreadImpl.h.

Constructor & Destructor Documentation

◆ ~ThreadImpl()

ThreadImpl::~ThreadImpl ( )
virtual

Definition at line 98 of file ThreadImpl.cpp.

Member Function Documentation

◆ afterStart()

void ThreadImpl::afterStart ( bool  success)
virtual

Reimplemented in yarp::os::Thread::Private, and yarp::os::PeriodicThread::Private.

Definition at line 174 of file ThreadImpl.cpp.

◆ askToClose()

void ThreadImpl::askToClose ( )

Definition at line 165 of file ThreadImpl.cpp.

◆ beforeStart()

void ThreadImpl::beforeStart ( )
virtual

Reimplemented in yarp::os::Thread::Private, and yarp::os::PeriodicThread::Private.

Definition at line 170 of file ThreadImpl.cpp.

◆ close()

◆ getCount()

int ThreadImpl::getCount ( )
static

Definition at line 244 of file ThreadImpl.cpp.

◆ getKey()

long int ThreadImpl::getKey ( )

Definition at line 105 of file ThreadImpl.cpp.

◆ getKeyOfCaller()

long int ThreadImpl::getKeyOfCaller ( )
static

Definition at line 111 of file ThreadImpl.cpp.

◆ getPolicy()

int ThreadImpl::getPolicy ( )

Definition at line 307 of file ThreadImpl.cpp.

◆ getPriority()

int ThreadImpl::getPriority ( )

Definition at line 280 of file ThreadImpl.cpp.

◆ getTid()

long ThreadImpl::getTid ( )

Definition at line 334 of file ThreadImpl.cpp.

◆ isClosing()

bool ThreadImpl::isClosing ( )

Definition at line 234 of file ThreadImpl.cpp.

◆ isRunning()

bool ThreadImpl::isRunning ( )

Definition at line 239 of file ThreadImpl.cpp.

◆ join()

int ThreadImpl::join ( double  seconds = -1)

Definition at line 123 of file ThreadImpl.cpp.

◆ notify()

void ThreadImpl::notify ( bool  s)

Definition at line 229 of file ThreadImpl.cpp.

◆ notifyOpened()

void yarp::os::impl::ThreadImpl::notifyOpened ( bool  s)
inline

Definition at line 57 of file ThreadImpl.h.

◆ run()

◆ setPriority()

int ThreadImpl::setPriority ( int  priority = -1,
int  policy = -1 
)

Definition at line 249 of file ThreadImpl.cpp.

◆ start()

bool ThreadImpl::start ( )
virtual

◆ synchroPost()

void ThreadImpl::synchroPost ( )

Definition at line 224 of file ThreadImpl.cpp.

◆ synchroWait()

void ThreadImpl::synchroWait ( )

Definition at line 219 of file ThreadImpl.cpp.

◆ threadInit()

bool ThreadImpl::threadInit ( )
virtual

Reimplemented in yarp::os::Thread::Private, and yarp::os::PeriodicThread::Private.

Definition at line 178 of file ThreadImpl.cpp.

◆ threadRelease()

void ThreadImpl::threadRelease ( )
virtual

Reimplemented in yarp::os::Thread::Private, and yarp::os::PeriodicThread::Private.

Definition at line 183 of file ThreadImpl.cpp.

◆ yield()

void ThreadImpl::yield ( )
static

Definition at line 339 of file ThreadImpl.cpp.

Member Data Documentation

◆ id

std::thread::id yarp::os::impl::ThreadImpl::id

Definition at line 70 of file ThreadImpl.h.

◆ tid

long yarp::os::impl::ThreadImpl::tid {-1}

Definition at line 69 of file ThreadImpl.h.


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