Class SpeechTranslationService.SpeechTranslationServiceClient (2.0.0-beta01)

public class SpeechTranslationServiceClient : ClientBase<SpeechTranslationService.SpeechTranslationServiceClient>

Client for SpeechTranslationService

Inheritance

Object > ClientBase > ClientBase<SpeechTranslationService.SpeechTranslationServiceClient> > SpeechTranslationService.SpeechTranslationServiceClient

Namespace

Google.Cloud.MediaTranslation.V1Beta1

Assembly

Google.Cloud.MediaTranslation.V1Beta1.dll

Constructors

SpeechTranslationServiceClient()

protected SpeechTranslationServiceClient()

Protected parameterless constructor to allow creation of test doubles.

SpeechTranslationServiceClient(CallInvoker)

public SpeechTranslationServiceClient(CallInvoker callInvoker)

Creates a new client for SpeechTranslationService that uses a custom CallInvoker.

Parameter
NameDescription
callInvokerCallInvoker

The callInvoker to use to make remote calls.

SpeechTranslationServiceClient(ChannelBase)

public SpeechTranslationServiceClient(ChannelBase channel)

Creates a new client for SpeechTranslationService

Parameter
NameDescription
channelChannelBase

The channel to use to make remote calls.

SpeechTranslationServiceClient(ClientBase.ClientBaseConfiguration)

protected SpeechTranslationServiceClient(ClientBase.ClientBaseConfiguration configuration)

Protected constructor to allow creation of configured clients.

Parameter
NameDescription
configurationClientBase.ClientBaseConfiguration

The client configuration.

Methods

NewInstance(ClientBase.ClientBaseConfiguration)

protected override SpeechTranslationService.SpeechTranslationServiceClient NewInstance(ClientBase.ClientBaseConfiguration configuration)

Creates a new instance of client from given ClientBaseConfiguration.

Parameter
NameDescription
configurationClientBase.ClientBaseConfiguration
Returns
TypeDescription
SpeechTranslationService.SpeechTranslationServiceClient
Overrides
Grpc.Core.ClientBase<Google.Cloud.MediaTranslation.V1Beta1.SpeechTranslationService.SpeechTranslationServiceClient>.NewInstance(Grpc.Core.ClientBase.ClientBaseConfiguration)

StreamingTranslateSpeech(CallOptions)

public virtual AsyncDuplexStreamingCall<StreamingTranslateSpeechRequest, StreamingTranslateSpeechResponse> StreamingTranslateSpeech(CallOptions options)

Performs bidirectional streaming speech translation: receive results while sending audio. This method is only available via the gRPC API (not REST).

Parameter
NameDescription
optionsCallOptions

The options for the call.

Returns
TypeDescription
AsyncDuplexStreamingCall<StreamingTranslateSpeechRequest, StreamingTranslateSpeechResponse>

The call object.

StreamingTranslateSpeech(Metadata, Nullable<DateTime>, CancellationToken)

public virtual AsyncDuplexStreamingCall<StreamingTranslateSpeechRequest, StreamingTranslateSpeechResponse> StreamingTranslateSpeech(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))

Performs bidirectional streaming speech translation: receive results while sending audio. This method is only available via the gRPC API (not REST).

Parameters
NameDescription
headersMetadata

The initial metadata to send with the call. This parameter is optional.

deadlineNullable<DateTime>

An optional deadline for the call. The call will be cancelled if deadline is hit.

cancellationTokenCancellationToken

An optional token for canceling the call.

Returns
TypeDescription
AsyncDuplexStreamingCall<StreamingTranslateSpeechRequest, StreamingTranslateSpeechResponse>

The call object.