Retail v2 API - Class CompletionService.CompletionServiceClient (2.7.0)

public class CompletionService.CompletionServiceClient : ClientBase<CompletionService.CompletionServiceClient>

Reference documentation and code samples for the Retail v2 API class CompletionService.CompletionServiceClient.

Client for CompletionService

Inheritance

object > ClientBase > ClientBaseCompletionServiceCompletionServiceClient > CompletionService.CompletionServiceClient

Namespace

Google.Cloud.Retail.V2

Assembly

Google.Cloud.Retail.V2.dll

Constructors

CompletionServiceClient()

protected CompletionServiceClient()

Protected parameterless constructor to allow creation of test doubles.

CompletionServiceClient(CallInvoker)

public CompletionServiceClient(CallInvoker callInvoker)

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

Parameter
NameDescription
callInvokerCallInvoker

The callInvoker to use to make remote calls.

CompletionServiceClient(ChannelBase)

public CompletionServiceClient(ChannelBase channel)

Creates a new client for CompletionService

Parameter
NameDescription
channelChannelBase

The channel to use to make remote calls.

CompletionServiceClient(ClientBaseConfiguration)

protected CompletionServiceClient(ClientBase.ClientBaseConfiguration configuration)

Protected constructor to allow creation of configured clients.

Parameter
NameDescription
configurationClientBaseClientBaseConfiguration

The client configuration.

Methods

CompleteQuery(CompleteQueryRequest, CallOptions)

public virtual CompleteQueryResponse CompleteQuery(CompleteQueryRequest request, CallOptions options)

Completes the specified prefix with keyword suggestions.

This feature is only available for users who have Retail Search enabled. Enable Retail Search on Cloud Console before using this feature.

Parameters
NameDescription
requestCompleteQueryRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
CompleteQueryResponse

The response received from the server.

CompleteQuery(CompleteQueryRequest, Metadata, DateTime?, CancellationToken)

public virtual CompleteQueryResponse CompleteQuery(CompleteQueryRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Completes the specified prefix with keyword suggestions.

This feature is only available for users who have Retail Search enabled. Enable Retail Search on Cloud Console before using this feature.

Parameters
NameDescription
requestCompleteQueryRequest

The request to send to the server.

headersMetadata

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

deadlineDateTime

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
CompleteQueryResponse

The response received from the server.

CompleteQueryAsync(CompleteQueryRequest, CallOptions)

public virtual AsyncUnaryCall<CompleteQueryResponse> CompleteQueryAsync(CompleteQueryRequest request, CallOptions options)

Completes the specified prefix with keyword suggestions.

This feature is only available for users who have Retail Search enabled. Enable Retail Search on Cloud Console before using this feature.

Parameters
NameDescription
requestCompleteQueryRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
AsyncUnaryCallCompleteQueryResponse

The call object.

CompleteQueryAsync(CompleteQueryRequest, Metadata, DateTime?, CancellationToken)

public virtual AsyncUnaryCall<CompleteQueryResponse> CompleteQueryAsync(CompleteQueryRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Completes the specified prefix with keyword suggestions.

This feature is only available for users who have Retail Search enabled. Enable Retail Search on Cloud Console before using this feature.

Parameters
NameDescription
requestCompleteQueryRequest

The request to send to the server.

headersMetadata

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

deadlineDateTime

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
AsyncUnaryCallCompleteQueryResponse

The call object.

CreateLocationsClient()

public virtual Locations.LocationsClient CreateLocationsClient()

Creates a new instance of Locations.LocationsClient using the same call invoker as this client.

Returns
TypeDescription
LocationsLocationsClient

A new Locations.LocationsClient for the same target as this client.

CreateOperationsClient()

public virtual Operations.OperationsClient CreateOperationsClient()

Creates a new instance of Operations.OperationsClient using the same call invoker as this client.

Returns
TypeDescription
OperationsOperationsClient

A new Operations client for the same target as this client.

ImportCompletionData(ImportCompletionDataRequest, CallOptions)

public virtual Operation ImportCompletionData(ImportCompletionDataRequest request, CallOptions options)

Bulk import of processed completion dataset.

Request processing is asynchronous. Partial updating is not supported.

The operation is successfully finished only after the imported suggestions are indexed successfully and ready for serving. The process takes hours.

This feature is only available for users who have Retail Search enabled. Enable Retail Search on Cloud Console before using this feature.

Parameters
NameDescription
requestImportCompletionDataRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
Operation

The response received from the server.

ImportCompletionData(ImportCompletionDataRequest, Metadata, DateTime?, CancellationToken)

public virtual Operation ImportCompletionData(ImportCompletionDataRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Bulk import of processed completion dataset.

Request processing is asynchronous. Partial updating is not supported.

The operation is successfully finished only after the imported suggestions are indexed successfully and ready for serving. The process takes hours.

This feature is only available for users who have Retail Search enabled. Enable Retail Search on Cloud Console before using this feature.

Parameters
NameDescription
requestImportCompletionDataRequest

The request to send to the server.

headersMetadata

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

deadlineDateTime

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
Operation

The response received from the server.

ImportCompletionDataAsync(ImportCompletionDataRequest, CallOptions)

public virtual AsyncUnaryCall<Operation> ImportCompletionDataAsync(ImportCompletionDataRequest request, CallOptions options)

Bulk import of processed completion dataset.

Request processing is asynchronous. Partial updating is not supported.

The operation is successfully finished only after the imported suggestions are indexed successfully and ready for serving. The process takes hours.

This feature is only available for users who have Retail Search enabled. Enable Retail Search on Cloud Console before using this feature.

Parameters
NameDescription
requestImportCompletionDataRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
AsyncUnaryCallOperation

The call object.

ImportCompletionDataAsync(ImportCompletionDataRequest, Metadata, DateTime?, CancellationToken)

public virtual AsyncUnaryCall<Operation> ImportCompletionDataAsync(ImportCompletionDataRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Bulk import of processed completion dataset.

Request processing is asynchronous. Partial updating is not supported.

The operation is successfully finished only after the imported suggestions are indexed successfully and ready for serving. The process takes hours.

This feature is only available for users who have Retail Search enabled. Enable Retail Search on Cloud Console before using this feature.

Parameters
NameDescription
requestImportCompletionDataRequest

The request to send to the server.

headersMetadata

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

deadlineDateTime

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
AsyncUnaryCallOperation

The call object.

NewInstance(ClientBaseConfiguration)

protected override CompletionService.CompletionServiceClient NewInstance(ClientBase.ClientBaseConfiguration configuration)

Creates a new instance of client from given ClientBaseConfiguration.

Parameter
NameDescription
configurationClientBaseClientBaseConfiguration
Returns
TypeDescription
CompletionServiceCompletionServiceClient
Overrides