JNA API 3.5.2-SNAPSHOT

## com.sun.jna.platform.win32.COM
Class COMObject

    java.lang.Object
      com.sun.jna.platform.win32.COM.COMObject

    public class COMObject

extends java.lang.Object

Helper class to provide basic COM support.

Author:
  Tobias Wolf, wolf.tobias@gmx.net

Field Summary
`protected IDispatch` `iDispatch`
`protected IUnknown` `iUnknown`
`static WinDef.LCID` `LOCALE_SYSTEM_DEFAULT`
`static WinDef.LCID` `LOCALE_USER_DEFAULT`

Constructor Summary
`COMObject(IDispatch iDispatch)`
`COMObject(java.lang.String progId, boolean useActiveInstance)` Instantiates a new cOM object.

Method Summary
`protected void` `checkFailed(WinNT.HRESULT hr)`
`IDispatch` `getIDispatch()`
`PointerByReference` `getIDispatchPointer()`
`IUnknown` `getIUnknown()`
`PointerByReference` `getIUnknownPointer()`
`protected WinNT.HRESULT` `oleMethod(int nType, Variant.VARIANT.ByReference pvResult, IDispatch pDisp, java.lang.String name)`
`protected WinNT.HRESULT` `oleMethod(int nType, Variant.VARIANT.ByReference pvResult, IDispatch pDisp, java.lang.String name, Variant.VARIANT pArg)`
`protected WinNT.HRESULT` `oleMethod(int nType, Variant.VARIANT.ByReference pvResult, IDispatch pDisp, java.lang.String name, Variant.VARIANT[] pArgs)`
`void` `release()`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### LOCALE_USER_DEFAULT

    public static final WinDef.LCID LOCALE_USER_DEFAULT

### LOCALE_SYSTEM_DEFAULT

    public static final WinDef.LCID LOCALE_SYSTEM_DEFAULT

### iUnknown

    protected IUnknown iUnknown

### iDispatch

    protected IDispatch iDispatch

Constructor Detail

### COMObject

    public COMObject(IDispatch iDispatch)

### COMObject

    public COMObject(java.lang.String progId,
                     boolean useActiveInstance)
              throws COMException

  Instantiates a new cOM object.

  Parameters:
    `progId` - the prog id
    `useActiveInstance` - the use active instance
  Throws:
    `COMException` - the automation exception

Method Detail

### oleMethod

    protected WinNT.HRESULT oleMethod(int nType,
                                      Variant.VARIANT.ByReference pvResult,
                                      IDispatch pDisp,
                                      java.lang.String name,
                                      Variant.VARIANT[] pArgs)
                               throws COMException

  Throws:
    `COMException`

### oleMethod

    protected WinNT.HRESULT oleMethod(int nType,
                                      Variant.VARIANT.ByReference pvResult,
                                      IDispatch pDisp,
                                      java.lang.String name,
                                      Variant.VARIANT pArg)
                               throws COMException

  Throws:
    `COMException`

### oleMethod

    protected WinNT.HRESULT oleMethod(int nType,
                                      Variant.VARIANT.ByReference pvResult,
                                      IDispatch pDisp,
                                      java.lang.String name)
                               throws COMException

  Throws:
    `COMException`

### checkFailed

    protected void checkFailed(WinNT.HRESULT hr)

### getIDispatch

    public IDispatch getIDispatch()

### getIDispatchPointer

    public PointerByReference getIDispatchPointer()

### getIUnknown

    public IUnknown getIUnknown()

### getIUnknownPointer

    public PointerByReference getIUnknownPointer()

### release

    public void release()

JNA API 3.5.2-SNAPSHOT

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