WARNING : this is the documentation for an old version of SFML. The documentation for the latest official release is available through the main menu.
WARNING : this is the documentation for an old version of SFML. The documentation for the latest official release is available through the main menu.
Thread defines an easy way to manipulate a thread. More...
#include <Thread.hpp>
Inheritance diagram for sf::Thread:Public Types | |
| typedef void(* | FuncType )(void *) |
Public Member Functions | |
| Thread (FuncType Function, void *UserData=NULL) | |
| Construct the thread from a function pointer. | |
| virtual | ~Thread () |
| Virtual destructor. | |
| void | Launch () |
| Create and run the thread. | |
| void | Wait () |
| Wait until the thread finishes. | |
| void | Terminate () |
| Terminate the thread Terminating a thread with this function is not safe, you should rather try to make the thread function terminate by itself. | |
Protected Member Functions | |
| Thread () | |
| Default constructor. | |
Thread defines an easy way to manipulate a thread.
There are two ways to use Thread :
Definition at line 44 of file Win32/Thread.hpp.
| sf::Thread::Thread | ( | FuncType | Function, |
| void * | UserData = NULL |
||
| ) |
Construct the thread from a function pointer.
| Function | : Entry point of the thread |
| UserData | : Data to pass to the thread function (NULL by default) |
| virtual sf::Thread::~Thread | ( | ) | [virtual] |
Virtual destructor.
| sf::Thread::Thread | ( | ) | [protected] |
Default constructor.
| void sf::Thread::Launch | ( | ) |
Create and run the thread.
| void sf::Thread::Terminate | ( | ) |
Terminate the thread Terminating a thread with this function is not safe, you should rather try to make the thread function terminate by itself.
| unsigned int Selector::Wait | ( | ) |
Wait until the thread finishes.
Wait and collect sockets which are ready for reading.
This functions will return either when at least one socket is ready, or when the given time is out
Definition at line 72 of file Selector.inl.