Class AbstractOpenPgpMetadataStore
- java.lang.Object
-
- org.jivesoftware.smackx.ox.store.abstr.AbstractOpenPgpMetadataStore
-
- All Implemented Interfaces:
OpenPgpMetadataStore
- Direct Known Subclasses:
FileBasedOpenPgpMetadataStore
public abstract class AbstractOpenPgpMetadataStore extends Object implements OpenPgpMetadataStore
-
-
Constructor Summary
Constructors Constructor Description AbstractOpenPgpMetadataStore()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description Map<org.pgpainless.key.OpenPgpV4Fingerprint,Date>
getAnnouncedFingerprintsOf(BareJid contact)
Return aMap
containing all announced fingerprints of a contact, as well as the dates on which they were last modified bycontact
.protected abstract Map<org.pgpainless.key.OpenPgpV4Fingerprint,Date>
readAnnouncedFingerprintsOf(BareJid contact)
Read the fingerprints and modification dates of announced keys of a user from local storage.void
setAnnouncedFingerprintsOf(BareJid contact, Map<org.pgpainless.key.OpenPgpV4Fingerprint,Date> data)
Store a contacts announced fingerprints and dates of last modification.protected abstract void
writeAnnouncedFingerprintsOf(BareJid contact, Map<org.pgpainless.key.OpenPgpV4Fingerprint,Date> metadata)
Write the fingerprints and modification dates of announced keys of a user to local storage.
-
-
-
Constructor Detail
-
AbstractOpenPgpMetadataStore
public AbstractOpenPgpMetadataStore()
-
-
Method Detail
-
getAnnouncedFingerprintsOf
public Map<org.pgpainless.key.OpenPgpV4Fingerprint,Date> getAnnouncedFingerprintsOf(BareJid contact) throws IOException
Description copied from interface:OpenPgpMetadataStore
Return aMap
containing all announced fingerprints of a contact, as well as the dates on which they were last modified bycontact
. This method MUST NOT return null.- Specified by:
getAnnouncedFingerprintsOf
in interfaceOpenPgpMetadataStore
- Parameters:
contact
- contact in which we are interested.- Returns:
- announced fingerprints
- Throws:
IOException
- IO is dangerous
-
setAnnouncedFingerprintsOf
public void setAnnouncedFingerprintsOf(BareJid contact, Map<org.pgpainless.key.OpenPgpV4Fingerprint,Date> data) throws IOException
Description copied from interface:OpenPgpMetadataStore
Store a contacts announced fingerprints and dates of last modification.- Specified by:
setAnnouncedFingerprintsOf
in interfaceOpenPgpMetadataStore
- Parameters:
contact
- contact in which we are interested.data
-Map
containing the contacts announced fingerprints and dates of last modification.- Throws:
IOException
- IO is dangerous
-
readAnnouncedFingerprintsOf
protected abstract Map<org.pgpainless.key.OpenPgpV4Fingerprint,Date> readAnnouncedFingerprintsOf(BareJid contact) throws IOException
Read the fingerprints and modification dates of announced keys of a user from local storage.- Parameters:
contact
- contact- Returns:
- contacts announced key fingerprints and latest modification dates
- Throws:
IOException
- IO is dangerous
-
writeAnnouncedFingerprintsOf
protected abstract void writeAnnouncedFingerprintsOf(BareJid contact, Map<org.pgpainless.key.OpenPgpV4Fingerprint,Date> metadata) throws IOException
Write the fingerprints and modification dates of announced keys of a user to local storage.- Parameters:
contact
- contactmetadata
- announced key fingerprints and latest modification dates- Throws:
IOException
- IO is dangerous
-
-