public class CheckedOutputStream extends FilterOutputStream
Checksum
out| Constructor and Description |
|---|
CheckedOutputStream(OutputStream out, Checksum cksum)
创建具有指定校验输出流。
|
| Modifier and Type | Method and Description |
|---|---|
Checksum |
getChecksum()
返回此输出流的校验。
|
void |
write(byte[] b, int off, int len)
写入一个字节数组。
|
void |
write(int b)
写一个字节。
|
close, flush, writepublic CheckedOutputStream(OutputStream out, Checksum cksum)
out -输出流
cksum -校验
public void write(int b)
throws IOException
write 方法重写,继承类
FilterOutputStream
b的字节被写入
IOException如果发生I/O错误
public void write(byte[] b,
int off,
int len)
throws IOException
write 方法重写,继承类
FilterOutputStream
b -要写入的数据
off的起始偏移量的数据
len -字节数要写
IOException如果发生I/O错误
FilterOutputStream.write(int)
public Checksum getChecksum()
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.