Posts

Showing posts from September, 2024

Design Patterns

Image
 Design Patterns - JAVA🔧👽 In software engineering, a design pattern is a repeatable solution to a common problem in software design. A design pattern is not a ready-made design that can be converted directly into code. It is a description or template of how to solve a problem that can be used in different situations. Why we use design patterns ?  Improved Code Quality and Readability Increased Reusability and Efficiency Better Maintainability and Extensibility Improved Collaboration and Communication Mitigates Risks Reduces errors Enhances reliability We can break these design patterns in terms of those categories. First criteria is Purpose and other one is . First we discuss the types of design patterns using Purpose criteria. 1) Purpose           What is the purpose any design pattern solves. There are 3 purposes that any design patterns would be solving. Creational Design Pattern : Used for creating or instantiating objects and classes. Struc...

Behavioral Design Pattern - Software Engineering

Image
 Behavioral Design Pattern - Software Engineering  👽 In the industry we have to use Design Patterns to develop systems. There are 3 types of design patterns. Creational Design Pattern - helps instantiate objects Structural Design Pattern - helps organize relationships between objects Behavioral Design Pattern - helps solve communication problems between objects In here we will discuss about Behavioral Design Pattern. Behavioral Design Patterns  Behavioral patterns focus on the interactions between cooperating objects. Behavioral design patterns are concerned with the interaction and responsibility of objects. Behavioral patterns only concern about the communication between the objects. The interaction between the object should be in such a way that they can talk to each other easily and should be loosely coupled. That means the implementation and the client should be loosely coupled avoid any hard coding or dependencies. The interaction between the cooperating objec...