xmllite/tests: Fix a memory leak (Valgrind).
[wine.git] / include / metahost.idl
blob549d664c5faac83a3e7a42ee9b33268e3a016aa6
1 /*
2 * Copyright 2010 Vincent Povirk for CodeWeavers
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
19 import "unknwn.idl";
20 import "oaidl.idl";
21 import "ocidl.idl";
22 import "mscoree.idl";
24 cpp_quote("#ifdef WINE_NO_UNICODE_MACROS")
25 cpp_quote("#undef LoadLibrary")
26 cpp_quote("#endif")
28 typedef enum
30 METAHOST_POLICY_HIGHCOMPAT = 0,
31 METAHOST_POLICY_APPLY_UPGRADE_POLICY = 0x08,
32 METAHOST_POLICY_EMULATE_EXE_LAUNCH = 0x10,
33 METAHOST_POLICY_SHOW_ERROR_DIALOG = 0x20,
34 METAHOST_POLICY_USE_PROCESS_IMAGE_PATH = 0x40,
35 METAHOST_POLICY_ENSURE_SKU_SUPPORTED = 0x80
36 } METAHOST_POLICY_FLAGS;
38 typedef enum
40 CLR_DEBUGGING_MANAGED_EVENT_PENDING = 1
41 } CLR_DEBUGGING_PROCESS_FLAGS;
43 typedef struct _CLR_DEBUGGING_VERSION
45 WORD wStructVersion;
46 WORD wMajor;
47 WORD wMinor;
48 WORD wBuild;
49 WORD wRevision;
50 } CLR_DEBUGGING_VERSION;
53 object,
54 local,
55 uuid(bd39d1d2-ba2f-486a-89b0-b4b0cb466891)
57 interface ICLRRuntimeInfo : IUnknown
59 HRESULT GetVersionString(
60 [out, size_is(*pcchBuffer)] LPWSTR pwzBuffer,
61 [in, out] DWORD *pcchBuffer);
63 HRESULT GetRuntimeDirectory(
64 [out, size_is(*pcchBuffer)] LPWSTR pwzBuffer,
65 [in, out] DWORD *pcchBuffer);
67 HRESULT IsLoaded(
68 [in] HANDLE hndProcess,
69 [out, retval] BOOL *pbLoaded);
71 HRESULT LoadErrorString(
72 [in] UINT iResourceID,
73 [out, size_is(*pcchBuffer)] LPWSTR pwzBuffer,
74 [in, out] DWORD *pcchBuffer,
75 [in] LONG iLocaleid);
77 HRESULT LoadLibrary(
78 [in] LPCWSTR pwzDllName,
79 [out, retval] HMODULE *phndModule);
81 HRESULT GetProcAddress(
82 [in] LPCSTR pszProcName,
83 [out, retval] LPVOID *ppProc);
85 HRESULT GetInterface(
86 [in] REFCLSID rclsid,
87 [in] REFIID riid,
88 [out, iid_is(riid), retval] LPVOID *ppUnk);
90 HRESULT IsLoadable(
91 [out, retval] BOOL *pbLoadable);
93 HRESULT SetDefaultStartupFlags(
94 [in] DWORD dwStartupFlags,
95 [in] LPCWSTR pwzHostConfigFile);
97 HRESULT GetDefaultStartupFlags(
98 [out] DWORD *pdwStartupFlags,
99 [out, size_is(*pcchHostConfigFile)] LPWSTR pwzHostConfigFile,
100 [in, out] DWORD *pcchHostConfigFile);
102 HRESULT BindAsLegacyV2Runtime();
104 HRESULT IsStarted(
105 [out] BOOL *pbStarted,
106 [out] DWORD *pdwStartupFlags);
109 typedef HRESULT (__stdcall *CallbackThreadSetFnPtr)();
110 typedef HRESULT (__stdcall *CallbackThreadUnsetFnPtr)();
112 typedef void (__stdcall *RuntimeLoadedCallbackFnPtr)(
113 ICLRRuntimeInfo *pRuntimeInfo,
114 CallbackThreadSetFnPtr pfnCallbackThreadSet,
115 CallbackThreadUnsetFnPtr pfnCallbackThreadUnset);
117 cpp_quote("DEFINE_GUID(CLSID_CLRDebuggingLegacy, 0xDF8395B5,0xA4BA,0x450b,0xA7,0x7C,0xA9,0xA4,0x77,0x62,0xC5,0x20);")
118 cpp_quote("DEFINE_GUID(CLSID_CLRMetaHost, 0x9280188d,0x0e8e,0x4867,0xb3,0x0c,0x7f,0xa8,0x38,0x84,0xe8,0xde);")
121 object,
122 local,
123 uuid(d332db9e-b9b3-4125-8207-a14884f53216)
125 interface ICLRMetaHost : IUnknown
127 HRESULT GetRuntime(
128 [in] LPCWSTR pwzVersion,
129 [in] REFIID iid,
130 [out, iid_is(iid), retval] LPVOID *ppRuntime);
132 HRESULT GetVersionFromFile(
133 [in] LPCWSTR pwzFilePath,
134 [out, size_is(*pcchBuffer)] LPWSTR pwzBuffer,
135 [in, out] DWORD *pcchBuffer);
137 HRESULT EnumerateInstalledRuntimes(
138 [out, retval] IEnumUnknown **ppEnumerator);
140 HRESULT EnumerateLoadedRuntimes(
141 [in] HANDLE hndProcess,
142 [out, retval] IEnumUnknown **ppEnumerator);
144 HRESULT RequestRuntimeLoadedNotification(
145 [in] RuntimeLoadedCallbackFnPtr pCallbackFunction);
147 HRESULT QueryLegacyV2RuntimeBinding(
148 [in] REFIID riid,
149 [out, iid_is(riid), retval] LPVOID *ppUnk);
151 HRESULT ExitProcess(
152 [in] INT32 iExitCode);
156 object,
157 local,
158 uuid(e2190695-77b2-492e-8e14-c4b3a7fdd593)
160 interface ICLRMetaHostPolicy : IUnknown
162 HRESULT GetRequestedRuntime([in] METAHOST_POLICY_FLAGS dwPolicyFlags,
163 [in] LPCWSTR pwzBinary, [in] IStream *pCfgStream,
164 [in, out] LPWSTR pwzVersion, [in, out] DWORD *pcchVersion,
165 [out] LPWSTR pwzImageVersion, [out, in] DWORD *pcchImageVersion,
166 [out] DWORD *pdwConfigFlags, [in] REFIID riid, [retval, out] LPVOID *ppRuntime);
170 uuid(2ebcd49a-1b47-4a61-b13a-4a03701e594b)
172 coclass CLRMetaHostPolicy
174 [default] interface ICLRMetaHostPolicy;
178 object,
179 local,
180 uuid(3151c08d-4d09-4f9b-8838-2880bf18fe51)
182 interface ICLRDebuggingLibraryProvider : IUnknown
184 HRESULT ProvideLibrary([in] const WCHAR *pwszFileName,
185 [in] DWORD dwTimestamp, [in] DWORD dwSizeOfImage,
186 [out] HMODULE *phModule);
190 object,
191 local,
192 uuid(d28f3c5a-9634-4206-a509-477552eefb10)
194 interface ICLRDebugging : IUnknown
196 HRESULT OpenVirtualProcess([in] ULONG64 moduleBaseAddress,
197 [in] IUnknown *pDataTarget, [in] ICLRDebuggingLibraryProvider *pLibraryProvider,
198 [in] CLR_DEBUGGING_VERSION *pMaxDebuggerSupportedVersion,
199 [in] REFIID riidProcess, [out] IUnknown **ppProcess,
200 [out, in] CLR_DEBUGGING_VERSION *pVersion,
201 [out] CLR_DEBUGGING_PROCESS_FLAGS *pdwFlags);
203 HRESULT CanUnloadNow(HMODULE hModule);
206 cpp_quote("HRESULT WINAPI CLRCreateInstance(REFCLSID clsid, REFIID riid, LPVOID *ppInterface);")