Class LanguageServiceGrpc.LanguageServiceImplBase (2.8.0)

publicabstractstaticclass LanguageServiceGrpc.LanguageServiceImplBaseimplementsBindableService

Provides text analysis operations such as sentiment analysis and entity recognition.

Inheritance

java.lang.Object > LanguageServiceGrpc.LanguageServiceImplBase

Implements

io.grpc.BindableService

Constructors

LanguageServiceImplBase()

publicLanguageServiceImplBase()

Methods

analyzeEntities(AnalyzeEntitiesRequest request, StreamObserver<AnalyzeEntitiesResponse> responseObserver)

publicvoidanalyzeEntities(AnalyzeEntitiesRequestrequest,StreamObserver<AnalyzeEntitiesResponse>responseObserver)

Finds named entities (currently proper names and common nouns) in the text along with entity types, salience, mentions for each entity, and other properties.

Parameters
Name Description
responseObserver io.grpc.stub.StreamObserver<AnalyzeEntitiesResponse>

analyzeEntitySentiment(AnalyzeEntitySentimentRequest request, StreamObserver<AnalyzeEntitySentimentResponse> responseObserver)

publicvoidanalyzeEntitySentiment(AnalyzeEntitySentimentRequestrequest,StreamObserver<AnalyzeEntitySentimentResponse>responseObserver)

Finds entities, similar to AnalyzeEntities in the text and analyzes sentiment associated with each entity and its mentions.

Parameters
Name Description
responseObserver io.grpc.stub.StreamObserver<AnalyzeEntitySentimentResponse>

analyzeSentiment(AnalyzeSentimentRequest request, StreamObserver<AnalyzeSentimentResponse> responseObserver)

publicvoidanalyzeSentiment(AnalyzeSentimentRequestrequest,StreamObserver<AnalyzeSentimentResponse>responseObserver)

Analyzes the sentiment of the provided text.

Parameters
Name Description
responseObserver io.grpc.stub.StreamObserver<AnalyzeSentimentResponse>

analyzeSyntax(AnalyzeSyntaxRequest request, StreamObserver<AnalyzeSyntaxResponse> responseObserver)

publicvoidanalyzeSyntax(AnalyzeSyntaxRequestrequest,StreamObserver<AnalyzeSyntaxResponse>responseObserver)

Analyzes the syntax of the text and provides sentence boundaries and tokenization along with part of speech tags, dependency trees, and other properties.

Parameters
Name Description
responseObserver io.grpc.stub.StreamObserver<AnalyzeSyntaxResponse>

annotateText(AnnotateTextRequest request, StreamObserver<AnnotateTextResponse> responseObserver)

publicvoidannotateText(AnnotateTextRequestrequest,StreamObserver<AnnotateTextResponse>responseObserver)

A convenience method that provides all syntax, sentiment, entity, and classification features in one call.

Parameters
Name Description
responseObserver io.grpc.stub.StreamObserver<AnnotateTextResponse>

bindService()

publicfinalServerServiceDefinitionbindService()
Returns
Type Description
io.grpc.ServerServiceDefinition

classifyText(ClassifyTextRequest request, StreamObserver<ClassifyTextResponse> responseObserver)

publicvoidclassifyText(ClassifyTextRequestrequest,StreamObserver<ClassifyTextResponse>responseObserver)

Classifies a document into categories.

Parameters
Name Description
responseObserver io.grpc.stub.StreamObserver<ClassifyTextResponse>

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025年10月30日 UTC.