Compute Engine v1 API - Class Advice.AdviceClient (3.22.0)

public class Advice.AdviceClient : ClientBase<Advice.AdviceClient>

Reference documentation and code samples for the Compute Engine v1 API class Advice.AdviceClient.

Client for Advice

Inheritance

object > ClientBase > ClientBaseAdviceAdviceClient > Advice.AdviceClient

Namespace

Google.Cloud.Compute.V1

Assembly

Google.Cloud.Compute.V1.dll

Constructors

AdviceClient()

protected AdviceClient()

Protected parameterless constructor to allow creation of test doubles.

AdviceClient(CallInvoker)

public AdviceClient(CallInvoker callInvoker)

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

Parameter
Name Description
callInvoker CallInvoker

The callInvoker to use to make remote calls.

AdviceClient(ChannelBase)

public AdviceClient(ChannelBase channel)

Creates a new client for Advice

Parameter
Name Description
channel ChannelBase

The channel to use to make remote calls.

AdviceClient(ClientBaseConfiguration)

protected AdviceClient(ClientBase.ClientBaseConfiguration configuration)

Protected constructor to allow creation of configured clients.

Parameter
Name Description
configuration ClientBaseClientBaseConfiguration

The client configuration.

Methods

CalendarMode(CalendarModeAdviceRpcRequest, CallOptions)

public virtual CalendarModeAdviceResponse CalendarMode(CalendarModeAdviceRpcRequest request, CallOptions options)

Advise how, where and when to create the requested amount of instances with specified accelerators, within the specified time and location limits. The method recommends creating future reservations for the requested resources.

Parameters
Name Description
request CalendarModeAdviceRpcRequest

The request to send to the server.

options CallOptions

The options for the call.

Returns
Type Description
CalendarModeAdviceResponse

The response received from the server.

CalendarMode(CalendarModeAdviceRpcRequest, Metadata, DateTime?, CancellationToken)

public virtual CalendarModeAdviceResponse CalendarMode(CalendarModeAdviceRpcRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Advise how, where and when to create the requested amount of instances with specified accelerators, within the specified time and location limits. The method recommends creating future reservations for the requested resources.

Parameters
Name Description
request CalendarModeAdviceRpcRequest

The request to send to the server.

headers Metadata

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

deadline System.DateTime

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

cancellationToken CancellationToken

An optional token for canceling the call.

Returns
Type Description
CalendarModeAdviceResponse

The response received from the server.

CalendarModeAsync(CalendarModeAdviceRpcRequest, CallOptions)

public virtual AsyncUnaryCall<CalendarModeAdviceResponse> CalendarModeAsync(CalendarModeAdviceRpcRequest request, CallOptions options)

Advise how, where and when to create the requested amount of instances with specified accelerators, within the specified time and location limits. The method recommends creating future reservations for the requested resources.

Parameters
Name Description
request CalendarModeAdviceRpcRequest

The request to send to the server.

options CallOptions

The options for the call.

Returns
Type Description
AsyncUnaryCallCalendarModeAdviceResponse

The call object.

CalendarModeAsync(CalendarModeAdviceRpcRequest, Metadata, DateTime?, CancellationToken)

public virtual AsyncUnaryCall<CalendarModeAdviceResponse> CalendarModeAsync(CalendarModeAdviceRpcRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Advise how, where and when to create the requested amount of instances with specified accelerators, within the specified time and location limits. The method recommends creating future reservations for the requested resources.

Parameters
Name Description
request CalendarModeAdviceRpcRequest

The request to send to the server.

headers Metadata

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

deadline System.DateTime

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

cancellationToken CancellationToken

An optional token for canceling the call.

Returns
Type Description
AsyncUnaryCallCalendarModeAdviceResponse

The call object.

NewInstance(ClientBaseConfiguration)

protected override Advice.AdviceClient NewInstance(ClientBase.ClientBaseConfiguration configuration)

Creates a new instance of client from given ClientBaseConfiguration.

Parameter
Name Description
configuration ClientBaseClientBaseConfiguration
Returns
Type Description
AdviceAdviceClient
Overrides
Grpc.Core.ClientBase<Google.Cloud.Compute.V1.Advice.AdviceClient>.NewInstance(Grpc.Core.ClientBase.ClientBaseConfiguration)