/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include namespace Aws { namespace Utils { namespace Xml { class XmlNode; } // namespace Xml } // namespace Utils namespace IAM { namespace Model { /** *

Contains information about an SSH public key.

This data type is used * as a response element in the GetSSHPublicKey and * UploadSSHPublicKey operations.

See Also:

AWS * API Reference

*/ class SSHPublicKey { public: AWS_IAM_API SSHPublicKey(); AWS_IAM_API SSHPublicKey(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_IAM_API SSHPublicKey& operator=(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_IAM_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const; AWS_IAM_API void OutputToStream(Aws::OStream& oStream, const char* location) const; /** *

The name of the IAM user associated with the SSH public key.

*/ inline const Aws::String& GetUserName() const{ return m_userName; } /** *

The name of the IAM user associated with the SSH public key.

*/ inline bool UserNameHasBeenSet() const { return m_userNameHasBeenSet; } /** *

The name of the IAM user associated with the SSH public key.

*/ inline void SetUserName(const Aws::String& value) { m_userNameHasBeenSet = true; m_userName = value; } /** *

The name of the IAM user associated with the SSH public key.

*/ inline void SetUserName(Aws::String&& value) { m_userNameHasBeenSet = true; m_userName = std::move(value); } /** *

The name of the IAM user associated with the SSH public key.

*/ inline void SetUserName(const char* value) { m_userNameHasBeenSet = true; m_userName.assign(value); } /** *

The name of the IAM user associated with the SSH public key.

*/ inline SSHPublicKey& WithUserName(const Aws::String& value) { SetUserName(value); return *this;} /** *

The name of the IAM user associated with the SSH public key.

*/ inline SSHPublicKey& WithUserName(Aws::String&& value) { SetUserName(std::move(value)); return *this;} /** *

The name of the IAM user associated with the SSH public key.

*/ inline SSHPublicKey& WithUserName(const char* value) { SetUserName(value); return *this;} /** *

The unique identifier for the SSH public key.

*/ inline const Aws::String& GetSSHPublicKeyId() const{ return m_sSHPublicKeyId; } /** *

The unique identifier for the SSH public key.

*/ inline bool SSHPublicKeyIdHasBeenSet() const { return m_sSHPublicKeyIdHasBeenSet; } /** *

The unique identifier for the SSH public key.

*/ inline void SetSSHPublicKeyId(const Aws::String& value) { m_sSHPublicKeyIdHasBeenSet = true; m_sSHPublicKeyId = value; } /** *

The unique identifier for the SSH public key.

*/ inline void SetSSHPublicKeyId(Aws::String&& value) { m_sSHPublicKeyIdHasBeenSet = true; m_sSHPublicKeyId = std::move(value); } /** *

The unique identifier for the SSH public key.

*/ inline void SetSSHPublicKeyId(const char* value) { m_sSHPublicKeyIdHasBeenSet = true; m_sSHPublicKeyId.assign(value); } /** *

The unique identifier for the SSH public key.

*/ inline SSHPublicKey& WithSSHPublicKeyId(const Aws::String& value) { SetSSHPublicKeyId(value); return *this;} /** *

The unique identifier for the SSH public key.

*/ inline SSHPublicKey& WithSSHPublicKeyId(Aws::String&& value) { SetSSHPublicKeyId(std::move(value)); return *this;} /** *

The unique identifier for the SSH public key.

*/ inline SSHPublicKey& WithSSHPublicKeyId(const char* value) { SetSSHPublicKeyId(value); return *this;} /** *

The MD5 message digest of the SSH public key.

*/ inline const Aws::String& GetFingerprint() const{ return m_fingerprint; } /** *

The MD5 message digest of the SSH public key.

*/ inline bool FingerprintHasBeenSet() const { return m_fingerprintHasBeenSet; } /** *

The MD5 message digest of the SSH public key.

*/ inline void SetFingerprint(const Aws::String& value) { m_fingerprintHasBeenSet = true; m_fingerprint = value; } /** *

The MD5 message digest of the SSH public key.

*/ inline void SetFingerprint(Aws::String&& value) { m_fingerprintHasBeenSet = true; m_fingerprint = std::move(value); } /** *

The MD5 message digest of the SSH public key.

*/ inline void SetFingerprint(const char* value) { m_fingerprintHasBeenSet = true; m_fingerprint.assign(value); } /** *

The MD5 message digest of the SSH public key.

*/ inline SSHPublicKey& WithFingerprint(const Aws::String& value) { SetFingerprint(value); return *this;} /** *

The MD5 message digest of the SSH public key.

*/ inline SSHPublicKey& WithFingerprint(Aws::String&& value) { SetFingerprint(std::move(value)); return *this;} /** *

The MD5 message digest of the SSH public key.

*/ inline SSHPublicKey& WithFingerprint(const char* value) { SetFingerprint(value); return *this;} /** *

The SSH public key.

*/ inline const Aws::String& GetSSHPublicKeyBody() const{ return m_sSHPublicKeyBody; } /** *

The SSH public key.

*/ inline bool SSHPublicKeyBodyHasBeenSet() const { return m_sSHPublicKeyBodyHasBeenSet; } /** *

The SSH public key.

*/ inline void SetSSHPublicKeyBody(const Aws::String& value) { m_sSHPublicKeyBodyHasBeenSet = true; m_sSHPublicKeyBody = value; } /** *

The SSH public key.

*/ inline void SetSSHPublicKeyBody(Aws::String&& value) { m_sSHPublicKeyBodyHasBeenSet = true; m_sSHPublicKeyBody = std::move(value); } /** *

The SSH public key.

*/ inline void SetSSHPublicKeyBody(const char* value) { m_sSHPublicKeyBodyHasBeenSet = true; m_sSHPublicKeyBody.assign(value); } /** *

The SSH public key.

*/ inline SSHPublicKey& WithSSHPublicKeyBody(const Aws::String& value) { SetSSHPublicKeyBody(value); return *this;} /** *

The SSH public key.

*/ inline SSHPublicKey& WithSSHPublicKeyBody(Aws::String&& value) { SetSSHPublicKeyBody(std::move(value)); return *this;} /** *

The SSH public key.

*/ inline SSHPublicKey& WithSSHPublicKeyBody(const char* value) { SetSSHPublicKeyBody(value); return *this;} /** *

The status of the SSH public key. Active means that the key can * be used for authentication with an CodeCommit repository. Inactive * means that the key cannot be used.

*/ inline const StatusType& GetStatus() const{ return m_status; } /** *

The status of the SSH public key. Active means that the key can * be used for authentication with an CodeCommit repository. Inactive * means that the key cannot be used.

*/ inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; } /** *

The status of the SSH public key. Active means that the key can * be used for authentication with an CodeCommit repository. Inactive * means that the key cannot be used.

*/ inline void SetStatus(const StatusType& value) { m_statusHasBeenSet = true; m_status = value; } /** *

The status of the SSH public key. Active means that the key can * be used for authentication with an CodeCommit repository. Inactive * means that the key cannot be used.

*/ inline void SetStatus(StatusType&& value) { m_statusHasBeenSet = true; m_status = std::move(value); } /** *

The status of the SSH public key. Active means that the key can * be used for authentication with an CodeCommit repository. Inactive * means that the key cannot be used.

*/ inline SSHPublicKey& WithStatus(const StatusType& value) { SetStatus(value); return *this;} /** *

The status of the SSH public key. Active means that the key can * be used for authentication with an CodeCommit repository. Inactive * means that the key cannot be used.

*/ inline SSHPublicKey& WithStatus(StatusType&& value) { SetStatus(std::move(value)); return *this;} /** *

The date and time, in ISO 8601 * date-time format, when the SSH public key was uploaded.

*/ inline const Aws::Utils::DateTime& GetUploadDate() const{ return m_uploadDate; } /** *

The date and time, in ISO 8601 * date-time format, when the SSH public key was uploaded.

*/ inline bool UploadDateHasBeenSet() const { return m_uploadDateHasBeenSet; } /** *

The date and time, in ISO 8601 * date-time format, when the SSH public key was uploaded.

*/ inline void SetUploadDate(const Aws::Utils::DateTime& value) { m_uploadDateHasBeenSet = true; m_uploadDate = value; } /** *

The date and time, in ISO 8601 * date-time format, when the SSH public key was uploaded.

*/ inline void SetUploadDate(Aws::Utils::DateTime&& value) { m_uploadDateHasBeenSet = true; m_uploadDate = std::move(value); } /** *

The date and time, in ISO 8601 * date-time format, when the SSH public key was uploaded.

*/ inline SSHPublicKey& WithUploadDate(const Aws::Utils::DateTime& value) { SetUploadDate(value); return *this;} /** *

The date and time, in ISO 8601 * date-time format, when the SSH public key was uploaded.

*/ inline SSHPublicKey& WithUploadDate(Aws::Utils::DateTime&& value) { SetUploadDate(std::move(value)); return *this;} private: Aws::String m_userName; bool m_userNameHasBeenSet = false; Aws::String m_sSHPublicKeyId; bool m_sSHPublicKeyIdHasBeenSet = false; Aws::String m_fingerprint; bool m_fingerprintHasBeenSet = false; Aws::String m_sSHPublicKeyBody; bool m_sSHPublicKeyBodyHasBeenSet = false; StatusType m_status; bool m_statusHasBeenSet = false; Aws::Utils::DateTime m_uploadDate; bool m_uploadDateHasBeenSet = false; }; } // namespace Model } // namespace IAM } // namespace Aws