From 2c15f33036489464f6ebd7cc1584e1975e765899 Mon Sep 17 00:00:00 2001 From: Rob Mensching Date: Wed, 8 May 2019 13:41:41 -0700 Subject: Rename ComponentKeyPathType to PossibleKeyPathType --- .../Data/ComponentKeyPathType.cs | 37 ---------------------- .../Data/IComponentKeyPath.cs | 2 +- .../Data/PossibleKeyPathType.cs | 37 ++++++++++++++++++++++ .../Services/IParseHelper.cs | 7 ++-- .../WixToolset.Extensibility.csproj | 2 +- 5 files changed, 43 insertions(+), 42 deletions(-) delete mode 100644 src/WixToolset.Extensibility/Data/ComponentKeyPathType.cs create mode 100644 src/WixToolset.Extensibility/Data/PossibleKeyPathType.cs (limited to 'src') diff --git a/src/WixToolset.Extensibility/Data/ComponentKeyPathType.cs b/src/WixToolset.Extensibility/Data/ComponentKeyPathType.cs deleted file mode 100644 index 58bbb0cf..00000000 --- a/src/WixToolset.Extensibility/Data/ComponentKeyPathType.cs +++ /dev/null @@ -1,37 +0,0 @@ -// 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. - -namespace WixToolset.Extensibility.Data -{ - public enum ComponentKeyPathType - { - /// - /// Not a key path. - /// - None, - - /// - /// File resource as a key path. - /// - File, - - /// - /// Folder as a key path. - /// - Directory, - - /// - /// ODBC data source as a key path. - /// - OdbcDataSource, - - /// - /// A simple registry key acting as a key path. - /// - Registry, - - /// - /// A registry key that contains a formatted property acting as a key path. - /// - RegistryFormatted - } -} diff --git a/src/WixToolset.Extensibility/Data/IComponentKeyPath.cs b/src/WixToolset.Extensibility/Data/IComponentKeyPath.cs index ba660b45..9417b836 100644 --- a/src/WixToolset.Extensibility/Data/IComponentKeyPath.cs +++ b/src/WixToolset.Extensibility/Data/IComponentKeyPath.cs @@ -8,6 +8,6 @@ namespace WixToolset.Extensibility.Data string Id { get; set; } - ComponentKeyPathType Type { get; set; } + PossibleKeyPathType Type { get; set; } } } diff --git a/src/WixToolset.Extensibility/Data/PossibleKeyPathType.cs b/src/WixToolset.Extensibility/Data/PossibleKeyPathType.cs new file mode 100644 index 00000000..75ccb1d1 --- /dev/null +++ b/src/WixToolset.Extensibility/Data/PossibleKeyPathType.cs @@ -0,0 +1,37 @@ +// 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. + +namespace WixToolset.Extensibility.Data +{ + public enum PossibleKeyPathType + { + /// + /// Not a key path. + /// + None, + + /// + /// File resource as a key path. + /// + File, + + /// + /// Folder as a key path. + /// + Directory, + + /// + /// ODBC data source as a key path. + /// + OdbcDataSource, + + /// + /// A simple registry key acting as a key path. + /// + Registry, + + /// + /// A registry key that contains a formatted property acting as a key path. + /// + RegistryFormatted + } +} diff --git a/src/WixToolset.Extensibility/Services/IParseHelper.cs b/src/WixToolset.Extensibility/Services/IParseHelper.cs index 36caf192..a4eb3ce7 100644 --- a/src/WixToolset.Extensibility/Services/IParseHelper.cs +++ b/src/WixToolset.Extensibility/Services/IParseHelper.cs @@ -6,6 +6,7 @@ namespace WixToolset.Extensibility.Services using System.Collections.Generic; using System.Xml.Linq; using WixToolset.Data; + using WixToolset.Data.Tuples; using WixToolset.Extensibility.Data; /// @@ -89,7 +90,7 @@ namespace WixToolset.Extensibility.Services /// The registry entry value. /// The component which will control installation/uninstallation of the registry entry. /// If true, "escape" leading '#' characters so the value is written as a REG_SZ. - Identifier CreateRegistryRow(IntermediateSection section, SourceLineNumber sourceLineNumbers, int root, string key, string name, string value, string componentId, bool escapeLeadingHash); + Identifier CreateRegistryRow(IntermediateSection section, SourceLineNumber sourceLineNumbers, RegistryRootType root, string key, string name, string value, string componentId, bool escapeLeadingHash); /// /// Creates a short file/directory name using an identifier and long file/directory name as input. @@ -220,13 +221,13 @@ namespace WixToolset.Extensibility.Services string GetAttributeLongFilename(SourceLineNumber sourceLineNumbers, XAttribute attribute, bool allowWildcards = false, bool allowRelative = false); /// - /// Gets a RegistryRoot as a MsiInterop.MsidbRegistryRoot value and displays an error for an illegal value. + /// Gets a RegistryRootType value and displays an error for an illegal value. /// /// Source line information about the owner element. /// The attribute containing the value to get. /// Whether HKMU is returned as -1 (true), or treated as an error (false). /// The attribute's RegisitryRootType value. - int GetAttributeMsidbRegistryRootValue(SourceLineNumber sourceLineNumbers, XAttribute attribute, bool allowHkmu); + RegistryRootType? GetAttributeRegistryRootValue(SourceLineNumber sourceLineNumbers, XAttribute attribute, bool allowHkmu); /// /// Gets a version value or possibly a binder variable and displays an error for an illegal version value. diff --git a/src/WixToolset.Extensibility/WixToolset.Extensibility.csproj b/src/WixToolset.Extensibility/WixToolset.Extensibility.csproj index 31d5ca87..997c10ce 100644 --- a/src/WixToolset.Extensibility/WixToolset.Extensibility.csproj +++ b/src/WixToolset.Extensibility/WixToolset.Extensibility.csproj @@ -15,7 +15,7 @@ - + -- cgit v1.2.3-55-g6feb