@@ -26,8 +26,7 @@ internal class VariableDetails : VariableDetailsBase
26
26
/// Provides a constant for the dollar sign variable prefix string.
27
27
/// </summary>
28
28
public const string DollarPrefix = "$" ;
29
-
30
- protected object valueObject ;
29
+ protected object ValueObject { get ; }
31
30
private VariableDetails [ ] cachedChildren ;
32
31
33
32
#endregion
@@ -81,7 +80,7 @@ public VariableDetails(PSPropertyInfo psProperty)
81
80
/// <param name="value">The variable's value.</param>
82
81
public VariableDetails ( string name , object value )
83
82
{
84
- this . valueObject = value ;
83
+ this . ValueObject = value ;
85
84
86
85
this . Id = - 1 ; // Not been assigned a variable reference id yet
87
86
this . Name = name ;
@@ -109,7 +108,7 @@ public override VariableDetailsBase[] GetChildren(ILogger logger)
109
108
{
110
109
if ( this . cachedChildren == null )
111
110
{
112
- this . cachedChildren = GetChildren ( this . valueObject , logger ) ;
111
+ this . cachedChildren = GetChildren ( this . ValueObject , logger ) ;
113
112
}
114
113
115
114
return this . cachedChildren ;
@@ -175,13 +174,13 @@ private static string GetValueStringAndType(object value, bool isExpandable, out
175
174
if ( value is bool )
176
175
{
177
176
// Set to identifier recognized by PowerShell to make setVariable from the debug UI more natural.
178
- valueString = ( bool ) value ? "$true" : "$false" ;
177
+ valueString = ( bool ) value ? "$true" : "$false" ;
179
178
180
179
// We need to use this "magic value" to highlight in vscode properly
181
180
// These "magic values" are analagous to TypeScript and are visible in VSCode here:
182
181
// https://github.com/microsoft/vscode/blob/57ca9b99d5b6a59f2d2e0f082ae186559f45f1d8/src/vs/workbench/contrib/debug/browser/baseDebugView.ts#L68-L78
183
- // NOTE: we don't do numbers and strings since they (so far) seem to get detected properly by
184
- //serialization, and the original .NET type can be preserved so it shows up in the variable name
182
+ // NOTE: we don't do numbers and strings since they (so far) seem to get detected properly by
183
+ //serialization, and the original .NET type can be preserved so it shows up in the variable name
185
184
//type hover as the original .NET type.
186
185
typeName = "boolean" ;
187
186
}
@@ -452,7 +451,7 @@ public VariableDetailsRawView(object value) : base(RawViewName, value)
452
451
public override VariableDetailsBase [ ] GetChildren ( ILogger logger )
453
452
{
454
453
List < VariableDetails > childVariables = new ( ) ;
455
- AddDotNetProperties ( valueObject , childVariables , noRawView : true ) ;
454
+ AddDotNetProperties ( ValueObject , childVariables , noRawView : true ) ;
456
455
return childVariables . ToArray ( ) ;
457
456
}
458
457
}
0 commit comments