Class Http2Route
java.lang.Object
io.helidon.webserver.http2.Http2Route
- All Implemented Interfaces:
HttpRoute, Route, ServerLifecycle
A route for HTTP/2 only.
To create a route valid for any version of HTTP, please use
HttpRoute or methods
defined on HttpRouting.Builder.-
Nested Class Summary
Nested classes/interfaces inherited from interface HttpRoute
HttpRoute.Builder -
Method Summary
Modifier and TypeMethodDescriptionaccepts(HttpPrologue prologue) Whether this route accept the provided request.voidAfter server stop.voidBefore server start.handler()Handler of this route.Path matcher for this HTTP route.static Http2RouteCreate a new HTTP/2 only route.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface HttpRoute
acceptsModifier and TypeMethodDescriptiondefault PathMatchers.MatchResultaccepts(HttpPrologue prologue, ServerRequestHeaders headers) Whether this route accept the provided request.Methods inherited from interface ServerLifecycle
afterStartModifier and TypeMethodDescriptiondefault voidafterStart(WebServer webServer) After server start.
-
Method Details
-
route
Create a new HTTP/2 only route.- Parameters:
method- method to handlepath- path patternhandler- handler- Returns:
- a new route
-
accepts
Description copied from interface:HttpRouteWhether this route accept the provided request. -
handler
-
beforeStart
public void beforeStart()Description copied from interface:ServerLifecycleBefore server start. If this method throws an exception, server startup fails and the server attempts startup cleanup.- Specified by:
beforeStartin interfaceServerLifecycle
-
afterStop
public void afterStop()Description copied from interface:ServerLifecycleAfter server stop. Exceptions thrown by this method failWebServer.stop()after listener cleanup has been attempted. If this method is invoked during startup cleanup, exceptions may failWebServer.start(). If this method is invoked during suspend or resume failure cleanup, exceptions may be suppressed on the original suspend or resume failure.- Specified by:
afterStopin interfaceServerLifecycle
-
pathMatcher
Description copied from interface:HttpRoutePath matcher for this HTTP route.- Specified by:
pathMatcherin interfaceHttpRoute- Returns:
- optional path matcher
-