ethread Namespace Reference

Functions

uint32_t getId ()
 
uint32_t getId (std::thread &_thread)
 
void setName (const std::string &_name)
 
void setName (std::thread &_thread, const std::string &_name)
 
std::string getName ()
 
std::string getName (std::thread &_thread)
 
void setPriority (int32_t _priority)
 
void setPriority (std::thread &_thread, int32_t _priority)
 
int32_t getPriority ()
 
int32_t getPriority (std::thread &_thread)
 

Detailed Description

ethread main namespace

Author
Edouard DUPIN
Note
License: APACHE v2.0 (see license file)

Function Documentation

§ getId() [1/2]

uint32_t ethread::getId ( )

get human readable thread ID. (not the std::thread::get_id())

Returns
the ID of the thread.

§ getId() [2/2]

uint32_t ethread::getId ( std::thread &  _thread)

get human readable thread ID. (not the std::thread::get_id())

Parameters
[in]_threadThread handle
Returns
the ID of the thread.

§ getName() [1/2]

std::string ethread::getName ( )

Set the Current thread name.

Returns
The current name of the thread

§ getName() [2/2]

std::string ethread::getName ( std::thread &  _thread)

Get an other thread name.

Parameters
[in]_threadThread handle
Returns
The external thread name of the thread

§ getPriority() [1/2]

int32_t ethread::getPriority ( )

get the Current thread priority [-20..0] for RT and ]0..50] for normal priority

Returns
current priority of the thread

§ getPriority() [2/2]

int32_t ethread::getPriority ( std::thread &  _thread)

Get an other thread priority [-20..0] for RT and ]0..50] for normal priority.

Parameters
[in]_threadThread handle
Returns
current priority of the thread

§ setName() [1/2]

void ethread::setName ( const std::string &  _name)

Set the Current thread name.

Parameters
[in]_nameNew name of the thread

§ setName() [2/2]

void ethread::setName ( std::thread &  _thread,
const std::string &  _name 
)

Set an other thread name.

Parameters
[in]_threadThread handle
[in]_nameNew name of the thread

§ setPriority() [1/2]

void ethread::setPriority ( int32_t  _priority)

Set the Current thread priority [-20..0] for RT and ]0..50] for normal priority.

Parameters
[in]_priorityNew priority of the thread
Note
If your process have not the right to change thread name, it does not work

§ setPriority() [2/2]

void ethread::setPriority ( std::thread &  _thread,
int32_t  _priority 
)

Set an other thread priority [-20..0] for RT and ]0..50] for normal priority.

Parameters
[in]_threadThread handle
[in]_priorityNew priority of the thread
Note
If your process have not the right to change thread name, it does not work