WPILibC++  2019.2.1-3-g1349dd4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Modules Pages
Threads.h
1 /*----------------------------------------------------------------------------*/
2 /* Copyright (c) 2016-2018 FIRST. All Rights Reserved. */
3 /* Open Source Software - may be modified and shared by FRC teams. The code */
4 /* must be accompanied by the FIRST BSD license file in the root directory of */
5 /* the project. */
6 /*----------------------------------------------------------------------------*/
7 
8 #pragma once
9 
10 #define NativeThreadHandle const void*
11 
12 #include "hal/Types.h"
13 
20 extern "C" {
30 int32_t HAL_GetThreadPriority(NativeThreadHandle handle, HAL_Bool* isRealTime,
31  int32_t* status);
32 
42 int32_t HAL_GetCurrentThreadPriority(HAL_Bool* isRealTime, int32_t* status);
43 
55 HAL_Bool HAL_SetThreadPriority(NativeThreadHandle handle, HAL_Bool realTime,
56  int32_t priority, int32_t* status);
57 
69 HAL_Bool HAL_SetCurrentThreadPriority(HAL_Bool realTime, int32_t priority,
70  int32_t* status);
71 } // extern "C"
HAL_Bool HAL_SetCurrentThreadPriority(HAL_Bool realTime, int32_t priority, int32_t *status)
Sets the thread priority for the current thread.
int32_t HAL_GetThreadPriority(NativeThreadHandle handle, HAL_Bool *isRealTime, int32_t *status)
Gets the thread priority for the specified thread.
int32_t HAL_GetCurrentThreadPriority(HAL_Bool *isRealTime, int32_t *status)
Gets the thread priority for the current thread.
HAL_Bool HAL_SetThreadPriority(NativeThreadHandle handle, HAL_Bool realTime, int32_t priority, int32_t *status)
Sets the thread priority for the specified thread.