All Packages Class Hierarchy This Package Previous Next Index
Class netscape.security.x509.CertificateVersion
netscape.security.x509.CertificateVersion
- public class CertificateVersion
- implements CertAttrSet
This class defines the version of the X509 Certificate.
- See Also:
- CertAttrSet
-
IDENT
- Identifier for this attribute, to be used with the
get, set, delete methods of Certificate, x509 type.
-
NAME
- Sub attributes name for this CertAttrSet.
-
V1
- X509Certificate Version 1
-
V2
- X509Certificate Version 2
-
V3
- X509Certificate Version 3
-
VERSION
-
-
CertificateVersion()
- The default constructor for this class,
sets the version to 0 (i.e.
-
CertificateVersion(DerInputStream)
- Create the object, decoding the values from the passed DER stream.
-
CertificateVersion(DerValue)
- Create the object, decoding the values from the passed DerValue.
-
CertificateVersion(InputStream)
- Create the object, decoding the values from the passed stream.
-
CertificateVersion(int)
- The constructor for this class for the required version.
-
compare(int)
- Compare versions.
-
decode(InputStream)
- Decode the CertificateVersion period in DER form from the stream.
-
delete(String)
- Delete the attribute value.
-
encode(OutputStream)
- Encode the CertificateVersion period in DER form to the stream.
-
get(String)
- Get the attribute value.
-
getElements()
- Return an enumeration of names of attributes existing within this
attribute.
-
getName()
- Return the name of this attribute.
-
set(String, Object)
- Set the attribute value.
-
toString()
- Return the version number of the certificate.
V1
public static final int V1
- X509Certificate Version 1
V2
public static final int V2
- X509Certificate Version 2
V3
public static final int V3
- X509Certificate Version 3
IDENT
public static final String IDENT
- Identifier for this attribute, to be used with the
get, set, delete methods of Certificate, x509 type.
NAME
public static final String NAME
- Sub attributes name for this CertAttrSet.
VERSION
public static final String VERSION
CertificateVersion
public CertificateVersion()
- The default constructor for this class,
sets the version to 0 (i.e. X.509 version 1).
CertificateVersion
public CertificateVersion(int version) throws IOException
- The constructor for this class for the required version.
- Parameters:
- version - the version for the certificate.
- Throws: IOException
- if the version is not valid.
CertificateVersion
public CertificateVersion(DerInputStream in) throws IOException
- Create the object, decoding the values from the passed DER stream.
- Parameters:
- in - the DerInputStream to read the CertificateVersion from.
- Throws: IOException
- on decoding errors.
CertificateVersion
public CertificateVersion(InputStream in) throws IOException
- Create the object, decoding the values from the passed stream.
- Parameters:
- in - the InputStream to read the CertificateVersion from.
- Throws: IOException
- on decoding errors.
CertificateVersion
public CertificateVersion(DerValue val) throws IOException
- Create the object, decoding the values from the passed DerValue.
- Parameters:
- val - the Der encoded value.
- Throws: IOException
- on decoding errors.
toString
public String toString()
- Return the version number of the certificate.
encode
public void encode(OutputStream out) throws IOException
- Encode the CertificateVersion period in DER form to the stream.
- Parameters:
- out - the OutputStream to marshal the contents to.
- Throws: IOException
- on errors.
decode
public void decode(InputStream in) throws IOException
- Decode the CertificateVersion period in DER form from the stream.
- Parameters:
- in - the InputStream to unmarshal the contents from.
- Throws: IOException
- on errors.
set
public void set(String name,
Object obj) throws IOException
- Set the attribute value.
get
public Object get(String name) throws IOException
- Get the attribute value.
delete
public void delete(String name) throws IOException
- Delete the attribute value.
getElements
public Enumeration getElements()
- Return an enumeration of names of attributes existing within this
attribute.
getName
public String getName()
- Return the name of this attribute.
compare
public int compare(int vers)
- Compare versions.
All Packages Class Hierarchy This Package Previous Next Index