APIdia Launch Partner
Top Description Fields Constructors Methods
java.security.cert

public Class LDAPCertStoreParameters

extends Object
implements CertStoreParameters
Class Inheritance
All Implemented Interfaces
java.security.cert.CertStoreParameters, java.lang.Cloneable

Parameters used as input for the LDAP CertStore algorithm.

This class is used to provide necessary configuration parameters (server name and port number) to implementations of the LDAP CertStore algorithm. However, if you are retrieving certificates or CRLs from an ldap URI as specified by RFC 5280, use the URICertStoreParameters instead, as the URI may contain additional information such as the distinguished name that will help the LDAP CertStore find the specific certificates and CRLs.

Concurrent Access

Unless otherwise specified, the methods defined in this class are not thread-safe. Multiple threads that need to access a single object concurrently should synchronize amongst themselves and provide the necessary locking. Multiple threads each manipulating separate objects need not synchronize.

Author
Steve Hanna
Since
1.4
See Also
CertStore

Field Summary

Modifier and TypeField and Description
private static final int
private final int
port

the port number of the LDAP server

private final String
serverName

the DNS name of the LDAP server

Constructor Summary

AccessConstructor and Description
public
LDAPCertStoreParameters(String
the DNS name of the LDAP server
serverName
,
int
the port number of the LDAP server
port
)

Creates an instance of LDAPCertStoreParameters with the specified parameter values.

public
LDAPCertStoreParameters(String
the DNS name of the LDAP server
serverName
)

Creates an instance of LDAPCertStoreParameters with the specified server name and a default port of 389.

public
LDAPCertStoreParameters()

Creates an instance of LDAPCertStoreParameters with the default parameter values (server name "localhost", port 389).

Method Summary

Modifier and TypeMethod and Description
public Object

Returns:

the copy
clone
()

Overrides java.lang.Object.clone.

Implements java.security.cert.CertStoreParameters.clone.

Returns a copy of this object.

public int

Returns:

the port number
getPort
()

Returns the port number of the LDAP server.

public String

Returns:

the name (not null)
getServerName
()

Returns the DNS name of the LDAP server.

public String

Returns:

a formatted string describing the parameters
toString
()

Overrides java.lang.Object.toString.

Returns a formatted string describing the parameters.

Inherited from java.lang.Object:
equalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

LDAP_DEFAULT_PORTback to summary
private static final int LDAP_DEFAULT_PORT
portback to summary
private final int port

the port number of the LDAP server

serverNameback to summary
private final String serverName

the DNS name of the LDAP server

Constructor Detail

LDAPCertStoreParametersback to summary
public LDAPCertStoreParameters(String serverName, int port)

Creates an instance of LDAPCertStoreParameters with the specified parameter values.

Parameters
serverName:String

the DNS name of the LDAP server

port:int

the port number of the LDAP server

Exceptions
NullPointerException:
if serverName is null
LDAPCertStoreParametersback to summary
public LDAPCertStoreParameters(String serverName)

Creates an instance of LDAPCertStoreParameters with the specified server name and a default port of 389.

Parameters
serverName:String

the DNS name of the LDAP server

Exceptions
NullPointerException:
if serverName is null
LDAPCertStoreParametersback to summary
public LDAPCertStoreParameters()

Creates an instance of LDAPCertStoreParameters with the default parameter values (server name "localhost", port 389).

Method Detail

cloneback to summary
public Object clone()

Overrides java.lang.Object.clone.

Implements java.security.cert.CertStoreParameters.clone.

Returns a copy of this object. Changes to the copy will not affect the original and vice versa.

Note

this method currently performs a shallow copy of the object (simply calls Object.clone()). This may be changed in a future revision to perform a deep copy if new parameters are added that should not be shared.

Returns:Object

the copy

getPortback to summary
public int getPort()

Returns the port number of the LDAP server.

Returns:int

the port number

getServerNameback to summary
public String getServerName()

Returns the DNS name of the LDAP server.

Returns:String

the name (not null)

toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Returns a formatted string describing the parameters.

Returns:String

a formatted string describing the parameters