@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:36.537Z") @Stability(value=Stable) public abstract class HeaderMatch extends software.amazon.jsii.JsiiObject
Example:
// Example automatically generated from non-compiling source. May contain errors.
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());
| Modifier | Constructor and Description |
|---|---|
protected |
HeaderMatch() |
protected |
HeaderMatch(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
HeaderMatch(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
abstract HeaderMatchConfig |
bind(software.constructs.Construct scope)
Returns the header match configuration.
|
static HeaderMatch |
valueDoesNotEndWith(String headerName,
String suffix)
The value of the header with the given name in the request must not end with the specified characters.
|
static HeaderMatch |
valueDoesNotMatchRegex(String headerName,
String regex)
The value of the header with the given name in the request must not include the specified characters.
|
static HeaderMatch |
valueDoesNotStartWith(String headerName,
String prefix)
The value of the header with the given name in the request must not start with the specified characters.
|
static HeaderMatch |
valueEndsWith(String headerName,
String suffix)
The value of the header with the given name in the request must end with the specified characters.
|
static HeaderMatch |
valueIs(String headerName,
String headerValue)
The value of the header with the given name in the request must match the specified value exactly.
|
static HeaderMatch |
valueIsNot(String headerName,
String headerValue)
The value of the header with the given name in the request must not match the specified value exactly.
|
static HeaderMatch |
valueMatchesRegex(String headerName,
String regex)
The value of the header with the given name in the request must include the specified characters.
|
static HeaderMatch |
valuesIsInRange(String headerName,
Number start,
Number end)
The value of the header with the given name in the request must be in a range of values.
|
static HeaderMatch |
valuesIsNotInRange(String headerName,
Number start,
Number end)
The value of the header with the given name in the request must not be in a range of values.
|
static HeaderMatch |
valueStartsWith(String headerName,
String prefix)
The value of the header with the given name in the request must start with the specified characters.
|
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetprotected HeaderMatch(software.amazon.jsii.JsiiObjectRef objRef)
protected HeaderMatch(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Stable) protected HeaderMatch()
@Stability(value=Stable) @NotNull public static HeaderMatch valueDoesNotEndWith(@NotNull String headerName, @NotNull String suffix)
headerName - the name of the header to match against. This parameter is required.suffix - The suffix to test against. This parameter is required.@Stability(value=Stable) @NotNull public static HeaderMatch valueDoesNotMatchRegex(@NotNull String headerName, @NotNull String regex)
headerName - the name of the header to match against. This parameter is required.regex - The regex to test against. This parameter is required.@Stability(value=Stable) @NotNull public static HeaderMatch valueDoesNotStartWith(@NotNull String headerName, @NotNull String prefix)
headerName - the name of the header to match against. This parameter is required.prefix - The prefix to test against. This parameter is required.@Stability(value=Stable) @NotNull public static HeaderMatch valueEndsWith(@NotNull String headerName, @NotNull String suffix)
headerName - the name of the header to match against. This parameter is required.suffix - The suffix to test against. This parameter is required.@Stability(value=Stable) @NotNull public static HeaderMatch valueIs(@NotNull String headerName, @NotNull String headerValue)
headerName - the name of the header to match against. This parameter is required.headerValue - The exact value to test against. This parameter is required.@Stability(value=Stable) @NotNull public static HeaderMatch valueIsNot(@NotNull String headerName, @NotNull String headerValue)
headerName - the name of the header to match against. This parameter is required.headerValue - The exact value to test against. This parameter is required.@Stability(value=Stable) @NotNull public static HeaderMatch valueMatchesRegex(@NotNull String headerName, @NotNull String regex)
headerName - the name of the header to match against. This parameter is required.regex - The regex to test against. This parameter is required.@Stability(value=Stable) @NotNull public static HeaderMatch valuesIsInRange(@NotNull String headerName, @NotNull Number start, @NotNull Number end)
headerName - the name of the header to match against. This parameter is required.start - Match on values starting at and including this value. This parameter is required.end - Match on values up to but not including this value. This parameter is required.@Stability(value=Stable) @NotNull public static HeaderMatch valuesIsNotInRange(@NotNull String headerName, @NotNull Number start, @NotNull Number end)
headerName - the name of the header to match against. This parameter is required.start - Match on values starting at and including this value. This parameter is required.end - Match on values up to but not including this value. This parameter is required.@Stability(value=Stable) @NotNull public static HeaderMatch valueStartsWith(@NotNull String headerName, @NotNull String prefix)
headerName - the name of the header to match against. This parameter is required.prefix - The prefix to test against. This parameter is required.@Stability(value=Stable) @NotNull public abstract HeaderMatchConfig bind(@NotNull software.constructs.Construct scope)
scope - This parameter is required.Copyright © 2022. All rights reserved.