📄 decorator.html
字号:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta name="description" content="Java,JDBC,EJB,Open Source,jdk,rmi">
<meta name="Keywords"
content="Java, servlets, Java servlet, Javascript, ActiveX, VRML,
applet, applets, directory, news, jdbc, applications,
Java applications, Java developer, Java development, developer,
classes, Jars.com, Jars, intranet, Java applet, Javabeans,
Java products, JDK, Java development kit, java development environment, JIT,
JavaPlan, enterprise tools, JVM, Java Virtual Machine, Java resources,
SUN, CGI, Perl, database, network, html,
xml, dhtml, rating, ratings, review, jars, cgi, programming,
software review, software rating">
<title>csdn_decorator 模式 </title>
<style>
.news { BACKGROUND: #007cd3; font-family: "宋体"; font-size: 9pt }
.t { font-family: "宋体"; font-size: 9pt }
.t1 { color:#007cd3; font-family: "宋体"; font-size: 9pt }
.white { font-family: "宋体"; font-size: 9pt;color:#FFFFFF }
.red { font-family: "宋体"; font-size: 9pt;color:#FF0000 }
A:visited {color:#0000FF}
A:hover {color: #ff6666; text-decoration: none}
.text {font-size: 12px; line-height: 160%; font-family: "宋体"}
.text1 {color:#000000; font-size: 12px; line-height: 130%; font-family: "宋体"; text-decoration: none}
.text1:visited {color:#000000}
.text1:hover {color: #000000}
.text2 {color:#000000; font-size: 12px; line-height: 130%; font-family: "宋体"; text-decoration: none}
.text2:visited {color:#000000}
.text2:hover {color: #000000}
.text3 {font-size: 12px; line-height: 100%; font-family: "宋体"; text-decoration: none}
.large {font-size: 14.8px; line-height: 130%}
</style>
</head>
<body
<tr>
<td WIDTH="100%" VALIGN="TOP">
<tr>
<td WIDTH="100%" CLASS="white"></td>
</tr>
<tr>
<td WIDTH="50%" bordercolor="#FFFFFF" CLASS="t1" bgcolor="#F0F0F0" align="center" nowrap> decorator 模式 </td>
<p> <td WIDTH="50%" bordercolor="#FFFFFF" CLASS="t1" bgcolor="#F0F0F0" align="center" nowrap>作者:jdeveloper</td></p>
</tr>
<tr>
<td WIDTH="100%" bordercolor="#FFFFFF" CLASS="t" bgcolor="#FFFFFF" colspan="2">
<hr size=1>
<img src="decorator.jpg" >
<hr size=1>
decorator for non-visualable class
e.g. java.io.*<br>
The class FilterInputStream itself simply overrides
all methods of InputStream with versions that pass all
requests to the underlying input stream. Subclasses of
FilterInputStream may further override some of these
methods as well as provide additional methods and fields.
<br>
The FilterInputStream class is thus a Decorator that can be wrapped
around any input stream class. It is essentially an abstract class that doesn’t
do any processing, but provides a layer where the relevant methods have been
duplicated. It normally forwards these method calls to the enclosed parent
stream class.
The interesting classes derived from FilterInputStream include:
<pre>
BufferedInputStream Adds buffering to stream so that every call does
not cause I/O to occur.
CheckedInputStream Maintains a checksum of bytes as they are read
DataInputStream Reads primitive types (Long, Boolean, Float, etc.)
from the input stream.
DigestInputStream Computes a MessageDigest of any input stream.
InflaterInputStream Implements methods for uncompressing data.
PushbackInputStream Provides a buffer where data can be “unread,” if
during parsing you discover you need to back up.
</pre>
</td>
</tr>
</td>
</tr>
</div>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -