| 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 WixInstanceTransforms = new IntermediateSymbolDefinition( |
| 10 | SymbolDefinitionType.WixInstanceTransforms, |
| 11 | new[] |
| 12 | { |
| 13 | new IntermediateFieldDefinition(nameof(WixInstanceTransformsSymbolFields.PropertyId), IntermediateFieldType.String), |
| 14 | new IntermediateFieldDefinition(nameof(WixInstanceTransformsSymbolFields.ProductCode), IntermediateFieldType.String), |
| 15 | new IntermediateFieldDefinition(nameof(WixInstanceTransformsSymbolFields.ProductName), IntermediateFieldType.String), |
| 16 | new IntermediateFieldDefinition(nameof(WixInstanceTransformsSymbolFields.UpgradeCode), IntermediateFieldType.String), |
| 17 | }, |
| 18 | typeof(WixInstanceTransformsSymbol)); |
| 19 | } |
| 20 | } |
| 21 | |
| 22 | namespace WixToolset.Data.Symbols |
| 23 | { |
| 24 | public enum WixInstanceTransformsSymbolFields |
| 25 | { |
| 26 | PropertyId, |
| 27 | ProductCode, |
| 28 | ProductName, |
| 29 | UpgradeCode, |
| 30 | } |
| 31 | |
| 32 | public class WixInstanceTransformsSymbol : IntermediateSymbol |
| 33 | { |
| 34 | public WixInstanceTransformsSymbol() : base(SymbolDefinitions.WixInstanceTransforms, null, null) |
| 35 | { |
| 36 | } |
| 37 | |
| 38 | public WixInstanceTransformsSymbol(SourceLineNumber sourceLineNumber, Identifier id = null) : base(SymbolDefinitions.WixInstanceTransforms, sourceLineNumber, id) |
| 39 | { |
| 40 | } |
| 41 | |
| 42 | public IntermediateField this[WixInstanceTransformsSymbolFields index] => this.Fields[(int)index]; |
| 43 | |
| 44 | public string PropertyId |
| 45 | { |
| 46 | get => (string)this.Fields[(int)WixInstanceTransformsSymbolFields.PropertyId]; |
| 47 | set => this.Set((int)WixInstanceTransformsSymbolFields.PropertyId, value); |
| 48 | } |
| 49 | |
| 50 | public string ProductCode |
| 51 | { |
| 52 | get => (string)this.Fields[(int)WixInstanceTransformsSymbolFields.ProductCode]; |
| 53 | set => this.Set((int)WixInstanceTransformsSymbolFields.ProductCode, value); |
| 54 | } |
| 55 | |
| 56 | public string ProductName |
| 57 | { |
| 58 | get => (string)this.Fields[(int)WixInstanceTransformsSymbolFields.ProductName]; |
| 59 | set => this.Set((int)WixInstanceTransformsSymbolFields.ProductName, value); |
| 60 | } |
| 61 | |
| 62 | public string UpgradeCode |
| 63 | { |
| 64 | get => (string)this.Fields[(int)WixInstanceTransformsSymbolFields.UpgradeCode]; |
| 65 | set => this.Set((int)WixInstanceTransformsSymbolFields.UpgradeCode, value); |
| 66 | } |
| 67 | } |
| 68 | } |