diff options
| author | Rob Mensching <rob@firegiant.com> | 2019-05-23 22:34:11 -0700 |
|---|---|---|
| committer | Rob Mensching <rob@firegiant.com> | 2019-05-24 15:18:30 -0700 |
| commit | 9d0fea2e7617e4ba4fc85fbe412c812d9bc65564 (patch) | |
| tree | 58ba680dbcc1d67e21e85397bbb063d2f4daf54c /src | |
| parent | c22120fa0311033b06e2cbc78190fc9066e86e42 (diff) | |
| download | wix-9d0fea2e7617e4ba4fc85fbe412c812d9bc65564.tar.gz wix-9d0fea2e7617e4ba4fc85fbe412c812d9bc65564.tar.bz2 wix-9d0fea2e7617e4ba4fc85fbe412c812d9bc65564.zip | |
Improve debuggability of tuples
Diffstat (limited to 'src')
| -rw-r--r-- | src/WixToolset.Data/IntermediateTuple.cs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/WixToolset.Data/IntermediateTuple.cs b/src/WixToolset.Data/IntermediateTuple.cs index e5df9ecb..09ff7692 100644 --- a/src/WixToolset.Data/IntermediateTuple.cs +++ b/src/WixToolset.Data/IntermediateTuple.cs | |||
| @@ -1,10 +1,12 @@ | |||
| 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.Data | 3 | namespace WixToolset.Data |
| 4 | { | 4 | { |
| 5 | using System; | 5 | using System; |
| 6 | using System.Diagnostics; | ||
| 6 | using SimpleJson; | 7 | using SimpleJson; |
| 7 | 8 | ||
| 9 | [DebuggerDisplay("{DebuggerDisplay,nq}")] | ||
| 8 | public class IntermediateTuple | 10 | public class IntermediateTuple |
| 9 | { | 11 | { |
| 10 | public IntermediateTuple(IntermediateTupleDefinition definition) : this(definition, null, null) | 12 | public IntermediateTuple(IntermediateTupleDefinition definition) : this(definition, null, null) |
| @@ -29,6 +31,8 @@ namespace WixToolset.Data | |||
| 29 | 31 | ||
| 30 | public IntermediateField this[int index] => this.Fields[index]; | 32 | public IntermediateField this[int index] => this.Fields[index]; |
| 31 | 33 | ||
| 34 | private string DebuggerDisplay => $"{this.Definition?.Name} {this.Id?.Id}"; | ||
| 35 | |||
| 32 | internal static IntermediateTuple Deserialize(ITupleDefinitionCreator creator, Uri baseUri, JsonObject jsonObject) | 36 | internal static IntermediateTuple Deserialize(ITupleDefinitionCreator creator, Uri baseUri, JsonObject jsonObject) |
| 33 | { | 37 | { |
| 34 | var definitionName = jsonObject.GetValueOrDefault<string>("type"); | 38 | var definitionName = jsonObject.GetValueOrDefault<string>("type"); |
