AWS SDK for C++

AWS SDK for C++ Version 1.11.747

Loading...
Searching...
No Matches
HttpRouteAction.h
1
6#pragma once
7#include <aws/appmesh/AppMesh_EXPORTS.h>
8#include <aws/appmesh/model/WeightedTarget.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10
11#include <utility>
12
13namespace Aws {
14namespace Utils {
15namespace Json {
16class JsonValue;
17class JsonView;
18} // namespace Json
19} // namespace Utils
20namespace AppMesh {
21namespace Model {
22
30 public:
31 AWS_APPMESH_API HttpRouteAction() = default;
32 AWS_APPMESH_API HttpRouteAction(Aws::Utils::Json::JsonView jsonValue);
34 AWS_APPMESH_API Aws::Utils::Json::JsonValue Jsonize() const;
35
37
41 inline const Aws::Vector<WeightedTarget>& GetWeightedTargets() const { return m_weightedTargets; }
42 inline bool WeightedTargetsHasBeenSet() const { return m_weightedTargetsHasBeenSet; }
43 template <typename WeightedTargetsT = Aws::Vector<WeightedTarget>>
44 void SetWeightedTargets(WeightedTargetsT&& value) {
45 m_weightedTargetsHasBeenSet = true;
46 m_weightedTargets = std::forward<WeightedTargetsT>(value);
47 }
48 template <typename WeightedTargetsT = Aws::Vector<WeightedTarget>>
49 HttpRouteAction& WithWeightedTargets(WeightedTargetsT&& value) {
50 SetWeightedTargets(std::forward<WeightedTargetsT>(value));
51 return *this;
52 }
53 template <typename WeightedTargetsT = WeightedTarget>
54 HttpRouteAction& AddWeightedTargets(WeightedTargetsT&& value) {
55 m_weightedTargetsHasBeenSet = true;
56 m_weightedTargets.emplace_back(std::forward<WeightedTargetsT>(value));
57 return *this;
58 }
60 private:
61 Aws::Vector<WeightedTarget> m_weightedTargets;
62 bool m_weightedTargetsHasBeenSet = false;
63};
64
65} // namespace Model
66} // namespace AppMesh
67} // namespace Aws
const Aws::Vector< WeightedTarget > & GetWeightedTargets() const
AWS_APPMESH_API HttpRouteAction & operator=(Aws::Utils::Json::JsonView jsonValue)
AWS_APPMESH_API Aws::Utils::Json::JsonValue Jsonize() const
AWS_APPMESH_API HttpRouteAction(Aws::Utils::Json::JsonView jsonValue)
HttpRouteAction & WithWeightedTargets(WeightedTargetsT &&value)
HttpRouteAction & AddWeightedTargets(WeightedTargetsT &&value)
AWS_APPMESH_API HttpRouteAction()=default
void SetWeightedTargets(WeightedTargetsT &&value)
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue