mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-09-27 04:40:53 +00:00
Javadoc warnings fixed
(Some JNA docs also changed to standard comments)
This commit is contained in:
@@ -394,7 +394,7 @@ public interface Advapi32 extends StdCallLibrary {
|
||||
public int RegSetValueEx(HKEY hKey, String lpValueName, int Reserved, int dwType,
|
||||
byte[] lpData, int cbData);
|
||||
|
||||
/**
|
||||
/* *
|
||||
*
|
||||
* @param hKey
|
||||
* @param lpSubKey
|
||||
@@ -413,7 +413,7 @@ public interface Advapi32 extends StdCallLibrary {
|
||||
int dwOptions, int samDesired, SECURITY_ATTRIBUTES lpSecurityAttributes,
|
||||
HKEYByReference phkResult, IntByReference lpdwDisposition);
|
||||
|
||||
/**
|
||||
/*
|
||||
*
|
||||
* @param hKey
|
||||
* @param name
|
||||
|
||||
@@ -303,7 +303,7 @@ public interface Gdi32 extends StdCallLibrary {
|
||||
*/
|
||||
int GetDeviceCaps(HDC hdc, int nIndex);
|
||||
|
||||
/**
|
||||
/* *
|
||||
* The GetDIBits function retrieves the bits fo the specified compatible
|
||||
* bitmap and copies them into a buffer as a DIB using the specified format.
|
||||
*
|
||||
|
||||
@@ -27,7 +27,7 @@ public interface Shell32 extends StdCallLibrary {
|
||||
Shell32 INSTANCE = (Shell32) Native.loadLibrary("shell32", Shell32.class,
|
||||
W32APIOptions.UNICODE_OPTIONS);
|
||||
|
||||
/**
|
||||
/* *
|
||||
* @param lpExecInfo
|
||||
* @return true if successful. Otherwise false.
|
||||
*/
|
||||
|
||||
@@ -952,7 +952,7 @@ public interface User32 extends StdCallLibrary, WinUser {
|
||||
*/
|
||||
DWORD SendInput(DWORD nInputs, WinUser.INPUT[] pInputs, int cbSize);
|
||||
|
||||
/**
|
||||
/* *
|
||||
* Waits until the specified process has finished processing its initial
|
||||
* input and is waiting for user input with no input pending, or until the
|
||||
* time-out interval has elapsed.
|
||||
@@ -1099,7 +1099,7 @@ public interface User32 extends StdCallLibrary, WinUser {
|
||||
*/
|
||||
boolean CloseWindow(HWND hWnd);
|
||||
|
||||
/**
|
||||
/* *
|
||||
* Defines a system-wide hot key.
|
||||
*
|
||||
* @param hWnd A handle to the window that will receive
|
||||
@@ -1199,7 +1199,7 @@ public interface User32 extends StdCallLibrary, WinUser {
|
||||
*/
|
||||
public boolean UnregisterClass(WString lpClassName, HINSTANCE hInstance);
|
||||
|
||||
/**
|
||||
/* *
|
||||
* Creates an overlapped, pop-up, or child window with an extended window
|
||||
* style; otherwise, this function is identical to the CreateWindow
|
||||
* function. For more information about creating a window and for full
|
||||
|
||||
@@ -1,181 +1,181 @@
|
||||
/* Copyright (c) 2010,2011 Daniel Doubrovkine, All Rights Reserved
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2.1 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*/
|
||||
package com.sun.jna.platform.win32;
|
||||
|
||||
import com.sun.jna.platform.win32.WinNT.HRESULT;
|
||||
|
||||
// TODO: Auto-generated Javadoc
|
||||
/**
|
||||
* Utility class for some common error functions.
|
||||
*/
|
||||
public abstract class W32Errors implements WinError {
|
||||
|
||||
/**
|
||||
* Generic test for success on any status value (non-negative numbers
|
||||
* indicate success).
|
||||
*
|
||||
* @param hr the hr
|
||||
* @return true, if successful
|
||||
*/
|
||||
public static final boolean SUCCEEDED(int hr) {
|
||||
return hr >= 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* and the inverse.
|
||||
*
|
||||
* @param hr the hr
|
||||
* @return true, if successful
|
||||
*/
|
||||
public static final boolean FAILED(int hr) {
|
||||
return hr < 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Succeeded.
|
||||
*
|
||||
* @param hr the hr
|
||||
* @return true, if successful
|
||||
*/
|
||||
public static final boolean SUCCEEDED(HRESULT hr) {
|
||||
if (hr != null) {
|
||||
return SUCCEEDED(hr.intValue());
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Failed.
|
||||
*
|
||||
* @param hr the hr
|
||||
* @return true, if successful
|
||||
*/
|
||||
public static final boolean FAILED(HRESULT hr) {
|
||||
if (hr != null) {
|
||||
return FAILED(hr.intValue());
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Extract error code from HRESULT.
|
||||
*
|
||||
* @param hr the hr
|
||||
* @return the int
|
||||
*/
|
||||
public static final int HRESULT_CODE(int hr) {
|
||||
return hr & 0xFFFF;
|
||||
}
|
||||
|
||||
/**
|
||||
* Extract error code from SCODE.
|
||||
*
|
||||
* @param sc the sc
|
||||
* @return the int
|
||||
*/
|
||||
public static final int SCODE_CODE(int sc) {
|
||||
return sc & 0xFFFF;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the facility.
|
||||
*
|
||||
* @param hr the hr
|
||||
* @return the int
|
||||
*/
|
||||
public static final int HRESULT_FACILITY(int hr) {
|
||||
return (hr >>= 16) & 0x1fff;
|
||||
}
|
||||
|
||||
/**
|
||||
* Scode facility.
|
||||
*
|
||||
* @param sc the sc
|
||||
* @return the int
|
||||
*/
|
||||
public static final int SCODE_FACILITY(short sc) {
|
||||
return (sc >>= 16) & 0x1fff;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the severity.
|
||||
*
|
||||
* @param hr the hr
|
||||
* @return the short
|
||||
*/
|
||||
public static short HRESULT_SEVERITY(int hr) {
|
||||
return (short) ((hr >>= 31) & 0x1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Scode severity.
|
||||
*
|
||||
* @param sc the sc
|
||||
* @return the short
|
||||
*/
|
||||
public static short SCODE_SEVERITY(short sc) {
|
||||
return (short) ((sc >>= 31) & 0x1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create an HRESULT value from component pieces.
|
||||
*
|
||||
* @param sev the sev
|
||||
* @param fac the fac
|
||||
* @param code the code
|
||||
* @return the int
|
||||
*/
|
||||
public static int MAKE_HRESULT(short sev, short fac, short code) {
|
||||
return ((sev << 31) | (fac << 16) | code);
|
||||
}
|
||||
|
||||
/**
|
||||
* Make scode.
|
||||
*
|
||||
* @param sev the sev
|
||||
* @param fac the fac
|
||||
* @param code the code
|
||||
* @return the int
|
||||
*/
|
||||
public static final int MAKE_SCODE(short sev, short fac, short code) {
|
||||
return ((sev << 31) | (fac << 16) | code);
|
||||
}
|
||||
|
||||
/**
|
||||
* Map a WIN32 error value into a HRESULT Note: This assumes that WIN32
|
||||
* errors fall in the range -32k to=32k.
|
||||
*
|
||||
* @param x original w32 error code
|
||||
* @return the converted value
|
||||
*/
|
||||
public static final HRESULT HRESULT_FROM_WIN32(int x) {
|
||||
int f = FACILITY_WIN32;
|
||||
return new HRESULT(x <= 0 ? x : ((x) & 0x0000FFFF) | (f <<= 16)
|
||||
| 0x80000000);
|
||||
}
|
||||
|
||||
/**
|
||||
* FACILITY_USERMODE_FILTER_MANAGER
|
||||
*
|
||||
* Translation macro for converting: NTSTATUS --> HRESULT.
|
||||
*
|
||||
* @param x the x
|
||||
* @return the int
|
||||
*/
|
||||
public static final int FILTER_HRESULT_FROM_FLT_NTSTATUS(int x) {
|
||||
int f = FACILITY_USERMODE_FILTER_MANAGER;
|
||||
return (((x) & 0x8000FFFF) | (f <<= 16));
|
||||
}
|
||||
}
|
||||
/* Copyright (c) 2010,2011 Daniel Doubrovkine, All Rights Reserved
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2.1 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*/
|
||||
package com.sun.jna.platform.win32;
|
||||
|
||||
import com.sun.jna.platform.win32.WinNT.HRESULT;
|
||||
|
||||
// TODO: Auto-generated Javadoc
|
||||
/**
|
||||
* Utility class for some common error functions.
|
||||
*/
|
||||
public abstract class W32Errors implements WinError {
|
||||
|
||||
/**
|
||||
* Generic test for success on any status value (non-negative numbers
|
||||
* indicate success).
|
||||
*
|
||||
* @param hr the hr
|
||||
* @return true, if successful
|
||||
*/
|
||||
public static final boolean SUCCEEDED(int hr) {
|
||||
return hr >= 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* and the inverse.
|
||||
*
|
||||
* @param hr the hr
|
||||
* @return true, if successful
|
||||
*/
|
||||
public static final boolean FAILED(int hr) {
|
||||
return hr < 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Succeeded.
|
||||
*
|
||||
* @param hr the hr
|
||||
* @return true, if successful
|
||||
*/
|
||||
public static final boolean SUCCEEDED(HRESULT hr) {
|
||||
if (hr != null) {
|
||||
return SUCCEEDED(hr.intValue());
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Failed.
|
||||
*
|
||||
* @param hr the hr
|
||||
* @return true, if successful
|
||||
*/
|
||||
public static final boolean FAILED(HRESULT hr) {
|
||||
if (hr != null) {
|
||||
return FAILED(hr.intValue());
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Extract error code from HRESULT.
|
||||
*
|
||||
* @param hr the hr
|
||||
* @return the int
|
||||
*/
|
||||
public static final int HRESULT_CODE(int hr) {
|
||||
return hr & 0xFFFF;
|
||||
}
|
||||
|
||||
/**
|
||||
* Extract error code from SCODE.
|
||||
*
|
||||
* @param sc the sc
|
||||
* @return the int
|
||||
*/
|
||||
public static final int SCODE_CODE(int sc) {
|
||||
return sc & 0xFFFF;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the facility.
|
||||
*
|
||||
* @param hr the hr
|
||||
* @return the int
|
||||
*/
|
||||
public static final int HRESULT_FACILITY(int hr) {
|
||||
return (hr >>= 16) & 0x1fff;
|
||||
}
|
||||
|
||||
/**
|
||||
* Scode facility.
|
||||
*
|
||||
* @param sc the sc
|
||||
* @return the int
|
||||
*/
|
||||
public static final int SCODE_FACILITY(short sc) {
|
||||
return (sc >>= 16) & 0x1fff;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the severity.
|
||||
*
|
||||
* @param hr the hr
|
||||
* @return the short
|
||||
*/
|
||||
public static short HRESULT_SEVERITY(int hr) {
|
||||
return (short) ((hr >>= 31) & 0x1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Scode severity.
|
||||
*
|
||||
* @param sc the sc
|
||||
* @return the short
|
||||
*/
|
||||
public static short SCODE_SEVERITY(short sc) {
|
||||
return (short) ((sc >>= 31) & 0x1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create an HRESULT value from component pieces.
|
||||
*
|
||||
* @param sev the sev
|
||||
* @param fac the fac
|
||||
* @param code the code
|
||||
* @return the int
|
||||
*/
|
||||
public static int MAKE_HRESULT(short sev, short fac, short code) {
|
||||
return ((sev << 31) | (fac << 16) | code);
|
||||
}
|
||||
|
||||
/**
|
||||
* Make scode.
|
||||
*
|
||||
* @param sev the sev
|
||||
* @param fac the fac
|
||||
* @param code the code
|
||||
* @return the int
|
||||
*/
|
||||
public static final int MAKE_SCODE(short sev, short fac, short code) {
|
||||
return ((sev << 31) | (fac << 16) | code);
|
||||
}
|
||||
|
||||
/**
|
||||
* Map a WIN32 error value into a HRESULT Note: This assumes that WIN32
|
||||
* errors fall in the range -32k to=32k.
|
||||
*
|
||||
* @param x original w32 error code
|
||||
* @return the converted value
|
||||
*/
|
||||
public static final HRESULT HRESULT_FROM_WIN32(int x) {
|
||||
int f = FACILITY_WIN32;
|
||||
return new HRESULT(x <= 0 ? x : ((x) & 0x0000FFFF) | (f <<= 16)
|
||||
| 0x80000000);
|
||||
}
|
||||
|
||||
/* *
|
||||
* FACILITY_USERMODE_FILTER_MANAGER
|
||||
*
|
||||
* Translation macro for converting: NTSTATUS --> HRESULT.
|
||||
*
|
||||
* @param x the x
|
||||
* @return the int
|
||||
*/
|
||||
public static final int FILTER_HRESULT_FROM_FLT_NTSTATUS(int x) {
|
||||
int f = FACILITY_USERMODE_FILTER_MANAGER;
|
||||
return (((x) & 0x8000FFFF) | (f <<= 16));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -346,7 +346,7 @@ public interface WinNT extends WinError, WinDef, WinBase, BaseTSD {
|
||||
Privileges = new LUID_AND_ATTRIBUTES[nbOfPrivileges];
|
||||
}
|
||||
|
||||
/**
|
||||
/* *
|
||||
* Initialize a TOKEN_PRIVILEGES instance from initialized memory.
|
||||
*
|
||||
* @param p
|
||||
@@ -671,7 +671,7 @@ public interface WinNT extends WinError, WinDef, WinBase, BaseTSD {
|
||||
allocateMemory(size);
|
||||
}
|
||||
|
||||
/**
|
||||
/* *
|
||||
* WARNING: this filename may be either the short or long form of the
|
||||
* filename.
|
||||
*
|
||||
@@ -1030,7 +1030,7 @@ public interface WinNT extends WinError, WinDef, WinBase, BaseTSD {
|
||||
immutable = true;
|
||||
}
|
||||
|
||||
/**
|
||||
/* *
|
||||
* Override to the appropriate object for INVALID_HANDLE_VALUE.
|
||||
*
|
||||
* @param nativeValue
|
||||
|
||||
@@ -265,7 +265,7 @@ public interface WinUser extends StdCallLibrary, WinDef {
|
||||
|
||||
public interface WNDENUMPROC extends StdCallCallback {
|
||||
|
||||
/**
|
||||
/* *
|
||||
* Return whether to continue enumeration.
|
||||
*
|
||||
* @param hWnd
|
||||
|
||||
Reference in New Issue
Block a user