Rudiments
thread.h
1 // Copyright (c) 2013 David Muse
2 // See the COPYING file for more information.
3 
4 #ifndef RUDIMENTS_THREAD_H
5 #define RUDIMENTS_THREAD_H
6 
7 #include <rudiments/private/threadincludes.h>
8 
9 class threadprivate;
10 
12 class RUDIMENTS_DLLSPEC thread {
13  public:
15  thread();
16 
18  virtual ~thread();
19 
22  void setFunction(void *(*function)(void *), void *arg);
23 
26  bool setStackSize(size_t stacksize);
27 
30  bool getStackSize(size_t *stacksize);
31 
35  bool create();
36 
40  void exit(int32_t status);
41 
47  bool join(int32_t *status);
48 
52  bool detach();
53 
56  static bool supportsThreads();
57 
58  #include <rudiments/private/thread.h>
59 };
60 
61 #endif