AWS SDK for C++

AWS SDK for C++ Version 1.11.750

Loading...
Searching...
No Matches
ApplicationMetrics.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSStreamFwd.h>
8#include <aws/elasticbeanstalk/ElasticBeanstalk_EXPORTS.h>
9#include <aws/elasticbeanstalk/model/Latency.h>
10#include <aws/elasticbeanstalk/model/StatusCodes.h>
11
12#include <utility>
13
14namespace Aws {
15namespace Utils {
16namespace Xml {
17class XmlNode;
18} // namespace Xml
19} // namespace Utils
20namespace ElasticBeanstalk {
21namespace Model {
22
30 public:
31 AWS_ELASTICBEANSTALK_API ApplicationMetrics() = default;
32 AWS_ELASTICBEANSTALK_API ApplicationMetrics(const Aws::Utils::Xml::XmlNode& xmlNode);
33 AWS_ELASTICBEANSTALK_API ApplicationMetrics& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
34
35 AWS_ELASTICBEANSTALK_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index,
36 const char* locationValue) const;
37 AWS_ELASTICBEANSTALK_API void OutputToStream(Aws::OStream& oStream, const char* location) const;
38
40
45 inline int GetDuration() const { return m_duration; }
46 inline bool DurationHasBeenSet() const { return m_durationHasBeenSet; }
47 inline void SetDuration(int value) {
48 m_durationHasBeenSet = true;
49 m_duration = value;
50 }
51 inline ApplicationMetrics& WithDuration(int value) {
52 SetDuration(value);
53 return *this;
54 }
56
58
62 inline int GetRequestCount() const { return m_requestCount; }
63 inline bool RequestCountHasBeenSet() const { return m_requestCountHasBeenSet; }
64 inline void SetRequestCount(int value) {
65 m_requestCountHasBeenSet = true;
66 m_requestCount = value;
67 }
69 SetRequestCount(value);
70 return *this;
71 }
73
75
79 inline const StatusCodes& GetStatusCodes() const { return m_statusCodes; }
80 inline bool StatusCodesHasBeenSet() const { return m_statusCodesHasBeenSet; }
81 template <typename StatusCodesT = StatusCodes>
82 void SetStatusCodes(StatusCodesT&& value) {
83 m_statusCodesHasBeenSet = true;
84 m_statusCodes = std::forward<StatusCodesT>(value);
85 }
86 template <typename StatusCodesT = StatusCodes>
87 ApplicationMetrics& WithStatusCodes(StatusCodesT&& value) {
88 SetStatusCodes(std::forward<StatusCodesT>(value));
89 return *this;
90 }
92
94
98 inline const Latency& GetLatency() const { return m_latency; }
99 inline bool LatencyHasBeenSet() const { return m_latencyHasBeenSet; }
100 template <typename LatencyT = Latency>
101 void SetLatency(LatencyT&& value) {
102 m_latencyHasBeenSet = true;
103 m_latency = std::forward<LatencyT>(value);
104 }
105 template <typename LatencyT = Latency>
106 ApplicationMetrics& WithLatency(LatencyT&& value) {
107 SetLatency(std::forward<LatencyT>(value));
108 return *this;
109 }
111 private:
112 int m_duration{0};
113
114 int m_requestCount{0};
115
116 StatusCodes m_statusCodes;
117
118 Latency m_latency;
119 bool m_durationHasBeenSet = false;
120 bool m_requestCountHasBeenSet = false;
121 bool m_statusCodesHasBeenSet = false;
122 bool m_latencyHasBeenSet = false;
123};
124
125} // namespace Model
126} // namespace ElasticBeanstalk
127} // namespace Aws
AWS_ELASTICBEANSTALK_API ApplicationMetrics & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
AWS_ELASTICBEANSTALK_API ApplicationMetrics(const Aws::Utils::Xml::XmlNode &xmlNode)
AWS_ELASTICBEANSTALK_API void OutputToStream(Aws::OStream &ostream, const char *location, unsigned index, const char *locationValue) const
AWS_ELASTICBEANSTALK_API void OutputToStream(Aws::OStream &oStream, const char *location) const
ApplicationMetrics & WithStatusCodes(StatusCodesT &&value)
ApplicationMetrics & WithLatency(LatencyT &&value)
AWS_ELASTICBEANSTALK_API ApplicationMetrics()=default
std::basic_ostream< char, std::char_traits< char > > OStream