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

Text extraction encountered one or more page-level errors in the input * document.

The ErrorCode contains one of the following * values:

  • TEXTRACT_BAD_PAGE - Amazon Textract cannot read the * page. For more information about page limits in Amazon Textract, see Page * Quotas in Amazon Textract.

  • *

    TEXTRACT_PROVISIONED_THROUGHPUT_EXCEEDED - The number of requests exceeded * your throughput limit. For more information about throughput quotas in Amazon * Textract, see * Default quotas in Amazon Textract.

  • *

    PAGE_CHARACTERS_EXCEEDED - Too many text characters on the page (10,000 * characters maximum).

  • PAGE_SIZE_EXCEEDED - The maximum page * size is 10 MB.

  • INTERNAL_SERVER_ERROR - The request encountered * a service issue. Try the API request again.

See Also:

* AWS * API Reference

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

Page number where the error occurred.

*/ inline int GetPage() const{ return m_page; } /** *

Page number where the error occurred.

*/ inline bool PageHasBeenSet() const { return m_pageHasBeenSet; } /** *

Page number where the error occurred.

*/ inline void SetPage(int value) { m_pageHasBeenSet = true; m_page = value; } /** *

Page number where the error occurred.

*/ inline ErrorsListItem& WithPage(int value) { SetPage(value); return *this;} /** *

Error code for the cause of the error.

*/ inline const PageBasedErrorCode& GetErrorCode() const{ return m_errorCode; } /** *

Error code for the cause of the error.

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

Error code for the cause of the error.

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

Error code for the cause of the error.

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

Error code for the cause of the error.

*/ inline ErrorsListItem& WithErrorCode(const PageBasedErrorCode& value) { SetErrorCode(value); return *this;} /** *

Error code for the cause of the error.

*/ inline ErrorsListItem& WithErrorCode(PageBasedErrorCode&& value) { SetErrorCode(std::move(value)); return *this;} /** *

Text message explaining the reason for the error.

*/ inline const Aws::String& GetErrorMessage() const{ return m_errorMessage; } /** *

Text message explaining the reason for the error.

*/ inline bool ErrorMessageHasBeenSet() const { return m_errorMessageHasBeenSet; } /** *

Text message explaining the reason for the error.

*/ inline void SetErrorMessage(const Aws::String& value) { m_errorMessageHasBeenSet = true; m_errorMessage = value; } /** *

Text message explaining the reason for the error.

*/ inline void SetErrorMessage(Aws::String&& value) { m_errorMessageHasBeenSet = true; m_errorMessage = std::move(value); } /** *

Text message explaining the reason for the error.

*/ inline void SetErrorMessage(const char* value) { m_errorMessageHasBeenSet = true; m_errorMessage.assign(value); } /** *

Text message explaining the reason for the error.

*/ inline ErrorsListItem& WithErrorMessage(const Aws::String& value) { SetErrorMessage(value); return *this;} /** *

Text message explaining the reason for the error.

*/ inline ErrorsListItem& WithErrorMessage(Aws::String&& value) { SetErrorMessage(std::move(value)); return *this;} /** *

Text message explaining the reason for the error.

*/ inline ErrorsListItem& WithErrorMessage(const char* value) { SetErrorMessage(value); return *this;} private: int m_page; bool m_pageHasBeenSet = false; PageBasedErrorCode m_errorCode; bool m_errorCodeHasBeenSet = false; Aws::String m_errorMessage; bool m_errorMessageHasBeenSet = false; }; } // namespace Model } // namespace Comprehend } // namespace Aws