AWS SDK for C++  0.12.9
AWS SDK for C++
ReservedInstancesConfiguration.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
16 #include <aws/ec2/EC2_EXPORTS.h>
20 
21 namespace Aws
22 {
23 namespace Utils
24 {
25 namespace Xml
26 {
27  class XmlNode;
28 } // namespace Xml
29 } // namespace Utils
30 namespace EC2
31 {
32 namespace Model
33 {
34 
39  {
40  public:
44 
45  void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
46  void OutputToStream(Aws::OStream& oStream, const char* location) const;
47 
51  inline const Aws::String& GetAvailabilityZone() const{ return m_availabilityZone; }
52 
56  inline void SetAvailabilityZone(const Aws::String& value) { m_availabilityZoneHasBeenSet = true; m_availabilityZone = value; }
57 
61  inline void SetAvailabilityZone(Aws::String&& value) { m_availabilityZoneHasBeenSet = true; m_availabilityZone = value; }
62 
66  inline void SetAvailabilityZone(const char* value) { m_availabilityZoneHasBeenSet = true; m_availabilityZone.assign(value); }
67 
71  inline ReservedInstancesConfiguration& WithAvailabilityZone(const Aws::String& value) { SetAvailabilityZone(value); return *this;}
72 
76  inline ReservedInstancesConfiguration& WithAvailabilityZone(Aws::String&& value) { SetAvailabilityZone(value); return *this;}
77 
81  inline ReservedInstancesConfiguration& WithAvailabilityZone(const char* value) { SetAvailabilityZone(value); return *this;}
82 
87  inline const Aws::String& GetPlatform() const{ return m_platform; }
88 
93  inline void SetPlatform(const Aws::String& value) { m_platformHasBeenSet = true; m_platform = value; }
94 
99  inline void SetPlatform(Aws::String&& value) { m_platformHasBeenSet = true; m_platform = value; }
100 
105  inline void SetPlatform(const char* value) { m_platformHasBeenSet = true; m_platform.assign(value); }
106 
111  inline ReservedInstancesConfiguration& WithPlatform(const Aws::String& value) { SetPlatform(value); return *this;}
112 
117  inline ReservedInstancesConfiguration& WithPlatform(Aws::String&& value) { SetPlatform(value); return *this;}
118 
123  inline ReservedInstancesConfiguration& WithPlatform(const char* value) { SetPlatform(value); return *this;}
124 
128  inline long GetInstanceCount() const{ return m_instanceCount; }
129 
133  inline void SetInstanceCount(long value) { m_instanceCountHasBeenSet = true; m_instanceCount = value; }
134 
138  inline ReservedInstancesConfiguration& WithInstanceCount(long value) { SetInstanceCount(value); return *this;}
139 
143  inline const InstanceType& GetInstanceType() const{ return m_instanceType; }
144 
148  inline void SetInstanceType(const InstanceType& value) { m_instanceTypeHasBeenSet = true; m_instanceType = value; }
149 
153  inline void SetInstanceType(InstanceType&& value) { m_instanceTypeHasBeenSet = true; m_instanceType = value; }
154 
158  inline ReservedInstancesConfiguration& WithInstanceType(const InstanceType& value) { SetInstanceType(value); return *this;}
159 
163  inline ReservedInstancesConfiguration& WithInstanceType(InstanceType&& value) { SetInstanceType(value); return *this;}
164 
165  private:
166  Aws::String m_availabilityZone;
167  bool m_availabilityZoneHasBeenSet;
168  Aws::String m_platform;
169  bool m_platformHasBeenSet;
170  long m_instanceCount;
171  bool m_instanceCountHasBeenSet;
172  InstanceType m_instanceType;
173  bool m_instanceTypeHasBeenSet;
174  };
175 
176 } // namespace Model
177 } // namespace EC2
178 } // namespace Aws
ReservedInstancesConfiguration & WithPlatform(Aws::String &&value)
ReservedInstancesConfiguration & WithInstanceType(InstanceType &&value)
ReservedInstancesConfiguration & WithAvailabilityZone(const char *value)
ReservedInstancesConfiguration & WithPlatform(const char *value)
std::basic_ostream< char, std::char_traits< char > > OStream
Definition: AWSStreamFwd.h:31
ReservedInstancesConfiguration & WithInstanceType(const InstanceType &value)
ReservedInstancesConfiguration & WithAvailabilityZone(const Aws::String &value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
#define AWS_EC2_API
Definition: EC2_EXPORTS.h:34
ReservedInstancesConfiguration & WithInstanceCount(long value)
ReservedInstancesConfiguration & WithPlatform(const Aws::String &value)
ReservedInstancesConfiguration & WithAvailabilityZone(Aws::String &&value)
JSON (JavaScript Object Notation).