Class UserContentCacheObserver
java.lang.Object
org.ametys.runtime.plugin.component.AbstractLogEnabled
org.ametys.plugins.userdirectory.observation.AbstractContentObserver
org.ametys.plugins.userdirectory.observation.UserContentCacheObserver
- All Implemented Interfaces:
 Observer,LogEnabled,Contextualizable,Serviceable
Observer when a user content is modified, deleted or validated.
 Clear the cache of virtual user pages and reindex all virtual pages on modification.- 
Field Summary
FieldsModifier and TypeFieldDescriptionprotected SynchronizableContentsCollectionDAOThe DAO for synchronizable contents collectionsprotected UserDirectoryHelperThe user directory helperprotected UserDirectoryPageHandlerThe user directory page handler.Fields inherited from class org.ametys.plugins.userdirectory.observation.AbstractContentObserver
_cocoonContext, _contentTypeHelper, _context, _organisationChartPageResolver, _resolver, _userDirectoryPageResolver, _zoneItemCacheFields inherited from interface org.ametys.core.observation.Observer
MAX_PRIORITY, MIN_PRIORITY - 
Constructor Summary
Constructors - 
Method Summary
Modifier and TypeMethodDescriptionprotected void_internalObserve(Event event, Page rootUsersPage, Content userContent) Do the actual work.intgetPriority(Event event) Retrieves the priority to observe this event.
This can be used to process a supported event before others observers.voidservice(ServiceManager manager) booleanChecks if the event is supported.Methods inherited from class org.ametys.plugins.userdirectory.observation.AbstractContentObserver
_getOrgUnitRootPages, _getTarget, _getUserRootPages, _isOrgUnitContent, _isUserContent, _removeZoneItemCache, contextualize, observeMethods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger 
- 
Field Details
- 
_userPageHandler
The user directory page handler. - 
_synchronizableContentsCollectionDAO
The DAO for synchronizable contents collections - 
_userDirectoryHelper
The user directory helper 
 - 
 - 
Constructor Details
- 
UserContentCacheObserver
public UserContentCacheObserver() 
 - 
 - 
Method Details
- 
service
- Specified by:
 servicein interfaceServiceable- Overrides:
 servicein classAbstractContentObserver- Throws:
 ServiceException
 - 
supports
Description copied from interface:ObserverChecks if the event is supported. If true, the observe(Event) method will be called.- Parameters:
 event- the event.- Returns:
 truefor observing this event,falseotherwise.
 - 
getPriority
Description copied from interface:ObserverRetrieves the priority to observe this event.
This can be used to process a supported event before others observers.- Parameters:
 event- the event.- Returns:
 - the priority where 0 the max priority and Integer.MAX_VALUE the min priority.
 
 - 
_internalObserve
Description copied from class:AbstractContentObserverDo the actual work.- Specified by:
 _internalObservein classAbstractContentObserver- Parameters:
 event- the observation event.rootUsersPage- the page holding the virtual user pagesuserContent- a list containing all impacted user contents.
 
 -