Package com.sun.jna.platform.win32.WinDef

Examples of com.sun.jna.platform.win32.WinDef.DWORD.intValue()


    HRESULT hr = Ole32.INSTANCE.CoCreateInstance(guid, null, // pOuter =
                                  // null, no
                                  // aggregation
        WTypes.CLSCTX_LOCAL_SERVER, riid, pDispatch);
    assertTrue(W32Errors.SUCCEEDED(hr.intValue()));
    assertTrue(!pDispatch.equals(Pointer.NULL));
    // We leak this iUnknown reference because we don't have the JNACOM lib
    // here to wrap the native iUnknown pointer and call iUnknown.release()
    if (W32Errors.SUCCEEDED(hrCI.intValue()))
      Ole32.INSTANCE.CoUninitialize();
View Full Code Here


       
        PointerByReference ppTInfo = new PointerByReference();
        HRESULT hr = dispatch.GetTypeInfo(new UINT(0), LOCALE_SYSTEM_DEFAULT, ppTInfo);
       
        COMUtils.checkRC(hr);
        assertEquals(0, hr.intValue());
    }

    public void testGetIDsOfNames() {
        Dispatch dispatch = this.createIDispatch();
       
View Full Code Here

        WString[] ptName = new WString[] { new WString("Application") };
        DISPIDByReference pdispID = new DISPIDByReference();

        HRESULT hr = dispatch.GetIDsOfNames(Guid.IID_NULL, ptName, 1, LOCALE_SYSTEM_DEFAULT, pdispID);
        COMUtils.checkRC(hr);
        assertEquals(0, hr.intValue());
    }

    public void testInvoke() {

    }
View Full Code Here

        UINT cMaxNames = new UINT(1);
        UINTByReference pcNames = new UINTByReference();
        HRESULT hr = typeInfo.GetNames(memid, rgBstrNames, cMaxNames, pcNames);

        COMUtils.checkRC(hr);
        assertEquals(0, hr.intValue());
        //System.out.println("rgBstrNames: " + rgBstrNames[0].getValue());
        //System.out.println("pcNames: " + pcNames.getValue().intValue());
    }

    public void testGetRefTypeOfImplType() {
View Full Code Here

        ITypeInfo typeInfo = getTypeInfo();
        HREFTYPEByReference pRefType = new HREFTYPEByReference();
        HRESULT hr = typeInfo.GetRefTypeOfImplType(new UINT(0), pRefType);

        COMUtils.checkRC(hr);
        assertEquals(0, hr.intValue());
        //System.out.println("GetRefTypeOfImplType: " + pRefType.toString());
    }

    public void testGetImplTypeFlags() {
        ITypeInfo typeInfo = getTypeInfo();
View Full Code Here

        ITypeInfo typeInfo = getTypeInfo();
        IntByReference pImplTypeFlags = new IntByReference();
        HRESULT hr = typeInfo.GetImplTypeFlags(new UINT(0), pImplTypeFlags);

        COMUtils.checkRC(hr);
        assertEquals(0, hr.intValue());
        //System.out.println("GetImplTypeFlags: " + pImplTypeFlags.toString());
    }

    public void testGetIDsOfNames() {
        ITypeInfo typeInfo = getTypeInfo();
View Full Code Here

        UINT cNames = new UINT(1);
        MEMBERID[] pMemId = new MEMBERID[1];
        HRESULT hr = typeInfo.GetIDsOfNames(rgszNames, cNames, pMemId);

        COMUtils.checkRC(hr);
        assertEquals(0, hr.intValue());
        //System.out.println("pMemId: " + pMemId.toString());
    }

    public void testInvoke() {
        fail("not implemented due complexity.");
View Full Code Here

        BSTRByReference pBstrHelpFile = new BSTRByReference();
        HRESULT hr = typeInfo.GetDocumentation(memid, pBstrName,
                pBstrDocString, pdwHelpContext, pBstrHelpFile);

        COMUtils.checkRC(hr);
        assertEquals(0, hr.intValue());
        //System.out.println("memid: " + memid.intValue());
        //System.out.println("pBstrName: " + pBstrName.getValue());
        //System.out.println("pBstrDocString: " + pBstrDocString.getValue());
        //System.out.println("pdwHelpContext: " + pdwHelpContext.getValue());
        //System.out.println("pBstrHelpFile: " + pBstrHelpFile.getValue());
View Full Code Here

        WORDByReference pwOrdinal = new WORDByReference();
        HRESULT hr = typeInfo.GetDllEntry(memid, INVOKEKIND.INVOKE_FUNC,
                pBstrDllName, pBstrName, pwOrdinal);

        COMUtils.checkRC(hr);
        assertEquals(0, hr.intValue());
        //System.out.println("memid: " + memid.intValue());
        //System.out.println("pBstrDllName: " + pBstrDllName.getValue());
        //System.out.println("pBstrName: " + pBstrName.getValue());
        //System.out.println("pwOrdinal: " + pwOrdinal.getValue());
    }
View Full Code Here

        PointerByReference ppv = new PointerByReference();
        HRESULT hr = typeInfo.AddressOfMember(memid, INVOKEKIND.INVOKE_FUNC,
                ppv);

        COMUtils.checkRC(hr);
        assertEquals(0, hr.intValue());
        //System.out.println("AddressOfMember: " + ppv.toString());
    }

    public void testCreateInstance() {
        fail("not implemented due complexity.");
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.