diff options
author | Sean Hall <r.sean.hall@gmail.com> | 2023-01-18 19:03:44 -0600 |
---|---|---|
committer | Sean Hall <r.sean.hall@gmail.com> | 2023-01-18 20:07:03 -0600 |
commit | 7a0aa56131ba7fa3b63788908c164d0f8118e3fc (patch) | |
tree | de06072b4bcf95c77afbae6efbf31df83f2848e0 /src/ext/Bal/wixext/Symbols | |
parent | d180bc6df297422f189ffd08a0dd558bfbeba1ca (diff) | |
download | wix-7a0aa56131ba7fa3b63788908c164d0f8118e3fc.tar.gz wix-7a0aa56131ba7fa3b63788908c164d0f8118e3fc.tar.bz2 wix-7a0aa56131ba7fa3b63788908c164d0f8118e3fc.zip |
Improve error messages from BalBurnBackendExtension.
Diffstat (limited to 'src/ext/Bal/wixext/Symbols')
-rw-r--r-- | src/ext/Bal/wixext/Symbols/BalSymbolDefinitions.cs | 6 | ||||
-rw-r--r-- | src/ext/Bal/wixext/Symbols/WixBalBootstrapperApplicationSymbol.cs | 56 |
2 files changed, 60 insertions, 2 deletions
diff --git a/src/ext/Bal/wixext/Symbols/BalSymbolDefinitions.cs b/src/ext/Bal/wixext/Symbols/BalSymbolDefinitions.cs index 22375508..5229f278 100644 --- a/src/ext/Bal/wixext/Symbols/BalSymbolDefinitions.cs +++ b/src/ext/Bal/wixext/Symbols/BalSymbolDefinitions.cs | |||
@@ -18,12 +18,11 @@ namespace WixToolset.Bal | |||
18 | WixStdbaOptions, | 18 | WixStdbaOptions, |
19 | WixStdbaOverridableVariable, | 19 | WixStdbaOverridableVariable, |
20 | WixMbaPrereqOptions, | 20 | WixMbaPrereqOptions, |
21 | WixBalBootstrapperApplication, | ||
21 | } | 22 | } |
22 | 23 | ||
23 | public static partial class BalSymbolDefinitions | 24 | public static partial class BalSymbolDefinitions |
24 | { | 25 | { |
25 | public static readonly Version Version = new Version("4.0.0"); | ||
26 | |||
27 | public static IntermediateSymbolDefinition ByName(string name) | 26 | public static IntermediateSymbolDefinition ByName(string name) |
28 | { | 27 | { |
29 | if (!Enum.TryParse(name, out BalSymbolDefinitionType type)) | 28 | if (!Enum.TryParse(name, out BalSymbolDefinitionType type)) |
@@ -68,6 +67,9 @@ namespace WixToolset.Bal | |||
68 | case BalSymbolDefinitionType.WixMbaPrereqOptions: | 67 | case BalSymbolDefinitionType.WixMbaPrereqOptions: |
69 | return BalSymbolDefinitions.WixMbaPrereqOptions; | 68 | return BalSymbolDefinitions.WixMbaPrereqOptions; |
70 | 69 | ||
70 | case BalSymbolDefinitionType.WixBalBootstrapperApplication: | ||
71 | return BalSymbolDefinitions.WixBalBootstrapperApplication; | ||
72 | |||
71 | default: | 73 | default: |
72 | throw new ArgumentOutOfRangeException(nameof(type)); | 74 | throw new ArgumentOutOfRangeException(nameof(type)); |
73 | } | 75 | } |
diff --git a/src/ext/Bal/wixext/Symbols/WixBalBootstrapperApplicationSymbol.cs b/src/ext/Bal/wixext/Symbols/WixBalBootstrapperApplicationSymbol.cs new file mode 100644 index 00000000..7096930d --- /dev/null +++ b/src/ext/Bal/wixext/Symbols/WixBalBootstrapperApplicationSymbol.cs | |||
@@ -0,0 +1,56 @@ | |||
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 | |||
3 | namespace WixToolset.Bal | ||
4 | { | ||
5 | using WixToolset.Data; | ||
6 | using WixToolset.Bal.Symbols; | ||
7 | |||
8 | public static partial class BalSymbolDefinitions | ||
9 | { | ||
10 | public static readonly IntermediateSymbolDefinition WixBalBootstrapperApplication = new IntermediateSymbolDefinition( | ||
11 | BalSymbolDefinitionType.WixBalBootstrapperApplication.ToString(), | ||
12 | new[] | ||
13 | { | ||
14 | new IntermediateFieldDefinition(nameof(WixBalBootstrapperApplicationSymbolFields.Type), IntermediateFieldType.Number), | ||
15 | }, | ||
16 | typeof(WixBalBootstrapperApplicationSymbol)); | ||
17 | } | ||
18 | } | ||
19 | |||
20 | namespace WixToolset.Bal.Symbols | ||
21 | { | ||
22 | using WixToolset.Data; | ||
23 | |||
24 | public enum WixBalBootstrapperApplicationType | ||
25 | { | ||
26 | Unknown, | ||
27 | Standard, | ||
28 | ManagedHost, | ||
29 | DotNetCoreHost, | ||
30 | InternalUi, | ||
31 | } | ||
32 | |||
33 | public enum WixBalBootstrapperApplicationSymbolFields | ||
34 | { | ||
35 | Type, | ||
36 | } | ||
37 | |||
38 | public class WixBalBootstrapperApplicationSymbol : IntermediateSymbol | ||
39 | { | ||
40 | public WixBalBootstrapperApplicationSymbol() : base(BalSymbolDefinitions.WixBalBootstrapperApplication, null, null) | ||
41 | { | ||
42 | } | ||
43 | |||
44 | public WixBalBootstrapperApplicationSymbol(SourceLineNumber sourceLineNumber, Identifier id = null) : base(BalSymbolDefinitions.WixBalBootstrapperApplication, sourceLineNumber, id) | ||
45 | { | ||
46 | } | ||
47 | |||
48 | public IntermediateField this[WixBalBootstrapperApplicationSymbolFields index] => this.Fields[(int)index]; | ||
49 | |||
50 | public WixBalBootstrapperApplicationType Type | ||
51 | { | ||
52 | get => (WixBalBootstrapperApplicationType)this.Fields[(int)WixBalBootstrapperApplicationSymbolFields.Type].AsNumber(); | ||
53 | set => this.Set((int)WixBalBootstrapperApplicationSymbolFields.Type, (int)value); | ||
54 | } | ||
55 | } | ||
56 | } | ||