# HttpGatewayRoutePathMatchConfig

The type returned from the `bind()` method in `HttpGatewayRoutePathMatch`.

Returned by: [HttpGatewayRoutePathMatch.bind](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_appmesh.HttpGatewayRoutePathMatch.html#bind)

- Source: [`aws-appmesh/lib/http-route-path-match.ts`](https://github.com/aws/aws-cdk/blob/v2.278.0/packages/aws-cdk-lib/aws-appmesh/lib/http-route-path-match.ts#L101)

## Example

TypeScript:

```ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_appmesh as appmesh } from 'aws-cdk-lib';
const httpGatewayRoutePathMatchConfig: appmesh.HttpGatewayRoutePathMatchConfig = {
  prefixPathMatch: 'prefixPathMatch',
  prefixPathRewrite: {
    defaultPrefix: 'defaultPrefix',
    value: 'value',
  },
  wholePathMatch: {
    exact: 'exact',
    regex: 'regex',
  },
  wholePathRewrite: {
    exact: 'exact',
  },
};
```

Python:

```python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_appmesh as appmesh

http_gateway_route_path_match_config = appmesh.HttpGatewayRoutePathMatchConfig(
    prefix_path_match="prefixPathMatch",
    prefix_path_rewrite=appmesh.CfnGatewayRoute.HttpGatewayRoutePrefixRewriteProperty(
        default_prefix="defaultPrefix",
        value="value"
    ),
    whole_path_match=appmesh.CfnGatewayRoute.HttpPathMatchProperty(
        exact="exact",
        regex="regex"
    ),
    whole_path_rewrite=appmesh.CfnGatewayRoute.HttpGatewayRoutePathRewriteProperty(
        exact="exact"
    )
)
```

Java:

```java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.appmesh.*;

HttpGatewayRoutePathMatchConfig httpGatewayRoutePathMatchConfig = HttpGatewayRoutePathMatchConfig.builder()
        .prefixPathMatch("prefixPathMatch")
        .prefixPathRewrite(HttpGatewayRoutePrefixRewriteProperty.builder()
                .defaultPrefix("defaultPrefix")
                .value("value")
                .build())
        .wholePathMatch(HttpPathMatchProperty.builder()
                .exact("exact")
                .regex("regex")
                .build())
        .wholePathRewrite(HttpGatewayRoutePathRewriteProperty.builder()
                .exact("exact")
                .build())
        .build();
```

C# / .NET:

```csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.AppMesh;

var httpGatewayRoutePathMatchConfig = new HttpGatewayRoutePathMatchConfig {
    PrefixPathMatch = "prefixPathMatch",
    PrefixPathRewrite = new HttpGatewayRoutePrefixRewriteProperty {
        DefaultPrefix = "defaultPrefix",
        Value = "value"
    },
    WholePathMatch = new HttpPathMatchProperty {
        Exact = "exact",
        Regex = "regex"
    },
    WholePathRewrite = new HttpGatewayRoutePathRewriteProperty {
        Exact = "exact"
    }
};
```

Golang:

```go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

httpGatewayRoutePathMatchConfig := &HttpGatewayRoutePathMatchConfig{
	PrefixPathMatch: jsii.String("prefixPathMatch"),
	PrefixPathRewrite: &HttpGatewayRoutePrefixRewriteProperty{
		DefaultPrefix: jsii.String("defaultPrefix"),
		Value: jsii.String("value"),
	},
	WholePathMatch: &HttpPathMatchProperty{
		Exact: jsii.String("exact"),
		Regex: jsii.String("regex"),
	},
	WholePathRewrite: &HttpGatewayRoutePathRewriteProperty{
		Exact: jsii.String("exact"),
	},
}
```

## Properties

- `prefixPathMatch`: string — Gateway route configuration for matching on the prefix of the URL path of the request.

  **Default:** no matching will be performed on the prefix of the URL path

- `prefixPathRewrite`: [CfnGatewayRoute.HttpGatewayRoutePrefixRewriteProperty](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_appmesh.CfnGatewayRoute.HttpGatewayRoutePrefixRewriteProperty.html) — Gateway route configuration for rewriting the prefix of the URL path of the request.

  **Default:** rewrites the request's URL path to '/'

- `wholePathMatch`: [CfnGatewayRoute.HttpPathMatchProperty](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_appmesh.CfnGatewayRoute.HttpPathMatchProperty.html) — Gateway route configuration for matching on the complete URL path of the request.

  **Default:** no matching will be performed on the complete URL path

- `wholePathRewrite`: [CfnGatewayRoute.HttpGatewayRoutePathRewriteProperty](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_appmesh.CfnGatewayRoute.HttpGatewayRoutePathRewriteProperty.html) — Gateway route configuration for rewriting the complete URL path of the request..

  **Default:** no rewrite will be performed on the request's complete URL path
