Starting point to learn Java Design Pattern.
SOLID Principles in Java Application Development
SOLID refers to five design principles in object-oriented programming, designed to reduce code rot and improve software’s value, function, and maintainability. Here, we give an overview of each SOLID principle along with an example of each.
What Are SOLID Design Principles?
SOLID principles are class-level, object-oriented design concepts that, in conjunction with an extensive test suite, help you avoid code rot.
SOLID design is an acronym for the following five principles:
1. Single Responsibility Principle
2. Open-Closed Principle
3. Liskov Substitution Principle
4. Interface Segregation Principle
5. Dependency Inversion Principle
These principles provide a valuable standard for guiding developers away from such “code rot” and instead towards building applications that provide lasting value for customers and sanity for future developers working on your project.
1. Single Responsibility Principle (SRP)
The Single Responsibility Principle (SRP) states that there should never be more than one reason for a class to change. This means that every class, or similar structure, should have only one job to do in your code.
2. Open-Closed Principle (OCP)
The Open-Closed Principle (OCP) states that classes should be open for extension but closed for modification. “Open to extension” means that you should design your classes so that new functionality can be added as new requirements are generated. “Closed for modification” means that once you have developed a class, you should never modify it, except to correct bugs.
3. Liskov Substitution Principles (LSP)
The Liskov Substitution Principle (LSP) applies to inheritance hierarchies, specifying that you should design your classes so that client dependencies can be substituted with subclasses without the client knowing about the change.
4. Interface Segregation Principle (ISP)
The Interface Segregation Principle (ISP) states that clients should not be forced to depend upon interface members they do not use. When we have non-cohesive interfaces, the ISP guides us to create multiple, smaller, cohesive interfaces.
5. Dependency Inversion Principle (DIP)
The Dependency Inversion Principle (DIP) states that high-level modules should not depend upon low-level modules; they should depend on abstractions.
Who this course is for:
- People who want to learn advanced concepts in Java
What you’ll learn
Its a Starting point for Design Pattern
[maxbutton id=”4″ text=”Enroll Now!” url=”https://www.udemy.com/course/soliddesignprinciple/?couponCode=5F78299AA3D59ED641FF”]
you need to have basic knowledge of Java
- Realme GT Master Explorer vs Vivo iQOO 7 View Comparison →
- Xiaomi Mi Pad 5 Pro vs Apple iPad Pro 11 (2021) View Comparison →
- Tecno Pova 2 vs Xiaomi Redmi 9 Power View Comparison →
- Tecno Pova 2 vs Tecno Phantom X View Comparison →
- OnePlus Nord 2 5G vs OnePlus Nord CE 5G vs OnePlus Nord View Comparison →
- Huawei P50 vs Huawei P50 Pro 4G View Comparison →