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 
41  void exit(int32_t *status);
42 
48  bool join(int32_t *status);
49 
53  bool detach();
54 
57  static bool supportsThreads();
58 
59  #include <rudiments/private/thread.h>
60 };
61 
62 #endif