public static WebSocketClientHandshaker newHandshaker(
            URI webSocketURL, WebSocketVersion version, String subprotocol,
            boolean allowExtensions, HttpHeaders customHeaders) {
        return newHandshaker(webSocketURL, version, subprotocol, allowExtensions, customHeaders, 65536);
    }
public static WebSocketClientHandshaker newHandshaker ( URI webSocketURL , WebSocketVersion version , String subprotocol , boolean allowExtensions , HttpHeaders customHeaders ) { return newHandshaker ( webSocketURL , version , subprotocol , allowExtensions , customHeaders , 65536 ) ; }
Creates a new handshaker.

@param webSocketURL
URL for web socket communications. e.g "ws://myhost.com/mypath".
Subsequent web socket frames will be sent to this URL.
@param version
Version of web socket specification to use to connect to the server
@param subprotocol
Sub protocol request sent to the server. Null if no sub-protocol support is required.
@param allowExtensions
Allow extensions to be used in the reserved bits of the web socket frame
@param customHeaders
Custom HTTP headers to send during the handshake