Class AbstractOpenPgpTrustStore

    • Constructor Detail

      • AbstractOpenPgpTrustStore

        public AbstractOpenPgpTrustStore()
    • Method Detail

      • readTrust

        protected abstract OpenPgpTrustStore.Trust readTrust​(org.jxmpp.jid.BareJid owner,
                                                             org.pgpainless.key.OpenPgpV4Fingerprint fingerprint)
                                                      throws java.io.IOException
        Read the trust record for the key with fingerprint fingerprint of user owner from local storage. This method returns OpenPgpTrustStore.Trust.undecided in case that no trust record has been found.
        Parameters:
        owner - owner of the key
        fingerprint - fingerprint of the key
        Returns:
        trust state of the key
        Throws:
        java.io.IOException - IO is dangerous
      • writeTrust

        protected abstract void writeTrust​(org.jxmpp.jid.BareJid owner,
                                           org.pgpainless.key.OpenPgpV4Fingerprint fingerprint,
                                           OpenPgpTrustStore.Trust trust)
                                    throws java.io.IOException
        Write the trust record for the key with fingerprint fingerprint of user owner to local storage.
        Parameters:
        owner - owner of the key
        fingerprint - fingerprint of the key
        trust - trust state of the key
        Throws:
        java.io.IOException - IO is dangerous
      • setTrust

        public void setTrust​(org.jxmpp.jid.BareJid owner,
                             org.pgpainless.key.OpenPgpV4Fingerprint fingerprint,
                             OpenPgpTrustStore.Trust trust)
                      throws java.io.IOException
        Description copied from interface: OpenPgpTrustStore
        Store the OpenPgpTrustStore.Trust state of owners key with fingerprint fingerprint.
        Specified by:
        setTrust in interface OpenPgpTrustStore
        Parameters:
        owner - owner of the key
        fingerprint - fingerprint of the key
        trust - trust record
        Throws:
        java.io.IOException - IO is dangerous