Class ProductService.ProductServiceClient
Client for ProductService
Inheritance
Inherited Members
Namespace: Google.Cloud.Retail.V2
Assembly: Google.Cloud.Retail.V2.dll
Syntax
public class ProductServiceClient : ClientBase<ProductService.ProductServiceClient>
Constructors
ProductServiceClient()
Protected parameterless constructor to allow creation of test doubles.
Declaration
protected ProductServiceClient()
ProductServiceClient(CallInvoker)
Creates a new client for ProductService that uses a custom CallInvoker
.
Declaration
public ProductServiceClient(CallInvoker callInvoker)
Parameters
Type | Name | Description |
---|---|---|
CallInvoker | callInvoker | The callInvoker to use to make remote calls. |
ProductServiceClient(ChannelBase)
Creates a new client for ProductService
Declaration
public ProductServiceClient(ChannelBase channel)
Parameters
Type | Name | Description |
---|---|---|
ChannelBase | channel | The channel to use to make remote calls. |
ProductServiceClient(ClientBase.ClientBaseConfiguration)
Protected constructor to allow creation of configured clients.
Declaration
protected ProductServiceClient(ClientBase.ClientBaseConfiguration configuration)
Parameters
Type | Name | Description |
---|---|---|
ClientBase.ClientBaseConfiguration | configuration | The client configuration. |
Methods
CreateOperationsClient()
Creates a new instance of Operations.OperationsClient using the same call invoker as this client.
Declaration
public virtual Operations.OperationsClient CreateOperationsClient()
Returns
Type | Description |
---|---|
Operations.OperationsClient | A new Operations client for the same target as this client. |
CreateProduct(CreateProductRequest, CallOptions)
Creates a [Product][google.cloud.retail.v2.Product].
Declaration
public virtual Product CreateProduct(CreateProductRequest request, CallOptions options)
Parameters
Type | Name | Description |
---|---|---|
CreateProductRequest | request | The request to send to the server. |
CallOptions | options | The options for the call. |
Returns
Type | Description |
---|---|
Product | The response received from the server. |
CreateProduct(CreateProductRequest, Metadata, Nullable<DateTime>, CancellationToken)
Creates a [Product][google.cloud.retail.v2.Product].
Declaration
public virtual Product CreateProduct(CreateProductRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type | Name | Description |
---|---|---|
CreateProductRequest | request | The request to send to the server. |
Metadata | headers | The initial metadata to send with the call. This parameter is optional. |
System.Nullable<System.DateTime> | deadline | An optional deadline for the call. The call will be cancelled if deadline is hit. |
System.Threading.CancellationToken | cancellationToken | An optional token for canceling the call. |
Returns
Type | Description |
---|---|
Product | The response received from the server. |
CreateProductAsync(CreateProductRequest, CallOptions)
Creates a [Product][google.cloud.retail.v2.Product].
Declaration
public virtual AsyncUnaryCall<Product> CreateProductAsync(CreateProductRequest request, CallOptions options)
Parameters
Type | Name | Description |
---|---|---|
CreateProductRequest | request | The request to send to the server. |
CallOptions | options | The options for the call. |
Returns
Type | Description |
---|---|
AsyncUnaryCall<Product> | The call object. |
CreateProductAsync(CreateProductRequest, Metadata, Nullable<DateTime>, CancellationToken)
Creates a [Product][google.cloud.retail.v2.Product].
Declaration
public virtual AsyncUnaryCall<Product> CreateProductAsync(CreateProductRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type | Name | Description |
---|---|---|
CreateProductRequest | request | The request to send to the server. |
Metadata | headers | The initial metadata to send with the call. This parameter is optional. |
System.Nullable<System.DateTime> | deadline | An optional deadline for the call. The call will be cancelled if deadline is hit. |
System.Threading.CancellationToken | cancellationToken | An optional token for canceling the call. |
Returns
Type | Description |
---|---|
AsyncUnaryCall<Product> | The call object. |
DeleteProduct(DeleteProductRequest, CallOptions)
Deletes a [Product][google.cloud.retail.v2.Product].
Declaration
public virtual Empty DeleteProduct(DeleteProductRequest request, CallOptions options)
Parameters
Type | Name | Description |
---|---|---|
DeleteProductRequest | request | The request to send to the server. |
CallOptions | options | The options for the call. |
Returns
Type | Description |
---|---|
Empty | The response received from the server. |
DeleteProduct(DeleteProductRequest, Metadata, Nullable<DateTime>, CancellationToken)
Deletes a [Product][google.cloud.retail.v2.Product].
Declaration
public virtual Empty DeleteProduct(DeleteProductRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type | Name | Description |
---|---|---|
DeleteProductRequest | request | The request to send to the server. |
Metadata | headers | The initial metadata to send with the call. This parameter is optional. |
System.Nullable<System.DateTime> | deadline | An optional deadline for the call. The call will be cancelled if deadline is hit. |
System.Threading.CancellationToken | cancellationToken | An optional token for canceling the call. |
Returns
Type | Description |
---|---|
Empty | The response received from the server. |
DeleteProductAsync(DeleteProductRequest, CallOptions)
Deletes a [Product][google.cloud.retail.v2.Product].
Declaration
public virtual AsyncUnaryCall<Empty> DeleteProductAsync(DeleteProductRequest request, CallOptions options)
Parameters
Type | Name | Description |
---|---|---|
DeleteProductRequest | request | The request to send to the server. |
CallOptions | options | The options for the call. |
Returns
Type | Description |
---|---|
AsyncUnaryCall<Empty> | The call object. |
DeleteProductAsync(DeleteProductRequest, Metadata, Nullable<DateTime>, CancellationToken)
Deletes a [Product][google.cloud.retail.v2.Product].
Declaration
public virtual AsyncUnaryCall<Empty> DeleteProductAsync(DeleteProductRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type | Name | Description |
---|---|---|
DeleteProductRequest | request | The request to send to the server. |
Metadata | headers | The initial metadata to send with the call. This parameter is optional. |
System.Nullable<System.DateTime> | deadline | An optional deadline for the call. The call will be cancelled if deadline is hit. |
System.Threading.CancellationToken | cancellationToken | An optional token for canceling the call. |
Returns
Type | Description |
---|---|
AsyncUnaryCall<Empty> | The call object. |
GetProduct(GetProductRequest, CallOptions)
Gets a [Product][google.cloud.retail.v2.Product].
Declaration
public virtual Product GetProduct(GetProductRequest request, CallOptions options)
Parameters
Type | Name | Description |
---|---|---|
GetProductRequest | request | The request to send to the server. |
CallOptions | options | The options for the call. |
Returns
Type | Description |
---|---|
Product | The response received from the server. |
GetProduct(GetProductRequest, Metadata, Nullable<DateTime>, CancellationToken)
Gets a [Product][google.cloud.retail.v2.Product].
Declaration
public virtual Product GetProduct(GetProductRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type | Name | Description |
---|---|---|
GetProductRequest | request | The request to send to the server. |
Metadata | headers | The initial metadata to send with the call. This parameter is optional. |
System.Nullable<System.DateTime> | deadline | An optional deadline for the call. The call will be cancelled if deadline is hit. |
System.Threading.CancellationToken | cancellationToken | An optional token for canceling the call. |
Returns
Type | Description |
---|---|
Product | The response received from the server. |
GetProductAsync(GetProductRequest, CallOptions)
Gets a [Product][google.cloud.retail.v2.Product].
Declaration
public virtual AsyncUnaryCall<Product> GetProductAsync(GetProductRequest request, CallOptions options)
Parameters
Type | Name | Description |
---|---|---|
GetProductRequest | request | The request to send to the server. |
CallOptions | options | The options for the call. |
Returns
Type | Description |
---|---|
AsyncUnaryCall<Product> | The call object. |
GetProductAsync(GetProductRequest, Metadata, Nullable<DateTime>, CancellationToken)
Gets a [Product][google.cloud.retail.v2.Product].
Declaration
public virtual AsyncUnaryCall<Product> GetProductAsync(GetProductRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type | Name | Description |
---|---|---|
GetProductRequest | request | The request to send to the server. |
Metadata | headers | The initial metadata to send with the call. This parameter is optional. |
System.Nullable<System.DateTime> | deadline | An optional deadline for the call. The call will be cancelled if deadline is hit. |
System.Threading.CancellationToken | cancellationToken | An optional token for canceling the call. |
Returns
Type | Description |
---|---|
AsyncUnaryCall<Product> | The call object. |
ImportProducts(ImportProductsRequest, CallOptions)
Bulk import of multiple [Product][google.cloud.retail.v2.Product]s.
Request processing may be synchronous. No partial updating is supported. Non-existing items are created.
Note that it is possible for a subset of the [Product][google.cloud.retail.v2.Product]s to be successfully updated.
Declaration
public virtual Operation ImportProducts(ImportProductsRequest request, CallOptions options)
Parameters
Type | Name | Description |
---|---|---|
ImportProductsRequest | request | The request to send to the server. |
CallOptions | options | The options for the call. |
Returns
Type | Description |
---|---|
Operation | The response received from the server. |
ImportProducts(ImportProductsRequest, Metadata, Nullable<DateTime>, CancellationToken)
Bulk import of multiple [Product][google.cloud.retail.v2.Product]s.
Request processing may be synchronous. No partial updating is supported. Non-existing items are created.
Note that it is possible for a subset of the [Product][google.cloud.retail.v2.Product]s to be successfully updated.
Declaration
public virtual Operation ImportProducts(ImportProductsRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type | Name | Description |
---|---|---|
ImportProductsRequest | request | The request to send to the server. |
Metadata | headers | The initial metadata to send with the call. This parameter is optional. |
System.Nullable<System.DateTime> | deadline | An optional deadline for the call. The call will be cancelled if deadline is hit. |
System.Threading.CancellationToken | cancellationToken | An optional token for canceling the call. |
Returns
Type | Description |
---|---|
Operation | The response received from the server. |
ImportProductsAsync(ImportProductsRequest, CallOptions)
Bulk import of multiple [Product][google.cloud.retail.v2.Product]s.
Request processing may be synchronous. No partial updating is supported. Non-existing items are created.
Note that it is possible for a subset of the [Product][google.cloud.retail.v2.Product]s to be successfully updated.
Declaration
public virtual AsyncUnaryCall<Operation> ImportProductsAsync(ImportProductsRequest request, CallOptions options)
Parameters
Type | Name | Description |
---|---|---|
ImportProductsRequest | request | The request to send to the server. |
CallOptions | options | The options for the call. |
Returns
Type | Description |
---|---|
AsyncUnaryCall<Operation> | The call object. |
ImportProductsAsync(ImportProductsRequest, Metadata, Nullable<DateTime>, CancellationToken)
Bulk import of multiple [Product][google.cloud.retail.v2.Product]s.
Request processing may be synchronous. No partial updating is supported. Non-existing items are created.
Note that it is possible for a subset of the [Product][google.cloud.retail.v2.Product]s to be successfully updated.
Declaration
public virtual AsyncUnaryCall<Operation> ImportProductsAsync(ImportProductsRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type | Name | Description |
---|---|---|
ImportProductsRequest | request | The request to send to the server. |
Metadata | headers | The initial metadata to send with the call. This parameter is optional. |
System.Nullable<System.DateTime> | deadline | An optional deadline for the call. The call will be cancelled if deadline is hit. |
System.Threading.CancellationToken | cancellationToken | An optional token for canceling the call. |
Returns
Type | Description |
---|---|
AsyncUnaryCall<Operation> | The call object. |
NewInstance(ClientBase.ClientBaseConfiguration)
Creates a new instance of client from given ClientBaseConfiguration
.
Declaration
protected override ProductService.ProductServiceClient NewInstance(ClientBase.ClientBaseConfiguration configuration)
Parameters
Type | Name | Description |
---|---|---|
ClientBase.ClientBaseConfiguration | configuration |
Returns
Type | Description |
---|---|
ProductService.ProductServiceClient |
Overrides
UpdateProduct(UpdateProductRequest, CallOptions)
Updates a [Product][google.cloud.retail.v2.Product].
Declaration
public virtual Product UpdateProduct(UpdateProductRequest request, CallOptions options)
Parameters
Type | Name | Description |
---|---|---|
UpdateProductRequest | request | The request to send to the server. |
CallOptions | options | The options for the call. |
Returns
Type | Description |
---|---|
Product | The response received from the server. |
UpdateProduct(UpdateProductRequest, Metadata, Nullable<DateTime>, CancellationToken)
Updates a [Product][google.cloud.retail.v2.Product].
Declaration
public virtual Product UpdateProduct(UpdateProductRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type | Name | Description |
---|---|---|
UpdateProductRequest | request | The request to send to the server. |
Metadata | headers | The initial metadata to send with the call. This parameter is optional. |
System.Nullable<System.DateTime> | deadline | An optional deadline for the call. The call will be cancelled if deadline is hit. |
System.Threading.CancellationToken | cancellationToken | An optional token for canceling the call. |
Returns
Type | Description |
---|---|
Product | The response received from the server. |
UpdateProductAsync(UpdateProductRequest, CallOptions)
Updates a [Product][google.cloud.retail.v2.Product].
Declaration
public virtual AsyncUnaryCall<Product> UpdateProductAsync(UpdateProductRequest request, CallOptions options)
Parameters
Type | Name | Description |
---|---|---|
UpdateProductRequest | request | The request to send to the server. |
CallOptions | options | The options for the call. |
Returns
Type | Description |
---|---|
AsyncUnaryCall<Product> | The call object. |
UpdateProductAsync(UpdateProductRequest, Metadata, Nullable<DateTime>, CancellationToken)
Updates a [Product][google.cloud.retail.v2.Product].
Declaration
public virtual AsyncUnaryCall<Product> UpdateProductAsync(UpdateProductRequest request, Metadata headers = null, DateTime? deadline = default(DateTime? ), CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type | Name | Description |
---|---|---|
UpdateProductRequest | request | The request to send to the server. |
Metadata | headers | The initial metadata to send with the call. This parameter is optional. |
System.Nullable<System.DateTime> | deadline | An optional deadline for the call. The call will be cancelled if deadline is hit. |
System.Threading.CancellationToken | cancellationToken | An optional token for canceling the call. |
Returns
Type | Description |
---|---|
AsyncUnaryCall<Product> | The call object. |