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

The output from the GetPolicy operation.

See Also:

AWS * API Reference

*/ class GetPolicyResult { public: AWS_IOT_API GetPolicyResult(); AWS_IOT_API GetPolicyResult(const Aws::AmazonWebServiceResult& result); AWS_IOT_API GetPolicyResult& operator=(const Aws::AmazonWebServiceResult& result); /** *

The policy name.

*/ inline const Aws::String& GetPolicyName() const{ return m_policyName; } /** *

The policy name.

*/ inline void SetPolicyName(const Aws::String& value) { m_policyName = value; } /** *

The policy name.

*/ inline void SetPolicyName(Aws::String&& value) { m_policyName = std::move(value); } /** *

The policy name.

*/ inline void SetPolicyName(const char* value) { m_policyName.assign(value); } /** *

The policy name.

*/ inline GetPolicyResult& WithPolicyName(const Aws::String& value) { SetPolicyName(value); return *this;} /** *

The policy name.

*/ inline GetPolicyResult& WithPolicyName(Aws::String&& value) { SetPolicyName(std::move(value)); return *this;} /** *

The policy name.

*/ inline GetPolicyResult& WithPolicyName(const char* value) { SetPolicyName(value); return *this;} /** *

The policy ARN.

*/ inline const Aws::String& GetPolicyArn() const{ return m_policyArn; } /** *

The policy ARN.

*/ inline void SetPolicyArn(const Aws::String& value) { m_policyArn = value; } /** *

The policy ARN.

*/ inline void SetPolicyArn(Aws::String&& value) { m_policyArn = std::move(value); } /** *

The policy ARN.

*/ inline void SetPolicyArn(const char* value) { m_policyArn.assign(value); } /** *

The policy ARN.

*/ inline GetPolicyResult& WithPolicyArn(const Aws::String& value) { SetPolicyArn(value); return *this;} /** *

The policy ARN.

*/ inline GetPolicyResult& WithPolicyArn(Aws::String&& value) { SetPolicyArn(std::move(value)); return *this;} /** *

The policy ARN.

*/ inline GetPolicyResult& WithPolicyArn(const char* value) { SetPolicyArn(value); return *this;} /** *

The JSON document that describes the policy.

*/ inline const Aws::String& GetPolicyDocument() const{ return m_policyDocument; } /** *

The JSON document that describes the policy.

*/ inline void SetPolicyDocument(const Aws::String& value) { m_policyDocument = value; } /** *

The JSON document that describes the policy.

*/ inline void SetPolicyDocument(Aws::String&& value) { m_policyDocument = std::move(value); } /** *

The JSON document that describes the policy.

*/ inline void SetPolicyDocument(const char* value) { m_policyDocument.assign(value); } /** *

The JSON document that describes the policy.

*/ inline GetPolicyResult& WithPolicyDocument(const Aws::String& value) { SetPolicyDocument(value); return *this;} /** *

The JSON document that describes the policy.

*/ inline GetPolicyResult& WithPolicyDocument(Aws::String&& value) { SetPolicyDocument(std::move(value)); return *this;} /** *

The JSON document that describes the policy.

*/ inline GetPolicyResult& WithPolicyDocument(const char* value) { SetPolicyDocument(value); return *this;} /** *

The default policy version ID.

*/ inline const Aws::String& GetDefaultVersionId() const{ return m_defaultVersionId; } /** *

The default policy version ID.

*/ inline void SetDefaultVersionId(const Aws::String& value) { m_defaultVersionId = value; } /** *

The default policy version ID.

*/ inline void SetDefaultVersionId(Aws::String&& value) { m_defaultVersionId = std::move(value); } /** *

The default policy version ID.

*/ inline void SetDefaultVersionId(const char* value) { m_defaultVersionId.assign(value); } /** *

The default policy version ID.

*/ inline GetPolicyResult& WithDefaultVersionId(const Aws::String& value) { SetDefaultVersionId(value); return *this;} /** *

The default policy version ID.

*/ inline GetPolicyResult& WithDefaultVersionId(Aws::String&& value) { SetDefaultVersionId(std::move(value)); return *this;} /** *

The default policy version ID.

*/ inline GetPolicyResult& WithDefaultVersionId(const char* value) { SetDefaultVersionId(value); return *this;} /** *

The date the policy was created.

*/ inline const Aws::Utils::DateTime& GetCreationDate() const{ return m_creationDate; } /** *

The date the policy was created.

*/ inline void SetCreationDate(const Aws::Utils::DateTime& value) { m_creationDate = value; } /** *

The date the policy was created.

*/ inline void SetCreationDate(Aws::Utils::DateTime&& value) { m_creationDate = std::move(value); } /** *

The date the policy was created.

*/ inline GetPolicyResult& WithCreationDate(const Aws::Utils::DateTime& value) { SetCreationDate(value); return *this;} /** *

The date the policy was created.

*/ inline GetPolicyResult& WithCreationDate(Aws::Utils::DateTime&& value) { SetCreationDate(std::move(value)); return *this;} /** *

The date the policy was last modified.

*/ inline const Aws::Utils::DateTime& GetLastModifiedDate() const{ return m_lastModifiedDate; } /** *

The date the policy was last modified.

*/ inline void SetLastModifiedDate(const Aws::Utils::DateTime& value) { m_lastModifiedDate = value; } /** *

The date the policy was last modified.

*/ inline void SetLastModifiedDate(Aws::Utils::DateTime&& value) { m_lastModifiedDate = std::move(value); } /** *

The date the policy was last modified.

*/ inline GetPolicyResult& WithLastModifiedDate(const Aws::Utils::DateTime& value) { SetLastModifiedDate(value); return *this;} /** *

The date the policy was last modified.

*/ inline GetPolicyResult& WithLastModifiedDate(Aws::Utils::DateTime&& value) { SetLastModifiedDate(std::move(value)); return *this;} /** *

The generation ID of the policy.

*/ inline const Aws::String& GetGenerationId() const{ return m_generationId; } /** *

The generation ID of the policy.

*/ inline void SetGenerationId(const Aws::String& value) { m_generationId = value; } /** *

The generation ID of the policy.

*/ inline void SetGenerationId(Aws::String&& value) { m_generationId = std::move(value); } /** *

The generation ID of the policy.

*/ inline void SetGenerationId(const char* value) { m_generationId.assign(value); } /** *

The generation ID of the policy.

*/ inline GetPolicyResult& WithGenerationId(const Aws::String& value) { SetGenerationId(value); return *this;} /** *

The generation ID of the policy.

*/ inline GetPolicyResult& WithGenerationId(Aws::String&& value) { SetGenerationId(std::move(value)); return *this;} /** *

The generation ID of the policy.

*/ inline GetPolicyResult& WithGenerationId(const char* value) { SetGenerationId(value); return *this;} inline const Aws::String& GetRequestId() const{ return m_requestId; } inline void SetRequestId(const Aws::String& value) { m_requestId = value; } inline void SetRequestId(Aws::String&& value) { m_requestId = std::move(value); } inline void SetRequestId(const char* value) { m_requestId.assign(value); } inline GetPolicyResult& WithRequestId(const Aws::String& value) { SetRequestId(value); return *this;} inline GetPolicyResult& WithRequestId(Aws::String&& value) { SetRequestId(std::move(value)); return *this;} inline GetPolicyResult& WithRequestId(const char* value) { SetRequestId(value); return *this;} private: Aws::String m_policyName; Aws::String m_policyArn; Aws::String m_policyDocument; Aws::String m_defaultVersionId; Aws::Utils::DateTime m_creationDate; Aws::Utils::DateTime m_lastModifiedDate; Aws::String m_generationId; Aws::String m_requestId; }; } // namespace Model } // namespace IoT } // namespace Aws