#include <thread_manager.hpp>
dcf::ThreadManager::ThreadManager |
( |
| ) |
|
virtual dcf::ThreadManager::~ThreadManager |
( |
| ) |
|
|
virtual |
Clones this object and returns pointer of copy.
Implements dcf::Manager.
virtual size_t dcf::ThreadManager::getUnitsCount |
( |
| ) |
const |
|
virtual |
virtual dcf::error_t dcf::ThreadManager::isAllocatedUnit |
( |
int |
unit_id, |
|
|
bool & |
is_allocated |
|
) |
| const |
|
virtual |
Is CPU with provided id allocated. Returns ErrSuccess if all good.
Implements dcf::Manager.
Tries to allocate next unit in system. Gets allocated unit id.
Returns ErrSuccess if all good.
virtual dcf::error_t dcf::ThreadManager::unitAlloc |
( |
int |
unit_id | ) |
|
|
virtual |
Only sends message that CPU with provided id is allocated.
Returns ErrSuccess if all good.
Implements dcf::Manager.
virtual dcf::error_t dcf::ThreadManager::unitFree |
( |
int |
unit_id | ) |
|
|
virtual |
Only removes message about allocated CPU with provided id and
from own PID. Returns ErrSuccess if all good.
Implements dcf::Manager.
virtual dcf::error_t dcf::ThreadManager::unitPower |
( |
int |
unit_id, |
|
|
double & |
power |
|
) |
| const |
|
virtual |
Gets power of CPU with provided id. Returns ErrSuccess if all good.
Implements dcf::Manager.
Removes messages about all allocated CPUs from own PID.
Returns ErrSuccess if all good.
Implements dcf::Manager.
The documentation for this class was generated from the following file: