aboutsummaryrefslogtreecommitdiff
path: root/src/dtf/WixToolset.Dtf.WindowsInstaller/Enums.cs
diff options
context:
space:
mode:
Diffstat (limited to 'src/dtf/WixToolset.Dtf.WindowsInstaller/Enums.cs')
-rw-r--r--src/dtf/WixToolset.Dtf.WindowsInstaller/Enums.cs909
1 files changed, 909 insertions, 0 deletions
diff --git a/src/dtf/WixToolset.Dtf.WindowsInstaller/Enums.cs b/src/dtf/WixToolset.Dtf.WindowsInstaller/Enums.cs
new file mode 100644
index 00000000..64ed0e7f
--- /dev/null
+++ b/src/dtf/WixToolset.Dtf.WindowsInstaller/Enums.cs
@@ -0,0 +1,909 @@
1// 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.
2
3namespace WixToolset.Dtf.WindowsInstaller
4{
5 using System;
6 using System.Diagnostics.CodeAnalysis;
7
8 // Enumerations are in alphabetical order.
9
10 /// <summary>
11 /// Specifies a return status value for custom actions.
12 /// </summary>
13 public enum ActionResult : int
14 {
15 /// <summary>Action completed successfully.</summary>
16 Success = 0,
17
18 /// <summary>Skip remaining actions, not an error.</summary>
19 SkipRemainingActions = 259,
20
21 /// <summary>User terminated prematurely.</summary>
22 UserExit = 1602,
23
24 /// <summary>Unrecoverable error or unhandled exception occurred.</summary>
25 Failure = 1603,
26
27 /// <summary>Action not executed.</summary>
28 NotExecuted = 1626,
29 }
30
31 /// <summary>
32 /// Specifies the open mode for a <see cref="Database"/>.
33 /// </summary>
34 public enum DatabaseOpenMode : int
35 {
36 /// <summary>Open a database read-only, no persistent changes.</summary>
37 ReadOnly = 0,
38
39 /// <summary>Open a database read/write in transaction mode.</summary>
40 Transact = 1,
41
42 /// <summary>Open a database direct read/write without transaction.</summary>
43 Direct = 2,
44
45 /// <summary>Create a new database, transact mode read/write.</summary>
46 Create = 3,
47
48 /// <summary>Create a new database, direct mode read/write.</summary>
49 CreateDirect = 4,
50 }
51
52 /// <summary>
53 /// Log modes available for <see cref="Installer.EnableLog(InstallLogModes,string)"/>
54 /// and <see cref="Installer.SetExternalUI(ExternalUIHandler,InstallLogModes)"/>.
55 /// </summary>
56 [Flags]
57 public enum InstallLogModes : int
58 {
59 /// <summary>Disable logging.</summary>
60 None = 0,
61
62 /// <summary>Log out of memory or fatal exit information.</summary>
63 FatalExit = (1 << ((int) InstallMessage.FatalExit >> 24)),
64
65 /// <summary>Log error messages.</summary>
66 Error = (1 << ((int) InstallMessage.Error >> 24)),
67
68 /// <summary>Log warning messages.</summary>
69 Warning = (1 << ((int) InstallMessage.Warning >> 24)),
70
71 /// <summary>Log user requests.</summary>
72 User = (1 << ((int) InstallMessage.User >> 24)),
73
74 /// <summary>Log status messages that are not displayed.</summary>
75 Info = (1 << ((int) InstallMessage.Info >> 24)),
76
77 /// <summary>Log request to determine a valid source location.</summary>
78 ResolveSource = (1 << ((int) InstallMessage.ResolveSource >> 24)),
79
80 /// <summary>Log insufficient disk space error.</summary>
81 OutOfDiskSpace = (1 << ((int) InstallMessage.OutOfDiskSpace >> 24)),
82
83 /// <summary>Log the start of installation actions.</summary>
84 ActionStart = (1 << ((int) InstallMessage.ActionStart >> 24)),
85
86 /// <summary>Log the data record for installation actions.</summary>
87 ActionData = (1 << ((int) InstallMessage.ActionData >> 24)),
88
89 /// <summary>Log parameters for user-interface initialization.</summary>
90 CommonData = (1 << ((int) InstallMessage.CommonData >> 24)),
91
92 /// <summary>Log the property values at termination.</summary>
93 PropertyDump = (1 << ((int) InstallMessage.Progress >> 24)), // log only
94
95 /// <summary>
96 /// Sends large amounts of information to log file not generally useful to users.
97 /// May be used for support.
98 /// </summary>
99 Verbose = (1 << ((int) InstallMessage.Initialize >> 24)), // log only
100
101 /// <summary>
102 /// Log extra debugging information.
103 /// </summary>
104 ExtraDebug = (1 << ((int) InstallMessage.Terminate >> 24)), // log only
105
106 /// <summary>
107 /// Log only on error.
108 /// </summary>
109 LogOnlyOnError = (1 << ((int) InstallMessage.ShowDialog >> 24)), // log only
110
111 /// <summary>
112 /// Log progress bar information. This message includes information on units so far and total number
113 /// of units. See <see cref="Session.Message"/> for an explanation of the message format. This message
114 /// is only sent to an external user interface and is not logged.
115 /// </summary>
116 Progress = (1 << ((int) InstallMessage.Progress >> 24)), // external handler only
117
118 /// <summary>
119 /// If this is not a quiet installation, then the basic UI has been initialized. If this is a full
120 /// UI installation, the Full UI is not yet initialized. This message is only sent to an external
121 /// user interface and is not logged.
122 /// </summary>
123 Initialize = (1 << ((int) InstallMessage.Initialize >> 24)), // external handler only
124
125 /// <summary>
126 /// If a full UI is being used, the full UI has ended. If this is not a quiet installation, the basic
127 /// UI has not yet ended. This message is only sent to an external user interface and is not logged.
128 /// </summary>
129 Terminate = (1 << ((int) InstallMessage.Terminate >> 24)), // external handler only
130
131 /// <summary>
132 /// Sent prior to display of the Full UI dialog. This message is only sent to an external user
133 /// interface and is not logged.
134 /// </summary>
135 ShowDialog = (1 << ((int) InstallMessage.ShowDialog >> 24)), // external handler only
136
137 /// <summary>
138 /// List of files in use that need to be replaced.
139 /// </summary>
140 FilesInUse = (1 << ((int) InstallMessage.FilesInUse >> 24)), // external handler only
141
142 /// <summary>
143 /// [MSI 4.0] List of apps that the user can request Restart Manager to shut down and restart.
144 /// </summary>
145 RMFilesInUse = (1 << ((int) InstallMessage.RMFilesInUse >> 24)), // external handler only
146 }
147
148 /// <summary>
149 /// Type of message to be processed by <see cref="Session.Message"/>,
150 /// <see cref="ExternalUIHandler"/>, or <see cref="ExternalUIRecordHandler"/>.
151 /// </summary>
152 [SuppressMessage("Microsoft.Design", "CA1027:MarkEnumsWithFlags")]
153 public enum InstallMessage : int
154 {
155 /// <summary>Premature termination, possibly fatal OOM.</summary>
156 FatalExit = 0x00000000,
157
158 /// <summary>Formatted error message.</summary>
159 Error = 0x01000000,
160
161 /// <summary>Formatted warning message.</summary>
162 Warning = 0x02000000,
163
164 /// <summary>User request message.</summary>
165 User = 0x03000000,
166
167 /// <summary>Informative message for log.</summary>
168 Info = 0x04000000,
169
170 /// <summary>List of files in use that need to be replaced.</summary>
171 FilesInUse = 0x05000000,
172
173 /// <summary>Request to determine a valid source location.</summary>
174 ResolveSource = 0x06000000,
175
176 /// <summary>Insufficient disk space message.</summary>
177 OutOfDiskSpace = 0x07000000,
178
179 /// <summary>Start of action: action name &amp; description.</summary>
180 ActionStart = 0x08000000,
181
182 /// <summary>Formatted data associated with individual action item.</summary>
183 ActionData = 0x09000000,
184
185 /// <summary>Progress gauge info: units so far, total.</summary>
186 Progress = 0x0A000000,
187
188 /// <summary>Product info for dialog: language Id, dialog caption.</summary>
189 CommonData = 0x0B000000,
190
191 /// <summary>Sent prior to UI initialization, no string data.</summary>
192 Initialize = 0x0C000000,
193
194 /// <summary>Sent after UI termination, no string data.</summary>
195 Terminate = 0x0D000000,
196
197 /// <summary>Sent prior to display or authored dialog or wizard.</summary>
198 ShowDialog = 0x0E000000,
199
200 /// <summary>[MSI 4.0] List of apps that the user can request Restart Manager to shut down and restart.</summary>
201 RMFilesInUse = 0x19000000,
202
203 /// <summary>[MSI 4.5] Sent prior to install of a product.</summary>
204 InstallStart = 0x1A000000,
205
206 /// <summary>[MSI 4.5] Sent after install of a product.</summary>
207 InstallEnd = 0x1B000000,
208 }
209
210 /// <summary>
211 /// Specifies the install mode for <see cref="Installer.ProvideComponent"/> or <see cref="Installer.ProvideQualifiedComponent"/>.
212 /// </summary>
213 public enum InstallMode : int
214 {
215 /// <summary>Provide the component only if the feature's installation state is <see cref="InstallState.Local"/>.</summary>
216 NoSourceResolution = -3,
217
218 /// <summary>Only check that the component is registered, without verifying that the key file of the component exists.</summary>
219 NoDetection = -2,
220
221 /// <summary>Provide the component only if the feature exists.</summary>
222 Existing = -1,
223
224 /// <summary>Provide the component and perform any installation necessary to provide the component.</summary>
225 Default = 0,
226 }
227
228 /// <summary>
229 /// Specifies the run mode for <see cref="Session.GetMode"/>.
230 /// </summary>
231 [SuppressMessage("Microsoft.Design", "CA1027:MarkEnumsWithFlags")]
232 public enum InstallRunMode : int
233 {
234 /// <summary>The administrative mode is installing, or the product is installing.</summary>
235 Admin = 0,
236
237 /// <summary>The advertisements are installing or the product is installing or updating.</summary>
238 Advertise = 1,
239
240 /// <summary>An existing installation is being modified or there is a new installation.</summary>
241 Maintenance = 2,
242
243 /// <summary>Rollback is enabled.</summary>
244 RollbackEnabled = 3,
245
246 /// <summary>The log file is active. It was enabled prior to the installation session.</summary>
247 LogEnabled = 4,
248
249 /// <summary>Execute operations are spooling or they are in the determination phase.</summary>
250 Operations = 5,
251
252 /// <summary>A reboot is necessary after a successful installation (settable).</summary>
253 RebootAtEnd = 6,
254
255 /// <summary>A reboot is necessary to continue the installation (settable).</summary>
256 RebootNow = 7,
257
258 /// <summary>Files from cabinets and Media table files are installing.</summary>
259 Cabinet = 8,
260
261 /// <summary>The source LongFileNames is suppressed through the PID_MSISOURCE summary property.</summary>
262 SourceShortNames = 9,
263
264 /// <summary>The target LongFileNames is suppressed through the SHORTFILENAMES property.</summary>
265 TargetShortNames = 10,
266
267 // <summary>Reserved for future use.</summary>
268 //Reserved11 = 11,
269
270 /// <summary>The operating system is Windows 95, Windows 98, or Windows ME.</summary>
271 [SuppressMessage("Microsoft.Naming", "CA1709:IdentifiersShouldBeCasedCorrectly", MessageId = "x")]
272 Windows9x = 12,
273
274 /// <summary>The operating system supports demand installation.</summary>
275 [SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly", MessageId = "Zaw")]
276 ZawEnabled = 13,
277
278 // <summary>Reserved for future use.</summary>
279 //Reserved14 = 14,
280
281 // <summary>Reserved for future use.</summary>
282 //Reserved15 = 15,
283
284 /// <summary>A custom action called from install script execution.</summary>
285 Scheduled = 16,
286
287 /// <summary>A custom action called from rollback execution script.</summary>
288 Rollback = 17,
289
290 /// <summary>A custom action called from commit execution script.</summary>
291 Commit = 18,
292 }
293
294 /// <summary>
295 /// Installed state of a Component or Feature.
296 /// </summary>
297 public enum InstallState : int
298 {
299 /// <summary>The component is disabled.</summary>
300 NotUsed = -7,
301
302 /// <summary>The installation configuration data is corrupt.</summary>
303 BadConfig = -6,
304
305 /// <summary>The installation is suspended or in progress.</summary>
306 Incomplete = -5,
307
308 /// <summary>Component is set to run from source, but source is unavailable.</summary>
309 SourceAbsent = -4,
310
311 /// <summary>The buffer overflow is returned.</summary>
312 MoreData = -3,
313
314 /// <summary>An invalid parameter was passed to the function.</summary>
315 InvalidArgument = -2,
316
317 /// <summary>An unrecognized product or feature name was passed to the function.</summary>
318 Unknown = -1,
319
320 /// <summary>The component is broken.</summary>
321 Broken = 0,
322
323 /// <summary>The feature is advertised.</summary>
324 Advertised = 1,
325
326 /// <summary>The component is being removed. In action state and not settable.</summary>
327 Removed = 1,
328
329 /// <summary>The component is not installed, or action state is absent but clients remain.</summary>
330 Absent = 2,
331
332 /// <summary>The component is installed on the local drive.</summary>
333 Local = 3,
334
335 /// <summary>The component will run from the source, CD, or network.</summary>
336 Source = 4,
337
338 /// <summary>The component will be installed in the default location: local or source.</summary>
339 Default = 5,
340 }
341
342 /// <summary>
343 /// Specifies the type of installation for <see cref="Installer.ApplyPatch(string,string,InstallType,string)"/>.
344 /// </summary>
345 public enum InstallType : int
346 {
347 /// <summary>Searches system for products to patch.</summary>
348 Default = 0,
349
350 /// <summary>Indicates a administrative installation.</summary>
351 NetworkImage = 1,
352
353 /// <summary>Indicates a particular instance.</summary>
354 SingleInstance = 2,
355 }
356
357 /// <summary>
358 /// Level of the installation user interface, specified with
359 /// <see cref="Installer.SetInternalUI(InstallUIOptions)"/>.
360 /// </summary>
361 [SuppressMessage("Microsoft.Design", "CA1008:EnumsShouldHaveZeroValue")]
362 [Flags]
363 public enum InstallUIOptions : int
364 {
365 /// <summary>Does not change UI level.</summary>
366 NoChange = 0,
367
368 /// <summary>Uses Default UI level.</summary>
369 Default = 1,
370
371 /// <summary>Silent installation.</summary>
372 Silent = 2,
373
374 /// <summary>Simple progress and error handling.</summary>
375 Basic = 3,
376
377 /// <summary>Authored UI, wizard dialogs suppressed.</summary>
378 Reduced = 4,
379
380 /// <summary>Authored UI with wizards, progress, and errors.</summary>
381 Full = 5,
382
383 /// <summary>
384 /// When combined with the <see cref="Basic"/> value, the installer does not display
385 /// the cancel button in the progress dialog.
386 /// </summary>
387 HideCancel = 0x20,
388
389 /// <summary>
390 /// When combined with the <see cref="Basic"/> value, the installer displays progress
391 /// dialog boxes but does not display any modal dialog boxes or error dialog boxes.
392 /// </summary>
393 ProgressOnly = 0x40,
394
395 /// <summary>
396 /// When combined with another value, the installer displays a modal dialog
397 /// box at the end of a successful installation or if there has been an error.
398 /// No dialog box is displayed if the user cancels.
399 /// </summary>
400 EndDialog = 0x80,
401
402 /// <summary>
403 /// Forces display of the source resolution dialog even if the UI is otherwise silent.
404 /// </summary>
405 SourceResolutionOnly = 0x100,
406
407 /// <summary>
408 /// [MSI 5.0] Forces display of the UAC dialog even if the UI is otherwise silent.
409 /// </summary>
410 UacOnly = 0x200,
411 }
412
413 /// <summary>
414 /// Specifies a return status value for message handlers. These values are returned by
415 /// <see cref="Session.Message"/>, <see cref="ExternalUIHandler"/>, and <see cref="IEmbeddedUI.ProcessMessage"/>.
416 /// </summary>
417 public enum MessageResult : int
418 {
419 /// <summary>An error was found in the message handler.</summary>
420 Error = -1,
421
422 /// <summary>No action was taken.</summary>
423 None = 0,
424
425 /// <summary>IDOK</summary>
426 [SuppressMessage("Microsoft.Naming", "CA1706:ShortAcronymsShouldBeUppercase")]
427 OK = 1,
428
429 /// <summary>IDCANCEL</summary>
430 Cancel = 2,
431
432 /// <summary>IDABORT</summary>
433 Abort = 3,
434
435 /// <summary>IDRETRY</summary>
436 Retry = 4,
437
438 /// <summary>IDIGNORE</summary>
439 Ignore = 5,
440
441 /// <summary>IDYES</summary>
442 Yes = 6,
443
444 /// <summary>IDNO</summary>
445 No = 7,
446 }
447
448 /// <summary>
449 /// Specifies constants defining which buttons to display for a message. This can be cast to
450 /// the MessageBoxButtons enum in System.Windows.Forms and System.Windows.
451 /// </summary>
452 public enum MessageButtons
453 {
454 /// <summary>
455 /// The message contains an OK button.
456 /// </summary>
457 OK = 0,
458
459 /// <summary>
460 /// The message contains OK and Cancel buttons.
461 /// </summary>
462 OKCancel = 1,
463
464 /// <summary>
465 /// The message contains Abort, Retry, and Ignore buttons.
466 /// </summary>
467 AbortRetryIgnore = 2,
468
469 /// <summary>
470 /// The message contains Yes, No, and Cancel buttons.
471 /// </summary>
472 YesNoCancel = 3,
473
474 /// <summary>
475 /// The message contains Yes and No buttons.
476 /// </summary>
477 YesNo = 4,
478
479 /// <summary>
480 /// The message contains Retry and Cancel buttons.
481 /// </summary>
482 RetryCancel = 5,
483 }
484
485 /// <summary>
486 /// Specifies constants defining which information to display. This can be cast to
487 /// the MessageBoxIcon enum in System.Windows.Forms and System.Windows.
488 /// </summary>
489 public enum MessageIcon
490 {
491 /// <summary>
492 /// The message contain no symbols.
493 /// </summary>
494 None = 0,
495
496 /// <summary>
497 /// The message contains a symbol consisting of white X in a circle with a red background.
498 /// </summary>
499 Error = 16,
500
501 /// <summary>
502 /// The message contains a symbol consisting of a white X in a circle with a red background.
503 /// </summary>
504 Hand = 16,
505
506 /// <summary>
507 /// The message contains a symbol consisting of white X in a circle with a red background.
508 /// </summary>
509 Stop = 16,
510
511 /// <summary>
512 /// The message contains a symbol consisting of a question mark in a circle.
513 /// </summary>
514 Question = 32,
515
516 /// <summary>
517 /// The message contains a symbol consisting of an exclamation point in a triangle with a yellow background.
518 /// </summary>
519 Exclamation = 48,
520
521 /// <summary>
522 /// The message contains a symbol consisting of an exclamation point in a triangle with a yellow background.
523 /// </summary>
524 Warning = 48,
525
526 /// <summary>
527 /// The message contains a symbol consisting of a lowercase letter i in a circle.
528 /// </summary>
529 Information = 64,
530
531 /// <summary>
532 /// The message contains a symbol consisting of a lowercase letter i in a circle.
533 /// </summary>
534 Asterisk = 64,
535 }
536
537 /// <summary>
538 /// Specifies constants defining the default button on a message. This can be cast to
539 /// the MessageBoxDefaultButton enum in System.Windows.Forms and System.Windows.
540 /// </summary>
541 public enum MessageDefaultButton
542 {
543 /// <summary>
544 /// The first button on the message is the default button.
545 /// </summary>
546 Button1 = 0,
547
548 /// <summary>
549 /// The second button on the message is the default button.
550 /// </summary>
551 Button2 = 256,
552
553 /// <summary>
554 /// The third button on the message is the default button.
555 /// </summary>
556 Button3 = 512,
557 }
558
559 /// <summary>
560 /// Additional styles for use with message boxes.
561 /// </summary>
562 [Flags]
563 internal enum MessageBoxStyles
564 {
565 /// <summary>
566 /// The message box is created with the WS_EX_TOPMOST window style.
567 /// </summary>
568 TopMost = 0x00040000,
569
570 /// <summary>
571 /// The caller is a service notifying the user of an event.
572 /// The function displays a message box on the current active desktop, even if there is no user logged on to the computer.
573 /// </summary>
574 ServiceNotification = 0x00200000,
575 }
576
577 /// <summary>
578 /// Specifies the different patch states for <see cref="PatchInstallation.GetPatches(string, string, string, UserContexts, PatchStates)"/>.
579 /// </summary>
580 [Flags]
581 public enum PatchStates : int
582 {
583 /// <summary>Invalid value.</summary>
584 None = 0,
585
586 /// <summary>Patches applied to a product.</summary>
587 Applied = 1,
588
589 /// <summary>Patches that are superseded by other patches.</summary>
590 Superseded = 2,
591
592 /// <summary>Patches that are obsolesced by other patches.</summary>
593 [SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly", MessageId = "Obsoleted")]
594 Obsoleted = 4,
595
596 /// <summary>Patches that are registered to a product but not applied.</summary>
597 Registered = 8,
598
599 /// <summary>All valid patch states.</summary>
600 All = (Applied | Superseded | Obsoleted | Registered)
601 }
602
603 /// <summary>
604 /// Specifies the reinstall mode for <see cref="Installer.ReinstallFeature"/> or <see cref="Installer.ReinstallProduct"/>.
605 /// </summary>
606 [Flags]
607 public enum ReinstallModes : int
608 {
609 /// <summary>Reinstall only if file is missing.</summary>
610 FileMissing = 0x00000002,
611
612 /// <summary>Reinstall if file is missing, or older version.</summary>
613 FileOlderVersion = 0x00000004,
614
615 /// <summary>Reinstall if file is missing, or equal or older version.</summary>
616 FileEqualVersion = 0x00000008,
617
618 /// <summary>Reinstall if file is missing, or not exact version.</summary>
619 FileExact = 0x00000010,
620
621 /// <summary>Checksum executables, reinstall if missing or corrupt.</summary>
622 FileVerify = 0x00000020,
623
624 /// <summary>Reinstall all files, regardless of version.</summary>
625 FileReplace = 0x00000040,
626
627 /// <summary>Insure required machine reg entries.</summary>
628 MachineData = 0x00000080,
629
630 /// <summary>Insure required user reg entries.</summary>
631 UserData = 0x00000100,
632
633 /// <summary>Validate shortcuts items.</summary>
634 Shortcut = 0x00000200,
635
636 /// <summary>Use re-cache source install package.</summary>
637 Package = 0x00000400,
638 }
639
640 /// <summary>
641 /// Attributes for <see cref="Transaction"/> methods.
642 /// </summary>
643 [Flags]
644 public enum TransactionAttributes : int
645 {
646 /// <summary>No attributes.</summary>
647 None = 0x00000000,
648
649 /// <summary>Request that the Windows Installer not shutdown the embedded UI until the transaction is complete.</summary>
650 ChainEmbeddedUI = 0x00000001,
651
652 /// <summary>Request that the Windows Installer transfer the embedded UI from the original installation.</summary>
653 JoinExistingEmbeddedUI = 0x00000002,
654 }
655
656 /// <summary>
657 /// Transform error conditions available for <see cref="Database.CreateTransformSummaryInfo"/> or
658 /// <see cref="Database.ApplyTransform(string,TransformErrors)"/>.
659 /// </summary>
660 [Flags]
661 public enum TransformErrors : int
662 {
663 /// <summary>No error conditions.</summary>
664 None = 0x0000,
665
666 /// <summary>Adding a row that already exists.</summary>
667 AddExistingRow = 0x0001,
668
669 /// <summary>Deleting a row that doesn't exist.</summary>
670 DelMissingRow = 0x0002,
671
672 /// <summary>Adding a table that already exists.</summary>
673 AddExistingTable = 0x0004,
674
675 /// <summary>Deleting a table that doesn't exist.</summary>
676 DelMissingTable = 0x0008,
677
678 /// <summary>Updating a row that doesn't exist.</summary>
679 UpdateMissingRow = 0x0010,
680
681 /// <summary>Transform and database code pages do not match and neither code page is neutral.</summary>
682 ChangeCodePage = 0x0020,
683
684 /// <summary>Create the temporary _TransformView table when applying the transform.</summary>
685 ViewTransform = 0x0100,
686 }
687
688 /// <summary>
689 /// Transform validation flags available for <see cref="Database.CreateTransformSummaryInfo"/>.
690 /// </summary>
691 [Flags]
692 public enum TransformValidations : int
693 {
694 /// <summary>Validate no properties.</summary>
695 None = 0x0000,
696
697 /// <summary>Default language must match base database.</summary>
698 Language = 0x0001,
699
700 /// <summary>Product must match base database.</summary>
701 Product = 0x0002,
702
703 /// <summary>Check major version only.</summary>
704 MajorVersion = 0x0008,
705
706 /// <summary>Check major and minor versions only.</summary>
707 MinorVersion = 0x0010,
708
709 /// <summary>Check major, minor, and update versions.</summary>
710 UpdateVersion = 0x0020,
711
712 /// <summary>Installed version &lt; base version.</summary>
713 NewLessBaseVersion = 0x0040,
714
715 /// <summary>Installed version &lt;= base version.</summary>
716 NewLessEqualBaseVersion = 0x0080,
717
718 /// <summary>Installed version = base version.</summary>
719 NewEqualBaseVersion = 0x0100,
720
721 /// <summary>Installed version &gt;= base version.</summary>
722 NewGreaterEqualBaseVersion = 0x0200,
723
724 /// <summary>Installed version &gt; base version.</summary>
725 NewGreaterBaseVersion = 0x0400,
726
727 /// <summary>UpgradeCode must match base database.</summary>
728 UpgradeCode = 0x0800,
729 }
730
731 /// <summary>
732 /// Specifies the installation context for <see cref="ProductInstallation"/>s,
733 /// <see cref="PatchInstallation"/>es, and
734 /// <see cref="Installer.DetermineApplicablePatches(string,string[],InapplicablePatchHandler,string,UserContexts)"/>
735 /// </summary>
736 [Flags]
737 public enum UserContexts : int
738 {
739 /// <summary>Not installed.</summary>
740 None = 0,
741
742 /// <summary>User managed install context.</summary>
743 UserManaged = 1,
744
745 /// <summary>User non-managed context.</summary>
746 UserUnmanaged = 2,
747
748 /// <summary>Per-machine context.</summary>
749 Machine = 4,
750
751 /// <summary>All contexts, or all valid values.</summary>
752 All = (UserManaged | UserUnmanaged | Machine),
753
754 /// <summary>All user-managed contexts.</summary>
755 AllUserManaged = 8,
756 }
757
758 /// <summary>
759 /// Defines the type of error encountered by the <see cref="View.Validate"/>, <see cref="View.ValidateNew"/>,
760 /// or <see cref="View.ValidateFields"/> methods of the <see cref="View"/> class.
761 /// </summary>
762 public enum ValidationError : int
763 {
764 /*
765 InvalidArg = -3,
766 MoreData = -2,
767 FunctionError = -1,
768 */
769
770 /// <summary>No error.</summary>
771 None = 0,
772
773 /// <summary>The new record duplicates primary keys of the existing record in a table.</summary>
774 DuplicateKey = 1,
775
776 /// <summary>There are no null values allowed, or the column is about to be deleted but is referenced by another row.</summary>
777 Required = 2,
778
779 /// <summary>The corresponding record in a foreign table was not found.</summary>
780 BadLink = 3,
781
782 /// <summary>The data is greater than the maximum value allowed.</summary>
783 Overflow = 4,
784
785 /// <summary>The data is less than the minimum value allowed.</summary>
786 Underflow = 5,
787
788 /// <summary>The data is not a member of the values permitted in the set.</summary>
789 NotInSet = 6,
790
791 /// <summary>An invalid version string was supplied.</summary>
792 BadVersion = 7,
793
794 /// <summary>The case was invalid. The case must be all uppercase or all lowercase.</summary>
795 BadCase = 8,
796
797 /// <summary>An invalid GUID was supplied.</summary>
798 BadGuid = 9,
799
800 /// <summary>An invalid wildcard file name was supplied, or the use of wildcards was invalid.</summary>
801 BadWildcard = 10,
802
803 /// <summary>An invalid identifier was supplied.</summary>
804 BadIdentifier = 11,
805
806 /// <summary>Invalid language IDs were supplied.</summary>
807 BadLanguage = 12,
808
809 /// <summary>An invalid file name was supplied.</summary>
810 BadFileName = 13,
811
812 /// <summary>An invalid path was supplied.</summary>
813 BadPath = 14,
814
815 /// <summary>An invalid conditional statement was supplied.</summary>
816 BadCondition = 15,
817
818 /// <summary>An invalid format string was supplied.</summary>
819 BadFormatted = 16,
820
821 /// <summary>An invalid template string was supplied.</summary>
822 BadTemplate = 17,
823
824 /// <summary>An invalid string was supplied in the DefaultDir column of the Directory table.</summary>
825 BadDefaultDir = 18,
826
827 /// <summary>An invalid registry path string was supplied.</summary>
828 BadRegPath = 19,
829
830 /// <summary>An invalid string was supplied in the CustomSource column of the CustomAction table.</summary>
831 BadCustomSource = 20,
832
833 /// <summary>An invalid property string was supplied.</summary>
834 BadProperty = 21,
835
836 /// <summary>The _Validation table is missing a reference to a column.</summary>
837 MissingData = 22,
838
839 /// <summary>The category column of the _Validation table for the column is invalid.</summary>
840 BadCategory = 23,
841
842 /// <summary>The table in the Keytable column of the _Validation table was not found or loaded.</summary>
843 BadKeyTable = 24,
844
845 /// <summary>The value in the MaxValue column of the _Validation table is less than the value in the MinValue column.</summary>
846 BadMaxMinValues = 25,
847
848 /// <summary>An invalid cabinet name was supplied.</summary>
849 BadCabinet = 26,
850
851 /// <summary>An invalid shortcut target name was supplied.</summary>
852 BadShortcut = 27,
853
854 /// <summary>The string is too long for the length specified by the column definition.</summary>
855 StringOverflow = 28,
856
857 /// <summary>An invalid localization attribute was supplied. (Primary keys cannot be localized.)</summary>
858 BadLocalizeAttrib = 29
859 }
860
861 /// <summary>
862 /// Specifies the modify mode for <see cref="View.Modify"/>.
863 /// </summary>
864 public enum ViewModifyMode : int
865 {
866 /// <summary>
867 /// Refreshes the information in the supplied record without changing the position
868 /// in the result set and without affecting subsequent fetch operations.
869 /// </summary>
870 Seek = -1,
871
872 /// <summary>Refreshes the data in a Record.</summary>
873 Refresh = 0,
874
875 /// <summary>Inserts a Record into the view.</summary>
876 Insert = 1,
877
878 /// <summary>Updates the View with new data from the Record.</summary>
879 Update = 2,
880
881 /// <summary>Updates or inserts a Record into the View.</summary>
882 Assign = 3,
883
884 /// <summary>Updates or deletes and inserts a Record into the View.</summary>
885 Replace = 4,
886
887 /// <summary>Inserts or validates a record.</summary>
888 Merge = 5,
889
890 /// <summary>Deletes a Record from the View.</summary>
891 Delete = 6,
892
893 /// <summary>Inserts a Record into the View. The inserted data is not persistent.</summary>
894 InsertTemporary = 7,
895
896 /// <summary>Validates a record.</summary>
897 Validate = 8,
898
899 /// <summary>Validates a new record.</summary>
900 [SuppressMessage("Microsoft.Naming", "CA1711:IdentifiersShouldNotHaveIncorrectSuffix")]
901 ValidateNew = 9,
902
903 /// <summary>Validates fields of a fetched or new record. Can validate one or more fields of an incomplete record.</summary>
904 ValidateField = 10,
905
906 /// <summary>Validates a record that will be deleted later.</summary>
907 ValidateDelete = 11,
908 }
909}