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.Object

  The Class COMUtils.
  Author:
    wolf.tobias@gmx.net The Class COMUtils.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `COMUtils.COMInfo` The Class COMInfo.

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static int` | `E_UNEXPECTED`
    `static int` | `S_FALSE`
    `static int` | `S_OK` The Constant CO_E_NOTINITIALIZED.

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `COMUtils()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static void` | `checkRC(WinNT.HRESULT hr)` Throw new exception.
    `static void` | `checkRC(WinNT.HRESULT hr, OaIdl.EXCEPINFO pExcepInfo, IntByReference puArgErr)` Throw new exception.
    `static boolean` | `comIsInitialized()` Check if COM was initialized correctly.
    `static boolean` | `FAILED(int hr)` Failed.
    `static boolean` | `FAILED(WinNT.HRESULT hr)` Failed.
    `static java.util.ArrayList<COMUtils.COMInfo>` | `getAllCOMInfoOnSystem()` Gets the all com info on system.
    `static boolean` | `SUCCEEDED(int hr)` Succeeded.
    `static boolean` | `SUCCEEDED(WinNT.HRESULT hr)` Succeeded.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### S_OK

          public static final int S_OK

      The Constant CO_E_NOTINITIALIZED.
      See Also:
        Constant Field Values

    - #### S_FALSE

          public static final int S_FALSE

      See Also:
        Constant Field Values

    - #### E_UNEXPECTED

          public static final int E_UNEXPECTED

      See Also:
        Constant Field Values

  - ### Constructor Detail

    - #### COMUtils

          public COMUtils()

  - ### Method Detail

    - #### SUCCEEDED

          public static boolean SUCCEEDED(WinNT.HRESULT hr)

      Succeeded.
      Parameters:
        `hr` - the hr
      Returns:
        true, if successful

    - #### SUCCEEDED

          public static boolean SUCCEEDED(int hr)

      Succeeded.
      Parameters:
        `hr` - the hr
      Returns:
        true, if successful

    - #### FAILED

          public static boolean FAILED(WinNT.HRESULT hr)

      Failed.
      Parameters:
        `hr` - the hr
      Returns:
        true, if successful

    - #### FAILED

          public static boolean FAILED(int hr)

      Failed.
      Parameters:
        `hr` - the hr
      Returns:
        true, if successful

    - #### checkRC

          public static void checkRC(WinNT.HRESULT hr)

      Throw new exception.
      Parameters:
        `hr` - the hr

    - #### checkRC

          public static void checkRC(WinNT.HRESULT hr,
                     OaIdl.EXCEPINFO pExcepInfo,
                     IntByReference puArgErr)

      Throw new exception.
      Parameters:
        `hr` - the hr
        `pExcepInfo` - the excep info
        `puArgErr` - the pu arg err

    - #### getAllCOMInfoOnSystem

          public static java.util.ArrayList<COMUtils.COMInfo> getAllCOMInfoOnSystem()

      Gets the all com info on system.
      Returns:
        the all com info on system

    - #### comIsInitialized

          public 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

Copyright © 2007-2016 Timothy Wall. All Rights Reserved.