Backup and DR Service v1beta API - Class BackupDRClient (1.0.0-beta01)

public abstract class BackupDRClient

Reference documentation and code samples for the Backup and DR Service v1beta API class BackupDRClient.

BackupDR client wrapper, for convenient use.

Inheritance

object > BackupDRClient

Derived Types

Namespace

Google.Cloud.BackupDR.V1Beta

Assembly

Google.Cloud.BackupDR.V1Beta.dll

Remarks

The BackupDR Service

Properties

CreateAutoProtectionPolicyBindingOperationsClient

public virtual OperationsClient CreateAutoProtectionPolicyBindingOperationsClient { get; }

The long-running operations client for CreateAutoProtectionPolicyBinding.

Property Value
Type Description
OperationsClient

CreateAutoProtectionPolicyOperationsClient

public virtual OperationsClient CreateAutoProtectionPolicyOperationsClient { get; }

The long-running operations client for CreateAutoProtectionPolicy.

Property Value
Type Description
OperationsClient

CreateBackupPlanAssociationOperationsClient

public virtual OperationsClient CreateBackupPlanAssociationOperationsClient { get; }

The long-running operations client for CreateBackupPlanAssociation.

Property Value
Type Description
OperationsClient

CreateBackupPlanOperationsClient

public virtual OperationsClient CreateBackupPlanOperationsClient { get; }

The long-running operations client for CreateBackupPlan.

Property Value
Type Description
OperationsClient

CreateBackupVaultOperationsClient

public virtual OperationsClient CreateBackupVaultOperationsClient { get; }

The long-running operations client for CreateBackupVault.

Property Value
Type Description
OperationsClient

CreateManagementServerOperationsClient

public virtual OperationsClient CreateManagementServerOperationsClient { get; }

The long-running operations client for CreateManagementServer.

Property Value
Type Description
OperationsClient

DefaultEndpoint

public static string DefaultEndpoint { get; }

The default endpoint for the BackupDR service, which is a host of "backupdr.googleapis.com" and a port of 443.

Property Value
Type Description
string

DefaultScopes

public static IReadOnlyList<string> DefaultScopes { get; }

The default BackupDR scopes.

Property Value
Type Description
IReadOnlyListstring
Remarks

DeleteAutoProtectionPolicyOperationsClient

public virtual OperationsClient DeleteAutoProtectionPolicyOperationsClient { get; }

The long-running operations client for DeleteAutoProtectionPolicy.

Property Value
Type Description
OperationsClient

DeleteBackupOperationsClient

public virtual OperationsClient DeleteBackupOperationsClient { get; }

The long-running operations client for DeleteBackup.

Property Value
Type Description
OperationsClient

DeleteBackupPlanAssociationOperationsClient

public virtual OperationsClient DeleteBackupPlanAssociationOperationsClient { get; }

The long-running operations client for DeleteBackupPlanAssociation.

Property Value
Type Description
OperationsClient

DeleteBackupPlanOperationsClient

public virtual OperationsClient DeleteBackupPlanOperationsClient { get; }

The long-running operations client for DeleteBackupPlan.

Property Value
Type Description
OperationsClient

DeleteBackupVaultOperationsClient

public virtual OperationsClient DeleteBackupVaultOperationsClient { get; }

The long-running operations client for DeleteBackupVault.

Property Value
Type Description
OperationsClient

DeleteManagementServerOperationsClient

public virtual OperationsClient DeleteManagementServerOperationsClient { get; }

The long-running operations client for DeleteManagementServer.

Property Value
Type Description
OperationsClient

GrpcClient

public virtual BackupDR.BackupDRClient GrpcClient { get; }

The underlying gRPC BackupDR client

Property Value
Type Description
BackupDRBackupDRClient

IAMPolicyClient

public virtual IAMPolicyClient IAMPolicyClient { get; }

The IAMPolicyClient associated with this client.

Property Value
Type Description
IAMPolicyClient

InitializeServiceOperationsClient

public virtual OperationsClient InitializeServiceOperationsClient { get; }

The long-running operations client for InitializeService.

Property Value
Type Description
OperationsClient

InitiateDeleteAutoProtectionPolicyBindingOperationsClient

public virtual OperationsClient InitiateDeleteAutoProtectionPolicyBindingOperationsClient { get; }

The long-running operations client for InitiateDeleteAutoProtectionPolicyBinding.

Property Value
Type Description
OperationsClient

LocationsClient

public virtual LocationsClient LocationsClient { get; }

The LocationsClient associated with this client.

Property Value
Type Description
LocationsClient

RestoreBackupOperationsClient

public virtual OperationsClient RestoreBackupOperationsClient { get; }

The long-running operations client for RestoreBackup.

Property Value
Type Description
OperationsClient

ServiceMetadata

public static ServiceMetadata ServiceMetadata { get; }

The service metadata associated with this client type.

Property Value
Type Description
ServiceMetadata

TriggerBackupOperationsClient

public virtual OperationsClient TriggerBackupOperationsClient { get; }

The long-running operations client for TriggerBackup.

Property Value
Type Description
OperationsClient

UpdateAutoProtectionPolicyOperationsClient

public virtual OperationsClient UpdateAutoProtectionPolicyOperationsClient { get; }

The long-running operations client for UpdateAutoProtectionPolicy.

Property Value
Type Description
OperationsClient

UpdateBackupOperationsClient

public virtual OperationsClient UpdateBackupOperationsClient { get; }

The long-running operations client for UpdateBackup.

Property Value
Type Description
OperationsClient

UpdateBackupPlanAssociationOperationsClient

public virtual OperationsClient UpdateBackupPlanAssociationOperationsClient { get; }

The long-running operations client for UpdateBackupPlanAssociation.

Property Value
Type Description
OperationsClient

UpdateBackupPlanOperationsClient

public virtual OperationsClient UpdateBackupPlanOperationsClient { get; }

The long-running operations client for UpdateBackupPlan.

Property Value
Type Description
OperationsClient

UpdateBackupVaultOperationsClient

public virtual OperationsClient UpdateBackupVaultOperationsClient { get; }

The long-running operations client for UpdateBackupVault.

Property Value
Type Description
OperationsClient

UpdateDataSourceOperationsClient

public virtual OperationsClient UpdateDataSourceOperationsClient { get; }

The long-running operations client for UpdateDataSource.

Property Value
Type Description
OperationsClient

Methods

Create()

public static BackupDRClient Create()

Synchronously creates a BackupDRClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use BackupDRClientBuilder.

Returns
Type Description
BackupDRClient

The created BackupDRClient.

CreateAsync(CancellationToken)

public static Task<BackupDRClient> CreateAsync(CancellationToken cancellationToken = default)

Asynchronously creates a BackupDRClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use BackupDRClientBuilder.

Parameter
Name Description
cancellationToken CancellationToken

The CancellationToken to use while creating the client.

Returns
Type Description
TaskBackupDRClient

The task representing the created BackupDRClient.

CreateAutoProtectionPolicy(LocationName, AutoProtectionPolicy, string, CallSettings)

public virtual Operation<AutoProtectionPolicy, OperationMetadata> CreateAutoProtectionPolicy(LocationName parent, AutoProtectionPolicy autoProtectionPolicy, string autoProtectionPolicyId, CallSettings callSettings = null)

Creates a new AutoProtectionPolicy in a given project and location.

Parameters
Name Description
parent LocationName

Required. The parent resource where this policy will be created. Format: projects/{project}/locations/{location}

autoProtectionPolicy AutoProtectionPolicy

Required. The AutoProtectionPolicy resource to create.

autoProtectionPolicyId string

Required. The ID to use for the policy. This will become the final component of the policy's resource name.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationAutoProtectionPolicyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
AutoProtectionPolicy autoProtectionPolicy = new AutoProtectionPolicy();
string autoProtectionPolicyId = "";
// Make the request
Operation<AutoProtectionPolicy, OperationMetadata> response = backupDRClient.CreateAutoProtectionPolicy(parent, autoProtectionPolicy, autoProtectionPolicyId);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicy, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
AutoProtectionPolicy result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicy, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateAutoProtectionPolicy(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicy retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicy(CreateAutoProtectionPolicyRequest, CallSettings)

public virtual Operation<AutoProtectionPolicy, OperationMetadata> CreateAutoProtectionPolicy(CreateAutoProtectionPolicyRequest request, CallSettings callSettings = null)

Creates a new AutoProtectionPolicy in a given project and location.

Parameters
Name Description
request CreateAutoProtectionPolicyRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationAutoProtectionPolicyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
CreateAutoProtectionPolicyRequest request = new CreateAutoProtectionPolicyRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    AutoProtectionPolicyId = "",
    AutoProtectionPolicy = new AutoProtectionPolicy(),
};
// Make the request
Operation<AutoProtectionPolicy, OperationMetadata> response = backupDRClient.CreateAutoProtectionPolicy(request);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicy, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
AutoProtectionPolicy result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicy, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateAutoProtectionPolicy(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicy retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicy(string, AutoProtectionPolicy, string, CallSettings)

public virtual Operation<AutoProtectionPolicy, OperationMetadata> CreateAutoProtectionPolicy(string parent, AutoProtectionPolicy autoProtectionPolicy, string autoProtectionPolicyId, CallSettings callSettings = null)

Creates a new AutoProtectionPolicy in a given project and location.

Parameters
Name Description
parent string

Required. The parent resource where this policy will be created. Format: projects/{project}/locations/{location}

autoProtectionPolicy AutoProtectionPolicy

Required. The AutoProtectionPolicy resource to create.

autoProtectionPolicyId string

Required. The ID to use for the policy. This will become the final component of the policy's resource name.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationAutoProtectionPolicyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
AutoProtectionPolicy autoProtectionPolicy = new AutoProtectionPolicy();
string autoProtectionPolicyId = "";
// Make the request
Operation<AutoProtectionPolicy, OperationMetadata> response = backupDRClient.CreateAutoProtectionPolicy(parent, autoProtectionPolicy, autoProtectionPolicyId);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicy, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
AutoProtectionPolicy result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicy, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateAutoProtectionPolicy(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicy retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicyAsync(LocationName, AutoProtectionPolicy, string, CallSettings)

public virtual Task<Operation<AutoProtectionPolicy, OperationMetadata>> CreateAutoProtectionPolicyAsync(LocationName parent, AutoProtectionPolicy autoProtectionPolicy, string autoProtectionPolicyId, CallSettings callSettings = null)

Creates a new AutoProtectionPolicy in a given project and location.

Parameters
Name Description
parent LocationName

Required. The parent resource where this policy will be created. Format: projects/{project}/locations/{location}

autoProtectionPolicy AutoProtectionPolicy

Required. The AutoProtectionPolicy resource to create.

autoProtectionPolicyId string

Required. The ID to use for the policy. This will become the final component of the policy's resource name.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationAutoProtectionPolicyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
AutoProtectionPolicy autoProtectionPolicy = new AutoProtectionPolicy();
string autoProtectionPolicyId = "";
// Make the request
Operation<AutoProtectionPolicy, OperationMetadata> response = await backupDRClient.CreateAutoProtectionPolicyAsync(parent, autoProtectionPolicy, autoProtectionPolicyId);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicy, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicy result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicy, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateAutoProtectionPolicyAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicy retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicyAsync(LocationName, AutoProtectionPolicy, string, CancellationToken)

public virtual Task<Operation<AutoProtectionPolicy, OperationMetadata>> CreateAutoProtectionPolicyAsync(LocationName parent, AutoProtectionPolicy autoProtectionPolicy, string autoProtectionPolicyId, CancellationToken cancellationToken)

Creates a new AutoProtectionPolicy in a given project and location.

Parameters
Name Description
parent LocationName

Required. The parent resource where this policy will be created. Format: projects/{project}/locations/{location}

autoProtectionPolicy AutoProtectionPolicy

Required. The AutoProtectionPolicy resource to create.

autoProtectionPolicyId string

Required. The ID to use for the policy. This will become the final component of the policy's resource name.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationAutoProtectionPolicyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
AutoProtectionPolicy autoProtectionPolicy = new AutoProtectionPolicy();
string autoProtectionPolicyId = "";
// Make the request
Operation<AutoProtectionPolicy, OperationMetadata> response = await backupDRClient.CreateAutoProtectionPolicyAsync(parent, autoProtectionPolicy, autoProtectionPolicyId);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicy, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicy result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicy, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateAutoProtectionPolicyAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicy retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicyAsync(CreateAutoProtectionPolicyRequest, CallSettings)

public virtual Task<Operation<AutoProtectionPolicy, OperationMetadata>> CreateAutoProtectionPolicyAsync(CreateAutoProtectionPolicyRequest request, CallSettings callSettings = null)

Creates a new AutoProtectionPolicy in a given project and location.

Parameters
Name Description
request CreateAutoProtectionPolicyRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationAutoProtectionPolicyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
CreateAutoProtectionPolicyRequest request = new CreateAutoProtectionPolicyRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    AutoProtectionPolicyId = "",
    AutoProtectionPolicy = new AutoProtectionPolicy(),
};
// Make the request
Operation<AutoProtectionPolicy, OperationMetadata> response = await backupDRClient.CreateAutoProtectionPolicyAsync(request);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicy, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicy result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicy, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateAutoProtectionPolicyAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicy retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicyAsync(CreateAutoProtectionPolicyRequest, CancellationToken)

public virtual Task<Operation<AutoProtectionPolicy, OperationMetadata>> CreateAutoProtectionPolicyAsync(CreateAutoProtectionPolicyRequest request, CancellationToken cancellationToken)

Creates a new AutoProtectionPolicy in a given project and location.

Parameters
Name Description
request CreateAutoProtectionPolicyRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationAutoProtectionPolicyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
CreateAutoProtectionPolicyRequest request = new CreateAutoProtectionPolicyRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    AutoProtectionPolicyId = "",
    AutoProtectionPolicy = new AutoProtectionPolicy(),
};
// Make the request
Operation<AutoProtectionPolicy, OperationMetadata> response = await backupDRClient.CreateAutoProtectionPolicyAsync(request);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicy, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicy result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicy, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateAutoProtectionPolicyAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicy retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicyAsync(string, AutoProtectionPolicy, string, CallSettings)

public virtual Task<Operation<AutoProtectionPolicy, OperationMetadata>> CreateAutoProtectionPolicyAsync(string parent, AutoProtectionPolicy autoProtectionPolicy, string autoProtectionPolicyId, CallSettings callSettings = null)

Creates a new AutoProtectionPolicy in a given project and location.

Parameters
Name Description
parent string

Required. The parent resource where this policy will be created. Format: projects/{project}/locations/{location}

autoProtectionPolicy AutoProtectionPolicy

Required. The AutoProtectionPolicy resource to create.

autoProtectionPolicyId string

Required. The ID to use for the policy. This will become the final component of the policy's resource name.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationAutoProtectionPolicyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
AutoProtectionPolicy autoProtectionPolicy = new AutoProtectionPolicy();
string autoProtectionPolicyId = "";
// Make the request
Operation<AutoProtectionPolicy, OperationMetadata> response = await backupDRClient.CreateAutoProtectionPolicyAsync(parent, autoProtectionPolicy, autoProtectionPolicyId);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicy, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicy result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicy, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateAutoProtectionPolicyAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicy retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicyAsync(string, AutoProtectionPolicy, string, CancellationToken)

public virtual Task<Operation<AutoProtectionPolicy, OperationMetadata>> CreateAutoProtectionPolicyAsync(string parent, AutoProtectionPolicy autoProtectionPolicy, string autoProtectionPolicyId, CancellationToken cancellationToken)

Creates a new AutoProtectionPolicy in a given project and location.

Parameters
Name Description
parent string

Required. The parent resource where this policy will be created. Format: projects/{project}/locations/{location}

autoProtectionPolicy AutoProtectionPolicy

Required. The AutoProtectionPolicy resource to create.

autoProtectionPolicyId string

Required. The ID to use for the policy. This will become the final component of the policy's resource name.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationAutoProtectionPolicyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
AutoProtectionPolicy autoProtectionPolicy = new AutoProtectionPolicy();
string autoProtectionPolicyId = "";
// Make the request
Operation<AutoProtectionPolicy, OperationMetadata> response = await backupDRClient.CreateAutoProtectionPolicyAsync(parent, autoProtectionPolicy, autoProtectionPolicyId);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicy, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicy result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicy, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateAutoProtectionPolicyAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicy retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicyBinding(AutoProtectionPolicyName, AutoProtectionPolicyBinding, string, CallSettings)

public virtual Operation<AutoProtectionPolicyBinding, OperationMetadata> CreateAutoProtectionPolicyBinding(AutoProtectionPolicyName parent, AutoProtectionPolicyBinding autoProtectionPolicyBinding, string autoProtectionPolicyBindingId, CallSettings callSettings = null)

Creates a new AutoProtectionPolicyBinding in a given project and location.

Parameters
Name Description
parent AutoProtectionPolicyName

Required. The parent resource where this binding will be created. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

autoProtectionPolicyBinding AutoProtectionPolicyBinding

Required. The AutoProtectionPolicyBinding resource to create.

autoProtectionPolicyBindingId string

Required. The ID to use for the binding. This will become the final component of the binding's resource name.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationAutoProtectionPolicyBindingOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
AutoProtectionPolicyName parent = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]");
AutoProtectionPolicyBinding autoProtectionPolicyBinding = new AutoProtectionPolicyBinding();
string autoProtectionPolicyBindingId = "";
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = backupDRClient.CreateAutoProtectionPolicyBinding(parent, autoProtectionPolicyBinding, autoProtectionPolicyBindingId);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateAutoProtectionPolicyBinding(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicyBinding(CreateAutoProtectionPolicyBindingRequest, CallSettings)

public virtual Operation<AutoProtectionPolicyBinding, OperationMetadata> CreateAutoProtectionPolicyBinding(CreateAutoProtectionPolicyBindingRequest request, CallSettings callSettings = null)

Creates a new AutoProtectionPolicyBinding in a given project and location.

Parameters
Name Description
request CreateAutoProtectionPolicyBindingRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationAutoProtectionPolicyBindingOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
CreateAutoProtectionPolicyBindingRequest request = new CreateAutoProtectionPolicyBindingRequest
{
    ParentAsAutoProtectionPolicyName = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]"),
    AutoProtectionPolicyBindingId = "",
    AutoProtectionPolicyBinding = new AutoProtectionPolicyBinding(),
};
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = backupDRClient.CreateAutoProtectionPolicyBinding(request);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateAutoProtectionPolicyBinding(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicyBinding(string, AutoProtectionPolicyBinding, string, CallSettings)

public virtual Operation<AutoProtectionPolicyBinding, OperationMetadata> CreateAutoProtectionPolicyBinding(string parent, AutoProtectionPolicyBinding autoProtectionPolicyBinding, string autoProtectionPolicyBindingId, CallSettings callSettings = null)

Creates a new AutoProtectionPolicyBinding in a given project and location.

Parameters
Name Description
parent string

Required. The parent resource where this binding will be created. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

autoProtectionPolicyBinding AutoProtectionPolicyBinding

Required. The AutoProtectionPolicyBinding resource to create.

autoProtectionPolicyBindingId string

Required. The ID to use for the binding. This will become the final component of the binding's resource name.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationAutoProtectionPolicyBindingOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]";
AutoProtectionPolicyBinding autoProtectionPolicyBinding = new AutoProtectionPolicyBinding();
string autoProtectionPolicyBindingId = "";
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = backupDRClient.CreateAutoProtectionPolicyBinding(parent, autoProtectionPolicyBinding, autoProtectionPolicyBindingId);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateAutoProtectionPolicyBinding(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicyBindingAsync(AutoProtectionPolicyName, AutoProtectionPolicyBinding, string, CallSettings)

public virtual Task<Operation<AutoProtectionPolicyBinding, OperationMetadata>> CreateAutoProtectionPolicyBindingAsync(AutoProtectionPolicyName parent, AutoProtectionPolicyBinding autoProtectionPolicyBinding, string autoProtectionPolicyBindingId, CallSettings callSettings = null)

Creates a new AutoProtectionPolicyBinding in a given project and location.

Parameters
Name Description
parent AutoProtectionPolicyName

Required. The parent resource where this binding will be created. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

autoProtectionPolicyBinding AutoProtectionPolicyBinding

Required. The AutoProtectionPolicyBinding resource to create.

autoProtectionPolicyBindingId string

Required. The ID to use for the binding. This will become the final component of the binding's resource name.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationAutoProtectionPolicyBindingOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
AutoProtectionPolicyName parent = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]");
AutoProtectionPolicyBinding autoProtectionPolicyBinding = new AutoProtectionPolicyBinding();
string autoProtectionPolicyBindingId = "";
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = await backupDRClient.CreateAutoProtectionPolicyBindingAsync(parent, autoProtectionPolicyBinding, autoProtectionPolicyBindingId);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateAutoProtectionPolicyBindingAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicyBindingAsync(AutoProtectionPolicyName, AutoProtectionPolicyBinding, string, CancellationToken)

public virtual Task<Operation<AutoProtectionPolicyBinding, OperationMetadata>> CreateAutoProtectionPolicyBindingAsync(AutoProtectionPolicyName parent, AutoProtectionPolicyBinding autoProtectionPolicyBinding, string autoProtectionPolicyBindingId, CancellationToken cancellationToken)

Creates a new AutoProtectionPolicyBinding in a given project and location.

Parameters
Name Description
parent AutoProtectionPolicyName

Required. The parent resource where this binding will be created. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

autoProtectionPolicyBinding AutoProtectionPolicyBinding

Required. The AutoProtectionPolicyBinding resource to create.

autoProtectionPolicyBindingId string

Required. The ID to use for the binding. This will become the final component of the binding's resource name.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationAutoProtectionPolicyBindingOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
AutoProtectionPolicyName parent = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]");
AutoProtectionPolicyBinding autoProtectionPolicyBinding = new AutoProtectionPolicyBinding();
string autoProtectionPolicyBindingId = "";
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = await backupDRClient.CreateAutoProtectionPolicyBindingAsync(parent, autoProtectionPolicyBinding, autoProtectionPolicyBindingId);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateAutoProtectionPolicyBindingAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicyBindingAsync(CreateAutoProtectionPolicyBindingRequest, CallSettings)

public virtual Task<Operation<AutoProtectionPolicyBinding, OperationMetadata>> CreateAutoProtectionPolicyBindingAsync(CreateAutoProtectionPolicyBindingRequest request, CallSettings callSettings = null)

Creates a new AutoProtectionPolicyBinding in a given project and location.

Parameters
Name Description
request CreateAutoProtectionPolicyBindingRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationAutoProtectionPolicyBindingOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
CreateAutoProtectionPolicyBindingRequest request = new CreateAutoProtectionPolicyBindingRequest
{
    ParentAsAutoProtectionPolicyName = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]"),
    AutoProtectionPolicyBindingId = "",
    AutoProtectionPolicyBinding = new AutoProtectionPolicyBinding(),
};
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = await backupDRClient.CreateAutoProtectionPolicyBindingAsync(request);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateAutoProtectionPolicyBindingAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicyBindingAsync(CreateAutoProtectionPolicyBindingRequest, CancellationToken)

public virtual Task<Operation<AutoProtectionPolicyBinding, OperationMetadata>> CreateAutoProtectionPolicyBindingAsync(CreateAutoProtectionPolicyBindingRequest request, CancellationToken cancellationToken)

Creates a new AutoProtectionPolicyBinding in a given project and location.

Parameters
Name Description
request CreateAutoProtectionPolicyBindingRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationAutoProtectionPolicyBindingOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
CreateAutoProtectionPolicyBindingRequest request = new CreateAutoProtectionPolicyBindingRequest
{
    ParentAsAutoProtectionPolicyName = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]"),
    AutoProtectionPolicyBindingId = "",
    AutoProtectionPolicyBinding = new AutoProtectionPolicyBinding(),
};
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = await backupDRClient.CreateAutoProtectionPolicyBindingAsync(request);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateAutoProtectionPolicyBindingAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicyBindingAsync(string, AutoProtectionPolicyBinding, string, CallSettings)

public virtual Task<Operation<AutoProtectionPolicyBinding, OperationMetadata>> CreateAutoProtectionPolicyBindingAsync(string parent, AutoProtectionPolicyBinding autoProtectionPolicyBinding, string autoProtectionPolicyBindingId, CallSettings callSettings = null)

Creates a new AutoProtectionPolicyBinding in a given project and location.

Parameters
Name Description
parent string

Required. The parent resource where this binding will be created. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

autoProtectionPolicyBinding AutoProtectionPolicyBinding

Required. The AutoProtectionPolicyBinding resource to create.

autoProtectionPolicyBindingId string

Required. The ID to use for the binding. This will become the final component of the binding's resource name.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationAutoProtectionPolicyBindingOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]";
AutoProtectionPolicyBinding autoProtectionPolicyBinding = new AutoProtectionPolicyBinding();
string autoProtectionPolicyBindingId = "";
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = await backupDRClient.CreateAutoProtectionPolicyBindingAsync(parent, autoProtectionPolicyBinding, autoProtectionPolicyBindingId);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateAutoProtectionPolicyBindingAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

CreateAutoProtectionPolicyBindingAsync(string, AutoProtectionPolicyBinding, string, CancellationToken)

public virtual Task<Operation<AutoProtectionPolicyBinding, OperationMetadata>> CreateAutoProtectionPolicyBindingAsync(string parent, AutoProtectionPolicyBinding autoProtectionPolicyBinding, string autoProtectionPolicyBindingId, CancellationToken cancellationToken)

Creates a new AutoProtectionPolicyBinding in a given project and location.

Parameters
Name Description
parent string

Required. The parent resource where this binding will be created. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

autoProtectionPolicyBinding AutoProtectionPolicyBinding

Required. The AutoProtectionPolicyBinding resource to create.

autoProtectionPolicyBindingId string

Required. The ID to use for the binding. This will become the final component of the binding's resource name.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationAutoProtectionPolicyBindingOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]";
AutoProtectionPolicyBinding autoProtectionPolicyBinding = new AutoProtectionPolicyBinding();
string autoProtectionPolicyBindingId = "";
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = await backupDRClient.CreateAutoProtectionPolicyBindingAsync(parent, autoProtectionPolicyBinding, autoProtectionPolicyBindingId);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateAutoProtectionPolicyBindingAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

CreateBackupPlan(LocationName, BackupPlan, string, CallSettings)

public virtual Operation<BackupPlan, OperationMetadata> CreateBackupPlan(LocationName parent, BackupPlan backupPlan, string backupPlanId, CallSettings callSettings = null)

Create a BackupPlan

Parameters
Name Description
parent LocationName

Required. The BackupPlan project and location in the format projects/{project}/locations/{location}. In Google Cloud Backup and DR locations map to Google Cloud regions, for example us-central1.

backupPlan BackupPlan

Required. The BackupPlan resource object to create.

backupPlanId string

Required. The name of the BackupPlan to create. The name must be unique for the specified project and location.The name must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens. Pattern, /[a-z][a-z0-9-]{,62}/.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
BackupPlan backupPlan = new BackupPlan();
string backupPlanId = "";
// Make the request
Operation<BackupPlan, OperationMetadata> response = backupDRClient.CreateBackupPlan(parent, backupPlan, backupPlanId);

// Poll until the returned long-running operation is complete
Operation<BackupPlan, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupPlan result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlan, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateBackupPlan(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlan retrievedResult = retrievedResponse.Result;
}

CreateBackupPlan(CreateBackupPlanRequest, CallSettings)

public virtual Operation<BackupPlan, OperationMetadata> CreateBackupPlan(CreateBackupPlanRequest request, CallSettings callSettings = null)

Create a BackupPlan

Parameters
Name Description
request CreateBackupPlanRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
CreateBackupPlanRequest request = new CreateBackupPlanRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    BackupPlanId = "",
    BackupPlan = new BackupPlan(),
    RequestId = "",
};
// Make the request
Operation<BackupPlan, OperationMetadata> response = backupDRClient.CreateBackupPlan(request);

// Poll until the returned long-running operation is complete
Operation<BackupPlan, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupPlan result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlan, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateBackupPlan(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlan retrievedResult = retrievedResponse.Result;
}

CreateBackupPlan(string, BackupPlan, string, CallSettings)

public virtual Operation<BackupPlan, OperationMetadata> CreateBackupPlan(string parent, BackupPlan backupPlan, string backupPlanId, CallSettings callSettings = null)

Create a BackupPlan

Parameters
Name Description
parent string

Required. The BackupPlan project and location in the format projects/{project}/locations/{location}. In Google Cloud Backup and DR locations map to Google Cloud regions, for example us-central1.

backupPlan BackupPlan

Required. The BackupPlan resource object to create.

backupPlanId string

Required. The name of the BackupPlan to create. The name must be unique for the specified project and location.The name must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens. Pattern, /[a-z][a-z0-9-]{,62}/.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
BackupPlan backupPlan = new BackupPlan();
string backupPlanId = "";
// Make the request
Operation<BackupPlan, OperationMetadata> response = backupDRClient.CreateBackupPlan(parent, backupPlan, backupPlanId);

// Poll until the returned long-running operation is complete
Operation<BackupPlan, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupPlan result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlan, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateBackupPlan(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlan retrievedResult = retrievedResponse.Result;
}

CreateBackupPlanAssociation(LocationName, BackupPlanAssociation, string, CallSettings)

public virtual Operation<BackupPlanAssociation, OperationMetadata> CreateBackupPlanAssociation(LocationName parent, BackupPlanAssociation backupPlanAssociation, string backupPlanAssociationId, CallSettings callSettings = null)

Create a BackupPlanAssociation

Parameters
Name Description
parent LocationName

Required. The backup plan association project and location in the format projects/{project_id}/locations/{location}. In Backup and DR locations map to Google Cloud regions, for example us-central1.

backupPlanAssociation BackupPlanAssociation

Required. The resource being created

backupPlanAssociationId string

Required. The name of the backup plan association to create. The name must be unique for the specified project and location.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanAssociationOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
BackupPlanAssociation backupPlanAssociation = new BackupPlanAssociation();
string backupPlanAssociationId = "";
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = backupDRClient.CreateBackupPlanAssociation(parent, backupPlanAssociation, backupPlanAssociationId);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateBackupPlanAssociation(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

CreateBackupPlanAssociation(CreateBackupPlanAssociationRequest, CallSettings)

public virtual Operation<BackupPlanAssociation, OperationMetadata> CreateBackupPlanAssociation(CreateBackupPlanAssociationRequest request, CallSettings callSettings = null)

Create a BackupPlanAssociation

Parameters
Name Description
request CreateBackupPlanAssociationRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanAssociationOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
CreateBackupPlanAssociationRequest request = new CreateBackupPlanAssociationRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    BackupPlanAssociationId = "",
    BackupPlanAssociation = new BackupPlanAssociation(),
    RequestId = "",
};
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = backupDRClient.CreateBackupPlanAssociation(request);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateBackupPlanAssociation(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

CreateBackupPlanAssociation(string, BackupPlanAssociation, string, CallSettings)

public virtual Operation<BackupPlanAssociation, OperationMetadata> CreateBackupPlanAssociation(string parent, BackupPlanAssociation backupPlanAssociation, string backupPlanAssociationId, CallSettings callSettings = null)

Create a BackupPlanAssociation

Parameters
Name Description
parent string

Required. The backup plan association project and location in the format projects/{project_id}/locations/{location}. In Backup and DR locations map to Google Cloud regions, for example us-central1.

backupPlanAssociation BackupPlanAssociation

Required. The resource being created

backupPlanAssociationId string

Required. The name of the backup plan association to create. The name must be unique for the specified project and location.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanAssociationOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
BackupPlanAssociation backupPlanAssociation = new BackupPlanAssociation();
string backupPlanAssociationId = "";
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = backupDRClient.CreateBackupPlanAssociation(parent, backupPlanAssociation, backupPlanAssociationId);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateBackupPlanAssociation(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

CreateBackupPlanAssociationAsync(LocationName, BackupPlanAssociation, string, CallSettings)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> CreateBackupPlanAssociationAsync(LocationName parent, BackupPlanAssociation backupPlanAssociation, string backupPlanAssociationId, CallSettings callSettings = null)

Create a BackupPlanAssociation

Parameters
Name Description
parent LocationName

Required. The backup plan association project and location in the format projects/{project_id}/locations/{location}. In Backup and DR locations map to Google Cloud regions, for example us-central1.

backupPlanAssociation BackupPlanAssociation

Required. The resource being created

backupPlanAssociationId string

Required. The name of the backup plan association to create. The name must be unique for the specified project and location.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
BackupPlanAssociation backupPlanAssociation = new BackupPlanAssociation();
string backupPlanAssociationId = "";
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = await backupDRClient.CreateBackupPlanAssociationAsync(parent, backupPlanAssociation, backupPlanAssociationId);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupPlanAssociationAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

CreateBackupPlanAssociationAsync(LocationName, BackupPlanAssociation, string, CancellationToken)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> CreateBackupPlanAssociationAsync(LocationName parent, BackupPlanAssociation backupPlanAssociation, string backupPlanAssociationId, CancellationToken cancellationToken)

Create a BackupPlanAssociation

Parameters
Name Description
parent LocationName

Required. The backup plan association project and location in the format projects/{project_id}/locations/{location}. In Backup and DR locations map to Google Cloud regions, for example us-central1.

backupPlanAssociation BackupPlanAssociation

Required. The resource being created

backupPlanAssociationId string

Required. The name of the backup plan association to create. The name must be unique for the specified project and location.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
BackupPlanAssociation backupPlanAssociation = new BackupPlanAssociation();
string backupPlanAssociationId = "";
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = await backupDRClient.CreateBackupPlanAssociationAsync(parent, backupPlanAssociation, backupPlanAssociationId);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupPlanAssociationAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

CreateBackupPlanAssociationAsync(CreateBackupPlanAssociationRequest, CallSettings)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> CreateBackupPlanAssociationAsync(CreateBackupPlanAssociationRequest request, CallSettings callSettings = null)

Create a BackupPlanAssociation

Parameters
Name Description
request CreateBackupPlanAssociationRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
CreateBackupPlanAssociationRequest request = new CreateBackupPlanAssociationRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    BackupPlanAssociationId = "",
    BackupPlanAssociation = new BackupPlanAssociation(),
    RequestId = "",
};
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = await backupDRClient.CreateBackupPlanAssociationAsync(request);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupPlanAssociationAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

CreateBackupPlanAssociationAsync(CreateBackupPlanAssociationRequest, CancellationToken)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> CreateBackupPlanAssociationAsync(CreateBackupPlanAssociationRequest request, CancellationToken cancellationToken)

Create a BackupPlanAssociation

Parameters
Name Description
request CreateBackupPlanAssociationRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
CreateBackupPlanAssociationRequest request = new CreateBackupPlanAssociationRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    BackupPlanAssociationId = "",
    BackupPlanAssociation = new BackupPlanAssociation(),
    RequestId = "",
};
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = await backupDRClient.CreateBackupPlanAssociationAsync(request);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupPlanAssociationAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

CreateBackupPlanAssociationAsync(string, BackupPlanAssociation, string, CallSettings)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> CreateBackupPlanAssociationAsync(string parent, BackupPlanAssociation backupPlanAssociation, string backupPlanAssociationId, CallSettings callSettings = null)

Create a BackupPlanAssociation

Parameters
Name Description
parent string

Required. The backup plan association project and location in the format projects/{project_id}/locations/{location}. In Backup and DR locations map to Google Cloud regions, for example us-central1.

backupPlanAssociation BackupPlanAssociation

Required. The resource being created

backupPlanAssociationId string

