Reference documentation and code samples for the Natural Language V1 API class Google::Cloud::Language::V1::EntityMention.
Represents a mention for an entity in the text. Currently, proper noun mentions are supported.
Inherits
- Object
 
Extended By
- Google::Protobuf::MessageExts::ClassMethods
 
Includes
- Google::Protobuf::MessageExts
 
Methods
#sentiment
def sentiment() -> ::Google::Cloud::Language::V1::Sentiment Returns 
 - (::Google::Cloud::Language::V1::Sentiment) — For calls to [AnalyzeEntitySentiment][] or if AnnotateTextRequest.Features.extract_entity_sentiment is set to true, this field will contain the sentiment expressed for this mention of the entity in the provided document.
 
#sentiment=
def sentiment=(value) -> ::Google::Cloud::Language::V1::Sentiment Parameter 
 - value (::Google::Cloud::Language::V1::Sentiment) — For calls to [AnalyzeEntitySentiment][] or if AnnotateTextRequest.Features.extract_entity_sentiment is set to true, this field will contain the sentiment expressed for this mention of the entity in the provided document.
 
 Returns 
 - (::Google::Cloud::Language::V1::Sentiment) — For calls to [AnalyzeEntitySentiment][] or if AnnotateTextRequest.Features.extract_entity_sentiment is set to true, this field will contain the sentiment expressed for this mention of the entity in the provided document.
 
#text
def text() -> ::Google::Cloud::Language::V1::TextSpan Returns 
 - (::Google::Cloud::Language::V1::TextSpan) — The mention text.
 
#text=
def text=(value) -> ::Google::Cloud::Language::V1::TextSpan Parameter 
 - value (::Google::Cloud::Language::V1::TextSpan) — The mention text.
 
 Returns 
 - (::Google::Cloud::Language::V1::TextSpan) — The mention text.
 
#type
def type() -> ::Google::Cloud::Language::V1::EntityMention::Type Returns 
 - (::Google::Cloud::Language::V1::EntityMention::Type) — The type of the entity mention.
 
#type=
def type=(value) -> ::Google::Cloud::Language::V1::EntityMention::Type Parameter 
 - value (::Google::Cloud::Language::V1::EntityMention::Type) — The type of the entity mention.
 
 Returns 
 - (::Google::Cloud::Language::V1::EntityMention::Type) — The type of the entity mention.