Class LDAPControl
java.lang.Object
com.unboundid.ldap.sdk.migrate.ldapjdk.LDAPControl
- All Implemented Interfaces:
Serializable
@Extensible
@NotMutable
@ThreadSafety(level=COMPLETELY_THREADSAFE)
public class LDAPControl
extends Object
implements Serializable
This class provides a data structure that holds information about an LDAP
control.
This class is primarily intended to be used in the process of updating applications which use the Netscape Directory SDK for Java to switch to or coexist with the UnboundID LDAP SDK for Java. For applications not written using the Netscape Directory SDK for Java, the
This class is primarily intended to be used in the process of updating applications which use the Netscape Directory SDK for Java to switch to or coexist with the UnboundID LDAP SDK for Java. For applications not written using the Netscape Directory SDK for Java, the
Control class should
be used instead.- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionLDAPControl(Control control) Creates a new LDAP control from the provided control.LDAPControl(String id, boolean critical, byte[] vals) Creates a new LDAP control with the specified information. -
Method Summary
Modifier and TypeMethodDescriptionCreates a duplicate of this control.getID()Retrieves the OID for this control.byte[]getValue()Retrieves the value for this control, if available.booleanIndicates whether this control is marked critical.final ControlConverts this LDAP control to aControlobject.static Control[]toControls(LDAPControl[] ldapControls) Converts the provided array of controls to an array of LDAP controls.static LDAPControl[]toLDAPControls(Control[] controls) Converts the provided array of LDAP controls to an array of controls.toString()Retrieves a string representation of this control.
-
Field Details
-
MANAGEDSAIT
The OID for the ManageDsaIT request control.- See Also:
-
PWEXPIRED
The OID for the password expired control.- See Also:
-
PWEXPIRING
The OID for the password expiring control.- See Also:
-
-
Constructor Details
-
LDAPControl
Creates a new LDAP control from the provided control.- Parameters:
control- The control to use to create this control.
-
LDAPControl
Creates a new LDAP control with the specified information.- Parameters:
id- The OID for the control.critical- Indicates whether the control should be marked critical.vals- The encoded value for the control.
-
-
Method Details
-
getID
Retrieves the OID for this control.- Returns:
- The OID for this control.
-
isCritical
Indicates whether this control is marked critical.- Returns:
trueif this control is marked critical, orfalseif not.
-
getValue
Retrieves the value for this control, if available.- Returns:
- The value for this control, or
nullif there is none.
-
toControl
Converts this LDAP control to aControlobject.- Returns:
- The
Controlobject for this LDAP control.
-
toControls
Converts the provided array of controls to an array of LDAP controls.- Parameters:
ldapControls- The LDAP controls to be converted.- Returns:
- The corresponding array of controls.
-
toLDAPControls
Converts the provided array of LDAP controls to an array of controls.- Parameters:
controls- The controls to be converted.- Returns:
- The corresponding array of LDAP controls.
-
duplicate
Creates a duplicate of this control.- Returns:
- A duplicate of this control.
-
toString
Retrieves a string representation of this control.
-