AWS SDK for C++

AWS SDK for C++ Version 1.11.750

Loading...
Searching...
No Matches
SearchResultBlock.h
1
6#pragma once
7#include <aws/bedrock-runtime/BedrockRuntime_EXPORTS.h>
8#include <aws/bedrock-runtime/model/CitationsConfig.h>
9#include <aws/bedrock-runtime/model/SearchResultContentBlock.h>
10#include <aws/core/utils/memory/stl/AWSString.h>
11#include <aws/core/utils/memory/stl/AWSVector.h>
12
13#include <utility>
14
15namespace Aws {
16namespace Utils {
17namespace Json {
18class JsonValue;
19class JsonView;
20} // namespace Json
21} // namespace Utils
22namespace BedrockRuntime {
23namespace Model {
24
34 public:
35 AWS_BEDROCKRUNTIME_API SearchResultBlock() = default;
38 AWS_BEDROCKRUNTIME_API Aws::Utils::Json::JsonValue Jsonize() const;
39
41
44 inline const Aws::String& GetSource() const { return m_source; }
45 inline bool SourceHasBeenSet() const { return m_sourceHasBeenSet; }
46 template <typename SourceT = Aws::String>
47 void SetSource(SourceT&& value) {
48 m_sourceHasBeenSet = true;
49 m_source = std::forward<SourceT>(value);
50 }
51 template <typename SourceT = Aws::String>
53 SetSource(std::forward<SourceT>(value));
54 return *this;
55 }
57
59
62 inline const Aws::String& GetTitle() const { return m_title; }
63 inline bool TitleHasBeenSet() const { return m_titleHasBeenSet; }
64 template <typename TitleT = Aws::String>
65 void SetTitle(TitleT&& value) {
66 m_titleHasBeenSet = true;
67 m_title = std::forward<TitleT>(value);
68 }
69 template <typename TitleT = Aws::String>
71 SetTitle(std::forward<TitleT>(value));
72 return *this;
73 }
75
77
80 inline const Aws::Vector<SearchResultContentBlock>& GetContent() const { return m_content; }
81 inline bool ContentHasBeenSet() const { return m_contentHasBeenSet; }
82 template <typename ContentT = Aws::Vector<SearchResultContentBlock>>
83 void SetContent(ContentT&& value) {
84 m_contentHasBeenSet = true;
85 m_content = std::forward<ContentT>(value);
86 }
87 template <typename ContentT = Aws::Vector<SearchResultContentBlock>>
89 SetContent(std::forward<ContentT>(value));
90 return *this;
91 }
92 template <typename ContentT = SearchResultContentBlock>
94 m_contentHasBeenSet = true;
95 m_content.emplace_back(std::forward<ContentT>(value));
96 return *this;
97 }
99
101
104 inline const CitationsConfig& GetCitations() const { return m_citations; }
105 inline bool CitationsHasBeenSet() const { return m_citationsHasBeenSet; }
106 template <typename CitationsT = CitationsConfig>
107 void SetCitations(CitationsT&& value) {
108 m_citationsHasBeenSet = true;
109 m_citations = std::forward<CitationsT>(value);
110 }
111 template <typename CitationsT = CitationsConfig>
113 SetCitations(std::forward<CitationsT>(value));
114 return *this;
115 }
117 private:
118 Aws::String m_source;
119
120 Aws::String m_title;
121
123
124 CitationsConfig m_citations;
125 bool m_sourceHasBeenSet = false;
126 bool m_titleHasBeenSet = false;
127 bool m_contentHasBeenSet = false;
128 bool m_citationsHasBeenSet = false;
129};
130
131} // namespace Model
132} // namespace BedrockRuntime
133} // namespace Aws
SearchResultBlock & WithCitations(CitationsT &&value)
AWS_BEDROCKRUNTIME_API SearchResultBlock()=default
SearchResultBlock & AddContent(ContentT &&value)
SearchResultBlock & WithSource(SourceT &&value)
const CitationsConfig & GetCitations() const
AWS_BEDROCKRUNTIME_API Aws::Utils::Json::JsonValue Jsonize() const
SearchResultBlock & WithTitle(TitleT &&value)
const Aws::Vector< SearchResultContentBlock > & GetContent() const
SearchResultBlock & WithContent(ContentT &&value)
AWS_BEDROCKRUNTIME_API SearchResultBlock(Aws::Utils::Json::JsonView jsonValue)
AWS_BEDROCKRUNTIME_API SearchResultBlock & operator=(Aws::Utils::Json::JsonView jsonValue)
std::shared_ptr< T > MakeShared(const char *allocationTag, ArgTypes &&... args)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue