/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace AppMesh { namespace Model { /** *

An object that represents the criteria for determining a request * match.

See Also:

AWS * API Reference

*/ class GrpcRouteMatch { public: AWS_APPMESH_API GrpcRouteMatch(); AWS_APPMESH_API GrpcRouteMatch(Aws::Utils::Json::JsonView jsonValue); AWS_APPMESH_API GrpcRouteMatch& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_APPMESH_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

An object that represents the data to match from the request.

*/ inline const Aws::Vector& GetMetadata() const{ return m_metadata; } /** *

An object that represents the data to match from the request.

*/ inline bool MetadataHasBeenSet() const { return m_metadataHasBeenSet; } /** *

An object that represents the data to match from the request.

*/ inline void SetMetadata(const Aws::Vector& value) { m_metadataHasBeenSet = true; m_metadata = value; } /** *

An object that represents the data to match from the request.

*/ inline void SetMetadata(Aws::Vector&& value) { m_metadataHasBeenSet = true; m_metadata = std::move(value); } /** *

An object that represents the data to match from the request.

*/ inline GrpcRouteMatch& WithMetadata(const Aws::Vector& value) { SetMetadata(value); return *this;} /** *

An object that represents the data to match from the request.

*/ inline GrpcRouteMatch& WithMetadata(Aws::Vector&& value) { SetMetadata(std::move(value)); return *this;} /** *

An object that represents the data to match from the request.

*/ inline GrpcRouteMatch& AddMetadata(const GrpcRouteMetadata& value) { m_metadataHasBeenSet = true; m_metadata.push_back(value); return *this; } /** *

An object that represents the data to match from the request.

*/ inline GrpcRouteMatch& AddMetadata(GrpcRouteMetadata&& value) { m_metadataHasBeenSet = true; m_metadata.push_back(std::move(value)); return *this; } /** *

The method name to match from the request. If you specify a name, you must * also specify a serviceName.

*/ inline const Aws::String& GetMethodName() const{ return m_methodName; } /** *

The method name to match from the request. If you specify a name, you must * also specify a serviceName.

*/ inline bool MethodNameHasBeenSet() const { return m_methodNameHasBeenSet; } /** *

The method name to match from the request. If you specify a name, you must * also specify a serviceName.

*/ inline void SetMethodName(const Aws::String& value) { m_methodNameHasBeenSet = true; m_methodName = value; } /** *

The method name to match from the request. If you specify a name, you must * also specify a serviceName.

*/ inline void SetMethodName(Aws::String&& value) { m_methodNameHasBeenSet = true; m_methodName = std::move(value); } /** *

The method name to match from the request. If you specify a name, you must * also specify a serviceName.

*/ inline void SetMethodName(const char* value) { m_methodNameHasBeenSet = true; m_methodName.assign(value); } /** *

The method name to match from the request. If you specify a name, you must * also specify a serviceName.

*/ inline GrpcRouteMatch& WithMethodName(const Aws::String& value) { SetMethodName(value); return *this;} /** *

The method name to match from the request. If you specify a name, you must * also specify a serviceName.

*/ inline GrpcRouteMatch& WithMethodName(Aws::String&& value) { SetMethodName(std::move(value)); return *this;} /** *

The method name to match from the request. If you specify a name, you must * also specify a serviceName.

*/ inline GrpcRouteMatch& WithMethodName(const char* value) { SetMethodName(value); return *this;} /** *

The port number to match on.

*/ inline int GetPort() const{ return m_port; } /** *

The port number to match on.

*/ inline bool PortHasBeenSet() const { return m_portHasBeenSet; } /** *

The port number to match on.

*/ inline void SetPort(int value) { m_portHasBeenSet = true; m_port = value; } /** *

The port number to match on.

*/ inline GrpcRouteMatch& WithPort(int value) { SetPort(value); return *this;} /** *

The fully qualified domain name for the service to match from the * request.

*/ inline const Aws::String& GetServiceName() const{ return m_serviceName; } /** *

The fully qualified domain name for the service to match from the * request.

*/ inline bool ServiceNameHasBeenSet() const { return m_serviceNameHasBeenSet; } /** *

The fully qualified domain name for the service to match from the * request.

*/ inline void SetServiceName(const Aws::String& value) { m_serviceNameHasBeenSet = true; m_serviceName = value; } /** *

The fully qualified domain name for the service to match from the * request.

*/ inline void SetServiceName(Aws::String&& value) { m_serviceNameHasBeenSet = true; m_serviceName = std::move(value); } /** *

The fully qualified domain name for the service to match from the * request.

*/ inline void SetServiceName(const char* value) { m_serviceNameHasBeenSet = true; m_serviceName.assign(value); } /** *

The fully qualified domain name for the service to match from the * request.

*/ inline GrpcRouteMatch& WithServiceName(const Aws::String& value) { SetServiceName(value); return *this;} /** *

The fully qualified domain name for the service to match from the * request.

*/ inline GrpcRouteMatch& WithServiceName(Aws::String&& value) { SetServiceName(std::move(value)); return *this;} /** *

The fully qualified domain name for the service to match from the * request.

*/ inline GrpcRouteMatch& WithServiceName(const char* value) { SetServiceName(value); return *this;} private: Aws::Vector m_metadata; bool m_metadataHasBeenSet = false; Aws::String m_methodName; bool m_methodNameHasBeenSet = false; int m_port; bool m_portHasBeenSet = false; Aws::String m_serviceName; bool m_serviceNameHasBeenSet = false; }; } // namespace Model } // namespace AppMesh } // namespace Aws