diff options
Diffstat (limited to 'src/WixToolset.Data/Symbols/WixOrderingSymbol.cs')
-rw-r--r-- | src/WixToolset.Data/Symbols/WixOrderingSymbol.cs | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/src/WixToolset.Data/Symbols/WixOrderingSymbol.cs b/src/WixToolset.Data/Symbols/WixOrderingSymbol.cs new file mode 100644 index 00000000..5e6dc980 --- /dev/null +++ b/src/WixToolset.Data/Symbols/WixOrderingSymbol.cs | |||
@@ -0,0 +1,68 @@ | |||
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.Data | ||
4 | { | ||
5 | using WixToolset.Data.Symbols; | ||
6 | |||
7 | public static partial class SymbolDefinitions | ||
8 | { | ||
9 | public static readonly IntermediateSymbolDefinition WixOrdering = new IntermediateSymbolDefinition( | ||
10 | SymbolDefinitionType.WixOrdering, | ||
11 | new[] | ||
12 | { | ||
13 | new IntermediateFieldDefinition(nameof(WixOrderingSymbolFields.ItemType), IntermediateFieldType.String), | ||
14 | new IntermediateFieldDefinition(nameof(WixOrderingSymbolFields.ItemIdRef), IntermediateFieldType.String), | ||
15 | new IntermediateFieldDefinition(nameof(WixOrderingSymbolFields.DependsOnType), IntermediateFieldType.String), | ||
16 | new IntermediateFieldDefinition(nameof(WixOrderingSymbolFields.DependsOnIdRef), IntermediateFieldType.String), | ||
17 | }, | ||
18 | typeof(WixOrderingSymbol)); | ||
19 | } | ||
20 | } | ||
21 | |||
22 | namespace WixToolset.Data.Symbols | ||
23 | { | ||
24 | public enum WixOrderingSymbolFields | ||
25 | { | ||
26 | ItemType, | ||
27 | ItemIdRef, | ||
28 | DependsOnType, | ||
29 | DependsOnIdRef, | ||
30 | } | ||
31 | |||
32 | public class WixOrderingSymbol : IntermediateSymbol | ||
33 | { | ||
34 | public WixOrderingSymbol() : base(SymbolDefinitions.WixOrdering, null, null) | ||
35 | { | ||
36 | } | ||
37 | |||
38 | public WixOrderingSymbol(SourceLineNumber sourceLineNumber, Identifier id = null) : base(SymbolDefinitions.WixOrdering, sourceLineNumber, id) | ||
39 | { | ||
40 | } | ||
41 | |||
42 | public IntermediateField this[WixOrderingSymbolFields index] => this.Fields[(int)index]; | ||
43 | |||
44 | public ComplexReferenceChildType ItemType | ||
45 | { | ||
46 | get => (ComplexReferenceChildType)this.Fields[(int)WixOrderingSymbolFields.ItemType].AsNumber(); | ||
47 | set => this.Set((int)WixOrderingSymbolFields.ItemType, (int)value); | ||
48 | } | ||
49 | |||
50 | public string ItemIdRef | ||
51 | { | ||
52 | get => (string)this.Fields[(int)WixOrderingSymbolFields.ItemIdRef]; | ||
53 | set => this.Set((int)WixOrderingSymbolFields.ItemIdRef, value); | ||
54 | } | ||
55 | |||
56 | public ComplexReferenceChildType DependsOnType | ||
57 | { | ||
58 | get => (ComplexReferenceChildType)this.Fields[(int)WixOrderingSymbolFields.DependsOnType].AsNumber(); | ||
59 | set => this.Set((int)WixOrderingSymbolFields.DependsOnType, (int)value); | ||
60 | } | ||
61 | |||
62 | public string DependsOnIdRef | ||
63 | { | ||
64 | get => (string)this.Fields[(int)WixOrderingSymbolFields.DependsOnIdRef]; | ||
65 | set => this.Set((int)WixOrderingSymbolFields.DependsOnIdRef, value); | ||
66 | } | ||
67 | } | ||
68 | } \ No newline at end of file | ||