java.security.cert
Class LDAPCertStoreParameters
- java.lang.Object
-
- java.security.cert.LDAPCertStoreParameters
-
- All Implemented Interfaces:
- java.lang.Cloneable, CertStoreParameters
public class LDAPCertStoreParameters extends java.lang.Object implements CertStoreParameters
Parameters used as input for the LDAPCertStorealgorithm.This class is used to provide necessary configuration parameters (server name and port number) to implementations of the LDAP
CertStorealgorithm.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.
- Since:
- 1.4
- See Also:
CertStore
-
-
Constructor Summary
Constructors Constructor and Description LDAPCertStoreParameters()Creates an instance ofLDAPCertStoreParameterswith the default parameter values (server name "localhost", port 389).LDAPCertStoreParameters(java.lang.String serverName)Creates an instance ofLDAPCertStoreParameterswith the specified server name and a default port of 389.LDAPCertStoreParameters(java.lang.String serverName, int port)Creates an instance ofLDAPCertStoreParameterswith the specified parameter values.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description java.lang.Objectclone()Returns a copy of this object.intgetPort()Returns the port number of the LDAP server.java.lang.StringgetServerName()Returns the DNS name of the LDAP server.java.lang.StringtoString()Returns a formatted string describing the parameters.
-
-
-
Constructor Detail
-
LDAPCertStoreParameters
public LDAPCertStoreParameters(java.lang.String serverName, int port)Creates an instance ofLDAPCertStoreParameterswith the specified parameter values.- Parameters:
serverName- the DNS name of the LDAP serverport- the port number of the LDAP server- Throws:
java.lang.NullPointerException- ifserverNameisnull
-
LDAPCertStoreParameters
public LDAPCertStoreParameters(java.lang.String serverName)
Creates an instance ofLDAPCertStoreParameterswith the specified server name and a default port of 389.- Parameters:
serverName- the DNS name of the LDAP server- Throws:
java.lang.NullPointerException- ifserverNameisnull
-
LDAPCertStoreParameters
public LDAPCertStoreParameters()
Creates an instance ofLDAPCertStoreParameterswith the default parameter values (server name "localhost", port 389).
-
-
Method Detail
-
getServerName
public java.lang.String getServerName()
Returns the DNS name of the LDAP server.- Returns:
- serverName the name (not
null)
-
getPort
public int getPort()
Returns the port number of the LDAP server.- Returns:
- the port number
-
clone
public java.lang.Object 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.- Specified by:
clonein interfaceCertStoreParameters- Overrides:
clonein classjava.lang.Object- Returns:
- the copy
-
toString
public java.lang.String toString()
Returns a formatted string describing the parameters.- Overrides:
toStringin classjava.lang.Object- Returns:
- a formatted string describing the parameters
-
-