1 /** 2 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 * SPDX-License-Identifier: Apache-2.0. 4 */ 5 6 #pragma once 7 #include <aws/comprehend/Comprehend_EXPORTS.h> 8 #include <aws/comprehend/model/SentimentType.h> 9 #include <aws/comprehend/model/SentimentScore.h> 10 #include <utility> 11 12 namespace Aws 13 { 14 template<typename RESULT_TYPE> 15 class AmazonWebServiceResult; 16 17 namespace Utils 18 { 19 namespace Json 20 { 21 class JsonValue; 22 } // namespace Json 23 } // namespace Utils 24 namespace Comprehend 25 { 26 namespace Model 27 { 28 class AWS_COMPREHEND_API DetectSentimentResult 29 { 30 public: 31 DetectSentimentResult(); 32 DetectSentimentResult(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result); 33 DetectSentimentResult& operator=(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result); 34 35 36 /** 37 * <p>The inferred sentiment that Amazon Comprehend has the highest level of 38 * confidence in.</p> 39 */ GetSentiment()40 inline const SentimentType& GetSentiment() const{ return m_sentiment; } 41 42 /** 43 * <p>The inferred sentiment that Amazon Comprehend has the highest level of 44 * confidence in.</p> 45 */ SetSentiment(const SentimentType & value)46 inline void SetSentiment(const SentimentType& value) { m_sentiment = value; } 47 48 /** 49 * <p>The inferred sentiment that Amazon Comprehend has the highest level of 50 * confidence in.</p> 51 */ SetSentiment(SentimentType && value)52 inline void SetSentiment(SentimentType&& value) { m_sentiment = std::move(value); } 53 54 /** 55 * <p>The inferred sentiment that Amazon Comprehend has the highest level of 56 * confidence in.</p> 57 */ WithSentiment(const SentimentType & value)58 inline DetectSentimentResult& WithSentiment(const SentimentType& value) { SetSentiment(value); return *this;} 59 60 /** 61 * <p>The inferred sentiment that Amazon Comprehend has the highest level of 62 * confidence in.</p> 63 */ WithSentiment(SentimentType && value)64 inline DetectSentimentResult& WithSentiment(SentimentType&& value) { SetSentiment(std::move(value)); return *this;} 65 66 67 /** 68 * <p>An object that lists the sentiments, and their corresponding confidence 69 * levels.</p> 70 */ GetSentimentScore()71 inline const SentimentScore& GetSentimentScore() const{ return m_sentimentScore; } 72 73 /** 74 * <p>An object that lists the sentiments, and their corresponding confidence 75 * levels.</p> 76 */ SetSentimentScore(const SentimentScore & value)77 inline void SetSentimentScore(const SentimentScore& value) { m_sentimentScore = value; } 78 79 /** 80 * <p>An object that lists the sentiments, and their corresponding confidence 81 * levels.</p> 82 */ SetSentimentScore(SentimentScore && value)83 inline void SetSentimentScore(SentimentScore&& value) { m_sentimentScore = std::move(value); } 84 85 /** 86 * <p>An object that lists the sentiments, and their corresponding confidence 87 * levels.</p> 88 */ WithSentimentScore(const SentimentScore & value)89 inline DetectSentimentResult& WithSentimentScore(const SentimentScore& value) { SetSentimentScore(value); return *this;} 90 91 /** 92 * <p>An object that lists the sentiments, and their corresponding confidence 93 * levels.</p> 94 */ WithSentimentScore(SentimentScore && value)95 inline DetectSentimentResult& WithSentimentScore(SentimentScore&& value) { SetSentimentScore(std::move(value)); return *this;} 96 97 private: 98 99 SentimentType m_sentiment; 100 101 SentimentScore m_sentimentScore; 102 }; 103 104 } // namespace Model 105 } // namespace Comprehend 106 } // namespace Aws 107