Interface PreOperationModifyOperation
-
- All Superinterfaces:
PluginOperation
,PreOperationOperation
- All Known Implementing Classes:
ModifyOperation
@PublicAPI(stability=UNCOMMITTED, mayInstantiate=false, mayExtend=false, mayInvoke=true) public interface PreOperationModifyOperation extends PreOperationOperation
This class defines a set of methods that are available for use by pre-operation plugins for modify operations. Note that this interface is intended only to define an API for use by plugins and is not intended to be implemented by any custom classes.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
addModification(Modification modification)
Adds the provided modification to the set of modifications to this modify operation.Entry
getCurrentEntry()
Retrieves the current entry before any modifications are applied.List<ByteString>
getCurrentPasswords()
Retrieves the set of clear-text current passwords for the user, if available.Dn
getEntryDN()
Retrieves the DN of the entry to modify.List<Modification>
getModifications()
Retrieves the set of modifications for this modify operation.Entry
getModifiedEntry()
Retrieves the modified entry that is to be written to the backend.List<ByteString>
getNewPasswords()
Retrieves the set of clear-text new passwords for the user, if available.-
Methods inherited from interface org.opends.server.types.operation.PluginOperation
checkIfCanceled, disconnectClient, getAttachment, getAttachments, getClientConnection, getConnectionID, getMessageID, getOperationID, getOperationType, getRequestControl, getRequestControl, getRequestControls, getResponseControls, isInternalOperation, isSynchronizationOperation, removeAttachment, setAttachment, toString, toString
-
Methods inherited from interface org.opends.server.types.operation.PreOperationOperation
addAdditionalLogItem, addResponseControl, appendErrorMessage, getAdditionalLogItems, getAuthorizationDN, getErrorMessage, removeResponseControl, setErrorMessage
-
-
-
-
Method Detail
-
getEntryDN
Dn getEntryDN()
Retrieves the DN of the entry to modify.- Returns:
- The DN of the entry to modify.
-
getModifications
List<Modification> getModifications()
Retrieves the set of modifications for this modify operation. Its contents should not be altered.- Returns:
- The set of modifications for this modify operation.
-
addModification
void addModification(Modification modification) throws LdapException
Adds the provided modification to the set of modifications to this modify operation. Note that this will be called after the schema and access control processing, so the caller must be careful to avoid making any changes that will violate schema or access control constraints.- Parameters:
modification
- The modification to add to the set of changes for this modify operation.- Throws:
LdapException
- If an unexpected problem occurs while applying the modification to the entry.
-
getCurrentEntry
Entry getCurrentEntry()
Retrieves the current entry before any modifications are applied. It should not be modified by the caller.- Returns:
- The current entry before any modifications are applied.
-
getModifiedEntry
Entry getModifiedEntry()
Retrieves the modified entry that is to be written to the backend. This entry should not be modified directly, but should only be altered through theaddModification
method.- Returns:
- The modified entry that is to be written to the backend.
-
getCurrentPasswords
List<ByteString> getCurrentPasswords()
Retrieves the set of clear-text current passwords for the user, if available. This will only be available if the modify operation contains one or more delete elements that target the password attribute and provide the values to delete in the clear. This list should not be altered by the caller.- Returns:
- The set of clear-text current password values as provided in the modify request, or
null
if there were none.
-
getNewPasswords
List<ByteString> getNewPasswords()
Retrieves the set of clear-text new passwords for the user, if available. This will only be available if the modify operation contains one or more add or replace elements that target the password attribute and provide the values in the clear. This list should not be altered by the caller.- Returns:
- The set of clear-text new passwords as provided in the modify request, or
null
if there were none.
-
-