public class DigestDocument extends CommonDocument
DSSDocument. It can be used to handle a large file to be signed. The computation
of the digest associated to the file can be done externally.absolutePath, base64EncodeDigestMap, mimeType, name| Constructor and Description |
|---|
DigestDocument()
Creates DigestDocument.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addDigest(DigestAlgorithm digestAlgorithm,
String base64EncodeDigest)
This method allows to add a pair:
DigestAlgorithm and the corresponding digest value calculated
externally on the encapsulated file. |
String |
getDigest(DigestAlgorithm digestAlgorithm) |
InputStream |
openStream() |
void |
save(String filePath) |
getAbsolutePath, getMimeType, getName, setAbsolutePath, setMimeType, setName, toString, writeTopublic void addDigest(DigestAlgorithm digestAlgorithm, String base64EncodeDigest)
DigestAlgorithm and the corresponding digest value calculated
externally on the encapsulated file. The digest value is base 64 encoded.digestAlgorithm - DigestAlgorithmbase64EncodeDigest - the corresponding base 64 encoded digest valuepublic String getDigest(DigestAlgorithm digestAlgorithm)
getDigest in interface DSSDocumentgetDigest in class CommonDocumentpublic InputStream openStream()
public void save(String filePath) throws IOException
save in interface DSSDocumentsave in class CommonDocumentIOExceptionCopyright © 2019. All rights reserved.