Required. The name of the backup plan association to create. The name must be unique for the specified project and location.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
BackupPlanAssociation backupPlanAssociation = new BackupPlanAssociation();
string backupPlanAssociationId = "";
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = await backupDRClient.CreateBackupPlanAssociationAsync(parent, backupPlanAssociation, backupPlanAssociationId);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupPlanAssociationAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

CreateBackupPlanAssociationAsync(string, BackupPlanAssociation, string, CancellationToken)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> CreateBackupPlanAssociationAsync(string parent, BackupPlanAssociation backupPlanAssociation, string backupPlanAssociationId, CancellationToken cancellationToken)

Create a BackupPlanAssociation

Parameters
Name Description
parent string

Required. The backup plan association project and location in the format projects/{project_id}/locations/{location}. In Backup and DR locations map to Google Cloud regions, for example us-central1.

backupPlanAssociation BackupPlanAssociation

Required. The resource being created

backupPlanAssociationId string

Required. The name of the backup plan association to create. The name must be unique for the specified project and location.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
BackupPlanAssociation backupPlanAssociation = new BackupPlanAssociation();
string backupPlanAssociationId = "";
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = await backupDRClient.CreateBackupPlanAssociationAsync(parent, backupPlanAssociation, backupPlanAssociationId);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupPlanAssociationAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

CreateBackupPlanAsync(LocationName, BackupPlan, string, CallSettings)

public virtual Task<Operation<BackupPlan, OperationMetadata>> CreateBackupPlanAsync(LocationName parent, BackupPlan backupPlan, string backupPlanId, CallSettings callSettings = null)

Create a BackupPlan

Parameters
Name Description
parent LocationName

Required. The BackupPlan project and location in the format projects/{project}/locations/{location}. In Google Cloud Backup and DR locations map to Google Cloud regions, for example us-central1.

backupPlan BackupPlan

Required. The BackupPlan resource object to create.

backupPlanId string

Required. The name of the BackupPlan to create. The name must be unique for the specified project and location.The name must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens. Pattern, /[a-z][a-z0-9-]{,62}/.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
BackupPlan backupPlan = new BackupPlan();
string backupPlanId = "";
// Make the request
Operation<BackupPlan, OperationMetadata> response = await backupDRClient.CreateBackupPlanAsync(parent, backupPlan, backupPlanId);

// Poll until the returned long-running operation is complete
Operation<BackupPlan, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlan result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlan, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupPlanAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlan retrievedResult = retrievedResponse.Result;
}

CreateBackupPlanAsync(LocationName, BackupPlan, string, CancellationToken)

public virtual Task<Operation<BackupPlan, OperationMetadata>> CreateBackupPlanAsync(LocationName parent, BackupPlan backupPlan, string backupPlanId, CancellationToken cancellationToken)

Create a BackupPlan

Parameters
Name Description
parent LocationName

Required. The BackupPlan project and location in the format projects/{project}/locations/{location}. In Google Cloud Backup and DR locations map to Google Cloud regions, for example us-central1.

backupPlan BackupPlan

Required. The BackupPlan resource object to create.

backupPlanId string

Required. The name of the BackupPlan to create. The name must be unique for the specified project and location.The name must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens. Pattern, /[a-z][a-z0-9-]{,62}/.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupPlanOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
BackupPlan backupPlan = new BackupPlan();
string backupPlanId = "";
// Make the request
Operation<BackupPlan, OperationMetadata> response = await backupDRClient.CreateBackupPlanAsync(parent, backupPlan, backupPlanId);

// Poll until the returned long-running operation is complete
Operation<BackupPlan, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlan result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlan, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupPlanAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlan retrievedResult = retrievedResponse.Result;
}

CreateBackupPlanAsync(CreateBackupPlanRequest, CallSettings)

public virtual Task<Operation<BackupPlan, OperationMetadata>> CreateBackupPlanAsync(CreateBackupPlanRequest request, CallSettings callSettings = null)

Create a BackupPlan

Parameters
Name Description
request CreateBackupPlanRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
CreateBackupPlanRequest request = new CreateBackupPlanRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    BackupPlanId = "",
    BackupPlan = new BackupPlan(),
    RequestId = "",
};
// Make the request
Operation<BackupPlan, OperationMetadata> response = await backupDRClient.CreateBackupPlanAsync(request);

// Poll until the returned long-running operation is complete
Operation<BackupPlan, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlan result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlan, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupPlanAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlan retrievedResult = retrievedResponse.Result;
}

CreateBackupPlanAsync(CreateBackupPlanRequest, CancellationToken)

public virtual Task<Operation<BackupPlan, OperationMetadata>> CreateBackupPlanAsync(CreateBackupPlanRequest request, CancellationToken cancellationToken)

Create a BackupPlan

Parameters
Name Description
request CreateBackupPlanRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupPlanOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
CreateBackupPlanRequest request = new CreateBackupPlanRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    BackupPlanId = "",
    BackupPlan = new BackupPlan(),
    RequestId = "",
};
// Make the request
Operation<BackupPlan, OperationMetadata> response = await backupDRClient.CreateBackupPlanAsync(request);

// Poll until the returned long-running operation is complete
Operation<BackupPlan, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlan result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlan, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupPlanAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlan retrievedResult = retrievedResponse.Result;
}

CreateBackupPlanAsync(string, BackupPlan, string, CallSettings)

public virtual Task<Operation<BackupPlan, OperationMetadata>> CreateBackupPlanAsync(string parent, BackupPlan backupPlan, string backupPlanId, CallSettings callSettings = null)

Create a BackupPlan

Parameters
Name Description
parent string

Required. The BackupPlan project and location in the format projects/{project}/locations/{location}. In Google Cloud Backup and DR locations map to Google Cloud regions, for example us-central1.

backupPlan BackupPlan

Required. The BackupPlan resource object to create.

backupPlanId string

Required. The name of the BackupPlan to create. The name must be unique for the specified project and location.The name must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens. Pattern, /[a-z][a-z0-9-]{,62}/.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
BackupPlan backupPlan = new BackupPlan();
string backupPlanId = "";
// Make the request
Operation<BackupPlan, OperationMetadata> response = await backupDRClient.CreateBackupPlanAsync(parent, backupPlan, backupPlanId);

// Poll until the returned long-running operation is complete
Operation<BackupPlan, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlan result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlan, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupPlanAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlan retrievedResult = retrievedResponse.Result;
}

CreateBackupPlanAsync(string, BackupPlan, string, CancellationToken)

public virtual Task<Operation<BackupPlan, OperationMetadata>> CreateBackupPlanAsync(string parent, BackupPlan backupPlan, string backupPlanId, CancellationToken cancellationToken)

Create a BackupPlan

Parameters
Name Description
parent string

Required. The BackupPlan project and location in the format projects/{project}/locations/{location}. In Google Cloud Backup and DR locations map to Google Cloud regions, for example us-central1.

backupPlan BackupPlan

Required. The BackupPlan resource object to create.

backupPlanId string

Required. The name of the BackupPlan to create. The name must be unique for the specified project and location.The name must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens. Pattern, /[a-z][a-z0-9-]{,62}/.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupPlanOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
BackupPlan backupPlan = new BackupPlan();
string backupPlanId = "";
// Make the request
Operation<BackupPlan, OperationMetadata> response = await backupDRClient.CreateBackupPlanAsync(parent, backupPlan, backupPlanId);

// Poll until the returned long-running operation is complete
Operation<BackupPlan, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlan result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlan, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupPlanAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlan retrievedResult = retrievedResponse.Result;
}

CreateBackupVault(LocationName, BackupVault, string, CallSettings)

public virtual Operation<BackupVault, OperationMetadata> CreateBackupVault(LocationName parent, BackupVault backupVault, string backupVaultId, CallSettings callSettings = null)

Creates a new BackupVault in a given project and location.

Parameters
Name Description
parent LocationName

Required. Value for parent.

backupVault BackupVault

Required. The resource being created

backupVaultId string

Required. ID of the requesting object If auto-generating ID server-side, remove this field and backup_vault_id from the method_signature of Create RPC

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupVaultOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
BackupVault backupVault = new BackupVault();
string backupVaultId = "";
// Make the request
Operation<BackupVault, OperationMetadata> response = backupDRClient.CreateBackupVault(parent, backupVault, backupVaultId);

// Poll until the returned long-running operation is complete
Operation<BackupVault, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupVault result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupVault, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateBackupVault(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupVault retrievedResult = retrievedResponse.Result;
}

CreateBackupVault(CreateBackupVaultRequest, CallSettings)

public virtual Operation<BackupVault, OperationMetadata> CreateBackupVault(CreateBackupVaultRequest request, CallSettings callSettings = null)

Creates a new BackupVault in a given project and location.

Parameters
Name Description
request CreateBackupVaultRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupVaultOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
CreateBackupVaultRequest request = new CreateBackupVaultRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    BackupVaultId = "",
    BackupVault = new BackupVault(),
    RequestId = "",
    ValidateOnly = false,
};
// Make the request
Operation<BackupVault, OperationMetadata> response = backupDRClient.CreateBackupVault(request);

// Poll until the returned long-running operation is complete
Operation<BackupVault, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupVault result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupVault, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateBackupVault(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupVault retrievedResult = retrievedResponse.Result;
}

CreateBackupVault(string, BackupVault, string, CallSettings)

public virtual Operation<BackupVault, OperationMetadata> CreateBackupVault(string parent, BackupVault backupVault, string backupVaultId, CallSettings callSettings = null)

Creates a new BackupVault in a given project and location.

Parameters
Name Description
parent string

Required. Value for parent.

backupVault BackupVault

Required. The resource being created

backupVaultId string

Required. ID of the requesting object If auto-generating ID server-side, remove this field and backup_vault_id from the method_signature of Create RPC

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupVaultOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
BackupVault backupVault = new BackupVault();
string backupVaultId = "";
// Make the request
Operation<BackupVault, OperationMetadata> response = backupDRClient.CreateBackupVault(parent, backupVault, backupVaultId);

// Poll until the returned long-running operation is complete
Operation<BackupVault, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupVault result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupVault, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateBackupVault(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupVault retrievedResult = retrievedResponse.Result;
}

CreateBackupVaultAsync(LocationName, BackupVault, string, CallSettings)

public virtual Task<Operation<BackupVault, OperationMetadata>> CreateBackupVaultAsync(LocationName parent, BackupVault backupVault, string backupVaultId, CallSettings callSettings = null)

Creates a new BackupVault in a given project and location.

Parameters
Name Description
parent LocationName

Required. Value for parent.

backupVault BackupVault

Required. The resource being created

backupVaultId string

Required. ID of the requesting object If auto-generating ID server-side, remove this field and backup_vault_id from the method_signature of Create RPC

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupVaultOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
BackupVault backupVault = new BackupVault();
string backupVaultId = "";
// Make the request
Operation<BackupVault, OperationMetadata> response = await backupDRClient.CreateBackupVaultAsync(parent, backupVault, backupVaultId);

// Poll until the returned long-running operation is complete
Operation<BackupVault, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupVault result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupVault, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupVaultAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupVault retrievedResult = retrievedResponse.Result;
}

CreateBackupVaultAsync(LocationName, BackupVault, string, CancellationToken)

public virtual Task<Operation<BackupVault, OperationMetadata>> CreateBackupVaultAsync(LocationName parent, BackupVault backupVault, string backupVaultId, CancellationToken cancellationToken)

Creates a new BackupVault in a given project and location.

Parameters
Name Description
parent LocationName

Required. Value for parent.

backupVault BackupVault

Required. The resource being created

backupVaultId string

Required. ID of the requesting object If auto-generating ID server-side, remove this field and backup_vault_id from the method_signature of Create RPC

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupVaultOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
BackupVault backupVault = new BackupVault();
string backupVaultId = "";
// Make the request
Operation<BackupVault, OperationMetadata> response = await backupDRClient.CreateBackupVaultAsync(parent, backupVault, backupVaultId);

// Poll until the returned long-running operation is complete
Operation<BackupVault, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupVault result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupVault, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupVaultAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupVault retrievedResult = retrievedResponse.Result;
}

CreateBackupVaultAsync(CreateBackupVaultRequest, CallSettings)

public virtual Task<Operation<BackupVault, OperationMetadata>> CreateBackupVaultAsync(CreateBackupVaultRequest request, CallSettings callSettings = null)

Creates a new BackupVault in a given project and location.

Parameters
Name Description
request CreateBackupVaultRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupVaultOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
CreateBackupVaultRequest request = new CreateBackupVaultRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    BackupVaultId = "",
    BackupVault = new BackupVault(),
    RequestId = "",
    ValidateOnly = false,
};
// Make the request
Operation<BackupVault, OperationMetadata> response = await backupDRClient.CreateBackupVaultAsync(request);

// Poll until the returned long-running operation is complete
Operation<BackupVault, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupVault result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupVault, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupVaultAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupVault retrievedResult = retrievedResponse.Result;
}

CreateBackupVaultAsync(CreateBackupVaultRequest, CancellationToken)

public virtual Task<Operation<BackupVault, OperationMetadata>> CreateBackupVaultAsync(CreateBackupVaultRequest request, CancellationToken cancellationToken)

Creates a new BackupVault in a given project and location.

Parameters
Name Description
request CreateBackupVaultRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupVaultOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
CreateBackupVaultRequest request = new CreateBackupVaultRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    BackupVaultId = "",
    BackupVault = new BackupVault(),
    RequestId = "",
    ValidateOnly = false,
};
// Make the request
Operation<BackupVault, OperationMetadata> response = await backupDRClient.CreateBackupVaultAsync(request);

// Poll until the returned long-running operation is complete
Operation<BackupVault, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupVault result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupVault, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupVaultAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupVault retrievedResult = retrievedResponse.Result;
}

CreateBackupVaultAsync(string, BackupVault, string, CallSettings)

public virtual Task<Operation<BackupVault, OperationMetadata>> CreateBackupVaultAsync(string parent, BackupVault backupVault, string backupVaultId, CallSettings callSettings = null)

Creates a new BackupVault in a given project and location.

Parameters
Name Description
parent string

Required. Value for parent.

backupVault BackupVault

Required. The resource being created

backupVaultId string

Required. ID of the requesting object If auto-generating ID server-side, remove this field and backup_vault_id from the method_signature of Create RPC

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupVaultOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
BackupVault backupVault = new BackupVault();
string backupVaultId = "";
// Make the request
Operation<BackupVault, OperationMetadata> response = await backupDRClient.CreateBackupVaultAsync(parent, backupVault, backupVaultId);

// Poll until the returned long-running operation is complete
Operation<BackupVault, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupVault result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupVault, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupVaultAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupVault retrievedResult = retrievedResponse.Result;
}

CreateBackupVaultAsync(string, BackupVault, string, CancellationToken)

public virtual Task<Operation<BackupVault, OperationMetadata>> CreateBackupVaultAsync(string parent, BackupVault backupVault, string backupVaultId, CancellationToken cancellationToken)

Creates a new BackupVault in a given project and location.

Parameters
Name Description
parent string

Required. Value for parent.

backupVault BackupVault

Required. The resource being created

backupVaultId string

Required. ID of the requesting object If auto-generating ID server-side, remove this field and backup_vault_id from the method_signature of Create RPC

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupVaultOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
BackupVault backupVault = new BackupVault();
string backupVaultId = "";
// Make the request
Operation<BackupVault, OperationMetadata> response = await backupDRClient.CreateBackupVaultAsync(parent, backupVault, backupVaultId);

// Poll until the returned long-running operation is complete
Operation<BackupVault, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupVault result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupVault, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateBackupVaultAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupVault retrievedResult = retrievedResponse.Result;
}

CreateManagementServer(LocationName, ManagementServer, string, CallSettings)

public virtual Operation<ManagementServer, OperationMetadata> CreateManagementServer(LocationName parent, ManagementServer managementServer, string managementServerId, CallSettings callSettings = null)

Creates a new ManagementServer in a given project and location.

Parameters
Name Description
parent LocationName

Required. The management server project and location in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR locations map to Google Cloud regions, for example us-central1.

managementServer ManagementServer

Required. A [management server resource][google.cloud.backupdr.v1.ManagementServer]

managementServerId string

Required. The name of the management server to create. The name must be unique for the specified project and location.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationManagementServerOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
ManagementServer managementServer = new ManagementServer();
string managementServerId = "";
// Make the request
Operation<ManagementServer, OperationMetadata> response = backupDRClient.CreateManagementServer(parent, managementServer, managementServerId);

// Poll until the returned long-running operation is complete
Operation<ManagementServer, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
ManagementServer result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<ManagementServer, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateManagementServer(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    ManagementServer retrievedResult = retrievedResponse.Result;
}

CreateManagementServer(CreateManagementServerRequest, CallSettings)

public virtual Operation<ManagementServer, OperationMetadata> CreateManagementServer(CreateManagementServerRequest request, CallSettings callSettings = null)

Creates a new ManagementServer in a given project and location.

Parameters
Name Description
request CreateManagementServerRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationManagementServerOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
CreateManagementServerRequest request = new CreateManagementServerRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    ManagementServerId = "",
    ManagementServer = new ManagementServer(),
    RequestId = "",
};
// Make the request
Operation<ManagementServer, OperationMetadata> response = backupDRClient.CreateManagementServer(request);

// Poll until the returned long-running operation is complete
Operation<ManagementServer, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
ManagementServer result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<ManagementServer, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateManagementServer(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    ManagementServer retrievedResult = retrievedResponse.Result;
}

CreateManagementServer(string, ManagementServer, string, CallSettings)

public virtual Operation<ManagementServer, OperationMetadata> CreateManagementServer(string parent, ManagementServer managementServer, string managementServerId, CallSettings callSettings = null)

Creates a new ManagementServer in a given project and location.

Parameters
Name Description
parent string

Required. The management server project and location in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR locations map to Google Cloud regions, for example us-central1.

managementServer ManagementServer

Required. A [management server resource][google.cloud.backupdr.v1.ManagementServer]

managementServerId string

Required. The name of the management server to create. The name must be unique for the specified project and location.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationManagementServerOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
ManagementServer managementServer = new ManagementServer();
string managementServerId = "";
// Make the request
Operation<ManagementServer, OperationMetadata> response = backupDRClient.CreateManagementServer(parent, managementServer, managementServerId);

// Poll until the returned long-running operation is complete
Operation<ManagementServer, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
ManagementServer result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<ManagementServer, OperationMetadata> retrievedResponse = backupDRClient.PollOnceCreateManagementServer(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    ManagementServer retrievedResult = retrievedResponse.Result;
}

CreateManagementServerAsync(LocationName, ManagementServer, string, CallSettings)

public virtual Task<Operation<ManagementServer, OperationMetadata>> CreateManagementServerAsync(LocationName parent, ManagementServer managementServer, string managementServerId, CallSettings callSettings = null)

Creates a new ManagementServer in a given project and location.

Parameters
Name Description
parent LocationName

Required. The management server project and location in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR locations map to Google Cloud regions, for example us-central1.

managementServer ManagementServer

Required. A [management server resource][google.cloud.backupdr.v1.ManagementServer]

managementServerId string

Required. The name of the management server to create. The name must be unique for the specified project and location.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationManagementServerOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
ManagementServer managementServer = new ManagementServer();
string managementServerId = "";
// Make the request
Operation<ManagementServer, OperationMetadata> response = await backupDRClient.CreateManagementServerAsync(parent, managementServer, managementServerId);

// Poll until the returned long-running operation is complete
Operation<ManagementServer, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
ManagementServer result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<ManagementServer, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateManagementServerAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    ManagementServer retrievedResult = retrievedResponse.Result;
}

CreateManagementServerAsync(LocationName, ManagementServer, string, CancellationToken)

public virtual Task<Operation<ManagementServer, OperationMetadata>> CreateManagementServerAsync(LocationName parent, ManagementServer managementServer, string managementServerId, CancellationToken cancellationToken)

Creates a new ManagementServer in a given project and location.

Parameters
Name Description
parent LocationName

Required. The management server project and location in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR locations map to Google Cloud regions, for example us-central1.

managementServer ManagementServer

Required. A [management server resource][google.cloud.backupdr.v1.ManagementServer]

managementServerId string

Required. The name of the management server to create. The name must be unique for the specified project and location.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationManagementServerOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
ManagementServer managementServer = new ManagementServer();
string managementServerId = "";
// Make the request
Operation<ManagementServer, OperationMetadata> response = await backupDRClient.CreateManagementServerAsync(parent, managementServer, managementServerId);

// Poll until the returned long-running operation is complete
Operation<ManagementServer, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
ManagementServer result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<ManagementServer, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateManagementServerAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    ManagementServer retrievedResult = retrievedResponse.Result;
}

CreateManagementServerAsync(CreateManagementServerRequest, CallSettings)

public virtual Task<Operation<ManagementServer, OperationMetadata>> CreateManagementServerAsync(CreateManagementServerRequest request, CallSettings callSettings = null)

Creates a new ManagementServer in a given project and location.

Parameters
Name Description
request CreateManagementServerRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationManagementServerOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
CreateManagementServerRequest request = new CreateManagementServerRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    ManagementServerId = "",
    ManagementServer = new ManagementServer(),
    RequestId = "",
};
// Make the request
Operation<ManagementServer, OperationMetadata> response = await backupDRClient.CreateManagementServerAsync(request);

// Poll until the returned long-running operation is complete
Operation<ManagementServer, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
ManagementServer result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<ManagementServer, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateManagementServerAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    ManagementServer retrievedResult = retrievedResponse.Result;
}

CreateManagementServerAsync(CreateManagementServerRequest, CancellationToken)

public virtual Task<Operation<ManagementServer, OperationMetadata>> CreateManagementServerAsync(CreateManagementServerRequest request, CancellationToken cancellationToken)

Creates a new ManagementServer in a given project and location.

Parameters
Name Description
request CreateManagementServerRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationManagementServerOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
CreateManagementServerRequest request = new CreateManagementServerRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    ManagementServerId = "",
    ManagementServer = new ManagementServer(),
    RequestId = "",
};
// Make the request
Operation<ManagementServer, OperationMetadata> response = await backupDRClient.CreateManagementServerAsync(request);

// Poll until the returned long-running operation is complete
Operation<ManagementServer, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
ManagementServer result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<ManagementServer, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateManagementServerAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    ManagementServer retrievedResult = retrievedResponse.Result;
}

CreateManagementServerAsync(string, ManagementServer, string, CallSettings)

public virtual Task<Operation<ManagementServer, OperationMetadata>> CreateManagementServerAsync(string parent, ManagementServer managementServer, string managementServerId, CallSettings callSettings = null)

Creates a new ManagementServer in a given project and location.

Parameters
Name Description
parent string

Required. The management server project and location in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR locations map to Google Cloud regions, for example us-central1.

managementServer ManagementServer

Required. A [management server resource][google.cloud.backupdr.v1.ManagementServer]

managementServerId string

Required. The name of the management server to create. The name must be unique for the specified project and location.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationManagementServerOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
ManagementServer managementServer = new ManagementServer();
string managementServerId = "";
// Make the request
Operation<ManagementServer, OperationMetadata> response = await backupDRClient.CreateManagementServerAsync(parent, managementServer, managementServerId);

// Poll until the returned long-running operation is complete
Operation<ManagementServer, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
ManagementServer result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<ManagementServer, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateManagementServerAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    ManagementServer retrievedResult = retrievedResponse.Result;
}

CreateManagementServerAsync(string, ManagementServer, string, CancellationToken)

public virtual Task<Operation<ManagementServer, OperationMetadata>> CreateManagementServerAsync(string parent, ManagementServer managementServer, string managementServerId, CancellationToken cancellationToken)

Creates a new ManagementServer in a given project and location.

Parameters
Name Description
parent string

Required. The management server project and location in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR locations map to Google Cloud regions, for example us-central1.

managementServer ManagementServer

Required. A [management server resource][google.cloud.backupdr.v1.ManagementServer]

managementServerId string

Required. The name of the management server to create. The name must be unique for the specified project and location.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationManagementServerOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
ManagementServer managementServer = new ManagementServer();
string managementServerId = "";
// Make the request
Operation<ManagementServer, OperationMetadata> response = await backupDRClient.CreateManagementServerAsync(parent, managementServer, managementServerId);

// Poll until the returned long-running operation is complete
Operation<ManagementServer, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
ManagementServer result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<ManagementServer, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceCreateManagementServerAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    ManagementServer retrievedResult = retrievedResponse.Result;
}

DeleteAutoProtectionPolicy(AutoProtectionPolicyName, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteAutoProtectionPolicy(AutoProtectionPolicyName name, CallSettings callSettings = null)

Deletes a single AutoProtectionPolicy.

Parameters
Name Description
name AutoProtectionPolicyName

Required. The name of the policy to delete. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
AutoProtectionPolicyName name = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]");
// Make the request
Operation<Empty, OperationMetadata> response = backupDRClient.DeleteAutoProtectionPolicy(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteAutoProtectionPolicy(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteAutoProtectionPolicy(DeleteAutoProtectionPolicyRequest, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteAutoProtectionPolicy(DeleteAutoProtectionPolicyRequest request, CallSettings callSettings = null)

Deletes a single AutoProtectionPolicy.

Parameters
Name Description
request DeleteAutoProtectionPolicyRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
DeleteAutoProtectionPolicyRequest request = new DeleteAutoProtectionPolicyRequest
{
    AutoProtectionPolicyName = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]"),
    Etag = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = backupDRClient.DeleteAutoProtectionPolicy(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteAutoProtectionPolicy(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteAutoProtectionPolicy(string, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteAutoProtectionPolicy(string name, CallSettings callSettings = null)

Deletes a single AutoProtectionPolicy.

Parameters
Name Description
name string

Required. The name of the policy to delete. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]";
// Make the request
Operation<Empty, OperationMetadata> response = backupDRClient.DeleteAutoProtectionPolicy(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteAutoProtectionPolicy(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteAutoProtectionPolicyAsync(AutoProtectionPolicyName, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteAutoProtectionPolicyAsync(AutoProtectionPolicyName name, CallSettings callSettings = null)

Deletes a single AutoProtectionPolicy.

Parameters
Name Description
name AutoProtectionPolicyName

Required. The name of the policy to delete. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
AutoProtectionPolicyName name = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]");
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteAutoProtectionPolicyAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteAutoProtectionPolicyAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteAutoProtectionPolicyAsync(AutoProtectionPolicyName, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteAutoProtectionPolicyAsync(AutoProtectionPolicyName name, CancellationToken cancellationToken)

Deletes a single AutoProtectionPolicy.

Parameters
Name Description
name AutoProtectionPolicyName

Required. The name of the policy to delete. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
AutoProtectionPolicyName name = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]");
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteAutoProtectionPolicyAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteAutoProtectionPolicyAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteAutoProtectionPolicyAsync(DeleteAutoProtectionPolicyRequest, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteAutoProtectionPolicyAsync(DeleteAutoProtectionPolicyRequest request, CallSettings callSettings = null)

Deletes a single AutoProtectionPolicy.

Parameters
Name Description
request DeleteAutoProtectionPolicyRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DeleteAutoProtectionPolicyRequest request = new DeleteAutoProtectionPolicyRequest
{
    AutoProtectionPolicyName = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]"),
    Etag = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteAutoProtectionPolicyAsync(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteAutoProtectionPolicyAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteAutoProtectionPolicyAsync(DeleteAutoProtectionPolicyRequest, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteAutoProtectionPolicyAsync(DeleteAutoProtectionPolicyRequest request, CancellationToken cancellationToken)

Deletes a single AutoProtectionPolicy.

Parameters
Name Description
request DeleteAutoProtectionPolicyRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DeleteAutoProtectionPolicyRequest request = new DeleteAutoProtectionPolicyRequest
{
    AutoProtectionPolicyName = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]"),
    Etag = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteAutoProtectionPolicyAsync(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteAutoProtectionPolicyAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteAutoProtectionPolicyAsync(string, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteAutoProtectionPolicyAsync(string name, CallSettings callSettings = null)

Deletes a single AutoProtectionPolicy.

Parameters
Name Description
name string

Required. The name of the policy to delete. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]";
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteAutoProtectionPolicyAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteAutoProtectionPolicyAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteAutoProtectionPolicyAsync(string, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteAutoProtectionPolicyAsync(string name, CancellationToken cancellationToken)

Deletes a single AutoProtectionPolicy.

Parameters
Name Description
name string

Required. The name of the policy to delete. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]";
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteAutoProtectionPolicyAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteAutoProtectionPolicyAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackup(BackupName, CallSettings)

public virtual Operation<Backup, OperationMetadata> DeleteBackup(BackupName name, CallSettings callSettings = null)

Deletes a Backup.

Parameters
Name Description
name BackupName

Required. Name of the resource.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BackupName name = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]");
// Make the request
Operation<Backup, OperationMetadata> response = backupDRClient.DeleteBackup(name);

// Poll until the returned long-running operation is complete
Operation<Backup, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Backup result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Backup, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteBackup(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Backup retrievedResult = retrievedResponse.Result;
}

DeleteBackup(DeleteBackupRequest, CallSettings)

public virtual Operation<Backup, OperationMetadata> DeleteBackup(DeleteBackupRequest request, CallSettings callSettings = null)

Deletes a Backup.

Parameters
Name Description
request DeleteBackupRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
DeleteBackupRequest request = new DeleteBackupRequest
{
    BackupName = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]"),
    RequestId = "",
};
// Make the request
Operation<Backup, OperationMetadata> response = backupDRClient.DeleteBackup(request);

// Poll until the returned long-running operation is complete
Operation<Backup, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Backup result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Backup, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteBackup(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Backup retrievedResult = retrievedResponse.Result;
}

DeleteBackup(string, CallSettings)

public virtual Operation<Backup, OperationMetadata> DeleteBackup(string name, CallSettings callSettings = null)

Deletes a Backup.

Parameters
Name Description
name string

Required. Name of the resource.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]/dataSources/[DATASOURCE]/backups/[BACKUP]";
// Make the request
Operation<Backup, OperationMetadata> response = backupDRClient.DeleteBackup(name);

// Poll until the returned long-running operation is complete
Operation<Backup, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Backup result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Backup, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteBackup(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Backup retrievedResult = retrievedResponse.Result;
}

DeleteBackupAsync(BackupName, CallSettings)

public virtual Task<Operation<Backup, OperationMetadata>> DeleteBackupAsync(BackupName name, CallSettings callSettings = null)

Deletes a Backup.

Parameters
Name Description
name BackupName

Required. Name of the resource.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupName name = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]");
// Make the request
Operation<Backup, OperationMetadata> response = await backupDRClient.DeleteBackupAsync(name);

// Poll until the returned long-running operation is complete
Operation<Backup, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Backup result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Backup, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Backup retrievedResult = retrievedResponse.Result;
}

DeleteBackupAsync(BackupName, CancellationToken)

public virtual Task<Operation<Backup, OperationMetadata>> DeleteBackupAsync(BackupName name, CancellationToken cancellationToken)

Deletes a Backup.

Parameters
Name Description
name BackupName

Required. Name of the resource.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupName name = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]");
// Make the request
Operation<Backup, OperationMetadata> response = await backupDRClient.DeleteBackupAsync(name);

// Poll until the returned long-running operation is complete
Operation<Backup, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Backup result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Backup, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Backup retrievedResult = retrievedResponse.Result;
}

DeleteBackupAsync(DeleteBackupRequest, CallSettings)

public virtual Task<Operation<Backup, OperationMetadata>> DeleteBackupAsync(DeleteBackupRequest request, CallSettings callSettings = null)

Deletes a Backup.

Parameters
Name Description
request DeleteBackupRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DeleteBackupRequest request = new DeleteBackupRequest
{
    BackupName = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]"),
    RequestId = "",
};
// Make the request
Operation<Backup, OperationMetadata> response = await backupDRClient.DeleteBackupAsync(request);

// Poll until the returned long-running operation is complete
Operation<Backup, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Backup result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Backup, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Backup retrievedResult = retrievedResponse.Result;
}

DeleteBackupAsync(DeleteBackupRequest, CancellationToken)

public virtual Task<Operation<Backup, OperationMetadata>> DeleteBackupAsync(DeleteBackupRequest request, CancellationToken cancellationToken)

Deletes a Backup.

Parameters
Name Description
request DeleteBackupRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DeleteBackupRequest request = new DeleteBackupRequest
{
    BackupName = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]"),
    RequestId = "",
};
// Make the request
Operation<Backup, OperationMetadata> response = await backupDRClient.DeleteBackupAsync(request);

// Poll until the returned long-running operation is complete
Operation<Backup, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Backup result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Backup, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Backup retrievedResult = retrievedResponse.Result;
}

DeleteBackupAsync(string, CallSettings)

public virtual Task<Operation<Backup, OperationMetadata>> DeleteBackupAsync(string name, CallSettings callSettings = null)

Deletes a Backup.

Parameters
Name Description
name string

Required. Name of the resource.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]/dataSources/[DATASOURCE]/backups/[BACKUP]";
// Make the request
Operation<Backup, OperationMetadata> response = await backupDRClient.DeleteBackupAsync(name);

// Poll until the returned long-running operation is complete
Operation<Backup, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Backup result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Backup, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Backup retrievedResult = retrievedResponse.Result;
}

DeleteBackupAsync(string, CancellationToken)

public virtual Task<Operation<Backup, OperationMetadata>> DeleteBackupAsync(string name, CancellationToken cancellationToken)

Deletes a Backup.

Parameters
Name Description
name string

Required. Name of the resource.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]/dataSources/[DATASOURCE]/backups/[BACKUP]";
// Make the request
Operation<Backup, OperationMetadata> response = await backupDRClient.DeleteBackupAsync(name);

