Tag: .cs
All the articles with the tag ".cs".
Design Patterns: Memento
Published: at 12:18 PMThe Memento Design Pattern, a powerful tool for implementing undo/redo functionality and managing object states while adhering to software design principles like encapsulation and the Single Responsibility Principle.
Design Patterns: Bridge
Published: at 03:09 PMThe Bridge pattern decouples abstractions from their implementations, enabling flexible and scalable code structures. By favoring composition over inheritance, it helps manage complexity and reduce code duplication.
Design Patterns: Command
Published: at 02:06 PMThe Command design pattern encapsulates actions as objects, allowing for flexible execution, queuing, and undo/redo operations. It decouples command execution from application logic, enhancing modularity and maintainability in systems
SOLID: Dependency Inversion Principle
Published: at 03:20 PMThe Dependency Inversion Principle (DIP) promotes decoupling by ensuring high-level modules depend on abstractions, not low-level details. This leads to more flexible, maintainable, and testable code, often implemented through Dependency Injection.
SOLID: Interface Segregation Principle
Published: at 05:33 PMThe Interface Segregation Principle (ISP) advises that objects should only depend on the interfaces they actually use, promoting smaller, cohesive interfaces over large, cumbersome ones. By adhering to ISP, you reduce coupling, enhance code maintainability, and improve testability, ensuring that clients aren't burdened with unnecessary methods.
SOLID: Liskov Substitution Principle
Published: at 08:05 PMThe Liskov Substitution Principle (LSP) ensures subtypes can replace their base types without issues. Violations occur when subtypes change expected behavior, often signaled by type checks or unimplemented methods. To follow LSP, ensure subtypes fully support the base type's behavior.
SOLID: Open/Closed Principle
Published: at 03:49 PMThe Open/Closed Principle (OCP) states that software entities should be open for extension but closed for modification. This principle advocates designing systems so that new functionality can be added without altering existing code, which helps maintain stability and reduces the risk of introducing bugs.