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 20 of file ThreadImpl.h.

Constructor & Destructor Documentation

◆ ~ThreadImpl()

ThreadImpl::~ThreadImpl ( )
virtual

Definition at line 95 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 171 of file ThreadImpl.cpp.

◆ askToClose()

void ThreadImpl::askToClose ( )

Definition at line 162 of file ThreadImpl.cpp.

◆ beforeStart()

void ThreadImpl::beforeStart ( )
virtual

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

Definition at line 167 of file ThreadImpl.cpp.

◆ close()

◆ getCount()

int ThreadImpl::getCount ( )
static

Definition at line 241 of file ThreadImpl.cpp.

◆ getKey()

long int ThreadImpl::getKey ( )

Definition at line 102 of file ThreadImpl.cpp.

◆ getKeyOfCaller()

long int ThreadImpl::getKeyOfCaller ( )
static

Definition at line 108 of file ThreadImpl.cpp.

◆ getPolicy()

int ThreadImpl::getPolicy ( )

Definition at line 304 of file ThreadImpl.cpp.

◆ getPriority()

int ThreadImpl::getPriority ( )

Definition at line 277 of file ThreadImpl.cpp.

◆ getTid()

long ThreadImpl::getTid ( )

Definition at line 331 of file ThreadImpl.cpp.

◆ isClosing()

bool ThreadImpl::isClosing ( )

Definition at line 231 of file ThreadImpl.cpp.

◆ isRunning()

bool ThreadImpl::isRunning ( )

Definition at line 236 of file ThreadImpl.cpp.

◆ join()

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

Definition at line 120 of file ThreadImpl.cpp.

◆ notify()

void ThreadImpl::notify ( bool  s)

Definition at line 226 of file ThreadImpl.cpp.

◆ notifyOpened()

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

Definition at line 52 of file ThreadImpl.h.

◆ run()

◆ setPriority()

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

Definition at line 246 of file ThreadImpl.cpp.

◆ start()

bool ThreadImpl::start ( )
virtual

◆ synchroPost()

void ThreadImpl::synchroPost ( )

Definition at line 221 of file ThreadImpl.cpp.

◆ synchroWait()

void ThreadImpl::synchroWait ( )

Definition at line 216 of file ThreadImpl.cpp.

◆ threadInit()

bool ThreadImpl::threadInit ( )
virtual

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

Definition at line 175 of file ThreadImpl.cpp.

◆ threadRelease()

void ThreadImpl::threadRelease ( )
virtual

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

Definition at line 180 of file ThreadImpl.cpp.

◆ yield()

void ThreadImpl::yield ( )
static

Definition at line 336 of file ThreadImpl.cpp.

Member Data Documentation

◆ id

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

Definition at line 65 of file ThreadImpl.h.

◆ tid

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

Definition at line 64 of file ThreadImpl.h.


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