java.lang.Object
org.omnifaces.cdi.viewscope.ViewScopeEventListener
- All Implemented Interfaces:
FacesListener,SystemEventListener,ViewMapListener,EventListener
Listener for Faces view scope destroy events so that view scope manager can be notified.
- Since:
- 1.6
- Author:
- Bauke Scholtz
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanisListenerForSource(Object source) Returnstrueif given source is an instance ofUIViewRoot.voidprocessEvent(SystemEvent event) If the event is an instance ofPreDestroyViewMapEvent, which means that the Faces view scope is about to be destroyed, then find the current instance ofViewScopeManagerand invoke itsViewScopeManager.preDestroyView()method.
-
Constructor Details
-
ViewScopeEventListener
public ViewScopeEventListener()
-
-
Method Details
-
isListenerForSource
Returnstrueif given source is an instance ofUIViewRoot.- Specified by:
isListenerForSourcein interfaceSystemEventListener
-
processEvent
If the event is an instance ofPreDestroyViewMapEvent, which means that the Faces view scope is about to be destroyed, then find the current instance ofViewScopeManagerand invoke itsViewScopeManager.preDestroyView()method.- Specified by:
processEventin interfaceSystemEventListener
-