Package org.atmosphere.websocket
Class DefaultWebSocketFactory
java.lang.Object
org.atmosphere.websocket.DefaultWebSocketFactory
- All Implemented Interfaces:
WebSocketFactory
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
DefaultWebSocketFactory
public DefaultWebSocketFactory()
-
-
Method Details
-
find
Deprecated.Description copied from interface:WebSocketFactoryRetrieve theWebSocketassociated with a uuid. The uuid could be the one returned by theAtmosphereResource.uuid()or an application generated one.- Specified by:
findin interfaceWebSocketFactory- Parameters:
uuid- a UUID associated- Returns:
- WebSocket, or null if not found.
-
findWebSocket
Description copied from interface:WebSocketFactoryRetrieve theWebSocketassociated with a uuid. The uuid could be the one returned by theAtmosphereResource.uuid()or an application generated one.This is the preferred alternative to
WebSocketFactory.find(String)as it returns anOptionalinstead of null, making the absent-websocket case explicit at the call site.- Specified by:
findWebSocketin interfaceWebSocketFactory- Parameters:
uuid- a UUID associated- Returns:
- an
Optionalcontaining theWebSocket, or empty if not found.
-