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