java.lang.Object | |||
↳ | com.pspdfkit.signatures.signers.Signer | ||
↳ | com.pspdfkit.signatures.signers.PrivateKeySigner | ||
↳ | com.pspdfkit.signatures.signers.MemorySigner |
A Signer
that uses a given KeyStore.PrivateKeyEntry to sign documents.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
MemorySigner(String displayName, KeyStore.PrivateKeyEntry signingKeyPair)
Create the memory signer.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
void |
loadPrivateKey(String password, InteractiveSigner.LoadingFeedbackListener feedbackListener, PrivateKeySigner.OnPrivateKeyLoadedCallback onPrivateKeyLoadedCallback)
Loads the
KeyStore.PrivateKeyEntry used by this signer. |
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() | |||||||||||
![]() | |||||||||||
![]() | |||||||||||
![]() |
Create the memory signer. Required parameters are the displayName
and the signingKeyPair
(a KeyStore.PrivateKeyEntry
instance).
displayName | Name of this signer to be used for UI display. |
---|---|
signingKeyPair | Key pair which is used to sign the document. It has to contain both a
certificate and a private key. Use loadPrivateKeyFromFile(File, String, String, String) to load a KeyStore.PrivateKeyEntry from a PKCS#12 file.
|
Loads the KeyStore.PrivateKeyEntry
used by this signer. Subclasses have to override
this and have to make sure to call the provided PrivateKeySigner.OnPrivateKeyLoadedCallback
whenever
private key is ready. The method might be called with a LoadingFeedbackListener which
should be used by the implementation to notify of important events (e.g. password required,
key loading complete, etc.).
password | An optional password that should be used to load the private key. |
---|---|
feedbackListener | A LoadingFeedbackListener to be notified of important loading
events, or null . |
onPrivateKeyLoadedCallback | An OnPrivateKeyLoadedCallback that should be called once the private key has been loaded. |