Interface MappedWebSocketCreator
- All Known Implementing Classes:
NativeWebSocketConfiguration,WebSocketUpgradeFilter,WebSocketUpgradeHandlerWrapper
public interface MappedWebSocketCreator
Common interface for MappedWebSocketCreator
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddMapping(String spec, WebSocketCreator creator) Add a mapping, of a pathspec to a WebSocketCreator.voidaddMapping(PathSpec spec, WebSocketCreator creator) Add a mapping.voidaddMapping(PathSpec spec, WebSocketCreator creator) Deprecated.getMapping(String spec) /** Returns the creator for the given path spec.booleanremoveMapping(String spec) Removes the mapping based on the given path spec.
-
Method Details
-
addMapping
Add a mapping, of a pathspec to a WebSocketCreator.Recognized Path Spec syntaxes
/path/toor/or*.extorservlet|{spec}- Servlet Syntax
^{spec}orregex|{spec}- Regex Syntax
uri-template|{spec}- URI Template (see JSR356 and RFC6570 level 1)
- Parameters:
spec- the path spec to use.creator- the websocket creator for this specific mapping
-
addMapping
Deprecated.useaddMapping(org.eclipse.jetty.http.pathmap.PathSpec, WebSocketCreator)instead. (support classes moved to generic jetty-http project)Add a mapping.- Parameters:
spec- the path spec to usecreator- the creator for the mapping
-
addMapping
Add a mapping.- Parameters:
spec- the path spec to usecreator- the creator for the mapping- Since:
- 9.2.20
-
getMapping
/** Returns the creator for the given path spec.- Parameters:
spec- the spec to test for (using the same spec syntax as seen inaddMapping(String, WebSocketCreator))- Returns:
- the websocket creator if path spec exists, or null
-
removeMapping
Removes the mapping based on the given path spec.- Parameters:
spec- the path spec to remove (using the same spec syntax as seen inaddMapping(String, WebSocketCreator))- Returns:
- true if underlying mapping were altered, false otherwise
-
addMapping(org.eclipse.jetty.http.pathmap.PathSpec, WebSocketCreator)instead.