use of com.sun.jna.platform.win32.WinNT.HRESULT in project jna by java-native-access.
the class RunningObjectTable method GetTimeOfLastChange.
@Override
public HRESULT GetTimeOfLastChange(Pointer pmkObjectName, FILETIME.ByReference pfiletime) {
final int vTableId = 8;
WinNT.HRESULT hr = (WinNT.HRESULT) this._invokeNativeObject(vTableId, new Object[] { this.getPointer(), pmkObjectName, pfiletime }, WinNT.HRESULT.class);
return hr;
}
use of com.sun.jna.platform.win32.WinNT.HRESULT in project jna by java-native-access.
the class RunningObjectTable method Register.
// The magic number values for (vTableId) below, are worked out by
// counting the number of methods in the full interface (0 indexed), as this
// inherits IUnknown, which has 3 methods, we start here at 3.
@Override
public HRESULT Register(DWORD grfFlags, Pointer punkObject, Pointer pmkObjectName, DWORDByReference pdwRegister) {
final int vTableId = 3;
WinNT.HRESULT hr = (WinNT.HRESULT) this._invokeNativeObject(vTableId, new Object[] { this.getPointer(), grfFlags, punkObject, pmkObjectName, pdwRegister }, WinNT.HRESULT.class);
return hr;
}
use of com.sun.jna.platform.win32.WinNT.HRESULT in project jna by java-native-access.
the class RunningObjectTable method NoteChangeTime.
@Override
public HRESULT NoteChangeTime(DWORD dwRegister, FILETIME pfiletime) {
final int vTableId = 7;
WinNT.HRESULT hr = (WinNT.HRESULT) this._invokeNativeObject(vTableId, new Object[] { this.getPointer(), dwRegister, pfiletime }, WinNT.HRESULT.class);
return hr;
}
use of com.sun.jna.platform.win32.WinNT.HRESULT in project jna by java-native-access.
the class TypeInfoUtil method CreateInstance.
/**
* Creates the instance.
*
* @param pUnkOuter
* the unk outer
* @param riid
* the riid
* @return the pointer by reference
*/
public PointerByReference CreateInstance(IUnknown pUnkOuter, REFIID riid) {
PointerByReference ppvObj = new PointerByReference();
HRESULT hr = this.typeInfo.CreateInstance(pUnkOuter, riid, ppvObj);
COMUtils.checkRC(hr);
return ppvObj;
}
use of com.sun.jna.platform.win32.WinNT.HRESULT in project jna by java-native-access.
the class TypeInfoUtil method getDocumentation.
/**
* Gets the documentation.
*
* @param memid
* the memid
* @return the documentation
*/
public TypeInfoDoc getDocumentation(MEMBERID memid) {
BSTRByReference pBstrName = new BSTRByReference();
BSTRByReference pBstrDocString = new BSTRByReference();
DWORDByReference pdwHelpContext = new DWORDByReference();
BSTRByReference pBstrHelpFile = new BSTRByReference();
HRESULT hr = this.typeInfo.GetDocumentation(memid, pBstrName, pBstrDocString, pdwHelpContext, pBstrHelpFile);
COMUtils.checkRC(hr);
TypeInfoDoc TypeInfoDoc = new TypeInfoDoc(pBstrName.getString(), pBstrDocString.getString(), pdwHelpContext.getValue().intValue(), pBstrHelpFile.getString());
OLEAUTO.SysFreeString(pBstrName.getValue());
OLEAUTO.SysFreeString(pBstrDocString.getValue());
OLEAUTO.SysFreeString(pBstrHelpFile.getValue());
return TypeInfoDoc;
}
Aggregations