19 #ifndef _THREAD_SERVER
20 #define _THREAD_SERVER
77 std::list<CThread> thread_list;
144 std::list<CThread>::iterator
search_thread(
const std::string& thread_id);
239 void attach_thread(
const std::string& thread_id,
void *(*user_thread_function)(
void *param),
void *param);
277 void end_thread(
const std::string& thread_id);
322 int get_thread_state(
const std::string &thread_id);
void create_thread(const std::string &thread_id)
Function to create a new thread.
void start_thread(const std::string &thread_id)
Function to start a thread.
std::list< CThread >::iterator search_thread(const std::string &thread_id)
Function to search for an specific thread.
Implementation of a mutual exclusion mechanism.
void kill_thread(const std::string &thread_id)
Function to immediately terminate a thread.
void end_thread(const std::string &thread_id)
Function to request the termination of a thread.
CThreadServer & operator=(const CThreadServer &object)
assign operator overloading
void delete_thread(const std::string &thread_id)
Function to delete an existing thread.
void attach_thread(const std::string &thread_id, void *(*user_thread_function)(void *param), void *param)
Function to attach a function to a thread.
CThreadServer()
Default constructor.
void detach_thread(const std::string &thread_id)
Function to detach a function from a thread.
static CThreadServer * instance(void)
Function to get a reference to the unique instance.