Skip to content

Commit f27effb

Browse files
authored
Fix namespace spacing and indentation for classes
1 parent ed77b75 commit f27effb

File tree

1 file changed

+26
-21
lines changed
  • docs/csharp/programming-guide/classes-and-structs/snippets/properties

1 file changed

+26
-21
lines changed

docs/csharp/programming-guide/classes-and-structs/snippets/properties/Person.cs

Lines changed: 26 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ public class Person
5151
}
5252
// </Initializer>
5353
}
54+
5455
namespace VersionFour
5556
{
5657
// <AccessorModifiers>
@@ -76,6 +77,7 @@ public class Person
7677
}
7778
// </Readonly>
7879
}
80+
7981
namespace VersionSix
8082
{
8183
// <InitOnly>
@@ -90,6 +92,7 @@ public Person() { }
9092
}
9193
// </InitOnly>
9294
}
95+
9396
namespace VersionSeven
9497
{
9598
// <Required>
@@ -130,6 +133,7 @@ public Person(string firstName, string lastName)
130133
}
131134
// </ExpressionBodiedProperty>
132135
}
136+
133137
namespace VersionNine
134138
{
135139
// <CachedBackingStore>
@@ -160,6 +164,7 @@ public string FullName
160164
}
161165
// </CachedBackingStore>
162166
}
167+
163168
namespace VersionTen
164169
{
165170
// <UseBackingFields>
@@ -206,29 +211,29 @@ namespace properties
206211

207212
// <UsingEmployeeExample>
208213
class Employee
209-
{
210-
private string _name; // the name field
211-
public string Name => _name; // the Name property
212-
}
213-
// </UsingEmployeeExample>
214+
{
215+
private string _name; // the name field
216+
public string Name => _name; // the Name property
217+
}
218+
// </UsingEmployeeExample>
214219

215-
// <ManageExample>
216-
class Manager
217-
{
218-
private string _name;
219-
public string Name => _name != null ? _name : "NA";
220-
}
221-
// </ManageExample>
220+
// <ManageExample>
221+
class Manager
222+
{
223+
private string _name;
224+
public string Name => _name != null ? _name : "NA";
225+
}
226+
// </ManageExample>
222227

223-
//<StudentExample>
224-
class Student
225-
{
226-
private string _name; // the name field
227-
public string Name // the Name property
228+
//<StudentExample>
229+
class Student
228230
{
229-
get => _name;
230-
set => _name = value;
231+
private string _name; // the name field
232+
public string Name // the Name property
233+
{
234+
get => _name;
235+
set => _name = value;
236+
}
231237
}
232-
}
233-
//</StudentExample>
238+
//</StudentExample>
234239
}

0 commit comments

Comments
 (0)