Top Description Fields Constructors Methods
org.bouncycastle.asn1.x509

public Class X509ExtensionsGenerator

extends Object
Class Inheritance
Imports
java.io.IOException, java.util.Hashtable, .Vector, org.bouncycastle.asn1.ASN1Encodable, .ASN1Encoding, .ASN1ObjectIdentifier, .DEROctetString

Deprecated

use org.bouncycastle.asn1.x509.ExtensionsGenerator

Generator for X.509 extensions

Field Summary

Modifier and TypeField and Description
private Hashtable<K, V>
private Vector<E>

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public void
addExtension(ASN1ObjectIdentifier
OID for the extension.
oid
,
boolean
true if critical, false otherwise.
critical
,
ASN1Encodable
the ASN.1 object to be included in the extension.
value
)

Add an extension with the given oid and the passed in value to be included in the OCTET STRING associated with the extension.

public void
addExtension(ASN1ObjectIdentifier
OID for the extension.
oid
,
boolean
true if critical, false otherwise.
critical
,
byte[]
the byte array to be wrapped.
value
)

Add an extension with the given oid and the passed in byte array to be wrapped in the OCTET STRING associated with the extension.

public X509Extensions

Returns:

an X09Extensions object.
generate
()
References Deprecated X509Extensions is deprecated or references (maybe indirectly) at least one deprecated element.

Generate an X509Extensions object based on the current state of the generator.

public boolean

Returns:

true if empty, false otherwise
isEmpty
()

Return true if there are no extension present in this generator.

public void
reset()

Reset the generator

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

extensionsback to summary
private Hashtable<K, V> extensions
extOrderingback to summary
private Vector<E> extOrdering

Constructor Detail

X509ExtensionsGeneratorback to summary
public X509ExtensionsGenerator()

Method Detail

addExtensionback to summary
public void addExtension(ASN1ObjectIdentifier oid, boolean critical, ASN1Encodable value)

Add an extension with the given oid and the passed in value to be included in the OCTET STRING associated with the extension.

Parameters
oid:ASN1ObjectIdentifier

OID for the extension.

critical:boolean

true if critical, false otherwise.

value:ASN1Encodable

the ASN.1 object to be included in the extension.

addExtensionback to summary
public void addExtension(ASN1ObjectIdentifier oid, boolean critical, byte[] value)

Add an extension with the given oid and the passed in byte array to be wrapped in the OCTET STRING associated with the extension.

Parameters
oid:ASN1ObjectIdentifier

OID for the extension.

critical:boolean

true if critical, false otherwise.

value:byte[]

the byte array to be wrapped.

generateback to summary
public X509Extensions generate()

References Deprecated

X509Extensions is deprecated or references (maybe indirectly) at least one deprecated element.

See corresponding docs for further information.

Generate an X509Extensions object based on the current state of the generator.

Returns:X509Extensions

an X09Extensions object.

isEmptyback to summary
public boolean isEmpty()

Return true if there are no extension present in this generator.

Returns:boolean

true if empty, false otherwise

resetback to summary
public void reset()

Reset the generator