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

Describes a network route.

See Also:

AWS * API Reference

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

A unique identifier for the route, such as a CIDR block.

*/ inline const Aws::String& GetDestinationCidrBlock() const{ return m_destinationCidrBlock; } /** *

A unique identifier for the route, such as a CIDR block.

*/ inline bool DestinationCidrBlockHasBeenSet() const { return m_destinationCidrBlockHasBeenSet; } /** *

A unique identifier for the route, such as a CIDR block.

*/ inline void SetDestinationCidrBlock(const Aws::String& value) { m_destinationCidrBlockHasBeenSet = true; m_destinationCidrBlock = value; } /** *

A unique identifier for the route, such as a CIDR block.

*/ inline void SetDestinationCidrBlock(Aws::String&& value) { m_destinationCidrBlockHasBeenSet = true; m_destinationCidrBlock = std::move(value); } /** *

A unique identifier for the route, such as a CIDR block.

*/ inline void SetDestinationCidrBlock(const char* value) { m_destinationCidrBlockHasBeenSet = true; m_destinationCidrBlock.assign(value); } /** *

A unique identifier for the route, such as a CIDR block.

*/ inline NetworkRoute& WithDestinationCidrBlock(const Aws::String& value) { SetDestinationCidrBlock(value); return *this;} /** *

A unique identifier for the route, such as a CIDR block.

*/ inline NetworkRoute& WithDestinationCidrBlock(Aws::String&& value) { SetDestinationCidrBlock(std::move(value)); return *this;} /** *

A unique identifier for the route, such as a CIDR block.

*/ inline NetworkRoute& WithDestinationCidrBlock(const char* value) { SetDestinationCidrBlock(value); return *this;} /** *

The destinations.

*/ inline const Aws::Vector& GetDestinations() const{ return m_destinations; } /** *

The destinations.

*/ inline bool DestinationsHasBeenSet() const { return m_destinationsHasBeenSet; } /** *

The destinations.

*/ inline void SetDestinations(const Aws::Vector& value) { m_destinationsHasBeenSet = true; m_destinations = value; } /** *

The destinations.

*/ inline void SetDestinations(Aws::Vector&& value) { m_destinationsHasBeenSet = true; m_destinations = std::move(value); } /** *

The destinations.

*/ inline NetworkRoute& WithDestinations(const Aws::Vector& value) { SetDestinations(value); return *this;} /** *

The destinations.

*/ inline NetworkRoute& WithDestinations(Aws::Vector&& value) { SetDestinations(std::move(value)); return *this;} /** *

The destinations.

*/ inline NetworkRoute& AddDestinations(const NetworkRouteDestination& value) { m_destinationsHasBeenSet = true; m_destinations.push_back(value); return *this; } /** *

The destinations.

*/ inline NetworkRoute& AddDestinations(NetworkRouteDestination&& value) { m_destinationsHasBeenSet = true; m_destinations.push_back(std::move(value)); return *this; } /** *

The ID of the prefix list.

*/ inline const Aws::String& GetPrefixListId() const{ return m_prefixListId; } /** *

The ID of the prefix list.

*/ inline bool PrefixListIdHasBeenSet() const { return m_prefixListIdHasBeenSet; } /** *

The ID of the prefix list.

*/ inline void SetPrefixListId(const Aws::String& value) { m_prefixListIdHasBeenSet = true; m_prefixListId = value; } /** *

The ID of the prefix list.

*/ inline void SetPrefixListId(Aws::String&& value) { m_prefixListIdHasBeenSet = true; m_prefixListId = std::move(value); } /** *

The ID of the prefix list.

*/ inline void SetPrefixListId(const char* value) { m_prefixListIdHasBeenSet = true; m_prefixListId.assign(value); } /** *

The ID of the prefix list.

*/ inline NetworkRoute& WithPrefixListId(const Aws::String& value) { SetPrefixListId(value); return *this;} /** *

The ID of the prefix list.

*/ inline NetworkRoute& WithPrefixListId(Aws::String&& value) { SetPrefixListId(std::move(value)); return *this;} /** *

The ID of the prefix list.

*/ inline NetworkRoute& WithPrefixListId(const char* value) { SetPrefixListId(value); return *this;} /** *

The route state. The possible values are active and * blackhole.

*/ inline const RouteState& GetState() const{ return m_state; } /** *

The route state. The possible values are active and * blackhole.

*/ inline bool StateHasBeenSet() const { return m_stateHasBeenSet; } /** *

The route state. The possible values are active and * blackhole.

*/ inline void SetState(const RouteState& value) { m_stateHasBeenSet = true; m_state = value; } /** *

The route state. The possible values are active and * blackhole.

*/ inline void SetState(RouteState&& value) { m_stateHasBeenSet = true; m_state = std::move(value); } /** *

The route state. The possible values are active and * blackhole.

*/ inline NetworkRoute& WithState(const RouteState& value) { SetState(value); return *this;} /** *

The route state. The possible values are active and * blackhole.

*/ inline NetworkRoute& WithState(RouteState&& value) { SetState(std::move(value)); return *this;} /** *

The route type. The possible values are propagated and * static.

*/ inline const RouteType& GetType() const{ return m_type; } /** *

The route type. The possible values are propagated and * static.

*/ inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; } /** *

The route type. The possible values are propagated and * static.

*/ inline void SetType(const RouteType& value) { m_typeHasBeenSet = true; m_type = value; } /** *

The route type. The possible values are propagated and * static.

*/ inline void SetType(RouteType&& value) { m_typeHasBeenSet = true; m_type = std::move(value); } /** *

The route type. The possible values are propagated and * static.

*/ inline NetworkRoute& WithType(const RouteType& value) { SetType(value); return *this;} /** *

The route type. The possible values are propagated and * static.

*/ inline NetworkRoute& WithType(RouteType&& value) { SetType(std::move(value)); return *this;} private: Aws::String m_destinationCidrBlock; bool m_destinationCidrBlockHasBeenSet = false; Aws::Vector m_destinations; bool m_destinationsHasBeenSet = false; Aws::String m_prefixListId; bool m_prefixListIdHasBeenSet = false; RouteState m_state; bool m_stateHasBeenSet = false; RouteType m_type; bool m_typeHasBeenSet = false; }; } // namespace Model } // namespace NetworkManager } // namespace Aws