SignatureType
ArmoredSignatureType
, BinarySignatureType
public abstract class AbstractSignatureType extends Object implements SignatureType
SignatureType
implementations.Constructor | Description |
---|---|
AbstractSignatureType() |
Modifier and Type | Method | Description |
---|---|---|
String |
combinedExtension(File toSign) |
Combines the extension of the given file with the expected signature extension.
|
File |
fileFor(File toSign) |
Calculates the file where to store the signature of the given file to be signed.
|
File |
sign(Signatory signatory,
File toSign) |
Signs the given file and returns the file where the signature has been written to.
|
void |
sign(Signatory signatory,
InputStream toSign,
OutputStream destination) |
Signs the data from the given InputStream and stores the signature in the given OutputStream.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getExtension
public File sign(Signatory signatory, File toSign)
SignatureType
sign
in interface SignatureType
signatory
- The signatorytoSign
- The file to be signedpublic void sign(Signatory signatory, InputStream toSign, OutputStream destination)
SignatureType
sign
in interface SignatureType
signatory
- The signatorytoSign
- The source of the data to be signeddestination
- Where the signature will be written topublic File fileFor(File toSign)
SignatureType
fileFor
in interface SignatureType
toSign
- The file to be signedpublic String combinedExtension(File toSign)
SignatureType
combinedExtension
in interface SignatureType
toSign
- The file to be signedSignatureType.getExtension()