// Poll until the returned long-running operation is complete
Operation<Backup, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Backup result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Backup, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Backup retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlan(BackupPlanName, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteBackupPlan(BackupPlanName name, CallSettings callSettings = null)

Deletes a single BackupPlan.

Parameters
Name Description
name BackupPlanName

Required. The resource name of the BackupPlan to delete.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BackupPlanName name = BackupPlanName.FromProjectLocationBackupPlan("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]");
// Make the request
Operation<Empty, OperationMetadata> response = backupDRClient.DeleteBackupPlan(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteBackupPlan(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlan(DeleteBackupPlanRequest, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteBackupPlan(DeleteBackupPlanRequest request, CallSettings callSettings = null)

Deletes a single BackupPlan.

Parameters
Name Description
request DeleteBackupPlanRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
DeleteBackupPlanRequest request = new DeleteBackupPlanRequest
{
    BackupPlanName = BackupPlanName.FromProjectLocationBackupPlan("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]"),
    RequestId = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = backupDRClient.DeleteBackupPlan(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteBackupPlan(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlan(string, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteBackupPlan(string name, CallSettings callSettings = null)

Deletes a single BackupPlan.

Parameters
Name Description
name string

Required. The resource name of the BackupPlan to delete.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlans/[BACKUP_PLAN]";
// Make the request
Operation<Empty, OperationMetadata> response = backupDRClient.DeleteBackupPlan(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteBackupPlan(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlanAssociation(BackupPlanAssociationName, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteBackupPlanAssociation(BackupPlanAssociationName name, CallSettings callSettings = null)

Deletes a single BackupPlanAssociation.

Parameters
Name Description
name BackupPlanAssociationName

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BackupPlanAssociationName name = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]");
// Make the request
Operation<Empty, OperationMetadata> response = backupDRClient.DeleteBackupPlanAssociation(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteBackupPlanAssociation(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlanAssociation(DeleteBackupPlanAssociationRequest, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteBackupPlanAssociation(DeleteBackupPlanAssociationRequest request, CallSettings callSettings = null)

Deletes a single BackupPlanAssociation.

Parameters
Name Description
request DeleteBackupPlanAssociationRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
DeleteBackupPlanAssociationRequest request = new DeleteBackupPlanAssociationRequest
{
    BackupPlanAssociationName = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]"),
    RequestId = "",
    AutoProtectionPolicyBindingAsAutoProtectionPolicyBindingName = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]"),
};
// Make the request
Operation<Empty, OperationMetadata> response = backupDRClient.DeleteBackupPlanAssociation(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteBackupPlanAssociation(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlanAssociation(string, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteBackupPlanAssociation(string name, CallSettings callSettings = null)

Deletes a single BackupPlanAssociation.

Parameters
Name Description
name string

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlanAssociations/[BACKUP_PLAN_ASSOCIATION]";
// Make the request
Operation<Empty, OperationMetadata> response = backupDRClient.DeleteBackupPlanAssociation(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteBackupPlanAssociation(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlanAssociationAsync(BackupPlanAssociationName, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupPlanAssociationAsync(BackupPlanAssociationName name, CallSettings callSettings = null)

Deletes a single BackupPlanAssociation.

Parameters
Name Description
name BackupPlanAssociationName

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlanAssociationName name = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]");
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupPlanAssociationAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupPlanAssociationAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlanAssociationAsync(BackupPlanAssociationName, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupPlanAssociationAsync(BackupPlanAssociationName name, CancellationToken cancellationToken)

Deletes a single BackupPlanAssociation.

Parameters
Name Description
name BackupPlanAssociationName

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlanAssociationName name = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]");
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupPlanAssociationAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupPlanAssociationAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlanAssociationAsync(DeleteBackupPlanAssociationRequest, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupPlanAssociationAsync(DeleteBackupPlanAssociationRequest request, CallSettings callSettings = null)

Deletes a single BackupPlanAssociation.

Parameters
Name Description
request DeleteBackupPlanAssociationRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DeleteBackupPlanAssociationRequest request = new DeleteBackupPlanAssociationRequest
{
    BackupPlanAssociationName = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]"),
    RequestId = "",
    AutoProtectionPolicyBindingAsAutoProtectionPolicyBindingName = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]"),
};
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupPlanAssociationAsync(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupPlanAssociationAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlanAssociationAsync(DeleteBackupPlanAssociationRequest, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupPlanAssociationAsync(DeleteBackupPlanAssociationRequest request, CancellationToken cancellationToken)

Deletes a single BackupPlanAssociation.

Parameters
Name Description
request DeleteBackupPlanAssociationRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DeleteBackupPlanAssociationRequest request = new DeleteBackupPlanAssociationRequest
{
    BackupPlanAssociationName = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]"),
    RequestId = "",
    AutoProtectionPolicyBindingAsAutoProtectionPolicyBindingName = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]"),
};
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupPlanAssociationAsync(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupPlanAssociationAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlanAssociationAsync(string, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupPlanAssociationAsync(string name, CallSettings callSettings = null)

Deletes a single BackupPlanAssociation.

Parameters
Name Description
name string

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlanAssociations/[BACKUP_PLAN_ASSOCIATION]";
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupPlanAssociationAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupPlanAssociationAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlanAssociationAsync(string, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupPlanAssociationAsync(string name, CancellationToken cancellationToken)

Deletes a single BackupPlanAssociation.

Parameters
Name Description
name string

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlanAssociations/[BACKUP_PLAN_ASSOCIATION]";
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupPlanAssociationAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupPlanAssociationAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlanAsync(BackupPlanName, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupPlanAsync(BackupPlanName name, CallSettings callSettings = null)

Deletes a single BackupPlan.

Parameters
Name Description
name BackupPlanName

Required. The resource name of the BackupPlan to delete.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlanName name = BackupPlanName.FromProjectLocationBackupPlan("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]");
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupPlanAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupPlanAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlanAsync(BackupPlanName, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupPlanAsync(BackupPlanName name, CancellationToken cancellationToken)

Deletes a single BackupPlan.

Parameters
Name Description
name BackupPlanName

Required. The resource name of the BackupPlan to delete.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlanName name = BackupPlanName.FromProjectLocationBackupPlan("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]");
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupPlanAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupPlanAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlanAsync(DeleteBackupPlanRequest, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupPlanAsync(DeleteBackupPlanRequest request, CallSettings callSettings = null)

Deletes a single BackupPlan.

Parameters
Name Description
request DeleteBackupPlanRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DeleteBackupPlanRequest request = new DeleteBackupPlanRequest
{
    BackupPlanName = BackupPlanName.FromProjectLocationBackupPlan("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]"),
    RequestId = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupPlanAsync(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupPlanAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlanAsync(DeleteBackupPlanRequest, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupPlanAsync(DeleteBackupPlanRequest request, CancellationToken cancellationToken)

Deletes a single BackupPlan.

Parameters
Name Description
request DeleteBackupPlanRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DeleteBackupPlanRequest request = new DeleteBackupPlanRequest
{
    BackupPlanName = BackupPlanName.FromProjectLocationBackupPlan("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]"),
    RequestId = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupPlanAsync(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupPlanAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlanAsync(string, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupPlanAsync(string name, CallSettings callSettings = null)

Deletes a single BackupPlan.

Parameters
Name Description
name string

Required. The resource name of the BackupPlan to delete.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlans/[BACKUP_PLAN]";
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupPlanAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupPlanAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupPlanAsync(string, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupPlanAsync(string name, CancellationToken cancellationToken)

Deletes a single BackupPlan.

Parameters
Name Description
name string

Required. The resource name of the BackupPlan to delete.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlans/[BACKUP_PLAN]";
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupPlanAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupPlanAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupVault(BackupVaultName, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteBackupVault(BackupVaultName name, CallSettings callSettings = null)

Deletes a BackupVault.

Parameters
Name Description
name BackupVaultName

Required. Name of the resource.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BackupVaultName name = BackupVaultName.FromProjectLocationBackupvault("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]");
// Make the request
Operation<Empty, OperationMetadata> response = backupDRClient.DeleteBackupVault(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteBackupVault(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupVault(DeleteBackupVaultRequest, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteBackupVault(DeleteBackupVaultRequest request, CallSettings callSettings = null)

Deletes a BackupVault.

Parameters
Name Description
request DeleteBackupVaultRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
DeleteBackupVaultRequest request = new DeleteBackupVaultRequest
{
    BackupVaultName = BackupVaultName.FromProjectLocationBackupvault("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]"),
    RequestId = "",
    Force = false,
    Etag = "",
    ValidateOnly = false,
    AllowMissing = false,
    IgnoreBackupPlanReferences = false,
};
// Make the request
Operation<Empty, OperationMetadata> response = backupDRClient.DeleteBackupVault(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteBackupVault(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupVault(string, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteBackupVault(string name, CallSettings callSettings = null)

Deletes a BackupVault.

Parameters
Name Description
name string

Required. Name of the resource.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]";
// Make the request
Operation<Empty, OperationMetadata> response = backupDRClient.DeleteBackupVault(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteBackupVault(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupVaultAsync(BackupVaultName, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupVaultAsync(BackupVaultName name, CallSettings callSettings = null)

Deletes a BackupVault.

Parameters
Name Description
name BackupVaultName

Required. Name of the resource.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupVaultName name = BackupVaultName.FromProjectLocationBackupvault("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]");
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupVaultAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupVaultAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupVaultAsync(BackupVaultName, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupVaultAsync(BackupVaultName name, CancellationToken cancellationToken)

Deletes a BackupVault.

Parameters
Name Description
name BackupVaultName

Required. Name of the resource.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupVaultName name = BackupVaultName.FromProjectLocationBackupvault("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]");
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupVaultAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupVaultAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupVaultAsync(DeleteBackupVaultRequest, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupVaultAsync(DeleteBackupVaultRequest request, CallSettings callSettings = null)

Deletes a BackupVault.

Parameters
Name Description
request DeleteBackupVaultRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DeleteBackupVaultRequest request = new DeleteBackupVaultRequest
{
    BackupVaultName = BackupVaultName.FromProjectLocationBackupvault("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]"),
    RequestId = "",
    Force = false,
    Etag = "",
    ValidateOnly = false,
    AllowMissing = false,
    IgnoreBackupPlanReferences = false,
};
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupVaultAsync(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupVaultAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupVaultAsync(DeleteBackupVaultRequest, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupVaultAsync(DeleteBackupVaultRequest request, CancellationToken cancellationToken)

Deletes a BackupVault.

Parameters
Name Description
request DeleteBackupVaultRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DeleteBackupVaultRequest request = new DeleteBackupVaultRequest
{
    BackupVaultName = BackupVaultName.FromProjectLocationBackupvault("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]"),
    RequestId = "",
    Force = false,
    Etag = "",
    ValidateOnly = false,
    AllowMissing = false,
    IgnoreBackupPlanReferences = false,
};
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupVaultAsync(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupVaultAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupVaultAsync(string, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupVaultAsync(string name, CallSettings callSettings = null)

Deletes a BackupVault.

Parameters
Name Description
name string

Required. Name of the resource.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]";
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupVaultAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupVaultAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteBackupVaultAsync(string, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteBackupVaultAsync(string name, CancellationToken cancellationToken)

Deletes a BackupVault.

Parameters
Name Description
name string

Required. Name of the resource.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]";
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteBackupVaultAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteBackupVaultAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteManagementServer(DeleteManagementServerRequest, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteManagementServer(DeleteManagementServerRequest request, CallSettings callSettings = null)

Deletes a single ManagementServer.

Parameters
Name Description
request DeleteManagementServerRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
DeleteManagementServerRequest request = new DeleteManagementServerRequest
{
    ManagementServerName = ManagementServerName.FromProjectLocationManagementserver("[PROJECT]", "[LOCATION]", "[MANAGEMENTSERVER]"),
    RequestId = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = backupDRClient.DeleteManagementServer(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteManagementServer(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteManagementServer(ManagementServerName, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteManagementServer(ManagementServerName name, CallSettings callSettings = null)

Deletes a single ManagementServer.

Parameters
Name Description
name ManagementServerName

Required. Name of the resource

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
ManagementServerName name = ManagementServerName.FromProjectLocationManagementserver("[PROJECT]", "[LOCATION]", "[MANAGEMENTSERVER]");
// Make the request
Operation<Empty, OperationMetadata> response = backupDRClient.DeleteManagementServer(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteManagementServer(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteManagementServer(string, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteManagementServer(string name, CallSettings callSettings = null)

Deletes a single ManagementServer.

Parameters
Name Description
name string

Required. Name of the resource

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/managementServers/[MANAGEMENTSERVER]";
// Make the request
Operation<Empty, OperationMetadata> response = backupDRClient.DeleteManagementServer(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = backupDRClient.PollOnceDeleteManagementServer(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteManagementServerAsync(DeleteManagementServerRequest, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteManagementServerAsync(DeleteManagementServerRequest request, CallSettings callSettings = null)

Deletes a single ManagementServer.

Parameters
Name Description
request DeleteManagementServerRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DeleteManagementServerRequest request = new DeleteManagementServerRequest
{
    ManagementServerName = ManagementServerName.FromProjectLocationManagementserver("[PROJECT]", "[LOCATION]", "[MANAGEMENTSERVER]"),
    RequestId = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteManagementServerAsync(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteManagementServerAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteManagementServerAsync(DeleteManagementServerRequest, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteManagementServerAsync(DeleteManagementServerRequest request, CancellationToken cancellationToken)

Deletes a single ManagementServer.

Parameters
Name Description
request DeleteManagementServerRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DeleteManagementServerRequest request = new DeleteManagementServerRequest
{
    ManagementServerName = ManagementServerName.FromProjectLocationManagementserver("[PROJECT]", "[LOCATION]", "[MANAGEMENTSERVER]"),
    RequestId = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteManagementServerAsync(request);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteManagementServerAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteManagementServerAsync(ManagementServerName, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteManagementServerAsync(ManagementServerName name, CallSettings callSettings = null)

Deletes a single ManagementServer.

Parameters
Name Description
name ManagementServerName

Required. Name of the resource

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
ManagementServerName name = ManagementServerName.FromProjectLocationManagementserver("[PROJECT]", "[LOCATION]", "[MANAGEMENTSERVER]");
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteManagementServerAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteManagementServerAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteManagementServerAsync(ManagementServerName, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteManagementServerAsync(ManagementServerName name, CancellationToken cancellationToken)

Deletes a single ManagementServer.

Parameters
Name Description
name ManagementServerName

Required. Name of the resource

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
ManagementServerName name = ManagementServerName.FromProjectLocationManagementserver("[PROJECT]", "[LOCATION]", "[MANAGEMENTSERVER]");
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteManagementServerAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteManagementServerAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteManagementServerAsync(string, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteManagementServerAsync(string name, CallSettings callSettings = null)

Deletes a single ManagementServer.

Parameters
Name Description
name string

Required. Name of the resource

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/managementServers/[MANAGEMENTSERVER]";
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteManagementServerAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteManagementServerAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

DeleteManagementServerAsync(string, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteManagementServerAsync(string name, CancellationToken cancellationToken)

Deletes a single ManagementServer.

Parameters
Name Description
name string

Required. Name of the resource

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/managementServers/[MANAGEMENTSERVER]";
// Make the request
Operation<Empty, OperationMetadata> response = await backupDRClient.DeleteManagementServerAsync(name);

// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceDeleteManagementServerAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Empty retrievedResult = retrievedResponse.Result;
}

FetchBackupPlanAssociationsForResourceType(LocationName, string, string, int?, CallSettings)

public virtual PagedEnumerable<FetchBackupPlanAssociationsForResourceTypeResponse, BackupPlanAssociation> FetchBackupPlanAssociationsForResourceType(LocationName parent, string resourceType, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

List BackupPlanAssociations for a given resource type.

Parameters
Name Description
parent LocationName

Required. The parent resource name. Format: projects/{project}/locations/{location}

resourceType string

Required. The type of the Google Cloud resource. Ex: sql.googleapis.com/Instance

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableFetchBackupPlanAssociationsForResourceTypeResponseBackupPlanAssociation

A pageable sequence of BackupPlanAssociation resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
string resourceType = "";
// Make the request
PagedEnumerable<FetchBackupPlanAssociationsForResourceTypeResponse, BackupPlanAssociation> response = backupDRClient.FetchBackupPlanAssociationsForResourceType(parent, resourceType);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupPlanAssociation item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (FetchBackupPlanAssociationsForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanAssociation item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanAssociation> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanAssociation item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchBackupPlanAssociationsForResourceType(FetchBackupPlanAssociationsForResourceTypeRequest, CallSettings)

public virtual PagedEnumerable<FetchBackupPlanAssociationsForResourceTypeResponse, BackupPlanAssociation> FetchBackupPlanAssociationsForResourceType(FetchBackupPlanAssociationsForResourceTypeRequest request, CallSettings callSettings = null)

List BackupPlanAssociations for a given resource type.

Parameters
Name Description
request FetchBackupPlanAssociationsForResourceTypeRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableFetchBackupPlanAssociationsForResourceTypeResponseBackupPlanAssociation

A pageable sequence of BackupPlanAssociation resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
FetchBackupPlanAssociationsForResourceTypeRequest request = new FetchBackupPlanAssociationsForResourceTypeRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    ResourceType = "",
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedEnumerable<FetchBackupPlanAssociationsForResourceTypeResponse, BackupPlanAssociation> response = backupDRClient.FetchBackupPlanAssociationsForResourceType(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupPlanAssociation item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (FetchBackupPlanAssociationsForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanAssociation item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanAssociation> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanAssociation item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchBackupPlanAssociationsForResourceType(string, string, string, int?, CallSettings)

public virtual PagedEnumerable<FetchBackupPlanAssociationsForResourceTypeResponse, BackupPlanAssociation> FetchBackupPlanAssociationsForResourceType(string parent, string resourceType, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

List BackupPlanAssociations for a given resource type.

Parameters
Name Description
parent string

Required. The parent resource name. Format: projects/{project}/locations/{location}

resourceType string

Required. The type of the Google Cloud resource. Ex: sql.googleapis.com/Instance

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableFetchBackupPlanAssociationsForResourceTypeResponseBackupPlanAssociation

A pageable sequence of BackupPlanAssociation resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
string resourceType = "";
// Make the request
PagedEnumerable<FetchBackupPlanAssociationsForResourceTypeResponse, BackupPlanAssociation> response = backupDRClient.FetchBackupPlanAssociationsForResourceType(parent, resourceType);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupPlanAssociation item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (FetchBackupPlanAssociationsForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanAssociation item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanAssociation> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanAssociation item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchBackupPlanAssociationsForResourceTypeAsync(LocationName, string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<FetchBackupPlanAssociationsForResourceTypeResponse, BackupPlanAssociation> FetchBackupPlanAssociationsForResourceTypeAsync(LocationName parent, string resourceType, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

List BackupPlanAssociations for a given resource type.

Parameters
Name Description
parent LocationName

Required. The parent resource name. Format: projects/{project}/locations/{location}

resourceType string

Required. The type of the Google Cloud resource. Ex: sql.googleapis.com/Instance

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableFetchBackupPlanAssociationsForResourceTypeResponseBackupPlanAssociation

A pageable asynchronous sequence of BackupPlanAssociation resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
string resourceType = "";
// Make the request
PagedAsyncEnumerable<FetchBackupPlanAssociationsForResourceTypeResponse, BackupPlanAssociation> response = backupDRClient.FetchBackupPlanAssociationsForResourceTypeAsync(parent, resourceType);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupPlanAssociation item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (FetchBackupPlanAssociationsForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanAssociation item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanAssociation> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanAssociation item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchBackupPlanAssociationsForResourceTypeAsync(FetchBackupPlanAssociationsForResourceTypeRequest, CallSettings)

public virtual PagedAsyncEnumerable<FetchBackupPlanAssociationsForResourceTypeResponse, BackupPlanAssociation> FetchBackupPlanAssociationsForResourceTypeAsync(FetchBackupPlanAssociationsForResourceTypeRequest request, CallSettings callSettings = null)

List BackupPlanAssociations for a given resource type.

Parameters
Name Description
request FetchBackupPlanAssociationsForResourceTypeRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableFetchBackupPlanAssociationsForResourceTypeResponseBackupPlanAssociation

A pageable asynchronous sequence of BackupPlanAssociation resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
FetchBackupPlanAssociationsForResourceTypeRequest request = new FetchBackupPlanAssociationsForResourceTypeRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    ResourceType = "",
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedAsyncEnumerable<FetchBackupPlanAssociationsForResourceTypeResponse, BackupPlanAssociation> response = backupDRClient.FetchBackupPlanAssociationsForResourceTypeAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupPlanAssociation item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (FetchBackupPlanAssociationsForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanAssociation item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanAssociation> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanAssociation item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchBackupPlanAssociationsForResourceTypeAsync(string, string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<FetchBackupPlanAssociationsForResourceTypeResponse, BackupPlanAssociation> FetchBackupPlanAssociationsForResourceTypeAsync(string parent, string resourceType, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

List BackupPlanAssociations for a given resource type.

Parameters
Name Description
parent string

Required. The parent resource name. Format: projects/{project}/locations/{location}

resourceType string

Required. The type of the Google Cloud resource. Ex: sql.googleapis.com/Instance

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableFetchBackupPlanAssociationsForResourceTypeResponseBackupPlanAssociation

A pageable asynchronous sequence of BackupPlanAssociation resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
string resourceType = "";
// Make the request
PagedAsyncEnumerable<FetchBackupPlanAssociationsForResourceTypeResponse, BackupPlanAssociation> response = backupDRClient.FetchBackupPlanAssociationsForResourceTypeAsync(parent, resourceType);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupPlanAssociation item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (FetchBackupPlanAssociationsForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanAssociation item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanAssociation> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanAssociation item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchBackupsForResourceType(DataSourceName, string, string, int?, CallSettings)

public virtual PagedEnumerable<FetchBackupsForResourceTypeResponse, Backup> FetchBackupsForResourceType(DataSourceName parent, string resourceType, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Fetch Backups for a given resource type.

Parameters
Name Description
parent DataSourceName

Required. Datasources are the parent resource for the backups. Format: projects/{project}/locations/{location}/backupVaults/{backupVaultId}/dataSources/{datasourceId}

resourceType string

Required. The type of the GCP resource. Ex: sqladmin.googleapis.com/Instance

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableFetchBackupsForResourceTypeResponseBackup

A pageable sequence of Backup resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
DataSourceName parent = DataSourceName.FromProjectLocationBackupvaultDatasource("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]");
string resourceType = "";
// Make the request
PagedEnumerable<FetchBackupsForResourceTypeResponse, Backup> response = backupDRClient.FetchBackupsForResourceType(parent, resourceType);

// Iterate over all response items, lazily performing RPCs as required
foreach (Backup item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (FetchBackupsForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Backup item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Backup> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Backup item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchBackupsForResourceType(FetchBackupsForResourceTypeRequest, CallSettings)

public virtual PagedEnumerable<FetchBackupsForResourceTypeResponse, Backup> FetchBackupsForResourceType(FetchBackupsForResourceTypeRequest request, CallSettings callSettings = null)

Fetch Backups for a given resource type.

Parameters
Name Description
request FetchBackupsForResourceTypeRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableFetchBackupsForResourceTypeResponseBackup

A pageable sequence of Backup resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
FetchBackupsForResourceTypeRequest request = new FetchBackupsForResourceTypeRequest
{
    ParentAsDataSourceName = DataSourceName.FromProjectLocationBackupvaultDatasource("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]"),
    ResourceType = "",
    Filter = "",
    OrderBy = "",
    View = BackupView.Unspecified,
};
// Make the request
PagedEnumerable<FetchBackupsForResourceTypeResponse, Backup> response = backupDRClient.FetchBackupsForResourceType(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (Backup item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (FetchBackupsForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Backup item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Backup> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Backup item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchBackupsForResourceType(string, string, string, int?, CallSettings)

public virtual PagedEnumerable<FetchBackupsForResourceTypeResponse, Backup> FetchBackupsForResourceType(string parent, string resourceType, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Fetch Backups for a given resource type.

Parameters
Name Description
parent string

Required. Datasources are the parent resource for the backups. Format: projects/{project}/locations/{location}/backupVaults/{backupVaultId}/dataSources/{datasourceId}

resourceType string

Required. The type of the GCP resource. Ex: sqladmin.googleapis.com/Instance

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableFetchBackupsForResourceTypeResponseBackup

A pageable sequence of Backup resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]/dataSources/[DATASOURCE]";
string resourceType = "";
// Make the request
PagedEnumerable<FetchBackupsForResourceTypeResponse, Backup> response = backupDRClient.FetchBackupsForResourceType(parent, resourceType);

// Iterate over all response items, lazily performing RPCs as required
foreach (Backup item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (FetchBackupsForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Backup item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Backup> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Backup item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchBackupsForResourceTypeAsync(DataSourceName, string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<FetchBackupsForResourceTypeResponse, Backup> FetchBackupsForResourceTypeAsync(DataSourceName parent, string resourceType, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Fetch Backups for a given resource type.

Parameters
Name Description
parent DataSourceName

Required. Datasources are the parent resource for the backups. Format: projects/{project}/locations/{location}/backupVaults/{backupVaultId}/dataSources/{datasourceId}

resourceType string

Required. The type of the GCP resource. Ex: sqladmin.googleapis.com/Instance

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableFetchBackupsForResourceTypeResponseBackup

A pageable asynchronous sequence of Backup resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DataSourceName parent = DataSourceName.FromProjectLocationBackupvaultDatasource("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]");
string resourceType = "";
// Make the request
PagedAsyncEnumerable<FetchBackupsForResourceTypeResponse, Backup> response = backupDRClient.FetchBackupsForResourceTypeAsync(parent, resourceType);

// Iterate over all response items, lazily performing RPCs as required
await foreach (Backup item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (FetchBackupsForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Backup item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Backup> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Backup item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchBackupsForResourceTypeAsync(FetchBackupsForResourceTypeRequest, CallSettings)

public virtual PagedAsyncEnumerable<FetchBackupsForResourceTypeResponse, Backup> FetchBackupsForResourceTypeAsync(FetchBackupsForResourceTypeRequest request, CallSettings callSettings = null)

Fetch Backups for a given resource type.

Parameters
Name Description
request FetchBackupsForResourceTypeRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableFetchBackupsForResourceTypeResponseBackup

A pageable asynchronous sequence of Backup resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
FetchBackupsForResourceTypeRequest request = new FetchBackupsForResourceTypeRequest
{
    ParentAsDataSourceName = DataSourceName.FromProjectLocationBackupvaultDatasource("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]"),
    ResourceType = "",
    Filter = "",
    OrderBy = "",
    View = BackupView.Unspecified,
};
// Make the request
PagedAsyncEnumerable<FetchBackupsForResourceTypeResponse, Backup> response = backupDRClient.FetchBackupsForResourceTypeAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await foreach (Backup item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (FetchBackupsForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Backup item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Backup> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Backup item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchBackupsForResourceTypeAsync(string, string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<FetchBackupsForResourceTypeResponse, Backup> FetchBackupsForResourceTypeAsync(string parent, string resourceType, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Fetch Backups for a given resource type.

Parameters
Name Description
parent string

Required. Datasources are the parent resource for the backups. Format: projects/{project}/locations/{location}/backupVaults/{backupVaultId}/dataSources/{datasourceId}

resourceType string

Required. The type of the GCP resource. Ex: sqladmin.googleapis.com/Instance

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableFetchBackupsForResourceTypeResponseBackup

A pageable asynchronous sequence of Backup resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]/dataSources/[DATASOURCE]";
string resourceType = "";
// Make the request
PagedAsyncEnumerable<FetchBackupsForResourceTypeResponse, Backup> response = backupDRClient.FetchBackupsForResourceTypeAsync(parent, resourceType);

// Iterate over all response items, lazily performing RPCs as required
await foreach (Backup item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (FetchBackupsForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Backup item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Backup> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Backup item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchDataSourceReferencesForResourceType(LocationName, string, string, int?, CallSettings)

public virtual PagedEnumerable<FetchDataSourceReferencesForResourceTypeResponse, DataSourceReference> FetchDataSourceReferencesForResourceType(LocationName parent, string resourceType, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Fetch DataSourceReferences for a given project, location and resource type.

Parameters
Name Description
parent LocationName

Required. The parent resource name. Format: projects/{project}/locations/{location}

resourceType string

Required. The type of the Google Cloud resource. Ex: sql.googleapis.com/Instance

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableFetchDataSourceReferencesForResourceTypeResponseDataSourceReference

A pageable sequence of DataSourceReference resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
string resourceType = "";
// Make the request
PagedEnumerable<FetchDataSourceReferencesForResourceTypeResponse, DataSourceReference> response = backupDRClient.FetchDataSourceReferencesForResourceType(parent, resourceType);

// Iterate over all response items, lazily performing RPCs as required
foreach (DataSourceReference item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (FetchDataSourceReferencesForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSourceReference item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSourceReference> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSourceReference item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchDataSourceReferencesForResourceType(FetchDataSourceReferencesForResourceTypeRequest, CallSettings)

public virtual PagedEnumerable<FetchDataSourceReferencesForResourceTypeResponse, DataSourceReference> FetchDataSourceReferencesForResourceType(FetchDataSourceReferencesForResourceTypeRequest request, CallSettings callSettings = null)

Fetch DataSourceReferences for a given project, location and resource type.

Parameters
Name Description
request FetchDataSourceReferencesForResourceTypeRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableFetchDataSourceReferencesForResourceTypeResponseDataSourceReference

A pageable sequence of DataSourceReference resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
FetchDataSourceReferencesForResourceTypeRequest request = new FetchDataSourceReferencesForResourceTypeRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    ResourceType = "",
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedEnumerable<FetchDataSourceReferencesForResourceTypeResponse, DataSourceReference> response = backupDRClient.FetchDataSourceReferencesForResourceType(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (DataSourceReference item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (FetchDataSourceReferencesForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSourceReference item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSourceReference> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSourceReference item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchDataSourceReferencesForResourceType(string, string, string, int?, CallSettings)

public virtual PagedEnumerable<FetchDataSourceReferencesForResourceTypeResponse, DataSourceReference> FetchDataSourceReferencesForResourceType(string parent, string resourceType, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Fetch DataSourceReferences for a given project, location and resource type.

Parameters
Name Description
parent string

Required. The parent resource name. Format: projects/{project}/locations/{location}

resourceType string

Required. The type of the Google Cloud resource. Ex: sql.googleapis.com/Instance

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableFetchDataSourceReferencesForResourceTypeResponseDataSourceReference

A pageable sequence of DataSourceReference resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
string resourceType = "";
// Make the request
PagedEnumerable<FetchDataSourceReferencesForResourceTypeResponse, DataSourceReference> response = backupDRClient.FetchDataSourceReferencesForResourceType(parent, resourceType);

// Iterate over all response items, lazily performing RPCs as required
foreach (DataSourceReference item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (FetchDataSourceReferencesForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSourceReference item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSourceReference> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSourceReference item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchDataSourceReferencesForResourceTypeAsync(LocationName, string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<FetchDataSourceReferencesForResourceTypeResponse, DataSourceReference> FetchDataSourceReferencesForResourceTypeAsync(LocationName parent, string resourceType, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Fetch DataSourceReferences for a given project, location and resource type.

Parameters
Name Description
parent LocationName

Required. The parent resource name. Format: projects/{project}/locations/{location}

resourceType string

Required. The type of the Google Cloud resource. Ex: sql.googleapis.com/Instance

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableFetchDataSourceReferencesForResourceTypeResponseDataSourceReference

A pageable asynchronous sequence of DataSourceReference resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
string resourceType = "";
// Make the request
PagedAsyncEnumerable<FetchDataSourceReferencesForResourceTypeResponse, DataSourceReference> response = backupDRClient.FetchDataSourceReferencesForResourceTypeAsync(parent, resourceType);

// Iterate over all response items, lazily performing RPCs as required
await foreach (DataSourceReference item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (FetchDataSourceReferencesForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSourceReference item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSourceReference> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSourceReference item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchDataSourceReferencesForResourceTypeAsync(FetchDataSourceReferencesForResourceTypeRequest, CallSettings)

public virtual PagedAsyncEnumerable<FetchDataSourceReferencesForResourceTypeResponse, DataSourceReference> FetchDataSourceReferencesForResourceTypeAsync(FetchDataSourceReferencesForResourceTypeRequest request, CallSettings callSettings = null)

Fetch DataSourceReferences for a given project, location and resource type.

Parameters
Name Description
request FetchDataSourceReferencesForResourceTypeRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableFetchDataSourceReferencesForResourceTypeResponseDataSourceReference

A pageable asynchronous sequence of DataSourceReference resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
FetchDataSourceReferencesForResourceTypeRequest request = new FetchDataSourceReferencesForResourceTypeRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    ResourceType = "",
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedAsyncEnumerable<FetchDataSourceReferencesForResourceTypeResponse, DataSourceReference> response = backupDRClient.FetchDataSourceReferencesForResourceTypeAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await foreach (DataSourceReference item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (FetchDataSourceReferencesForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSourceReference item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSourceReference> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSourceReference item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchDataSourceReferencesForResourceTypeAsync(string, string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<FetchDataSourceReferencesForResourceTypeResponse, DataSourceReference> FetchDataSourceReferencesForResourceTypeAsync(string parent, string resourceType, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Fetch DataSourceReferences for a given project, location and resource type.

Parameters
Name Description
parent string

Required. The parent resource name. Format: projects/{project}/locations/{location}

resourceType string

Required. The type of the Google Cloud resource. Ex: sql.googleapis.com/Instance

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableFetchDataSourceReferencesForResourceTypeResponseDataSourceReference

A pageable asynchronous sequence of DataSourceReference resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
string resourceType = "";
// Make the request
PagedAsyncEnumerable<FetchDataSourceReferencesForResourceTypeResponse, DataSourceReference> response = backupDRClient.FetchDataSourceReferencesForResourceTypeAsync(parent, resourceType);

// Iterate over all response items, lazily performing RPCs as required
await foreach (DataSourceReference item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (FetchDataSourceReferencesForResourceTypeResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSourceReference item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSourceReference> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSourceReference item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchUsableBackupVaults(LocationName, string, int?, CallSettings)

public virtual PagedEnumerable<FetchUsableBackupVaultsResponse, BackupVault> FetchUsableBackupVaults(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

FetchUsableBackupVaults lists usable BackupVaults in a given project and location. Usable BackupVault are the ones that user has backupdr.backupVaults.get permission.

Parameters
Name Description
parent LocationName

Required. The project and location for which to retrieve backupvault stores information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve backupvault stores for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableFetchUsableBackupVaultsResponseBackupVault

A pageable sequence of BackupVault resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedEnumerable<FetchUsableBackupVaultsResponse, BackupVault> response = backupDRClient.FetchUsableBackupVaults(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupVault item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (FetchUsableBackupVaultsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupVault item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupVault> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupVault item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchUsableBackupVaults(FetchUsableBackupVaultsRequest, CallSettings)

public virtual PagedEnumerable<FetchUsableBackupVaultsResponse, BackupVault> FetchUsableBackupVaults(FetchUsableBackupVaultsRequest request, CallSettings callSettings = null)

FetchUsableBackupVaults lists usable BackupVaults in a given project and location. Usable BackupVault are the ones that user has backupdr.backupVaults.get permission.

Parameters
Name Description
request FetchUsableBackupVaultsRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableFetchUsableBackupVaultsResponseBackupVault

A pageable sequence of BackupVault resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
FetchUsableBackupVaultsRequest request = new FetchUsableBackupVaultsRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedEnumerable<FetchUsableBackupVaultsResponse, BackupVault> response = backupDRClient.FetchUsableBackupVaults(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupVault item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (FetchUsableBackupVaultsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupVault item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupVault> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupVault item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchUsableBackupVaults(string, string, int?, CallSettings)

public virtual PagedEnumerable<FetchUsableBackupVaultsResponse, BackupVault> FetchUsableBackupVaults(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

FetchUsableBackupVaults lists usable BackupVaults in a given project and location. Usable BackupVault are the ones that user has backupdr.backupVaults.get permission.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve backupvault stores information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve backupvault stores for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableFetchUsableBackupVaultsResponseBackupVault

A pageable sequence of BackupVault resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedEnumerable<FetchUsableBackupVaultsResponse, BackupVault> response = backupDRClient.FetchUsableBackupVaults(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupVault item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (FetchUsableBackupVaultsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupVault item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupVault> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupVault item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchUsableBackupVaultsAsync(LocationName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<FetchUsableBackupVaultsResponse, BackupVault> FetchUsableBackupVaultsAsync(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

FetchUsableBackupVaults lists usable BackupVaults in a given project and location. Usable BackupVault are the ones that user has backupdr.backupVaults.get permission.

Parameters
Name Description
parent LocationName

Required. The project and location for which to retrieve backupvault stores information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve backupvault stores for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableFetchUsableBackupVaultsResponseBackupVault

A pageable asynchronous sequence of BackupVault resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedAsyncEnumerable<FetchUsableBackupVaultsResponse, BackupVault> response = backupDRClient.FetchUsableBackupVaultsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupVault item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (FetchUsableBackupVaultsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupVault item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupVault> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupVault item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchUsableBackupVaultsAsync(FetchUsableBackupVaultsRequest, CallSettings)

public virtual PagedAsyncEnumerable<FetchUsableBackupVaultsResponse, BackupVault> FetchUsableBackupVaultsAsync(FetchUsableBackupVaultsRequest request, CallSettings callSettings = null)

FetchUsableBackupVaults lists usable BackupVaults in a given project and location. Usable BackupVault are the ones that user has backupdr.backupVaults.get permission.

Parameters
Name Description
request FetchUsableBackupVaultsRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableFetchUsableBackupVaultsResponseBackupVault

A pageable asynchronous sequence of BackupVault resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
FetchUsableBackupVaultsRequest request = new FetchUsableBackupVaultsRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedAsyncEnumerable<FetchUsableBackupVaultsResponse, BackupVault> response = backupDRClient.FetchUsableBackupVaultsAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupVault item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (FetchUsableBackupVaultsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupVault item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupVault> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupVault item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

FetchUsableBackupVaultsAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<FetchUsableBackupVaultsResponse, BackupVault> FetchUsableBackupVaultsAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

FetchUsableBackupVaults lists usable BackupVaults in a given project and location. Usable BackupVault are the ones that user has backupdr.backupVaults.get permission.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve backupvault stores information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve backupvault stores for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableFetchUsableBackupVaultsResponseBackupVault

A pageable asynchronous sequence of BackupVault resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedAsyncEnumerable<FetchUsableBackupVaultsResponse, BackupVault> response = backupDRClient.FetchUsableBackupVaultsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupVault item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (FetchUsableBackupVaultsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupVault item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupVault> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupVault item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

GetAutoProtectionPolicy(AutoProtectionPolicyName, CallSettings)

public virtual AutoProtectionPolicy GetAutoProtectionPolicy(AutoProtectionPolicyName name, CallSettings callSettings = null)

Gets details of a single AutoProtectionPolicy.

Parameters
Name Description
name AutoProtectionPolicyName

Required. The name of the policy to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
AutoProtectionPolicy

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
AutoProtectionPolicyName name = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]");
// Make the request
AutoProtectionPolicy response = backupDRClient.GetAutoProtectionPolicy(name);

GetAutoProtectionPolicy(GetAutoProtectionPolicyRequest, CallSettings)

public virtual AutoProtectionPolicy GetAutoProtectionPolicy(GetAutoProtectionPolicyRequest request, CallSettings callSettings = null)

Gets details of a single AutoProtectionPolicy.

Parameters
Name Description
request GetAutoProtectionPolicyRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
AutoProtectionPolicy

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
GetAutoProtectionPolicyRequest request = new GetAutoProtectionPolicyRequest
{
    AutoProtectionPolicyName = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]"),
};
// Make the request
AutoProtectionPolicy response = backupDRClient.GetAutoProtectionPolicy(request);

GetAutoProtectionPolicy(string, CallSettings)

public virtual AutoProtectionPolicy GetAutoProtectionPolicy(string name, CallSettings callSettings = null)

Gets details of a single AutoProtectionPolicy.

Parameters
Name Description
name string

Required. The name of the policy to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
AutoProtectionPolicy

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]";
// Make the request
AutoProtectionPolicy response = backupDRClient.GetAutoProtectionPolicy(name);

GetAutoProtectionPolicyAsync(AutoProtectionPolicyName, CallSettings)

public virtual Task<AutoProtectionPolicy> GetAutoProtectionPolicyAsync(AutoProtectionPolicyName name, CallSettings callSettings = null)

Gets details of a single AutoProtectionPolicy.

Parameters
Name Description
name AutoProtectionPolicyName

Required. The name of the policy to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskAutoProtectionPolicy

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
AutoProtectionPolicyName name = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]");
// Make the request
AutoProtectionPolicy response = await backupDRClient.GetAutoProtectionPolicyAsync(name);

GetAutoProtectionPolicyAsync(AutoProtectionPolicyName, CancellationToken)

public virtual Task<AutoProtectionPolicy> GetAutoProtectionPolicyAsync(AutoProtectionPolicyName name, CancellationToken cancellationToken)

Gets details of a single AutoProtectionPolicy.

Parameters
Name Description
name AutoProtectionPolicyName

Required. The name of the policy to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskAutoProtectionPolicy

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
AutoProtectionPolicyName name = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]");
// Make the request
AutoProtectionPolicy response = await backupDRClient.GetAutoProtectionPolicyAsync(name);

GetAutoProtectionPolicyAsync(GetAutoProtectionPolicyRequest, CallSettings)

public virtual Task<AutoProtectionPolicy> GetAutoProtectionPolicyAsync(GetAutoProtectionPolicyRequest request, CallSettings callSettings = null)

Gets details of a single AutoProtectionPolicy.

Parameters
Name Description
request GetAutoProtectionPolicyRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskAutoProtectionPolicy

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetAutoProtectionPolicyRequest request = new GetAutoProtectionPolicyRequest
{
    AutoProtectionPolicyName = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]"),
};
// Make the request
AutoProtectionPolicy response = await backupDRClient.GetAutoProtectionPolicyAsync(request);

GetAutoProtectionPolicyAsync(GetAutoProtectionPolicyRequest, CancellationToken)

public virtual Task<AutoProtectionPolicy> GetAutoProtectionPolicyAsync(GetAutoProtectionPolicyRequest request, CancellationToken cancellationToken)

Gets details of a single AutoProtectionPolicy.

Parameters
Name Description
request GetAutoProtectionPolicyRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskAutoProtectionPolicy

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetAutoProtectionPolicyRequest request = new GetAutoProtectionPolicyRequest
{
    AutoProtectionPolicyName = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]"),
};
// Make the request
AutoProtectionPolicy response = await backupDRClient.GetAutoProtectionPolicyAsync(request);

GetAutoProtectionPolicyAsync(string, CallSettings)

public virtual Task<AutoProtectionPolicy> GetAutoProtectionPolicyAsync(string name, CallSettings callSettings = null)

Gets details of a single AutoProtectionPolicy.

Parameters
Name Description
name string

Required. The name of the policy to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskAutoProtectionPolicy

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]";
// Make the request
AutoProtectionPolicy response = await backupDRClient.GetAutoProtectionPolicyAsync(name);

GetAutoProtectionPolicyAsync(string, CancellationToken)

public virtual Task<AutoProtectionPolicy> GetAutoProtectionPolicyAsync(string name, CancellationToken cancellationToken)

Gets details of a single AutoProtectionPolicy.

Parameters
Name Description
name string

Required. The name of the policy to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskAutoProtectionPolicy

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]";
// Make the request
AutoProtectionPolicy response = await backupDRClient.GetAutoProtectionPolicyAsync(name);

GetAutoProtectionPolicyBinding(AutoProtectionPolicyBindingName, CallSettings)

public virtual AutoProtectionPolicyBinding GetAutoProtectionPolicyBinding(AutoProtectionPolicyBindingName name, CallSettings callSettings = null)

Returns the auto protection policy binding read from the CCFE tables.

Parameters
Name Description
name AutoProtectionPolicyBindingName

Required. The name of the binding to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
AutoProtectionPolicyBinding

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
AutoProtectionPolicyBindingName name = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]");
// Make the request
AutoProtectionPolicyBinding response = backupDRClient.GetAutoProtectionPolicyBinding(name);

GetAutoProtectionPolicyBinding(GetAutoProtectionPolicyBindingRequest, CallSettings)

public virtual AutoProtectionPolicyBinding GetAutoProtectionPolicyBinding(GetAutoProtectionPolicyBindingRequest request, CallSettings callSettings = null)

Returns the auto protection policy binding read from the CCFE tables.

Parameters
Name Description
request GetAutoProtectionPolicyBindingRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
AutoProtectionPolicyBinding

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
GetAutoProtectionPolicyBindingRequest request = new GetAutoProtectionPolicyBindingRequest
{
    AutoProtectionPolicyBindingName = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]"),
};
// Make the request
AutoProtectionPolicyBinding response = backupDRClient.GetAutoProtectionPolicyBinding(request);

GetAutoProtectionPolicyBinding(string, CallSettings)

public virtual AutoProtectionPolicyBinding GetAutoProtectionPolicyBinding(string name, CallSettings callSettings = null)

Returns the auto protection policy binding read from the CCFE tables.

Parameters
Name Description
name string

Required. The name of the binding to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
AutoProtectionPolicyBinding

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]/bindings/[BINDING]";
// Make the request
AutoProtectionPolicyBinding response = backupDRClient.GetAutoProtectionPolicyBinding(name);

GetAutoProtectionPolicyBindingAsync(AutoProtectionPolicyBindingName, CallSettings)

public virtual Task<AutoProtectionPolicyBinding> GetAutoProtectionPolicyBindingAsync(AutoProtectionPolicyBindingName name, CallSettings callSettings = null)

Returns the auto protection policy binding read from the CCFE tables.

Parameters
Name Description
name AutoProtectionPolicyBindingName

Required. The name of the binding to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskAutoProtectionPolicyBinding

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
AutoProtectionPolicyBindingName name = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]");
// Make the request
AutoProtectionPolicyBinding response = await backupDRClient.GetAutoProtectionPolicyBindingAsync(name);

GetAutoProtectionPolicyBindingAsync(AutoProtectionPolicyBindingName, CancellationToken)

public virtual Task<AutoProtectionPolicyBinding> GetAutoProtectionPolicyBindingAsync(AutoProtectionPolicyBindingName name, CancellationToken cancellationToken)

Returns the auto protection policy binding read from the CCFE tables.

Parameters
Name Description
name AutoProtectionPolicyBindingName

Required. The name of the binding to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskAutoProtectionPolicyBinding

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
AutoProtectionPolicyBindingName name = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]");
// Make the request
AutoProtectionPolicyBinding response = await backupDRClient.GetAutoProtectionPolicyBindingAsync(name);

GetAutoProtectionPolicyBindingAsync(GetAutoProtectionPolicyBindingRequest, CallSettings)

public virtual Task<AutoProtectionPolicyBinding> GetAutoProtectionPolicyBindingAsync(GetAutoProtectionPolicyBindingRequest request, CallSettings callSettings = null)

Returns the auto protection policy binding read from the CCFE tables.

Parameters
Name Description
request GetAutoProtectionPolicyBindingRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskAutoProtectionPolicyBinding

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetAutoProtectionPolicyBindingRequest request = new GetAutoProtectionPolicyBindingRequest
{
    AutoProtectionPolicyBindingName = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]"),
};
// Make the request
AutoProtectionPolicyBinding response = await backupDRClient.GetAutoProtectionPolicyBindingAsync(request);

GetAutoProtectionPolicyBindingAsync(GetAutoProtectionPolicyBindingRequest, CancellationToken)

public virtual Task<AutoProtectionPolicyBinding> GetAutoProtectionPolicyBindingAsync(GetAutoProtectionPolicyBindingRequest request, CancellationToken cancellationToken)

Returns the auto protection policy binding read from the CCFE tables.

Parameters
Name Description
request GetAutoProtectionPolicyBindingRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskAutoProtectionPolicyBinding

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetAutoProtectionPolicyBindingRequest request = new GetAutoProtectionPolicyBindingRequest
{
    AutoProtectionPolicyBindingName = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]"),
};
// Make the request
AutoProtectionPolicyBinding response = await backupDRClient.GetAutoProtectionPolicyBindingAsync(request);

GetAutoProtectionPolicyBindingAsync(string, CallSettings)

public virtual Task<AutoProtectionPolicyBinding> GetAutoProtectionPolicyBindingAsync(string name, CallSettings callSettings = null)

Returns the auto protection policy binding read from the CCFE tables.

Parameters
Name Description
name string

Required. The name of the binding to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskAutoProtectionPolicyBinding

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]/bindings/[BINDING]";
// Make the request
AutoProtectionPolicyBinding response = await backupDRClient.GetAutoProtectionPolicyBindingAsync(name);

GetAutoProtectionPolicyBindingAsync(string, CancellationToken)

public virtual Task<AutoProtectionPolicyBinding> GetAutoProtectionPolicyBindingAsync(string name, CancellationToken cancellationToken)

Returns the auto protection policy binding read from the CCFE tables.

Parameters
Name Description
name string

Required. The name of the binding to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskAutoProtectionPolicyBinding

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]/bindings/[BINDING]";
// Make the request
AutoProtectionPolicyBinding response = await backupDRClient.GetAutoProtectionPolicyBindingAsync(name);

GetBackup(BackupName, CallSettings)

public virtual Backup GetBackup(BackupName name, CallSettings callSettings = null)

Gets details of a Backup.

Parameters
Name Description
name BackupName

Required. Name of the data source resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{backupVault}/dataSources/{datasource}/backups/{backup}'

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
Backup

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BackupName name = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]");
// Make the request
Backup response = backupDRClient.GetBackup(name);

GetBackup(GetBackupRequest, CallSettings)

public virtual Backup GetBackup(GetBackupRequest request, CallSettings callSettings = null)

Gets details of a Backup.

Parameters
Name Description
request GetBackupRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
Backup

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
GetBackupRequest request = new GetBackupRequest
{
    BackupName = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]"),
    View = BackupView.Unspecified,
};
// Make the request
Backup response = backupDRClient.GetBackup(request);

GetBackup(string, CallSettings)

public virtual Backup GetBackup(string name, CallSettings callSettings = null)

Gets details of a Backup.

Parameters
Name Description
name string

Required. Name of the data source resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{backupVault}/dataSources/{datasource}/backups/{backup}'

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
Backup

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]/dataSources/[DATASOURCE]/backups/[BACKUP]";
// Make the request
Backup response = backupDRClient.GetBackup(name);

GetBackupAsync(BackupName, CallSettings)

public virtual Task<Backup> GetBackupAsync(BackupName name, CallSettings callSettings = null)

Gets details of a Backup.

Parameters
Name Description
name BackupName

Required. Name of the data source resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{backupVault}/dataSources/{datasource}/backups/{backup}'

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBackup

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupName name = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]");
// Make the request
Backup response = await backupDRClient.GetBackupAsync(name);

GetBackupAsync(BackupName, CancellationToken)

public virtual Task<Backup> GetBackupAsync(BackupName name, CancellationToken cancellationToken)

Gets details of a Backup.

Parameters
Name Description
name BackupName

Required. Name of the data source resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{backupVault}/dataSources/{datasource}/backups/{backup}'

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBackup

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupName name = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]");
// Make the request
Backup response = await backupDRClient.GetBackupAsync(name);

GetBackupAsync(GetBackupRequest, CallSettings)

public virtual Task<Backup> GetBackupAsync(GetBackupRequest request, CallSettings callSettings = null)

Gets details of a Backup.

Parameters
Name Description
request GetBackupRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBackup

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetBackupRequest request = new GetBackupRequest
{
    BackupName = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]"),
    View = BackupView.Unspecified,
};
// Make the request
Backup response = await backupDRClient.GetBackupAsync(request);

GetBackupAsync(GetBackupRequest, CancellationToken)

public virtual Task<Backup> GetBackupAsync(GetBackupRequest request, CancellationToken cancellationToken)

Gets details of a Backup.

Parameters
Name Description
request GetBackupRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBackup

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetBackupRequest request = new GetBackupRequest
{
    BackupName = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]"),
    View = BackupView.Unspecified,
};
// Make the request
Backup response = await backupDRClient.GetBackupAsync(request);

GetBackupAsync(string, CallSettings)

public virtual Task<Backup> GetBackupAsync(string name, CallSettings callSettings = null)

Gets details of a Backup.

Parameters
Name Description
name string

Required. Name of the data source resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{backupVault}/dataSources/{datasource}/backups/{backup}'

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBackup

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]/dataSources/[DATASOURCE]/backups/[BACKUP]";
// Make the request
Backup response = await backupDRClient.GetBackupAsync(name);

GetBackupAsync(string, CancellationToken)

public virtual Task<Backup> GetBackupAsync(string name, CancellationToken cancellationToken)

Gets details of a Backup.

Parameters
Name Description
name string

Required. Name of the data source resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{backupVault}/dataSources/{datasource}/backups/{backup}'

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBackup

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]/dataSources/[DATASOURCE]/backups/[BACKUP]";
// Make the request
Backup response = await backupDRClient.GetBackupAsync(name);

GetBackupPlan(BackupPlanName, CallSettings)

public virtual BackupPlan GetBackupPlan(BackupPlanName name, CallSettings callSettings = null)

Gets details of a single BackupPlan.

Parameters
Name Description
name BackupPlanName

Required. The resource name of the BackupPlan to retrieve.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
BackupPlan

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BackupPlanName name = BackupPlanName.FromProjectLocationBackupPlan("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]");
// Make the request
BackupPlan response = backupDRClient.GetBackupPlan(name);

GetBackupPlan(GetBackupPlanRequest, CallSettings)

public virtual BackupPlan GetBackupPlan(GetBackupPlanRequest request, CallSettings callSettings = null)

Gets details of a single BackupPlan.

Parameters
Name Description
request GetBackupPlanRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
BackupPlan

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
GetBackupPlanRequest request = new GetBackupPlanRequest
{
    BackupPlanName = BackupPlanName.FromProjectLocationBackupPlan("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]"),
};
// Make the request
BackupPlan response = backupDRClient.GetBackupPlan(request);

GetBackupPlan(string, CallSettings)

public virtual BackupPlan GetBackupPlan(string name, CallSettings callSettings = null)

Gets details of a single BackupPlan.

Parameters
Name Description
name string

Required. The resource name of the BackupPlan to retrieve.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
BackupPlan

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlans/[BACKUP_PLAN]";
// Make the request
BackupPlan response = backupDRClient.GetBackupPlan(name);

GetBackupPlanAssociation(BackupPlanAssociationName, CallSettings)

public virtual BackupPlanAssociation GetBackupPlanAssociation(BackupPlanAssociationName name, CallSettings callSettings = null)

Gets details of a single BackupPlanAssociation.

Parameters
Name Description
name BackupPlanAssociationName

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
BackupPlanAssociation

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BackupPlanAssociationName name = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]");
// Make the request
BackupPlanAssociation response = backupDRClient.GetBackupPlanAssociation(name);

GetBackupPlanAssociation(GetBackupPlanAssociationRequest, CallSettings)

public virtual BackupPlanAssociation GetBackupPlanAssociation(GetBackupPlanAssociationRequest request, CallSettings callSettings = null)

Gets details of a single BackupPlanAssociation.

Parameters
Name Description
request GetBackupPlanAssociationRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
BackupPlanAssociation

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
GetBackupPlanAssociationRequest request = new GetBackupPlanAssociationRequest
{
    BackupPlanAssociationName = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]"),
};
// Make the request
BackupPlanAssociation response = backupDRClient.GetBackupPlanAssociation(request);

GetBackupPlanAssociation(string, CallSettings)

public virtual BackupPlanAssociation GetBackupPlanAssociation(string name, CallSettings callSettings = null)

Gets details of a single BackupPlanAssociation.

Parameters
Name Description
name string

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
BackupPlanAssociation

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlanAssociations/[BACKUP_PLAN_ASSOCIATION]";
// Make the request
BackupPlanAssociation response = backupDRClient.GetBackupPlanAssociation(name);

GetBackupPlanAssociationAsync(BackupPlanAssociationName, CallSettings)

public virtual Task<BackupPlanAssociation> GetBackupPlanAssociationAsync(BackupPlanAssociationName name, CallSettings callSettings = null)

Gets details of a single BackupPlanAssociation.

Parameters
Name Description
name BackupPlanAssociationName

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBackupPlanAssociation

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlanAssociationName name = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]");
// Make the request
BackupPlanAssociation response = await backupDRClient.GetBackupPlanAssociationAsync(name);

GetBackupPlanAssociationAsync(BackupPlanAssociationName, CancellationToken)

public virtual Task<BackupPlanAssociation> GetBackupPlanAssociationAsync(BackupPlanAssociationName name, CancellationToken cancellationToken)

Gets details of a single BackupPlanAssociation.

Parameters
Name Description
name BackupPlanAssociationName

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBackupPlanAssociation

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlanAssociationName name = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]");
// Make the request
BackupPlanAssociation response = await backupDRClient.GetBackupPlanAssociationAsync(name);

GetBackupPlanAssociationAsync(GetBackupPlanAssociationRequest, CallSettings)

public virtual Task<BackupPlanAssociation> GetBackupPlanAssociationAsync(GetBackupPlanAssociationRequest request, CallSettings callSettings = null)

Gets details of a single BackupPlanAssociation.

Parameters
Name Description
request GetBackupPlanAssociationRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBackupPlanAssociation

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetBackupPlanAssociationRequest request = new GetBackupPlanAssociationRequest
{
    BackupPlanAssociationName = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]"),
};
// Make the request
BackupPlanAssociation response = await backupDRClient.GetBackupPlanAssociationAsync(request);

GetBackupPlanAssociationAsync(GetBackupPlanAssociationRequest, CancellationToken)

public virtual Task<BackupPlanAssociation> GetBackupPlanAssociationAsync(GetBackupPlanAssociationRequest request, CancellationToken cancellationToken)

Gets details of a single BackupPlanAssociation.

Parameters
Name Description
request GetBackupPlanAssociationRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBackupPlanAssociation

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetBackupPlanAssociationRequest request = new GetBackupPlanAssociationRequest
{
    BackupPlanAssociationName = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]"),
};
// Make the request
BackupPlanAssociation response = await backupDRClient.GetBackupPlanAssociationAsync(request);

GetBackupPlanAssociationAsync(string, CallSettings)

public virtual Task<BackupPlanAssociation> GetBackupPlanAssociationAsync(string name, CallSettings callSettings = null)

Gets details of a single BackupPlanAssociation.

Parameters
Name Description
name string

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBackupPlanAssociation

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlanAssociations/[BACKUP_PLAN_ASSOCIATION]";
// Make the request
BackupPlanAssociation response = await backupDRClient.GetBackupPlanAssociationAsync(name);

GetBackupPlanAssociationAsync(string, CancellationToken)

public virtual Task<BackupPlanAssociation> GetBackupPlanAssociationAsync(string name, CancellationToken cancellationToken)

Gets details of a single BackupPlanAssociation.

Parameters
Name Description
name string

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBackupPlanAssociation

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlanAssociations/[BACKUP_PLAN_ASSOCIATION]";
// Make the request
BackupPlanAssociation response = await backupDRClient.GetBackupPlanAssociationAsync(name);

GetBackupPlanAsync(BackupPlanName, CallSettings)

public virtual Task<BackupPlan> GetBackupPlanAsync(BackupPlanName name, CallSettings callSettings = null)

Gets details of a single BackupPlan.

Parameters
Name Description
name BackupPlanName

Required. The resource name of the BackupPlan to retrieve.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBackupPlan

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlanName name = BackupPlanName.FromProjectLocationBackupPlan("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]");
// Make the request
BackupPlan response = await backupDRClient.GetBackupPlanAsync(name);

GetBackupPlanAsync(BackupPlanName, CancellationToken)

public virtual Task<BackupPlan> GetBackupPlanAsync(BackupPlanName name, CancellationToken cancellationToken)

Gets details of a single BackupPlan.

Parameters
Name Description
name BackupPlanName

Required. The resource name of the BackupPlan to retrieve.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBackupPlan

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlanName name = BackupPlanName.FromProjectLocationBackupPlan("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]");
// Make the request
BackupPlan response = await backupDRClient.GetBackupPlanAsync(name);

GetBackupPlanAsync(GetBackupPlanRequest, CallSettings)

public virtual Task<BackupPlan> GetBackupPlanAsync(GetBackupPlanRequest request, CallSettings callSettings = null)

Gets details of a single BackupPlan.

Parameters
Name Description
request GetBackupPlanRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBackupPlan

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetBackupPlanRequest request = new GetBackupPlanRequest
{
    BackupPlanName = BackupPlanName.FromProjectLocationBackupPlan("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]"),
};
// Make the request
BackupPlan response = await backupDRClient.GetBackupPlanAsync(request);

GetBackupPlanAsync(GetBackupPlanRequest, CancellationToken)

public virtual Task<BackupPlan> GetBackupPlanAsync(GetBackupPlanRequest request, CancellationToken cancellationToken)

Gets details of a single BackupPlan.

Parameters
Name Description
request GetBackupPlanRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBackupPlan

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetBackupPlanRequest request = new GetBackupPlanRequest
{
    BackupPlanName = BackupPlanName.FromProjectLocationBackupPlan("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]"),
};
// Make the request
BackupPlan response = await backupDRClient.GetBackupPlanAsync(request);

GetBackupPlanAsync(string, CallSettings)

public virtual Task<BackupPlan> GetBackupPlanAsync(string name, CallSettings callSettings = null)

Gets details of a single BackupPlan.

Parameters
Name Description
name string

Required. The resource name of the BackupPlan to retrieve.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBackupPlan

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlans/[BACKUP_PLAN]";
// Make the request
BackupPlan response = await backupDRClient.GetBackupPlanAsync(name);

GetBackupPlanAsync(string, CancellationToken)

public virtual Task<BackupPlan> GetBackupPlanAsync(string name, CancellationToken cancellationToken)

Gets details of a single BackupPlan.

Parameters
Name Description
name string

Required. The resource name of the BackupPlan to retrieve.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBackupPlan

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlans/[BACKUP_PLAN]";
// Make the request
BackupPlan response = await backupDRClient.GetBackupPlanAsync(name);

GetBackupPlanRevision(BackupPlanRevisionName, CallSettings)

public virtual BackupPlanRevision GetBackupPlanRevision(BackupPlanRevisionName name, CallSettings callSettings = null)

Gets details of a single BackupPlanRevision.

Parameters
Name Description
name BackupPlanRevisionName

Required. The resource name of the BackupPlanRevision to retrieve.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}/revisions/{revision}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
BackupPlanRevision

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BackupPlanRevisionName name = BackupPlanRevisionName.FromProjectLocationBackupPlanRevision("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]", "[REVISION]");
// Make the request
BackupPlanRevision response = backupDRClient.GetBackupPlanRevision(name);

GetBackupPlanRevision(GetBackupPlanRevisionRequest, CallSettings)

public virtual BackupPlanRevision GetBackupPlanRevision(GetBackupPlanRevisionRequest request, CallSettings callSettings = null)

Gets details of a single BackupPlanRevision.

Parameters
Name Description
request GetBackupPlanRevisionRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
BackupPlanRevision

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
GetBackupPlanRevisionRequest request = new GetBackupPlanRevisionRequest
{
    BackupPlanRevisionName = BackupPlanRevisionName.FromProjectLocationBackupPlanRevision("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]", "[REVISION]"),
};
// Make the request
BackupPlanRevision response = backupDRClient.GetBackupPlanRevision(request);

GetBackupPlanRevision(string, CallSettings)

public virtual BackupPlanRevision GetBackupPlanRevision(string name, CallSettings callSettings = null)

Gets details of a single BackupPlanRevision.

Parameters
Name Description
name string

Required. The resource name of the BackupPlanRevision to retrieve.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}/revisions/{revision}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
BackupPlanRevision

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlans/[BACKUP_PLAN]/revisions/[REVISION]";
// Make the request
BackupPlanRevision response = backupDRClient.GetBackupPlanRevision(name);

GetBackupPlanRevisionAsync(BackupPlanRevisionName, CallSettings)

public virtual Task<BackupPlanRevision> GetBackupPlanRevisionAsync(BackupPlanRevisionName name, CallSettings callSettings = null)

Gets details of a single BackupPlanRevision.

Parameters
Name Description
name BackupPlanRevisionName

Required. The resource name of the BackupPlanRevision to retrieve.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}/revisions/{revision}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBackupPlanRevision

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlanRevisionName name = BackupPlanRevisionName.FromProjectLocationBackupPlanRevision("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]", "[REVISION]");
// Make the request
BackupPlanRevision response = await backupDRClient.GetBackupPlanRevisionAsync(name);

GetBackupPlanRevisionAsync(BackupPlanRevisionName, CancellationToken)

public virtual Task<BackupPlanRevision> GetBackupPlanRevisionAsync(BackupPlanRevisionName name, CancellationToken cancellationToken)

Gets details of a single BackupPlanRevision.

Parameters
Name Description
name BackupPlanRevisionName

Required. The resource name of the BackupPlanRevision to retrieve.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}/revisions/{revision}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBackupPlanRevision

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlanRevisionName name = BackupPlanRevisionName.FromProjectLocationBackupPlanRevision("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]", "[REVISION]");
// Make the request
BackupPlanRevision response = await backupDRClient.GetBackupPlanRevisionAsync(name);

GetBackupPlanRevisionAsync(GetBackupPlanRevisionRequest, CallSettings)

public virtual Task<BackupPlanRevision> GetBackupPlanRevisionAsync(GetBackupPlanRevisionRequest request, CallSettings callSettings = null)

Gets details of a single BackupPlanRevision.

Parameters
Name Description
request GetBackupPlanRevisionRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBackupPlanRevision

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetBackupPlanRevisionRequest request = new GetBackupPlanRevisionRequest
{
    BackupPlanRevisionName = BackupPlanRevisionName.FromProjectLocationBackupPlanRevision("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]", "[REVISION]"),
};
// Make the request
BackupPlanRevision response = await backupDRClient.GetBackupPlanRevisionAsync(request);

GetBackupPlanRevisionAsync(GetBackupPlanRevisionRequest, CancellationToken)

public virtual Task<BackupPlanRevision> GetBackupPlanRevisionAsync(GetBackupPlanRevisionRequest request, CancellationToken cancellationToken)

Gets details of a single BackupPlanRevision.

Parameters
Name Description
request GetBackupPlanRevisionRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBackupPlanRevision

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetBackupPlanRevisionRequest request = new GetBackupPlanRevisionRequest
{
    BackupPlanRevisionName = BackupPlanRevisionName.FromProjectLocationBackupPlanRevision("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]", "[REVISION]"),
};
// Make the request
BackupPlanRevision response = await backupDRClient.GetBackupPlanRevisionAsync(request);

GetBackupPlanRevisionAsync(string, CallSettings)

public virtual Task<BackupPlanRevision> GetBackupPlanRevisionAsync(string name, CallSettings callSettings = null)

Gets details of a single BackupPlanRevision.

Parameters
Name Description
name string

Required. The resource name of the BackupPlanRevision to retrieve.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}/revisions/{revision}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBackupPlanRevision

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlans/[BACKUP_PLAN]/revisions/[REVISION]";
// Make the request
BackupPlanRevision response = await backupDRClient.GetBackupPlanRevisionAsync(name);

GetBackupPlanRevisionAsync(string, CancellationToken)

public virtual Task<BackupPlanRevision> GetBackupPlanRevisionAsync(string name, CancellationToken cancellationToken)

Gets details of a single BackupPlanRevision.

Parameters
Name Description
name string

Required. The resource name of the BackupPlanRevision to retrieve.

Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}/revisions/{revision}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBackupPlanRevision

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlans/[BACKUP_PLAN]/revisions/[REVISION]";
// Make the request
BackupPlanRevision response = await backupDRClient.GetBackupPlanRevisionAsync(name);

GetBackupVault(BackupVaultName, CallSettings)

public virtual BackupVault GetBackupVault(BackupVaultName name, CallSettings callSettings = null)

Gets details of a BackupVault.

Parameters
Name Description
name BackupVaultName

Required. Name of the backupvault store resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{resource_name}'

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
BackupVault

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BackupVaultName name = BackupVaultName.FromProjectLocationBackupvault("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]");
// Make the request
BackupVault response = backupDRClient.GetBackupVault(name);

GetBackupVault(GetBackupVaultRequest, CallSettings)

public virtual BackupVault GetBackupVault(GetBackupVaultRequest request, CallSettings callSettings = null)

Gets details of a BackupVault.

Parameters
Name Description
request GetBackupVaultRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
BackupVault

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
GetBackupVaultRequest request = new GetBackupVaultRequest
{
    BackupVaultName = BackupVaultName.FromProjectLocationBackupvault("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]"),
    View = BackupVaultView.Unspecified,
};
// Make the request
BackupVault response = backupDRClient.GetBackupVault(request);

GetBackupVault(string, CallSettings)

public virtual BackupVault GetBackupVault(string name, CallSettings callSettings = null)

Gets details of a BackupVault.

Parameters
Name Description
name string

Required. Name of the backupvault store resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{resource_name}'

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
BackupVault

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]";
// Make the request
BackupVault response = backupDRClient.GetBackupVault(name);

GetBackupVaultAsync(BackupVaultName, CallSettings)

public virtual Task<BackupVault> GetBackupVaultAsync(BackupVaultName name, CallSettings callSettings = null)

Gets details of a BackupVault.

Parameters
Name Description
name BackupVaultName

Required. Name of the backupvault store resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{resource_name}'

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBackupVault

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupVaultName name = BackupVaultName.FromProjectLocationBackupvault("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]");
// Make the request
BackupVault response = await backupDRClient.GetBackupVaultAsync(name);

GetBackupVaultAsync(BackupVaultName, CancellationToken)

public virtual Task<BackupVault> GetBackupVaultAsync(BackupVaultName name, CancellationToken cancellationToken)

Gets details of a BackupVault.

Parameters
Name Description
name BackupVaultName

Required. Name of the backupvault store resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{resource_name}'

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBackupVault

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupVaultName name = BackupVaultName.FromProjectLocationBackupvault("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]");
// Make the request
BackupVault response = await backupDRClient.GetBackupVaultAsync(name);

GetBackupVaultAsync(GetBackupVaultRequest, CallSettings)

public virtual Task<BackupVault> GetBackupVaultAsync(GetBackupVaultRequest request, CallSettings callSettings = null)

Gets details of a BackupVault.

Parameters
Name Description
request GetBackupVaultRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBackupVault

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetBackupVaultRequest request = new GetBackupVaultRequest
{
    BackupVaultName = BackupVaultName.FromProjectLocationBackupvault("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]"),
    View = BackupVaultView.Unspecified,
};
// Make the request
BackupVault response = await backupDRClient.GetBackupVaultAsync(request);

GetBackupVaultAsync(GetBackupVaultRequest, CancellationToken)

public virtual Task<BackupVault> GetBackupVaultAsync(GetBackupVaultRequest request, CancellationToken cancellationToken)

Gets details of a BackupVault.

Parameters
Name Description
request GetBackupVaultRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBackupVault

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetBackupVaultRequest request = new GetBackupVaultRequest
{
    BackupVaultName = BackupVaultName.FromProjectLocationBackupvault("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]"),
    View = BackupVaultView.Unspecified,
};
// Make the request
BackupVault response = await backupDRClient.GetBackupVaultAsync(request);

GetBackupVaultAsync(string, CallSettings)

public virtual Task<BackupVault> GetBackupVaultAsync(string name, CallSettings callSettings = null)

Gets details of a BackupVault.

Parameters
Name Description
name string

Required. Name of the backupvault store resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{resource_name}'

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBackupVault

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]";
// Make the request
BackupVault response = await backupDRClient.GetBackupVaultAsync(name);

GetBackupVaultAsync(string, CancellationToken)

public virtual Task<BackupVault> GetBackupVaultAsync(string name, CancellationToken cancellationToken)

Gets details of a BackupVault.

Parameters
Name Description
name string

Required. Name of the backupvault store resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{resource_name}'

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBackupVault

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]";
// Make the request
BackupVault response = await backupDRClient.GetBackupVaultAsync(name);

GetBindingMatchingResource(BindingMatchingResourceName, CallSettings)

public virtual BindingMatchingResource GetBindingMatchingResource(BindingMatchingResourceName name, CallSettings callSettings = null)

Gets details of a single Binding Matching Resource.

Parameters
Name Description
name BindingMatchingResourceName

Required. The name of the matching resource to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}/matchingResources/{matching_resource}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
BindingMatchingResource

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BindingMatchingResourceName name = BindingMatchingResourceName.FromProjectLocationAutoProtectionPolicyBindingMatchingResource("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]", "[MATCHING_RESOURCE]");
// Make the request
BindingMatchingResource response = backupDRClient.GetBindingMatchingResource(name);

GetBindingMatchingResource(GetBindingMatchingResourceRequest, CallSettings)

public virtual BindingMatchingResource GetBindingMatchingResource(GetBindingMatchingResourceRequest request, CallSettings callSettings = null)

Gets details of a single Binding Matching Resource.

Parameters
Name Description
request GetBindingMatchingResourceRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
BindingMatchingResource

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
GetBindingMatchingResourceRequest request = new GetBindingMatchingResourceRequest
{
    BindingMatchingResourceName = BindingMatchingResourceName.FromProjectLocationAutoProtectionPolicyBindingMatchingResource("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]", "[MATCHING_RESOURCE]"),
};
// Make the request
BindingMatchingResource response = backupDRClient.GetBindingMatchingResource(request);

GetBindingMatchingResource(string, CallSettings)

public virtual BindingMatchingResource GetBindingMatchingResource(string name, CallSettings callSettings = null)

Gets details of a single Binding Matching Resource.

Parameters
Name Description
name string

Required. The name of the matching resource to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}/matchingResources/{matching_resource}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
BindingMatchingResource

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]/bindings/[BINDING]/matchingResources/[MATCHING_RESOURCE]";
// Make the request
BindingMatchingResource response = backupDRClient.GetBindingMatchingResource(name);

GetBindingMatchingResourceAsync(BindingMatchingResourceName, CallSettings)

public virtual Task<BindingMatchingResource> GetBindingMatchingResourceAsync(BindingMatchingResourceName name, CallSettings callSettings = null)

Gets details of a single Binding Matching Resource.

Parameters
Name Description
name BindingMatchingResourceName

Required. The name of the matching resource to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}/matchingResources/{matching_resource}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBindingMatchingResource

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BindingMatchingResourceName name = BindingMatchingResourceName.FromProjectLocationAutoProtectionPolicyBindingMatchingResource("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]", "[MATCHING_RESOURCE]");
// Make the request
BindingMatchingResource response = await backupDRClient.GetBindingMatchingResourceAsync(name);

GetBindingMatchingResourceAsync(BindingMatchingResourceName, CancellationToken)

public virtual Task<BindingMatchingResource> GetBindingMatchingResourceAsync(BindingMatchingResourceName name, CancellationToken cancellationToken)

Gets details of a single Binding Matching Resource.

Parameters
Name Description
name BindingMatchingResourceName

Required. The name of the matching resource to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}/matchingResources/{matching_resource}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBindingMatchingResource

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BindingMatchingResourceName name = BindingMatchingResourceName.FromProjectLocationAutoProtectionPolicyBindingMatchingResource("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]", "[MATCHING_RESOURCE]");
// Make the request
BindingMatchingResource response = await backupDRClient.GetBindingMatchingResourceAsync(name);

GetBindingMatchingResourceAsync(GetBindingMatchingResourceRequest, CallSettings)

public virtual Task<BindingMatchingResource> GetBindingMatchingResourceAsync(GetBindingMatchingResourceRequest request, CallSettings callSettings = null)

Gets details of a single Binding Matching Resource.

Parameters
Name Description
request GetBindingMatchingResourceRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBindingMatchingResource

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetBindingMatchingResourceRequest request = new GetBindingMatchingResourceRequest
{
    BindingMatchingResourceName = BindingMatchingResourceName.FromProjectLocationAutoProtectionPolicyBindingMatchingResource("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]", "[MATCHING_RESOURCE]"),
};
// Make the request
BindingMatchingResource response = await backupDRClient.GetBindingMatchingResourceAsync(request);

GetBindingMatchingResourceAsync(GetBindingMatchingResourceRequest, CancellationToken)

public virtual Task<BindingMatchingResource> GetBindingMatchingResourceAsync(GetBindingMatchingResourceRequest request, CancellationToken cancellationToken)

Gets details of a single Binding Matching Resource.

Parameters
Name Description
request GetBindingMatchingResourceRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBindingMatchingResource

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetBindingMatchingResourceRequest request = new GetBindingMatchingResourceRequest
{
    BindingMatchingResourceName = BindingMatchingResourceName.FromProjectLocationAutoProtectionPolicyBindingMatchingResource("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]", "[MATCHING_RESOURCE]"),
};
// Make the request
BindingMatchingResource response = await backupDRClient.GetBindingMatchingResourceAsync(request);

GetBindingMatchingResourceAsync(string, CallSettings)

public virtual Task<BindingMatchingResource> GetBindingMatchingResourceAsync(string name, CallSettings callSettings = null)

Gets details of a single Binding Matching Resource.

Parameters
Name Description
name string

Required. The name of the matching resource to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}/matchingResources/{matching_resource}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskBindingMatchingResource

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]/bindings/[BINDING]/matchingResources/[MATCHING_RESOURCE]";
// Make the request
BindingMatchingResource response = await backupDRClient.GetBindingMatchingResourceAsync(name);

GetBindingMatchingResourceAsync(string, CancellationToken)

public virtual Task<BindingMatchingResource> GetBindingMatchingResourceAsync(string name, CancellationToken cancellationToken)

Gets details of a single Binding Matching Resource.

Parameters
Name Description
name string

Required. The name of the matching resource to retrieve. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}/matchingResources/{matching_resource}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskBindingMatchingResource

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]/bindings/[BINDING]/matchingResources/[MATCHING_RESOURCE]";
// Make the request
BindingMatchingResource response = await backupDRClient.GetBindingMatchingResourceAsync(name);

GetDataSource(DataSourceName, CallSettings)

public virtual DataSource GetDataSource(DataSourceName name, CallSettings callSettings = null)

Gets details of a DataSource.

Parameters
Name Description
name DataSourceName

Required. Name of the data source resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{resource_name}/dataSource/{resource_name}'

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
DataSource

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
DataSourceName name = DataSourceName.FromProjectLocationBackupvaultDatasource("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]");
// Make the request
DataSource response = backupDRClient.GetDataSource(name);

GetDataSource(GetDataSourceRequest, CallSettings)

public virtual DataSource GetDataSource(GetDataSourceRequest request, CallSettings callSettings = null)

Gets details of a DataSource.

Parameters
Name Description
request GetDataSourceRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
DataSource

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
GetDataSourceRequest request = new GetDataSourceRequest
{
    DataSourceName = DataSourceName.FromProjectLocationBackupvaultDatasource("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]"),
};
// Make the request
DataSource response = backupDRClient.GetDataSource(request);

GetDataSource(string, CallSettings)

public virtual DataSource GetDataSource(string name, CallSettings callSettings = null)

Gets details of a DataSource.

Parameters
Name Description
name string

Required. Name of the data source resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{resource_name}/dataSource/{resource_name}'

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
DataSource

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]/dataSources/[DATASOURCE]";
// Make the request
DataSource response = backupDRClient.GetDataSource(name);

GetDataSourceAsync(DataSourceName, CallSettings)

public virtual Task<DataSource> GetDataSourceAsync(DataSourceName name, CallSettings callSettings = null)

Gets details of a DataSource.

Parameters
Name Description
name DataSourceName

Required. Name of the data source resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{resource_name}/dataSource/{resource_name}'

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskDataSource

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DataSourceName name = DataSourceName.FromProjectLocationBackupvaultDatasource("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]");
// Make the request
DataSource response = await backupDRClient.GetDataSourceAsync(name);

GetDataSourceAsync(DataSourceName, CancellationToken)

public virtual Task<DataSource> GetDataSourceAsync(DataSourceName name, CancellationToken cancellationToken)

Gets details of a DataSource.

Parameters
Name Description
name DataSourceName

Required. Name of the data source resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{resource_name}/dataSource/{resource_name}'

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskDataSource

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DataSourceName name = DataSourceName.FromProjectLocationBackupvaultDatasource("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]");
// Make the request
DataSource response = await backupDRClient.GetDataSourceAsync(name);

GetDataSourceAsync(GetDataSourceRequest, CallSettings)

public virtual Task<DataSource> GetDataSourceAsync(GetDataSourceRequest request, CallSettings callSettings = null)

Gets details of a DataSource.

Parameters
Name Description
request GetDataSourceRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskDataSource

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetDataSourceRequest request = new GetDataSourceRequest
{
    DataSourceName = DataSourceName.FromProjectLocationBackupvaultDatasource("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]"),
};
// Make the request
DataSource response = await backupDRClient.GetDataSourceAsync(request);

GetDataSourceAsync(GetDataSourceRequest, CancellationToken)

public virtual Task<DataSource> GetDataSourceAsync(GetDataSourceRequest request, CancellationToken cancellationToken)

Gets details of a DataSource.

Parameters
Name Description
request GetDataSourceRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskDataSource

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetDataSourceRequest request = new GetDataSourceRequest
{
    DataSourceName = DataSourceName.FromProjectLocationBackupvaultDatasource("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]"),
};
// Make the request
DataSource response = await backupDRClient.GetDataSourceAsync(request);

GetDataSourceAsync(string, CallSettings)

public virtual Task<DataSource> GetDataSourceAsync(string name, CallSettings callSettings = null)

Gets details of a DataSource.

Parameters
Name Description
name string

Required. Name of the data source resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{resource_name}/dataSource/{resource_name}'

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskDataSource

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]/dataSources/[DATASOURCE]";
// Make the request
DataSource response = await backupDRClient.GetDataSourceAsync(name);

GetDataSourceAsync(string, CancellationToken)

public virtual Task<DataSource> GetDataSourceAsync(string name, CancellationToken cancellationToken)

Gets details of a DataSource.

Parameters
Name Description
name string

Required. Name of the data source resource name, in the format 'projects/{project_id}/locations/{location}/backupVaults/{resource_name}/dataSource/{resource_name}'

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskDataSource

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]/dataSources/[DATASOURCE]";
// Make the request
DataSource response = await backupDRClient.GetDataSourceAsync(name);

GetDataSourceReference(DataSourceReferenceName, CallSettings)

public virtual DataSourceReference GetDataSourceReference(DataSourceReferenceName name, CallSettings callSettings = null)

Gets details of a single DataSourceReference.

Parameters
Name Description
name DataSourceReferenceName

Required. The name of the DataSourceReference to retrieve. Format: projects/{project}/locations/{location}/dataSourceReferences/{data_source_reference}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
DataSourceReference

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
DataSourceReferenceName name = DataSourceReferenceName.FromProjectLocationDataSourceReference("[PROJECT]", "[LOCATION]", "[DATA_SOURCE_REFERENCE]");
// Make the request
DataSourceReference response = backupDRClient.GetDataSourceReference(name);

GetDataSourceReference(GetDataSourceReferenceRequest, CallSettings)

public virtual DataSourceReference GetDataSourceReference(GetDataSourceReferenceRequest request, CallSettings callSettings = null)

Gets details of a single DataSourceReference.

Parameters
Name Description
request GetDataSourceReferenceRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
DataSourceReference

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
GetDataSourceReferenceRequest request = new GetDataSourceReferenceRequest
{
    DataSourceReferenceName = DataSourceReferenceName.FromProjectLocationDataSourceReference("[PROJECT]", "[LOCATION]", "[DATA_SOURCE_REFERENCE]"),
};
// Make the request
DataSourceReference response = backupDRClient.GetDataSourceReference(request);

GetDataSourceReference(string, CallSettings)

public virtual DataSourceReference GetDataSourceReference(string name, CallSettings callSettings = null)

Gets details of a single DataSourceReference.

Parameters
Name Description
name string

Required. The name of the DataSourceReference to retrieve. Format: projects/{project}/locations/{location}/dataSourceReferences/{data_source_reference}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
DataSourceReference

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/dataSourceReferences/[DATA_SOURCE_REFERENCE]";
// Make the request
DataSourceReference response = backupDRClient.GetDataSourceReference(name);

GetDataSourceReferenceAsync(DataSourceReferenceName, CallSettings)

public virtual Task<DataSourceReference> GetDataSourceReferenceAsync(DataSourceReferenceName name, CallSettings callSettings = null)

Gets details of a single DataSourceReference.

Parameters
Name Description
name DataSourceReferenceName

Required. The name of the DataSourceReference to retrieve. Format: projects/{project}/locations/{location}/dataSourceReferences/{data_source_reference}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskDataSourceReference

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DataSourceReferenceName name = DataSourceReferenceName.FromProjectLocationDataSourceReference("[PROJECT]", "[LOCATION]", "[DATA_SOURCE_REFERENCE]");
// Make the request
DataSourceReference response = await backupDRClient.GetDataSourceReferenceAsync(name);

GetDataSourceReferenceAsync(DataSourceReferenceName, CancellationToken)

public virtual Task<DataSourceReference> GetDataSourceReferenceAsync(DataSourceReferenceName name, CancellationToken cancellationToken)

Gets details of a single DataSourceReference.

Parameters
Name Description
name DataSourceReferenceName

Required. The name of the DataSourceReference to retrieve. Format: projects/{project}/locations/{location}/dataSourceReferences/{data_source_reference}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskDataSourceReference

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DataSourceReferenceName name = DataSourceReferenceName.FromProjectLocationDataSourceReference("[PROJECT]", "[LOCATION]", "[DATA_SOURCE_REFERENCE]");
// Make the request
DataSourceReference response = await backupDRClient.GetDataSourceReferenceAsync(name);

GetDataSourceReferenceAsync(GetDataSourceReferenceRequest, CallSettings)

public virtual Task<DataSourceReference> GetDataSourceReferenceAsync(GetDataSourceReferenceRequest request, CallSettings callSettings = null)

Gets details of a single DataSourceReference.

Parameters
Name Description
request GetDataSourceReferenceRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskDataSourceReference

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetDataSourceReferenceRequest request = new GetDataSourceReferenceRequest
{
    DataSourceReferenceName = DataSourceReferenceName.FromProjectLocationDataSourceReference("[PROJECT]", "[LOCATION]", "[DATA_SOURCE_REFERENCE]"),
};
// Make the request
DataSourceReference response = await backupDRClient.GetDataSourceReferenceAsync(request);

GetDataSourceReferenceAsync(GetDataSourceReferenceRequest, CancellationToken)

public virtual Task<DataSourceReference> GetDataSourceReferenceAsync(GetDataSourceReferenceRequest request, CancellationToken cancellationToken)

Gets details of a single DataSourceReference.

Parameters
Name Description
request GetDataSourceReferenceRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskDataSourceReference

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetDataSourceReferenceRequest request = new GetDataSourceReferenceRequest
{
    DataSourceReferenceName = DataSourceReferenceName.FromProjectLocationDataSourceReference("[PROJECT]", "[LOCATION]", "[DATA_SOURCE_REFERENCE]"),
};
// Make the request
DataSourceReference response = await backupDRClient.GetDataSourceReferenceAsync(request);

GetDataSourceReferenceAsync(string, CallSettings)

public virtual Task<DataSourceReference> GetDataSourceReferenceAsync(string name, CallSettings callSettings = null)

Gets details of a single DataSourceReference.

Parameters
Name Description
name string

Required. The name of the DataSourceReference to retrieve. Format: projects/{project}/locations/{location}/dataSourceReferences/{data_source_reference}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskDataSourceReference

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/dataSourceReferences/[DATA_SOURCE_REFERENCE]";
// Make the request
DataSourceReference response = await backupDRClient.GetDataSourceReferenceAsync(name);

GetDataSourceReferenceAsync(string, CancellationToken)

public virtual Task<DataSourceReference> GetDataSourceReferenceAsync(string name, CancellationToken cancellationToken)

Gets details of a single DataSourceReference.

Parameters
Name Description
name string

Required. The name of the DataSourceReference to retrieve. Format: projects/{project}/locations/{location}/dataSourceReferences/{data_source_reference}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskDataSourceReference

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/dataSourceReferences/[DATA_SOURCE_REFERENCE]";
// Make the request
DataSourceReference response = await backupDRClient.GetDataSourceReferenceAsync(name);

GetManagementServer(GetManagementServerRequest, CallSettings)

public virtual ManagementServer GetManagementServer(GetManagementServerRequest request, CallSettings callSettings = null)

Gets details of a single ManagementServer.

Parameters
Name Description
request GetManagementServerRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
ManagementServer

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
GetManagementServerRequest request = new GetManagementServerRequest
{
    ManagementServerName = ManagementServerName.FromProjectLocationManagementserver("[PROJECT]", "[LOCATION]", "[MANAGEMENTSERVER]"),
};
// Make the request
ManagementServer response = backupDRClient.GetManagementServer(request);

GetManagementServer(ManagementServerName, CallSettings)

public virtual ManagementServer GetManagementServer(ManagementServerName name, CallSettings callSettings = null)

Gets details of a single ManagementServer.

Parameters
Name Description
name ManagementServerName

Required. Name of the management server resource name, in the format 'projects/{project_id}/locations/{location}/managementServers/{resource_name}'

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
ManagementServer

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
ManagementServerName name = ManagementServerName.FromProjectLocationManagementserver("[PROJECT]", "[LOCATION]", "[MANAGEMENTSERVER]");
// Make the request
ManagementServer response = backupDRClient.GetManagementServer(name);

GetManagementServer(string, CallSettings)

public virtual ManagementServer GetManagementServer(string name, CallSettings callSettings = null)

Gets details of a single ManagementServer.

Parameters
Name Description
name string

Required. Name of the management server resource name, in the format 'projects/{project_id}/locations/{location}/managementServers/{resource_name}'

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
ManagementServer

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/managementServers/[MANAGEMENTSERVER]";
// Make the request
ManagementServer response = backupDRClient.GetManagementServer(name);

GetManagementServerAsync(GetManagementServerRequest, CallSettings)

public virtual Task<ManagementServer> GetManagementServerAsync(GetManagementServerRequest request, CallSettings callSettings = null)

Gets details of a single ManagementServer.

Parameters
Name Description
request GetManagementServerRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskManagementServer

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetManagementServerRequest request = new GetManagementServerRequest
{
    ManagementServerName = ManagementServerName.FromProjectLocationManagementserver("[PROJECT]", "[LOCATION]", "[MANAGEMENTSERVER]"),
};
// Make the request
ManagementServer response = await backupDRClient.GetManagementServerAsync(request);

GetManagementServerAsync(GetManagementServerRequest, CancellationToken)

public virtual Task<ManagementServer> GetManagementServerAsync(GetManagementServerRequest request, CancellationToken cancellationToken)

Gets details of a single ManagementServer.

Parameters
Name Description
request GetManagementServerRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskManagementServer

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
GetManagementServerRequest request = new GetManagementServerRequest
{
    ManagementServerName = ManagementServerName.FromProjectLocationManagementserver("[PROJECT]", "[LOCATION]", "[MANAGEMENTSERVER]"),
};
// Make the request
ManagementServer response = await backupDRClient.GetManagementServerAsync(request);

GetManagementServerAsync(ManagementServerName, CallSettings)

public virtual Task<ManagementServer> GetManagementServerAsync(ManagementServerName name, CallSettings callSettings = null)

Gets details of a single ManagementServer.

Parameters
Name Description
name ManagementServerName

Required. Name of the management server resource name, in the format 'projects/{project_id}/locations/{location}/managementServers/{resource_name}'

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskManagementServer

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
ManagementServerName name = ManagementServerName.FromProjectLocationManagementserver("[PROJECT]", "[LOCATION]", "[MANAGEMENTSERVER]");
// Make the request
ManagementServer response = await backupDRClient.GetManagementServerAsync(name);

GetManagementServerAsync(ManagementServerName, CancellationToken)

public virtual Task<ManagementServer> GetManagementServerAsync(ManagementServerName name, CancellationToken cancellationToken)

Gets details of a single ManagementServer.

Parameters
Name Description
name ManagementServerName

Required. Name of the management server resource name, in the format 'projects/{project_id}/locations/{location}/managementServers/{resource_name}'

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskManagementServer

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
ManagementServerName name = ManagementServerName.FromProjectLocationManagementserver("[PROJECT]", "[LOCATION]", "[MANAGEMENTSERVER]");
// Make the request
ManagementServer response = await backupDRClient.GetManagementServerAsync(name);

GetManagementServerAsync(string, CallSettings)

public virtual Task<ManagementServer> GetManagementServerAsync(string name, CallSettings callSettings = null)

Gets details of a single ManagementServer.

Parameters
Name Description
name string

Required. Name of the management server resource name, in the format 'projects/{project_id}/locations/{location}/managementServers/{resource_name}'

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskManagementServer

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/managementServers/[MANAGEMENTSERVER]";
// Make the request
ManagementServer response = await backupDRClient.GetManagementServerAsync(name);

GetManagementServerAsync(string, CancellationToken)

public virtual Task<ManagementServer> GetManagementServerAsync(string name, CancellationToken cancellationToken)

Gets details of a single ManagementServer.

Parameters
Name Description
name string

Required. Name of the management server resource name, in the format 'projects/{project_id}/locations/{location}/managementServers/{resource_name}'

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskManagementServer

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/managementServers/[MANAGEMENTSERVER]";
// Make the request
ManagementServer response = await backupDRClient.GetManagementServerAsync(name);

InitializeService(InitializeServiceRequest, CallSettings)

public virtual Operation<InitializeServiceResponse, OperationMetadata> InitializeService(InitializeServiceRequest request, CallSettings callSettings = null)

Initializes the service related config for a project.

Parameters
Name Description
request InitializeServiceRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationInitializeServiceResponseOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
InitializeServiceRequest request = new InitializeServiceRequest
{
    Name = "",
    ResourceType = "",
    RequestId = "",
    CloudSqlInstanceInitializationConfig = new CloudSqlInstanceInitializationConfig(),
    BackupPlanLocation = "",
    ValidateOnly = false,
};
// Make the request
Operation<InitializeServiceResponse, OperationMetadata> response = backupDRClient.InitializeService(request);

// Poll until the returned long-running operation is complete
Operation<InitializeServiceResponse, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
InitializeServiceResponse result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<InitializeServiceResponse, OperationMetadata> retrievedResponse = backupDRClient.PollOnceInitializeService(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    InitializeServiceResponse retrievedResult = retrievedResponse.Result;
}

InitializeServiceAsync(InitializeServiceRequest, CallSettings)

public virtual Task<Operation<InitializeServiceResponse, OperationMetadata>> InitializeServiceAsync(InitializeServiceRequest request, CallSettings callSettings = null)

Initializes the service related config for a project.

Parameters
Name Description
request InitializeServiceRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationInitializeServiceResponseOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
InitializeServiceRequest request = new InitializeServiceRequest
{
    Name = "",
    ResourceType = "",
    RequestId = "",
    CloudSqlInstanceInitializationConfig = new CloudSqlInstanceInitializationConfig(),
    BackupPlanLocation = "",
    ValidateOnly = false,
};
// Make the request
Operation<InitializeServiceResponse, OperationMetadata> response = await backupDRClient.InitializeServiceAsync(request);

// Poll until the returned long-running operation is complete
Operation<InitializeServiceResponse, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
InitializeServiceResponse result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<InitializeServiceResponse, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceInitializeServiceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    InitializeServiceResponse retrievedResult = retrievedResponse.Result;
}

InitializeServiceAsync(InitializeServiceRequest, CancellationToken)

public virtual Task<Operation<InitializeServiceResponse, OperationMetadata>> InitializeServiceAsync(InitializeServiceRequest request, CancellationToken cancellationToken)

Initializes the service related config for a project.

Parameters
Name Description
request InitializeServiceRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationInitializeServiceResponseOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
InitializeServiceRequest request = new InitializeServiceRequest
{
    Name = "",
    ResourceType = "",
    RequestId = "",
    CloudSqlInstanceInitializationConfig = new CloudSqlInstanceInitializationConfig(),
    BackupPlanLocation = "",
    ValidateOnly = false,
};
// Make the request
Operation<InitializeServiceResponse, OperationMetadata> response = await backupDRClient.InitializeServiceAsync(request);

// Poll until the returned long-running operation is complete
Operation<InitializeServiceResponse, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
InitializeServiceResponse result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<InitializeServiceResponse, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceInitializeServiceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    InitializeServiceResponse retrievedResult = retrievedResponse.Result;
}

InitiateDeleteAutoProtectionPolicyBinding(AutoProtectionPolicyBindingName, CallSettings)

public virtual Operation<AutoProtectionPolicyBinding, OperationMetadata> InitiateDeleteAutoProtectionPolicyBinding(AutoProtectionPolicyBindingName name, CallSettings callSettings = null)

InitiateDeleteAutoProtectionPolicyBinding initiates delete for AutoProtectionPolicy Binding

Parameters
Name Description
name AutoProtectionPolicyBindingName

Required. The name of the binding to delete. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationAutoProtectionPolicyBindingOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
AutoProtectionPolicyBindingName name = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]");
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = backupDRClient.InitiateDeleteAutoProtectionPolicyBinding(name);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = backupDRClient.PollOnceInitiateDeleteAutoProtectionPolicyBinding(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

InitiateDeleteAutoProtectionPolicyBinding(InitiateDeleteAutoProtectionPolicyBindingRequest, CallSettings)

public virtual Operation<AutoProtectionPolicyBinding, OperationMetadata> InitiateDeleteAutoProtectionPolicyBinding(InitiateDeleteAutoProtectionPolicyBindingRequest request, CallSettings callSettings = null)

InitiateDeleteAutoProtectionPolicyBinding initiates delete for AutoProtectionPolicy Binding

Parameters
Name Description
request InitiateDeleteAutoProtectionPolicyBindingRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationAutoProtectionPolicyBindingOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
InitiateDeleteAutoProtectionPolicyBindingRequest request = new InitiateDeleteAutoProtectionPolicyBindingRequest
{
    AutoProtectionPolicyBindingName = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]"),
};
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = backupDRClient.InitiateDeleteAutoProtectionPolicyBinding(request);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = backupDRClient.PollOnceInitiateDeleteAutoProtectionPolicyBinding(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

InitiateDeleteAutoProtectionPolicyBinding(string, CallSettings)

public virtual Operation<AutoProtectionPolicyBinding, OperationMetadata> InitiateDeleteAutoProtectionPolicyBinding(string name, CallSettings callSettings = null)

InitiateDeleteAutoProtectionPolicyBinding initiates delete for AutoProtectionPolicy Binding

Parameters
Name Description
name string

Required. The name of the binding to delete. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationAutoProtectionPolicyBindingOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]/bindings/[BINDING]";
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = backupDRClient.InitiateDeleteAutoProtectionPolicyBinding(name);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = backupDRClient.PollOnceInitiateDeleteAutoProtectionPolicyBinding(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

InitiateDeleteAutoProtectionPolicyBindingAsync(AutoProtectionPolicyBindingName, CallSettings)

public virtual Task<Operation<AutoProtectionPolicyBinding, OperationMetadata>> InitiateDeleteAutoProtectionPolicyBindingAsync(AutoProtectionPolicyBindingName name, CallSettings callSettings = null)

InitiateDeleteAutoProtectionPolicyBinding initiates delete for AutoProtectionPolicy Binding

Parameters
Name Description
name AutoProtectionPolicyBindingName

Required. The name of the binding to delete. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationAutoProtectionPolicyBindingOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
AutoProtectionPolicyBindingName name = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]");
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = await backupDRClient.InitiateDeleteAutoProtectionPolicyBindingAsync(name);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceInitiateDeleteAutoProtectionPolicyBindingAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

InitiateDeleteAutoProtectionPolicyBindingAsync(AutoProtectionPolicyBindingName, CancellationToken)

public virtual Task<Operation<AutoProtectionPolicyBinding, OperationMetadata>> InitiateDeleteAutoProtectionPolicyBindingAsync(AutoProtectionPolicyBindingName name, CancellationToken cancellationToken)

InitiateDeleteAutoProtectionPolicyBinding initiates delete for AutoProtectionPolicy Binding

Parameters
Name Description
name AutoProtectionPolicyBindingName

Required. The name of the binding to delete. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationAutoProtectionPolicyBindingOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
AutoProtectionPolicyBindingName name = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]");
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = await backupDRClient.InitiateDeleteAutoProtectionPolicyBindingAsync(name);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceInitiateDeleteAutoProtectionPolicyBindingAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

InitiateDeleteAutoProtectionPolicyBindingAsync(InitiateDeleteAutoProtectionPolicyBindingRequest, CallSettings)

public virtual Task<Operation<AutoProtectionPolicyBinding, OperationMetadata>> InitiateDeleteAutoProtectionPolicyBindingAsync(InitiateDeleteAutoProtectionPolicyBindingRequest request, CallSettings callSettings = null)

InitiateDeleteAutoProtectionPolicyBinding initiates delete for AutoProtectionPolicy Binding

Parameters
Name Description
request InitiateDeleteAutoProtectionPolicyBindingRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationAutoProtectionPolicyBindingOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
InitiateDeleteAutoProtectionPolicyBindingRequest request = new InitiateDeleteAutoProtectionPolicyBindingRequest
{
    AutoProtectionPolicyBindingName = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]"),
};
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = await backupDRClient.InitiateDeleteAutoProtectionPolicyBindingAsync(request);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceInitiateDeleteAutoProtectionPolicyBindingAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

InitiateDeleteAutoProtectionPolicyBindingAsync(InitiateDeleteAutoProtectionPolicyBindingRequest, CancellationToken)

public virtual Task<Operation<AutoProtectionPolicyBinding, OperationMetadata>> InitiateDeleteAutoProtectionPolicyBindingAsync(InitiateDeleteAutoProtectionPolicyBindingRequest request, CancellationToken cancellationToken)

InitiateDeleteAutoProtectionPolicyBinding initiates delete for AutoProtectionPolicy Binding

Parameters
Name Description
request InitiateDeleteAutoProtectionPolicyBindingRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationAutoProtectionPolicyBindingOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
InitiateDeleteAutoProtectionPolicyBindingRequest request = new InitiateDeleteAutoProtectionPolicyBindingRequest
{
    AutoProtectionPolicyBindingName = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]"),
};
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = await backupDRClient.InitiateDeleteAutoProtectionPolicyBindingAsync(request);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceInitiateDeleteAutoProtectionPolicyBindingAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

InitiateDeleteAutoProtectionPolicyBindingAsync(string, CallSettings)

public virtual Task<Operation<AutoProtectionPolicyBinding, OperationMetadata>> InitiateDeleteAutoProtectionPolicyBindingAsync(string name, CallSettings callSettings = null)

InitiateDeleteAutoProtectionPolicyBinding initiates delete for AutoProtectionPolicy Binding

Parameters
Name Description
name string

Required. The name of the binding to delete. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationAutoProtectionPolicyBindingOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]/bindings/[BINDING]";
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = await backupDRClient.InitiateDeleteAutoProtectionPolicyBindingAsync(name);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceInitiateDeleteAutoProtectionPolicyBindingAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

InitiateDeleteAutoProtectionPolicyBindingAsync(string, CancellationToken)

public virtual Task<Operation<AutoProtectionPolicyBinding, OperationMetadata>> InitiateDeleteAutoProtectionPolicyBindingAsync(string name, CancellationToken cancellationToken)

InitiateDeleteAutoProtectionPolicyBinding initiates delete for AutoProtectionPolicy Binding

Parameters
Name Description
name string

Required. The name of the binding to delete. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationAutoProtectionPolicyBindingOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]/bindings/[BINDING]";
// Make the request
Operation<AutoProtectionPolicyBinding, OperationMetadata> response = await backupDRClient.InitiateDeleteAutoProtectionPolicyBindingAsync(name);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicyBinding, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicyBinding result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicyBinding, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceInitiateDeleteAutoProtectionPolicyBindingAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicyBinding retrievedResult = retrievedResponse.Result;
}

ListAppliedAutoProtectionPolicies(LocationName, string, int?, CallSettings)

public virtual PagedEnumerable<ListAppliedAutoProtectionPoliciesResponse, AppliedAutoProtectionPolicy> ListAppliedAutoProtectionPolicies(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists AppliedAutoProtectionPolicies in a given project and location.

Parameters
Name Description
parent LocationName

Required. The project and location for which to retrieve the list of applied policies. Format: projects/{project}/locations/{location}

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListAppliedAutoProtectionPoliciesResponseAppliedAutoProtectionPolicy

A pageable sequence of AppliedAutoProtectionPolicy resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedEnumerable<ListAppliedAutoProtectionPoliciesResponse, AppliedAutoProtectionPolicy> response = backupDRClient.ListAppliedAutoProtectionPolicies(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (AppliedAutoProtectionPolicy item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListAppliedAutoProtectionPoliciesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AppliedAutoProtectionPolicy item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AppliedAutoProtectionPolicy> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AppliedAutoProtectionPolicy item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAppliedAutoProtectionPolicies(ListAppliedAutoProtectionPoliciesRequest, CallSettings)

public virtual PagedEnumerable<ListAppliedAutoProtectionPoliciesResponse, AppliedAutoProtectionPolicy> ListAppliedAutoProtectionPolicies(ListAppliedAutoProtectionPoliciesRequest request, CallSettings callSettings = null)

Lists AppliedAutoProtectionPolicies in a given project and location.

Parameters
Name Description
request ListAppliedAutoProtectionPoliciesRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListAppliedAutoProtectionPoliciesResponseAppliedAutoProtectionPolicy

A pageable sequence of AppliedAutoProtectionPolicy resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
ListAppliedAutoProtectionPoliciesRequest request = new ListAppliedAutoProtectionPoliciesRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedEnumerable<ListAppliedAutoProtectionPoliciesResponse, AppliedAutoProtectionPolicy> response = backupDRClient.ListAppliedAutoProtectionPolicies(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (AppliedAutoProtectionPolicy item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListAppliedAutoProtectionPoliciesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AppliedAutoProtectionPolicy item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AppliedAutoProtectionPolicy> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AppliedAutoProtectionPolicy item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAppliedAutoProtectionPolicies(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListAppliedAutoProtectionPoliciesResponse, AppliedAutoProtectionPolicy> ListAppliedAutoProtectionPolicies(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists AppliedAutoProtectionPolicies in a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve the list of applied policies. Format: projects/{project}/locations/{location}

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListAppliedAutoProtectionPoliciesResponseAppliedAutoProtectionPolicy

A pageable sequence of AppliedAutoProtectionPolicy resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedEnumerable<ListAppliedAutoProtectionPoliciesResponse, AppliedAutoProtectionPolicy> response = backupDRClient.ListAppliedAutoProtectionPolicies(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (AppliedAutoProtectionPolicy item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListAppliedAutoProtectionPoliciesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AppliedAutoProtectionPolicy item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AppliedAutoProtectionPolicy> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AppliedAutoProtectionPolicy item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAppliedAutoProtectionPoliciesAsync(LocationName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListAppliedAutoProtectionPoliciesResponse, AppliedAutoProtectionPolicy> ListAppliedAutoProtectionPoliciesAsync(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists AppliedAutoProtectionPolicies in a given project and location.

Parameters
Name Description
parent LocationName

Required. The project and location for which to retrieve the list of applied policies. Format: projects/{project}/locations/{location}

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListAppliedAutoProtectionPoliciesResponseAppliedAutoProtectionPolicy

A pageable asynchronous sequence of AppliedAutoProtectionPolicy resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedAsyncEnumerable<ListAppliedAutoProtectionPoliciesResponse, AppliedAutoProtectionPolicy> response = backupDRClient.ListAppliedAutoProtectionPoliciesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (AppliedAutoProtectionPolicy item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListAppliedAutoProtectionPoliciesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AppliedAutoProtectionPolicy item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AppliedAutoProtectionPolicy> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AppliedAutoProtectionPolicy item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAppliedAutoProtectionPoliciesAsync(ListAppliedAutoProtectionPoliciesRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListAppliedAutoProtectionPoliciesResponse, AppliedAutoProtectionPolicy> ListAppliedAutoProtectionPoliciesAsync(ListAppliedAutoProtectionPoliciesRequest request, CallSettings callSettings = null)

Lists AppliedAutoProtectionPolicies in a given project and location.

Parameters
Name Description
request ListAppliedAutoProtectionPoliciesRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListAppliedAutoProtectionPoliciesResponseAppliedAutoProtectionPolicy

A pageable asynchronous sequence of AppliedAutoProtectionPolicy resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
ListAppliedAutoProtectionPoliciesRequest request = new ListAppliedAutoProtectionPoliciesRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedAsyncEnumerable<ListAppliedAutoProtectionPoliciesResponse, AppliedAutoProtectionPolicy> response = backupDRClient.ListAppliedAutoProtectionPoliciesAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await foreach (AppliedAutoProtectionPolicy item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListAppliedAutoProtectionPoliciesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AppliedAutoProtectionPolicy item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AppliedAutoProtectionPolicy> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AppliedAutoProtectionPolicy item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAppliedAutoProtectionPoliciesAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListAppliedAutoProtectionPoliciesResponse, AppliedAutoProtectionPolicy> ListAppliedAutoProtectionPoliciesAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists AppliedAutoProtectionPolicies in a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve the list of applied policies. Format: projects/{project}/locations/{location}

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListAppliedAutoProtectionPoliciesResponseAppliedAutoProtectionPolicy

A pageable asynchronous sequence of AppliedAutoProtectionPolicy resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedAsyncEnumerable<ListAppliedAutoProtectionPoliciesResponse, AppliedAutoProtectionPolicy> response = backupDRClient.ListAppliedAutoProtectionPoliciesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (AppliedAutoProtectionPolicy item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListAppliedAutoProtectionPoliciesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AppliedAutoProtectionPolicy item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AppliedAutoProtectionPolicy> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AppliedAutoProtectionPolicy item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAutoProtectionPolicies(LocationName, string, int?, CallSettings)

public virtual PagedEnumerable<ListAutoProtectionPoliciesResponse, AutoProtectionPolicy> ListAutoProtectionPolicies(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists AutoProtectionPolicies for a given project and location.

Parameters
Name Description
parent LocationName

Required. The project and location for which to retrieve the list of policies. Format: projects/{project}/locations/{location}

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListAutoProtectionPoliciesResponseAutoProtectionPolicy

A pageable sequence of AutoProtectionPolicy resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedEnumerable<ListAutoProtectionPoliciesResponse, AutoProtectionPolicy> response = backupDRClient.ListAutoProtectionPolicies(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (AutoProtectionPolicy item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListAutoProtectionPoliciesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AutoProtectionPolicy item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AutoProtectionPolicy> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AutoProtectionPolicy item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAutoProtectionPolicies(ListAutoProtectionPoliciesRequest, CallSettings)

public virtual PagedEnumerable<ListAutoProtectionPoliciesResponse, AutoProtectionPolicy> ListAutoProtectionPolicies(ListAutoProtectionPoliciesRequest request, CallSettings callSettings = null)

Lists AutoProtectionPolicies for a given project and location.

Parameters
Name Description
request ListAutoProtectionPoliciesRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListAutoProtectionPoliciesResponseAutoProtectionPolicy

A pageable sequence of AutoProtectionPolicy resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
ListAutoProtectionPoliciesRequest request = new ListAutoProtectionPoliciesRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedEnumerable<ListAutoProtectionPoliciesResponse, AutoProtectionPolicy> response = backupDRClient.ListAutoProtectionPolicies(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (AutoProtectionPolicy item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListAutoProtectionPoliciesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AutoProtectionPolicy item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AutoProtectionPolicy> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AutoProtectionPolicy item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAutoProtectionPolicies(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListAutoProtectionPoliciesResponse, AutoProtectionPolicy> ListAutoProtectionPolicies(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists AutoProtectionPolicies for a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve the list of policies. Format: projects/{project}/locations/{location}

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListAutoProtectionPoliciesResponseAutoProtectionPolicy

A pageable sequence of AutoProtectionPolicy resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedEnumerable<ListAutoProtectionPoliciesResponse, AutoProtectionPolicy> response = backupDRClient.ListAutoProtectionPolicies(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (AutoProtectionPolicy item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListAutoProtectionPoliciesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AutoProtectionPolicy item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AutoProtectionPolicy> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AutoProtectionPolicy item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAutoProtectionPoliciesAsync(LocationName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListAutoProtectionPoliciesResponse, AutoProtectionPolicy> ListAutoProtectionPoliciesAsync(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists AutoProtectionPolicies for a given project and location.

Parameters
Name Description
parent LocationName

Required. The project and location for which to retrieve the list of policies. Format: projects/{project}/locations/{location}

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListAutoProtectionPoliciesResponseAutoProtectionPolicy

A pageable asynchronous sequence of AutoProtectionPolicy resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedAsyncEnumerable<ListAutoProtectionPoliciesResponse, AutoProtectionPolicy> response = backupDRClient.ListAutoProtectionPoliciesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (AutoProtectionPolicy item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListAutoProtectionPoliciesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AutoProtectionPolicy item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AutoProtectionPolicy> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AutoProtectionPolicy item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAutoProtectionPoliciesAsync(ListAutoProtectionPoliciesRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListAutoProtectionPoliciesResponse, AutoProtectionPolicy> ListAutoProtectionPoliciesAsync(ListAutoProtectionPoliciesRequest request, CallSettings callSettings = null)

Lists AutoProtectionPolicies for a given project and location.

Parameters
Name Description
request ListAutoProtectionPoliciesRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListAutoProtectionPoliciesResponseAutoProtectionPolicy

A pageable asynchronous sequence of AutoProtectionPolicy resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
ListAutoProtectionPoliciesRequest request = new ListAutoProtectionPoliciesRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedAsyncEnumerable<ListAutoProtectionPoliciesResponse, AutoProtectionPolicy> response = backupDRClient.ListAutoProtectionPoliciesAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await foreach (AutoProtectionPolicy item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListAutoProtectionPoliciesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AutoProtectionPolicy item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AutoProtectionPolicy> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AutoProtectionPolicy item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAutoProtectionPoliciesAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListAutoProtectionPoliciesResponse, AutoProtectionPolicy> ListAutoProtectionPoliciesAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists AutoProtectionPolicies for a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve the list of policies. Format: projects/{project}/locations/{location}

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListAutoProtectionPoliciesResponseAutoProtectionPolicy

A pageable asynchronous sequence of AutoProtectionPolicy resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedAsyncEnumerable<ListAutoProtectionPoliciesResponse, AutoProtectionPolicy> response = backupDRClient.ListAutoProtectionPoliciesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (AutoProtectionPolicy item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListAutoProtectionPoliciesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AutoProtectionPolicy item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AutoProtectionPolicy> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AutoProtectionPolicy item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAutoProtectionPolicyBindings(AutoProtectionPolicyName, string, int?, CallSettings)

public virtual PagedEnumerable<ListAutoProtectionPolicyBindingsResponse, AutoProtectionPolicyBinding> ListAutoProtectionPolicyBindings(AutoProtectionPolicyName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Returns the auto protection policy bindings read from the CCFE tables.

Parameters
Name Description
parent AutoProtectionPolicyName

Required. The project and location for which to retrieve the list of policies. Format: projects/{project}/locations/{location}

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListAutoProtectionPolicyBindingsResponseAutoProtectionPolicyBinding

A pageable sequence of AutoProtectionPolicyBinding resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
AutoProtectionPolicyName parent = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]");
// Make the request
PagedEnumerable<ListAutoProtectionPolicyBindingsResponse, AutoProtectionPolicyBinding> response = backupDRClient.ListAutoProtectionPolicyBindings(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (AutoProtectionPolicyBinding item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListAutoProtectionPolicyBindingsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AutoProtectionPolicyBinding item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AutoProtectionPolicyBinding> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AutoProtectionPolicyBinding item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAutoProtectionPolicyBindings(ListAutoProtectionPolicyBindingsRequest, CallSettings)

public virtual PagedEnumerable<ListAutoProtectionPolicyBindingsResponse, AutoProtectionPolicyBinding> ListAutoProtectionPolicyBindings(ListAutoProtectionPolicyBindingsRequest request, CallSettings callSettings = null)

Returns the auto protection policy bindings read from the CCFE tables.

Parameters
Name Description
request ListAutoProtectionPolicyBindingsRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListAutoProtectionPolicyBindingsResponseAutoProtectionPolicyBinding

A pageable sequence of AutoProtectionPolicyBinding resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
ListAutoProtectionPolicyBindingsRequest request = new ListAutoProtectionPolicyBindingsRequest
{
    ParentAsAutoProtectionPolicyName = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedEnumerable<ListAutoProtectionPolicyBindingsResponse, AutoProtectionPolicyBinding> response = backupDRClient.ListAutoProtectionPolicyBindings(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (AutoProtectionPolicyBinding item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListAutoProtectionPolicyBindingsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AutoProtectionPolicyBinding item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AutoProtectionPolicyBinding> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AutoProtectionPolicyBinding item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAutoProtectionPolicyBindings(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListAutoProtectionPolicyBindingsResponse, AutoProtectionPolicyBinding> ListAutoProtectionPolicyBindings(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Returns the auto protection policy bindings read from the CCFE tables.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve the list of policies. Format: projects/{project}/locations/{location}

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListAutoProtectionPolicyBindingsResponseAutoProtectionPolicyBinding

A pageable sequence of AutoProtectionPolicyBinding resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]";
// Make the request
PagedEnumerable<ListAutoProtectionPolicyBindingsResponse, AutoProtectionPolicyBinding> response = backupDRClient.ListAutoProtectionPolicyBindings(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (AutoProtectionPolicyBinding item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListAutoProtectionPolicyBindingsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AutoProtectionPolicyBinding item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AutoProtectionPolicyBinding> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AutoProtectionPolicyBinding item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAutoProtectionPolicyBindingsAsync(AutoProtectionPolicyName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListAutoProtectionPolicyBindingsResponse, AutoProtectionPolicyBinding> ListAutoProtectionPolicyBindingsAsync(AutoProtectionPolicyName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Returns the auto protection policy bindings read from the CCFE tables.

Parameters
Name Description
parent AutoProtectionPolicyName

Required. The project and location for which to retrieve the list of policies. Format: projects/{project}/locations/{location}

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListAutoProtectionPolicyBindingsResponseAutoProtectionPolicyBinding

A pageable asynchronous sequence of AutoProtectionPolicyBinding resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
AutoProtectionPolicyName parent = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]");
// Make the request
PagedAsyncEnumerable<ListAutoProtectionPolicyBindingsResponse, AutoProtectionPolicyBinding> response = backupDRClient.ListAutoProtectionPolicyBindingsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (AutoProtectionPolicyBinding item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListAutoProtectionPolicyBindingsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AutoProtectionPolicyBinding item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AutoProtectionPolicyBinding> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AutoProtectionPolicyBinding item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAutoProtectionPolicyBindingsAsync(ListAutoProtectionPolicyBindingsRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListAutoProtectionPolicyBindingsResponse, AutoProtectionPolicyBinding> ListAutoProtectionPolicyBindingsAsync(ListAutoProtectionPolicyBindingsRequest request, CallSettings callSettings = null)

Returns the auto protection policy bindings read from the CCFE tables.

Parameters
Name Description
request ListAutoProtectionPolicyBindingsRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListAutoProtectionPolicyBindingsResponseAutoProtectionPolicyBinding

A pageable asynchronous sequence of AutoProtectionPolicyBinding resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
ListAutoProtectionPolicyBindingsRequest request = new ListAutoProtectionPolicyBindingsRequest
{
    ParentAsAutoProtectionPolicyName = AutoProtectionPolicyName.FromProjectLocationAutoProtectionPolicy("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedAsyncEnumerable<ListAutoProtectionPolicyBindingsResponse, AutoProtectionPolicyBinding> response = backupDRClient.ListAutoProtectionPolicyBindingsAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await foreach (AutoProtectionPolicyBinding item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListAutoProtectionPolicyBindingsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AutoProtectionPolicyBinding item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AutoProtectionPolicyBinding> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AutoProtectionPolicyBinding item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAutoProtectionPolicyBindingsAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListAutoProtectionPolicyBindingsResponse, AutoProtectionPolicyBinding> ListAutoProtectionPolicyBindingsAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Returns the auto protection policy bindings read from the CCFE tables.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve the list of policies. Format: projects/{project}/locations/{location}

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListAutoProtectionPolicyBindingsResponseAutoProtectionPolicyBinding

A pageable asynchronous sequence of AutoProtectionPolicyBinding resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]";
// Make the request
PagedAsyncEnumerable<ListAutoProtectionPolicyBindingsResponse, AutoProtectionPolicyBinding> response = backupDRClient.ListAutoProtectionPolicyBindingsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (AutoProtectionPolicyBinding item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListAutoProtectionPolicyBindingsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AutoProtectionPolicyBinding item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AutoProtectionPolicyBinding> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AutoProtectionPolicyBinding item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlanAssociations(LocationName, string, int?, CallSettings)

public virtual PagedEnumerable<ListBackupPlanAssociationsResponse, BackupPlanAssociation> ListBackupPlanAssociations(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists BackupPlanAssociations in a given project and location.

Parameters
Name Description
parent LocationName

Required. The project and location for which to retrieve backup Plan Associations information, in the format projects/{project_id}/locations/{location}. In Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve backup plan associations for all locations, use "-" for the {location} value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBackupPlanAssociationsResponseBackupPlanAssociation

A pageable sequence of BackupPlanAssociation resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedEnumerable<ListBackupPlanAssociationsResponse, BackupPlanAssociation> response = backupDRClient.ListBackupPlanAssociations(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupPlanAssociation item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBackupPlanAssociationsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanAssociation item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanAssociation> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanAssociation item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlanAssociations(ListBackupPlanAssociationsRequest, CallSettings)

public virtual PagedEnumerable<ListBackupPlanAssociationsResponse, BackupPlanAssociation> ListBackupPlanAssociations(ListBackupPlanAssociationsRequest request, CallSettings callSettings = null)

Lists BackupPlanAssociations in a given project and location.

Parameters
Name Description
request ListBackupPlanAssociationsRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBackupPlanAssociationsResponseBackupPlanAssociation

A pageable sequence of BackupPlanAssociation resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
ListBackupPlanAssociationsRequest request = new ListBackupPlanAssociationsRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
};
// Make the request
PagedEnumerable<ListBackupPlanAssociationsResponse, BackupPlanAssociation> response = backupDRClient.ListBackupPlanAssociations(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupPlanAssociation item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBackupPlanAssociationsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanAssociation item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanAssociation> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanAssociation item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlanAssociations(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListBackupPlanAssociationsResponse, BackupPlanAssociation> ListBackupPlanAssociations(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists BackupPlanAssociations in a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve backup Plan Associations information, in the format projects/{project_id}/locations/{location}. In Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve backup plan associations for all locations, use "-" for the {location} value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBackupPlanAssociationsResponseBackupPlanAssociation

A pageable sequence of BackupPlanAssociation resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedEnumerable<ListBackupPlanAssociationsResponse, BackupPlanAssociation> response = backupDRClient.ListBackupPlanAssociations(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupPlanAssociation item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBackupPlanAssociationsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanAssociation item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanAssociation> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanAssociation item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlanAssociationsAsync(LocationName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListBackupPlanAssociationsResponse, BackupPlanAssociation> ListBackupPlanAssociationsAsync(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists BackupPlanAssociations in a given project and location.

Parameters
Name Description
parent LocationName

Required. The project and location for which to retrieve backup Plan Associations information, in the format projects/{project_id}/locations/{location}. In Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve backup plan associations for all locations, use "-" for the {location} value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBackupPlanAssociationsResponseBackupPlanAssociation

A pageable asynchronous sequence of BackupPlanAssociation resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedAsyncEnumerable<ListBackupPlanAssociationsResponse, BackupPlanAssociation> response = backupDRClient.ListBackupPlanAssociationsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupPlanAssociation item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBackupPlanAssociationsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanAssociation item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanAssociation> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanAssociation item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlanAssociationsAsync(ListBackupPlanAssociationsRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListBackupPlanAssociationsResponse, BackupPlanAssociation> ListBackupPlanAssociationsAsync(ListBackupPlanAssociationsRequest request, CallSettings callSettings = null)

Lists BackupPlanAssociations in a given project and location.

Parameters
Name Description
request ListBackupPlanAssociationsRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBackupPlanAssociationsResponseBackupPlanAssociation

A pageable asynchronous sequence of BackupPlanAssociation resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
ListBackupPlanAssociationsRequest request = new ListBackupPlanAssociationsRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
};
// Make the request
PagedAsyncEnumerable<ListBackupPlanAssociationsResponse, BackupPlanAssociation> response = backupDRClient.ListBackupPlanAssociationsAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupPlanAssociation item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBackupPlanAssociationsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanAssociation item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanAssociation> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanAssociation item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlanAssociationsAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListBackupPlanAssociationsResponse, BackupPlanAssociation> ListBackupPlanAssociationsAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists BackupPlanAssociations in a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve backup Plan Associations information, in the format projects/{project_id}/locations/{location}. In Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve backup plan associations for all locations, use "-" for the {location} value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBackupPlanAssociationsResponseBackupPlanAssociation

A pageable asynchronous sequence of BackupPlanAssociation resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedAsyncEnumerable<ListBackupPlanAssociationsResponse, BackupPlanAssociation> response = backupDRClient.ListBackupPlanAssociationsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupPlanAssociation item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBackupPlanAssociationsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanAssociation item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanAssociation> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanAssociation item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlanRevisions(BackupPlanName, string, int?, CallSettings)

public virtual PagedEnumerable<ListBackupPlanRevisionsResponse, BackupPlanRevision> ListBackupPlanRevisions(BackupPlanName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists BackupPlanRevisions in a given project and location.

Parameters
Name Description
parent BackupPlanName

Required. The project and location for which to retrieve BackupPlanRevisions information. Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}. In Google Cloud Backup and DR, locations map to Google Cloud regions, for e.g. us-central1.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBackupPlanRevisionsResponseBackupPlanRevision

A pageable sequence of BackupPlanRevision resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BackupPlanName parent = BackupPlanName.FromProjectLocationBackupPlan("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]");
// Make the request
PagedEnumerable<ListBackupPlanRevisionsResponse, BackupPlanRevision> response = backupDRClient.ListBackupPlanRevisions(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupPlanRevision item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBackupPlanRevisionsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanRevision item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanRevision> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanRevision item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlanRevisions(ListBackupPlanRevisionsRequest, CallSettings)

public virtual PagedEnumerable<ListBackupPlanRevisionsResponse, BackupPlanRevision> ListBackupPlanRevisions(ListBackupPlanRevisionsRequest request, CallSettings callSettings = null)

Lists BackupPlanRevisions in a given project and location.

Parameters
Name Description
request ListBackupPlanRevisionsRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBackupPlanRevisionsResponseBackupPlanRevision

A pageable sequence of BackupPlanRevision resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
ListBackupPlanRevisionsRequest request = new ListBackupPlanRevisionsRequest
{
    ParentAsBackupPlanName = BackupPlanName.FromProjectLocationBackupPlan("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]"),
};
// Make the request
PagedEnumerable<ListBackupPlanRevisionsResponse, BackupPlanRevision> response = backupDRClient.ListBackupPlanRevisions(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupPlanRevision item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBackupPlanRevisionsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanRevision item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanRevision> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanRevision item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlanRevisions(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListBackupPlanRevisionsResponse, BackupPlanRevision> ListBackupPlanRevisions(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists BackupPlanRevisions in a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve BackupPlanRevisions information. Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}. In Google Cloud Backup and DR, locations map to Google Cloud regions, for e.g. us-central1.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBackupPlanRevisionsResponseBackupPlanRevision

A pageable sequence of BackupPlanRevision resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/backupPlans/[BACKUP_PLAN]";
// Make the request
PagedEnumerable<ListBackupPlanRevisionsResponse, BackupPlanRevision> response = backupDRClient.ListBackupPlanRevisions(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupPlanRevision item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBackupPlanRevisionsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanRevision item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanRevision> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanRevision item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlanRevisionsAsync(BackupPlanName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListBackupPlanRevisionsResponse, BackupPlanRevision> ListBackupPlanRevisionsAsync(BackupPlanName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists BackupPlanRevisions in a given project and location.

Parameters
Name Description
parent BackupPlanName

Required. The project and location for which to retrieve BackupPlanRevisions information. Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}. In Google Cloud Backup and DR, locations map to Google Cloud regions, for e.g. us-central1.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBackupPlanRevisionsResponseBackupPlanRevision

A pageable asynchronous sequence of BackupPlanRevision resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlanName parent = BackupPlanName.FromProjectLocationBackupPlan("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]");
// Make the request
PagedAsyncEnumerable<ListBackupPlanRevisionsResponse, BackupPlanRevision> response = backupDRClient.ListBackupPlanRevisionsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupPlanRevision item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBackupPlanRevisionsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanRevision item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanRevision> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanRevision item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlanRevisionsAsync(ListBackupPlanRevisionsRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListBackupPlanRevisionsResponse, BackupPlanRevision> ListBackupPlanRevisionsAsync(ListBackupPlanRevisionsRequest request, CallSettings callSettings = null)

Lists BackupPlanRevisions in a given project and location.

Parameters
Name Description
request ListBackupPlanRevisionsRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBackupPlanRevisionsResponseBackupPlanRevision

A pageable asynchronous sequence of BackupPlanRevision resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
ListBackupPlanRevisionsRequest request = new ListBackupPlanRevisionsRequest
{
    ParentAsBackupPlanName = BackupPlanName.FromProjectLocationBackupPlan("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN]"),
};
// Make the request
PagedAsyncEnumerable<ListBackupPlanRevisionsResponse, BackupPlanRevision> response = backupDRClient.ListBackupPlanRevisionsAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupPlanRevision item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBackupPlanRevisionsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanRevision item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanRevision> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanRevision item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlanRevisionsAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListBackupPlanRevisionsResponse, BackupPlanRevision> ListBackupPlanRevisionsAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists BackupPlanRevisions in a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve BackupPlanRevisions information. Format: projects/{project}/locations/{location}/backupPlans/{backup_plan}. In Google Cloud Backup and DR, locations map to Google Cloud regions, for e.g. us-central1.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBackupPlanRevisionsResponseBackupPlanRevision

A pageable asynchronous sequence of BackupPlanRevision resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/backupPlans/[BACKUP_PLAN]";
// Make the request
PagedAsyncEnumerable<ListBackupPlanRevisionsResponse, BackupPlanRevision> response = backupDRClient.ListBackupPlanRevisionsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupPlanRevision item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBackupPlanRevisionsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlanRevision item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlanRevision> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlanRevision item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlans(LocationName, string, int?, CallSettings)

public virtual PagedEnumerable<ListBackupPlansResponse, BackupPlan> ListBackupPlans(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists BackupPlans in a given project and location.

Parameters
Name Description
parent LocationName

Required. The project and location for which to retrieve BackupPlans information. Format: projects/{project}/locations/{location}. In Google Cloud Backup and DR, locations map to Google Cloud regions, for e.g. us-central1. To retrieve backup plans for all locations, use "-" for the {location} value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBackupPlansResponseBackupPlan

A pageable sequence of BackupPlan resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedEnumerable<ListBackupPlansResponse, BackupPlan> response = backupDRClient.ListBackupPlans(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupPlan item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBackupPlansResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlan item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlan> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlan item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlans(ListBackupPlansRequest, CallSettings)

public virtual PagedEnumerable<ListBackupPlansResponse, BackupPlan> ListBackupPlans(ListBackupPlansRequest request, CallSettings callSettings = null)

Lists BackupPlans in a given project and location.

Parameters
Name Description
request ListBackupPlansRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBackupPlansResponseBackupPlan

A pageable sequence of BackupPlan resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
ListBackupPlansRequest request = new ListBackupPlansRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedEnumerable<ListBackupPlansResponse, BackupPlan> response = backupDRClient.ListBackupPlans(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupPlan item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBackupPlansResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlan item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlan> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlan item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlans(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListBackupPlansResponse, BackupPlan> ListBackupPlans(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists BackupPlans in a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve BackupPlans information. Format: projects/{project}/locations/{location}. In Google Cloud Backup and DR, locations map to Google Cloud regions, for e.g. us-central1. To retrieve backup plans for all locations, use "-" for the {location} value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBackupPlansResponseBackupPlan

A pageable sequence of BackupPlan resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedEnumerable<ListBackupPlansResponse, BackupPlan> response = backupDRClient.ListBackupPlans(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupPlan item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBackupPlansResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlan item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlan> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlan item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlansAsync(LocationName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListBackupPlansResponse, BackupPlan> ListBackupPlansAsync(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists BackupPlans in a given project and location.

Parameters
Name Description
parent LocationName

Required. The project and location for which to retrieve BackupPlans information. Format: projects/{project}/locations/{location}. In Google Cloud Backup and DR, locations map to Google Cloud regions, for e.g. us-central1. To retrieve backup plans for all locations, use "-" for the {location} value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBackupPlansResponseBackupPlan

A pageable asynchronous sequence of BackupPlan resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedAsyncEnumerable<ListBackupPlansResponse, BackupPlan> response = backupDRClient.ListBackupPlansAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupPlan item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBackupPlansResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlan item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlan> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlan item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlansAsync(ListBackupPlansRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListBackupPlansResponse, BackupPlan> ListBackupPlansAsync(ListBackupPlansRequest request, CallSettings callSettings = null)

Lists BackupPlans in a given project and location.

Parameters
Name Description
request ListBackupPlansRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBackupPlansResponseBackupPlan

A pageable asynchronous sequence of BackupPlan resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
ListBackupPlansRequest request = new ListBackupPlansRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedAsyncEnumerable<ListBackupPlansResponse, BackupPlan> response = backupDRClient.ListBackupPlansAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupPlan item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBackupPlansResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlan item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlan> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlan item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupPlansAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListBackupPlansResponse, BackupPlan> ListBackupPlansAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists BackupPlans in a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve BackupPlans information. Format: projects/{project}/locations/{location}. In Google Cloud Backup and DR, locations map to Google Cloud regions, for e.g. us-central1. To retrieve backup plans for all locations, use "-" for the {location} value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBackupPlansResponseBackupPlan

A pageable asynchronous sequence of BackupPlan resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedAsyncEnumerable<ListBackupPlansResponse, BackupPlan> response = backupDRClient.ListBackupPlansAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupPlan item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBackupPlansResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupPlan item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupPlan> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupPlan item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupVaults(LocationName, string, int?, CallSettings)

public virtual PagedEnumerable<ListBackupVaultsResponse, BackupVault> ListBackupVaults(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists BackupVaults in a given project and location.

Parameters
Name Description
parent LocationName

Required. The project and location for which to retrieve backupvault stores information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve backupvault stores for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBackupVaultsResponseBackupVault

A pageable sequence of BackupVault resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedEnumerable<ListBackupVaultsResponse, BackupVault> response = backupDRClient.ListBackupVaults(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupVault item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBackupVaultsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupVault item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupVault> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupVault item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupVaults(ListBackupVaultsRequest, CallSettings)

public virtual PagedEnumerable<ListBackupVaultsResponse, BackupVault> ListBackupVaults(ListBackupVaultsRequest request, CallSettings callSettings = null)

Lists BackupVaults in a given project and location.

Parameters
Name Description
request ListBackupVaultsRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBackupVaultsResponseBackupVault

A pageable sequence of BackupVault resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
ListBackupVaultsRequest request = new ListBackupVaultsRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
    OrderBy = "",
    View = BackupVaultView.Unspecified,
};
// Make the request
PagedEnumerable<ListBackupVaultsResponse, BackupVault> response = backupDRClient.ListBackupVaults(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupVault item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBackupVaultsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupVault item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupVault> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupVault item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupVaults(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListBackupVaultsResponse, BackupVault> ListBackupVaults(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists BackupVaults in a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve backupvault stores information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve backupvault stores for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBackupVaultsResponseBackupVault

A pageable sequence of BackupVault resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedEnumerable<ListBackupVaultsResponse, BackupVault> response = backupDRClient.ListBackupVaults(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (BackupVault item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBackupVaultsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupVault item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupVault> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupVault item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupVaultsAsync(LocationName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListBackupVaultsResponse, BackupVault> ListBackupVaultsAsync(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists BackupVaults in a given project and location.

Parameters
Name Description
parent LocationName

Required. The project and location for which to retrieve backupvault stores information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve backupvault stores for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBackupVaultsResponseBackupVault

A pageable asynchronous sequence of BackupVault resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedAsyncEnumerable<ListBackupVaultsResponse, BackupVault> response = backupDRClient.ListBackupVaultsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupVault item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBackupVaultsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupVault item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupVault> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupVault item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupVaultsAsync(ListBackupVaultsRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListBackupVaultsResponse, BackupVault> ListBackupVaultsAsync(ListBackupVaultsRequest request, CallSettings callSettings = null)

Lists BackupVaults in a given project and location.

Parameters
Name Description
request ListBackupVaultsRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBackupVaultsResponseBackupVault

A pageable asynchronous sequence of BackupVault resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
ListBackupVaultsRequest request = new ListBackupVaultsRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
    OrderBy = "",
    View = BackupVaultView.Unspecified,
};
// Make the request
PagedAsyncEnumerable<ListBackupVaultsResponse, BackupVault> response = backupDRClient.ListBackupVaultsAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupVault item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBackupVaultsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupVault item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupVault> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupVault item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupVaultsAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListBackupVaultsResponse, BackupVault> ListBackupVaultsAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists BackupVaults in a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve backupvault stores information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve backupvault stores for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBackupVaultsResponseBackupVault

A pageable asynchronous sequence of BackupVault resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedAsyncEnumerable<ListBackupVaultsResponse, BackupVault> response = backupDRClient.ListBackupVaultsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BackupVault item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBackupVaultsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BackupVault item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BackupVault> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BackupVault item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackups(DataSourceName, string, int?, CallSettings)

public virtual PagedEnumerable<ListBackupsResponse, Backup> ListBackups(DataSourceName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists Backups in a given project and location.

Parameters
Name Description
parent DataSourceName

Required. The project and location for which to retrieve backup information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve data sources for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBackupsResponseBackup

A pageable sequence of Backup resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
DataSourceName parent = DataSourceName.FromProjectLocationBackupvaultDatasource("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]");
// Make the request
PagedEnumerable<ListBackupsResponse, Backup> response = backupDRClient.ListBackups(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (Backup item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBackupsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Backup item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Backup> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Backup item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackups(ListBackupsRequest, CallSettings)

public virtual PagedEnumerable<ListBackupsResponse, Backup> ListBackups(ListBackupsRequest request, CallSettings callSettings = null)

Lists Backups in a given project and location.

Parameters
Name Description
request ListBackupsRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBackupsResponseBackup

A pageable sequence of Backup resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
ListBackupsRequest request = new ListBackupsRequest
{
    ParentAsDataSourceName = DataSourceName.FromProjectLocationBackupvaultDatasource("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]"),
    Filter = "",
    OrderBy = "",
    View = BackupView.Unspecified,
};
// Make the request
PagedEnumerable<ListBackupsResponse, Backup> response = backupDRClient.ListBackups(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (Backup item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBackupsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Backup item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Backup> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Backup item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackups(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListBackupsResponse, Backup> ListBackups(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists Backups in a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve backup information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve data sources for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBackupsResponseBackup

A pageable sequence of Backup resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]/dataSources/[DATASOURCE]";
// Make the request
PagedEnumerable<ListBackupsResponse, Backup> response = backupDRClient.ListBackups(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (Backup item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBackupsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Backup item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Backup> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Backup item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupsAsync(DataSourceName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListBackupsResponse, Backup> ListBackupsAsync(DataSourceName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists Backups in a given project and location.

Parameters
Name Description
parent DataSourceName

Required. The project and location for which to retrieve backup information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve data sources for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBackupsResponseBackup

A pageable asynchronous sequence of Backup resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DataSourceName parent = DataSourceName.FromProjectLocationBackupvaultDatasource("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]");
// Make the request
PagedAsyncEnumerable<ListBackupsResponse, Backup> response = backupDRClient.ListBackupsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (Backup item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBackupsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Backup item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Backup> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Backup item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupsAsync(ListBackupsRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListBackupsResponse, Backup> ListBackupsAsync(ListBackupsRequest request, CallSettings callSettings = null)

Lists Backups in a given project and location.

Parameters
Name Description
request ListBackupsRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBackupsResponseBackup

A pageable asynchronous sequence of Backup resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
ListBackupsRequest request = new ListBackupsRequest
{
    ParentAsDataSourceName = DataSourceName.FromProjectLocationBackupvaultDatasource("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]"),
    Filter = "",
    OrderBy = "",
    View = BackupView.Unspecified,
};
// Make the request
PagedAsyncEnumerable<ListBackupsResponse, Backup> response = backupDRClient.ListBackupsAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await foreach (Backup item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBackupsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Backup item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Backup> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Backup item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBackupsAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListBackupsResponse, Backup> ListBackupsAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists Backups in a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve backup information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve data sources for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBackupsResponseBackup

A pageable asynchronous sequence of Backup resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]/dataSources/[DATASOURCE]";
// Make the request
PagedAsyncEnumerable<ListBackupsResponse, Backup> response = backupDRClient.ListBackupsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (Backup item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBackupsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Backup item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Backup> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Backup item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBindingMatchingResources(AutoProtectionPolicyBindingName, string, int?, CallSettings)

public virtual PagedEnumerable<ListBindingMatchingResourcesResponse, BindingMatchingResource> ListBindingMatchingResources(AutoProtectionPolicyBindingName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists Binding Matching Resources for a given AutoProtectionPolicyBinding.

Parameters
Name Description
parent AutoProtectionPolicyBindingName

Required. The project, location, auto protection policy and binding for which to retrieve BindingMatchingResources information. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBindingMatchingResourcesResponseBindingMatchingResource

A pageable sequence of BindingMatchingResource resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
AutoProtectionPolicyBindingName parent = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]");
// Make the request
PagedEnumerable<ListBindingMatchingResourcesResponse, BindingMatchingResource> response = backupDRClient.ListBindingMatchingResources(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (BindingMatchingResource item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBindingMatchingResourcesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BindingMatchingResource item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BindingMatchingResource> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BindingMatchingResource item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBindingMatchingResources(ListBindingMatchingResourcesRequest, CallSettings)

public virtual PagedEnumerable<ListBindingMatchingResourcesResponse, BindingMatchingResource> ListBindingMatchingResources(ListBindingMatchingResourcesRequest request, CallSettings callSettings = null)

Lists Binding Matching Resources for a given AutoProtectionPolicyBinding.

Parameters
Name Description
request ListBindingMatchingResourcesRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBindingMatchingResourcesResponseBindingMatchingResource

A pageable sequence of BindingMatchingResource resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
ListBindingMatchingResourcesRequest request = new ListBindingMatchingResourcesRequest
{
    ParentAsAutoProtectionPolicyBindingName = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedEnumerable<ListBindingMatchingResourcesResponse, BindingMatchingResource> response = backupDRClient.ListBindingMatchingResources(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (BindingMatchingResource item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBindingMatchingResourcesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BindingMatchingResource item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BindingMatchingResource> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BindingMatchingResource item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBindingMatchingResources(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListBindingMatchingResourcesResponse, BindingMatchingResource> ListBindingMatchingResources(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists Binding Matching Resources for a given AutoProtectionPolicyBinding.

Parameters
Name Description
parent string

Required. The project, location, auto protection policy and binding for which to retrieve BindingMatchingResources information. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListBindingMatchingResourcesResponseBindingMatchingResource

A pageable sequence of BindingMatchingResource resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]/bindings/[BINDING]";
// Make the request
PagedEnumerable<ListBindingMatchingResourcesResponse, BindingMatchingResource> response = backupDRClient.ListBindingMatchingResources(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (BindingMatchingResource item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListBindingMatchingResourcesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BindingMatchingResource item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BindingMatchingResource> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BindingMatchingResource item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBindingMatchingResourcesAsync(AutoProtectionPolicyBindingName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListBindingMatchingResourcesResponse, BindingMatchingResource> ListBindingMatchingResourcesAsync(AutoProtectionPolicyBindingName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists Binding Matching Resources for a given AutoProtectionPolicyBinding.

Parameters
Name Description
parent AutoProtectionPolicyBindingName

Required. The project, location, auto protection policy and binding for which to retrieve BindingMatchingResources information. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBindingMatchingResourcesResponseBindingMatchingResource

A pageable asynchronous sequence of BindingMatchingResource resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
AutoProtectionPolicyBindingName parent = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]");
// Make the request
PagedAsyncEnumerable<ListBindingMatchingResourcesResponse, BindingMatchingResource> response = backupDRClient.ListBindingMatchingResourcesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BindingMatchingResource item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBindingMatchingResourcesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BindingMatchingResource item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BindingMatchingResource> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BindingMatchingResource item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBindingMatchingResourcesAsync(ListBindingMatchingResourcesRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListBindingMatchingResourcesResponse, BindingMatchingResource> ListBindingMatchingResourcesAsync(ListBindingMatchingResourcesRequest request, CallSettings callSettings = null)

Lists Binding Matching Resources for a given AutoProtectionPolicyBinding.

Parameters
Name Description
request ListBindingMatchingResourcesRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBindingMatchingResourcesResponseBindingMatchingResource

A pageable asynchronous sequence of BindingMatchingResource resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
ListBindingMatchingResourcesRequest request = new ListBindingMatchingResourcesRequest
{
    ParentAsAutoProtectionPolicyBindingName = AutoProtectionPolicyBindingName.FromProjectLocationAutoProtectionPolicyBinding("[PROJECT]", "[LOCATION]", "[AUTO_PROTECTION_POLICY]", "[BINDING]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedAsyncEnumerable<ListBindingMatchingResourcesResponse, BindingMatchingResource> response = backupDRClient.ListBindingMatchingResourcesAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BindingMatchingResource item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBindingMatchingResourcesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BindingMatchingResource item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BindingMatchingResource> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BindingMatchingResource item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListBindingMatchingResourcesAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListBindingMatchingResourcesResponse, BindingMatchingResource> ListBindingMatchingResourcesAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists Binding Matching Resources for a given AutoProtectionPolicyBinding.

Parameters
Name Description
parent string

Required. The project, location, auto protection policy and binding for which to retrieve BindingMatchingResources information. Format: projects/{project}/locations/{location}/autoProtectionPolicies/{auto_protection_policy}/bindings/{binding}. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListBindingMatchingResourcesResponseBindingMatchingResource

A pageable asynchronous sequence of BindingMatchingResource resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/autoProtectionPolicies/[AUTO_PROTECTION_POLICY]/bindings/[BINDING]";
// Make the request
PagedAsyncEnumerable<ListBindingMatchingResourcesResponse, BindingMatchingResource> response = backupDRClient.ListBindingMatchingResourcesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (BindingMatchingResource item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListBindingMatchingResourcesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (BindingMatchingResource item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<BindingMatchingResource> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (BindingMatchingResource item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListDataSourceReferences(LocationName, string, int?, CallSettings)

public virtual PagedEnumerable<ListDataSourceReferencesResponse, DataSourceReference> ListDataSourceReferences(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists DataSourceReferences for a given project and location.

Parameters
Name Description
parent LocationName

Required. The parent resource name. Format: projects/{project}/locations/{location}

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListDataSourceReferencesResponseDataSourceReference

A pageable sequence of DataSourceReference resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedEnumerable<ListDataSourceReferencesResponse, DataSourceReference> response = backupDRClient.ListDataSourceReferences(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (DataSourceReference item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListDataSourceReferencesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSourceReference item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSourceReference> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSourceReference item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListDataSourceReferences(ListDataSourceReferencesRequest, CallSettings)

public virtual PagedEnumerable<ListDataSourceReferencesResponse, DataSourceReference> ListDataSourceReferences(ListDataSourceReferencesRequest request, CallSettings callSettings = null)

Lists DataSourceReferences for a given project and location.

Parameters
Name Description
request ListDataSourceReferencesRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListDataSourceReferencesResponseDataSourceReference

A pageable sequence of DataSourceReference resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
ListDataSourceReferencesRequest request = new ListDataSourceReferencesRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedEnumerable<ListDataSourceReferencesResponse, DataSourceReference> response = backupDRClient.ListDataSourceReferences(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (DataSourceReference item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListDataSourceReferencesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSourceReference item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSourceReference> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSourceReference item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListDataSourceReferences(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListDataSourceReferencesResponse, DataSourceReference> ListDataSourceReferences(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists DataSourceReferences for a given project and location.

Parameters
Name Description
parent string

Required. The parent resource name. Format: projects/{project}/locations/{location}

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListDataSourceReferencesResponseDataSourceReference

A pageable sequence of DataSourceReference resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedEnumerable<ListDataSourceReferencesResponse, DataSourceReference> response = backupDRClient.ListDataSourceReferences(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (DataSourceReference item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListDataSourceReferencesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSourceReference item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSourceReference> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSourceReference item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListDataSourceReferencesAsync(LocationName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListDataSourceReferencesResponse, DataSourceReference> ListDataSourceReferencesAsync(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists DataSourceReferences for a given project and location.

Parameters
Name Description
parent LocationName

Required. The parent resource name. Format: projects/{project}/locations/{location}

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListDataSourceReferencesResponseDataSourceReference

A pageable asynchronous sequence of DataSourceReference resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedAsyncEnumerable<ListDataSourceReferencesResponse, DataSourceReference> response = backupDRClient.ListDataSourceReferencesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (DataSourceReference item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListDataSourceReferencesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSourceReference item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSourceReference> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSourceReference item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListDataSourceReferencesAsync(ListDataSourceReferencesRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListDataSourceReferencesResponse, DataSourceReference> ListDataSourceReferencesAsync(ListDataSourceReferencesRequest request, CallSettings callSettings = null)

Lists DataSourceReferences for a given project and location.

Parameters
Name Description
request ListDataSourceReferencesRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListDataSourceReferencesResponseDataSourceReference

A pageable asynchronous sequence of DataSourceReference resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
ListDataSourceReferencesRequest request = new ListDataSourceReferencesRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedAsyncEnumerable<ListDataSourceReferencesResponse, DataSourceReference> response = backupDRClient.ListDataSourceReferencesAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await foreach (DataSourceReference item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListDataSourceReferencesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSourceReference item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSourceReference> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSourceReference item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListDataSourceReferencesAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListDataSourceReferencesResponse, DataSourceReference> ListDataSourceReferencesAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists DataSourceReferences for a given project and location.

Parameters
Name Description
parent string

Required. The parent resource name. Format: projects/{project}/locations/{location}

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListDataSourceReferencesResponseDataSourceReference

A pageable asynchronous sequence of DataSourceReference resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedAsyncEnumerable<ListDataSourceReferencesResponse, DataSourceReference> response = backupDRClient.ListDataSourceReferencesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (DataSourceReference item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListDataSourceReferencesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSourceReference item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSourceReference> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSourceReference item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListDataSources(BackupVaultName, string, int?, CallSettings)

public virtual PagedEnumerable<ListDataSourcesResponse, DataSource> ListDataSources(BackupVaultName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists DataSources in a given project and location.

Parameters
Name Description
parent BackupVaultName

Required. The project and location for which to retrieve data sources information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve data sources for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListDataSourcesResponseDataSource

A pageable sequence of DataSource resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BackupVaultName parent = BackupVaultName.FromProjectLocationBackupvault("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]");
// Make the request
PagedEnumerable<ListDataSourcesResponse, DataSource> response = backupDRClient.ListDataSources(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (DataSource item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListDataSourcesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSource item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSource> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSource item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListDataSources(ListDataSourcesRequest, CallSettings)

public virtual PagedEnumerable<ListDataSourcesResponse, DataSource> ListDataSources(ListDataSourcesRequest request, CallSettings callSettings = null)

Lists DataSources in a given project and location.

Parameters
Name Description
request ListDataSourcesRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListDataSourcesResponseDataSource

A pageable sequence of DataSource resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
ListDataSourcesRequest request = new ListDataSourcesRequest
{
    ParentAsBackupVaultName = BackupVaultName.FromProjectLocationBackupvault("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedEnumerable<ListDataSourcesResponse, DataSource> response = backupDRClient.ListDataSources(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (DataSource item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListDataSourcesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSource item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSource> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSource item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListDataSources(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListDataSourcesResponse, DataSource> ListDataSources(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists DataSources in a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve data sources information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve data sources for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListDataSourcesResponseDataSource

A pageable sequence of DataSource resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]";
// Make the request
PagedEnumerable<ListDataSourcesResponse, DataSource> response = backupDRClient.ListDataSources(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (DataSource item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListDataSourcesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSource item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSource> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSource item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListDataSourcesAsync(BackupVaultName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListDataSourcesResponse, DataSource> ListDataSourcesAsync(BackupVaultName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists DataSources in a given project and location.

Parameters
Name Description
parent BackupVaultName

Required. The project and location for which to retrieve data sources information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve data sources for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListDataSourcesResponseDataSource

A pageable asynchronous sequence of DataSource resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupVaultName parent = BackupVaultName.FromProjectLocationBackupvault("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]");
// Make the request
PagedAsyncEnumerable<ListDataSourcesResponse, DataSource> response = backupDRClient.ListDataSourcesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (DataSource item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListDataSourcesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSource item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSource> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSource item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListDataSourcesAsync(ListDataSourcesRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListDataSourcesResponse, DataSource> ListDataSourcesAsync(ListDataSourcesRequest request, CallSettings callSettings = null)

Lists DataSources in a given project and location.

Parameters
Name Description
request ListDataSourcesRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListDataSourcesResponseDataSource

A pageable asynchronous sequence of DataSource resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
ListDataSourcesRequest request = new ListDataSourcesRequest
{
    ParentAsBackupVaultName = BackupVaultName.FromProjectLocationBackupvault("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedAsyncEnumerable<ListDataSourcesResponse, DataSource> response = backupDRClient.ListDataSourcesAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await foreach (DataSource item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListDataSourcesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSource item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSource> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSource item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListDataSourcesAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListDataSourcesResponse, DataSource> ListDataSourcesAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists DataSources in a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve data sources information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve data sources for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListDataSourcesResponseDataSource

A pageable asynchronous sequence of DataSource resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]";
// Make the request
PagedAsyncEnumerable<ListDataSourcesResponse, DataSource> response = backupDRClient.ListDataSourcesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (DataSource item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListDataSourcesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DataSource item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<DataSource> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (DataSource item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListManagementServers(LocationName, string, int?, CallSettings)

public virtual PagedEnumerable<ListManagementServersResponse, ManagementServer> ListManagementServers(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists ManagementServers in a given project and location.

Parameters
Name Description
parent LocationName

Required. The project and location for which to retrieve management servers information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve management servers for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListManagementServersResponseManagementServer

A pageable sequence of ManagementServer resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedEnumerable<ListManagementServersResponse, ManagementServer> response = backupDRClient.ListManagementServers(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (ManagementServer item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListManagementServersResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (ManagementServer item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<ManagementServer> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (ManagementServer item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListManagementServers(ListManagementServersRequest, CallSettings)

public virtual PagedEnumerable<ListManagementServersResponse, ManagementServer> ListManagementServers(ListManagementServersRequest request, CallSettings callSettings = null)

Lists ManagementServers in a given project and location.

Parameters
Name Description
request ListManagementServersRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListManagementServersResponseManagementServer

A pageable sequence of ManagementServer resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
ListManagementServersRequest request = new ListManagementServersRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedEnumerable<ListManagementServersResponse, ManagementServer> response = backupDRClient.ListManagementServers(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (ManagementServer item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListManagementServersResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (ManagementServer item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<ManagementServer> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (ManagementServer item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListManagementServers(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListManagementServersResponse, ManagementServer> ListManagementServers(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists ManagementServers in a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve management servers information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve management servers for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListManagementServersResponseManagementServer

A pageable sequence of ManagementServer resources.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedEnumerable<ListManagementServersResponse, ManagementServer> response = backupDRClient.ListManagementServers(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (ManagementServer item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListManagementServersResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (ManagementServer item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<ManagementServer> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (ManagementServer item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListManagementServersAsync(LocationName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListManagementServersResponse, ManagementServer> ListManagementServersAsync(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists ManagementServers in a given project and location.

Parameters
Name Description
parent LocationName

Required. The project and location for which to retrieve management servers information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve management servers for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListManagementServersResponseManagementServer

A pageable asynchronous sequence of ManagementServer resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedAsyncEnumerable<ListManagementServersResponse, ManagementServer> response = backupDRClient.ListManagementServersAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (ManagementServer item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListManagementServersResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (ManagementServer item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<ManagementServer> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (ManagementServer item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListManagementServersAsync(ListManagementServersRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListManagementServersResponse, ManagementServer> ListManagementServersAsync(ListManagementServersRequest request, CallSettings callSettings = null)

Lists ManagementServers in a given project and location.

Parameters
Name Description
request ListManagementServersRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListManagementServersResponseManagementServer

A pageable asynchronous sequence of ManagementServer resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
ListManagementServersRequest request = new ListManagementServersRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedAsyncEnumerable<ListManagementServersResponse, ManagementServer> response = backupDRClient.ListManagementServersAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await foreach (ManagementServer item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListManagementServersResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (ManagementServer item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<ManagementServer> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (ManagementServer item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListManagementServersAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListManagementServersResponse, ManagementServer> ListManagementServersAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists ManagementServers in a given project and location.

Parameters
Name Description
parent string

Required. The project and location for which to retrieve management servers information, in the format 'projects/{project_id}/locations/{location}'. In Google Cloud Backup and DR, locations map to Google Cloud regions, for example us-central1. To retrieve management servers for all locations, use "-" for the '{location}' value.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListManagementServersResponseManagementServer

A pageable asynchronous sequence of ManagementServer resources.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedAsyncEnumerable<ListManagementServersResponse, ManagementServer> response = backupDRClient.ListManagementServersAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await foreach (ManagementServer item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
await foreach (ListManagementServersResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (ManagementServer item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<ManagementServer> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (ManagementServer item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

PollOnceCreateAutoProtectionPolicy(string, CallSettings)

public virtual Operation<AutoProtectionPolicy, OperationMetadata> PollOnceCreateAutoProtectionPolicy(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of CreateAutoProtectionPolicy.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationAutoProtectionPolicyOperationMetadata

The result of polling the operation.

PollOnceCreateAutoProtectionPolicyAsync(string, CallSettings)

public virtual Task<Operation<AutoProtectionPolicy, OperationMetadata>> PollOnceCreateAutoProtectionPolicyAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of CreateAutoProtectionPolicy.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationAutoProtectionPolicyOperationMetadata

A task representing the result of polling the operation.

PollOnceCreateAutoProtectionPolicyBinding(string, CallSettings)

public virtual Operation<AutoProtectionPolicyBinding, OperationMetadata> PollOnceCreateAutoProtectionPolicyBinding(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of CreateAutoProtectionPolicyBinding.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationAutoProtectionPolicyBindingOperationMetadata

The result of polling the operation.

PollOnceCreateAutoProtectionPolicyBindingAsync(string, CallSettings)

public virtual Task<Operation<AutoProtectionPolicyBinding, OperationMetadata>> PollOnceCreateAutoProtectionPolicyBindingAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of CreateAutoProtectionPolicyBinding.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationAutoProtectionPolicyBindingOperationMetadata

A task representing the result of polling the operation.

PollOnceCreateBackupPlan(string, CallSettings)

public virtual Operation<BackupPlan, OperationMetadata> PollOnceCreateBackupPlan(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of CreateBackupPlan.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanOperationMetadata

The result of polling the operation.

PollOnceCreateBackupPlanAssociation(string, CallSettings)

public virtual Operation<BackupPlanAssociation, OperationMetadata> PollOnceCreateBackupPlanAssociation(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of CreateBackupPlanAssociation.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanAssociationOperationMetadata

The result of polling the operation.

PollOnceCreateBackupPlanAssociationAsync(string, CallSettings)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> PollOnceCreateBackupPlanAssociationAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of CreateBackupPlanAssociation.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A task representing the result of polling the operation.

PollOnceCreateBackupPlanAsync(string, CallSettings)

public virtual Task<Operation<BackupPlan, OperationMetadata>> PollOnceCreateBackupPlanAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of CreateBackupPlan.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanOperationMetadata

A task representing the result of polling the operation.

PollOnceCreateBackupVault(string, CallSettings)

public virtual Operation<BackupVault, OperationMetadata> PollOnceCreateBackupVault(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of CreateBackupVault .

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupVaultOperationMetadata

The result of polling the operation.

PollOnceCreateBackupVaultAsync(string, CallSettings)

public virtual Task<Operation<BackupVault, OperationMetadata>> PollOnceCreateBackupVaultAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of CreateBackupVault.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupVaultOperationMetadata

A task representing the result of polling the operation.

PollOnceCreateManagementServer(string, CallSettings)

public virtual Operation<ManagementServer, OperationMetadata> PollOnceCreateManagementServer(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of CreateManagementServer.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationManagementServerOperationMetadata

The result of polling the operation.

PollOnceCreateManagementServerAsync(string, CallSettings)

public virtual Task<Operation<ManagementServer, OperationMetadata>> PollOnceCreateManagementServerAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of CreateManagementServer.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationManagementServerOperationMetadata

A task representing the result of polling the operation.

PollOnceDeleteAutoProtectionPolicy(string, CallSettings)

public virtual Operation<Empty, OperationMetadata> PollOnceDeleteAutoProtectionPolicy(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of DeleteAutoProtectionPolicy.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The result of polling the operation.

PollOnceDeleteAutoProtectionPolicyAsync(string, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> PollOnceDeleteAutoProtectionPolicyAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of DeleteAutoProtectionPolicy.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A task representing the result of polling the operation.

PollOnceDeleteBackup(string, CallSettings)

public virtual Operation<Backup, OperationMetadata> PollOnceDeleteBackup(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of DeleteBackup.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupOperationMetadata

The result of polling the operation.

PollOnceDeleteBackupAsync(string, CallSettings)

public virtual Task<Operation<Backup, OperationMetadata>> PollOnceDeleteBackupAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of DeleteBackup.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupOperationMetadata

A task representing the result of polling the operation.

PollOnceDeleteBackupPlan(string, CallSettings)

public virtual Operation<Empty, OperationMetadata> PollOnceDeleteBackupPlan(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of DeleteBackupPlan.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The result of polling the operation.

PollOnceDeleteBackupPlanAssociation(string, CallSettings)

public virtual Operation<Empty, OperationMetadata> PollOnceDeleteBackupPlanAssociation(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of DeleteBackupPlanAssociation.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The result of polling the operation.

PollOnceDeleteBackupPlanAssociationAsync(string, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> PollOnceDeleteBackupPlanAssociationAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of DeleteBackupPlanAssociation.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A task representing the result of polling the operation.

PollOnceDeleteBackupPlanAsync(string, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> PollOnceDeleteBackupPlanAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of DeleteBackupPlan.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A task representing the result of polling the operation.

PollOnceDeleteBackupVault(string, CallSettings)

public virtual Operation<Empty, OperationMetadata> PollOnceDeleteBackupVault(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of DeleteBackupVault .

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The result of polling the operation.

PollOnceDeleteBackupVaultAsync(string, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> PollOnceDeleteBackupVaultAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of DeleteBackupVault.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A task representing the result of polling the operation.

PollOnceDeleteManagementServer(string, CallSettings)

public virtual Operation<Empty, OperationMetadata> PollOnceDeleteManagementServer(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of DeleteManagementServer.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationEmptyOperationMetadata

The result of polling the operation.

PollOnceDeleteManagementServerAsync(string, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> PollOnceDeleteManagementServerAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of DeleteManagementServer.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationEmptyOperationMetadata

A task representing the result of polling the operation.

PollOnceInitializeService(string, CallSettings)

public virtual Operation<InitializeServiceResponse, OperationMetadata> PollOnceInitializeService(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of InitializeService .

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationInitializeServiceResponseOperationMetadata

The result of polling the operation.

PollOnceInitializeServiceAsync(string, CallSettings)

public virtual Task<Operation<InitializeServiceResponse, OperationMetadata>> PollOnceInitializeServiceAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of InitializeService.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationInitializeServiceResponseOperationMetadata

A task representing the result of polling the operation.

PollOnceInitiateDeleteAutoProtectionPolicyBinding(string, CallSettings)

public virtual Operation<AutoProtectionPolicyBinding, OperationMetadata> PollOnceInitiateDeleteAutoProtectionPolicyBinding(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of InitiateDeleteAutoProtectionPolicyBinding.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationAutoProtectionPolicyBindingOperationMetadata

The result of polling the operation.

PollOnceInitiateDeleteAutoProtectionPolicyBindingAsync(string, CallSettings)

public virtual Task<Operation<AutoProtectionPolicyBinding, OperationMetadata>> PollOnceInitiateDeleteAutoProtectionPolicyBindingAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of InitiateDeleteAutoProtectionPolicyBinding.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationAutoProtectionPolicyBindingOperationMetadata

A task representing the result of polling the operation.

PollOnceRestoreBackup(string, CallSettings)

public virtual Operation<RestoreBackupResponse, OperationMetadata> PollOnceRestoreBackup(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of RestoreBackup.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationRestoreBackupResponseOperationMetadata

The result of polling the operation.

PollOnceRestoreBackupAsync(string, CallSettings)

public virtual Task<Operation<RestoreBackupResponse, OperationMetadata>> PollOnceRestoreBackupAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of RestoreBackup.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationRestoreBackupResponseOperationMetadata

A task representing the result of polling the operation.

PollOnceTriggerBackup(string, CallSettings)

public virtual Operation<BackupPlanAssociation, OperationMetadata> PollOnceTriggerBackup(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of TriggerBackup.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanAssociationOperationMetadata

The result of polling the operation.

PollOnceTriggerBackupAsync(string, CallSettings)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> PollOnceTriggerBackupAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of TriggerBackup.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A task representing the result of polling the operation.

PollOnceUpdateAutoProtectionPolicy(string, CallSettings)

public virtual Operation<AutoProtectionPolicy, OperationMetadata> PollOnceUpdateAutoProtectionPolicy(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of UpdateAutoProtectionPolicy.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationAutoProtectionPolicyOperationMetadata

The result of polling the operation.

PollOnceUpdateAutoProtectionPolicyAsync(string, CallSettings)

public virtual Task<Operation<AutoProtectionPolicy, OperationMetadata>> PollOnceUpdateAutoProtectionPolicyAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of UpdateAutoProtectionPolicy.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationAutoProtectionPolicyOperationMetadata

A task representing the result of polling the operation.

PollOnceUpdateBackup(string, CallSettings)

public virtual Operation<Backup, OperationMetadata> PollOnceUpdateBackup(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of UpdateBackup.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupOperationMetadata

The result of polling the operation.

PollOnceUpdateBackupAsync(string, CallSettings)

public virtual Task<Operation<Backup, OperationMetadata>> PollOnceUpdateBackupAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of UpdateBackup.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupOperationMetadata

A task representing the result of polling the operation.

PollOnceUpdateBackupPlan(string, CallSettings)

public virtual Operation<BackupPlan, OperationMetadata> PollOnceUpdateBackupPlan(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of UpdateBackupPlan.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanOperationMetadata

The result of polling the operation.

PollOnceUpdateBackupPlanAssociation(string, CallSettings)

public virtual Operation<BackupPlanAssociation, OperationMetadata> PollOnceUpdateBackupPlanAssociation(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of UpdateBackupPlanAssociation.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanAssociationOperationMetadata

The result of polling the operation.

PollOnceUpdateBackupPlanAssociationAsync(string, CallSettings)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> PollOnceUpdateBackupPlanAssociationAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of UpdateBackupPlanAssociation.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A task representing the result of polling the operation.

PollOnceUpdateBackupPlanAsync(string, CallSettings)

public virtual Task<Operation<BackupPlan, OperationMetadata>> PollOnceUpdateBackupPlanAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of UpdateBackupPlan.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanOperationMetadata

A task representing the result of polling the operation.

PollOnceUpdateBackupVault(string, CallSettings)

public virtual Operation<BackupVault, OperationMetadata> PollOnceUpdateBackupVault(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of UpdateBackupVault .

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupVaultOperationMetadata

The result of polling the operation.

PollOnceUpdateBackupVaultAsync(string, CallSettings)

public virtual Task<Operation<BackupVault, OperationMetadata>> PollOnceUpdateBackupVaultAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of UpdateBackupVault.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupVaultOperationMetadata

A task representing the result of polling the operation.

PollOnceUpdateDataSource(string, CallSettings)

public virtual Operation<DataSource, OperationMetadata> PollOnceUpdateDataSource(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of UpdateDataSource.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationDataSourceOperationMetadata

The result of polling the operation.

PollOnceUpdateDataSourceAsync(string, CallSettings)

public virtual Task<Operation<DataSource, OperationMetadata>> PollOnceUpdateDataSourceAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of UpdateDataSource.

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationDataSourceOperationMetadata

A task representing the result of polling the operation.

RestoreBackup(BackupName, CallSettings)

public virtual Operation<RestoreBackupResponse, OperationMetadata> RestoreBackup(BackupName name, CallSettings callSettings = null)

Restore from a Backup

Parameters
Name Description
name BackupName

Required. The resource name of the Backup instance, in the format 'projects//locations//backupVaults//dataSources//backups/'.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationRestoreBackupResponseOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BackupName name = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]");
// Make the request
Operation<RestoreBackupResponse, OperationMetadata> response = backupDRClient.RestoreBackup(name);

// Poll until the returned long-running operation is complete
Operation<RestoreBackupResponse, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
RestoreBackupResponse result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<RestoreBackupResponse, OperationMetadata> retrievedResponse = backupDRClient.PollOnceRestoreBackup(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    RestoreBackupResponse retrievedResult = retrievedResponse.Result;
}

RestoreBackup(RestoreBackupRequest, CallSettings)

public virtual Operation<RestoreBackupResponse, OperationMetadata> RestoreBackup(RestoreBackupRequest request, CallSettings callSettings = null)

Restore from a Backup

Parameters
Name Description
request RestoreBackupRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationRestoreBackupResponseOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
RestoreBackupRequest request = new RestoreBackupRequest
{
    BackupName = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]"),
    RequestId = "",
    ComputeInstanceTargetEnvironment = new ComputeInstanceTargetEnvironment(),
    ComputeInstanceRestoreProperties = new ComputeInstanceRestoreProperties(),
    ClearOverridesFieldMask = new FieldMask(),
};
// Make the request
Operation<RestoreBackupResponse, OperationMetadata> response = backupDRClient.RestoreBackup(request);

// Poll until the returned long-running operation is complete
Operation<RestoreBackupResponse, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
RestoreBackupResponse result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<RestoreBackupResponse, OperationMetadata> retrievedResponse = backupDRClient.PollOnceRestoreBackup(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    RestoreBackupResponse retrievedResult = retrievedResponse.Result;
}

RestoreBackup(string, CallSettings)

public virtual Operation<RestoreBackupResponse, OperationMetadata> RestoreBackup(string name, CallSettings callSettings = null)

Restore from a Backup

Parameters
Name Description
name string

Required. The resource name of the Backup instance, in the format 'projects//locations//backupVaults//dataSources//backups/'.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationRestoreBackupResponseOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]/dataSources/[DATASOURCE]/backups/[BACKUP]";
// Make the request
Operation<RestoreBackupResponse, OperationMetadata> response = backupDRClient.RestoreBackup(name);

// Poll until the returned long-running operation is complete
Operation<RestoreBackupResponse, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
RestoreBackupResponse result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<RestoreBackupResponse, OperationMetadata> retrievedResponse = backupDRClient.PollOnceRestoreBackup(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    RestoreBackupResponse retrievedResult = retrievedResponse.Result;
}

RestoreBackupAsync(BackupName, CallSettings)

public virtual Task<Operation<RestoreBackupResponse, OperationMetadata>> RestoreBackupAsync(BackupName name, CallSettings callSettings = null)

Restore from a Backup

Parameters
Name Description
name BackupName

Required. The resource name of the Backup instance, in the format 'projects//locations//backupVaults//dataSources//backups/'.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationRestoreBackupResponseOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupName name = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]");
// Make the request
Operation<RestoreBackupResponse, OperationMetadata> response = await backupDRClient.RestoreBackupAsync(name);

// Poll until the returned long-running operation is complete
Operation<RestoreBackupResponse, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
RestoreBackupResponse result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<RestoreBackupResponse, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceRestoreBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    RestoreBackupResponse retrievedResult = retrievedResponse.Result;
}

RestoreBackupAsync(BackupName, CancellationToken)

public virtual Task<Operation<RestoreBackupResponse, OperationMetadata>> RestoreBackupAsync(BackupName name, CancellationToken cancellationToken)

Restore from a Backup

Parameters
Name Description
name BackupName

Required. The resource name of the Backup instance, in the format 'projects//locations//backupVaults//dataSources//backups/'.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationRestoreBackupResponseOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupName name = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]");
// Make the request
Operation<RestoreBackupResponse, OperationMetadata> response = await backupDRClient.RestoreBackupAsync(name);

// Poll until the returned long-running operation is complete
Operation<RestoreBackupResponse, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
RestoreBackupResponse result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<RestoreBackupResponse, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceRestoreBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    RestoreBackupResponse retrievedResult = retrievedResponse.Result;
}

RestoreBackupAsync(RestoreBackupRequest, CallSettings)

public virtual Task<Operation<RestoreBackupResponse, OperationMetadata>> RestoreBackupAsync(RestoreBackupRequest request, CallSettings callSettings = null)

Restore from a Backup

Parameters
Name Description
request RestoreBackupRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationRestoreBackupResponseOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
RestoreBackupRequest request = new RestoreBackupRequest
{
    BackupName = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]"),
    RequestId = "",
    ComputeInstanceTargetEnvironment = new ComputeInstanceTargetEnvironment(),
    ComputeInstanceRestoreProperties = new ComputeInstanceRestoreProperties(),
    ClearOverridesFieldMask = new FieldMask(),
};
// Make the request
Operation<RestoreBackupResponse, OperationMetadata> response = await backupDRClient.RestoreBackupAsync(request);

// Poll until the returned long-running operation is complete
Operation<RestoreBackupResponse, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
RestoreBackupResponse result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<RestoreBackupResponse, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceRestoreBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    RestoreBackupResponse retrievedResult = retrievedResponse.Result;
}

RestoreBackupAsync(RestoreBackupRequest, CancellationToken)

public virtual Task<Operation<RestoreBackupResponse, OperationMetadata>> RestoreBackupAsync(RestoreBackupRequest request, CancellationToken cancellationToken)

Restore from a Backup

Parameters
Name Description
request RestoreBackupRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationRestoreBackupResponseOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
RestoreBackupRequest request = new RestoreBackupRequest
{
    BackupName = BackupName.FromProjectLocationBackupvaultDatasourceBackup("[PROJECT]", "[LOCATION]", "[BACKUPVAULT]", "[DATASOURCE]", "[BACKUP]"),
    RequestId = "",
    ComputeInstanceTargetEnvironment = new ComputeInstanceTargetEnvironment(),
    ComputeInstanceRestoreProperties = new ComputeInstanceRestoreProperties(),
    ClearOverridesFieldMask = new FieldMask(),
};
// Make the request
Operation<RestoreBackupResponse, OperationMetadata> response = await backupDRClient.RestoreBackupAsync(request);

// Poll until the returned long-running operation is complete
Operation<RestoreBackupResponse, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
RestoreBackupResponse result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<RestoreBackupResponse, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceRestoreBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    RestoreBackupResponse retrievedResult = retrievedResponse.Result;
}

RestoreBackupAsync(string, CallSettings)

public virtual Task<Operation<RestoreBackupResponse, OperationMetadata>> RestoreBackupAsync(string name, CallSettings callSettings = null)

Restore from a Backup

Parameters
Name Description
name string

Required. The resource name of the Backup instance, in the format 'projects//locations//backupVaults//dataSources//backups/'.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationRestoreBackupResponseOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]/dataSources/[DATASOURCE]/backups/[BACKUP]";
// Make the request
Operation<RestoreBackupResponse, OperationMetadata> response = await backupDRClient.RestoreBackupAsync(name);

// Poll until the returned long-running operation is complete
Operation<RestoreBackupResponse, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
RestoreBackupResponse result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<RestoreBackupResponse, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceRestoreBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    RestoreBackupResponse retrievedResult = retrievedResponse.Result;
}

RestoreBackupAsync(string, CancellationToken)

public virtual Task<Operation<RestoreBackupResponse, OperationMetadata>> RestoreBackupAsync(string name, CancellationToken cancellationToken)

Restore from a Backup

Parameters
Name Description
name string

Required. The resource name of the Backup instance, in the format 'projects//locations//backupVaults//dataSources//backups/'.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationRestoreBackupResponseOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupVaults/[BACKUPVAULT]/dataSources/[DATASOURCE]/backups/[BACKUP]";
// Make the request
Operation<RestoreBackupResponse, OperationMetadata> response = await backupDRClient.RestoreBackupAsync(name);

// Poll until the returned long-running operation is complete
Operation<RestoreBackupResponse, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
RestoreBackupResponse result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<RestoreBackupResponse, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceRestoreBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    RestoreBackupResponse retrievedResult = retrievedResponse.Result;
}

ShutdownDefaultChannelsAsync()

public static Task ShutdownDefaultChannelsAsync()

Shuts down any channels automatically created by Create() and CreateAsync(CancellationToken). Channels which weren't automatically created are not affected.

Returns
Type Description
Task

A task representing the asynchronous shutdown operation.

Remarks

After calling this method, further calls to Create() and CreateAsync(CancellationToken) will create new channels, which could in turn be shut down by another call to this method.

TriggerBackup(BackupPlanAssociationName, string, CallSettings)

public virtual Operation<BackupPlanAssociation, OperationMetadata> TriggerBackup(BackupPlanAssociationName name, string ruleId, CallSettings callSettings = null)

Triggers a new Backup.

Parameters
Name Description
name BackupPlanAssociationName

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

ruleId string

Optional. backup rule_id for which a backup needs to be triggered. If not specified, on-demand backup with custom retention will be triggered.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanAssociationOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BackupPlanAssociationName name = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]");
string ruleId = "";
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = backupDRClient.TriggerBackup(name, ruleId);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = backupDRClient.PollOnceTriggerBackup(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

TriggerBackup(TriggerBackupRequest, CallSettings)

public virtual Operation<BackupPlanAssociation, OperationMetadata> TriggerBackup(TriggerBackupRequest request, CallSettings callSettings = null)

Triggers a new Backup.

Parameters
Name Description
request TriggerBackupRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanAssociationOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
TriggerBackupRequest request = new TriggerBackupRequest
{
    BackupPlanAssociationName = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]"),
    RuleId = "",
    RequestId = "",
    CustomRetentionDays = 0,
    Labels = { { "", "" }, },
};
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = backupDRClient.TriggerBackup(request);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = backupDRClient.PollOnceTriggerBackup(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

TriggerBackup(string, string, CallSettings)

public virtual Operation<BackupPlanAssociation, OperationMetadata> TriggerBackup(string name, string ruleId, CallSettings callSettings = null)

Triggers a new Backup.

Parameters
Name Description
name string

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

ruleId string

Optional. backup rule_id for which a backup needs to be triggered. If not specified, on-demand backup with custom retention will be triggered.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanAssociationOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlanAssociations/[BACKUP_PLAN_ASSOCIATION]";
string ruleId = "";
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = backupDRClient.TriggerBackup(name, ruleId);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = backupDRClient.PollOnceTriggerBackup(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

TriggerBackupAsync(BackupPlanAssociationName, string, CallSettings)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> TriggerBackupAsync(BackupPlanAssociationName name, string ruleId, CallSettings callSettings = null)

Triggers a new Backup.

Parameters
Name Description
name BackupPlanAssociationName

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

ruleId string

Optional. backup rule_id for which a backup needs to be triggered. If not specified, on-demand backup with custom retention will be triggered.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlanAssociationName name = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]");
string ruleId = "";
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = await backupDRClient.TriggerBackupAsync(name, ruleId);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceTriggerBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

TriggerBackupAsync(BackupPlanAssociationName, string, CancellationToken)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> TriggerBackupAsync(BackupPlanAssociationName name, string ruleId, CancellationToken cancellationToken)

Triggers a new Backup.

Parameters
Name Description
name BackupPlanAssociationName

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

ruleId string

Optional. backup rule_id for which a backup needs to be triggered. If not specified, on-demand backup with custom retention will be triggered.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlanAssociationName name = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]");
string ruleId = "";
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = await backupDRClient.TriggerBackupAsync(name, ruleId);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceTriggerBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

TriggerBackupAsync(TriggerBackupRequest, CallSettings)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> TriggerBackupAsync(TriggerBackupRequest request, CallSettings callSettings = null)

Triggers a new Backup.

Parameters
Name Description
request TriggerBackupRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
TriggerBackupRequest request = new TriggerBackupRequest
{
    BackupPlanAssociationName = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]"),
    RuleId = "",
    RequestId = "",
    CustomRetentionDays = 0,
    Labels = { { "", "" }, },
};
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = await backupDRClient.TriggerBackupAsync(request);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceTriggerBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

TriggerBackupAsync(TriggerBackupRequest, CancellationToken)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> TriggerBackupAsync(TriggerBackupRequest request, CancellationToken cancellationToken)

Triggers a new Backup.

Parameters
Name Description
request TriggerBackupRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
TriggerBackupRequest request = new TriggerBackupRequest
{
    BackupPlanAssociationName = BackupPlanAssociationName.FromProjectLocationBackupPlanAssociation("[PROJECT]", "[LOCATION]", "[BACKUP_PLAN_ASSOCIATION]"),
    RuleId = "",
    RequestId = "",
    CustomRetentionDays = 0,
    Labels = { { "", "" }, },
};
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = await backupDRClient.TriggerBackupAsync(request);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceTriggerBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

TriggerBackupAsync(string, string, CallSettings)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> TriggerBackupAsync(string name, string ruleId, CallSettings callSettings = null)

Triggers a new Backup.

Parameters
Name Description
name string

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

ruleId string

Optional. backup rule_id for which a backup needs to be triggered. If not specified, on-demand backup with custom retention will be triggered.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlanAssociations/[BACKUP_PLAN_ASSOCIATION]";
string ruleId = "";
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = await backupDRClient.TriggerBackupAsync(name, ruleId);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceTriggerBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

TriggerBackupAsync(string, string, CancellationToken)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> TriggerBackupAsync(string name, string ruleId, CancellationToken cancellationToken)

Triggers a new Backup.

Parameters
Name Description
name string

Required. Name of the backup plan association resource, in the format projects/{project}/locations/{location}/backupPlanAssociations/{backupPlanAssociationId}

ruleId string

Optional. backup rule_id for which a backup needs to be triggered. If not specified, on-demand backup with custom retention will be triggered.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/backupPlanAssociations/[BACKUP_PLAN_ASSOCIATION]";
string ruleId = "";
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = await backupDRClient.TriggerBackupAsync(name, ruleId);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceTriggerBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

UpdateAutoProtectionPolicy(AutoProtectionPolicy, FieldMask, CallSettings)

public virtual Operation<AutoProtectionPolicy, OperationMetadata> UpdateAutoProtectionPolicy(AutoProtectionPolicy autoProtectionPolicy, FieldMask updateMask, CallSettings callSettings = null)

Updates the parameters of a single AutoProtectionPolicy.

Parameters
Name Description
autoProtectionPolicy AutoProtectionPolicy

Required. The policy to update.

updateMask FieldMask

Required. Field mask is used to specify the fields to be overwritten in the AutoProtectionPolicy resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationAutoProtectionPolicyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
AutoProtectionPolicy autoProtectionPolicy = new AutoProtectionPolicy();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<AutoProtectionPolicy, OperationMetadata> response = backupDRClient.UpdateAutoProtectionPolicy(autoProtectionPolicy, updateMask);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicy, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
AutoProtectionPolicy result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicy, OperationMetadata> retrievedResponse = backupDRClient.PollOnceUpdateAutoProtectionPolicy(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicy retrievedResult = retrievedResponse.Result;
}

UpdateAutoProtectionPolicy(UpdateAutoProtectionPolicyRequest, CallSettings)

public virtual Operation<AutoProtectionPolicy, OperationMetadata> UpdateAutoProtectionPolicy(UpdateAutoProtectionPolicyRequest request, CallSettings callSettings = null)

Updates the parameters of a single AutoProtectionPolicy.

Parameters
Name Description
request UpdateAutoProtectionPolicyRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationAutoProtectionPolicyOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
UpdateAutoProtectionPolicyRequest request = new UpdateAutoProtectionPolicyRequest
{
    AutoProtectionPolicy = new AutoProtectionPolicy(),
    UpdateMask = new FieldMask(),
};
// Make the request
Operation<AutoProtectionPolicy, OperationMetadata> response = backupDRClient.UpdateAutoProtectionPolicy(request);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicy, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
AutoProtectionPolicy result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicy, OperationMetadata> retrievedResponse = backupDRClient.PollOnceUpdateAutoProtectionPolicy(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicy retrievedResult = retrievedResponse.Result;
}

UpdateAutoProtectionPolicyAsync(AutoProtectionPolicy, FieldMask, CallSettings)

public virtual Task<Operation<AutoProtectionPolicy, OperationMetadata>> UpdateAutoProtectionPolicyAsync(AutoProtectionPolicy autoProtectionPolicy, FieldMask updateMask, CallSettings callSettings = null)

Updates the parameters of a single AutoProtectionPolicy.

Parameters
Name Description
autoProtectionPolicy AutoProtectionPolicy

Required. The policy to update.

updateMask FieldMask

Required. Field mask is used to specify the fields to be overwritten in the AutoProtectionPolicy resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationAutoProtectionPolicyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
AutoProtectionPolicy autoProtectionPolicy = new AutoProtectionPolicy();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<AutoProtectionPolicy, OperationMetadata> response = await backupDRClient.UpdateAutoProtectionPolicyAsync(autoProtectionPolicy, updateMask);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicy, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicy result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicy, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateAutoProtectionPolicyAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicy retrievedResult = retrievedResponse.Result;
}

UpdateAutoProtectionPolicyAsync(AutoProtectionPolicy, FieldMask, CancellationToken)

public virtual Task<Operation<AutoProtectionPolicy, OperationMetadata>> UpdateAutoProtectionPolicyAsync(AutoProtectionPolicy autoProtectionPolicy, FieldMask updateMask, CancellationToken cancellationToken)

Updates the parameters of a single AutoProtectionPolicy.

Parameters
Name Description
autoProtectionPolicy AutoProtectionPolicy

Required. The policy to update.

updateMask FieldMask

Required. Field mask is used to specify the fields to be overwritten in the AutoProtectionPolicy resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationAutoProtectionPolicyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
AutoProtectionPolicy autoProtectionPolicy = new AutoProtectionPolicy();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<AutoProtectionPolicy, OperationMetadata> response = await backupDRClient.UpdateAutoProtectionPolicyAsync(autoProtectionPolicy, updateMask);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicy, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicy result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicy, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateAutoProtectionPolicyAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicy retrievedResult = retrievedResponse.Result;
}

UpdateAutoProtectionPolicyAsync(UpdateAutoProtectionPolicyRequest, CallSettings)

public virtual Task<Operation<AutoProtectionPolicy, OperationMetadata>> UpdateAutoProtectionPolicyAsync(UpdateAutoProtectionPolicyRequest request, CallSettings callSettings = null)

Updates the parameters of a single AutoProtectionPolicy.

Parameters
Name Description
request UpdateAutoProtectionPolicyRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationAutoProtectionPolicyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
UpdateAutoProtectionPolicyRequest request = new UpdateAutoProtectionPolicyRequest
{
    AutoProtectionPolicy = new AutoProtectionPolicy(),
    UpdateMask = new FieldMask(),
};
// Make the request
Operation<AutoProtectionPolicy, OperationMetadata> response = await backupDRClient.UpdateAutoProtectionPolicyAsync(request);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicy, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicy result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicy, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateAutoProtectionPolicyAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicy retrievedResult = retrievedResponse.Result;
}

UpdateAutoProtectionPolicyAsync(UpdateAutoProtectionPolicyRequest, CancellationToken)

public virtual Task<Operation<AutoProtectionPolicy, OperationMetadata>> UpdateAutoProtectionPolicyAsync(UpdateAutoProtectionPolicyRequest request, CancellationToken cancellationToken)

Updates the parameters of a single AutoProtectionPolicy.

Parameters
Name Description
request UpdateAutoProtectionPolicyRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationAutoProtectionPolicyOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
UpdateAutoProtectionPolicyRequest request = new UpdateAutoProtectionPolicyRequest
{
    AutoProtectionPolicy = new AutoProtectionPolicy(),
    UpdateMask = new FieldMask(),
};
// Make the request
Operation<AutoProtectionPolicy, OperationMetadata> response = await backupDRClient.UpdateAutoProtectionPolicyAsync(request);

// Poll until the returned long-running operation is complete
Operation<AutoProtectionPolicy, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
AutoProtectionPolicy result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<AutoProtectionPolicy, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateAutoProtectionPolicyAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    AutoProtectionPolicy retrievedResult = retrievedResponse.Result;
}

UpdateBackup(Backup, FieldMask, CallSettings)

public virtual Operation<Backup, OperationMetadata> UpdateBackup(Backup backup, FieldMask updateMask, CallSettings callSettings = null)

Updates the settings of a Backup.

Parameters
Name Description
backup Backup

Required. The resource being updated

updateMask FieldMask

Required. Field mask is used to specify the fields to be overwritten in the Backup resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then the request will fail.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
Backup backup = new Backup();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<Backup, OperationMetadata> response = backupDRClient.UpdateBackup(backup, updateMask);

// Poll until the returned long-running operation is complete
Operation<Backup, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Backup result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Backup, OperationMetadata> retrievedResponse = backupDRClient.PollOnceUpdateBackup(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Backup retrievedResult = retrievedResponse.Result;
}

UpdateBackup(UpdateBackupRequest, CallSettings)

public virtual Operation<Backup, OperationMetadata> UpdateBackup(UpdateBackupRequest request, CallSettings callSettings = null)

Updates the settings of a Backup.

Parameters
Name Description
request UpdateBackupRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
UpdateBackupRequest request = new UpdateBackupRequest
{
    UpdateMask = new FieldMask(),
    Backup = new Backup(),
    RequestId = "",
};
// Make the request
Operation<Backup, OperationMetadata> response = backupDRClient.UpdateBackup(request);

// Poll until the returned long-running operation is complete
Operation<Backup, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Backup result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Backup, OperationMetadata> retrievedResponse = backupDRClient.PollOnceUpdateBackup(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Backup retrievedResult = retrievedResponse.Result;
}

UpdateBackupAsync(Backup, FieldMask, CallSettings)

public virtual Task<Operation<Backup, OperationMetadata>> UpdateBackupAsync(Backup backup, FieldMask updateMask, CallSettings callSettings = null)

Updates the settings of a Backup.

Parameters
Name Description
backup Backup

Required. The resource being updated

updateMask FieldMask

Required. Field mask is used to specify the fields to be overwritten in the Backup resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then the request will fail.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
Backup backup = new Backup();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<Backup, OperationMetadata> response = await backupDRClient.UpdateBackupAsync(backup, updateMask);

// Poll until the returned long-running operation is complete
Operation<Backup, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Backup result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Backup, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Backup retrievedResult = retrievedResponse.Result;
}

UpdateBackupAsync(Backup, FieldMask, CancellationToken)

public virtual Task<Operation<Backup, OperationMetadata>> UpdateBackupAsync(Backup backup, FieldMask updateMask, CancellationToken cancellationToken)

Updates the settings of a Backup.

Parameters
Name Description
backup Backup

Required. The resource being updated

updateMask FieldMask

Required. Field mask is used to specify the fields to be overwritten in the Backup resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then the request will fail.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
Backup backup = new Backup();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<Backup, OperationMetadata> response = await backupDRClient.UpdateBackupAsync(backup, updateMask);

// Poll until the returned long-running operation is complete
Operation<Backup, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Backup result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Backup, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Backup retrievedResult = retrievedResponse.Result;
}

UpdateBackupAsync(UpdateBackupRequest, CallSettings)

public virtual Task<Operation<Backup, OperationMetadata>> UpdateBackupAsync(UpdateBackupRequest request, CallSettings callSettings = null)

Updates the settings of a Backup.

Parameters
Name Description
request UpdateBackupRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
UpdateBackupRequest request = new UpdateBackupRequest
{
    UpdateMask = new FieldMask(),
    Backup = new Backup(),
    RequestId = "",
};
// Make the request
Operation<Backup, OperationMetadata> response = await backupDRClient.UpdateBackupAsync(request);

// Poll until the returned long-running operation is complete
Operation<Backup, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Backup result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Backup, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Backup retrievedResult = retrievedResponse.Result;
}

UpdateBackupAsync(UpdateBackupRequest, CancellationToken)

public virtual Task<Operation<Backup, OperationMetadata>> UpdateBackupAsync(UpdateBackupRequest request, CancellationToken cancellationToken)

Updates the settings of a Backup.

Parameters
Name Description
request UpdateBackupRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
UpdateBackupRequest request = new UpdateBackupRequest
{
    UpdateMask = new FieldMask(),
    Backup = new Backup(),
    RequestId = "",
};
// Make the request
Operation<Backup, OperationMetadata> response = await backupDRClient.UpdateBackupAsync(request);

// Poll until the returned long-running operation is complete
Operation<Backup, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Backup result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Backup, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateBackupAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Backup retrievedResult = retrievedResponse.Result;
}

UpdateBackupPlan(BackupPlan, FieldMask, CallSettings)

public virtual Operation<BackupPlan, OperationMetadata> UpdateBackupPlan(BackupPlan backupPlan, FieldMask updateMask, CallSettings callSettings = null)

Update a BackupPlan.

Parameters
Name Description
backupPlan BackupPlan

Required. The resource being updated

updateMask FieldMask

Required. The list of fields to update. Field mask is used to specify the fields to be overwritten in the BackupPlan resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then the request will fail. Currently, these fields are supported in update: description, schedules, retention period, adding and removing Backup Rules.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BackupPlan backupPlan = new BackupPlan();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<BackupPlan, OperationMetadata> response = backupDRClient.UpdateBackupPlan(backupPlan, updateMask);

// Poll until the returned long-running operation is complete
Operation<BackupPlan, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupPlan result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlan, OperationMetadata> retrievedResponse = backupDRClient.PollOnceUpdateBackupPlan(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlan retrievedResult = retrievedResponse.Result;
}

UpdateBackupPlan(UpdateBackupPlanRequest, CallSettings)

public virtual Operation<BackupPlan, OperationMetadata> UpdateBackupPlan(UpdateBackupPlanRequest request, CallSettings callSettings = null)

Update a BackupPlan.

Parameters
Name Description
request UpdateBackupPlanRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
UpdateBackupPlanRequest request = new UpdateBackupPlanRequest
{
    BackupPlan = new BackupPlan(),
    UpdateMask = new FieldMask(),
    RequestId = "",
};
// Make the request
Operation<BackupPlan, OperationMetadata> response = backupDRClient.UpdateBackupPlan(request);

// Poll until the returned long-running operation is complete
Operation<BackupPlan, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupPlan result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlan, OperationMetadata> retrievedResponse = backupDRClient.PollOnceUpdateBackupPlan(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlan retrievedResult = retrievedResponse.Result;
}

UpdateBackupPlanAssociation(BackupPlanAssociation, FieldMask, CallSettings)

public virtual Operation<BackupPlanAssociation, OperationMetadata> UpdateBackupPlanAssociation(BackupPlanAssociation backupPlanAssociation, FieldMask updateMask, CallSettings callSettings = null)

Update a BackupPlanAssociation.

Parameters
Name Description
backupPlanAssociation BackupPlanAssociation

Required. The resource being updated

updateMask FieldMask

Required. The list of fields to update. Field mask is used to specify the fields to be overwritten in the BackupPlanAssociation resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then the request will fail. Currently backup_plan_association.backup_plan is the only supported field.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanAssociationOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BackupPlanAssociation backupPlanAssociation = new BackupPlanAssociation();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = backupDRClient.UpdateBackupPlanAssociation(backupPlanAssociation, updateMask);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = backupDRClient.PollOnceUpdateBackupPlanAssociation(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

UpdateBackupPlanAssociation(UpdateBackupPlanAssociationRequest, CallSettings)

public virtual Operation<BackupPlanAssociation, OperationMetadata> UpdateBackupPlanAssociation(UpdateBackupPlanAssociationRequest request, CallSettings callSettings = null)

Update a BackupPlanAssociation.

Parameters
Name Description
request UpdateBackupPlanAssociationRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupPlanAssociationOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
UpdateBackupPlanAssociationRequest request = new UpdateBackupPlanAssociationRequest
{
    BackupPlanAssociation = new BackupPlanAssociation(),
    UpdateMask = new FieldMask(),
    RequestId = "",
};
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = backupDRClient.UpdateBackupPlanAssociation(request);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = backupDRClient.PollOnceUpdateBackupPlanAssociation(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

UpdateBackupPlanAssociationAsync(BackupPlanAssociation, FieldMask, CallSettings)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> UpdateBackupPlanAssociationAsync(BackupPlanAssociation backupPlanAssociation, FieldMask updateMask, CallSettings callSettings = null)

Update a BackupPlanAssociation.

Parameters
Name Description
backupPlanAssociation BackupPlanAssociation

Required. The resource being updated

updateMask FieldMask

Required. The list of fields to update. Field mask is used to specify the fields to be overwritten in the BackupPlanAssociation resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then the request will fail. Currently backup_plan_association.backup_plan is the only supported field.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlanAssociation backupPlanAssociation = new BackupPlanAssociation();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = await backupDRClient.UpdateBackupPlanAssociationAsync(backupPlanAssociation, updateMask);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateBackupPlanAssociationAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

UpdateBackupPlanAssociationAsync(BackupPlanAssociation, FieldMask, CancellationToken)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> UpdateBackupPlanAssociationAsync(BackupPlanAssociation backupPlanAssociation, FieldMask updateMask, CancellationToken cancellationToken)

Update a BackupPlanAssociation.

Parameters
Name Description
backupPlanAssociation BackupPlanAssociation

Required. The resource being updated

updateMask FieldMask

Required. The list of fields to update. Field mask is used to specify the fields to be overwritten in the BackupPlanAssociation resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then the request will fail. Currently backup_plan_association.backup_plan is the only supported field.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlanAssociation backupPlanAssociation = new BackupPlanAssociation();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = await backupDRClient.UpdateBackupPlanAssociationAsync(backupPlanAssociation, updateMask);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateBackupPlanAssociationAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

UpdateBackupPlanAssociationAsync(UpdateBackupPlanAssociationRequest, CallSettings)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> UpdateBackupPlanAssociationAsync(UpdateBackupPlanAssociationRequest request, CallSettings callSettings = null)

Update a BackupPlanAssociation.

Parameters
Name Description
request UpdateBackupPlanAssociationRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
UpdateBackupPlanAssociationRequest request = new UpdateBackupPlanAssociationRequest
{
    BackupPlanAssociation = new BackupPlanAssociation(),
    UpdateMask = new FieldMask(),
    RequestId = "",
};
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = await backupDRClient.UpdateBackupPlanAssociationAsync(request);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateBackupPlanAssociationAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

UpdateBackupPlanAssociationAsync(UpdateBackupPlanAssociationRequest, CancellationToken)

public virtual Task<Operation<BackupPlanAssociation, OperationMetadata>> UpdateBackupPlanAssociationAsync(UpdateBackupPlanAssociationRequest request, CancellationToken cancellationToken)

Update a BackupPlanAssociation.

Parameters
Name Description
request UpdateBackupPlanAssociationRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupPlanAssociationOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
UpdateBackupPlanAssociationRequest request = new UpdateBackupPlanAssociationRequest
{
    BackupPlanAssociation = new BackupPlanAssociation(),
    UpdateMask = new FieldMask(),
    RequestId = "",
};
// Make the request
Operation<BackupPlanAssociation, OperationMetadata> response = await backupDRClient.UpdateBackupPlanAssociationAsync(request);

// Poll until the returned long-running operation is complete
Operation<BackupPlanAssociation, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlanAssociation result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlanAssociation, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateBackupPlanAssociationAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlanAssociation retrievedResult = retrievedResponse.Result;
}

UpdateBackupPlanAsync(BackupPlan, FieldMask, CallSettings)

public virtual Task<Operation<BackupPlan, OperationMetadata>> UpdateBackupPlanAsync(BackupPlan backupPlan, FieldMask updateMask, CallSettings callSettings = null)

Update a BackupPlan.

Parameters
Name Description
backupPlan BackupPlan

Required. The resource being updated

updateMask FieldMask

Required. The list of fields to update. Field mask is used to specify the fields to be overwritten in the BackupPlan resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then the request will fail. Currently, these fields are supported in update: description, schedules, retention period, adding and removing Backup Rules.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlan backupPlan = new BackupPlan();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<BackupPlan, OperationMetadata> response = await backupDRClient.UpdateBackupPlanAsync(backupPlan, updateMask);

// Poll until the returned long-running operation is complete
Operation<BackupPlan, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlan result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlan, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateBackupPlanAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlan retrievedResult = retrievedResponse.Result;
}

UpdateBackupPlanAsync(BackupPlan, FieldMask, CancellationToken)

public virtual Task<Operation<BackupPlan, OperationMetadata>> UpdateBackupPlanAsync(BackupPlan backupPlan, FieldMask updateMask, CancellationToken cancellationToken)

Update a BackupPlan.

Parameters
Name Description
backupPlan BackupPlan

Required. The resource being updated

updateMask FieldMask

Required. The list of fields to update. Field mask is used to specify the fields to be overwritten in the BackupPlan resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then the request will fail. Currently, these fields are supported in update: description, schedules, retention period, adding and removing Backup Rules.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupPlanOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupPlan backupPlan = new BackupPlan();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<BackupPlan, OperationMetadata> response = await backupDRClient.UpdateBackupPlanAsync(backupPlan, updateMask);

// Poll until the returned long-running operation is complete
Operation<BackupPlan, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlan result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlan, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateBackupPlanAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlan retrievedResult = retrievedResponse.Result;
}

UpdateBackupPlanAsync(UpdateBackupPlanRequest, CallSettings)

public virtual Task<Operation<BackupPlan, OperationMetadata>> UpdateBackupPlanAsync(UpdateBackupPlanRequest request, CallSettings callSettings = null)

Update a BackupPlan.

Parameters
Name Description
request UpdateBackupPlanRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupPlanOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
UpdateBackupPlanRequest request = new UpdateBackupPlanRequest
{
    BackupPlan = new BackupPlan(),
    UpdateMask = new FieldMask(),
    RequestId = "",
};
// Make the request
Operation<BackupPlan, OperationMetadata> response = await backupDRClient.UpdateBackupPlanAsync(request);

// Poll until the returned long-running operation is complete
Operation<BackupPlan, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlan result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlan, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateBackupPlanAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlan retrievedResult = retrievedResponse.Result;
}

UpdateBackupPlanAsync(UpdateBackupPlanRequest, CancellationToken)

public virtual Task<Operation<BackupPlan, OperationMetadata>> UpdateBackupPlanAsync(UpdateBackupPlanRequest request, CancellationToken cancellationToken)

Update a BackupPlan.

Parameters
Name Description
request UpdateBackupPlanRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupPlanOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
UpdateBackupPlanRequest request = new UpdateBackupPlanRequest
{
    BackupPlan = new BackupPlan(),
    UpdateMask = new FieldMask(),
    RequestId = "",
};
// Make the request
Operation<BackupPlan, OperationMetadata> response = await backupDRClient.UpdateBackupPlanAsync(request);

// Poll until the returned long-running operation is complete
Operation<BackupPlan, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupPlan result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupPlan, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateBackupPlanAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupPlan retrievedResult = retrievedResponse.Result;
}

UpdateBackupVault(BackupVault, FieldMask, CallSettings)

public virtual Operation<BackupVault, OperationMetadata> UpdateBackupVault(BackupVault backupVault, FieldMask updateMask, CallSettings callSettings = null)

Updates the settings of a BackupVault.

Parameters
Name Description
backupVault BackupVault

Required. The resource being updated

updateMask FieldMask

Required. Field mask is used to specify the fields to be overwritten in the BackupVault resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then the request will fail.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupVaultOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
BackupVault backupVault = new BackupVault();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<BackupVault, OperationMetadata> response = backupDRClient.UpdateBackupVault(backupVault, updateMask);

// Poll until the returned long-running operation is complete
Operation<BackupVault, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupVault result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupVault, OperationMetadata> retrievedResponse = backupDRClient.PollOnceUpdateBackupVault(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupVault retrievedResult = retrievedResponse.Result;
}

UpdateBackupVault(UpdateBackupVaultRequest, CallSettings)

public virtual Operation<BackupVault, OperationMetadata> UpdateBackupVault(UpdateBackupVaultRequest request, CallSettings callSettings = null)

Updates the settings of a BackupVault.

Parameters
Name Description
request UpdateBackupVaultRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationBackupVaultOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
UpdateBackupVaultRequest request = new UpdateBackupVaultRequest
{
    UpdateMask = new FieldMask(),
    BackupVault = new BackupVault(),
    RequestId = "",
    ValidateOnly = false,
    Force = false,
    ForceUpdateAccessRestriction = false,
};
// Make the request
Operation<BackupVault, OperationMetadata> response = backupDRClient.UpdateBackupVault(request);

// Poll until the returned long-running operation is complete
Operation<BackupVault, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BackupVault result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupVault, OperationMetadata> retrievedResponse = backupDRClient.PollOnceUpdateBackupVault(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupVault retrievedResult = retrievedResponse.Result;
}

UpdateBackupVaultAsync(BackupVault, FieldMask, CallSettings)

public virtual Task<Operation<BackupVault, OperationMetadata>> UpdateBackupVaultAsync(BackupVault backupVault, FieldMask updateMask, CallSettings callSettings = null)

Updates the settings of a BackupVault.

Parameters
Name Description
backupVault BackupVault

Required. The resource being updated

updateMask FieldMask

Required. Field mask is used to specify the fields to be overwritten in the BackupVault resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then the request will fail.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupVaultOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupVault backupVault = new BackupVault();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<BackupVault, OperationMetadata> response = await backupDRClient.UpdateBackupVaultAsync(backupVault, updateMask);

// Poll until the returned long-running operation is complete
Operation<BackupVault, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupVault result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupVault, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateBackupVaultAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupVault retrievedResult = retrievedResponse.Result;
}

UpdateBackupVaultAsync(BackupVault, FieldMask, CancellationToken)

public virtual Task<Operation<BackupVault, OperationMetadata>> UpdateBackupVaultAsync(BackupVault backupVault, FieldMask updateMask, CancellationToken cancellationToken)

Updates the settings of a BackupVault.

Parameters
Name Description
backupVault BackupVault

Required. The resource being updated

updateMask FieldMask

Required. Field mask is used to specify the fields to be overwritten in the BackupVault resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then the request will fail.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupVaultOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
BackupVault backupVault = new BackupVault();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<BackupVault, OperationMetadata> response = await backupDRClient.UpdateBackupVaultAsync(backupVault, updateMask);

// Poll until the returned long-running operation is complete
Operation<BackupVault, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupVault result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupVault, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateBackupVaultAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupVault retrievedResult = retrievedResponse.Result;
}

UpdateBackupVaultAsync(UpdateBackupVaultRequest, CallSettings)

public virtual Task<Operation<BackupVault, OperationMetadata>> UpdateBackupVaultAsync(UpdateBackupVaultRequest request, CallSettings callSettings = null)

Updates the settings of a BackupVault.

Parameters
Name Description
request UpdateBackupVaultRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationBackupVaultOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
UpdateBackupVaultRequest request = new UpdateBackupVaultRequest
{
    UpdateMask = new FieldMask(),
    BackupVault = new BackupVault(),
    RequestId = "",
    ValidateOnly = false,
    Force = false,
    ForceUpdateAccessRestriction = false,
};
// Make the request
Operation<BackupVault, OperationMetadata> response = await backupDRClient.UpdateBackupVaultAsync(request);

// Poll until the returned long-running operation is complete
Operation<BackupVault, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupVault result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupVault, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateBackupVaultAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupVault retrievedResult = retrievedResponse.Result;
}

UpdateBackupVaultAsync(UpdateBackupVaultRequest, CancellationToken)

public virtual Task<Operation<BackupVault, OperationMetadata>> UpdateBackupVaultAsync(UpdateBackupVaultRequest request, CancellationToken cancellationToken)

Updates the settings of a BackupVault.

Parameters
Name Description
request UpdateBackupVaultRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationBackupVaultOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
UpdateBackupVaultRequest request = new UpdateBackupVaultRequest
{
    UpdateMask = new FieldMask(),
    BackupVault = new BackupVault(),
    RequestId = "",
    ValidateOnly = false,
    Force = false,
    ForceUpdateAccessRestriction = false,
};
// Make the request
Operation<BackupVault, OperationMetadata> response = await backupDRClient.UpdateBackupVaultAsync(request);

// Poll until the returned long-running operation is complete
Operation<BackupVault, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BackupVault result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BackupVault, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateBackupVaultAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    BackupVault retrievedResult = retrievedResponse.Result;
}

UpdateDataSource(DataSource, FieldMask, CallSettings)

public virtual Operation<DataSource, OperationMetadata> UpdateDataSource(DataSource dataSource, FieldMask updateMask, CallSettings callSettings = null)

Updates the settings of a DataSource.

Parameters
Name Description
dataSource DataSource

Required. The resource being updated

updateMask FieldMask

Required. Field mask is used to specify the fields to be overwritten in the DataSource resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then the request will fail.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationDataSourceOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
DataSource dataSource = new DataSource();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<DataSource, OperationMetadata> response = backupDRClient.UpdateDataSource(dataSource, updateMask);

// Poll until the returned long-running operation is complete
Operation<DataSource, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
DataSource result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<DataSource, OperationMetadata> retrievedResponse = backupDRClient.PollOnceUpdateDataSource(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    DataSource retrievedResult = retrievedResponse.Result;
}

UpdateDataSource(UpdateDataSourceRequest, CallSettings)

public virtual Operation<DataSource, OperationMetadata> UpdateDataSource(UpdateDataSourceRequest request, CallSettings callSettings = null)

Updates the settings of a DataSource.

Parameters
Name Description
request UpdateDataSourceRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationDataSourceOperationMetadata

The RPC response.

Example
// Create client
BackupDRClient backupDRClient = BackupDRClient.Create();
// Initialize request argument(s)
UpdateDataSourceRequest request = new UpdateDataSourceRequest
{
    UpdateMask = new FieldMask(),
    DataSource = new DataSource(),
    RequestId = "",
    AllowMissing = false,
};
// Make the request
Operation<DataSource, OperationMetadata> response = backupDRClient.UpdateDataSource(request);

// Poll until the returned long-running operation is complete
Operation<DataSource, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
DataSource result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<DataSource, OperationMetadata> retrievedResponse = backupDRClient.PollOnceUpdateDataSource(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    DataSource retrievedResult = retrievedResponse.Result;
}

UpdateDataSourceAsync(DataSource, FieldMask, CallSettings)

public virtual Task<Operation<DataSource, OperationMetadata>> UpdateDataSourceAsync(DataSource dataSource, FieldMask updateMask, CallSettings callSettings = null)

Updates the settings of a DataSource.

Parameters
Name Description
dataSource DataSource

Required. The resource being updated

updateMask FieldMask

Required. Field mask is used to specify the fields to be overwritten in the DataSource resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then the request will fail.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationDataSourceOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DataSource dataSource = new DataSource();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<DataSource, OperationMetadata> response = await backupDRClient.UpdateDataSourceAsync(dataSource, updateMask);

// Poll until the returned long-running operation is complete
Operation<DataSource, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
DataSource result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<DataSource, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateDataSourceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    DataSource retrievedResult = retrievedResponse.Result;
}

UpdateDataSourceAsync(DataSource, FieldMask, CancellationToken)

public virtual Task<Operation<DataSource, OperationMetadata>> UpdateDataSourceAsync(DataSource dataSource, FieldMask updateMask, CancellationToken cancellationToken)

Updates the settings of a DataSource.

Parameters
Name Description
dataSource DataSource

Required. The resource being updated

updateMask FieldMask

Required. Field mask is used to specify the fields to be overwritten in the DataSource resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then the request will fail.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationDataSourceOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
DataSource dataSource = new DataSource();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<DataSource, OperationMetadata> response = await backupDRClient.UpdateDataSourceAsync(dataSource, updateMask);

// Poll until the returned long-running operation is complete
Operation<DataSource, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
DataSource result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<DataSource, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateDataSourceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    DataSource retrievedResult = retrievedResponse.Result;
}

UpdateDataSourceAsync(UpdateDataSourceRequest, CallSettings)

public virtual Task<Operation<DataSource, OperationMetadata>> UpdateDataSourceAsync(UpdateDataSourceRequest request, CallSettings callSettings = null)

Updates the settings of a DataSource.

Parameters
Name Description
request UpdateDataSourceRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationDataSourceOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
UpdateDataSourceRequest request = new UpdateDataSourceRequest
{
    UpdateMask = new FieldMask(),
    DataSource = new DataSource(),
    RequestId = "",
    AllowMissing = false,
};
// Make the request
Operation<DataSource, OperationMetadata> response = await backupDRClient.UpdateDataSourceAsync(request);

// Poll until the returned long-running operation is complete
Operation<DataSource, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
DataSource result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<DataSource, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateDataSourceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    DataSource retrievedResult = retrievedResponse.Result;
}

UpdateDataSourceAsync(UpdateDataSourceRequest, CancellationToken)

public virtual Task<Operation<DataSource, OperationMetadata>> UpdateDataSourceAsync(UpdateDataSourceRequest request, CancellationToken cancellationToken)

Updates the settings of a DataSource.

Parameters
Name Description
request UpdateDataSourceRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationDataSourceOperationMetadata

A Task containing the RPC response.

Example
// Create client
BackupDRClient backupDRClient = await BackupDRClient.CreateAsync();
// Initialize request argument(s)
UpdateDataSourceRequest request = new UpdateDataSourceRequest
{
    UpdateMask = new FieldMask(),
    DataSource = new DataSource(),
    RequestId = "",
    AllowMissing = false,
};
// Make the request
Operation<DataSource, OperationMetadata> response = await backupDRClient.UpdateDataSourceAsync(request);

// Poll until the returned long-running operation is complete
Operation<DataSource, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
DataSource result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<DataSource, OperationMetadata> retrievedResponse = await backupDRClient.PollOnceUpdateDataSourceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    DataSource retrievedResult = retrievedResponse.Result;
}