/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include #include #include #include namespace Aws { template class AmazonWebServiceResult; namespace Utils { namespace Json { class JsonValue; } // namespace Json } // namespace Utils namespace Comprehend { namespace Model { class DetectEntitiesResult { public: AWS_COMPREHEND_API DetectEntitiesResult(); AWS_COMPREHEND_API DetectEntitiesResult(const Aws::AmazonWebServiceResult& result); AWS_COMPREHEND_API DetectEntitiesResult& operator=(const Aws::AmazonWebServiceResult& result); /** *

A collection of entities identified in the input text. For each entity, the * response provides the entity text, entity type, where the entity text begins and * ends, and the level of confidence that Amazon Comprehend has in the detection. *

If your request uses a custom entity recognition model, Amazon * Comprehend detects the entities that the model is trained to recognize. * Otherwise, it detects the default entity types. For a list of default entity * types, see Entities * in the Comprehend Developer Guide.

*/ inline const Aws::Vector& GetEntities() const{ return m_entities; } /** *

A collection of entities identified in the input text. For each entity, the * response provides the entity text, entity type, where the entity text begins and * ends, and the level of confidence that Amazon Comprehend has in the detection. *

If your request uses a custom entity recognition model, Amazon * Comprehend detects the entities that the model is trained to recognize. * Otherwise, it detects the default entity types. For a list of default entity * types, see Entities * in the Comprehend Developer Guide.

*/ inline void SetEntities(const Aws::Vector& value) { m_entities = value; } /** *

A collection of entities identified in the input text. For each entity, the * response provides the entity text, entity type, where the entity text begins and * ends, and the level of confidence that Amazon Comprehend has in the detection. *

If your request uses a custom entity recognition model, Amazon * Comprehend detects the entities that the model is trained to recognize. * Otherwise, it detects the default entity types. For a list of default entity * types, see Entities * in the Comprehend Developer Guide.

*/ inline void SetEntities(Aws::Vector&& value) { m_entities = std::move(value); } /** *

A collection of entities identified in the input text. For each entity, the * response provides the entity text, entity type, where the entity text begins and * ends, and the level of confidence that Amazon Comprehend has in the detection. *

If your request uses a custom entity recognition model, Amazon * Comprehend detects the entities that the model is trained to recognize. * Otherwise, it detects the default entity types. For a list of default entity * types, see Entities * in the Comprehend Developer Guide.

*/ inline DetectEntitiesResult& WithEntities(const Aws::Vector& value) { SetEntities(value); return *this;} /** *

A collection of entities identified in the input text. For each entity, the * response provides the entity text, entity type, where the entity text begins and * ends, and the level of confidence that Amazon Comprehend has in the detection. *

If your request uses a custom entity recognition model, Amazon * Comprehend detects the entities that the model is trained to recognize. * Otherwise, it detects the default entity types. For a list of default entity * types, see Entities * in the Comprehend Developer Guide.

*/ inline DetectEntitiesResult& WithEntities(Aws::Vector&& value) { SetEntities(std::move(value)); return *this;} /** *

A collection of entities identified in the input text. For each entity, the * response provides the entity text, entity type, where the entity text begins and * ends, and the level of confidence that Amazon Comprehend has in the detection. *

If your request uses a custom entity recognition model, Amazon * Comprehend detects the entities that the model is trained to recognize. * Otherwise, it detects the default entity types. For a list of default entity * types, see Entities * in the Comprehend Developer Guide.

*/ inline DetectEntitiesResult& AddEntities(const Entity& value) { m_entities.push_back(value); return *this; } /** *

A collection of entities identified in the input text. For each entity, the * response provides the entity text, entity type, where the entity text begins and * ends, and the level of confidence that Amazon Comprehend has in the detection. *

If your request uses a custom entity recognition model, Amazon * Comprehend detects the entities that the model is trained to recognize. * Otherwise, it detects the default entity types. For a list of default entity * types, see Entities * in the Comprehend Developer Guide.

*/ inline DetectEntitiesResult& AddEntities(Entity&& value) { m_entities.push_back(std::move(value)); return *this; } /** *

Information about the document, discovered during text extraction. This field * is present in the response only if your request used the Byte * parameter.

*/ inline const DocumentMetadata& GetDocumentMetadata() const{ return m_documentMetadata; } /** *

Information about the document, discovered during text extraction. This field * is present in the response only if your request used the Byte * parameter.

*/ inline void SetDocumentMetadata(const DocumentMetadata& value) { m_documentMetadata = value; } /** *

Information about the document, discovered during text extraction. This field * is present in the response only if your request used the Byte * parameter.

*/ inline void SetDocumentMetadata(DocumentMetadata&& value) { m_documentMetadata = std::move(value); } /** *

Information about the document, discovered during text extraction. This field * is present in the response only if your request used the Byte * parameter.

*/ inline DetectEntitiesResult& WithDocumentMetadata(const DocumentMetadata& value) { SetDocumentMetadata(value); return *this;} /** *

Information about the document, discovered during text extraction. This field * is present in the response only if your request used the Byte * parameter.

*/ inline DetectEntitiesResult& WithDocumentMetadata(DocumentMetadata&& value) { SetDocumentMetadata(std::move(value)); return *this;} /** *

The document type for each page in the input document. This field is present * in the response only if your request used the Byte parameter.

*/ inline const Aws::Vector& GetDocumentType() const{ return m_documentType; } /** *

The document type for each page in the input document. This field is present * in the response only if your request used the Byte parameter.

*/ inline void SetDocumentType(const Aws::Vector& value) { m_documentType = value; } /** *

The document type for each page in the input document. This field is present * in the response only if your request used the Byte parameter.

*/ inline void SetDocumentType(Aws::Vector&& value) { m_documentType = std::move(value); } /** *

The document type for each page in the input document. This field is present * in the response only if your request used the Byte parameter.

*/ inline DetectEntitiesResult& WithDocumentType(const Aws::Vector& value) { SetDocumentType(value); return *this;} /** *

The document type for each page in the input document. This field is present * in the response only if your request used the Byte parameter.

*/ inline DetectEntitiesResult& WithDocumentType(Aws::Vector&& value) { SetDocumentType(std::move(value)); return *this;} /** *

The document type for each page in the input document. This field is present * in the response only if your request used the Byte parameter.

*/ inline DetectEntitiesResult& AddDocumentType(const DocumentTypeListItem& value) { m_documentType.push_back(value); return *this; } /** *

The document type for each page in the input document. This field is present * in the response only if your request used the Byte parameter.

*/ inline DetectEntitiesResult& AddDocumentType(DocumentTypeListItem&& value) { m_documentType.push_back(std::move(value)); return *this; } /** *

Information about each block of text in the input document. Blocks are * nested. A page block contains a block for each line of text, which contains a * block for each word.

The Block content for a Word input * document does not include a Geometry field.

The * Block field is not present in the response for plain-text * inputs.

*/ inline const Aws::Vector& GetBlocks() const{ return m_blocks; } /** *

Information about each block of text in the input document. Blocks are * nested. A page block contains a block for each line of text, which contains a * block for each word.

The Block content for a Word input * document does not include a Geometry field.

The * Block field is not present in the response for plain-text * inputs.

*/ inline void SetBlocks(const Aws::Vector& value) { m_blocks = value; } /** *

Information about each block of text in the input document. Blocks are * nested. A page block contains a block for each line of text, which contains a * block for each word.

The Block content for a Word input * document does not include a Geometry field.

The * Block field is not present in the response for plain-text * inputs.

*/ inline void SetBlocks(Aws::Vector&& value) { m_blocks = std::move(value); } /** *

Information about each block of text in the input document. Blocks are * nested. A page block contains a block for each line of text, which contains a * block for each word.

The Block content for a Word input * document does not include a Geometry field.

The * Block field is not present in the response for plain-text * inputs.

*/ inline DetectEntitiesResult& WithBlocks(const Aws::Vector& value) { SetBlocks(value); return *this;} /** *

Information about each block of text in the input document. Blocks are * nested. A page block contains a block for each line of text, which contains a * block for each word.

The Block content for a Word input * document does not include a Geometry field.

The * Block field is not present in the response for plain-text * inputs.

*/ inline DetectEntitiesResult& WithBlocks(Aws::Vector&& value) { SetBlocks(std::move(value)); return *this;} /** *

Information about each block of text in the input document. Blocks are * nested. A page block contains a block for each line of text, which contains a * block for each word.

The Block content for a Word input * document does not include a Geometry field.

The * Block field is not present in the response for plain-text * inputs.

*/ inline DetectEntitiesResult& AddBlocks(const Block& value) { m_blocks.push_back(value); return *this; } /** *

Information about each block of text in the input document. Blocks are * nested. A page block contains a block for each line of text, which contains a * block for each word.

The Block content for a Word input * document does not include a Geometry field.

The * Block field is not present in the response for plain-text * inputs.

*/ inline DetectEntitiesResult& AddBlocks(Block&& value) { m_blocks.push_back(std::move(value)); return *this; } /** *

Page-level errors that the system detected while processing the input * document. The field is empty if the system encountered no errors.

*/ inline const Aws::Vector& GetErrors() const{ return m_errors; } /** *

Page-level errors that the system detected while processing the input * document. The field is empty if the system encountered no errors.

*/ inline void SetErrors(const Aws::Vector& value) { m_errors = value; } /** *

Page-level errors that the system detected while processing the input * document. The field is empty if the system encountered no errors.

*/ inline void SetErrors(Aws::Vector&& value) { m_errors = std::move(value); } /** *

Page-level errors that the system detected while processing the input * document. The field is empty if the system encountered no errors.

*/ inline DetectEntitiesResult& WithErrors(const Aws::Vector& value) { SetErrors(value); return *this;} /** *

Page-level errors that the system detected while processing the input * document. The field is empty if the system encountered no errors.

*/ inline DetectEntitiesResult& WithErrors(Aws::Vector&& value) { SetErrors(std::move(value)); return *this;} /** *

Page-level errors that the system detected while processing the input * document. The field is empty if the system encountered no errors.

*/ inline DetectEntitiesResult& AddErrors(const ErrorsListItem& value) { m_errors.push_back(value); return *this; } /** *

Page-level errors that the system detected while processing the input * document. The field is empty if the system encountered no errors.

*/ inline DetectEntitiesResult& AddErrors(ErrorsListItem&& value) { m_errors.push_back(std::move(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 DetectEntitiesResult& WithRequestId(const Aws::String& value) { SetRequestId(value); return *this;} inline DetectEntitiesResult& WithRequestId(Aws::String&& value) { SetRequestId(std::move(value)); return *this;} inline DetectEntitiesResult& WithRequestId(const char* value) { SetRequestId(value); return *this;} private: Aws::Vector m_entities; DocumentMetadata m_documentMetadata; Aws::Vector m_documentType; Aws::Vector m_blocks; Aws::Vector m_errors; Aws::String m_requestId; }; } // namespace Model } // namespace Comprehend } // namespace Aws