Class InvalidateCacheOnDisplayedContentValidationObserver
java.lang.Object
org.ametys.runtime.plugin.component.AbstractLogEnabled
org.ametys.plugins.userdirectory.observation.InvalidateCacheOnDisplayedContentValidationObserver
- All Implemented Interfaces:
Observer
,LogEnabled
,Prioritizable
,Supporter<Event>
,Serviceable
public class InvalidateCacheOnDisplayedContentValidationObserver
extends AbstractLogEnabled
implements Observer, Serviceable
Observer
for observing user content validation, for content that are displayed, in order to invalidate cache on front-office.-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected CacheInvalidationPolicy
Cache invalidation policyprotected ContentTypesHelper
The content types helperprotected AmetysObjectResolver
The Ametys object resolverFields inherited from interface org.ametys.core.observation.Observer
MAX_PRIORITY, MIN_PRIORITY
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription_getSitesWhereUserContentIsDisplayed
(String contentId) Get the sites where the user is displayedint
Get the priority for the component.void
Observes an event.void
service
(ServiceManager manager) boolean
Check if an element is supportedMethods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
Field Details
-
_cachePolicy
Cache invalidation policy -
_contentTypesHelper
The content types helper -
_resolver
The Ametys object resolver
-
-
Constructor Details
-
InvalidateCacheOnDisplayedContentValidationObserver
-
-
Method Details
-
service
- Specified by:
service
in interfaceServiceable
- Throws:
ServiceException
-
supports
Description copied from interface:Supporter
Check if an element is supported -
_getSitesWhereUserContentIsDisplayed
Get the sites where the user is displayed- Parameters:
contentId
- The Id of the user content- Returns:
- The list of sites
-
getPriority
Description copied from interface:Prioritizable
Get the priority for the component. On components usingPrioritizable
interface, each implementation define the order. In most cases, less is the number, more prior is the component.- Specified by:
getPriority
in interfacePrioritizable
- Returns:
- the priority
-
observe
Description copied from interface:Observer
Observes an event.
-