Chapter 3
- We can organize classes in C# using namespaces, which provide a way to group related classes and avoid naming conflicts.
- A class should have a single responsibility, following the SRP from the SOLID principles.
- To comment code for document generators, use XML comments starting with /// to provide documentation for classes, methods, and parameters.
- Cohesion refers to how closely related the responsibilities of elements within a module (for example, a class) are. High cohesion means elements are closely related and focused on a single task.
- Coupling refers to the degree of dependency between modules or classes. Loose coupling means classes are less dependent on each other.
- Cohesion should be high, meaning that a class should have a single, well-defined responsibility.
- Coupling should be loose, indicating that classes should be as independent as possible.
- Mechanisms for designing for change include SOLID principles, DI, and design patterns such...