Policy Simulator v1 API - Class Simulator.SimulatorClient (1.0.0)

public class Simulator.SimulatorClient : ClientBase<Simulator.SimulatorClient>

Reference documentation and code samples for the Policy Simulator v1 API class Simulator.SimulatorClient.

Client for Simulator

Inheritance

object > ClientBase > ClientBaseSimulatorSimulatorClient > Simulator.SimulatorClient

Namespace

Google.Cloud.PolicySimulator.V1

Assembly

Google.Cloud.PolicySimulator.V1.dll

Constructors

SimulatorClient()

protected SimulatorClient()

Protected parameterless constructor to allow creation of test doubles.

SimulatorClient(CallInvoker)

public SimulatorClient(CallInvoker callInvoker)

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

Parameter
NameDescription
callInvokerCallInvoker

The callInvoker to use to make remote calls.

SimulatorClient(ChannelBase)

public SimulatorClient(ChannelBase channel)

Creates a new client for Simulator

Parameter
NameDescription
channelChannelBase

The channel to use to make remote calls.

SimulatorClient(ClientBaseConfiguration)

protected SimulatorClient(ClientBase.ClientBaseConfiguration configuration)

Protected constructor to allow creation of configured clients.

Parameter
NameDescription
configurationClientBaseClientBaseConfiguration

The client configuration.

Methods

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.

CreateReplay(CreateReplayRequest, CallOptions)

public virtual Operation CreateReplay(CreateReplayRequest request, CallOptions options)

Creates and starts a [Replay][google.cloud.policysimulator.v1.Replay] using the given [ReplayConfig][google.cloud.policysimulator.v1.ReplayConfig].

Parameters
NameDescription
requestCreateReplayRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
Operation

The response received from the server.

CreateReplay(CreateReplayRequest, Metadata, DateTime?, CancellationToken)

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

Creates and starts a [Replay][google.cloud.policysimulator.v1.Replay] using the given [ReplayConfig][google.cloud.policysimulator.v1.ReplayConfig].

Parameters
NameDescription
requestCreateReplayRequest

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.

CreateReplayAsync(CreateReplayRequest, CallOptions)

public virtual AsyncUnaryCall<Operation> CreateReplayAsync(CreateReplayRequest request, CallOptions options)

Creates and starts a [Replay][google.cloud.policysimulator.v1.Replay] using the given [ReplayConfig][google.cloud.policysimulator.v1.ReplayConfig].

Parameters
NameDescription
requestCreateReplayRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
AsyncUnaryCallOperation

The call object.

CreateReplayAsync(CreateReplayRequest, Metadata, DateTime?, CancellationToken)

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

Creates and starts a [Replay][google.cloud.policysimulator.v1.Replay] using the given [ReplayConfig][google.cloud.policysimulator.v1.ReplayConfig].

Parameters
NameDescription
requestCreateReplayRequest

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.

GetReplay(GetReplayRequest, CallOptions)

public virtual Replay GetReplay(GetReplayRequest request, CallOptions options)

Gets the specified [Replay][google.cloud.policysimulator.v1.Replay]. Each Replay is available for at least 7 days.

Parameters
NameDescription
requestGetReplayRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
Replay

The response received from the server.

GetReplay(GetReplayRequest, Metadata, DateTime?, CancellationToken)

public virtual Replay GetReplay(GetReplayRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Gets the specified [Replay][google.cloud.policysimulator.v1.Replay]. Each Replay is available for at least 7 days.

Parameters
NameDescription
requestGetReplayRequest

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
Replay

The response received from the server.

GetReplayAsync(GetReplayRequest, CallOptions)

public virtual AsyncUnaryCall<Replay> GetReplayAsync(GetReplayRequest request, CallOptions options)

Gets the specified [Replay][google.cloud.policysimulator.v1.Replay]. Each Replay is available for at least 7 days.

Parameters
NameDescription
requestGetReplayRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
AsyncUnaryCallReplay

The call object.

GetReplayAsync(GetReplayRequest, Metadata, DateTime?, CancellationToken)

public virtual AsyncUnaryCall<Replay> GetReplayAsync(GetReplayRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Gets the specified [Replay][google.cloud.policysimulator.v1.Replay]. Each Replay is available for at least 7 days.

Parameters
NameDescription
requestGetReplayRequest

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
AsyncUnaryCallReplay

The call object.

ListReplayResults(ListReplayResultsRequest, CallOptions)

public virtual ListReplayResultsResponse ListReplayResults(ListReplayResultsRequest request, CallOptions options)

Lists the results of running a [Replay][google.cloud.policysimulator.v1.Replay].

Parameters
NameDescription
requestListReplayResultsRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
ListReplayResultsResponse

The response received from the server.

ListReplayResults(ListReplayResultsRequest, Metadata, DateTime?, CancellationToken)

public virtual ListReplayResultsResponse ListReplayResults(ListReplayResultsRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Lists the results of running a [Replay][google.cloud.policysimulator.v1.Replay].

Parameters
NameDescription
requestListReplayResultsRequest

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
ListReplayResultsResponse

The response received from the server.

ListReplayResultsAsync(ListReplayResultsRequest, CallOptions)

public virtual AsyncUnaryCall<ListReplayResultsResponse> ListReplayResultsAsync(ListReplayResultsRequest request, CallOptions options)

Lists the results of running a [Replay][google.cloud.policysimulator.v1.Replay].

Parameters
NameDescription
requestListReplayResultsRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
AsyncUnaryCallListReplayResultsResponse

The call object.

ListReplayResultsAsync(ListReplayResultsRequest, Metadata, DateTime?, CancellationToken)

public virtual AsyncUnaryCall<ListReplayResultsResponse> ListReplayResultsAsync(ListReplayResultsRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Lists the results of running a [Replay][google.cloud.policysimulator.v1.Replay].

Parameters
NameDescription
requestListReplayResultsRequest

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
AsyncUnaryCallListReplayResultsResponse

The call object.

NewInstance(ClientBaseConfiguration)

protected override Simulator.SimulatorClient NewInstance(ClientBase.ClientBaseConfiguration configuration)

Creates a new instance of client from given ClientBaseConfiguration.

Parameter
NameDescription
configurationClientBaseClientBaseConfiguration
Returns
TypeDescription
SimulatorSimulatorClient
Overrides