Class ConnectionManager
java.lang.Object
io.quarkus.websockets.next.runtime.ConnectionManager
- All Implemented Interfaces:
OpenConnections,Iterable<WebSocketConnection>
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionConnectionManager(jakarta.enterprise.event.Event<WebSocketConnection> openEvent, jakarta.enterprise.event.Event<WebSocketConnection> closedEvent) -
Method Summary
Modifier and TypeMethodDescription(package private) voidadd(String endpoint, WebSocketConnection connection) void(package private) voiddestroy()getConnections(String endpoint) iterator()(package private) voidremove(String endpoint, WebSocketConnection connection) stream()Returns the stream of all open connections at the given time.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliteratorMethods inherited from interface io.quarkus.websockets.next.OpenConnections
findByConnectionId, findByEndpointId, listAll
-
Constructor Details
-
ConnectionManager
ConnectionManager(@Open jakarta.enterprise.event.Event<WebSocketConnection> openEvent, @Closed jakarta.enterprise.event.Event<WebSocketConnection> closedEvent)
-
-
Method Details
-
iterator
- Specified by:
iteratorin interfaceIterable<WebSocketConnection>
-
stream
Description copied from interface:OpenConnectionsReturns the stream of all open connections at the given time.- Specified by:
streamin interfaceOpenConnections- Returns:
- the stream of open connections
-
add
-
remove
-
getConnections
- Parameters:
endpoint-- Returns:
- the connections for the given endpoint, never
null
-
addListener
-
destroy
@PreDestroy void destroy()
-