I have the following code:
public class PersonInitializer
{
private Person _person;
public static Person LoadFromFile(string path)
{
Per
From the documentation:
Private members are accessible only within the body of the class or the struct in which they are declared.
Since LoadFromFile
is within the body of the class where _person
is declared, it has access to it. There's nothing you can do about that, since
Private access is the least permissive access level.