summaryrefslogtreecommitdiffhomepage
path: root/Public/Developer/SystemLib/Headers/Thread.h
diff options
context:
space:
mode:
authorAmlal El Mahrouss <amlal.elmahrouss@icloud.com>2024-05-07 17:42:32 +0200
committerAmlal El Mahrouss <amlal.elmahrouss@icloud.com>2024-05-07 17:43:56 +0200
commitca83108fd138cc0398f900e6a6c0a53ad51aee31 (patch)
tree66146e07671517ab1867663081ec39e348205731 /Public/Developer/SystemLib/Headers/Thread.h
parent636a6034a613f98f13848bf4bf1143bf5966dbce (diff)
MHR-23: Rework graphics stack, moving to another repository.
- Alongside patches on the FileManager. - And code improvements on the System API. Signed-off-by: Amlal El Mahrouss <amlal.elmahrouss@icloud.com>
Diffstat (limited to 'Public/Developer/SystemLib/Headers/Thread.h')
-rw-r--r--Public/Developer/SystemLib/Headers/Thread.h16
1 files changed, 10 insertions, 6 deletions
diff --git a/Public/Developer/SystemLib/Headers/Thread.h b/Public/Developer/SystemLib/Headers/Thread.h
index 2bcebdcd..9562003e 100644
--- a/Public/Developer/SystemLib/Headers/Thread.h
+++ b/Public/Developer/SystemLib/Headers/Thread.h
@@ -13,10 +13,9 @@
#include <Headers/Defines.h>
-#define kThreadErrorExit -33
+#define kThreadErrorExit (-33)
-/// @brief Thread Information Block, which holds information about the running
-/// thread.
+/// @brief Thread reference.
typedef QWordType ThreadRef;
/// @brief Main application thread.
@@ -28,16 +27,21 @@ typedef VoidType (*ThreadEntrypointKind)(VoidType);
/// @param threadName the thread's name.
/// @param threadStart where to start.
/// @return
-CA_EXTERN_C ThreadRef TmCreateThread(const CharacterTypeUTF8* threadName, ThreadEntrypointKind threadStart);
+CA_EXTERN_C ThreadRef CTCreate(const CharacterTypeUTF8* threadName, ThreadEntrypointKind threadStart);
/// @brief Dispoes the thread, and exits with code kThreadErrorExit
/// @param ref the thread reference.
/// @return nothing.
-CA_EXTERN_C VoidType TmDisposeThread(ThreadRef ref);
+CA_EXTERN_C VoidType CTRelease(ThreadRef ref);
/// @brief Waits for the thread to complete.
/// @param ref the thread reference.
/// @return nothing.
-CA_EXTERN_C VoidType TmWaitForCompletion(ThreadRef ref);
+CA_EXTERN_C VoidType CTJoin(ThreadRef ref);
+
+/// @brief Yields the current thread.
+/// @param ref the thead reference.
+/// @return
+CA_EXTERN_C VoidType CTYield(ThreadRef ref);
#endif // __THREAD__