0
Multiple Classes per File
In C#, is it common to have multiple classes in one file? Generally there would only be one class per file, right? Also, can the classes be called "public class" instead of just "class" (or "static class", that is)?
2 Respuestas
0
for organization most people keep to a one file per class style. the default access modifier is internal which hides its members and methods from other classes outside its namespace. You can have many access modifiers such as
protected
internal
protected internal
and private
0
in c# if no access specifier is procided it is implicitly internal, which restricts members of that type from being seen in other classes.