Encapsulation C# newbie
New to C#, and I understand that encapsulation is just a way of "protecting data". But I am still unclear. I thought that the point of get and set accessors were to add tests within those methods to check to see if parameters meet certain criteria, before allowing an external function to get and set anything, like this: private string myName; public string MyName;// this is a property, speical to c#, which sets the backing field. private string myName = "mary";// the backing field. public string MyName // this is a property, which sets/gets the backing field. { get { return myName; } set { if