public static WebsocketClientTransport create(URI uri) {
    Objects.requireNonNull(uri, "uri must not be null");

    TcpClient client = createClient(uri);
    return create(HttpClient.from(client), uri.getPath());
  }
public static WebsocketClientTransport create ( URI uri ) { Objects . requireNonNull ( uri , "uri must not be null" ) ; TcpClient client = createClient ( uri ) ; return create ( HttpClient . from ( client ) , uri . getPath ( ) ) ; }
Creates a new instance

@param uri the URI to connect to
@return a new instance
@throws NullPointerException if {@code uri} is {@code null}