1 /** 2 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 * SPDX-License-Identifier: Apache-2.0. 4 */ 5 6 #pragma once 7 #include <aws/ec2/EC2_EXPORTS.h> 8 #include <aws/core/utils/memory/stl/AWSStreamFwd.h> 9 #include <aws/core/utils/memory/stl/AWSString.h> 10 #include <utility> 11 12 namespace Aws 13 { 14 namespace Utils 15 { 16 namespace Xml 17 { 18 class XmlNode; 19 } // namespace Xml 20 } // namespace Utils 21 namespace EC2 22 { 23 namespace Model 24 { 25 26 /** 27 * <p>Describes a private IPv4 address for a Scheduled Instance.</p><p><h3>See 28 * Also:</h3> <a 29 * href="http://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ScheduledInstancesPrivateIpAddressConfig">AWS 30 * API Reference</a></p> 31 */ 32 class AWS_EC2_API ScheduledInstancesPrivateIpAddressConfig 33 { 34 public: 35 ScheduledInstancesPrivateIpAddressConfig(); 36 ScheduledInstancesPrivateIpAddressConfig(const Aws::Utils::Xml::XmlNode& xmlNode); 37 ScheduledInstancesPrivateIpAddressConfig& operator=(const Aws::Utils::Xml::XmlNode& xmlNode); 38 39 void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const; 40 void OutputToStream(Aws::OStream& oStream, const char* location) const; 41 42 43 /** 44 * <p>Indicates whether this is a primary IPv4 address. Otherwise, this is a 45 * secondary IPv4 address.</p> 46 */ GetPrimary()47 inline bool GetPrimary() const{ return m_primary; } 48 49 /** 50 * <p>Indicates whether this is a primary IPv4 address. Otherwise, this is a 51 * secondary IPv4 address.</p> 52 */ PrimaryHasBeenSet()53 inline bool PrimaryHasBeenSet() const { return m_primaryHasBeenSet; } 54 55 /** 56 * <p>Indicates whether this is a primary IPv4 address. Otherwise, this is a 57 * secondary IPv4 address.</p> 58 */ SetPrimary(bool value)59 inline void SetPrimary(bool value) { m_primaryHasBeenSet = true; m_primary = value; } 60 61 /** 62 * <p>Indicates whether this is a primary IPv4 address. Otherwise, this is a 63 * secondary IPv4 address.</p> 64 */ WithPrimary(bool value)65 inline ScheduledInstancesPrivateIpAddressConfig& WithPrimary(bool value) { SetPrimary(value); return *this;} 66 67 68 /** 69 * <p>The IPv4 address.</p> 70 */ GetPrivateIpAddress()71 inline const Aws::String& GetPrivateIpAddress() const{ return m_privateIpAddress; } 72 73 /** 74 * <p>The IPv4 address.</p> 75 */ PrivateIpAddressHasBeenSet()76 inline bool PrivateIpAddressHasBeenSet() const { return m_privateIpAddressHasBeenSet; } 77 78 /** 79 * <p>The IPv4 address.</p> 80 */ SetPrivateIpAddress(const Aws::String & value)81 inline void SetPrivateIpAddress(const Aws::String& value) { m_privateIpAddressHasBeenSet = true; m_privateIpAddress = value; } 82 83 /** 84 * <p>The IPv4 address.</p> 85 */ SetPrivateIpAddress(Aws::String && value)86 inline void SetPrivateIpAddress(Aws::String&& value) { m_privateIpAddressHasBeenSet = true; m_privateIpAddress = std::move(value); } 87 88 /** 89 * <p>The IPv4 address.</p> 90 */ SetPrivateIpAddress(const char * value)91 inline void SetPrivateIpAddress(const char* value) { m_privateIpAddressHasBeenSet = true; m_privateIpAddress.assign(value); } 92 93 /** 94 * <p>The IPv4 address.</p> 95 */ WithPrivateIpAddress(const Aws::String & value)96 inline ScheduledInstancesPrivateIpAddressConfig& WithPrivateIpAddress(const Aws::String& value) { SetPrivateIpAddress(value); return *this;} 97 98 /** 99 * <p>The IPv4 address.</p> 100 */ WithPrivateIpAddress(Aws::String && value)101 inline ScheduledInstancesPrivateIpAddressConfig& WithPrivateIpAddress(Aws::String&& value) { SetPrivateIpAddress(std::move(value)); return *this;} 102 103 /** 104 * <p>The IPv4 address.</p> 105 */ WithPrivateIpAddress(const char * value)106 inline ScheduledInstancesPrivateIpAddressConfig& WithPrivateIpAddress(const char* value) { SetPrivateIpAddress(value); return *this;} 107 108 private: 109 110 bool m_primary; 111 bool m_primaryHasBeenSet; 112 113 Aws::String m_privateIpAddress; 114 bool m_privateIpAddressHasBeenSet; 115 }; 116 117 } // namespace Model 118 } // namespace EC2 119 } // namespace Aws 120