public class ConfigChangeListener extends DirectoryListenerAdapter
| Modifier and Type | Field and Description |
|---|---|
private ConfigPartitionReader |
cpReader
the config parition reader
|
private DirectoryService |
directoryService
the directory service
|
private static org.slf4j.Logger |
LOG
The logger for this class
|
private org.apache.directory.api.ldap.model.entry.Attribute |
passwordPolicyObjectClassAttribute |
private static java.lang.String |
PPOLICY_OC_NAME |
private PpolicyConfigContainer |
ppolicyConfigContainer
container holding the current active password policy configurations
|
private org.apache.directory.api.ldap.model.name.Dn |
ppolicyConfigDnRoot
the root DN of password policy configurations
|
| Constructor and Description |
|---|
ConfigChangeListener(ConfigPartitionReader cpReader,
DirectoryService directoryService)
Creates a new instance of ConfigChangeListener.
|
| Modifier and Type | Method and Description |
|---|---|
void |
entryAdded(AddOperationContext addContext)
Called when an entry has been added.
|
void |
entryDeleted(DeleteOperationContext deleteContext)
Called when an entry has been deleted.
|
void |
entryModified(ModifyOperationContext modifyContext)
Called when an entry has been modified.
|
private void |
updatePasswordPolicy(org.apache.directory.api.ldap.model.entry.Entry entry,
boolean deleted)
Updates the password policy represented by the given configuration entry
|
entryMoved, entryMovedAndRenamed, entryRenamed, isSynchronousprivate ConfigPartitionReader cpReader
private DirectoryService directoryService
private PpolicyConfigContainer ppolicyConfigContainer
private org.apache.directory.api.ldap.model.name.Dn ppolicyConfigDnRoot
private static final java.lang.String PPOLICY_OC_NAME
private org.apache.directory.api.ldap.model.entry.Attribute passwordPolicyObjectClassAttribute
private static final org.slf4j.Logger LOG
public ConfigChangeListener(ConfigPartitionReader cpReader, DirectoryService directoryService) throws org.apache.directory.api.ldap.model.exception.LdapException
cpReader - the configuration readerdirectoryService - the DirectoryService instanceorg.apache.directory.api.ldap.model.exception.LdapExceptionpublic void entryAdded(AddOperationContext addContext)
DirectoryListenerentryAdded in interface DirectoryListenerentryAdded in class DirectoryListenerAdapteraddContext - the add operation context responsible for the changepublic void entryDeleted(DeleteOperationContext deleteContext)
DirectoryListenerentryDeleted in interface DirectoryListenerentryDeleted in class DirectoryListenerAdapterdeleteContext - the delete operation context responsible for the changepublic void entryModified(ModifyOperationContext modifyContext)
DirectoryListenerentryModified in interface DirectoryListenerentryModified in class DirectoryListenerAdaptermodifyContext - the modify operation context responsible for the changeprivate void updatePasswordPolicy(org.apache.directory.api.ldap.model.entry.Entry entry,
boolean deleted)
entry - the password policy configuration entrydeleted - flag to detect if this is a deleted entry