Package org.opends.server.controls
Class PersistentSearchControl
- java.lang.Object
-
- org.opends.server.types.Control
-
- org.opends.server.controls.PersistentSearchControl
-
public class PersistentSearchControl extends Control
This class implements the persistent search control defined in draft-ietf-ldapext-psearch. It makes it possible for clients to be notified of changes to information in the Directory Server as they occur.
-
-
Field Summary
Fields Modifier and Type Field Description static ControlDecoder<PersistentSearchControl>DECODERThe Control Decoder that can be used to decode this control.
-
Constructor Summary
Constructors Constructor Description PersistentSearchControl(boolean isCritical, Set<PersistentSearchChangeType> changeTypes, boolean changesOnly, boolean returnECs)Creates a new persistent search control with the provided information.PersistentSearchControl(Set<PersistentSearchChangeType> changeTypes, boolean changesOnly, boolean returnECs)Creates a new persistent search control with the provided information.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleangetChangesOnly()Indicates whether to only return changes that match the associated search criteria, or to also return all existing entries that match the filter.Set<PersistentSearchChangeType>getChangeTypes()Retrieves the set of change types for this persistent search control.booleangetReturnECs()Indicates whether to include the entry change notification control in entries returned to the client as the result of a change in the Directory Server data.voidtoString(StringBuilder buffer)Appends a string representation of this persistent search control to the provided buffer.protected voidwriteValue(ASN1Writer writer)Writes this control's value to an ASN.1 writer.-
Methods inherited from class org.opends.server.types.Control
getOID, isCritical, toString, write
-
-
-
-
Field Detail
-
DECODER
public static final ControlDecoder<PersistentSearchControl> DECODER
The Control Decoder that can be used to decode this control.
-
-
Constructor Detail
-
PersistentSearchControl
public PersistentSearchControl(Set<PersistentSearchChangeType> changeTypes, boolean changesOnly, boolean returnECs)
Creates a new persistent search control with the provided information.- Parameters:
changeTypes- The set of change types for which to provide notification to the client.changesOnly- Indicates whether to only return changes that match the associated search criteria, or to also return all existing entries that match the filter.returnECs- Indicates whether to include the entry change notification control in updated entries that match the associated search criteria.
-
PersistentSearchControl
public PersistentSearchControl(boolean isCritical, Set<PersistentSearchChangeType> changeTypes, boolean changesOnly, boolean returnECs)Creates a new persistent search control with the provided information.- Parameters:
isCritical- Indicates whether the control should be considered critical for the operation processing.changeTypes- The set of change types for which to provide notification to the client.changesOnly- Indicates whether to only return changes that match the associated search criteria, or to also return all existing entries that match the filter.returnECs- Indicates whether to include the entry change notification control in updated entries that match the associated search criteria.
-
-
Method Detail
-
writeValue
protected void writeValue(ASN1Writer writer) throws IOException
Writes this control's value to an ASN.1 writer. The value (if any) must be written as an ASN1OctetString.- Specified by:
writeValuein classControl- Parameters:
writer- The ASN.1 writer to use.- Throws:
IOException- If a problem occurs while writing to the stream.
-
getChangeTypes
public Set<PersistentSearchChangeType> getChangeTypes()
Retrieves the set of change types for this persistent search control.- Returns:
- The set of change types for this persistent search control.
-
getChangesOnly
public boolean getChangesOnly()
Indicates whether to only return changes that match the associated search criteria, or to also return all existing entries that match the filter.- Returns:
trueif only changes to matching entries should be returned, orfalseif existing matches should also be included.
-
getReturnECs
public boolean getReturnECs()
Indicates whether to include the entry change notification control in entries returned to the client as the result of a change in the Directory Server data.- Returns:
trueif entry change notification controls should be included in applicable entries, orfalseif not.
-
toString
public void toString(StringBuilder buffer)
Appends a string representation of this persistent search control to the provided buffer.
-
-