在好例子网,分享、交流、成长!
您当前所在位置:首页Java 开发实例企业应用开发/EJB → Hands-On Design Patterns with Java.pdf

Hands-On Design Patterns with Java.pdf

企业应用开发/EJB

下载此实例
  • 开发语言:Java
  • 实例大小:10.95M
  • 下载次数:17
  • 浏览次数:109
  • 发布时间:2020-06-18
  • 实例类别:企业应用开发/EJB
  • 发 布 人:cloud_1988
  • 文件格式:.pdf
  • 所需积分:2
 相关标签: Design Patterns java

实例介绍

【实例简介】java设计模式书籍

【实例截图】

【核心代码】

Table of Contents
Preface 1
Section 1: Section 1: Introducing Design Patterns
Chapter 1: Unified Modeling Language Primer 7
Technical requirements 7
Introducing UML 8
Understanding behavioral UML diagrams 8
Activity diagrams 9
Interaction diagrams 10
Sequence diagrams 11
Communication diagrams 12
Timing diagrams 12
State machine diagrams 13
Use case diagrams 14
Understanding structural UML diagrams 15
Class diagrams 16
Component diagrams 17
Composite structure diagrams 17
Deployment diagrams 18
Object diagrams 19
Package diagrams 20
Summary 20
Questions 21
Further reading 21
Chapter 2: Object-Oriented Design Patterns 22
Technical requirements 22
Introduction to object-oriented programming 23
Primary benefits of OOP 23
Portability 23
Inheritance 24
Encapsulation 25
Polymorphism 25
Sample OOP class 27
Instance variables 29
The this reference 29
Object-oriented programming approaches 29
Accessors and mutators 30
Driver class 31
Constructors 31
Table of Contents
[ ii ]
Overloading constructors and methods 32
Method call chaining 35
Principles of design patterns 37
Creating concise objects 37
Encapsulating to protect 37
Being purposeful with inheritance 38
Learning the complete OOP class 41
Summary 48
Questions 48
Further reading 48
Section 2: Section 2: Original Design Patterns
Chapter 3: Behavioral Design Patterns 50
Technical requirements 51
Introducing behavioral design patterns 51
Understanding the chain of responsibility pattern 52
Use case 53
UML class diagram 54
Programming the design pattern 54
University email handler interface 55
Main email handler 55
Academic email handler 57
Alumni email handler 58
Advising email handler 58
Finance email handler 59
HR email handler 59
Admin email handler 60
Exploring the command pattern 61
Use case 61
UML class diagram 62
Programming the design pattern 62
Class variables 63
Constructor 63
Accessor methods 63
Power-related methods 64
Slider-related methods 64
Using the interpreter pattern 65
Use case 65
UML class diagram 66
Programming the design pattern 66
The Expression interface 67
The MapIntToCharacters class 67
The Conversion class 68
InterpreterDriver class 69
Using the iterator pattern 71
Use case 71
Table of Contents
[ iii ]
UML class diagram 72
Programming the design pattern 72
Understanding the mediator pattern 74
Use case 74
UML class diagram 75
Programming the design pattern 76
Starter 76
AssemblySystem 77
Hopper 78
The SystemAccelerator class 79
EmergencyBreak 80
WidgetProductionSystem 82
Examining the memento pattern 85
Use case 85
UML class diagram 86
Programming the design pattern 86
Using the null object pattern 88
Use case 88
UML class diagram 89
Programming the design pattern 89
Observing the observer pattern 91
Use case 91
UML class diagram 91
Programming the design pattern 92
Understanding the state pattern 93
Use case 93
UML class diagram 93
Programming the design pattern 94
PrinterOnLine 94
PrinterOffLine 95
Printer 95
PrinterController 96
Driver 96
Application output 97
Strategizing with the strategy pattern 97
UML class diagram 97
Understanding the template method pattern 98
Understanding the visitor pattern 98
Summary 99
Questions 99
Further reading 100
Chapter 4: Creational Design Patterns 101
Technical requirements 101
Introducing creational design patterns 102
Understanding the abstract factory design pattern 102
Table of Contents
[ iv ]
Use case 104
UML class diagram 104
Programming the design pattern 106
Interfaces 106
Abstract Factory class 107
TypeA classes 107
TypeB classes 108
Type-C classes 110
Driver class 111
Building with the builder design pattern 113
Use case 113
UML class diagram 114
Programming the design pattern 114
Roaster class 115
Interface 115
Builder classes 116
Director class 119
Driver class 119
Exploring the factory method design pattern 121
Use case 121
UML class diagram 121
Programming the design pattern 122
Using the prototype design pattern 124
Use case 125
UML class diagram 125
Programming the design pattern 126
Examining the simple factory design pattern 129
Use case 130
UML class diagram 130
Programming the design pattern 131
Implementing the singleton design pattern 133
Use case 133
UML class diagram 133
Programming the design pattern 134
Summary 135
Questions 135
Further reading 136
Chapter 5: Structural Design Patterns 137
Technical requirements 137
Introduction to structural design patterns 138
Understanding the adapter design pattern 138
Use case 139
UML class diagram 139
Programming the design pattern 140
Crossing the bridge design pattern 142
Table of Contents
[ v ]
Learning about abstraction 142
Implementing the abstraction example 143
Use case 146
UML class diagram 146
Programming the design pattern 147
Combining objects with the composite design pattern 151
Use case 151
UML class diagram 151
Programming the design pattern 152
Understanding the decorator design pattern 156
Use case 157
UML class diagram 157
Programming the design pattern 158
Implementing the facade design pattern 160
Use case 161
UML class diagram 162
Programming the design pattern 162
Soaring with the flyweight design pattern 166
Use case 166
UML class diagram 166
Programming the design pattern 167
Implementing the proxy design pattern 170
Use case 171
UML class diagram 171
Programming the design pattern 172
Summary 174
Questions 174
Further reading 175
Section 3: Section 3: New Design Patterns
Chapter 6: Architectural Patterns - Part I 177
Introducing architectural patterns 178
Understanding the blackboard pattern 178
Coffee shop automation example 178
Warehouse security bot example 181
Understanding the broker pattern 182
University enterprise information system example 183
Luxury cruise reservation system example 184
Understanding the client-server pattern 185
Coffee shop example 185
Three-tier example 186
Understanding the event-driven pattern 187
Event-driven architectural pattern – broker 187
Event-driven architectural pattern – mediator 188
Table of Contents
[ vi ]
Understanding the extract-transform-load pattern 189
Extract 190
Transform 190
Load 191
Understanding the layered pattern 192
Traditional operating system layers example 194
Mobile operating system layers example 194
Business application layers example 195
Understanding the master–slave pattern 196
Single client example 198
Cloud storage example 199
Understanding the microkernel pattern 200
Construction quote example 201
Optical disc player example 202
Summary 203
Questions 203
Further reading 204
Chapter 7: Architectural Patterns - Part II 205
Technical requirements 205
Understanding the microservices pattern 206
Logistics example 207
eCommerce example implementation 208
Understanding the model-view-controller pattern 209
Book model-view-controller example implementation 210
Book class 210
BookView class 211
The BookController class 211
The MVCArchitecturalPattern class 213
Understanding the naked object pattern 214
Understanding the peer-to-peer pattern 215
File sharing example implementation 216
Networking example implementation 217
Understanding the pipe-filter pattern 218
Simple transformation example implementation 219
Complex transformation example implementation 220
Understanding the serverless pattern 221
IaaS implementation 222
PaaS implementation 223
SaaS implementation 223
BaaS implementation 224
MBaaS implementation 224
FaaS implementation 225
Understanding the service-oriented pattern 225
Understanding the space-based pattern 227
Table of Contents
[ vii ]
Summary 228
Questions 229
Further reading 229
Chapter 8: Functional Design Patterns 230
Technical requirements 230
Introducing functional design patterns 231
Understanding the execute around design pattern 232
Demonstrated implementation 232
Understanding the lambda design pattern 233
Accessing variables 234
Implementing lambda with a single parameter 234
Implementing lambda with multiple parameters 236
Understanding the loan design pattern 239
Implementing file processing 239
Understanding the MapReduce design pattern 243
Input-Map-Output 244
Input 244
Map 245
Output 245
Input-Map-Reduce-Output 245
Input 246
Map 247
Reduce 247
Output 247
Input-Multiple Maps-Reduce-Output 248
Input 248
Multiple maps 249
Input-Map-Combiner-Reduce-Output 249
Understanding the memoization design pattern 250
Understanding the streams design pattern 254
Stream intermediate operations 255
Stream terminal operations 256
Programming the streams design pattern 256
Understanding the tail call design pattern 257
Programming the tail call design pattern 257
Summary 260
Questions 261
Further reading 261
Chapter 9: Reactive Design Patterns 262
Technical requirements 263
Introducing reactive design patterns 263
Responsive 264
Resilient 264
Elastic 264
Table of Contents
[ viii ]
Message-driven 265
Understanding the asynchronous communication design pattern 266
Implementing the asynchronous communication design pattern 267
Understanding the autoscaling design pattern 272
Horizontal scaling 274
Vertical scaling 275
Implementing autoscaling 275
Understanding the bounded queue design pattern 275
Understanding the bulkhead design pattern 278
Understanding the caching design pattern 280
Implementing the caching design pattern in Java 281
Understanding the circuit-breaker design pattern 285
Use case 286
Understanding the event-driven communication design pattern 286
Understanding the fail-fast design pattern 287
Programming the design pattern 287
Introducing a fail event 289
Understanding the failure-handling design pattern 291
Failure isolation 291
Controlled failure 292
Understanding the fan-out and quickest-reply design pattern 294
Understanding the idempotency design pattern 295
Programming the design pattern 296
Understanding the monitoring design pattern 299
Understanding the publisher-subscriber design pattern 300
Understanding the self-containment design pattern 301
Understanding the stateless design pattern 302
Use case 303
UML class diagram 303
Programming the design pattern 304
Summary 316
Questions 316
Further reading 317
Appendix A: Assessments 318
Chapter 1 318
Chapter 2 318
Chapter 3 319
Chapter 4 319
Chapter 5 320
Chapter 6 320
Chapter 7 321
Chapter 8 321
Chapter 9 322
Table of Contents
[ ix ]
Other Books You May Enjoy 323
Index 326

