当前位置:网站首页>Solid principle
Solid principle
2022-07-06 17:38:00 【Wzzzzzzx】
In terms of software architecture design , There is a general principle that cannot be bypassed , That's it SOLID principle
. The general principle consists of the initials of five principles , They are as follows :
- Principle of single responsibility (The Single Responsibility Prinlciple): Any software module should only be responsible for a certain kind of behavior
- Opening and closing principle (The Open/Closed Principle): Well designed software should be easy to extend , At the same time, it resists modification
- Richter's principle of substitution (The Liskov Substitution Principle): If you want to build software with replaceable components , Then these components should follow the same interface , So that they can freely replace each other
- Interface isolation principle (The Interface Segregation Principle): Unnecessary dependencies should be avoided in design
- Dependency Inversion Principle (The Dependency Inversion Principle): Depend on abstraction rather than concrete
Build a good software system , We should not only focus on the implementation level of the code , Pay more attention to the design of the overall architecture . A good architecture design can avoid most of the bug
, Cope with endless modifications and functional overlays . How to measure the quality of an architecture ? An important criterion is its maintainability . As a small change, you need to change a lot of code , When you ask some unexpected questions , Such architecture design must be bad . Secondly, readability . The code is to be read , Chaotic architecture will complicate the logic of the code , Increase the difficulty of understanding .
In order to design a good architecture ,SOLID principle
Through a series of principles to guide us How to correctly organize functions and data into components , And how to summarize these components into the final software .
边栏推荐
- Pyspark operator processing spatial data full parsing (5): how to use spatial operation interface in pyspark
- 自动化运维利器-Ansible-Playbook
- C# NanoFramework 点灯和按键 之 ESP32
- 自动化运维利器ansible基础
- Kali2021 installation and basic configuration
- [reverse] repair IAT and close ASLR after shelling
- CentOS7上Redis安装
- The problem of "syntax error" when uipath executes insert statement is solved
- 02个人研发的产品及推广-短信平台
- 03 products and promotion developed by individuals - plan service configurator v3.0
猜你喜欢
04 products and promotion developed by individuals - data push tool
Integrated development management platform
【MySQL入门】第三话 · MySQL中常见的数据类型
02个人研发的产品及推广-短信平台
Flink analysis (II): analysis of backpressure mechanism
信息与网络安全期末复习(基于老师给的重点)
当前系统缺少NTFS格式转换器(convert.exe)
02 personal developed products and promotion - SMS platform
Case: check the empty field [annotation + reflection + custom exception]
JVM garbage collector part 2
随机推荐
06 products and promotion developed by individuals - code statistical tools
Re signal writeup
[reverse primary] Unique
轻量级计划服务工具研发与实践
TCP连接不止用TCP协议沟通
Akamai浅谈风控原理与解决方案
【逆向初级】独树一帜
Learn the wisdom of investment Masters
1. Introduction to JVM
Garbage first of JVM garbage collector
华为认证云计算HICA
C WinForm series button easy to use
Vscode replaces commas, or specific characters with newlines
[elastic] elastic lacks xpack and cannot create template unknown setting index lifecycle. name index. lifecycle. rollover_ alias
04个人研发的产品及推广-数据推送工具
PySpark算子处理空间数据全解析(4): 先说说空间运算
Uipath browser performs actions in the new tab
[reverse intermediate] eager to try
List集合数据移除(List.subList.clear)
February database ranking: how long can Oracle remain the first?