|
|
|
|
|
|
|
|
|
|
|
|
| Category: Threads, semaphores, signals and mutex |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| Closes a synchronization event between several threads. |
|
|
|
|
|
|
|
| Opens a synchronization event between several threads. |
|
|
|
|
|
|
|
| Locks the current thread while waiting for the specified event to be opened. |
|
|
|
|
|
|
|
| Closes a synchronization event between several threads. |
|
|
|
|
|
|
|
| Opens a synchronization event between several threads. |
|
|
|
|
|
|
|
| Locks the current thread while waiting for the specified event to be opened. |
|
|
|
|
|
|
|
| Waits for the end of the execution of the specified thread. |
|
|
|
|
|
|
|
| Sends a stop request to a thread. |
|
|
|
|
|
|
|
| The current thread sends a signal to the specified thread in order to unlock it. |
|
|
|
|
|
|
|
| The AutomaticEvent type is used to manage an automatic event. |
|
|
|
|
|
|
|
| Activates a critical section named or on a variable in an instruction of type USE ... IN. |
|
|
|
|
|
|
|
| CriticalSection variables are used to define critical sections to limit the simultaneous execution of a code (procedure, line of code, etc.) to one thread at a given moment in an application. |
|
|
|
|
|
|
|
| Marks the end of a critical section: another thread will be able to run the code. |
|
|
|
|
|
|
|
| Marks the beginning of a critical section: no other thread will be able to run the code as long as the current thread does not exit from the critical section. |
|
|
|
|
|
|
|
| Modifies the status of an event. |
|
|
|
|
|
|
|
| Closes a synchronization event between several threads. |
|
|
|
|
|
|
|
| Explicitly destroys an event. |
|
|
|
|
|
|
|
| Opens a synchronization event between several threads. |
|
|
|
|
|
|
|
| Locks the current thread while waiting for the specified event to be opened. |
|
|
|
|
|
|
|
| Triggers the execution of the procedure specified in the main application thread. |
|
|
|
|
|
|
|
| Executes a procedure in the main thread of the application without waiting for the end of its execution. |
|
|
|
|
|
|
|
| List of functions for managing threads (prefix syntax) |
|
|
|
|
|
|
|
| A mutex is used to limit the simultaneous execution of a code (procedure, line of code, etc.) to one thread at a given time. |
|
|
|
|
|
|
|
| Semaphores are used to limit the simultaneous execution of a code (procedure, line of code, etc. |
|
|
|
|
|
|
|
| Semaphores are used to limit the simultaneous execution of a code (procedure, line of code, etc. |
|
|
|
|
|
|
|
| WINDEV and WINDEV Mobile propose several functions used to perform an advanced management of threads. |
|
|
|
|
|
|
|
| The ManualEvent type is used to manage a manual event. |
|
|
|
|
|
|
|
| Explicitly creates a mutex. |
|
|
|
|
|
|
|
| Explicitly destroys a mutex. |
|
|
|
|
|
|
|
| Signals that the thread frees the mutex. |
|
|
|
|
|
|
|
| Locks the current thread while waiting for the mutex to be freed. |
|
|
|
|
|
|
|
| A secondary thread cannot directly open a window with the standard WLanguage functions such as... |
|
|
|
|
|
|
|
| Explicitly destroys a semaphore. |
|
|
|
|
|
|
|
| Allows one or more threads to exit from the area protected by the semaphore. |
|
|
|
|
|
|
|
| Locks the current thread until the semaphore is opened (which means until a "free" spot becomes available in the protected section). |
|
|
|
|
|
|
|
| Events can be used to synchronize the different threads of an application... |
|
|
|
|
|
|
|
| At runtime, an application runs in a main thread... |
|
|
|
|
|
|
|
| List of functions for managing threads |
|
|
|
|
|
|
|
| List of constants used by the functions for managing threads, critical sections, semaphores, mutexes, ... |
|
|
|
|
|
|
|
| The Thread type allows you to define all the characteristics of a thread. |
|
|
|
|
|
|
|
| Returns the name of the thread currently run.
|
|
|
|
|
|
|
|
| Ends the execution of the current thread. |
|
|
|
|
|
|
|
| Starts the execution of a secondary thread. |
|
|
|
|
|
|
|
| Changes the management mode of threads. |
|
|
|
|
|
|
|
| Pauses the current thread during the specified duration. |
|
|
|
|
|
|
|
| Makes a thread persistent. |
|
|
|
|
|
|
|
| Returns or modifies the priority level of a thread. |
|
|
|
|
|
|
|
| Sends a stop request to a thread. |
|
|
|
|
|
|
|
| Resumes the execution of a thread that was interrupted by ThreadSuspend. Function not recommended. |
|
|
|
|
|
|
|
| The current thread sends a signal to the specified thread in order to unlock it. |
|
|
|
|
|
|
|
| Returns the current status of a thread. |
|
|
|
|
|
|
|
| Stops a secondary thread. Function not recommended. |
|
|
|
|
|
|
|
| Checks if a stop request has been sent to the running thread. |
|
|
|
|
|
|
|
| Temporarily suspends the execution of the specified thread. Function not recommended. |
|
|
|
|
|
|
|
| Waits for the end of the execution of the specified thread. |
|
|
|
|
|
|
|
| Locks the current thread until it receives a signal from another thread. |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|