AWS SDK for C++  0.12.9
AWS SDK for C++
CreateVolumePermission.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 
40  {
41  public:
44  CreateVolumePermission& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
45 
46  void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
47  void OutputToStream(Aws::OStream& oStream, const char* location) const;
48 
53  inline const Aws::String& GetUserId() const{ return m_userId; }
54 
59  inline void SetUserId(const Aws::String& value) { m_userIdHasBeenSet = true; m_userId = value; }
60 
65  inline void SetUserId(Aws::String&& value) { m_userIdHasBeenSet = true; m_userId = value; }
66 
71  inline void SetUserId(const char* value) { m_userIdHasBeenSet = true; m_userId.assign(value); }
72 
77  inline CreateVolumePermission& WithUserId(const Aws::String& value) { SetUserId(value); return *this;}
78 
83  inline CreateVolumePermission& WithUserId(Aws::String&& value) { SetUserId(value); return *this;}
84 
89  inline CreateVolumePermission& WithUserId(const char* value) { SetUserId(value); return *this;}
90 
95  inline const PermissionGroup& GetGroup() const{ return m_group; }
96 
101  inline void SetGroup(const PermissionGroup& value) { m_groupHasBeenSet = true; m_group = value; }
102 
107  inline void SetGroup(PermissionGroup&& value) { m_groupHasBeenSet = true; m_group = value; }
108 
113  inline CreateVolumePermission& WithGroup(const PermissionGroup& value) { SetGroup(value); return *this;}
114 
119  inline CreateVolumePermission& WithGroup(PermissionGroup&& value) { SetGroup(value); return *this;}
120 
121  private:
122  Aws::String m_userId;
123  bool m_userIdHasBeenSet;
124  PermissionGroup m_group;
125  bool m_groupHasBeenSet;
126  };
127 
128 } // namespace Model
129 } // namespace EC2
130 } // namespace Aws
void SetUserId(const Aws::String &value)
CreateVolumePermission & WithUserId(const char *value)
CreateVolumePermission & WithUserId(Aws::String &&value)
CreateVolumePermission & WithUserId(const Aws::String &value)
const PermissionGroup & GetGroup() const
std::basic_ostream< char, std::char_traits< char > > OStream
Definition: AWSStreamFwd.h:31
CreateVolumePermission & WithGroup(const PermissionGroup &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
CreateVolumePermission & WithGroup(PermissionGroup &&value)
void SetGroup(const PermissionGroup &value)
JSON (JavaScript Object Notation).