Enum HttpRouteMethod
- All Implemented Interfaces:
Serializable
,Comparable<HttpRouteMethod>
,java.lang.constant.Constable
@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)",
date="2023-06-19T16:30:46.096Z")
@Stability(Stable)
public enum HttpRouteMethod
extends Enum<HttpRouteMethod>
Supported values for matching routes based on the HTTP request method.
Example:
VirtualRouter router; VirtualNode node; router.addRoute("route-http2", RouteBaseProps.builder() .routeSpec(RouteSpec.http2(HttpRouteSpecOptions.builder() .weightedTargets(List.of(WeightedTarget.builder() .virtualNode(node) .build())) .match(HttpRouteMatch.builder() .path(HttpRoutePathMatch.exactly("/exact")) .method(HttpRouteMethod.POST) .protocol(HttpRouteProtocol.HTTPS) .headers(List.of(HeaderMatch.valueIs("Content-Type", "application/json"), HeaderMatch.valueIsNot("Content-Type", "application/json"))) .queryParameters(List.of(QueryParameterMatch.valueIs("query-field", "value"))) .build()) .build())) .build());
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic HttpRouteMethod
Returns the enum constant of this type with the specified name.static HttpRouteMethod[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
GET
GET request. -
HEAD
HEAD request. -
POST
POST request. -
PUT
PUT request. -
DELETE
DELETE request. -
CONNECT
CONNECT request. -
OPTIONS
OPTIONS request. -
TRACE
TRACE request. -
PATCH
PATCH request.
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-