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/opensearch/OpenSearchService_EXPORTS.h>
8 #include <aws/opensearch/OpenSearchServiceRequest.h>
9 #include <aws/core/utils/memory/stl/AWSString.h>
10 #include <aws/core/utils/memory/stl/AWSMap.h>
11 #include <utility>
12 
13 namespace Aws
14 {
15 namespace OpenSearchService
16 {
17 namespace Model
18 {
19 
20   /**
21    * <p> Container for the request parameters to <code> <a>UpgradeDomain</a> </code>
22    * operation. </p><p><h3>See Also:</h3>   <a
23    * href="http://docs.aws.amazon.com/goto/WebAPI/opensearch-2021-01-01/UpgradeDomainRequest">AWS
24    * API Reference</a></p>
25    */
26   class AWS_OPENSEARCHSERVICE_API UpgradeDomainRequest : public OpenSearchServiceRequest
27   {
28   public:
29     UpgradeDomainRequest();
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.
GetServiceRequestName()35     inline virtual const char* GetServiceRequestName() const override { return "UpgradeDomain"; }
36 
37     Aws::String SerializePayload() const override;
38 
39 
40 
GetDomainName()41     inline const Aws::String& GetDomainName() const{ return m_domainName; }
42 
43 
DomainNameHasBeenSet()44     inline bool DomainNameHasBeenSet() const { return m_domainNameHasBeenSet; }
45 
46 
SetDomainName(const Aws::String & value)47     inline void SetDomainName(const Aws::String& value) { m_domainNameHasBeenSet = true; m_domainName = value; }
48 
49 
SetDomainName(Aws::String && value)50     inline void SetDomainName(Aws::String&& value) { m_domainNameHasBeenSet = true; m_domainName = std::move(value); }
51 
52 
SetDomainName(const char * value)53     inline void SetDomainName(const char* value) { m_domainNameHasBeenSet = true; m_domainName.assign(value); }
54 
55 
WithDomainName(const Aws::String & value)56     inline UpgradeDomainRequest& WithDomainName(const Aws::String& value) { SetDomainName(value); return *this;}
57 
58 
WithDomainName(Aws::String && value)59     inline UpgradeDomainRequest& WithDomainName(Aws::String&& value) { SetDomainName(std::move(value)); return *this;}
60 
61 
WithDomainName(const char * value)62     inline UpgradeDomainRequest& WithDomainName(const char* value) { SetDomainName(value); return *this;}
63 
64 
65     /**
66      * <p>The version of OpenSearch you intend to upgrade the domain to.</p>
67      */
GetTargetVersion()68     inline const Aws::String& GetTargetVersion() const{ return m_targetVersion; }
69 
70     /**
71      * <p>The version of OpenSearch you intend to upgrade the domain to.</p>
72      */
TargetVersionHasBeenSet()73     inline bool TargetVersionHasBeenSet() const { return m_targetVersionHasBeenSet; }
74 
75     /**
76      * <p>The version of OpenSearch you intend to upgrade the domain to.</p>
77      */
SetTargetVersion(const Aws::String & value)78     inline void SetTargetVersion(const Aws::String& value) { m_targetVersionHasBeenSet = true; m_targetVersion = value; }
79 
80     /**
81      * <p>The version of OpenSearch you intend to upgrade the domain to.</p>
82      */
SetTargetVersion(Aws::String && value)83     inline void SetTargetVersion(Aws::String&& value) { m_targetVersionHasBeenSet = true; m_targetVersion = std::move(value); }
84 
85     /**
86      * <p>The version of OpenSearch you intend to upgrade the domain to.</p>
87      */
SetTargetVersion(const char * value)88     inline void SetTargetVersion(const char* value) { m_targetVersionHasBeenSet = true; m_targetVersion.assign(value); }
89 
90     /**
91      * <p>The version of OpenSearch you intend to upgrade the domain to.</p>
92      */
WithTargetVersion(const Aws::String & value)93     inline UpgradeDomainRequest& WithTargetVersion(const Aws::String& value) { SetTargetVersion(value); return *this;}
94 
95     /**
96      * <p>The version of OpenSearch you intend to upgrade the domain to.</p>
97      */
WithTargetVersion(Aws::String && value)98     inline UpgradeDomainRequest& WithTargetVersion(Aws::String&& value) { SetTargetVersion(std::move(value)); return *this;}
99 
100     /**
101      * <p>The version of OpenSearch you intend to upgrade the domain to.</p>
102      */
WithTargetVersion(const char * value)103     inline UpgradeDomainRequest& WithTargetVersion(const char* value) { SetTargetVersion(value); return *this;}
104 
105 
106     /**
107      * <p> When true, indicates that an upgrade eligibility check needs to be
108      * performed. Does not actually perform the upgrade. </p>
109      */
GetPerformCheckOnly()110     inline bool GetPerformCheckOnly() const{ return m_performCheckOnly; }
111 
112     /**
113      * <p> When true, indicates that an upgrade eligibility check needs to be
114      * performed. Does not actually perform the upgrade. </p>
115      */
PerformCheckOnlyHasBeenSet()116     inline bool PerformCheckOnlyHasBeenSet() const { return m_performCheckOnlyHasBeenSet; }
117 
118     /**
119      * <p> When true, indicates that an upgrade eligibility check needs to be
120      * performed. Does not actually perform the upgrade. </p>
121      */
SetPerformCheckOnly(bool value)122     inline void SetPerformCheckOnly(bool value) { m_performCheckOnlyHasBeenSet = true; m_performCheckOnly = value; }
123 
124     /**
125      * <p> When true, indicates that an upgrade eligibility check needs to be
126      * performed. Does not actually perform the upgrade. </p>
127      */
WithPerformCheckOnly(bool value)128     inline UpgradeDomainRequest& WithPerformCheckOnly(bool value) { SetPerformCheckOnly(value); return *this;}
129 
130 
131 
GetAdvancedOptions()132     inline const Aws::Map<Aws::String, Aws::String>& GetAdvancedOptions() const{ return m_advancedOptions; }
133 
134 
AdvancedOptionsHasBeenSet()135     inline bool AdvancedOptionsHasBeenSet() const { return m_advancedOptionsHasBeenSet; }
136 
137 
SetAdvancedOptions(const Aws::Map<Aws::String,Aws::String> & value)138     inline void SetAdvancedOptions(const Aws::Map<Aws::String, Aws::String>& value) { m_advancedOptionsHasBeenSet = true; m_advancedOptions = value; }
139 
140 
SetAdvancedOptions(Aws::Map<Aws::String,Aws::String> && value)141     inline void SetAdvancedOptions(Aws::Map<Aws::String, Aws::String>&& value) { m_advancedOptionsHasBeenSet = true; m_advancedOptions = std::move(value); }
142 
143 
WithAdvancedOptions(const Aws::Map<Aws::String,Aws::String> & value)144     inline UpgradeDomainRequest& WithAdvancedOptions(const Aws::Map<Aws::String, Aws::String>& value) { SetAdvancedOptions(value); return *this;}
145 
146 
WithAdvancedOptions(Aws::Map<Aws::String,Aws::String> && value)147     inline UpgradeDomainRequest& WithAdvancedOptions(Aws::Map<Aws::String, Aws::String>&& value) { SetAdvancedOptions(std::move(value)); return *this;}
148 
149 
AddAdvancedOptions(const Aws::String & key,const Aws::String & value)150     inline UpgradeDomainRequest& AddAdvancedOptions(const Aws::String& key, const Aws::String& value) { m_advancedOptionsHasBeenSet = true; m_advancedOptions.emplace(key, value); return *this; }
151 
152 
AddAdvancedOptions(Aws::String && key,const Aws::String & value)153     inline UpgradeDomainRequest& AddAdvancedOptions(Aws::String&& key, const Aws::String& value) { m_advancedOptionsHasBeenSet = true; m_advancedOptions.emplace(std::move(key), value); return *this; }
154 
155 
AddAdvancedOptions(const Aws::String & key,Aws::String && value)156     inline UpgradeDomainRequest& AddAdvancedOptions(const Aws::String& key, Aws::String&& value) { m_advancedOptionsHasBeenSet = true; m_advancedOptions.emplace(key, std::move(value)); return *this; }
157 
158 
AddAdvancedOptions(Aws::String && key,Aws::String && value)159     inline UpgradeDomainRequest& AddAdvancedOptions(Aws::String&& key, Aws::String&& value) { m_advancedOptionsHasBeenSet = true; m_advancedOptions.emplace(std::move(key), std::move(value)); return *this; }
160 
161 
AddAdvancedOptions(const char * key,Aws::String && value)162     inline UpgradeDomainRequest& AddAdvancedOptions(const char* key, Aws::String&& value) { m_advancedOptionsHasBeenSet = true; m_advancedOptions.emplace(key, std::move(value)); return *this; }
163 
164 
AddAdvancedOptions(Aws::String && key,const char * value)165     inline UpgradeDomainRequest& AddAdvancedOptions(Aws::String&& key, const char* value) { m_advancedOptionsHasBeenSet = true; m_advancedOptions.emplace(std::move(key), value); return *this; }
166 
167 
AddAdvancedOptions(const char * key,const char * value)168     inline UpgradeDomainRequest& AddAdvancedOptions(const char* key, const char* value) { m_advancedOptionsHasBeenSet = true; m_advancedOptions.emplace(key, value); return *this; }
169 
170   private:
171 
172     Aws::String m_domainName;
173     bool m_domainNameHasBeenSet;
174 
175     Aws::String m_targetVersion;
176     bool m_targetVersionHasBeenSet;
177 
178     bool m_performCheckOnly;
179     bool m_performCheckOnlyHasBeenSet;
180 
181     Aws::Map<Aws::String, Aws::String> m_advancedOptions;
182     bool m_advancedOptionsHasBeenSet;
183   };
184 
185 } // namespace Model
186 } // namespace OpenSearchService
187 } // namespace Aws
188