Package org.apache.james.jdkim.canon
Class DigestOutputStream
java.lang.Object
java.io.OutputStream
java.io.FilterOutputStream
org.apache.james.jdkim.canon.DigestOutputStream
- All Implemented Interfaces:
Closeable,Flushable,AutoCloseable
DigestOutputStream is used as a filter stream or as the ending stream in
order to calculate a digest of a stream.
-
Field Summary
Fields inherited from class java.io.FilterOutputStream
out -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.io.OutputStream
nullOutputStream
-
Constructor Details
-
DigestOutputStream
-
DigestOutputStream
-
-
Method Details
-
write
- Overrides:
writein classFilterOutputStream- Throws:
IOException
-
write
- Overrides:
writein classFilterOutputStream- Throws:
IOException
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classFilterOutputStream- Throws:
IOException
-
flush
- Specified by:
flushin interfaceFlushable- Overrides:
flushin classFilterOutputStream- Throws:
IOException
-
write
- Overrides:
writein classFilterOutputStream- Throws:
IOException
-
getDigest
public byte[] getDigest()- Returns:
- the stream digest as a byte array
-