Class: Google::Apis::LanguageV1::AnalyzeEntitySentimentResponse
- Inherits:
-
Object
- Object
- Google::Apis::LanguageV1::AnalyzeEntitySentimentResponse
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/language_v1/classes.rb,
lib/google/apis/language_v1/representations.rb,
lib/google/apis/language_v1/representations.rb
Overview
The entity-level sentiment analysis response message.
Instance Attribute Summary collapse
-
#entities ⇒ Array<Google::Apis::LanguageV1::Entity>
The recognized entities in the input document with associated sentiments.
-
#language ⇒ String
The language of the text, which will be the same as the language specified in the request or, if not specified, the automatically-detected language.
Instance Method Summary collapse
-
#initialize(**args) ⇒ AnalyzeEntitySentimentResponse
constructor
A new instance of AnalyzeEntitySentimentResponse.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ AnalyzeEntitySentimentResponse
Returns a new instance of AnalyzeEntitySentimentResponse.
118 119 120 |
# File 'lib/google/apis/language_v1/classes.rb', line 118 def initialize(**args) update!(**args) end |
Instance Attribute Details
#entities ⇒ Array<Google::Apis::LanguageV1::Entity>
The recognized entities in the input document with associated sentiments.
Corresponds to the JSON property entities
109 110 111 |
# File 'lib/google/apis/language_v1/classes.rb', line 109 def entities @entities end |
#language ⇒ String
The language of the text, which will be the same as the language specified in
the request or, if not specified, the automatically-detected language. See
Document.language field for more details.
Corresponds to the JSON property language
116 117 118 |
# File 'lib/google/apis/language_v1/classes.rb', line 116 def language @language end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
123 124 125 126 |
# File 'lib/google/apis/language_v1/classes.rb', line 123 def update!(**args) @entities = args[:entities] if args.key?(:entities) @language = args[:language] if args.key?(:language) end |