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

A single retrieved relevant passage result.

See Also:

AWS * API Reference

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

The identifier of the relevant passage result.

*/ inline const Aws::String& GetId() const{ return m_id; } /** *

The identifier of the relevant passage result.

*/ inline bool IdHasBeenSet() const { return m_idHasBeenSet; } /** *

The identifier of the relevant passage result.

*/ inline void SetId(const Aws::String& value) { m_idHasBeenSet = true; m_id = value; } /** *

The identifier of the relevant passage result.

*/ inline void SetId(Aws::String&& value) { m_idHasBeenSet = true; m_id = std::move(value); } /** *

The identifier of the relevant passage result.

*/ inline void SetId(const char* value) { m_idHasBeenSet = true; m_id.assign(value); } /** *

The identifier of the relevant passage result.

*/ inline RetrieveResultItem& WithId(const Aws::String& value) { SetId(value); return *this;} /** *

The identifier of the relevant passage result.

*/ inline RetrieveResultItem& WithId(Aws::String&& value) { SetId(std::move(value)); return *this;} /** *

The identifier of the relevant passage result.

*/ inline RetrieveResultItem& WithId(const char* value) { SetId(value); return *this;} /** *

The identifier of the document.

*/ inline const Aws::String& GetDocumentId() const{ return m_documentId; } /** *

The identifier of the document.

*/ inline bool DocumentIdHasBeenSet() const { return m_documentIdHasBeenSet; } /** *

The identifier of the document.

*/ inline void SetDocumentId(const Aws::String& value) { m_documentIdHasBeenSet = true; m_documentId = value; } /** *

The identifier of the document.

*/ inline void SetDocumentId(Aws::String&& value) { m_documentIdHasBeenSet = true; m_documentId = std::move(value); } /** *

The identifier of the document.

*/ inline void SetDocumentId(const char* value) { m_documentIdHasBeenSet = true; m_documentId.assign(value); } /** *

The identifier of the document.

*/ inline RetrieveResultItem& WithDocumentId(const Aws::String& value) { SetDocumentId(value); return *this;} /** *

The identifier of the document.

*/ inline RetrieveResultItem& WithDocumentId(Aws::String&& value) { SetDocumentId(std::move(value)); return *this;} /** *

The identifier of the document.

*/ inline RetrieveResultItem& WithDocumentId(const char* value) { SetDocumentId(value); return *this;} /** *

The title of the document.

*/ inline const Aws::String& GetDocumentTitle() const{ return m_documentTitle; } /** *

The title of the document.

*/ inline bool DocumentTitleHasBeenSet() const { return m_documentTitleHasBeenSet; } /** *

The title of the document.

*/ inline void SetDocumentTitle(const Aws::String& value) { m_documentTitleHasBeenSet = true; m_documentTitle = value; } /** *

The title of the document.

*/ inline void SetDocumentTitle(Aws::String&& value) { m_documentTitleHasBeenSet = true; m_documentTitle = std::move(value); } /** *

The title of the document.

*/ inline void SetDocumentTitle(const char* value) { m_documentTitleHasBeenSet = true; m_documentTitle.assign(value); } /** *

The title of the document.

*/ inline RetrieveResultItem& WithDocumentTitle(const Aws::String& value) { SetDocumentTitle(value); return *this;} /** *

The title of the document.

*/ inline RetrieveResultItem& WithDocumentTitle(Aws::String&& value) { SetDocumentTitle(std::move(value)); return *this;} /** *

The title of the document.

*/ inline RetrieveResultItem& WithDocumentTitle(const char* value) { SetDocumentTitle(value); return *this;} /** *

The contents of the relevant passage.

*/ inline const Aws::String& GetContent() const{ return m_content; } /** *

The contents of the relevant passage.

*/ inline bool ContentHasBeenSet() const { return m_contentHasBeenSet; } /** *

The contents of the relevant passage.

*/ inline void SetContent(const Aws::String& value) { m_contentHasBeenSet = true; m_content = value; } /** *

The contents of the relevant passage.

*/ inline void SetContent(Aws::String&& value) { m_contentHasBeenSet = true; m_content = std::move(value); } /** *

The contents of the relevant passage.

*/ inline void SetContent(const char* value) { m_contentHasBeenSet = true; m_content.assign(value); } /** *

The contents of the relevant passage.

*/ inline RetrieveResultItem& WithContent(const Aws::String& value) { SetContent(value); return *this;} /** *

The contents of the relevant passage.

*/ inline RetrieveResultItem& WithContent(Aws::String&& value) { SetContent(std::move(value)); return *this;} /** *

The contents of the relevant passage.

*/ inline RetrieveResultItem& WithContent(const char* value) { SetContent(value); return *this;} /** *

The URI of the original location of the document.

*/ inline const Aws::String& GetDocumentURI() const{ return m_documentURI; } /** *

The URI of the original location of the document.

*/ inline bool DocumentURIHasBeenSet() const { return m_documentURIHasBeenSet; } /** *

The URI of the original location of the document.

*/ inline void SetDocumentURI(const Aws::String& value) { m_documentURIHasBeenSet = true; m_documentURI = value; } /** *

The URI of the original location of the document.

*/ inline void SetDocumentURI(Aws::String&& value) { m_documentURIHasBeenSet = true; m_documentURI = std::move(value); } /** *

The URI of the original location of the document.

*/ inline void SetDocumentURI(const char* value) { m_documentURIHasBeenSet = true; m_documentURI.assign(value); } /** *

The URI of the original location of the document.

*/ inline RetrieveResultItem& WithDocumentURI(const Aws::String& value) { SetDocumentURI(value); return *this;} /** *

The URI of the original location of the document.

*/ inline RetrieveResultItem& WithDocumentURI(Aws::String&& value) { SetDocumentURI(std::move(value)); return *this;} /** *

The URI of the original location of the document.

*/ inline RetrieveResultItem& WithDocumentURI(const char* value) { SetDocumentURI(value); return *this;} /** *

An array of document fields/attributes assigned to a document in the search * results. For example, the document author (_author) or the source * URI (_source_uri) of the document.

*/ inline const Aws::Vector& GetDocumentAttributes() const{ return m_documentAttributes; } /** *

An array of document fields/attributes assigned to a document in the search * results. For example, the document author (_author) or the source * URI (_source_uri) of the document.

*/ inline bool DocumentAttributesHasBeenSet() const { return m_documentAttributesHasBeenSet; } /** *

An array of document fields/attributes assigned to a document in the search * results. For example, the document author (_author) or the source * URI (_source_uri) of the document.

*/ inline void SetDocumentAttributes(const Aws::Vector& value) { m_documentAttributesHasBeenSet = true; m_documentAttributes = value; } /** *

An array of document fields/attributes assigned to a document in the search * results. For example, the document author (_author) or the source * URI (_source_uri) of the document.

*/ inline void SetDocumentAttributes(Aws::Vector&& value) { m_documentAttributesHasBeenSet = true; m_documentAttributes = std::move(value); } /** *

An array of document fields/attributes assigned to a document in the search * results. For example, the document author (_author) or the source * URI (_source_uri) of the document.

*/ inline RetrieveResultItem& WithDocumentAttributes(const Aws::Vector& value) { SetDocumentAttributes(value); return *this;} /** *

An array of document fields/attributes assigned to a document in the search * results. For example, the document author (_author) or the source * URI (_source_uri) of the document.

*/ inline RetrieveResultItem& WithDocumentAttributes(Aws::Vector&& value) { SetDocumentAttributes(std::move(value)); return *this;} /** *

An array of document fields/attributes assigned to a document in the search * results. For example, the document author (_author) or the source * URI (_source_uri) of the document.

*/ inline RetrieveResultItem& AddDocumentAttributes(const DocumentAttribute& value) { m_documentAttributesHasBeenSet = true; m_documentAttributes.push_back(value); return *this; } /** *

An array of document fields/attributes assigned to a document in the search * results. For example, the document author (_author) or the source * URI (_source_uri) of the document.

*/ inline RetrieveResultItem& AddDocumentAttributes(DocumentAttribute&& value) { m_documentAttributesHasBeenSet = true; m_documentAttributes.push_back(std::move(value)); return *this; } private: Aws::String m_id; bool m_idHasBeenSet = false; Aws::String m_documentId; bool m_documentIdHasBeenSet = false; Aws::String m_documentTitle; bool m_documentTitleHasBeenSet = false; Aws::String m_content; bool m_contentHasBeenSet = false; Aws::String m_documentURI; bool m_documentURIHasBeenSet = false; Aws::Vector m_documentAttributes; bool m_documentAttributesHasBeenSet = false; }; } // namespace Model } // namespace kendra } // namespace Aws