什么是软件工程中的可扩展设计?

What is extensible design in software engineering?

首先什么是可扩展设计?是软件架构还是软件中的设计方法?

Extensible design in software engineering is to accept that not everything can be designed in advance. A light software framework which allows for changes is provided instead. Small commands are made to prevent losing the element of extensibility, following the principle of separating work elements into comprehensible units, in order to avoid traditional software development issues including low cohesion and high coupling and allow for continued development. Embracing change is essential to the extensible design, in which additions will be continual. Each chunk of the system will be workable with any changes, and the idea of change through addition is the center of the whole system design. Extensible design supports frequent re-prioritization and allows functionality to be implemented in small steps upon request, which are the principles advocated by the Agile methodologies and iterative development. Extensibility imposes fewer and cleaner dependencies during development, as well as reduced coupling and more cohesive abstractions, plus well defined interfaces

以及这种方法的实现是否普遍?

这是一种设计方法。基本上,分解您的工作,以便人类和计算机都能理解它。例如,使用 OOP、有用的变量名、注释和 well-named 方法,而不是使用名为 x 和 y 的变量编写单一函数。它是现代软件工程的核心,允许其他人阅读和理解您的软件(包括六个月后的您自己)。

每个人都写过 non-extensible 软件,脚本,你写一次执行一次,并计划永远不再使用(并且通常希望没有人看到,因为它有点尴尬)。这不是软件工程,它可能在功能上是“正确的”,但缺乏可扩展性意味着它在下次需要更改时实际上毫无用处,并且可能必须重写。