Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 8e3f3c3

Browse files
ReadMe opt
1 parent 9ad99b1 commit 8e3f3c3

File tree

1 file changed

+16
-6
lines changed

1 file changed

+16
-6
lines changed

‎README.md‎

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,18 +13,28 @@
1313
![逻辑结构](http://upload-images.jianshu.io/upload_images/7802425-5d6b679ecdac9f47.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)
1414

1515
### 代码结构图
16-
![结构图](http://upload-images.jianshu.io/upload_images/7802425-d0344f416ed446ad.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)
16+
![结构图](http://upload-images.jianshu.io/upload_images/7802425-677a863b9d4690d0.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)
1717

18-
责任链模式
18+
# 责任链模式
19+
* 抽象处理者(Handler)角色:定义出一个处理请求的接口。如果需要,接口可以定义 出一个方法以设定和返回对下家的引用。这个角色通常由一个Java抽象类或者Java接口实现。上图中Handler类的聚合关系给出了具体子类对下家的引用,抽象方法handleRequest()规范了子类处理请求的操作。
20+
* 具体处理者(BossHandler)角色:具体处理者接到请求后,可以选择将请求处理掉,或者将请求传给下家。由于具体处理者持有对下家的引用,因此,如果需要,具体处理者可以访问下家。
1921

20-
命令模式
2122

23+
# 命令模式
24+
*
25+
*
2226

23-
观察者模式
27+
# 观察者模式
28+
*
29+
*
2430

25-
状态模式
31+
# 状态模式
32+
*
33+
*
2634

27-
访问者模式
35+
# 访问者模式
36+
*
37+
*
2838

2939

3040
### FAQ

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /