| Modifier and Type | Field and Description |
|---|---|
| protected boolean | |
| protected Set | |
| private static final byte[] | |
| private final String | |
| private final String | |
| private static final Pattern | |
| protected final Set | |
| private final WebSocketVersion |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| public final void | addExtension(ExtensionHandshake
a new extension)ExtensionHandshakeAdd a new WebSocket Extension handshake to the list of available extensions. |
| public abstract WebSocketChannel | createChannel(WebSocketHttpExchange exchange, final StreamConnection channel, final ByteBufferPool pool)
Create the |
| public String | |
| public String | |
| public WebSocketVersion | |
| protected static String | getWebSocketLocation(WebSocketHttpExchange exchange)
Return the full url of the websocket location of the given |
| public final void | handshake(final WebSocketHttpExchange
The exchange)WebSocketHttpExchange for which the handshake and upgrade should occur.Issue the WebSocket upgrade |
| protected abstract void | |
| protected final List | Returns: a list ofExtensionFunction with the implementation of the extensionsthe exchange used to retrieve negotiated extensions exchange)Create the |
| public abstract boolean | matches(WebSocketHttpExchange exchange)
Return |
| protected final void | performUpgrade(final WebSocketHttpExchange exchange, final byte[] data)
convenience method to perform the upgrade |
| protected final void | |
| protected List | |
| protected final void | |
| protected final void | selectSubprotocol(final WebSocketHttpExchange exchange)
Selects the first matching supported sub protocol and add it the the headers of the exchange. |
| protected String | |
| protected void | |
| private static void |
| allowExtensions | back to summary |
|---|---|
| protected boolean allowExtensions | |
| availableExtensions | back to summary |
|---|---|
| protected Set<ExtensionHandshake> availableExtensions | |
| EMPTY | back to summary |
|---|---|
| private static final byte[] EMPTY | |
| hashAlgorithm | back to summary |
|---|---|
| private final String hashAlgorithm | |
| magicNumber | back to summary |
|---|---|
| private final String magicNumber | |
| PATTERN | back to summary |
|---|---|
| private static final Pattern PATTERN | |
| subprotocols | back to summary |
|---|---|
| protected final Set<String> subprotocols | |
| version | back to summary |
|---|---|
| private final WebSocketVersion version | |
| Handshake | back to summary |
|---|---|
| protected Handshake(WebSocketVersion version, String hashAlgorithm, String magicNumber, final Set<String> subprotocols) | |
| addExtension | back to summary |
|---|---|
| public final void addExtension(ExtensionHandshake extension) Add a new WebSocket Extension handshake to the list of available extensions.
| |
| createChannel | back to summary |
|---|---|
| public abstract WebSocketChannel createChannel(WebSocketHttpExchange exchange, final StreamConnection channel, final ByteBufferPool pool) Create the | |
| getHashAlgorithm | back to summary |
|---|---|
| public String getHashAlgorithm() Return the algorithm that is used to hash during the handshake | |
| getMagicNumber | back to summary |
|---|---|
| public String getMagicNumber() Return the magic number which will be mixed in | |
| getVersion | back to summary |
|---|---|
| public WebSocketVersion getVersion() Return the version for which the | |
| getWebSocketLocation | back to summary |
|---|---|
| protected static String getWebSocketLocation(WebSocketHttpExchange exchange) Return the full url of the websocket location of the given | |
| handshake | back to summary |
|---|---|
| public final void handshake(final WebSocketHttpExchange exchange) Issue the WebSocket upgrade
| |
| handshakeInternal | back to summary |
|---|---|
| protected abstract void handshakeInternal(final WebSocketHttpExchange exchange) | |
| initExtensions | back to summary |
|---|---|
| protected final List Create the
| |
| matches | back to summary |
|---|---|
| public abstract boolean matches(WebSocketHttpExchange exchange) Return | |
| performUpgrade | back to summary |
|---|---|
| protected final void performUpgrade(final WebSocketHttpExchange exchange, final byte[] data) convenience method to perform the upgrade | |
| performUpgrade | back to summary |
|---|---|
| protected final void performUpgrade(final WebSocketHttpExchange exchange) Perform the upgrade using no payload | |
| selectedExtension | back to summary |
|---|---|
| protected List | |
| selectExtensions | back to summary |
|---|---|
| protected final void selectExtensions(final WebSocketHttpExchange exchange) | |
| selectSubprotocol | back to summary |
|---|---|
| protected final void selectSubprotocol(final WebSocketHttpExchange exchange) Selects the first matching supported sub protocol and add it the the headers of the exchange. | |
| supportedSubprotols | back to summary |
|---|---|
| protected String supportedSubprotols(String[] requestedSubprotocolArray) | |
| upgradeChannel | back to summary |
|---|---|
| protected void upgradeChannel(final WebSocketHttpExchange exchange, final byte[] data) | |
| writePayload | back to summary |
|---|---|
| private static void writePayload(final WebSocketHttpExchange exchange, final ByteBuffer payload) | |