Increase coverage of PGPCertificateDirectory

This commit is contained in:
Paul Schaub 2022-08-25 11:26:12 +02:00
parent f34c6d7735
commit 4ce9f46846
Signed by: vanitasvitae
GPG key ID: 62BEE9264BF17311
2 changed files with 39 additions and 1 deletions

View file

@ -21,6 +21,10 @@ import java.util.Iterator;
import java.util.Map;
import java.util.concurrent.atomic.AtomicLong;
/**
* Implementation of the {@link PGPCertificateDirectory.Backend} which stores key material in-memory.
* It uses object locking with {@link #wait()} and {@link #notify()} to synchronize write-access.
*/
public class InMemoryCertificateDirectoryBackend implements PGPCertificateDirectory.Backend {
protected static class ObjectLockingMechanism implements PGPCertificateDirectory.LockingMechanism {