Cloud Natural Language v2 API - Class LanguageService.LanguageServiceBase (1.0.0-beta02)

[BindServiceMethod(typeof(LanguageService), "BindService")]
public abstract class LanguageService.LanguageServiceBase

Reference documentation and code samples for the Cloud Natural Language v2 API class LanguageService.LanguageServiceBase.

Base class for server-side implementations of LanguageService

Inheritance

object > LanguageService.LanguageServiceBase

Namespace

Google.Cloud.Language.V2

Assembly

Google.Cloud.Language.V2.dll

Methods

AnalyzeEntities(AnalyzeEntitiesRequest, ServerCallContext)

public virtual Task<AnalyzeEntitiesResponse> AnalyzeEntities(AnalyzeEntitiesRequest request, ServerCallContext context)

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

Parameters
NameDescription
requestAnalyzeEntitiesRequest

The request received from the client.

contextServerCallContext

The context of the server-side call handler being invoked.

Returns
TypeDescription
TaskAnalyzeEntitiesResponse

The response to send back to the client (wrapped by a task).

AnalyzeSentiment(AnalyzeSentimentRequest, ServerCallContext)

public virtual Task<AnalyzeSentimentResponse> AnalyzeSentiment(AnalyzeSentimentRequest request, ServerCallContext context)

Analyzes the sentiment of the provided text.

Parameters
NameDescription
requestAnalyzeSentimentRequest

The request received from the client.

contextServerCallContext

The context of the server-side call handler being invoked.

Returns
TypeDescription
TaskAnalyzeSentimentResponse

The response to send back to the client (wrapped by a task).

AnnotateText(AnnotateTextRequest, ServerCallContext)

public virtual Task<AnnotateTextResponse> AnnotateText(AnnotateTextRequest request, ServerCallContext context)

A convenience method that provides all features in one call.

Parameters
NameDescription
requestAnnotateTextRequest

The request received from the client.

contextServerCallContext

The context of the server-side call handler being invoked.

Returns
TypeDescription
TaskAnnotateTextResponse

The response to send back to the client (wrapped by a task).

ClassifyText(ClassifyTextRequest, ServerCallContext)

public virtual Task<ClassifyTextResponse> ClassifyText(ClassifyTextRequest request, ServerCallContext context)

Classifies a document into categories.

Parameters
NameDescription
requestClassifyTextRequest

The request received from the client.

contextServerCallContext

The context of the server-side call handler being invoked.

Returns
TypeDescription
TaskClassifyTextResponse

The response to send back to the client (wrapped by a task).

ModerateText(ModerateTextRequest, ServerCallContext)

public virtual Task<ModerateTextResponse> ModerateText(ModerateTextRequest request, ServerCallContext context)

Moderates a document for harmful and sensitive categories.

Parameters
NameDescription
requestModerateTextRequest

The request received from the client.

contextServerCallContext

The context of the server-side call handler being invoked.

Returns
TypeDescription
TaskModerateTextResponse

The response to send back to the client (wrapped by a task).