Package com.sun.jna.platform.win32.COM
Class COMUtils
- java.lang.Object
- 
- com.sun.jna.platform.win32.COM.COMUtils
 
- 
 public abstract class COMUtils extends java.lang.ObjectThe Class COMUtils.- Author:
- wolf.tobias@gmx.net The Class COMUtils.
 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description static classCOMUtils.COMInfoThe Class COMInfo.
 - 
Field SummaryFields Modifier and Type Field Description static intE_UNEXPECTEDstatic intS_FALSEstatic intS_OKThe Constant CO_E_NOTINITIALIZED.
 - 
Constructor SummaryConstructors Constructor Description COMUtils()
 - 
Method SummaryAll Methods Static Methods Concrete Methods Modifier and Type Method Description static voidcheckRC(WinNT.HRESULT hr)Throw new exception.static voidcheckRC(WinNT.HRESULT hr, OaIdl.EXCEPINFO pExcepInfo, IntByReference puArgErr)Check status of HRESULT if it indicates a failed call a COMInvokeException is reaised.static booleancomIsInitialized()Check if COM was initialized correctly.static booleanFAILED(int hr)Failed.static booleanFAILED(WinNT.HRESULT hr)Failed.static java.util.ArrayList<COMUtils.COMInfo>getAllCOMInfoOnSystem()Gets the all com info on system.static booleanSUCCEEDED(int hr)Succeeded.static booleanSUCCEEDED(WinNT.HRESULT hr)Succeeded.
 
- 
- 
- 
Field Detail- 
S_OKpublic static final int S_OK The Constant CO_E_NOTINITIALIZED.- See Also:
- Constant Field Values
 
 - 
S_FALSEpublic static final int S_FALSE - See Also:
- Constant Field Values
 
 - 
E_UNEXPECTEDpublic static final int E_UNEXPECTED - See Also:
- Constant Field Values
 
 
- 
 - 
Method Detail- 
SUCCEEDEDpublic static boolean SUCCEEDED(WinNT.HRESULT hr) Succeeded.- Parameters:
- hr- the hr
- Returns:
- true, if successful
 
 - 
SUCCEEDEDpublic static boolean SUCCEEDED(int hr) Succeeded.- Parameters:
- hr- the hr
- Returns:
- true, if successful
 
 - 
FAILEDpublic static boolean FAILED(WinNT.HRESULT hr) Failed.- Parameters:
- hr- the hr
- Returns:
- true, if successful
 
 - 
FAILEDpublic static boolean FAILED(int hr) Failed.- Parameters:
- hr- the hr
- Returns:
- true, if successful
 
 - 
checkRCpublic static void checkRC(WinNT.HRESULT hr) Throw new exception.- Parameters:
- hr- the hr
 
 - 
checkRCpublic static void checkRC(WinNT.HRESULT hr, OaIdl.EXCEPINFO pExcepInfo, IntByReference puArgErr) Check status of HRESULT if it indicates a failed call a COMInvokeException is reaised.The string members of the pExcepInfo are freed in this call and can't be used afterwards. The structure is not freeed, as it is expected, that is allocated via the Memory object of JNA. - Parameters:
- hr- the hr
- pExcepInfo- the excep info, it is expected
- puArgErr- the pu arg err
 
 - 
getAllCOMInfoOnSystempublic static java.util.ArrayList<COMUtils.COMInfo> getAllCOMInfoOnSystem() Gets the all com info on system.- Returns:
- the all com info on system
 
 - 
comIsInitializedpublic static boolean comIsInitialized() Check if COM was initialized correctly. The initialization status is not changed!This is a debug function, not for normal usage! - Returns:
- whether COM has been initialized
 
 
- 
 
-