Skip to content

Commit

Permalink
Merge pull request #1884 from clidclid/master
Browse files Browse the repository at this point in the history
#4 #5 #1238 实验四、五
  • Loading branch information
zengsn authored Mar 28, 2020
2 parents b3783ad + 36cd43b commit 143090d
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 0 deletions.
Binary file added students/1714080902326/ClassDiagram1.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added students/1714080902326/ClassDiagram2.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
37 changes: 37 additions & 0 deletions students/1714080902326/lab4&5.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# 实验四:类建模 & 实验五:高级类建模

## 一、实验目标

1. 掌握类建模方法;
2. 了解MVC或你熟悉的设计模式;
3. 掌握类图的画法;
4. 理解类的5种关系;
5. 掌握类之间关系的画法。

## 二、实验内容

1. 基于MVC模式设计类;
2. 设计类的关系;
3. 画出类图。

## 三、实验步骤

1. 根据MVC模式和用例规约,先找数据,再找视图,最后找控制器,确定各层包含哪些类
2. 在StarUML中制作类图

## 四、实验结果

![ClassDiagram1](./ClassDiagram1.jpg)

图1:聊天类图

![ClassDiagram2](./ClassDiagram2.jpg)

图2:转账类图


## 五、实验总结

1. 有多少个用例,就有多少个类图
2. 建立类关系,越弱越好,其好处是低耦合,方便维护
3. 数据层和视图层不能通信,用例规约涉及到系统的就是控制器

0 comments on commit 143090d

Please sign in to comment.