AWS SDK for C++  1.9.20
AWS SDK for C++
GetInstanceMetricDataRequest.h
Go to the documentation of this file.
1 
6 #pragma once
15 #include <utility>
16 
17 namespace Aws
18 {
19 namespace Lightsail
20 {
21 namespace Model
22 {
23 
27  {
28  public:
30 
31  // Service request name is the Operation name which will send this request out,
32  // each operation should has unique request name, so that we can get operation's name from this request.
33  // Note: this is not true for response, multiple operations may have the same response name,
34  // so we can not get operation's name from response.
35  inline virtual const char* GetServiceRequestName() const override { return "GetInstanceMetricData"; }
36 
37  Aws::String SerializePayload() const override;
38 
40 
41 
45  inline const Aws::String& GetInstanceName() const{ return m_instanceName; }
46 
50  inline bool InstanceNameHasBeenSet() const { return m_instanceNameHasBeenSet; }
51 
55  inline void SetInstanceName(const Aws::String& value) { m_instanceNameHasBeenSet = true; m_instanceName = value; }
56 
60  inline void SetInstanceName(Aws::String&& value) { m_instanceNameHasBeenSet = true; m_instanceName = std::move(value); }
61 
65  inline void SetInstanceName(const char* value) { m_instanceNameHasBeenSet = true; m_instanceName.assign(value); }
66 
70  inline GetInstanceMetricDataRequest& WithInstanceName(const Aws::String& value) { SetInstanceName(value); return *this;}
71 
75  inline GetInstanceMetricDataRequest& WithInstanceName(Aws::String&& value) { SetInstanceName(std::move(value)); return *this;}
76 
80  inline GetInstanceMetricDataRequest& WithInstanceName(const char* value) { SetInstanceName(value); return *this;}
81 
82 
151  inline const InstanceMetricName& GetMetricName() const{ return m_metricName; }
152 
221  inline bool MetricNameHasBeenSet() const { return m_metricNameHasBeenSet; }
222 
291  inline void SetMetricName(const InstanceMetricName& value) { m_metricNameHasBeenSet = true; m_metricName = value; }
292 
361  inline void SetMetricName(InstanceMetricName&& value) { m_metricNameHasBeenSet = true; m_metricName = std::move(value); }
362 
431  inline GetInstanceMetricDataRequest& WithMetricName(const InstanceMetricName& value) { SetMetricName(value); return *this;}
432 
501  inline GetInstanceMetricDataRequest& WithMetricName(InstanceMetricName&& value) { SetMetricName(std::move(value)); return *this;}
502 
503 
511  inline int GetPeriod() const{ return m_period; }
512 
520  inline bool PeriodHasBeenSet() const { return m_periodHasBeenSet; }
521 
529  inline void SetPeriod(int value) { m_periodHasBeenSet = true; m_period = value; }
530 
538  inline GetInstanceMetricDataRequest& WithPeriod(int value) { SetPeriod(value); return *this;}
539 
540 
544  inline const Aws::Utils::DateTime& GetStartTime() const{ return m_startTime; }
545 
549  inline bool StartTimeHasBeenSet() const { return m_startTimeHasBeenSet; }
550 
554  inline void SetStartTime(const Aws::Utils::DateTime& value) { m_startTimeHasBeenSet = true; m_startTime = value; }
555 
559  inline void SetStartTime(Aws::Utils::DateTime&& value) { m_startTimeHasBeenSet = true; m_startTime = std::move(value); }
560 
564  inline GetInstanceMetricDataRequest& WithStartTime(const Aws::Utils::DateTime& value) { SetStartTime(value); return *this;}
565 
569  inline GetInstanceMetricDataRequest& WithStartTime(Aws::Utils::DateTime&& value) { SetStartTime(std::move(value)); return *this;}
570 
571 
575  inline const Aws::Utils::DateTime& GetEndTime() const{ return m_endTime; }
576 
580  inline bool EndTimeHasBeenSet() const { return m_endTimeHasBeenSet; }
581 
585  inline void SetEndTime(const Aws::Utils::DateTime& value) { m_endTimeHasBeenSet = true; m_endTime = value; }
586 
590  inline void SetEndTime(Aws::Utils::DateTime&& value) { m_endTimeHasBeenSet = true; m_endTime = std::move(value); }
591 
595  inline GetInstanceMetricDataRequest& WithEndTime(const Aws::Utils::DateTime& value) { SetEndTime(value); return *this;}
596 
600  inline GetInstanceMetricDataRequest& WithEndTime(Aws::Utils::DateTime&& value) { SetEndTime(std::move(value)); return *this;}
601 
602 
608  inline const MetricUnit& GetUnit() const{ return m_unit; }
609 
615  inline bool UnitHasBeenSet() const { return m_unitHasBeenSet; }
616 
622  inline void SetUnit(const MetricUnit& value) { m_unitHasBeenSet = true; m_unit = value; }
623 
629  inline void SetUnit(MetricUnit&& value) { m_unitHasBeenSet = true; m_unit = std::move(value); }
630 
636  inline GetInstanceMetricDataRequest& WithUnit(const MetricUnit& value) { SetUnit(value); return *this;}
637 
643  inline GetInstanceMetricDataRequest& WithUnit(MetricUnit&& value) { SetUnit(std::move(value)); return *this;}
644 
645 
663  inline const Aws::Vector<MetricStatistic>& GetStatistics() const{ return m_statistics; }
664 
682  inline bool StatisticsHasBeenSet() const { return m_statisticsHasBeenSet; }
683 
701  inline void SetStatistics(const Aws::Vector<MetricStatistic>& value) { m_statisticsHasBeenSet = true; m_statistics = value; }
702 
720  inline void SetStatistics(Aws::Vector<MetricStatistic>&& value) { m_statisticsHasBeenSet = true; m_statistics = std::move(value); }
721 
739  inline GetInstanceMetricDataRequest& WithStatistics(const Aws::Vector<MetricStatistic>& value) { SetStatistics(value); return *this;}
740 
758  inline GetInstanceMetricDataRequest& WithStatistics(Aws::Vector<MetricStatistic>&& value) { SetStatistics(std::move(value)); return *this;}
759 
777  inline GetInstanceMetricDataRequest& AddStatistics(const MetricStatistic& value) { m_statisticsHasBeenSet = true; m_statistics.push_back(value); return *this; }
778 
796  inline GetInstanceMetricDataRequest& AddStatistics(MetricStatistic&& value) { m_statisticsHasBeenSet = true; m_statistics.push_back(std::move(value)); return *this; }
797 
798  private:
799 
800  Aws::String m_instanceName;
801  bool m_instanceNameHasBeenSet;
802 
803  InstanceMetricName m_metricName;
804  bool m_metricNameHasBeenSet;
805 
806  int m_period;
807  bool m_periodHasBeenSet;
808 
809  Aws::Utils::DateTime m_startTime;
810  bool m_startTimeHasBeenSet;
811 
812  Aws::Utils::DateTime m_endTime;
813  bool m_endTimeHasBeenSet;
814 
815  MetricUnit m_unit;
816  bool m_unitHasBeenSet;
817 
818  Aws::Vector<MetricStatistic> m_statistics;
819  bool m_statisticsHasBeenSet;
820  };
821 
822 } // namespace Model
823 } // namespace Lightsail
824 } // namespace Aws
Aws::Lightsail::Model::GetInstanceMetricDataRequest::AddStatistics
GetInstanceMetricDataRequest & AddStatistics(const MetricStatistic &value)
Definition: GetInstanceMetricDataRequest.h:777
Aws::Utils::DateTime
Definition: DateTime.h:55
Aws::Lightsail::Model::GetInstanceMetricDataRequest::UnitHasBeenSet
bool UnitHasBeenSet() const
Definition: GetInstanceMetricDataRequest.h:615
Aws::Lightsail::Model::GetInstanceMetricDataRequest::GetUnit
const MetricUnit & GetUnit() const
Definition: GetInstanceMetricDataRequest.h:608
Aws::Lightsail::Model::GetInstanceMetricDataRequest::WithMetricName
GetInstanceMetricDataRequest & WithMetricName(InstanceMetricName &&value)
Definition: GetInstanceMetricDataRequest.h:501
Aws::Lightsail::Model::GetInstanceMetricDataRequest::WithStartTime
GetInstanceMetricDataRequest & WithStartTime(const Aws::Utils::DateTime &value)
Definition: GetInstanceMetricDataRequest.h:564
Aws::Lightsail::Model::GetInstanceMetricDataRequest::SetMetricName
void SetMetricName(InstanceMetricName &&value)
Definition: GetInstanceMetricDataRequest.h:361
Aws::Lightsail::Model::GetInstanceMetricDataRequest::SetInstanceName
void SetInstanceName(const Aws::String &value)
Definition: GetInstanceMetricDataRequest.h:55
Aws::Lightsail::Model::GetInstanceMetricDataRequest::GetInstanceMetricDataRequest
GetInstanceMetricDataRequest()
Aws::Http::HeaderValueCollection
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
Definition: HttpTypes.h:53
Aws::Lightsail::Model::GetInstanceMetricDataRequest::SerializePayload
Aws::String SerializePayload() const override
Aws::Lightsail::Model::GetInstanceMetricDataRequest::SetEndTime
void SetEndTime(const Aws::Utils::DateTime &value)
Definition: GetInstanceMetricDataRequest.h:585
Aws::Lightsail::Model::GetInstanceMetricDataRequest::WithUnit
GetInstanceMetricDataRequest & WithUnit(const MetricUnit &value)
Definition: GetInstanceMetricDataRequest.h:636
Aws::Lightsail::Model::GetInstanceMetricDataRequest::SetInstanceName
void SetInstanceName(Aws::String &&value)
Definition: GetInstanceMetricDataRequest.h:60
Aws::Lightsail::Model::GetInstanceMetricDataRequest::SetMetricName
void SetMetricName(const InstanceMetricName &value)
Definition: GetInstanceMetricDataRequest.h:291
DateTime.h
Aws::Lightsail::Model::GetInstanceMetricDataRequest::SetStatistics
void SetStatistics(const Aws::Vector< MetricStatistic > &value)
Definition: GetInstanceMetricDataRequest.h:701
Aws::Lightsail::Model::GetInstanceMetricDataRequest::StartTimeHasBeenSet
bool StartTimeHasBeenSet() const
Definition: GetInstanceMetricDataRequest.h:549
Aws::Lightsail::Model::GetInstanceMetricDataRequest::GetPeriod
int GetPeriod() const
Definition: GetInstanceMetricDataRequest.h:511
Aws::Lightsail::Model::GetInstanceMetricDataRequest::SetUnit
void SetUnit(MetricUnit &&value)
Definition: GetInstanceMetricDataRequest.h:629
Aws::Vector
std::vector< T, Aws::Allocator< T > > Vector
Definition: AWSVector.h:17
Aws::Lightsail::Model::GetInstanceMetricDataRequest::GetEndTime
const Aws::Utils::DateTime & GetEndTime() const
Definition: GetInstanceMetricDataRequest.h:575
Aws::Lightsail::Model::GetInstanceMetricDataRequest::SetStatistics
void SetStatistics(Aws::Vector< MetricStatistic > &&value)
Definition: GetInstanceMetricDataRequest.h:720
Aws::Lightsail::Model::GetInstanceMetricDataRequest::GetMetricName
const InstanceMetricName & GetMetricName() const
Definition: GetInstanceMetricDataRequest.h:151
InstanceMetricName.h
Aws::Lightsail::Model::GetInstanceMetricDataRequest::StatisticsHasBeenSet
bool StatisticsHasBeenSet() const
Definition: GetInstanceMetricDataRequest.h:682
Aws::Lightsail::Model::GetInstanceMetricDataRequest::SetStartTime
void SetStartTime(Aws::Utils::DateTime &&value)
Definition: GetInstanceMetricDataRequest.h:559
AWSVector.h
Aws::Lightsail::Model::GetInstanceMetricDataRequest::GetStatistics
const Aws::Vector< MetricStatistic > & GetStatistics() const
Definition: GetInstanceMetricDataRequest.h:663
LightsailRequest.h
MetricUnit.h
Aws::Lightsail::Model::GetInstanceMetricDataRequest::SetPeriod
void SetPeriod(int value)
Definition: GetInstanceMetricDataRequest.h:529
Aws::Lightsail::Model::GetInstanceMetricDataRequest::AddStatistics
GetInstanceMetricDataRequest & AddStatistics(MetricStatistic &&value)
Definition: GetInstanceMetricDataRequest.h:796
Aws::Lightsail::Model::GetInstanceMetricDataRequest::WithInstanceName
GetInstanceMetricDataRequest & WithInstanceName(const char *value)
Definition: GetInstanceMetricDataRequest.h:80
Aws::Lightsail::Model::GetInstanceMetricDataRequest::WithUnit
GetInstanceMetricDataRequest & WithUnit(MetricUnit &&value)
Definition: GetInstanceMetricDataRequest.h:643
Aws::Lightsail::Model::GetInstanceMetricDataRequest::PeriodHasBeenSet
bool PeriodHasBeenSet() const
Definition: GetInstanceMetricDataRequest.h:520
Aws::Lightsail::Model::GetInstanceMetricDataRequest::WithInstanceName
GetInstanceMetricDataRequest & WithInstanceName(Aws::String &&value)
Definition: GetInstanceMetricDataRequest.h:75
Aws::Lightsail::Model::GetInstanceMetricDataRequest::WithStatistics
GetInstanceMetricDataRequest & WithStatistics(Aws::Vector< MetricStatistic > &&value)
Definition: GetInstanceMetricDataRequest.h:758
Aws::Lightsail::Model::GetInstanceMetricDataRequest::GetRequestSpecificHeaders
Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
Aws::Lightsail::Model::GetInstanceMetricDataRequest
Definition: GetInstanceMetricDataRequest.h:27
Aws::Lightsail::Model::MetricUnit
MetricUnit
Definition: MetricUnit.h:17
Aws::Lightsail::LightsailRequest
Definition: LightsailRequest.h:17
Aws::Lightsail::Model::GetInstanceMetricDataRequest::WithPeriod
GetInstanceMetricDataRequest & WithPeriod(int value)
Definition: GetInstanceMetricDataRequest.h:538
AWSString.h
Aws::Lightsail::Model::GetInstanceMetricDataRequest::SetInstanceName
void SetInstanceName(const char *value)
Definition: GetInstanceMetricDataRequest.h:65
Aws::Lightsail::Model::GetInstanceMetricDataRequest::EndTimeHasBeenSet
bool EndTimeHasBeenSet() const
Definition: GetInstanceMetricDataRequest.h:580
Aws::Lightsail::Model::GetInstanceMetricDataRequest::GetInstanceName
const Aws::String & GetInstanceName() const
Definition: GetInstanceMetricDataRequest.h:45
Lightsail_EXPORTS.h
Aws::Lightsail::Model::GetInstanceMetricDataRequest::GetServiceRequestName
virtual const char * GetServiceRequestName() const override
Definition: GetInstanceMetricDataRequest.h:35
Aws::Lightsail::Model::GetInstanceMetricDataRequest::WithStartTime
GetInstanceMetricDataRequest & WithStartTime(Aws::Utils::DateTime &&value)
Definition: GetInstanceMetricDataRequest.h:569
Aws::Lightsail::Model::GetInstanceMetricDataRequest::GetStartTime
const Aws::Utils::DateTime & GetStartTime() const
Definition: GetInstanceMetricDataRequest.h:544
Aws::Lightsail::Model::GetInstanceMetricDataRequest::InstanceNameHasBeenSet
bool InstanceNameHasBeenSet() const
Definition: GetInstanceMetricDataRequest.h:50
Aws::Lightsail::Model::GetInstanceMetricDataRequest::WithEndTime
GetInstanceMetricDataRequest & WithEndTime(const Aws::Utils::DateTime &value)
Definition: GetInstanceMetricDataRequest.h:595
Aws::Lightsail::Model::GetInstanceMetricDataRequest::WithMetricName
GetInstanceMetricDataRequest & WithMetricName(const InstanceMetricName &value)
Definition: GetInstanceMetricDataRequest.h:431
Aws
Definition: AccessManagementClient.h:15
MetricStatistic.h
Aws::Lightsail::Model::GetInstanceMetricDataRequest::MetricNameHasBeenSet
bool MetricNameHasBeenSet() const
Definition: GetInstanceMetricDataRequest.h:221
Aws::String
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
Aws::Lightsail::Model::GetInstanceMetricDataRequest::SetUnit
void SetUnit(const MetricUnit &value)
Definition: GetInstanceMetricDataRequest.h:622
Aws::Lightsail::Model::GetInstanceMetricDataRequest::WithInstanceName
GetInstanceMetricDataRequest & WithInstanceName(const Aws::String &value)
Definition: GetInstanceMetricDataRequest.h:70
Aws::Lightsail::Model::GetInstanceMetricDataRequest::SetEndTime
void SetEndTime(Aws::Utils::DateTime &&value)
Definition: GetInstanceMetricDataRequest.h:590
Aws::Lightsail::Model::GetInstanceMetricDataRequest::WithStatistics
GetInstanceMetricDataRequest & WithStatistics(const Aws::Vector< MetricStatistic > &value)
Definition: GetInstanceMetricDataRequest.h:739
AWS_LIGHTSAIL_API
#define AWS_LIGHTSAIL_API
Definition: Lightsail_EXPORTS.h:28
Aws::Lightsail::Model::GetInstanceMetricDataRequest::WithEndTime
GetInstanceMetricDataRequest & WithEndTime(Aws::Utils::DateTime &&value)
Definition: GetInstanceMetricDataRequest.h:600
Aws::Lightsail::Model::MetricStatistic
MetricStatistic
Definition: MetricStatistic.h:17
Aws::Lightsail::Model::InstanceMetricName
InstanceMetricName
Definition: InstanceMetricName.h:17
Aws::Lightsail::Model::GetInstanceMetricDataRequest::SetStartTime
void SetStartTime(const Aws::Utils::DateTime &value)
Definition: GetInstanceMetricDataRequest.h:554