AWS SDK for C++  0.12.9
AWS SDK for C++
GetMetricStatisticsRequest.h
Go to the documentation of this file.
1 /*
2 * Copyright 2010-2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License").
5 * You may not use this file except in compliance with the License.
6 * A copy of the License is located at
7 *
8 * http://aws.amazon.com/apache2.0
9 *
10 * or in the "license" file accompanying this file. This file is distributed
11 * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
12 * express or implied. See the License for the specific language governing
13 * permissions and limitations under the License.
14 */
15 #pragma once
24 
25 namespace Aws
26 {
27 namespace CloudWatch
28 {
29 namespace Model
30 {
31 
35  {
36  public:
38  Aws::String SerializePayload() const override;
39 
43  inline const Aws::String& GetNamespace() const{ return m_namespace; }
44 
48  inline void SetNamespace(const Aws::String& value) { m_namespaceHasBeenSet = true; m_namespace = value; }
49 
53  inline void SetNamespace(Aws::String&& value) { m_namespaceHasBeenSet = true; m_namespace = value; }
54 
58  inline void SetNamespace(const char* value) { m_namespaceHasBeenSet = true; m_namespace.assign(value); }
59 
63  inline GetMetricStatisticsRequest& WithNamespace(const Aws::String& value) { SetNamespace(value); return *this;}
64 
68  inline GetMetricStatisticsRequest& WithNamespace(Aws::String&& value) { SetNamespace(value); return *this;}
69 
73  inline GetMetricStatisticsRequest& WithNamespace(const char* value) { SetNamespace(value); return *this;}
74 
78  inline const Aws::String& GetMetricName() const{ return m_metricName; }
79 
83  inline void SetMetricName(const Aws::String& value) { m_metricNameHasBeenSet = true; m_metricName = value; }
84 
88  inline void SetMetricName(Aws::String&& value) { m_metricNameHasBeenSet = true; m_metricName = value; }
89 
93  inline void SetMetricName(const char* value) { m_metricNameHasBeenSet = true; m_metricName.assign(value); }
94 
98  inline GetMetricStatisticsRequest& WithMetricName(const Aws::String& value) { SetMetricName(value); return *this;}
99 
103  inline GetMetricStatisticsRequest& WithMetricName(Aws::String&& value) { SetMetricName(value); return *this;}
104 
108  inline GetMetricStatisticsRequest& WithMetricName(const char* value) { SetMetricName(value); return *this;}
109 
113  inline const Aws::Vector<Dimension>& GetDimensions() const{ return m_dimensions; }
114 
118  inline void SetDimensions(const Aws::Vector<Dimension>& value) { m_dimensionsHasBeenSet = true; m_dimensions = value; }
119 
123  inline void SetDimensions(Aws::Vector<Dimension>&& value) { m_dimensionsHasBeenSet = true; m_dimensions = value; }
124 
128  inline GetMetricStatisticsRequest& WithDimensions(const Aws::Vector<Dimension>& value) { SetDimensions(value); return *this;}
129 
133  inline GetMetricStatisticsRequest& WithDimensions(Aws::Vector<Dimension>&& value) { SetDimensions(value); return *this;}
134 
138  inline GetMetricStatisticsRequest& AddDimensions(const Dimension& value) { m_dimensionsHasBeenSet = true; m_dimensions.push_back(value); return *this; }
139 
143  inline GetMetricStatisticsRequest& AddDimensions(Dimension&& value) { m_dimensionsHasBeenSet = true; m_dimensions.push_back(value); return *this; }
144 
157  inline const Aws::Utils::DateTime& GetStartTime() const{ return m_startTime; }
158 
171  inline void SetStartTime(const Aws::Utils::DateTime& value) { m_startTimeHasBeenSet = true; m_startTime = value; }
172 
185  inline void SetStartTime(Aws::Utils::DateTime&& value) { m_startTimeHasBeenSet = true; m_startTime = value; }
186 
199  inline GetMetricStatisticsRequest& WithStartTime(const Aws::Utils::DateTime& value) { SetStartTime(value); return *this;}
200 
213  inline GetMetricStatisticsRequest& WithStartTime(Aws::Utils::DateTime&& value) { SetStartTime(value); return *this;}
214 
221  inline const Aws::Utils::DateTime& GetEndTime() const{ return m_endTime; }
222 
229  inline void SetEndTime(const Aws::Utils::DateTime& value) { m_endTimeHasBeenSet = true; m_endTime = value; }
230 
237  inline void SetEndTime(Aws::Utils::DateTime&& value) { m_endTimeHasBeenSet = true; m_endTime = value; }
238 
245  inline GetMetricStatisticsRequest& WithEndTime(const Aws::Utils::DateTime& value) { SetEndTime(value); return *this;}
246 
253  inline GetMetricStatisticsRequest& WithEndTime(Aws::Utils::DateTime&& value) { SetEndTime(value); return *this;}
254 
260  inline long GetPeriod() const{ return m_period; }
261 
267  inline void SetPeriod(long value) { m_periodHasBeenSet = true; m_period = value; }
268 
274  inline GetMetricStatisticsRequest& WithPeriod(long value) { SetPeriod(value); return *this;}
275 
282  inline const Aws::Vector<Statistic>& GetStatistics() const{ return m_statistics; }
283 
290  inline void SetStatistics(const Aws::Vector<Statistic>& value) { m_statisticsHasBeenSet = true; m_statistics = value; }
291 
298  inline void SetStatistics(Aws::Vector<Statistic>&& value) { m_statisticsHasBeenSet = true; m_statistics = value; }
299 
306  inline GetMetricStatisticsRequest& WithStatistics(const Aws::Vector<Statistic>& value) { SetStatistics(value); return *this;}
307 
314  inline GetMetricStatisticsRequest& WithStatistics(Aws::Vector<Statistic>&& value) { SetStatistics(value); return *this;}
315 
322  inline GetMetricStatisticsRequest& AddStatistics(const Statistic& value) { m_statisticsHasBeenSet = true; m_statistics.push_back(value); return *this; }
323 
330  inline GetMetricStatisticsRequest& AddStatistics(Statistic&& value) { m_statisticsHasBeenSet = true; m_statistics.push_back(value); return *this; }
331 
335  inline const StandardUnit& GetUnit() const{ return m_unit; }
336 
340  inline void SetUnit(const StandardUnit& value) { m_unitHasBeenSet = true; m_unit = value; }
341 
345  inline void SetUnit(StandardUnit&& value) { m_unitHasBeenSet = true; m_unit = value; }
346 
350  inline GetMetricStatisticsRequest& WithUnit(const StandardUnit& value) { SetUnit(value); return *this;}
351 
355  inline GetMetricStatisticsRequest& WithUnit(StandardUnit&& value) { SetUnit(value); return *this;}
356 
357  private:
358  Aws::String m_namespace;
359  bool m_namespaceHasBeenSet;
360  Aws::String m_metricName;
361  bool m_metricNameHasBeenSet;
362  Aws::Vector<Dimension> m_dimensions;
363  bool m_dimensionsHasBeenSet;
364  Aws::Utils::DateTime m_startTime;
365  bool m_startTimeHasBeenSet;
366  Aws::Utils::DateTime m_endTime;
367  bool m_endTimeHasBeenSet;
368  long m_period;
369  bool m_periodHasBeenSet;
370  Aws::Vector<Statistic> m_statistics;
371  bool m_statisticsHasBeenSet;
372  StandardUnit m_unit;
373  bool m_unitHasBeenSet;
374  };
375 
376 } // namespace Model
377 } // namespace CloudWatch
378 } // namespace Aws
const Aws::Vector< Dimension > & GetDimensions() const
GetMetricStatisticsRequest & WithMetricName(const Aws::String &value)
GetMetricStatisticsRequest & WithNamespace(const Aws::String &value)
GetMetricStatisticsRequest & WithMetricName(const char *value)
#define AWS_CLOUDWATCH_API
std::vector< T, Aws::Allocator< T > > Vector
Definition: AWSVector.h:27
GetMetricStatisticsRequest & AddStatistics(Statistic &&value)
const Aws::Vector< Statistic > & GetStatistics() const
GetMetricStatisticsRequest & WithNamespace(Aws::String &&value)
GetMetricStatisticsRequest & AddStatistics(const Statistic &value)
GetMetricStatisticsRequest & AddDimensions(const Dimension &value)
GetMetricStatisticsRequest & AddDimensions(Dimension &&value)
GetMetricStatisticsRequest & WithStartTime(Aws::Utils::DateTime &&value)
GetMetricStatisticsRequest & WithMetricName(Aws::String &&value)
GetMetricStatisticsRequest & WithDimensions(Aws::Vector< Dimension > &&value)
GetMetricStatisticsRequest & WithStartTime(const Aws::Utils::DateTime &value)
GetMetricStatisticsRequest & WithStatistics(const Aws::Vector< Statistic > &value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
void SetStartTime(const Aws::Utils::DateTime &value)
void SetStatistics(const Aws::Vector< Statistic > &value)
GetMetricStatisticsRequest & WithNamespace(const char *value)
GetMetricStatisticsRequest & WithEndTime(const Aws::Utils::DateTime &value)
GetMetricStatisticsRequest & WithStatistics(Aws::Vector< Statistic > &&value)
void SetDimensions(const Aws::Vector< Dimension > &value)
GetMetricStatisticsRequest & WithPeriod(long value)
GetMetricStatisticsRequest & WithUnit(StandardUnit &&value)
GetMetricStatisticsRequest & WithEndTime(Aws::Utils::DateTime &&value)
GetMetricStatisticsRequest & WithUnit(const StandardUnit &value)
GetMetricStatisticsRequest & WithDimensions(const Aws::Vector< Dimension > &value)
JSON (JavaScript Object Notation).