Well,before referring something i can say you about my thoughts about those terms.
Literally these terms are called Access Modifiers
.When you declare something public
, the class (and consequently the object) is making a strong statement: this is my visible interface, there are many other like this but this is mine. The public interface is a contractual agreement that your class is exporting to the rest of the world (whatever that means) about what it can do. If you modify the public interface, you risk to break the contract that the rest of the world is assuming about the class.
On the other hand, private
stuff is internal to the class. It is support functionality that the class must use in order to do its job, while carrying the object state around (if it's a method) or keeping its internal state (if it's a variable). You are free to hack and tinker the class private stuff as much as you want, without breaking the interface contract, meaning that this gives you wide freedom for refactoring (of the internal data representation, for example, for efficiency). private stuff is not part of the interface.
is something that involves the openness to reimplementation. Avoid, if you can, deeply nested inheritances. You risk to make things very difficult to handle, as the base class can be screwed by your reimplementation class.
Behind this,check some really good answers from CP that i like to refer here:
access modifiers in c#
And,you can check also Accessibility Levels from it: