Class RelaxRulesRequestControl
java.lang.Object
org.forgerock.opendj.ldap.controls.RelaxRulesRequestControl
- All Implemented Interfaces:
Control
The internet-draft defined Relax Rules control.
The OID for this control is IANA-assigned, and since this is not an RFC yet, the OID hasn't been
officially assigned. An OID (1.3.6.1.4.1.4203.666.5.12) was allocated by OpenLDAP under its experimental arc,
which means that it's subject to future change.
The control is always critical and does not have a value.
This control can be used with all LDAP update requests: Add, Delete, Modify, ModifyDN. It changes the behavior of the operation as follows:
- Object metamorphism. Attempts to modify the structural objectclass of an entry will not fail with the objectClassModsProhibited error (as it should according to RFC 4511).
- Inactive Attribute Type. Attempts to add or modify an attribute that is marked in the schema as OBSOLETE will not fail.
- DIT Content Rules. Attempts to add an Auxiliary objectClass or an attribute will succeed as if the DIT Content Rule allowed any and all known auxiliary classes, and allowed any and all known attributes.
- DIT Structure Rules and Name Forms are ignored when performing the update.
- Modification of Nonconformant Objects. Attempts to modify an entry that does not conform to the schema will be accepted regardless of the resulting entry conforming to the schema or not.
- NO-USER-MODIFICATION attribute modification. Attempts to modify specific read-only operational attributes will succeed. The following attributes are allowed with this control: entryUUID, modifyTimestamp, createTimestamp, modifiersName, creatorsName. Operational attributes whose values are derived from others or computed by the server must not be allowed to be modified (such as subSchemaSubentry, structuralObjectClass...).
String entryDN = ...; Connection connection = ...; // Change the modifyTimestamp, telling the directory server not to // complain that the attribute is read-only. ModifyRequest request = Requests.newModifyRequest(entryDN) .addControl(RelaxRulesRequestControl.newControl()) .addModification(ModificationType.REPLACE, "modifyTimestamp", "20010101000000Z"); connection.modify(request);
-
Field Summary
Modifier and TypeFieldDescriptionThe user-friendly aliases for the Relax Rules request control.static final ControlDecoder<RelaxRulesRequestControl>
A decoder which can be used for decoding the permissive modify request control.static final String
The OpenLDAP OID for the Relax Rules request control. -
Method Summary
Modifier and TypeMethodDescriptiongetAlias()
Returns the control "friendly name" alias for the control.getOid()
Returns the numeric OID associated with this control.getValue()
Returns the value, if any, associated with this control.boolean
hasValue()
Returnstrue
if this control has a value.boolean
Returnstrue
if it is unacceptable to perform the operation without applying the semantics of this control.static RelaxRulesRequestControl
Creates a new permissive modify request control.toString()
-
Field Details
-
OID
The OpenLDAP OID for the Relax Rules request control.- See Also:
-
ALIASES
The user-friendly aliases for the Relax Rules request control. -
DECODER
A decoder which can be used for decoding the permissive modify request control.
-
-
Method Details
-
newControl
Creates a new permissive modify request control.- Returns:
- The new control.
-
getOid
Description copied from interface:Control
Returns the numeric OID associated with this control. -
getValue
Description copied from interface:Control
Returns the value, if any, associated with this control. Its format is defined by the specification of this control. -
hasValue
public boolean hasValue()Description copied from interface:Control
Returnstrue
if this control has a value. In some circumstances it may be useful to determine if a control has a value, without actually calculating the value and incurring any performance costs. -
isCritical
public boolean isCritical()Description copied from interface:Control
Returnstrue
if it is unacceptable to perform the operation without applying the semantics of this control.The criticality field only has meaning in controls attached to request messages (except UnbindRequest). For controls attached to response messages and the UnbindRequest, the criticality field SHOULD be
false
, and MUST be ignored by the receiving protocol peer. A value oftrue
indicates that it is unacceptable to perform the operation without applying the semantics of the control.- Specified by:
isCritical
in interfaceControl
- Returns:
true
if this control must be processed by the Directory Server, orfalse
if it can be ignored.
-
toString
-
getAlias
Description copied from interface:Control
Returns the control "friendly name" alias for the control.
-