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/iam/IAM_EXPORTS.h> 8 #include <aws/core/utils/memory/stl/AWSVector.h> 9 #include <aws/core/utils/memory/stl/AWSString.h> 10 #include <aws/iam/model/ResponseMetadata.h> 11 #include <aws/iam/model/SSHPublicKeyMetadata.h> 12 #include <utility> 13 14 namespace Aws 15 { 16 template<typename RESULT_TYPE> 17 class AmazonWebServiceResult; 18 19 namespace Utils 20 { 21 namespace Xml 22 { 23 class XmlDocument; 24 } // namespace Xml 25 } // namespace Utils 26 namespace IAM 27 { 28 namespace Model 29 { 30 /** 31 * <p>Contains the response to a successful <a>ListSSHPublicKeys</a> 32 * request.</p><p><h3>See Also:</h3> <a 33 * href="http://docs.aws.amazon.com/goto/WebAPI/iam-2010-05-08/ListSSHPublicKeysResponse">AWS 34 * API Reference</a></p> 35 */ 36 class AWS_IAM_API ListSSHPublicKeysResult 37 { 38 public: 39 ListSSHPublicKeysResult(); 40 ListSSHPublicKeysResult(const Aws::AmazonWebServiceResult<Aws::Utils::Xml::XmlDocument>& result); 41 ListSSHPublicKeysResult& operator=(const Aws::AmazonWebServiceResult<Aws::Utils::Xml::XmlDocument>& result); 42 43 44 /** 45 * <p>A list of the SSH public keys assigned to IAM user.</p> 46 */ GetSSHPublicKeys()47 inline const Aws::Vector<SSHPublicKeyMetadata>& GetSSHPublicKeys() const{ return m_sSHPublicKeys; } 48 49 /** 50 * <p>A list of the SSH public keys assigned to IAM user.</p> 51 */ SetSSHPublicKeys(const Aws::Vector<SSHPublicKeyMetadata> & value)52 inline void SetSSHPublicKeys(const Aws::Vector<SSHPublicKeyMetadata>& value) { m_sSHPublicKeys = value; } 53 54 /** 55 * <p>A list of the SSH public keys assigned to IAM user.</p> 56 */ SetSSHPublicKeys(Aws::Vector<SSHPublicKeyMetadata> && value)57 inline void SetSSHPublicKeys(Aws::Vector<SSHPublicKeyMetadata>&& value) { m_sSHPublicKeys = std::move(value); } 58 59 /** 60 * <p>A list of the SSH public keys assigned to IAM user.</p> 61 */ WithSSHPublicKeys(const Aws::Vector<SSHPublicKeyMetadata> & value)62 inline ListSSHPublicKeysResult& WithSSHPublicKeys(const Aws::Vector<SSHPublicKeyMetadata>& value) { SetSSHPublicKeys(value); return *this;} 63 64 /** 65 * <p>A list of the SSH public keys assigned to IAM user.</p> 66 */ WithSSHPublicKeys(Aws::Vector<SSHPublicKeyMetadata> && value)67 inline ListSSHPublicKeysResult& WithSSHPublicKeys(Aws::Vector<SSHPublicKeyMetadata>&& value) { SetSSHPublicKeys(std::move(value)); return *this;} 68 69 /** 70 * <p>A list of the SSH public keys assigned to IAM user.</p> 71 */ AddSSHPublicKeys(const SSHPublicKeyMetadata & value)72 inline ListSSHPublicKeysResult& AddSSHPublicKeys(const SSHPublicKeyMetadata& value) { m_sSHPublicKeys.push_back(value); return *this; } 73 74 /** 75 * <p>A list of the SSH public keys assigned to IAM user.</p> 76 */ AddSSHPublicKeys(SSHPublicKeyMetadata && value)77 inline ListSSHPublicKeysResult& AddSSHPublicKeys(SSHPublicKeyMetadata&& value) { m_sSHPublicKeys.push_back(std::move(value)); return *this; } 78 79 80 /** 81 * <p>A flag that indicates whether there are more items to return. If your results 82 * were truncated, you can make a subsequent pagination request using the 83 * <code>Marker</code> request parameter to retrieve more items. Note that IAM 84 * might return fewer than the <code>MaxItems</code> number of results even when 85 * there are more results available. We recommend that you check 86 * <code>IsTruncated</code> after every call to ensure that you receive all your 87 * results.</p> 88 */ GetIsTruncated()89 inline bool GetIsTruncated() const{ return m_isTruncated; } 90 91 /** 92 * <p>A flag that indicates whether there are more items to return. If your results 93 * were truncated, you can make a subsequent pagination request using the 94 * <code>Marker</code> request parameter to retrieve more items. Note that IAM 95 * might return fewer than the <code>MaxItems</code> number of results even when 96 * there are more results available. We recommend that you check 97 * <code>IsTruncated</code> after every call to ensure that you receive all your 98 * results.</p> 99 */ SetIsTruncated(bool value)100 inline void SetIsTruncated(bool value) { m_isTruncated = value; } 101 102 /** 103 * <p>A flag that indicates whether there are more items to return. If your results 104 * were truncated, you can make a subsequent pagination request using the 105 * <code>Marker</code> request parameter to retrieve more items. Note that IAM 106 * might return fewer than the <code>MaxItems</code> number of results even when 107 * there are more results available. We recommend that you check 108 * <code>IsTruncated</code> after every call to ensure that you receive all your 109 * results.</p> 110 */ WithIsTruncated(bool value)111 inline ListSSHPublicKeysResult& WithIsTruncated(bool value) { SetIsTruncated(value); return *this;} 112 113 114 /** 115 * <p>When <code>IsTruncated</code> is <code>true</code>, this element is present 116 * and contains the value to use for the <code>Marker</code> parameter in a 117 * subsequent pagination request.</p> 118 */ GetMarker()119 inline const Aws::String& GetMarker() const{ return m_marker; } 120 121 /** 122 * <p>When <code>IsTruncated</code> is <code>true</code>, this element is present 123 * and contains the value to use for the <code>Marker</code> parameter in a 124 * subsequent pagination request.</p> 125 */ SetMarker(const Aws::String & value)126 inline void SetMarker(const Aws::String& value) { m_marker = value; } 127 128 /** 129 * <p>When <code>IsTruncated</code> is <code>true</code>, this element is present 130 * and contains the value to use for the <code>Marker</code> parameter in a 131 * subsequent pagination request.</p> 132 */ SetMarker(Aws::String && value)133 inline void SetMarker(Aws::String&& value) { m_marker = std::move(value); } 134 135 /** 136 * <p>When <code>IsTruncated</code> is <code>true</code>, this element is present 137 * and contains the value to use for the <code>Marker</code> parameter in a 138 * subsequent pagination request.</p> 139 */ SetMarker(const char * value)140 inline void SetMarker(const char* value) { m_marker.assign(value); } 141 142 /** 143 * <p>When <code>IsTruncated</code> is <code>true</code>, this element is present 144 * and contains the value to use for the <code>Marker</code> parameter in a 145 * subsequent pagination request.</p> 146 */ WithMarker(const Aws::String & value)147 inline ListSSHPublicKeysResult& WithMarker(const Aws::String& value) { SetMarker(value); return *this;} 148 149 /** 150 * <p>When <code>IsTruncated</code> is <code>true</code>, this element is present 151 * and contains the value to use for the <code>Marker</code> parameter in a 152 * subsequent pagination request.</p> 153 */ WithMarker(Aws::String && value)154 inline ListSSHPublicKeysResult& WithMarker(Aws::String&& value) { SetMarker(std::move(value)); return *this;} 155 156 /** 157 * <p>When <code>IsTruncated</code> is <code>true</code>, this element is present 158 * and contains the value to use for the <code>Marker</code> parameter in a 159 * subsequent pagination request.</p> 160 */ WithMarker(const char * value)161 inline ListSSHPublicKeysResult& WithMarker(const char* value) { SetMarker(value); return *this;} 162 163 164 GetResponseMetadata()165 inline const ResponseMetadata& GetResponseMetadata() const{ return m_responseMetadata; } 166 167 SetResponseMetadata(const ResponseMetadata & value)168 inline void SetResponseMetadata(const ResponseMetadata& value) { m_responseMetadata = value; } 169 170 SetResponseMetadata(ResponseMetadata && value)171 inline void SetResponseMetadata(ResponseMetadata&& value) { m_responseMetadata = std::move(value); } 172 173 WithResponseMetadata(const ResponseMetadata & value)174 inline ListSSHPublicKeysResult& WithResponseMetadata(const ResponseMetadata& value) { SetResponseMetadata(value); return *this;} 175 176 WithResponseMetadata(ResponseMetadata && value)177 inline ListSSHPublicKeysResult& WithResponseMetadata(ResponseMetadata&& value) { SetResponseMetadata(std::move(value)); return *this;} 178 179 private: 180 181 Aws::Vector<SSHPublicKeyMetadata> m_sSHPublicKeys; 182 183 bool m_isTruncated; 184 185 Aws::String m_marker; 186 187 ResponseMetadata m_responseMetadata; 188 }; 189 190 } // namespace Model 191 } // namespace IAM 192 } // namespace Aws 193