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