- java.lang.Object
-
- org.omnifaces.cdi.push.SocketChannelManager.ViewScope
-
- All Implemented Interfaces:
Serializable
- Enclosing class:
- SocketChannelManager
@ViewScoped public static class SocketChannelManager.ViewScope extends Object implements Serializable
This helps the web socket channel manager to hold view scoped web socket channel identifiers registered by<o:socket>
.Since OmniFaces 4.6 this class is
public
instead ofprotected
so it can be externally registered into environment-specific CDI bean management facility.- Since:
- 2.3
- Author:
- Bauke Scholtz
- See Also:
SocketChannelManager
, Serialized Form
-
-
Constructor Summary
Constructors Constructor Description ViewScope()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
deregisterViewScope()
When current view scope is about to be destroyed, deregister all view scoped channels and explicitly close any open web sockets associated with it to avoid stale websockets.protected Map<String,String>
getChannels()
Returns the view scoped channels.
-
-
-
Method Detail
-
getChannels
protected Map<String,String> getChannels()
Returns the view scoped channels.- Returns:
- The view scoped channels.
-
deregisterViewScope
@PreDestroy protected void deregisterViewScope()
When current view scope is about to be destroyed, deregister all view scoped channels and explicitly close any open web sockets associated with it to avoid stale websockets.
-
-