# GatewayRouteProps

Properties to define a new GatewayRoute.

Extends: [GatewayRouteBaseProps](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_appmesh.GatewayRouteBaseProps.html)
Used as props by: [GatewayRoute](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_appmesh.GatewayRoute.html)

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

## 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';

declare const gatewayRouteSpec: appmesh.GatewayRouteSpec;
declare const virtualGateway: appmesh.VirtualGateway;
const gatewayRouteProps: appmesh.GatewayRouteProps = {
  routeSpec: gatewayRouteSpec,
  virtualGateway: virtualGateway,

  // the properties below are optional
  gatewayRouteName: 'gatewayRouteName',
};
```

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

# gateway_route_spec: appmesh.GatewayRouteSpec
# virtual_gateway: appmesh.VirtualGateway

gateway_route_props = appmesh.GatewayRouteProps(
    route_spec=gateway_route_spec,
    virtual_gateway=virtual_gateway,

    # the properties below are optional
    gateway_route_name="gatewayRouteName"
)
```

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.*;

GatewayRouteSpec gatewayRouteSpec;
VirtualGateway virtualGateway;

GatewayRouteProps gatewayRouteProps = GatewayRouteProps.builder()
        .routeSpec(gatewayRouteSpec)
        .virtualGateway(virtualGateway)

        // the properties below are optional
        .gatewayRouteName("gatewayRouteName")
        .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;

GatewayRouteSpec gatewayRouteSpec;
VirtualGateway virtualGateway;

var gatewayRouteProps = new GatewayRouteProps {
    RouteSpec = gatewayRouteSpec,
    VirtualGateway = virtualGateway,

    // the properties below are optional
    GatewayRouteName = "gatewayRouteName"
};
```

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"

var gatewayRouteSpec GatewayRouteSpec
var virtualGateway VirtualGateway

gatewayRouteProps := &GatewayRouteProps{
	RouteSpec: gatewayRouteSpec,
	VirtualGateway: virtualGateway,

	// the properties below are optional
	GatewayRouteName: jsii.String("gatewayRouteName"),
}
```

## Properties

- `gatewayRouteName`: string — The name of the GatewayRoute.

  **Default:** an automatically generated name

- `routeSpec`: [GatewayRouteSpec](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_appmesh.GatewayRouteSpec.html) (required) — What protocol the route uses.

- `virtualGateway`: [IVirtualGateway](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_appmesh.IVirtualGateway.html) (required) — The VirtualGateway this GatewayRoute is associated with.
