aboutsummaryrefslogtreecommitdiff
path: root/src/WixToolset.BootstrapperCore.Native/inc/BootstrapperApplication.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/WixToolset.BootstrapperCore.Native/inc/BootstrapperApplication.h')
-rw-r--r--src/WixToolset.BootstrapperCore.Native/inc/BootstrapperApplication.h1054
1 files changed, 1054 insertions, 0 deletions
diff --git a/src/WixToolset.BootstrapperCore.Native/inc/BootstrapperApplication.h b/src/WixToolset.BootstrapperCore.Native/inc/BootstrapperApplication.h
new file mode 100644
index 00000000..36d788ca
--- /dev/null
+++ b/src/WixToolset.BootstrapperCore.Native/inc/BootstrapperApplication.h
@@ -0,0 +1,1054 @@
1#pragma once
2// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
3
4
5enum BOOTSTRAPPER_DISPLAY
6{
7 BOOTSTRAPPER_DISPLAY_UNKNOWN,
8 BOOTSTRAPPER_DISPLAY_EMBEDDED,
9 BOOTSTRAPPER_DISPLAY_NONE,
10 BOOTSTRAPPER_DISPLAY_PASSIVE,
11 BOOTSTRAPPER_DISPLAY_FULL,
12};
13
14enum BOOTSTRAPPER_RESTART
15{
16 BOOTSTRAPPER_RESTART_UNKNOWN,
17 BOOTSTRAPPER_RESTART_NEVER,
18 BOOTSTRAPPER_RESTART_PROMPT,
19 BOOTSTRAPPER_RESTART_AUTOMATIC,
20 BOOTSTRAPPER_RESTART_ALWAYS,
21};
22
23enum BOOTSTRAPPER_RESUME_TYPE
24{
25 BOOTSTRAPPER_RESUME_TYPE_NONE,
26 BOOTSTRAPPER_RESUME_TYPE_INVALID, // resume information is present but invalid
27 BOOTSTRAPPER_RESUME_TYPE_INTERRUPTED, // relaunched after an unexpected interruption
28 BOOTSTRAPPER_RESUME_TYPE_REBOOT_PENDING, // reboot has not taken place yet
29 BOOTSTRAPPER_RESUME_TYPE_REBOOT, // relaunched after reboot
30 BOOTSTRAPPER_RESUME_TYPE_SUSPEND, // relaunched after suspend
31 BOOTSTRAPPER_RESUME_TYPE_ARP, // launched from ARP
32};
33
34enum BOOTSTRAPPER_ERROR_TYPE
35{
36 BOOTSTRAPPER_ERROR_TYPE_ELEVATE, // error occurred trying to elevate.
37 BOOTSTRAPPER_ERROR_TYPE_WINDOWS_INSTALLER, // error came from windows installer.
38 BOOTSTRAPPER_ERROR_TYPE_EXE_PACKAGE, // error came from an exe package.
39 BOOTSTRAPPER_ERROR_TYPE_HTTP_AUTH_SERVER, // error occurred trying to authenticate with HTTP server.
40 BOOTSTRAPPER_ERROR_TYPE_HTTP_AUTH_PROXY, // error occurred trying to authenticate with HTTP proxy.
41 BOOTSTRAPPER_ERROR_TYPE_APPLY, // error occurred during apply.
42};
43
44enum BOOTSTRAPPER_RELATED_OPERATION
45{
46 BOOTSTRAPPER_RELATED_OPERATION_NONE,
47 BOOTSTRAPPER_RELATED_OPERATION_DOWNGRADE,
48 BOOTSTRAPPER_RELATED_OPERATION_MINOR_UPDATE,
49 BOOTSTRAPPER_RELATED_OPERATION_MAJOR_UPGRADE,
50 BOOTSTRAPPER_RELATED_OPERATION_REMOVE,
51 BOOTSTRAPPER_RELATED_OPERATION_INSTALL,
52 BOOTSTRAPPER_RELATED_OPERATION_REPAIR,
53};
54
55enum BOOTSTRAPPER_CACHE_OPERATION
56{
57 BOOTSTRAPPER_CACHE_OPERATION_COPY,
58 BOOTSTRAPPER_CACHE_OPERATION_DOWNLOAD,
59 BOOTSTRAPPER_CACHE_OPERATION_EXTRACT,
60};
61
62enum BOOTSTRAPPER_APPLY_RESTART
63{
64 BOOTSTRAPPER_APPLY_RESTART_NONE,
65 BOOTSTRAPPER_APPLY_RESTART_REQUIRED,
66 BOOTSTRAPPER_APPLY_RESTART_INITIATED,
67};
68
69enum BOOTSTRAPPER_RELATION_TYPE
70{
71 BOOTSTRAPPER_RELATION_NONE,
72 BOOTSTRAPPER_RELATION_DETECT,
73 BOOTSTRAPPER_RELATION_UPGRADE,
74 BOOTSTRAPPER_RELATION_ADDON,
75 BOOTSTRAPPER_RELATION_PATCH,
76 BOOTSTRAPPER_RELATION_DEPENDENT,
77 BOOTSTRAPPER_RELATION_UPDATE,
78};
79
80enum BOOTSTRAPPER_APPLICATION_MESSAGE
81{
82 BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTBEGIN,
83 BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTCOMPLETE,
84 BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANBEGIN,
85 BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANCOMPLETE,
86 BOOTSTRAPPER_APPLICATION_MESSAGE_ONSTARTUP,
87 BOOTSTRAPPER_APPLICATION_MESSAGE_ONSHUTDOWN,
88 BOOTSTRAPPER_APPLICATION_MESSAGE_ONSYSTEMSHUTDOWN,
89 BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTFORWARDCOMPATIBLEBUNDLE,
90 BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTUPDATEBEGIN,
91 BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTUPDATE,
92 BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTUPDATECOMPLETE,
93 BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTRELATEDBUNDLE,
94 BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTPACKAGEBEGIN,
95 BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTCOMPATIBLEMSIPACKAGE,
96 BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTRELATEDMSIPACKAGE,
97 BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTTARGETMSIPACKAGE,
98 BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTMSIFEATURE,
99 BOOTSTRAPPER_APPLICATION_MESSAGE_ONDETECTPACKAGECOMPLETE,
100 BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANRELATEDBUNDLE,
101 BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANPACKAGEBEGIN,
102 BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANCOMPATIBLEMSIPACKAGEBEGIN,
103 BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANCOMPATIBLEMSIPACKAGECOMPLETE,
104 BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANTARGETMSIPACKAGE,
105 BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANMSIFEATURE,
106 BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANPACKAGECOMPLETE,
107 BOOTSTRAPPER_APPLICATION_MESSAGE_ONAPPLYBEGIN,
108 BOOTSTRAPPER_APPLICATION_MESSAGE_ONELEVATEBEGIN,
109 BOOTSTRAPPER_APPLICATION_MESSAGE_ONELEVATECOMPLETE,
110 BOOTSTRAPPER_APPLICATION_MESSAGE_ONPROGRESS,
111 BOOTSTRAPPER_APPLICATION_MESSAGE_ONERROR,
112 BOOTSTRAPPER_APPLICATION_MESSAGE_ONREGISTERBEGIN,
113 BOOTSTRAPPER_APPLICATION_MESSAGE_ONREGISTERCOMPLETE,
114 BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEBEGIN,
115 BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEPACKAGEBEGIN,
116 BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEACQUIREBEGIN,
117 BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEACQUIREPROGRESS,
118 BOOTSTRAPPER_APPLICATION_MESSAGE_ONRESOLVESOURCE,
119 BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEACQUIRECOMPLETE,
120 BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEVERIFYBEGIN,
121 BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEVERIFYCOMPLETE,
122 BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHEPACKAGECOMPLETE,
123 BOOTSTRAPPER_APPLICATION_MESSAGE_ONCACHECOMPLETE,
124 BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTEBEGIN,
125 BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTEPACKAGEBEGIN,
126 BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTEPATCHTARGET,
127 BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTEPROGRESS,
128 BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTEMSIMESSAGE,
129 BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTEFILESINUSE,
130 BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTEPACKAGECOMPLETE,
131 BOOTSTRAPPER_APPLICATION_MESSAGE_ONEXECUTECOMPLETE,
132 BOOTSTRAPPER_APPLICATION_MESSAGE_ONUNREGISTERBEGIN,
133 BOOTSTRAPPER_APPLICATION_MESSAGE_ONUNREGISTERCOMPLETE,
134 BOOTSTRAPPER_APPLICATION_MESSAGE_ONAPPLYCOMPLETE,
135 BOOTSTRAPPER_APPLICATION_MESSAGE_ONLAUNCHAPPROVEDEXEBEGIN,
136 BOOTSTRAPPER_APPLICATION_MESSAGE_ONLAUNCHAPPROVEDEXECOMPLETE,
137 BOOTSTRAPPER_APPLICATION_MESSAGE_ONPLANMSIPACKAGE,
138};
139
140enum BOOTSTRAPPER_APPLYCOMPLETE_ACTION
141{
142 BOOTSTRAPPER_APPLYCOMPLETE_ACTION_NONE,
143 // Instructs the engine to restart.
144 // The engine will not launch again after the machine is rebooted.
145 // Ignored if reboot was already initiated by OnExecutePackageComplete().
146 BOOTSTRAPPER_APPLYCOMPLETE_ACTION_RESTART,
147};
148
149enum BOOTSTRAPPER_CACHEACQUIRECOMPLETE_ACTION
150{
151 BOOTSTRAPPER_CACHEACQUIRECOMPLETE_ACTION_NONE,
152 // Instructs the engine to try the acquisition of the package again.
153 // Ignored if hrStatus is a success.
154 BOOTSTRAPPER_CACHEACQUIRECOMPLETE_ACTION_RETRY,
155};
156
157enum BOOTSTRAPPER_CACHEPACKAGECOMPLETE_ACTION
158{
159 BOOTSTRAPPER_CACHEPACKAGECOMPLETE_ACTION_NONE,
160 // Instructs the engine to ignore non-vital package failures and
161 // continue with the caching.
162 // Ignored if hrStatus is a success or the package is vital.
163 BOOTSTRAPPER_CACHEPACKAGECOMPLETE_ACTION_IGNORE,
164 // Instructs the engine to try the acquisition and verification of the package again.
165 // Ignored if hrStatus is a success.
166 BOOTSTRAPPER_CACHEPACKAGECOMPLETE_ACTION_RETRY,
167};
168
169enum BOOTSTRAPPER_CACHEVERIFYCOMPLETE_ACTION
170{
171 BOOTSTRAPPER_CACHEVERIFYCOMPLETE_ACTION_NONE,
172 // Ignored if hrStatus is a success.
173 BOOTSTRAPPER_CACHEVERIFYCOMPLETE_ACTION_RETRYVERIFICATION,
174 // Ignored if hrStatus is a success.
175 BOOTSTRAPPER_CACHEVERIFYCOMPLETE_ACTION_RETRYACQUISITION,
176};
177
178enum BOOTSTRAPPER_EXECUTEPACKAGECOMPLETE_ACTION
179{
180 BOOTSTRAPPER_EXECUTEPACKAGECOMPLETE_ACTION_NONE,
181 // Instructs the engine to ignore non-vital package failures and
182 // continue with the install.
183 // Ignored if hrStatus is a success or the package is vital.
184 BOOTSTRAPPER_EXECUTEPACKAGECOMPLETE_ACTION_IGNORE,
185 // Instructs the engine to try the execution of the package again.
186 // Ignored if hrStatus is a success.
187 BOOTSTRAPPER_EXECUTEPACKAGECOMPLETE_ACTION_RETRY,
188 // Instructs the engine to stop processing the chain and restart.
189 // The engine will launch again after the machine is restarted.
190 BOOTSTRAPPER_EXECUTEPACKAGECOMPLETE_ACTION_RESTART,
191 // Instructs the engine to stop processing the chain and
192 // suspend the current state.
193 BOOTSTRAPPER_EXECUTEPACKAGECOMPLETE_ACTION_SUSPEND,
194};
195
196enum BOOTSTRAPPER_RESOLVESOURCE_ACTION
197{
198 // Instructs the engine that the source can't be found.
199 BOOTSTRAPPER_RESOLVESOURCE_ACTION_NONE,
200 // Instructs the engine to try the local source again.
201 BOOTSTRAPPER_RESOLVESOURCE_ACTION_RETRY,
202 // Instructs the engine to try the download source.
203 BOOTSTRAPPER_RESOLVESOURCE_ACTION_DOWNLOAD,
204};
205
206enum BOOTSTRAPPER_SHUTDOWN_ACTION
207{
208 BOOTSTRAPPER_SHUTDOWN_ACTION_NONE,
209 // Instructs the engine to restart.
210 // The engine will not launch again after the machine is rebooted.
211 // Ignored if reboot was already initiated by OnExecutePackageComplete().
212 BOOTSTRAPPER_SHUTDOWN_ACTION_RESTART,
213 // Instructs the engine to unload the bootstrapper application and
214 // restart the engine which will load the bootstrapper application again.
215 // Typically used to switch from a native bootstrapper application to a managed one.
216 BOOTSTRAPPER_SHUTDOWN_ACTION_RELOAD_BOOTSTRAPPER,
217};
218
219enum BURN_MSI_PROPERTY
220{
221 BURN_MSI_PROPERTY_NONE, // no property added
222 BURN_MSI_PROPERTY_INSTALL, // add BURNMSIINSTALL=1
223 BURN_MSI_PROPERTY_MODIFY, // add BURNMSIMODIFY=1
224 BURN_MSI_PROPERTY_REPAIR, // add BURNMSIREPAIR=1
225 BURN_MSI_PROPERTY_UNINSTALL,// add BURNMSIUNINSTALL=1
226};
227
228struct BOOTSTRAPPER_COMMAND
229{
230 DWORD cbSize;
231 BOOTSTRAPPER_ACTION action;
232 BOOTSTRAPPER_DISPLAY display;
233 BOOTSTRAPPER_RESTART restart;
234
235 LPWSTR wzCommandLine;
236 int nCmdShow;
237
238 BOOTSTRAPPER_RESUME_TYPE resumeType;
239 HWND hwndSplashScreen;
240
241 // If this was run from a related bundle, specifies the relation type
242 BOOTSTRAPPER_RELATION_TYPE relationType;
243 BOOL fPassthrough;
244
245 LPWSTR wzLayoutDirectory;
246 LPWSTR wzBootstrapperWorkingFolder;
247 LPWSTR wzBootstrapperApplicationDataPath;
248};
249
250struct BA_ONAPPLYBEGIN_ARGS
251{
252 DWORD cbSize;
253 DWORD dwPhaseCount;
254};
255
256struct BA_ONAPPLYBEGIN_RESULTS
257{
258 DWORD cbSize;
259 BOOL fCancel;
260};
261
262struct BA_ONAPPLYCOMPLETE_ARGS
263{
264 DWORD cbSize;
265 HRESULT hrStatus;
266 // Indicates whether any package required a reboot or initiated the reboot already.
267 BOOTSTRAPPER_APPLY_RESTART restart;
268 BOOTSTRAPPER_APPLYCOMPLETE_ACTION recommendation;
269};
270
271struct BA_ONAPPLYCOMPLETE_RESULTS
272{
273 DWORD cbSize;
274 BOOTSTRAPPER_APPLYCOMPLETE_ACTION action;
275};
276
277struct BA_ONCACHEACQUIREBEGIN_ARGS
278{
279 DWORD cbSize;
280 LPCWSTR wzPackageOrContainerId;
281 LPCWSTR wzPayloadId;
282 BOOTSTRAPPER_CACHE_OPERATION operation;
283 LPCWSTR wzSource;
284};
285
286struct BA_ONCACHEACQUIREBEGIN_RESULTS
287{
288 DWORD cbSize;
289 BOOL fCancel;
290};
291
292struct BA_ONCACHEACQUIRECOMPLETE_ARGS
293{
294 DWORD cbSize;
295 LPCWSTR wzPackageOrContainerId;
296 LPCWSTR wzPayloadId;
297 HRESULT hrStatus;
298 BOOTSTRAPPER_CACHEACQUIRECOMPLETE_ACTION recommendation;
299};
300
301struct BA_ONCACHEACQUIRECOMPLETE_RESULTS
302{
303 DWORD cbSize;
304 BOOTSTRAPPER_CACHEACQUIRECOMPLETE_ACTION action;
305};
306
307struct BA_ONCACHEACQUIREPROGRESS_ARGS
308{
309 DWORD cbSize;
310 LPCWSTR wzPackageOrContainerId;
311 LPCWSTR wzPayloadId;
312 DWORD64 dw64Progress;
313 DWORD64 dw64Total;
314 DWORD dwOverallPercentage;
315};
316
317struct BA_ONCACHEACQUIREPROGRESS_RESULTS
318{
319 DWORD cbSize;
320 BOOL fCancel;
321};
322
323struct BA_ONCACHEBEGIN_ARGS
324{
325 DWORD cbSize;
326};
327
328struct BA_ONCACHEBEGIN_RESULTS
329{
330 DWORD cbSize;
331 BOOL fCancel;
332};
333
334struct BA_ONCACHECOMPLETE_ARGS
335{
336 DWORD cbSize;
337 HRESULT hrStatus;
338};
339
340struct BA_ONCACHECOMPLETE_RESULTS
341{
342 DWORD cbSize;
343};
344
345struct BA_ONCACHEPACKAGEBEGIN_ARGS
346{
347 DWORD cbSize;
348 LPCWSTR wzPackageId;
349 DWORD cCachePayloads;
350 DWORD64 dw64PackageCacheSize;
351};
352
353struct BA_ONCACHEPACKAGEBEGIN_RESULTS
354{
355 DWORD cbSize;
356 BOOL fCancel;
357};
358
359struct BA_ONCACHEPACKAGECOMPLETE_ARGS
360{
361 DWORD cbSize;
362 LPCWSTR wzPackageId;
363 HRESULT hrStatus;
364 BOOTSTRAPPER_CACHEPACKAGECOMPLETE_ACTION recommendation;
365};
366
367struct BA_ONCACHEPACKAGECOMPLETE_RESULTS
368{
369 DWORD cbSize;
370 BOOTSTRAPPER_CACHEPACKAGECOMPLETE_ACTION action;
371};
372
373struct BA_ONCACHEVERIFYBEGIN_ARGS
374{
375 DWORD cbSize;
376 LPCWSTR wzPackageOrContainerId;
377 LPCWSTR wzPayloadId;
378};
379
380struct BA_ONCACHEVERIFYBEGIN_RESULTS
381{
382 DWORD cbSize;
383 BOOL fCancel;
384};
385
386struct BA_ONCACHEVERIFYCOMPLETE_ARGS
387{
388 DWORD cbSize;
389 LPCWSTR wzPackageOrContainerId;
390 LPCWSTR wzPayloadId;
391 HRESULT hrStatus;
392 BOOTSTRAPPER_CACHEVERIFYCOMPLETE_ACTION recommendation;
393};
394
395struct BA_ONCACHEVERIFYCOMPLETE_RESULTS
396{
397 DWORD cbSize;
398 BOOTSTRAPPER_CACHEVERIFYCOMPLETE_ACTION action;
399};
400
401struct BA_ONDETECTBEGIN_ARGS
402{
403 DWORD cbSize;
404 BOOL fInstalled;
405 DWORD cPackages;
406};
407
408struct BA_ONDETECTBEGIN_RESULTS
409{
410 DWORD cbSize;
411 BOOL fCancel;
412};
413
414struct BA_ONDETECTCOMPATIBLEMSIPACKAGE_ARGS
415{
416 DWORD cbSize;
417 LPCWSTR wzPackageId;
418 LPCWSTR wzCompatiblePackageId;
419 DWORD64 dw64CompatiblePackageVersion;
420};
421
422struct BA_ONDETECTCOMPATIBLEMSIPACKAGE_RESULTS
423{
424 DWORD cbSize;
425 BOOL fCancel;
426};
427
428struct BA_ONDETECTCOMPLETE_ARGS
429{
430 DWORD cbSize;
431 HRESULT hrStatus;
432};
433
434struct BA_ONDETECTCOMPLETE_RESULTS
435{
436 DWORD cbSize;
437};
438
439struct BA_ONDETECTFORWARDCOMPATIBLEBUNDLE_ARGS
440{
441 DWORD cbSize;
442 LPCWSTR wzBundleId;
443 BOOTSTRAPPER_RELATION_TYPE relationType;
444 LPCWSTR wzBundleTag;
445 BOOL fPerMachine;
446 DWORD64 dw64Version;
447};
448
449struct BA_ONDETECTFORWARDCOMPATIBLEBUNDLE_RESULTS
450{
451 DWORD cbSize;
452 BOOL fCancel;
453 BOOL fIgnoreBundle;
454};
455
456struct BA_ONDETECTMSIFEATURE_ARGS
457{
458 DWORD cbSize;
459 LPCWSTR wzPackageId;
460 LPCWSTR wzFeatureId;
461 BOOTSTRAPPER_FEATURE_STATE state;
462};
463
464struct BA_ONDETECTMSIFEATURE_RESULTS
465{
466 DWORD cbSize;
467 BOOL fCancel;
468};
469
470struct BA_ONDETECTPACKAGEBEGIN_ARGS
471{
472 DWORD cbSize;
473 LPCWSTR wzPackageId;
474};
475
476struct BA_ONDETECTPACKAGEBEGIN_RESULTS
477{
478 DWORD cbSize;
479 BOOL fCancel;
480};
481
482struct BA_ONDETECTPACKAGECOMPLETE_ARGS
483{
484 DWORD cbSize;
485 LPCWSTR wzPackageId;
486 HRESULT hrStatus;
487 BOOTSTRAPPER_PACKAGE_STATE state;
488};
489
490struct BA_ONDETECTPACKAGECOMPLETE_RESULTS
491{
492 DWORD cbSize;
493};
494
495struct BA_ONDETECTRELATEDBUNDLE_ARGS
496{
497 DWORD cbSize;
498 LPCWSTR wzBundleId;
499 BOOTSTRAPPER_RELATION_TYPE relationType;
500 LPCWSTR wzBundleTag;
501 BOOL fPerMachine;
502 DWORD64 dw64Version;
503 BOOTSTRAPPER_RELATED_OPERATION operation;
504};
505
506struct BA_ONDETECTRELATEDBUNDLE_RESULTS
507{
508 DWORD cbSize;
509 BOOL fCancel;
510};
511
512struct BA_ONDETECTRELATEDMSIPACKAGE_ARGS
513{
514 DWORD cbSize;
515 LPCWSTR wzPackageId;
516 LPCWSTR wzUpgradeCode;
517 LPCWSTR wzProductCode;
518 BOOL fPerMachine;
519 DWORD64 dw64Version;
520 BOOTSTRAPPER_RELATED_OPERATION operation;
521};
522
523struct BA_ONDETECTRELATEDMSIPACKAGE_RESULTS
524{
525 DWORD cbSize;
526 BOOL fCancel;
527};
528
529struct BA_ONDETECTTARGETMSIPACKAGE_ARGS
530{
531 DWORD cbSize;
532 LPCWSTR wzPackageId;
533 LPCWSTR wzProductCode;
534 BOOTSTRAPPER_PACKAGE_STATE patchState;
535};
536
537struct BA_ONDETECTTARGETMSIPACKAGE_RESULTS
538{
539 DWORD cbSize;
540 BOOL fCancel;
541};
542
543struct BA_ONDETECTUPDATE_ARGS
544{
545 DWORD cbSize;
546 LPCWSTR wzUpdateLocation;
547 DWORD64 dw64Size;
548 DWORD64 dw64Version;
549 LPCWSTR wzTitle;
550 LPCWSTR wzSummary;
551 LPCWSTR wzContentType;
552 LPCWSTR wzContent;
553};
554
555struct BA_ONDETECTUPDATE_RESULTS
556{
557 DWORD cbSize;
558 BOOL fCancel;
559 BOOL fStopProcessingUpdates;
560};
561
562struct BA_ONDETECTUPDATEBEGIN_ARGS
563{
564 DWORD cbSize;
565 LPCWSTR wzUpdateLocation;
566};
567
568struct BA_ONDETECTUPDATEBEGIN_RESULTS
569{
570 DWORD cbSize;
571 BOOL fCancel;
572 BOOL fSkip;
573};
574
575struct BA_ONDETECTUPDATECOMPLETE_ARGS
576{
577 DWORD cbSize;
578 HRESULT hrStatus;
579};
580
581struct BA_ONDETECTUPDATECOMPLETE_RESULTS
582{
583 DWORD cbSize;
584 BOOL fIgnoreError;
585};
586
587struct BA_ONELEVATEBEGIN_ARGS
588{
589 DWORD cbSize;
590};
591
592struct BA_ONELEVATEBEGIN_RESULTS
593{
594 DWORD cbSize;
595 BOOL fCancel;
596};
597
598struct BA_ONELEVATECOMPLETE_ARGS
599{
600 DWORD cbSize;
601 HRESULT hrStatus;
602};
603
604struct BA_ONELEVATECOMPLETE_RESULTS
605{
606 DWORD cbSize;
607};
608
609struct BA_ONERROR_ARGS
610{
611 DWORD cbSize;
612 BOOTSTRAPPER_ERROR_TYPE errorType;
613 LPCWSTR wzPackageId;
614 DWORD dwCode;
615 LPCWSTR wzError;
616 DWORD dwUIHint;
617 DWORD cData;
618 LPCWSTR* rgwzData;
619 int nRecommendation;
620};
621
622struct BA_ONERROR_RESULTS
623{
624 DWORD cbSize;
625 int nResult;
626};
627
628struct BA_ONEXECUTEBEGIN_ARGS
629{
630 DWORD cbSize;
631 DWORD cExecutingPackages;
632};
633
634struct BA_ONEXECUTEBEGIN_RESULTS
635{
636 DWORD cbSize;
637 BOOL fCancel;
638};
639
640struct BA_ONEXECUTECOMPLETE_ARGS
641{
642 DWORD cbSize;
643 HRESULT hrStatus;
644};
645
646struct BA_ONEXECUTECOMPLETE_RESULTS
647{
648 DWORD cbSize;
649};
650
651struct BA_ONEXECUTEFILESINUSE_ARGS
652{
653 DWORD cbSize;
654 LPCWSTR wzPackageId;
655 DWORD cFiles;
656 LPCWSTR* rgwzFiles;
657 int nRecommendation;
658};
659
660struct BA_ONEXECUTEFILESINUSE_RESULTS
661{
662 DWORD cbSize;
663 int nResult;
664};
665
666struct BA_ONEXECUTEMSIMESSAGE_ARGS
667{
668 DWORD cbSize;
669 LPCWSTR wzPackageId;
670 INSTALLMESSAGE messageType;
671 DWORD dwUIHint;
672 LPCWSTR wzMessage;
673 DWORD cData;
674 LPCWSTR* rgwzData;
675 int nRecommendation;
676};
677
678struct BA_ONEXECUTEMSIMESSAGE_RESULTS
679{
680 DWORD cbSize;
681 int nResult;
682};
683
684struct BA_ONEXECUTEPACKAGEBEGIN_ARGS
685{
686 DWORD cbSize;
687 LPCWSTR wzPackageId;
688 BOOL fExecute; // false means rollback.
689 BOOTSTRAPPER_ACTION_STATE action;
690 INSTALLUILEVEL uiLevel;
691 BOOL fDisableExternalUiHandler;
692};
693
694struct BA_ONEXECUTEPACKAGEBEGIN_RESULTS
695{
696 DWORD cbSize;
697 BOOL fCancel;
698};
699
700struct BA_ONEXECUTEPACKAGECOMPLETE_ARGS
701{
702 DWORD cbSize;
703 LPCWSTR wzPackageId;
704 HRESULT hrStatus;
705 // Indicates whether this package requires a reboot or initiated the reboot already.
706 BOOTSTRAPPER_APPLY_RESTART restart;
707 BOOTSTRAPPER_EXECUTEPACKAGECOMPLETE_ACTION recommendation;
708};
709
710struct BA_ONEXECUTEPACKAGECOMPLETE_RESULTS
711{
712 DWORD cbSize;
713 BOOTSTRAPPER_EXECUTEPACKAGECOMPLETE_ACTION action;
714};
715
716struct BA_ONEXECUTEPATCHTARGET_ARGS
717{
718 DWORD cbSize;
719 LPCWSTR wzPackageId;
720 LPCWSTR wzTargetProductCode;
721};
722
723struct BA_ONEXECUTEPATCHTARGET_RESULTS
724{
725 DWORD cbSize;
726 BOOL fCancel;
727};
728
729struct BA_ONEXECUTEPROGRESS_ARGS
730{
731 DWORD cbSize;
732 LPCWSTR wzPackageId;
733 DWORD dwProgressPercentage;
734 DWORD dwOverallPercentage;
735};
736
737struct BA_ONEXECUTEPROGRESS_RESULTS
738{
739 DWORD cbSize;
740 BOOL fCancel;
741};
742
743struct BA_ONLAUNCHAPPROVEDEXEBEGIN_ARGS
744{
745 DWORD cbSize;
746};
747
748struct BA_ONLAUNCHAPPROVEDEXEBEGIN_RESULTS
749{
750 DWORD cbSize;
751 BOOL fCancel;
752};
753
754struct BA_ONLAUNCHAPPROVEDEXECOMPLETE_ARGS
755{
756 DWORD cbSize;
757 HRESULT hrStatus;
758 // Only valid if the operation succeeded.
759 DWORD dwProcessId;
760};
761
762struct BA_ONLAUNCHAPPROVEDEXECOMPLETE_RESULTS
763{
764 DWORD cbSize;
765};
766
767struct BA_ONPLANBEGIN_ARGS
768{
769 DWORD cbSize;
770 DWORD cPackages;
771};
772
773struct BA_ONPLANBEGIN_RESULTS
774{
775 DWORD cbSize;
776 BOOL fCancel;
777};
778
779struct BA_ONPLANCOMPATIBLEMSIPACKAGEBEGIN_ARGS
780{
781 DWORD cbSize;
782 LPCWSTR wzPackageId;
783 LPCWSTR wzCompatiblePackageId;
784 DWORD64 dw64CompatiblePackageVersion;
785 BOOTSTRAPPER_REQUEST_STATE recommendedState;
786};
787
788struct BA_ONPLANCOMPATIBLEMSIPACKAGEBEGIN_RESULTS
789{
790 DWORD cbSize;
791 BOOL fCancel;
792 BOOTSTRAPPER_REQUEST_STATE requestedState;
793};
794
795struct BA_ONPLANCOMPATIBLEMSIPACKAGECOMPLETE_ARGS
796{
797 DWORD cbSize;
798 LPCWSTR wzPackageId;
799 LPCWSTR wzCompatiblePackageId;
800 HRESULT hrStatus;
801 BOOTSTRAPPER_PACKAGE_STATE state;
802 BOOTSTRAPPER_REQUEST_STATE requested;
803 BOOTSTRAPPER_ACTION_STATE execute;
804 BOOTSTRAPPER_ACTION_STATE rollback;
805};
806
807struct BA_ONPLANCOMPATIBLEMSIPACKAGECOMPLETE_RESULTS
808{
809 DWORD cbSize;
810};
811
812struct BA_ONPLANCOMPLETE_ARGS
813{
814 DWORD cbSize;
815 HRESULT hrStatus;
816};
817
818struct BA_ONPLANCOMPLETE_RESULTS
819{
820 DWORD cbSize;
821};
822
823struct BA_ONPLANMSIFEATURE_ARGS
824{
825 DWORD cbSize;
826 LPCWSTR wzPackageId;
827 LPCWSTR wzFeatureId;
828 BOOTSTRAPPER_FEATURE_STATE recommendedState;
829};
830
831struct BA_ONPLANMSIFEATURE_RESULTS
832{
833 DWORD cbSize;
834 BOOTSTRAPPER_FEATURE_STATE requestedState;
835 BOOL fCancel;
836};
837
838struct BA_ONPLANMSIPACKAGE_ARGS
839{
840 DWORD cbSize;
841 LPCWSTR wzPackageId;
842 BOOL fExecute; // false means rollback.
843 BOOTSTRAPPER_ACTION_STATE action;
844};
845
846struct BA_ONPLANMSIPACKAGE_RESULTS
847{
848 DWORD cbSize;
849 BOOL fCancel;
850 BURN_MSI_PROPERTY actionMsiProperty;
851 INSTALLUILEVEL uiLevel;
852 BOOL fDisableExternalUiHandler;
853};
854
855struct BA_ONPLANPACKAGEBEGIN_ARGS
856{
857 DWORD cbSize;
858 LPCWSTR wzPackageId;
859 BOOTSTRAPPER_REQUEST_STATE recommendedState;
860};
861
862struct BA_ONPLANPACKAGEBEGIN_RESULTS
863{
864 DWORD cbSize;
865 BOOL fCancel;
866 BOOTSTRAPPER_REQUEST_STATE requestedState;
867};
868
869struct BA_ONPLANPACKAGECOMPLETE_ARGS
870{
871 DWORD cbSize;
872 LPCWSTR wzPackageId;
873 HRESULT hrStatus;
874 BOOTSTRAPPER_PACKAGE_STATE state;
875 BOOTSTRAPPER_REQUEST_STATE requested;
876 BOOTSTRAPPER_ACTION_STATE execute;
877 BOOTSTRAPPER_ACTION_STATE rollback;
878};
879
880struct BA_ONPLANPACKAGECOMPLETE_RESULTS
881{
882 DWORD cbSize;
883};
884
885struct BA_ONPLANRELATEDBUNDLE_ARGS
886{
887 DWORD cbSize;
888 LPCWSTR wzBundleId;
889 BOOTSTRAPPER_REQUEST_STATE recommendedState;
890};
891
892struct BA_ONPLANRELATEDBUNDLE_RESULTS
893{
894 DWORD cbSize;
895 BOOL fCancel;
896 BOOTSTRAPPER_REQUEST_STATE requestedState;
897};
898
899struct BA_ONPLANTARGETMSIPACKAGE_ARGS
900{
901 DWORD cbSize;
902 LPCWSTR wzPackageId;
903 LPCWSTR wzProductCode;
904 BOOTSTRAPPER_REQUEST_STATE recommendedState;
905};
906
907struct BA_ONPLANTARGETMSIPACKAGE_RESULTS
908{
909 DWORD cbSize;
910 BOOTSTRAPPER_REQUEST_STATE requestedState;
911 BOOL fCancel;
912};
913
914struct BA_ONPROGRESS_ARGS
915{
916 DWORD cbSize;
917 DWORD dwProgressPercentage;
918 DWORD dwOverallPercentage;
919};
920
921struct BA_ONPROGRESS_RESULTS
922{
923 DWORD cbSize;
924 BOOL fCancel;
925};
926
927struct BA_ONREGISTERBEGIN_ARGS
928{
929 DWORD cbSize;
930};
931
932struct BA_ONREGISTERBEGIN_RESULTS
933{
934 DWORD cbSize;
935 BOOL fCancel;
936};
937
938struct BA_ONREGISTERCOMPLETE_ARGS
939{
940 DWORD cbSize;
941 HRESULT hrStatus;
942};
943
944struct BA_ONREGISTERCOMPLETE_RESULTS
945{
946 DWORD cbSize;
947};
948
949struct BA_ONRESOLVESOURCE_ARGS
950{
951 DWORD cbSize;
952 LPCWSTR wzPackageOrContainerId;
953 LPCWSTR wzPayloadId;
954 LPCWSTR wzLocalSource;
955 LPCWSTR wzDownloadSource;
956 BOOTSTRAPPER_RESOLVESOURCE_ACTION recommendation;
957};
958
959struct BA_ONRESOLVESOURCE_RESULTS
960{
961 DWORD cbSize;
962 BOOTSTRAPPER_RESOLVESOURCE_ACTION action;
963 BOOL fCancel;
964};
965
966struct BA_ONSHUTDOWN_ARGS
967{
968 DWORD cbSize;
969};
970
971struct BA_ONSHUTDOWN_RESULTS
972{
973 DWORD cbSize;
974 BOOTSTRAPPER_SHUTDOWN_ACTION action;
975};
976
977struct BA_ONSTARTUP_ARGS
978{
979 DWORD cbSize;
980};
981
982struct BA_ONSTARTUP_RESULTS
983{
984 DWORD cbSize;
985};
986
987struct BA_ONSYSTEMSHUTDOWN_ARGS
988{
989 DWORD cbSize;
990 DWORD dwEndSession;
991};
992
993struct BA_ONSYSTEMSHUTDOWN_RESULTS
994{
995 DWORD cbSize;
996 BOOL fCancel;
997};
998
999struct BA_ONUNREGISTERBEGIN_ARGS
1000{
1001 DWORD cbSize;
1002};
1003
1004struct BA_ONUNREGISTERBEGIN_RESULTS
1005{
1006 DWORD cbSize;
1007 BOOL fCancel;
1008};
1009
1010struct BA_ONUNREGISTERCOMPLETE_ARGS
1011{
1012 DWORD cbSize;
1013 HRESULT hrStatus;
1014};
1015
1016struct BA_ONUNREGISTERCOMPLETE_RESULTS
1017{
1018 DWORD cbSize;
1019};
1020
1021
1022
1023extern "C" typedef HRESULT(WINAPI *PFN_BOOTSTRAPPER_APPLICATION_PROC)(
1024 __in BOOTSTRAPPER_APPLICATION_MESSAGE message,
1025 __in const LPVOID pvArgs,
1026 __inout LPVOID pvResults,
1027 __in_opt LPVOID pvContext
1028 );
1029
1030extern "C" typedef void (WINAPI *PFN_BOOTSTRAPPER_APPLICATION_DESTROY)();
1031
1032
1033
1034struct BOOTSTRAPPER_CREATE_ARGS
1035{
1036 DWORD cbSize;
1037 DWORD64 qwEngineAPIVersion;
1038 PFN_BOOTSTRAPPER_ENGINE_PROC pfnBootstrapperEngineProc;
1039 LPVOID pvBootstrapperEngineProcContext;
1040 BOOTSTRAPPER_COMMAND* pCommand;
1041};
1042
1043struct BOOTSTRAPPER_CREATE_RESULTS
1044{
1045 DWORD cbSize;
1046 PFN_BOOTSTRAPPER_APPLICATION_PROC pfnBootstrapperApplicationProc;
1047 LPVOID pvBootstrapperApplicationProcContext;
1048 BOOL fDisableUnloading; // indicates the BA dll must not be unloaded after BootstrapperApplicationDestroy.
1049};
1050
1051extern "C" typedef HRESULT(WINAPI *PFN_BOOTSTRAPPER_APPLICATION_CREATE)(
1052 __in const BOOTSTRAPPER_CREATE_ARGS* pArgs,
1053 __inout BOOTSTRAPPER_CREATE_RESULTS* pResults
1054 );