AWS SDK for C++

AWS SDK for C++ Version 1.11.788

Loading...
Searching...
No Matches
DetectSentimentResult.h
1
6#pragma once
7#include <aws/comprehend/Comprehend_EXPORTS.h>
8#include <aws/comprehend/model/SentimentScore.h>
9#include <aws/comprehend/model/SentimentType.h>
10#include <aws/core/http/HttpResponse.h>
11#include <aws/core/utils/memory/stl/AWSString.h>
12
13#include <utility>
14
15namespace Aws {
16template <typename RESULT_TYPE>
17class AmazonWebServiceResult;
18
19namespace Utils {
20namespace Json {
21class JsonValue;
22} // namespace Json
23} // namespace Utils
24namespace Comprehend {
25namespace Model {
27 public:
28 AWS_COMPREHEND_API DetectSentimentResult() = default;
31
33
37 inline SentimentType GetSentiment() const { return m_sentiment; }
38 inline void SetSentiment(SentimentType value) {
39 m_sentimentHasBeenSet = true;
40 m_sentiment = value;
41 }
43 SetSentiment(value);
44 return *this;
45 }
47
49
53 inline const SentimentScore& GetSentimentScore() const { return m_sentimentScore; }
54 template <typename SentimentScoreT = SentimentScore>
55 void SetSentimentScore(SentimentScoreT&& value) {
56 m_sentimentScoreHasBeenSet = true;
57 m_sentimentScore = std::forward<SentimentScoreT>(value);
58 }
59 template <typename SentimentScoreT = SentimentScore>
60 DetectSentimentResult& WithSentimentScore(SentimentScoreT&& value) {
61 SetSentimentScore(std::forward<SentimentScoreT>(value));
62 return *this;
63 }
65
67
68 inline const Aws::String& GetRequestId() const { return m_requestId; }
69 template <typename RequestIdT = Aws::String>
70 void SetRequestId(RequestIdT&& value) {
71 m_requestIdHasBeenSet = true;
72 m_requestId = std::forward<RequestIdT>(value);
73 }
74 template <typename RequestIdT = Aws::String>
75 DetectSentimentResult& WithRequestId(RequestIdT&& value) {
76 SetRequestId(std::forward<RequestIdT>(value));
77 return *this;
78 }
80 inline Aws::Http::HttpResponseCode GetHttpResponseCode() const { return m_HttpResponseCode; }
81
82 private:
84
85 SentimentScore m_sentimentScore;
86
87 Aws::String m_requestId;
88 Aws::Http::HttpResponseCode m_HttpResponseCode;
89 bool m_sentimentHasBeenSet = false;
90 bool m_sentimentScoreHasBeenSet = false;
91 bool m_requestIdHasBeenSet = false;
92};
93
94} // namespace Model
95} // namespace Comprehend
96} // namespace Aws
AWS_COMPREHEND_API DetectSentimentResult(const Aws::AmazonWebServiceResult< Aws::Utils::Json::JsonValue > &result)
AWS_COMPREHEND_API DetectSentimentResult & operator=(const Aws::AmazonWebServiceResult< Aws::Utils::Json::JsonValue > &result)
DetectSentimentResult & WithRequestId(RequestIdT &&value)
DetectSentimentResult & WithSentimentScore(SentimentScoreT &&value)
Aws::Http::HttpResponseCode GetHttpResponseCode() const
AWS_COMPREHEND_API DetectSentimentResult()=default
DetectSentimentResult & WithSentiment(SentimentType value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue