From 2bb37beda887d120a0ddabf874ad25357101faa1 Mon Sep 17 00:00:00 2001 From: Rob Mensching Date: Wed, 1 Nov 2017 10:59:45 -0700 Subject: Update to WiX Intermediate Representation --- src/WixToolset.Core/Link/ConnectToFeature.cs | 50 +++++++--------------------- 1 file changed, 12 insertions(+), 38 deletions(-) (limited to 'src/WixToolset.Core/Link/ConnectToFeature.cs') diff --git a/src/WixToolset.Core/Link/ConnectToFeature.cs b/src/WixToolset.Core/Link/ConnectToFeature.cs index 6e046b89..bc85426a 100644 --- a/src/WixToolset.Core/Link/ConnectToFeature.cs +++ b/src/WixToolset.Core/Link/ConnectToFeature.cs @@ -2,7 +2,7 @@ namespace WixToolset.Link { - using System.Collections.Specialized; + using System.Collections.Generic; using WixToolset.Data; /// @@ -10,19 +10,12 @@ namespace WixToolset.Link /// public sealed class ConnectToFeature { - private Section section; - private string childId; - - private string primaryFeature; - private bool explicitPrimaryFeature; - private StringCollection connectFeatures; - /// /// Creates a new connect to feature. /// /// Section this connect belongs to. /// Id of the child. - public ConnectToFeature(Section section, string childId) : + public ConnectToFeature(IntermediateSection section, string childId) : this(section, childId, null, false) { } @@ -34,62 +27,43 @@ namespace WixToolset.Link /// Id of the child. /// Sets the primary feature for the connection. /// Sets if this is explicit primary. - public ConnectToFeature(Section section, string childId, string primaryFeature, bool explicitPrimaryFeature) + public ConnectToFeature(IntermediateSection section, string childId, string primaryFeature, bool explicitPrimaryFeature) { - this.section = section; - this.childId = childId; + this.Section = section; + this.ChildId = childId; - this.primaryFeature = primaryFeature; - this.explicitPrimaryFeature = explicitPrimaryFeature; - - this.connectFeatures = new StringCollection(); + this.PrimaryFeature = primaryFeature; + this.IsExplicitPrimaryFeature = explicitPrimaryFeature; } /// /// Gets the section. /// /// Section. - public Section Section - { - get { return this.section; } - } + public IntermediateSection Section { get; } /// /// Gets the child identifier. /// /// The child identifier. - public string ChildId - { - get { return this.childId; } - } + public string ChildId { get; } /// /// Gets or sets if the flag for if the primary feature was set explicitly. /// /// The flag for if the primary feature was set explicitly. - public bool IsExplicitPrimaryFeature - { - get { return this.explicitPrimaryFeature; } - set { this.explicitPrimaryFeature = value; } - } + public bool IsExplicitPrimaryFeature { get; set; } /// /// Gets or sets the primary feature. /// /// The primary feature. - public string PrimaryFeature - { - get { return this.primaryFeature; } - set { this.primaryFeature = value; } - } + public string PrimaryFeature { get; set; } /// /// Gets the features connected to. /// /// Features connected to. - public StringCollection ConnectFeatures - { - get { return this.connectFeatures; } - } + public List ConnectFeatures { get; } = new List(); } } -- cgit v1.2.3-55-g6feb