public interface WebSocketServerFactory extends WebSocketFactory
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Allows to shutdown the websocket factory for a clean shutdown
|
WebSocketImpl |
createWebSocket(WebSocketAdapter a,
Draft d)
Create a new Websocket with the provided listener, drafts and socket
|
WebSocketImpl |
createWebSocket(WebSocketAdapter a,
List<Draft> drafts)
Create a new Websocket with the provided listener, drafts and socket
|
ByteChannel |
wrapChannel(SocketChannel channel,
SelectionKey key)
Allows to wrap the SocketChannel( key.channel() ) to insert a protocol layer( like ssl or proxy
authentication) beyond the ws layer.
|
WebSocketImpl createWebSocket(WebSocketAdapter a, Draft d)
WebSocketFactorycreateWebSocket in interface WebSocketFactorya - The Listener for the WebsocketImpld - The draft which should be usedWebSocketImpl createWebSocket(WebSocketAdapter a, List<Draft> drafts)
WebSocketFactorycreateWebSocket in interface WebSocketFactorya - The Listener for the WebsocketImpldrafts - The drafts which should be usedByteChannel wrapChannel(SocketChannel channel, SelectionKey key) throws IOException
channel - The SocketChannel to wrapkey - a SelectionKey of an open SocketChannel.IOException - may be thrown while writing on the channelvoid close()
Copyright © 2021. All rights reserved.