Package org.opends.server.controls
Class ReplicatedRequestControl
java.lang.Object
org.opends.server.controls.ReplicatedRequestControl
- All Implemented Interfaces:
Control
Control that provides some replication context to requests.
The replication context provides a CSN, an entry UUID and an additional UUID.
Note: the use of this control was the fastest way to make things work. This should be only a temporary solution until we find a better way to handle this. To get a better idea of the issue:
- before, we had an operation, which allow to add attachments.
- now, with a request, there is no easy way to provide additional information.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ControlDecoder<ReplicatedRequestControl>The Control Decoder that can be used to decode this control.static final StringOID of the replication context control. -
Constructor Summary
ConstructorsConstructorDescriptionReplicatedRequestControl(boolean isCritical, CSN csn, UUID entryUuid) Constructs a new control.ReplicatedRequestControl(boolean isCritical, CSN csn, UUID entryUuid, UUID parentUuid) Constructs a new control. -
Method Summary
Modifier and TypeMethodDescriptionbooleangetAlias()Returns the control "friendly name" alias for the control.getCSN()Returns the CSN.Returns the entry UUID.getOid()Returns the numeric OID associated with this control.Returns the additional UUID.static ReplicatedRequestControlgetReplicatedRequestControl(Request request) Returns the replicated request control from the provided request.getValue()Returns the value, if any, associated with this control.inthashCode()booleanhasValue()Returnstrueif this control has a value.booleanReturnstrueif it is unacceptable to perform the operation without applying the semantics of this control.Convert this control to anAddContext.Convert this control to aDeleteContext.Convert this control to aModifyContext.Convert this control to aModifyDnContext.toString()
-
Field Details
-
OID
OID of the replication context control.- See Also:
-
DECODER
The Control Decoder that can be used to decode this control.
-
-
Constructor Details
-
ReplicatedRequestControl
Constructs a new control.- Parameters:
isCritical- Indicates whether support for this control should be considered a critical part of the server processing.csn- the non-nullCSN.entryUuid- the non-nullUUID of the entry.parentUuid- the parent UUID that may be provided for Add and ModifyDN requests
-
ReplicatedRequestControl
Constructs a new control.- Parameters:
isCritical- Indicates whether support for this control should be considered a critical part of the server processing.csn- the non-nullCSN.entryUuid- the non-nullUUID of the entry.
-
-
Method Details
-
getReplicatedRequestControl
Returns the replicated request control from the provided request.- Parameters:
request- The request- Returns:
- the replicated request control or
nullif there is none
-
getOid
Description copied from interface:ControlReturns the numeric OID associated with this control. -
toAddContext
Convert this control to anAddContext.- Returns:
- the add context
-
toDeleteContext
Convert this control to aDeleteContext.- Returns:
- the delete context
-
toModifyContext
Convert this control to aModifyContext.- Returns:
- the modify context
-
toModifyDNContext
Convert this control to aModifyDnContext.- Returns:
- the modify Dn context
-
getValue
Description copied from interface:ControlReturns 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:ControlReturnstrueif 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. -
getCSN
Returns the CSN.- Returns:
- the non-
nullCSN
-
getEntryUuid
Returns the entry UUID.- Returns:
- the non-
nullentry UUID
-
getParentUuid
Returns the additional UUID.- Returns:
- the additional UUID
-
isCritical
public boolean isCritical()Description copied from interface:ControlReturnstrueif 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 oftrueindicates that it is unacceptable to perform the operation without applying the semantics of the control.- Specified by:
isCriticalin interfaceControl- Returns:
trueif this control must be processed by the Directory Server, orfalseif it can be ignored.
-
equals
-
hashCode
public int hashCode() -
toString
-
getAlias
Description copied from interface:ControlReturns the control "friendly name" alias for the control.
-