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

You do not have sufficient access to perform this action. Access denied * errors appear when Amazon Security Lake explicitly or implicitly denies an * authorization request. An explicit denial occurs when a policy contains a Deny * statement for the specific Amazon Web Services action. An implicit denial occurs * when there is no applicable Deny statement and also no applicable Allow * statement.

See Also:

AWS * API Reference

*/ class AccessDeniedException { public: AWS_SECURITYLAKE_API AccessDeniedException(); AWS_SECURITYLAKE_API AccessDeniedException(Aws::Utils::Json::JsonView jsonValue); AWS_SECURITYLAKE_API AccessDeniedException& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_SECURITYLAKE_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

A coded string to provide more information about the access denied exception. * You can use the error code to check the exception type.

*/ inline const Aws::String& GetErrorCode() const{ return m_errorCode; } /** *

A coded string to provide more information about the access denied exception. * You can use the error code to check the exception type.

*/ inline bool ErrorCodeHasBeenSet() const { return m_errorCodeHasBeenSet; } /** *

A coded string to provide more information about the access denied exception. * You can use the error code to check the exception type.

*/ inline void SetErrorCode(const Aws::String& value) { m_errorCodeHasBeenSet = true; m_errorCode = value; } /** *

A coded string to provide more information about the access denied exception. * You can use the error code to check the exception type.

*/ inline void SetErrorCode(Aws::String&& value) { m_errorCodeHasBeenSet = true; m_errorCode = std::move(value); } /** *

A coded string to provide more information about the access denied exception. * You can use the error code to check the exception type.

*/ inline void SetErrorCode(const char* value) { m_errorCodeHasBeenSet = true; m_errorCode.assign(value); } /** *

A coded string to provide more information about the access denied exception. * You can use the error code to check the exception type.

*/ inline AccessDeniedException& WithErrorCode(const Aws::String& value) { SetErrorCode(value); return *this;} /** *

A coded string to provide more information about the access denied exception. * You can use the error code to check the exception type.

*/ inline AccessDeniedException& WithErrorCode(Aws::String&& value) { SetErrorCode(std::move(value)); return *this;} /** *

A coded string to provide more information about the access denied exception. * You can use the error code to check the exception type.

*/ inline AccessDeniedException& WithErrorCode(const char* value) { SetErrorCode(value); return *this;} inline const Aws::String& GetMessage() const{ return m_message; } inline bool MessageHasBeenSet() const { return m_messageHasBeenSet; } inline void SetMessage(const Aws::String& value) { m_messageHasBeenSet = true; m_message = value; } inline void SetMessage(Aws::String&& value) { m_messageHasBeenSet = true; m_message = std::move(value); } inline void SetMessage(const char* value) { m_messageHasBeenSet = true; m_message.assign(value); } inline AccessDeniedException& WithMessage(const Aws::String& value) { SetMessage(value); return *this;} inline AccessDeniedException& WithMessage(Aws::String&& value) { SetMessage(std::move(value)); return *this;} inline AccessDeniedException& WithMessage(const char* value) { SetMessage(value); return *this;} private: Aws::String m_errorCode; bool m_errorCodeHasBeenSet = false; Aws::String m_message; bool m_messageHasBeenSet = false; }; } // namespace Model } // namespace SecurityLake } // namespace Aws