标签: Design Patterns java

实例下载地址

Hands-On Design Patterns with Java.pdf

不能下载?内容有错? 点击这里报错 + 投诉 + 提问

好例子网口号:伸出你的我的手 — 分享

网友评论

发表评论

(您的评论需要经过审核才能显示)

查看所有0条评论>>

小贴士

感谢您为本站写下的评论,您的评论对其它用户来说具有重要的参考价值,所以请认真填写。

  • 类似“顶”、“沙发”之类没有营养的文字,对勤劳贡献的楼主来说是令人沮丧的反馈信息。
  • 相信您也不想看到一排文字/表情墙,所以请不要反馈意义不大的重复字符,也请尽量不要纯表情的回复。
  • 提问之前请再仔细看一遍楼主的说明,或许是您遗漏了。
  • 请勿到处挖坑绊人、招贴广告。既占空间让人厌烦,又没人会搭理,于人于己都无利。

关于好例子网

本站旨在为广大IT学习爱好者提供一个非营利性互相学习交流分享平台。本站所有资源都可以被免费获取学习研究。本站资源来自网友分享,对搜索内容的合法性不具有预见性、识别性、控制性,仅供学习研究,请务必在下载后24小时内给予删除,不得用于其他任何用途,否则后果自负。基于互联网的特殊性,平台无法对用户传输的作品、信息、内容的权属或合法性、安全性、合规性、真实性、科学性、完整权、有效性等进行实质审查;无论平台是否已进行审查,用户均应自行承担因其传输的作品、信息、内容而可能或已经产生的侵权或权属纠纷等法律责任。本站所有资源不代表本站的观点或立场,基于网友分享,根据中国法律《信息网络传播权保护条例》第二十二与二十三条之规定,若资源存在侵权或相关问题请联系本站客服人员,点此联系我们。关于更多版权及免责申明参见 版权及免责申明

;
报警