So I am reading Clean Code and I want to write my class names with the proper amount of context, but how does .NET namespaces play into the concept of Meaningful Names?
Do I forego context in the class name that has been provided in the namespace?
For example, If I have the following namespaces
MySolution.Event.Registration.BeginRequest
MySolution.Event.Registration.EndRequest
MySolution.Event.Registration.Error
Should I name the classes EventRegistrationBeginRequest, etc.?
MySolution.Event.Registration.BeginRequest
, or would users import that class name and writeBeginRequest
? In my experience, it's usually the latter – thus indicating that each class name should provide enough context in isolation.