Class HttpRouteKey
java.lang.Object
software.amazon.jsii.JsiiObject
software.amazon.awscdk.services.apigatewayv2.HttpRouteKey
- All Implemented Interfaces:
software.amazon.jsii.JsiiSerializable
@Generated(value="jsii-pacmak/1.103.1 (build bef2dea)",
date="2024-09-11T18:01:10.756Z")
@Stability(Stable)
public class HttpRouteKey
extends software.amazon.jsii.JsiiObject
HTTP route in APIGateway is a combination of the HTTP method and the path component.
This class models that combination.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import software.amazon.awscdk.services.apigatewayv2.*; HttpRouteKey httpRouteKey = HttpRouteKey.with("path", HttpMethod.ANY);
-
Nested Class Summary
Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode
-
Field Summary
Modifier and TypeFieldDescriptionstatic final HttpRouteKey
The catch-all route of the API, i.e., when no other routes match. -
Constructor Summary
ModifierConstructorDescriptionprotected
HttpRouteKey
(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protected
HttpRouteKey
(software.amazon.jsii.JsiiObjectRef objRef) -
Method Summary
Modifier and TypeMethodDescriptiongetKey()
The key to the RouteKey as recognized by APIGateway.The method of the route.getPath()
The path part of this RouteKey.static HttpRouteKey
Create a route key with the combination of the path and the method.static HttpRouteKey
with
(String path, HttpMethod method) Create a route key with the combination of the path and the method.Methods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
DEFAULT
The catch-all route of the API, i.e., when no other routes match.
-
-
Constructor Details
-
HttpRouteKey
protected HttpRouteKey(software.amazon.jsii.JsiiObjectRef objRef) -
HttpRouteKey
protected HttpRouteKey(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
-
-
Method Details
-
with
@Stability(Stable) @NotNull public static HttpRouteKey with(@NotNull String path, @Nullable HttpMethod method) Create a route key with the combination of the path and the method.- Parameters:
path
- This parameter is required.method
- default is 'ANY'.
-
with
Create a route key with the combination of the path and the method.- Parameters:
path
- This parameter is required.
-
getKey
The key to the RouteKey as recognized by APIGateway. -
getMethod
The method of the route. -
getPath
The path part of this RouteKey.Returns
undefined
whenRouteKey.DEFAULT
is used.
-