msvcrt: Use _exception definiotion from public header.
[wine/zf.git] / include / msiquery.h
blob7f5e4c903a5a1336a75bd14afdad6285c2b72576
1 /*
2 * Copyright (C) 2002,2003 Mike McCormack
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 #ifndef __WINE_MSIQUERY_H
20 #define __WINE_MSIQUERY_H
22 #include <msi.h>
24 typedef enum tagMSICONDITION
26 MSICONDITION_FALSE = 0,
27 MSICONDITION_TRUE = 1,
28 MSICONDITION_NONE = 2,
29 MSICONDITION_ERROR = 3,
30 } MSICONDITION;
32 #define MSI_NULL_INTEGER 0x80000000
34 typedef enum tagMSICOLINFO
36 MSICOLINFO_NAMES = 0,
37 MSICOLINFO_TYPES = 1
38 } MSICOLINFO;
40 typedef enum tagMSICOSTTREE
42 MSICOSTTREE_SELFONLY = 0,
43 MSICOSTTREE_CHILDREN = 1,
44 MSICOSTTREE_PARENTS = 2,
45 MSICOSTTREE_PRODUCT = 3,
46 } MSICOSTTREE;
48 typedef enum tagMSIMODIFY
50 MSIMODIFY_SEEK = -1,
51 MSIMODIFY_REFRESH = 0,
52 MSIMODIFY_INSERT = 1,
53 MSIMODIFY_UPDATE = 2,
54 MSIMODIFY_ASSIGN = 3,
55 MSIMODIFY_REPLACE = 4,
56 MSIMODIFY_MERGE = 5,
57 MSIMODIFY_DELETE = 6,
58 MSIMODIFY_INSERT_TEMPORARY = 7,
59 MSIMODIFY_VALIDATE = 8,
60 MSIMODIFY_VALIDATE_NEW = 9,
61 MSIMODIFY_VALIDATE_FIELD = 10,
62 MSIMODIFY_VALIDATE_DELETE = 11
63 } MSIMODIFY;
65 #ifndef WINE_NO_UNICODE_MACROS
66 #define MSIDBOPEN_READONLY (LPCTSTR)0
67 #define MSIDBOPEN_TRANSACT (LPCTSTR)1
68 #define MSIDBOPEN_DIRECT (LPCTSTR)2
69 #define MSIDBOPEN_CREATE (LPCTSTR)3
70 #define MSIDBOPEN_CREATEDIRECT (LPCTSTR)4
71 #else
72 #define MSIDBOPEN_READONLY (LPCWSTR)0
73 #define MSIDBOPEN_TRANSACT (LPCWSTR)1
74 #define MSIDBOPEN_DIRECT (LPCWSTR)2
75 #define MSIDBOPEN_CREATE (LPCWSTR)3
76 #define MSIDBOPEN_CREATEDIRECT (LPCWSTR)4
77 #endif
79 #define MSIDBOPEN_PATCHFILE 32 / sizeof(*MSIDBOPEN_READONLY)
81 typedef enum tagMSIRUNMODE
83 MSIRUNMODE_ADMIN = 0,
84 MSIRUNMODE_ADVERTISE = 1,
85 MSIRUNMODE_MAINTENANCE = 2,
86 MSIRUNMODE_ROLLBACKENABLED = 3,
87 MSIRUNMODE_LOGENABLED = 4,
88 MSIRUNMODE_OPERATIONS = 5,
89 MSIRUNMODE_REBOOTATEND = 6,
90 MSIRUNMODE_REBOOTNOW = 7,
91 MSIRUNMODE_CABINET = 8,
92 MSIRUNMODE_SOURCESHORTNAMES = 9,
93 MSIRUNMODE_TARGETSHORTNAMES = 10,
94 MSIRUNMODE_RESERVED11 = 11,
95 MSIRUNMODE_WINDOWS9X = 12,
96 MSIRUNMODE_ZAWENABLED = 13,
97 MSIRUNMODE_RESERVED14 = 14,
98 MSIRUNMODE_RESERVED15 = 15,
99 MSIRUNMODE_SCHEDULED = 16,
100 MSIRUNMODE_ROLLBACK = 17,
101 MSIRUNMODE_COMMIT = 18
102 } MSIRUNMODE;
104 typedef enum tagMSIDBERROR
106 MSIDBERROR_INVALIDARG = -3,
107 MSIDBERROR_MOREDATA = -2,
108 MSIDBERROR_FUNCTIONERROR = -1,
109 MSIDBERROR_NOERROR = 0,
110 MSIDBERROR_DUPLICATEKEY = 1,
111 MSIDBERROR_REQUIRED = 2,
112 MSIDBERROR_BADLINK = 3,
113 MSIDBERROR_OVERFLOW = 4,
114 MSIDBERROR_UNDERFLOW = 5,
115 MSIDBERROR_NOTINSET = 6,
116 MSIDBERROR_BADVERSION = 7,
117 MSIDBERROR_BADCASE = 8,
118 MSIDBERROR_BADGUID = 9,
119 MSIDBERROR_BADWILDCARD = 10,
120 MSIDBERROR_BADIDENTIFIER = 11,
121 MSIDBERROR_BADLANGUAGE = 12,
122 MSIDBERROR_BADFILENAME = 13,
123 MSIDBERROR_BADPATH = 14,
124 MSIDBERROR_BADCONDITION = 15,
125 MSIDBERROR_BADFORMATTED = 16,
126 MSIDBERROR_BADTEMPLATE = 17,
127 MSIDBERROR_BADDEFAULTDIR = 18,
128 MSIDBERROR_BADREGPATH = 19,
129 MSIDBERROR_BADCUSTOMSOURCE = 20,
130 MSIDBERROR_BADPROPERTY = 21,
131 MSIDBERROR_MISSINGDATA = 22,
132 MSIDBERROR_BADCATEGORY = 23,
133 MSIDBERROR_BADKEYTABLE = 24,
134 MSIDBERROR_BADMAXMINVALUES = 25,
135 MSIDBERROR_BADCABINET = 26,
136 MSIDBERROR_BADSHORTCUT= 27,
137 MSIDBERROR_STRINGOVERFLOW = 28,
138 MSIDBERROR_BADLOCALIZEATTRIB = 29
139 } MSIDBERROR;
141 typedef enum tagMSIDBSTATE
143 MSIDBSTATE_ERROR = -1,
144 MSIDBSTATE_READ = 0,
145 MSIDBSTATE_WRITE = 1
146 } MSIDBSTATE;
148 typedef enum tagMSITRANSFORM_ERROR
150 MSITRANSFORM_ERROR_ADDEXISTINGROW = 0x00000001,
151 MSITRANSFORM_ERROR_DELMISSINGROW = 0x00000002,
152 MSITRANSFORM_ERROR_ADDEXISTINGTABLE = 0x00000004,
153 MSITRANSFORM_ERROR_DELMISSINGTABLE = 0x00000008,
154 MSITRANSFORM_ERROR_UPDATEMISSINGROW = 0x00000010,
155 MSITRANSFORM_ERROR_CHANGECODEPAGE = 0x00000020,
156 MSITRANSFORM_ERROR_VIEWTRANSFORM = 0x00000100
157 } MSITRANSFORM_ERROR;
159 typedef enum tagMSITRANSFORM_VALIDATE
161 MSITRANSFORM_VALIDATE_LANGUAGE = 0x00000001,
162 MSITRANSFORM_VALIDATE_PRODUCT = 0x00000002,
163 MSITRANSFORM_VALIDATE_PLATFORM = 0x00000004,
164 MSITRANSFORM_VALIDATE_MAJORVERSION = 0x00000008,
165 MSITRANSFORM_VALIDATE_MINORVERSION = 0x00000010,
166 MSITRANSFORM_VALIDATE_UPDATEVERSION = 0x00000020,
167 MSITRANSFORM_VALIDATE_NEWLESSBASEVERSION = 0x00000040,
168 MSITRANSFORM_VALIDATE_NEWLESSEQUALBASEVERSION = 0x00000080,
169 MSITRANSFORM_VALIDATE_NEWEQUALBASEVERSION = 0x00000100,
170 MSITRANSFORM_VALIDATE_NEWGREATEREQUALBASEVERSION = 0x00000200,
171 MSITRANSFORM_VALIDATE_NEWGREATERBASEVERSION = 0x00000400,
172 MSITRANSFORM_VALIDATE_UPGRADECODE = 0x00000800
173 } MSITRANSFORM_VALIDATE;
175 #ifdef __cplusplus
176 extern "C" {
177 #endif
179 /* view manipulation */
180 UINT WINAPI MsiViewFetch(MSIHANDLE,MSIHANDLE*);
181 UINT WINAPI MsiViewExecute(MSIHANDLE,MSIHANDLE);
182 UINT WINAPI MsiViewClose(MSIHANDLE);
183 UINT WINAPI MsiDatabaseOpenViewA(MSIHANDLE,LPCSTR,MSIHANDLE*);
184 UINT WINAPI MsiDatabaseOpenViewW(MSIHANDLE,LPCWSTR,MSIHANDLE*);
185 #define MsiDatabaseOpenView WINELIB_NAME_AW(MsiDatabaseOpenView)
186 MSIDBERROR WINAPI MsiViewGetErrorA(MSIHANDLE,LPSTR,LPDWORD);
187 MSIDBERROR WINAPI MsiViewGetErrorW(MSIHANDLE,LPWSTR,LPDWORD);
188 #define MsiViewGetError WINELIB_NAME_AW(MsiViewGetError)
190 MSIDBSTATE WINAPI MsiGetDatabaseState(MSIHANDLE);
192 /* record manipulation */
193 MSIHANDLE WINAPI MsiCreateRecord(UINT);
194 UINT WINAPI MsiRecordClearData(MSIHANDLE);
195 UINT WINAPI MsiRecordSetInteger(MSIHANDLE,UINT,int);
196 UINT WINAPI MsiRecordSetStringA(MSIHANDLE,UINT,LPCSTR);
197 UINT WINAPI MsiRecordSetStringW(MSIHANDLE,UINT,LPCWSTR);
198 #define MsiRecordSetString WINELIB_NAME_AW(MsiRecordSetString)
199 UINT WINAPI MsiRecordGetStringA(MSIHANDLE,UINT,LPSTR,LPDWORD);
200 UINT WINAPI MsiRecordGetStringW(MSIHANDLE,UINT,LPWSTR,LPDWORD);
201 #define MsiRecordGetString WINELIB_NAME_AW(MsiRecordGetString)
202 UINT WINAPI MsiRecordGetFieldCount(MSIHANDLE);
203 int WINAPI MsiRecordGetInteger(MSIHANDLE,UINT);
204 UINT WINAPI MsiRecordDataSize(MSIHANDLE,UINT);
205 BOOL WINAPI MsiRecordIsNull(MSIHANDLE,UINT);
206 UINT WINAPI MsiFormatRecordA(MSIHANDLE,MSIHANDLE,LPSTR,LPDWORD);
207 UINT WINAPI MsiFormatRecordW(MSIHANDLE,MSIHANDLE,LPWSTR,LPDWORD);
208 #define MsiFormatRecord WINELIB_NAME_AW(MsiFormatRecord)
209 UINT WINAPI MsiRecordSetStreamA(MSIHANDLE,UINT,LPCSTR);
210 UINT WINAPI MsiRecordSetStreamW(MSIHANDLE,UINT,LPCWSTR);
211 #define MsiRecordSetStream WINELIB_NAME_AW(MsiRecordSetStream)
212 UINT WINAPI MsiRecordReadStream(MSIHANDLE,UINT,char*,LPDWORD);
214 UINT WINAPI MsiDatabaseGetPrimaryKeysA(MSIHANDLE,LPCSTR,MSIHANDLE*);
215 UINT WINAPI MsiDatabaseGetPrimaryKeysW(MSIHANDLE,LPCWSTR,MSIHANDLE*);
216 #define MsiDatabaseGetPrimaryKeys WINELIB_NAME_AW(MsiDatabaseGetPrimaryKeys)
218 /* installing */
219 UINT WINAPI MsiDoActionA(MSIHANDLE,LPCSTR );
220 UINT WINAPI MsiDoActionW(MSIHANDLE,LPCWSTR );
221 #define MsiDoAction WINELIB_NAME_AW(MsiDoAction)
223 /* database transforms */
224 UINT WINAPI MsiDatabaseApplyTransformA(MSIHANDLE,LPCSTR,int);
225 UINT WINAPI MsiDatabaseApplyTransformW(MSIHANDLE,LPCWSTR,int);
226 #define MsiDatabaseApplyTransform WINELIB_NAME_AW(MsiDatabaseApplyTransform)
227 UINT WINAPI MsiDatabaseGenerateTransformA(MSIHANDLE,MSIHANDLE,LPCSTR,int,int);
228 UINT WINAPI MsiDatabaseGenerateTransformW(MSIHANDLE,MSIHANDLE,LPCWSTR,int,int);
229 #define MsiDatabaseGenerateTransform WINELIB_NAME_AW(MsiDatabaseGenerateTransform)
231 UINT WINAPI MsiDatabaseCommit(MSIHANDLE);
233 /* install state */
234 UINT WINAPI MsiGetFeatureStateA(MSIHANDLE,LPCSTR,INSTALLSTATE*,INSTALLSTATE*);
235 UINT WINAPI MsiGetFeatureStateW(MSIHANDLE,LPCWSTR,INSTALLSTATE*,INSTALLSTATE*);
236 #define MsiGetFeatureState WINELIB_NAME_AW(MsiGetFeatureState)
237 UINT WINAPI MsiGetFeatureValidStatesA(MSIHANDLE,LPCSTR,LPDWORD);
238 UINT WINAPI MsiGetFeatureValidStatesW(MSIHANDLE,LPCWSTR,LPDWORD);
239 #define MsiGetFeatureValidStates WINELIB_NAME_AW(MsiGetFeatureValidStates)
240 UINT WINAPI MsiSetComponentStateA(MSIHANDLE,LPCSTR,INSTALLSTATE);
241 UINT WINAPI MsiSetComponentStateW(MSIHANDLE,LPCWSTR,INSTALLSTATE);
242 #define MsiSetComponentState WINELIB_NAME_AW(MsiSetComponentState)
243 UINT WINAPI MsiGetComponentStateA(MSIHANDLE,LPCSTR,INSTALLSTATE*,INSTALLSTATE*);
244 UINT WINAPI MsiGetComponentStateW(MSIHANDLE,LPCWSTR,INSTALLSTATE*,INSTALLSTATE*);
245 #define MsiGetComponentState WINELIB_NAME_AW(MsiGetComponentState)
247 MSICONDITION WINAPI MsiEvaluateConditionA(MSIHANDLE,LPCSTR);
248 MSICONDITION WINAPI MsiEvaluateConditionW(MSIHANDLE,LPCWSTR);
249 #define MsiEvaluateCondition WINELIB_NAME_AW(MsiEvaluateCondition)
251 /* property functions */
252 UINT WINAPI MsiGetPropertyA(MSIHANDLE, LPCSTR, LPSTR, LPDWORD);
253 UINT WINAPI MsiGetPropertyW(MSIHANDLE, LPCWSTR, LPWSTR, LPDWORD);
254 #define MsiGetProperty WINELIB_NAME_AW(MsiGetProperty)
256 UINT WINAPI MsiSetPropertyA(MSIHANDLE, LPCSTR, LPCSTR);
257 UINT WINAPI MsiSetPropertyW(MSIHANDLE, LPCWSTR, LPCWSTR);
258 #define MsiSetProperty WINELIB_NAME_AW(MsiSetProperty)
260 UINT WINAPI MsiGetTargetPathA(MSIHANDLE,LPCSTR,LPSTR,LPDWORD);
261 UINT WINAPI MsiGetTargetPathW(MSIHANDLE,LPCWSTR,LPWSTR,LPDWORD);
262 #define MsiGetTargetPath WINELIB_NAME_AW(MsiGetTargetPath)
264 UINT WINAPI MsiSetTargetPathA(MSIHANDLE, LPCSTR, LPCSTR);
265 UINT WINAPI MsiSetTargetPathW(MSIHANDLE, LPCWSTR, LPCWSTR);
266 #define MsiSetTargetPath WINELIB_NAME_AW(MsiSetTargetPath)
268 UINT WINAPI MsiGetSourcePathA(MSIHANDLE,LPCSTR,LPSTR,LPDWORD);
269 UINT WINAPI MsiGetSourcePathW(MSIHANDLE,LPCWSTR,LPWSTR,LPDWORD);
270 #define MsiGetSourcePath WINELIB_NAME_AW(MsiGetSourcePath)
272 MSIHANDLE WINAPI MsiGetActiveDatabase(MSIHANDLE);
274 UINT WINAPI MsiViewGetColumnInfo(MSIHANDLE, MSICOLINFO, MSIHANDLE*);
275 INT WINAPI MsiProcessMessage(MSIHANDLE, INSTALLMESSAGE, MSIHANDLE);
277 UINT WINAPI MsiSetFeatureAttributesA(MSIHANDLE, LPCSTR, DWORD);
278 UINT WINAPI MsiSetFeatureAttributesW(MSIHANDLE, LPCWSTR, DWORD);
279 #define MsiSetFeatureAttributes WINELIB_NAME_AW(MsiSetFeatureAttributes)
281 UINT WINAPI MsiSetFeatureStateA(MSIHANDLE, LPCSTR, INSTALLSTATE);
282 UINT WINAPI MsiSetFeatureStateW(MSIHANDLE, LPCWSTR, INSTALLSTATE);
283 #define MsiSetFeatureState WINELIB_NAME_AW(MsiSetFeatureState)
285 UINT WINAPI MsiPreviewDialogA(MSIHANDLE, LPCSTR);
286 UINT WINAPI MsiPreviewDialogW(MSIHANDLE, LPCWSTR);
287 #define MsiPreviewDialog WINELIB_NAME_AW(MsiPreviewDialog)
289 UINT WINAPI MsiPreviewBillboardA(MSIHANDLE, LPCSTR, LPCSTR);
290 UINT WINAPI MsiPreviewBillboardW(MSIHANDLE, LPCWSTR, LPCWSTR);
291 #define MsiPreviewBillboard WINELIB_NAME_AW(MsiPreviewBillboard)
293 UINT WINAPI MsiCreateTransformSummaryInfoA(MSIHANDLE, MSIHANDLE, LPCSTR, int, int);
294 UINT WINAPI MsiCreateTransformSummaryInfoW(MSIHANDLE, MSIHANDLE, LPCWSTR, int, int);
295 #define MsiCreateTransformSummaryInfo WINELIB_NAME_AW(MsiCreateTransformSummaryInfo)
297 UINT WINAPI MsiGetSummaryInformationA(MSIHANDLE, LPCSTR, UINT, MSIHANDLE *);
298 UINT WINAPI MsiGetSummaryInformationW(MSIHANDLE, LPCWSTR, UINT, MSIHANDLE *);
299 #define MsiGetSummaryInformation WINELIB_NAME_AW(MsiGetSummaryInformation)
301 UINT WINAPI MsiSummaryInfoGetPropertyA(MSIHANDLE,UINT,PUINT,LPINT,FILETIME*,LPSTR,LPDWORD);
302 UINT WINAPI MsiSummaryInfoGetPropertyW(MSIHANDLE,UINT,PUINT,LPINT,FILETIME*,LPWSTR,LPDWORD);
303 #define MsiSummaryInfoGetProperty WINELIB_NAME_AW(MsiSummaryInfoGetProperty)
305 UINT WINAPI MsiSummaryInfoSetPropertyA(MSIHANDLE, UINT, UINT, INT, FILETIME*, LPCSTR);
306 UINT WINAPI MsiSummaryInfoSetPropertyW(MSIHANDLE, UINT, UINT, INT, FILETIME*, LPCWSTR);
307 #define MsiSummaryInfoSetProperty WINELIB_NAME_AW(MsiSummaryInfoSetProperty)
309 UINT WINAPI MsiDatabaseExportA(MSIHANDLE, LPCSTR, LPCSTR, LPCSTR);
310 UINT WINAPI MsiDatabaseExportW(MSIHANDLE, LPCWSTR, LPCWSTR, LPCWSTR);
311 #define MsiDatabaseExport WINELIB_NAME_AW(MsiDatabaseExport)
313 UINT WINAPI MsiDatabaseImportA(MSIHANDLE, LPCSTR, LPCSTR);
314 UINT WINAPI MsiDatabaseImportW(MSIHANDLE, LPCWSTR, LPCWSTR);
315 #define MsiDatabaseImport WINELIB_NAME_AW(MsiDatabaseImport)
317 UINT WINAPI MsiOpenDatabaseW(LPCWSTR, LPCWSTR, MSIHANDLE*);
318 UINT WINAPI MsiOpenDatabaseA(LPCSTR, LPCSTR, MSIHANDLE*);
319 #define MsiOpenDatabase WINELIB_NAME_AW(MsiOpenDatabase)
321 MSICONDITION WINAPI MsiDatabaseIsTablePersistentA(MSIHANDLE, LPCSTR);
322 MSICONDITION WINAPI MsiDatabaseIsTablePersistentW(MSIHANDLE, LPCWSTR);
323 #define MsiDatabaseIsTablePersistent WINELIB_NAME_AW(MsiDatabaseIsTablePersistent)
325 UINT WINAPI MsiSequenceA(MSIHANDLE, LPCSTR, INT);
326 UINT WINAPI MsiSequenceW(MSIHANDLE, LPCWSTR, INT);
327 #define MsiSequence WINELIB_NAME_AW(MsiSequence)
329 UINT WINAPI MsiSummaryInfoPersist(MSIHANDLE);
330 UINT WINAPI MsiSummaryInfoGetPropertyCount(MSIHANDLE,PUINT);
332 UINT WINAPI MsiEnableUIPreview(MSIHANDLE, MSIHANDLE*);
333 BOOL WINAPI MsiGetMode(MSIHANDLE, MSIRUNMODE);
334 UINT WINAPI MsiSetMode(MSIHANDLE, MSIRUNMODE, BOOL);
336 UINT WINAPI MsiViewModify(MSIHANDLE, MSIMODIFY, MSIHANDLE);
338 UINT WINAPI MsiGetFeatureCostA(MSIHANDLE, LPCSTR, MSICOSTTREE, INSTALLSTATE, LPINT);
339 UINT WINAPI MsiGetFeatureCostW(MSIHANDLE, LPCWSTR, MSICOSTTREE, INSTALLSTATE, LPINT);
340 #define MsiGetFeatureCost WINELIB_NAME_AW(MsiGetFeatureCost)
342 LANGID WINAPI MsiGetLanguage(MSIHANDLE);
344 UINT WINAPI MsiSetInstallLevel(MSIHANDLE, int);
346 MSIHANDLE WINAPI MsiGetLastErrorRecord(void);
348 #ifdef __cplusplus
350 #endif
352 #endif /* __WINE_MSIQUERY_H */