AWS SDK for C++

AWS SDK for C++ Version 1.11.608

Loading...
Searching...
No Matches
SearchResult.h
1
6#pragma once
7#include <aws/cloudsearchdomain/CloudSearchDomain_EXPORTS.h>
8#include <aws/cloudsearchdomain/model/SearchStatus.h>
9#include <aws/cloudsearchdomain/model/Hits.h>
10#include <aws/core/utils/memory/stl/AWSMap.h>
11#include <aws/core/utils/memory/stl/AWSString.h>
12#include <aws/cloudsearchdomain/model/BucketInfo.h>
13#include <aws/cloudsearchdomain/model/FieldStats.h>
14#include <utility>
15
16namespace Aws
17{
18template<typename RESULT_TYPE>
19class AmazonWebServiceResult;
20
21namespace Utils
22{
23namespace Json
24{
25 class JsonValue;
26} // namespace Json
27} // namespace Utils
28namespace CloudSearchDomain
29{
30namespace Model
31{
40 {
41 public:
42 AWS_CLOUDSEARCHDOMAIN_API SearchResult() = default;
45
46
48
51 inline const SearchStatus& GetStatus() const { return m_status; }
52 template<typename StatusT = SearchStatus>
53 void SetStatus(StatusT&& value) { m_statusHasBeenSet = true; m_status = std::forward<StatusT>(value); }
54 template<typename StatusT = SearchStatus>
55 SearchResult& WithStatus(StatusT&& value) { SetStatus(std::forward<StatusT>(value)); return *this;}
57
59
62 inline const Hits& GetHits() const { return m_hits; }
63 template<typename HitsT = Hits>
64 void SetHits(HitsT&& value) { m_hitsHasBeenSet = true; m_hits = std::forward<HitsT>(value); }
65 template<typename HitsT = Hits>
66 SearchResult& WithHits(HitsT&& value) { SetHits(std::forward<HitsT>(value)); return *this;}
68
70
73 inline const Aws::Map<Aws::String, BucketInfo>& GetFacets() const { return m_facets; }
74 template<typename FacetsT = Aws::Map<Aws::String, BucketInfo>>
75 void SetFacets(FacetsT&& value) { m_facetsHasBeenSet = true; m_facets = std::forward<FacetsT>(value); }
76 template<typename FacetsT = Aws::Map<Aws::String, BucketInfo>>
77 SearchResult& WithFacets(FacetsT&& value) { SetFacets(std::forward<FacetsT>(value)); return *this;}
78 template<typename FacetsKeyT = Aws::String, typename FacetsValueT = BucketInfo>
79 SearchResult& AddFacets(FacetsKeyT&& key, FacetsValueT&& value) {
80 m_facetsHasBeenSet = true; m_facets.emplace(std::forward<FacetsKeyT>(key), std::forward<FacetsValueT>(value)); return *this;
81 }
83
85
88 inline const Aws::Map<Aws::String, FieldStats>& GetStats() const { return m_stats; }
89 template<typename StatsT = Aws::Map<Aws::String, FieldStats>>
90 void SetStats(StatsT&& value) { m_statsHasBeenSet = true; m_stats = std::forward<StatsT>(value); }
91 template<typename StatsT = Aws::Map<Aws::String, FieldStats>>
92 SearchResult& WithStats(StatsT&& value) { SetStats(std::forward<StatsT>(value)); return *this;}
93 template<typename StatsKeyT = Aws::String, typename StatsValueT = FieldStats>
94 SearchResult& AddStats(StatsKeyT&& key, StatsValueT&& value) {
95 m_statsHasBeenSet = true; m_stats.emplace(std::forward<StatsKeyT>(key), std::forward<StatsValueT>(value)); return *this;
96 }
98
100
101 inline const Aws::String& GetRequestId() const { return m_requestId; }
102 template<typename RequestIdT = Aws::String>
103 void SetRequestId(RequestIdT&& value) { m_requestIdHasBeenSet = true; m_requestId = std::forward<RequestIdT>(value); }
104 template<typename RequestIdT = Aws::String>
105 SearchResult& WithRequestId(RequestIdT&& value) { SetRequestId(std::forward<RequestIdT>(value)); return *this;}
107 private:
108
109 SearchStatus m_status;
110 bool m_statusHasBeenSet = false;
111
112 Hits m_hits;
113 bool m_hitsHasBeenSet = false;
114
116 bool m_facetsHasBeenSet = false;
117
119 bool m_statsHasBeenSet = false;
120
121 Aws::String m_requestId;
122 bool m_requestIdHasBeenSet = false;
123 };
124
125} // namespace Model
126} // namespace CloudSearchDomain
127} // namespace Aws
AWS_CLOUDSEARCHDOMAIN_API SearchResult & operator=(const Aws::AmazonWebServiceResult< Aws::Utils::Json::JsonValue > &result)
SearchResult & WithStatus(StatusT &&value)
AWS_CLOUDSEARCHDOMAIN_API SearchResult()=default
AWS_CLOUDSEARCHDOMAIN_API SearchResult(const Aws::AmazonWebServiceResult< Aws::Utils::Json::JsonValue > &result)
const SearchStatus & GetStatus() const
SearchResult & WithFacets(FacetsT &&value)
SearchResult & AddFacets(FacetsKeyT &&key, FacetsValueT &&value)
SearchResult & WithRequestId(RequestIdT &&value)
const Aws::Map< Aws::String, FieldStats > & GetStats() const
SearchResult & AddStats(StatsKeyT &&key, StatsValueT &&value)
SearchResult & WithHits(HitsT &&value)
const Aws::Map< Aws::String, BucketInfo > & GetFacets() const
SearchResult & WithStats(StatsT &&value)
const Aws::String & GetRequestId() const
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue