All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.spongycastle.jce.MultiCertStoreParameters Maven / Gradle / Ivy

Go to download

Spongy Castle is a package-rename (org.bouncycastle.* to org.spongycastle.*) of Bouncy Castle intended for Android. Android ships with a stripped-down version of Bouncy Castle - this causes classloader collisions if you try to add an alternative (updated/complete) Bouncy Castle jar. This jar contains JCE provider and lightweight API for the Bouncy Castle Cryptography APIs for JDK 1.5.

There is a newer version: 1.46.99.3-UNOFFICIAL-ROBERTO-RELEASE
Show newest version
package org.spongycastle.jce;

import java.security.cert.CertStoreParameters;
import java.util.Collection;

public class MultiCertStoreParameters
    implements CertStoreParameters
{
    private Collection certStores;
    private boolean searchAllStores;

    /**
     * Create a parameters object which specifies searching of all the passed in stores.
     *
     * @param certStores CertStores making up the multi CertStore
     */
    public MultiCertStoreParameters(Collection certStores)
    {
        this(certStores, true);
    }

    /**
     * Create a parameters object which can be to used to make a multi store made up
     * of the passed in CertStores. If the searchAllStores parameter is false, any search on
     * the multi-store will terminate as soon as a search query produces a result.
     * 
     * @param certStores CertStores making up the multi CertStore
     * @param searchAllStores true if all CertStores should be searched on request, false if a result
     * should be returned on the first successful CertStore query.
     */
    public MultiCertStoreParameters(Collection certStores, boolean searchAllStores)
    {
        this.certStores = certStores;
        this.searchAllStores = searchAllStores;
    }

    public Collection getCertStores()
    {
        return certStores;
    }

    public boolean getSearchAllStores()
    {
        return searchAllStores;
    }

    public Object clone()
    {
        return this;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy