14 #ifndef THREADPOSIXIMPL_H 15 #define THREADPOSIXIMPL_H 20 #ifdef THREAD_POSIX_IMPL 29 typedef struct _JNIEnv JNIEnv;
37 class EXPCL_PANDA_PIPELINE ThreadPosixImpl {
39 INLINE ThreadPosixImpl(
Thread *parent_obj);
42 void setup_main_thread();
43 bool start(ThreadPriority priority,
bool joinable);
45 INLINE
void preempt();
47 std::string get_unique_id()
const;
49 INLINE
static void prepare_for_exit();
51 INLINE
static Thread *get_current_thread();
52 INLINE
static void bind_thread(
Thread *thread);
53 INLINE
static bool is_threading_supported();
54 INLINE
static bool is_true_threads();
55 INLINE
static bool is_simple_threads();
56 INLINE
static void sleep(
double seconds);
57 INLINE
static void yield();
58 INLINE
static void consider_yield();
61 INLINE JNIEnv *get_jni_env()
const;
62 bool attach_java_vm();
63 static void bind_java_thread();
67 static void *root_func(
void *data);
68 static void init_pt_ptr_index();
78 MutexPosixImpl _mutex;
89 static pthread_key_t _pt_ptr_index;
90 static bool _got_pt_ptr_index;
95 #endif // THREAD_POSIX_IMPL PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
A thread; that is, a lightweight process.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.