Class WSURI
- java.lang.Object
-
- org.eclipse.jetty.websocket.api.util.WSURI
-
public final class WSURI extends java.lang.ObjectUtility methods for converting aURIbetween an HTTP(S) and WS(S) URI.
-
-
Constructor Summary
Constructors Constructor Description WSURI()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.net.URItoHttp(java.net.URI inputUri)Convert to HTTPhttporhttpsscheme URIs.static java.net.URItoWebsocket(java.lang.CharSequence inputUrl)Convert to WebSocketwsorwssscheme URIsstatic java.net.URItoWebsocket(java.lang.CharSequence inputUrl, java.lang.String query)Convert to WebSocketwsorwssscheme URIsstatic java.net.URItoWebsocket(java.net.URI inputUri)Convert to WebSocketwsorwssscheme URIs
-
-
-
Method Detail
-
toHttp
public static java.net.URI toHttp(java.net.URI inputUri) throws java.net.URISyntaxExceptionConvert to HTTPhttporhttpsscheme URIs.Converting
wsandwssURIs to their HTTP equivalent- Parameters:
inputUri- the input URI- Returns:
- the HTTP scheme URI for the input URI.
- Throws:
java.net.URISyntaxException- if unable to convert the input URI
-
toWebsocket
public static java.net.URI toWebsocket(java.lang.CharSequence inputUrl) throws java.net.URISyntaxExceptionConvert to WebSocketwsorwssscheme URIsConverting
httpandhttpsURIs to their WebSocket equivalent- Parameters:
inputUrl- the input URI- Returns:
- the WebSocket scheme URI for the input URI.
- Throws:
java.net.URISyntaxException- if unable to convert the input URI
-
toWebsocket
public static java.net.URI toWebsocket(java.lang.CharSequence inputUrl, java.lang.String query) throws java.net.URISyntaxExceptionConvert to WebSocketwsorwssscheme URIsConverting
httpandhttpsURIs to their WebSocket equivalent- Parameters:
inputUrl- the input URIquery- the optional query string- Returns:
- the WebSocket scheme URI for the input URI.
- Throws:
java.net.URISyntaxException- if unable to convert the input URI
-
toWebsocket
public static java.net.URI toWebsocket(java.net.URI inputUri) throws java.net.URISyntaxExceptionConvert to WebSocketwsorwssscheme URIsConverting
httpandhttpsURIs to their WebSocket equivalent- Parameters:
inputUri- the input URI- Returns:
- the WebSocket scheme URI for the input URI.
- Throws:
java.net.URISyntaxException- if unable to convert the input URI
-
-