Class XMPP.SecRingSelectionStrategy

  • All Implemented Interfaces:
    KeyRingSelectionStrategy<org.bouncycastle.openpgp.PGPSecretKeyRing,​org.bouncycastle.openpgp.PGPSecretKeyRingCollection,​java.lang.String>
    Enclosing class:
    XMPP

    public static class XMPP.SecRingSelectionStrategy
    extends ExactUserId.SecRingSelectionStrategy
    SecretKeyRingSelectionStrategy which accepts a given PGPSecretKeyRing if its primary key has a user-id that matches the given
    jid
    . The argument
    jid
    can either contain the prefix "xmpp:", or not, the result will be the same.
    • Constructor Detail

      • SecRingSelectionStrategy

        public SecRingSelectionStrategy()
    • Method Detail

      • accept

        public boolean accept​(java.lang.String jid,
                              org.bouncycastle.openpgp.PGPSecretKeyRing keyRing)
        Description copied from interface: KeyRingSelectionStrategy
        Return true, if the filter accepts the given
        keyRing
        based on the given
        identifier
        .
        Specified by:
        accept in interface KeyRingSelectionStrategy<org.bouncycastle.openpgp.PGPSecretKeyRing,​org.bouncycastle.openpgp.PGPSecretKeyRingCollection,​java.lang.String>
        Overrides:
        accept in class ExactUserId.SecRingSelectionStrategy
        Parameters:
        jid - identifier
        keyRing - key ring
        Returns:
        acceptance