有人能解释一下软件设计和软件架构的区别吗?

更具体地说;如果你让别人给你展示“设计”——你希望他们展示什么?“建筑”也是如此。

我目前的理解是:

设计:系统特定模块/部分的UML图/流程图/简单线框(用于UI) 架构:组件图(显示系统的不同模块如何相互通信以及如何与其他系统通信),要使用什么语言,模式……?

如果我说错了,请指正。我提到了维基百科在http://en.wikipedia.org/wiki/Software_design和http://en.wikipedia.org/wiki/Software_architecture上有文章,但我不确定我是否理解正确。


当前回答

Good question... Although the line between them is hardly a bright sharp line, imho, if you are using both terms, then Architecture encompasses more technical or structural decisions about how to build or construct something, especially those decisions that will be hard (or harder) to change once implemeneted, whereas Design encompasses those decisions that either are easy to change later (like method names, class <-> file organizational structure, design patterns, whether to use a singleton or a static class to solve some specific problem, etc. ) and/or those that effect the appearance or esthetic aspects of a system or application (Human Interface, ease of use, look and feel, etc.)

其他回答

体系结构是用于构建系统的设计模式的最终集合。

我猜设计是用来把所有这些放在一起的创造力?

Good question... Although the line between them is hardly a bright sharp line, imho, if you are using both terms, then Architecture encompasses more technical or structural decisions about how to build or construct something, especially those decisions that will be hard (or harder) to change once implemeneted, whereas Design encompasses those decisions that either are easy to change later (like method names, class <-> file organizational structure, design patterns, whether to use a singleton or a static class to solve some specific problem, etc. ) and/or those that effect the appearance or esthetic aspects of a system or application (Human Interface, ease of use, look and feel, etc.)

体系结构更像是集成系统的各种功能,以实现系统的一个整体目标,而设计则解决每个功能需求。

例如,以MVVM为例,这是一种体系结构模式。对于通知功能,MVVM使用观察者模式,这又是一种设计模式,

以下是可能更详细地解释体系结构的参考资料和软件体系结构的UML图列表。(我找不到用于软件设计的UML图列表)

Grady Booch

在架构模型中使用UML 2图

UML图的分类

UML图的分类

即使在发布了这个答案之后,我自己也不清楚哪个图是用于架构的,哪个图是用于设计的:)。Grady Booch在他的第58张幻灯片中指出,类、接口和协作是设计视图的一部分,而这个设计视图是架构视图的一部分!!

体系结构是指计算机或基于计算机的系统的概念结构和逻辑组织。 设计是指在一个系统或物体被制造出来之前,为显示其外观、功能或工作方式而设计的计划或图纸。 如果您正在“架构”一个组件,那么您正在定义它在更大的系统中的行为。 如果你在“设计”同一个组件,你就是在定义它的内部行为。

所有的建筑都是设计,但并非所有的设计都是建筑。

什么部分是设计,如何具体实现,以及什么和如何是架构的交集。

区分建筑和设计的形象:

还有一些设计决策,在架构上并不重要,也就是说不属于设计的架构分支。例如,某些组件的内部设计决策,如算法的选择,数据结构的选择等。

任何在组件边界之外不可见的设计决策都是组件的内部设计,并且是非架构性的。这些是系统架构师留给模块设计人员或实现团队的设计决策,只要他们的设计不打破系统级架构施加的架构限制。

这个链接提供了一个很好的类比