-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Closed
Labels
Description
Provide complete information about the problem
- Version of JNA and related jars: 5.13.0
- Version and vendor of the java virtual machine: OpenJDK 17.0.8 LTS
- Operating system: Windows
- System architecture (CPU type, bitness of the JVM): x86-64, 64-Bit
- Complete description of the problem: Win32 API functions
SetPriorityClass()andSetThreadPriority()are missing from thecom.sun.jna.platform.win32.Kernel32class (fromjna-platform-5.13.0.jar) - Steps to reproduce: Add
jna-platform-5.13.0.jarto the class path and try to call the missing functionsSetPriorityClass()orSetThreadPriority()fromKernel32.INSTANCE; they are not currently available 😞
Obviously, those functions, which have been available from Kernel32.DLL since (at least) Windows XP, have been forgotten in the implementation of com.sun.jna.platform.win32.Kernel32. Please consider adding the missing functions 😏
These functions are very useful to change the priority of a process and/or thread.
SetPriorityClass function
Sets the priority class for the specified process. This value together with the priority value of each thread of the process determines each thread's base priority level.
BOOL SetPriorityClass( [in] HANDLE hProcess, [in] DWORD dwPriorityClass );Requirements
Minimum supported client: Windows XP
Minimum supported server: Windows Server 2003
Header: processthreadsapi.h
Library: Kernel32.lib
DLL: Kernel32.dll
Thanks!