#include "ktypes.h"
Defines | |
| #define | KThread_create(run_function, datas, name) _KThread_create(run_function, datas, name, __K_FILE__, __K_LINE__) |
| Creates a thread. | |
| #define | KThread_destroy(kThread) _KThread_destroy (kThread, __K_FILE__, __K_LINE__) |
| Deletes a thread and stops if it is in execution state. | |
| #define | KThread_kill(kThread) _KThread_kill (kThread, __K_FILE__, __K_LINE__) |
| Kills the thread. | |
| #define | KThread_wait(kThread, ret) _KThread_wait (kThread, ret, __K_FILE__, __K_LINE__) |
| Waits the end of the thread execution. | |
Typedefs | |
| typedef _KThread | KThread |
| Thread. | |
| typedef KInt( | KThread_Function )(KPtr) |
| functions called by threads | |
Functions | |
| KTL_API KThread * | _KThread_create (KThread_Function *run_function, KPtr datas, KString name, KString sFile, KInt32 iLine) |
| Creates a thread. | |
| KTL_API KBool | KThread_setStopFunc (KThread *kThread, KThread_Stop_Function *stop_function) |
| ?? | |
| KTL_API KBool | KThread_stop (KThread *kThread) |
| Stops the execution of a thread. | |
| KTL_API KBool | KThread_start (KThread *kThread) |
| Starts the execution of a thread. | |
| KTL_API void | _KThread_destroy (KThread **kThread, KString file, KInt line) |
| Deletes a thread and stops if it is in execution state. | |
| KTL_API KBool | _KThread_kill (KThread *kThread, KString file, KInt line) |
| Kills the thread. | |
| KTL_API KBool | _KThread_wait (KThread *kThread, KInt *n, KString file, KInt line) |
| Waits the end of the thread execution. | |
| KTL_API KBool | KThread_isStarted (KThread *kThread) |
| Indicates if a thread is launched. The thread can be in an execution state, blocked or ended. | |
| KTL_API KString | KThread_GetCurrentThreadName () |
| Gets the current name of a thread. | |
| KTL_API KInt | KThread_GetCurrentThreadId () |
| Gets the ID of a thread. | |
| KTL_API KBool | KThread_initControl () |
| Initializes the control for a thread. | |
| KTL_API KBool | KThread_closeControl () |
| Closes the control for a thread. | |
| KTL_API KBool | KThread_setPriority (KThread *kThread, KInt iPriority) |
| Changes a thread priority. | |
|
|
Creates a thread.
|
|
|
Deletes a thread and stops if it is in execution state.
|
|
|
Kills the thread.
|
|
|
Waits the end of the thread execution.
|
|
||||||||||||||||||||||||
|
Creates a thread.
|
|
||||||||||||||||
|
Deletes a thread and stops if it is in execution state.
|
|
||||||||||||||||
|
Kills the thread.
|
|
||||||||||||||||||||
|
Waits the end of the thread execution.
|
|
|
Closes the control for a thread.
|
|
|
Gets the ID of a thread.
|
|
|
Gets the current name of a thread.
|
|
|
Initializes the control for a thread.
|
|
|
Indicates if a thread is launched. The thread can be in an execution state, blocked or ended.
|
|
||||||||||||
|
Changes a thread priority.
|
|
||||||||||||
|
??
|
|
|
Starts the execution of a thread.
|
|
|
Stops the execution of a thread.
|
1.3.8