AWS SDK for C++  0.14.3
AWS SDK for C++
Source.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
19 
20 namespace Aws
21 {
22 namespace Utils
23 {
24 namespace Json
25 {
26  class JsonValue;
27 } // namespace Json
28 } // namespace Utils
29 namespace OpsWorks
30 {
31 namespace Model
32 {
33 
43  {
44  public:
45  Source();
46  Source(const Aws::Utils::Json::JsonValue& jsonValue);
47  Source& operator=(const Aws::Utils::Json::JsonValue& jsonValue);
48  Aws::Utils::Json::JsonValue Jsonize() const;
49 
53  inline const SourceType& GetType() const{ return m_type; }
54 
58  inline void SetType(const SourceType& value) { m_typeHasBeenSet = true; m_type = value; }
59 
63  inline void SetType(SourceType&& value) { m_typeHasBeenSet = true; m_type = value; }
64 
68  inline Source& WithType(const SourceType& value) { SetType(value); return *this;}
69 
73  inline Source& WithType(SourceType&& value) { SetType(value); return *this;}
74 
78  inline const Aws::String& GetUrl() const{ return m_url; }
79 
83  inline void SetUrl(const Aws::String& value) { m_urlHasBeenSet = true; m_url = value; }
84 
88  inline void SetUrl(Aws::String&& value) { m_urlHasBeenSet = true; m_url = value; }
89 
93  inline void SetUrl(const char* value) { m_urlHasBeenSet = true; m_url.assign(value); }
94 
98  inline Source& WithUrl(const Aws::String& value) { SetUrl(value); return *this;}
99 
103  inline Source& WithUrl(Aws::String&& value) { SetUrl(value); return *this;}
104 
108  inline Source& WithUrl(const char* value) { SetUrl(value); return *this;}
109 
116  inline const Aws::String& GetUsername() const{ return m_username; }
117 
124  inline void SetUsername(const Aws::String& value) { m_usernameHasBeenSet = true; m_username = value; }
125 
132  inline void SetUsername(Aws::String&& value) { m_usernameHasBeenSet = true; m_username = value; }
133 
140  inline void SetUsername(const char* value) { m_usernameHasBeenSet = true; m_username.assign(value); }
141 
148  inline Source& WithUsername(const Aws::String& value) { SetUsername(value); return *this;}
149 
156  inline Source& WithUsername(Aws::String&& value) { SetUsername(value); return *this;}
157 
164  inline Source& WithUsername(const char* value) { SetUsername(value); return *this;}
165 
176  inline const Aws::String& GetPassword() const{ return m_password; }
177 
188  inline void SetPassword(const Aws::String& value) { m_passwordHasBeenSet = true; m_password = value; }
189 
200  inline void SetPassword(Aws::String&& value) { m_passwordHasBeenSet = true; m_password = value; }
201 
212  inline void SetPassword(const char* value) { m_passwordHasBeenSet = true; m_password.assign(value); }
213 
224  inline Source& WithPassword(const Aws::String& value) { SetPassword(value); return *this;}
225 
236  inline Source& WithPassword(Aws::String&& value) { SetPassword(value); return *this;}
237 
248  inline Source& WithPassword(const char* value) { SetPassword(value); return *this;}
249 
254  inline const Aws::String& GetSshKey() const{ return m_sshKey; }
255 
260  inline void SetSshKey(const Aws::String& value) { m_sshKeyHasBeenSet = true; m_sshKey = value; }
261 
266  inline void SetSshKey(Aws::String&& value) { m_sshKeyHasBeenSet = true; m_sshKey = value; }
267 
272  inline void SetSshKey(const char* value) { m_sshKeyHasBeenSet = true; m_sshKey.assign(value); }
273 
278  inline Source& WithSshKey(const Aws::String& value) { SetSshKey(value); return *this;}
279 
284  inline Source& WithSshKey(Aws::String&& value) { SetSshKey(value); return *this;}
285 
290  inline Source& WithSshKey(const char* value) { SetSshKey(value); return *this;}
291 
298  inline const Aws::String& GetRevision() const{ return m_revision; }
299 
306  inline void SetRevision(const Aws::String& value) { m_revisionHasBeenSet = true; m_revision = value; }
307 
314  inline void SetRevision(Aws::String&& value) { m_revisionHasBeenSet = true; m_revision = value; }
315 
322  inline void SetRevision(const char* value) { m_revisionHasBeenSet = true; m_revision.assign(value); }
323 
330  inline Source& WithRevision(const Aws::String& value) { SetRevision(value); return *this;}
331 
338  inline Source& WithRevision(Aws::String&& value) { SetRevision(value); return *this;}
339 
346  inline Source& WithRevision(const char* value) { SetRevision(value); return *this;}
347 
348  private:
349  SourceType m_type;
350  bool m_typeHasBeenSet;
351  Aws::String m_url;
352  bool m_urlHasBeenSet;
353  Aws::String m_username;
354  bool m_usernameHasBeenSet;
355  Aws::String m_password;
356  bool m_passwordHasBeenSet;
357  Aws::String m_sshKey;
358  bool m_sshKeyHasBeenSet;
359  Aws::String m_revision;
360  bool m_revisionHasBeenSet;
361  };
362 
363 } // namespace Model
364 } // namespace OpsWorks
365 } // namespace Aws
void SetType(const SourceType &value)
Definition: Source.h:58
void SetRevision(const Aws::String &value)
Definition: Source.h:306
Source & WithUrl(const Aws::String &value)
Definition: Source.h:98
Source & WithRevision(const char *value)
Definition: Source.h:346
void SetSshKey(Aws::String &&value)
Definition: Source.h:266
Source & WithPassword(const Aws::String &value)
Definition: Source.h:224
Source & WithUsername(const char *value)
Definition: Source.h:164
const Aws::String & GetUsername() const
Definition: Source.h:116
Source & WithType(SourceType &&value)
Definition: Source.h:73
Source & WithUsername(Aws::String &&value)
Definition: Source.h:156
void SetType(SourceType &&value)
Definition: Source.h:63
const SourceType & GetType() const
Definition: Source.h:53
void SetRevision(const char *value)
Definition: Source.h:322
Source & WithSshKey(Aws::String &&value)
Definition: Source.h:284
const Aws::String & GetPassword() const
Definition: Source.h:176
Source & WithUrl(Aws::String &&value)
Definition: Source.h:103
Source & WithSshKey(const char *value)
Definition: Source.h:290
void SetPassword(const char *value)
Definition: Source.h:212
Source & WithType(const SourceType &value)
Definition: Source.h:68
void SetUrl(const Aws::String &value)
Definition: Source.h:83
Source & WithPassword(const char *value)
Definition: Source.h:248
void SetPassword(Aws::String &&value)
Definition: Source.h:200
Source & WithSshKey(const Aws::String &value)
Definition: Source.h:278
void SetUsername(Aws::String &&value)
Definition: Source.h:132
void SetRevision(Aws::String &&value)
Definition: Source.h:314
void SetPassword(const Aws::String &value)
Definition: Source.h:188
void SetUrl(Aws::String &&value)
Definition: Source.h:88
void SetUsername(const char *value)
Definition: Source.h:140
const Aws::String & GetRevision() const
Definition: Source.h:298
void SetUrl(const char *value)
Definition: Source.h:93
void SetSshKey(const char *value)
Definition: Source.h:272
Source & WithUrl(const char *value)
Definition: Source.h:108
const Aws::String & GetUrl() const
Definition: Source.h:78
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
#define AWS_OPSWORKS_API
Source & WithUsername(const Aws::String &value)
Definition: Source.h:148
Source & WithRevision(Aws::String &&value)
Definition: Source.h:338
Source & WithRevision(const Aws::String &value)
Definition: Source.h:330
const Aws::String & GetSshKey() const
Definition: Source.h:254
void SetUsername(const Aws::String &value)
Definition: Source.h:124
void SetSshKey(const Aws::String &value)
Definition: Source.h:260
Source & WithPassword(Aws::String &&value)
Definition: Source.h:236
JSON (JavaScript Object Notation).