aboutsummaryrefslogtreecommitdiffstats
path: root/libraries/spongycastle/core/src/main/jdk1.1/java/security/cert/CertificateFactorySpi.java
blob: 8cc06fc2e7db1039231595c5dfcbb75c0363546d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
package java.security.cert;

import java.io.InputStream;
import java.util.Collection;
import java.util.Iterator;
import java.util.List;

public abstract class CertificateFactorySpi
{
    public CertificateFactorySpi()
    {
    }

    public abstract CRL engineGenerateCRL(InputStream inStream)
        throws CRLException;

    public abstract Collection engineGenerateCRLs(InputStream inStream)
        throws CRLException;

    public abstract Certificate engineGenerateCertificate(InputStream inStream)
        throws CertificateException;

    public abstract /*SK13 Vector*/ Collection engineGenerateCertificates(InputStream inStream)
        throws CertificateException;

    /**
     * Returns an iteration of the <code>CertPath</code> encodings supported 
     * by this certificate factory, with the default encoding first. See 
     * Appendix A in the 
     * Java Certification Path API Programmer's Guide
     * for information about standard encoding names.<br />
     * <br />
     * Attempts to modify the returned <code>Iterator</code> via its
     * <code>remove</code> method result in an
     * <code>UnsupportedOperationException</code>.<br />
     * <br />
     * This method was added to version 1.4 of the Java 2 Platform
     * Standard Edition. In order to maintain backwards compatibility with
     * existing service providers, this method cannot be <code>abstract</code>
     * and by default throws an <code>UnsupportedOperationException</code>.
     *
     * @return an <code>Iterator</code> over the names of the supported
     *         <code>CertPath</code> encodings (as <code>String</code>s)
     *
     * @exception UnsupportedOperationException if the method is not supported
     */
    public abstract Iterator engineGetCertPathEncodings();

    /**
     * Generates a <code>CertPath</code> object and initializes it with
     * the data read from the <code>InputStream</code> inStream. The data
     * is assumed to be in the default encoding.
     *
     * @param inStream an <code>InputStream</code> containing the data
     *
     * @return a <code>CertPath</code> initialized with the data from the
     *   <code>InputStream</code>
     *
     * @exception CertificateException if an exception occurs while decoding
     */
    public abstract CertPath engineGenerateCertPath(InputStream inStream)
        throws CertificateException;

    /**
     * Generates a <code>CertPath</code> object and initializes it with
     * the data read from the <code>InputStream</code> inStream. The data
     * is assumed to be in the specified encoding.<br />
     * <br />
     * This method was added to version 1.4 of the Java 2 Platform
     * Standard Edition. In order to maintain backwards compatibility with
     * existing service providers, this method cannot be <code>abstract</code>
     * and by default throws an <code>UnsupportedOperationException</code>.
     *
     * @param inStream an <code>InputStream</code> containing the data
     * @param encoding the encoding used for the data
     *
     * @return a <code>CertPath</code> initialized with the data from the
     *   <code>InputStream</code>
     *
     * @exception CertificateException if an exception occurs while decoding or
     *   the encoding requested is not supported
     * @exception UnsupportedOperationException if the method is not supported
     */
    public abstract CertPath engineGenerateCertPath(InputStream inStream, String encoding)
        throws CertificateException;

    /**
     * Generates a <code>CertPath</code> object and initializes it with
     * a <code>List</code> of <code>Certificate</code>s.<br />
     * <br />
     * The certificates supplied must be of a type supported by the
     * <code>CertificateFactory</code>. They will be copied out of the supplied
     * <code>List</code> object.<br />
     * <br />
     * This method was added to version 1.4 of the Java 2 Platform
     * Standard Edition. In order to maintain backwards compatibility with
     * existing service providers, this method cannot be <code>abstract</code>
     * and by default throws an <code>UnsupportedOperationException</code>.
     *
     * @param certificates a <code>List</code> of <code>Certificate</code>s
     *
     * @return a <code>CertPath</code> initialized with the supplied list of
     *   certificates
     *
     * @exception CertificateException if an exception occurs
     * @exception UnsupportedOperationException if the method is not supported
     */
    public abstract CertPath engineGenerateCertPath(List certificates)
        throws CertificateException;
}