-
Notifications
You must be signed in to change notification settings - Fork 265
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1889 from time-emit/master
- Loading branch information
Showing
5 changed files
with
51 additions
and
5 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
# 实验四:类建模 & 实验五: 高级类建模 | ||
|
||
## 一、实验目标 | ||
|
||
### 1. 掌握类建模方法; | ||
### 2. 了解MVC或你熟悉的设计模式; | ||
### 3. 掌握类图的画法。(Class Diagram) | ||
|
||
## 二、实验内容 | ||
|
||
### 1. 学习类建模 | ||
### 2. 根据用例规约找出类对象,并且对类建模; | ||
|
||
## 三、 实验步骤 | ||
|
||
### 1.学习了解类建模、MVC模式 | ||
### 2.根据MVC模式和用例规约,确定各层包含哪些类 | ||
### 3.确定类之间的关系 | ||
### 4.使用StarUML画出类图 | ||
|
||
## 四、实验结果 | ||
|
||
![浏览图库类图](./Lab4&5_ClassDiagram1.jpg) | ||
|
||
图1:浏览图库类图 | ||
|
||
![评论帖子类图](./Lab4&5_ClassDiagram2.jpg) | ||
|
||
图2:评论帖子类图 | ||
|
||
## 五、实验总结 | ||
### 1.MVC模式: | ||
- Model层:表示数据和业务规则 | ||
- View层:与用户交互的界面 | ||
- Controller层:负责Model和View层之间的通信 | ||
### 2.类 | ||
一般包含3个组成部分 | ||
- 类名 | ||
- 属性(attributes) | ||
- 方法 | ||
### 3.类的关系 | ||
- 依赖 | ||
- 关联 | ||
- 聚合 | ||
- 组合 | ||
- 继承 |