diff options
Diffstat (limited to 'src/WixToolset.Core/Bind/ResolveDelayedFieldsCommand.cs')
| -rw-r--r-- | src/WixToolset.Core/Bind/ResolveDelayedFieldsCommand.cs | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/src/WixToolset.Core/Bind/ResolveDelayedFieldsCommand.cs b/src/WixToolset.Core/Bind/ResolveDelayedFieldsCommand.cs index 4ffe9e82..15365c2a 100644 --- a/src/WixToolset.Core/Bind/ResolveDelayedFieldsCommand.cs +++ b/src/WixToolset.Core/Bind/ResolveDelayedFieldsCommand.cs | |||
| @@ -1,23 +1,22 @@ | |||
| 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. | 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 | 2 | ||
| 3 | namespace WixToolset.Bind | 3 | namespace WixToolset.Core.Bind |
| 4 | { | 4 | { |
| 5 | using System; | 5 | using System; |
| 6 | using System.Collections.Generic; | 6 | using System.Collections.Generic; |
| 7 | using System.Globalization; | 7 | using System.Globalization; |
| 8 | using System.Linq; | ||
| 9 | using System.Text; | ||
| 10 | using WixToolset.Data; | 8 | using WixToolset.Data; |
| 9 | using WixToolset.Extensibility; | ||
| 11 | 10 | ||
| 12 | /// <summary> | 11 | /// <summary> |
| 13 | /// Resolves the fields which had variables that needed to be resolved after the file information | 12 | /// Resolves the fields which had variables that needed to be resolved after the file information |
| 14 | /// was loaded. | 13 | /// was loaded. |
| 15 | /// </summary> | 14 | /// </summary> |
| 16 | internal class ResolveDelayedFieldsCommand : ICommand | 15 | public class ResolveDelayedFieldsCommand : ICommand |
| 17 | { | 16 | { |
| 18 | public OutputType OutputType { private get; set;} | 17 | public OutputType OutputType { private get; set;} |
| 19 | 18 | ||
| 20 | public IEnumerable<DelayedField> DelayedFields { private get; set;} | 19 | public IEnumerable<IDelayedField> DelayedFields { private get; set;} |
| 21 | 20 | ||
| 22 | public IDictionary<string, string> VariableCache { private get; set; } | 21 | public IDictionary<string, string> VariableCache { private get; set; } |
| 23 | 22 | ||
| @@ -29,9 +28,9 @@ namespace WixToolset.Bind | |||
| 29 | /// <param name="modularizationGuid">The modularization guid (used in case of a merge module).</param> | 28 | /// <param name="modularizationGuid">The modularization guid (used in case of a merge module).</param> |
| 30 | public void Execute() | 29 | public void Execute() |
| 31 | { | 30 | { |
| 32 | List<DelayedField> deferredFields = new List<DelayedField>(); | 31 | var deferredFields = new List<IDelayedField>(); |
| 33 | 32 | ||
| 34 | foreach (DelayedField delayedField in this.DelayedFields) | 33 | foreach (IDelayedField delayedField in this.DelayedFields) |
| 35 | { | 34 | { |
| 36 | try | 35 | try |
| 37 | { | 36 | { |
| @@ -43,7 +42,7 @@ namespace WixToolset.Bind | |||
| 43 | string value = WixVariableResolver.ResolveDelayedVariables(propertyRow.SourceLineNumbers, (string)delayedField.Field.Data, this.VariableCache); | 42 | string value = WixVariableResolver.ResolveDelayedVariables(propertyRow.SourceLineNumbers, (string)delayedField.Field.Data, this.VariableCache); |
| 44 | 43 | ||
| 45 | // update the variable cache with the new value | 44 | // update the variable cache with the new value |
| 46 | string key = String.Concat("property.", BindDatabaseCommand.Demodularize(this.OutputType, this.ModularizationGuid, (string)propertyRow[0])); | 45 | string key = String.Concat("property.", Common.Demodularize(this.OutputType, this.ModularizationGuid, (string)propertyRow[0])); |
| 47 | this.VariableCache[key] = value; | 46 | this.VariableCache[key] = value; |
| 48 | 47 | ||
| 49 | // update the field data | 48 | // update the field data |
