Class AnalyzeSentimentResult
- java.lang.Object
-
- com.azure.ai.textanalytics.models.TextAnalyticsResult
-
- com.azure.ai.textanalytics.models.AnalyzeSentimentResult
-
public final class AnalyzeSentimentResult extends TextAnalyticsResult
TheAnalyzeSentimentResult
model.
-
-
Constructor Summary
Constructors Constructor Description AnalyzeSentimentResult(String id, TextDocumentStatistics textDocumentStatistics, TextAnalyticsError error, DocumentSentiment documentSentiment)
Creates aAnalyzeSentimentResult
model that describes analyzed sentiment result.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DocumentSentiment
getDocumentSentiment()
Gets the document sentiment.-
Methods inherited from class com.azure.ai.textanalytics.models.TextAnalyticsResult
getError, getId, getStatistics, isError
-
-
-
-
Constructor Detail
-
AnalyzeSentimentResult
public AnalyzeSentimentResult(String id, TextDocumentStatistics textDocumentStatistics, TextAnalyticsError error, DocumentSentiment documentSentiment)
Creates aAnalyzeSentimentResult
model that describes analyzed sentiment result.- Parameters:
id
- Unique, non-empty document identifier.textDocumentStatistics
- The text document statistics.error
- The document error.documentSentiment
- The document sentiment.
-
-
Method Detail
-
getDocumentSentiment
public DocumentSentiment getDocumentSentiment()
Gets the document sentiment.- Returns:
- The document sentiment.
- Throws:
TextAnalyticsException
- if result hasisError
equals to true and when a non-error property was accessed.
-
-