当前位置:网站首页>结构化设计的概要与原理--模块化
结构化设计的概要与原理--模块化
2022-07-28 15:58:00 【从一而终】

技术一般 不会贴图 原谅!!!
怎样做好软件开发过程中的模块化是一个值得思考的问题。
在思考这个问题之前,我曾做了当前工作中的项目代码部分重构,我自己给自己定的重构原则是,按照职责单一来划分模块。在函数拆分中将功能能构独立出来的代码行拆分成一个函数封装成一个接口。
在没有见到上图之前,我没有觉得自己哪里不对,但是上图引发了我的一个思考,我的拆分原则有没有问题,按照书面知识看似毫无破绽,面向对象的设计原则其中一条讲的就是单一职责原则。但是事务总是在带来好处的地方也带来负面效应,过度的拆分导致模块调用的过程中接口增多。接口成本也随之增加。这是一个问题,那么我们到底该如何进行模块拆分。
又是一些没有营养的建议,我恶心下自己:
1 拆分原则,还是按照书本上的知识--单一职责原则。
2 具体实施,根据业务场景进行功能的划分与合并,然后进行拆分。
3 一些业务无关的工具模块拆分越细越好,这些东西积累起来就是财富,越细越容易被重复使用。
。。。后续想到补充
边栏推荐
- 优化Hypermesh脚本性能的几点建议
- How to set ticdc synchronization data to only synchronize the specified library?
- [pointer internal skill cultivation] character pointer + pointer array + array pointer + pointer parameter (I)
- 【指针内功修炼】字符指针 + 指针数组 + 数组指针 + 指针参数(一)
- Some suggestions on optimizing HyperMesh script performance
- 排序1-插入排序与希尔排序
- 有趣的 Kotlin 0x0A:Fun with composition
- 配置web服务器步骤详细记录(多有借鉴)
- 有趣的 Kotlin 0x07:Composition
- 遭MQ连连干翻后的醒悟!含恨码出这份MQ手册助力秋招之旅
猜你喜欢

HyperMesh auto save (enhanced) plug-in instructions

Wake up after being repeatedly upset by MQ! Hate code out this MQ manual to help the journey of autumn recruitment

Leetcode daily practice - 160. Cross linked list

一小时内学会Abaqus脚本编程秘籍

LeetCode每日一练 —— 160. 相交链表

QT packaging

Configure HyperMesh secondary development environment on vs Code

Abaqus GUI界面解决中文乱码问题(插件中文乱码也适用)

栈的介绍与实现(详解)

Sort 3-select sort and merge sort (recursive implementation + non recursive implementation)
随机推荐
栈的介绍与实现(详解)
Pop up layer prompt in the background
Signal shielding and processing
asp.net大文件分块上传断点续传demo
Implementation of transfer business
Li Hongyi, machine learning 5. Tips for neural network design
nowcode-学会删除链表中重复元素两题(详解)
ANSYS二次开发 - MFC界面调用ADPL文件
HDU1847解题思路
排序2-冒泡排序与快速排序(递归加非递归讲解)
Leetcode daily practice - the number of digits in the offer 56 array of the sword finger
微软100题-天天做-第11题
Text filtering skills
egg(十九):使用egg-redis性能优化,缓存数据提升响应效率
Tcp/ip related
Early in the morning, pay Bora SMS to say that you won the "prize"? Dealing with server mining virus - kthreaddi
在abaqus中使用PyQt设计GUI
TCP handshake, waving, time wait connection reset and other records
Introduction and implementation of queue (detailed explanation)
2021-04-02