Artifact Registry v1 API - Class ArtifactRegistryClient (2.2.0)

public abstract class ArtifactRegistryClient

Reference documentation and code samples for the Artifact Registry v1 API class ArtifactRegistryClient.

ArtifactRegistry client wrapper, for convenient use.

Inheritance

object > ArtifactRegistryClient

Namespace

GoogleCloudGoogle.Cloud.ArtifactRegistryV1

Assembly

Google.Cloud.ArtifactRegistry.V1.dll

Remarks

The Artifact Registry API service.

Artifact Registry is an artifact management system for storing artifacts from different package management systems.

The resources managed by this API are:

  • Repositories, which group packages and their data.
  • Packages, which group versions and their tags.
  • Versions, which are specific forms of a package.
  • Tags, which represent alternative names for versions.
  • Files, which contain content and are optionally associated with a Package or Version.

Properties

CreateRepositoryOperationsClient

public virtual OperationsClient CreateRepositoryOperationsClient { get; }

The long-running operations client for CreateRepository.

Property Value
TypeDescription
OperationsClient

DefaultEndpoint

public static string DefaultEndpoint { get; }

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

Property Value
TypeDescription
string

DefaultScopes

public static IReadOnlyList<string> DefaultScopes { get; }

The default ArtifactRegistry scopes.

Property Value
TypeDescription
IReadOnlyListstring
Remarks

DeletePackageOperationsClient

public virtual OperationsClient DeletePackageOperationsClient { get; }

The long-running operations client for DeletePackage.

Property Value
TypeDescription
OperationsClient

DeleteRepositoryOperationsClient

public virtual OperationsClient DeleteRepositoryOperationsClient { get; }

The long-running operations client for DeleteRepository.

Property Value
TypeDescription
OperationsClient

DeleteVersionOperationsClient

public virtual OperationsClient DeleteVersionOperationsClient { get; }

The long-running operations client for DeleteVersion.

Property Value
TypeDescription
OperationsClient

GrpcClient

public virtual ArtifactRegistry.ArtifactRegistryClient GrpcClient { get; }

The underlying gRPC ArtifactRegistry client

Property Value
TypeDescription
ArtifactRegistryArtifactRegistryClient

ImportAptArtifactsOperationsClient

public virtual OperationsClient ImportAptArtifactsOperationsClient { get; }

The long-running operations client for ImportAptArtifacts.

Property Value
TypeDescription
OperationsClient

ImportYumArtifactsOperationsClient

public virtual OperationsClient ImportYumArtifactsOperationsClient { get; }

The long-running operations client for ImportYumArtifacts.

Property Value
TypeDescription
OperationsClient

LocationsClient

public virtual LocationsClient LocationsClient { get; }

The LocationsClient associated with this client.

Property Value
TypeDescription
LocationsClient

ServiceMetadata

public static ServiceMetadata ServiceMetadata { get; }

The service metadata associated with this client type.

Property Value
TypeDescription
ServiceMetadata

Methods

Create()

public static ArtifactRegistryClient Create()

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

Returns
TypeDescription
ArtifactRegistryClient

The created ArtifactRegistryClient.

CreateAsync(CancellationToken)

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

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

Parameter
NameDescription
cancellationTokenCancellationToken

The CancellationToken to use while creating the client.

Returns
TypeDescription
TaskArtifactRegistryClient

The task representing the created ArtifactRegistryClient.

CreateRepository(LocationName, Repository, string, CallSettings)

public virtual Operation<Repository, OperationMetadata> CreateRepository(LocationName parent, Repository repository, string repositoryId, CallSettings callSettings = null)

Creates a repository. The returned Operation will finish once the repository has been created. Its response will be the created Repository.

Parameters
NameDescription
parentLocationName

Required. The name of the parent resource where the repository will be created.

repositoryRepository

The repository to be created.

repositoryIdstring

The repository id to use for this repository.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
OperationRepositoryOperationMetadata

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
Repository repository = new Repository();
string repositoryId = "";
// Make the request
Operation<Repository, OperationMetadata> response = artifactRegistryClient.CreateRepository(parent, repository, repositoryId);

// Poll until the returned long-running operation is complete
Operation<Repository, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Repository 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<Repository, OperationMetadata> retrievedResponse = artifactRegistryClient.PollOnceCreateRepository(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Repository retrievedResult = retrievedResponse.Result;
}

CreateRepository(CreateRepositoryRequest, CallSettings)

public virtual Operation<Repository, OperationMetadata> CreateRepository(CreateRepositoryRequest request, CallSettings callSettings = null)

Creates a repository. The returned Operation will finish once the repository has been created. Its response will be the created Repository.

Parameters
NameDescription
requestCreateRepositoryRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
OperationRepositoryOperationMetadata

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
CreateRepositoryRequest request = new CreateRepositoryRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    RepositoryId = "",
    Repository = new Repository(),
};
// Make the request
Operation<Repository, OperationMetadata> response = artifactRegistryClient.CreateRepository(request);

// Poll until the returned long-running operation is complete
Operation<Repository, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Repository 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<Repository, OperationMetadata> retrievedResponse = artifactRegistryClient.PollOnceCreateRepository(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Repository retrievedResult = retrievedResponse.Result;
}

CreateRepository(string, Repository, string, CallSettings)

public virtual Operation<Repository, OperationMetadata> CreateRepository(string parent, Repository repository, string repositoryId, CallSettings callSettings = null)

Creates a repository. The returned Operation will finish once the repository has been created. Its response will be the created Repository.

Parameters
NameDescription
parentstring

Required. The name of the parent resource where the repository will be created.

repositoryRepository

The repository to be created.

repositoryIdstring

The repository id to use for this repository.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
OperationRepositoryOperationMetadata

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
Repository repository = new Repository();
string repositoryId = "";
// Make the request
Operation<Repository, OperationMetadata> response = artifactRegistryClient.CreateRepository(parent, repository, repositoryId);

// Poll until the returned long-running operation is complete
Operation<Repository, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Repository 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<Repository, OperationMetadata> retrievedResponse = artifactRegistryClient.PollOnceCreateRepository(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Repository retrievedResult = retrievedResponse.Result;
}

CreateRepositoryAsync(LocationName, Repository, string, CallSettings)

public virtual Task<Operation<Repository, OperationMetadata>> CreateRepositoryAsync(LocationName parent, Repository repository, string repositoryId, CallSettings callSettings = null)

Creates a repository. The returned Operation will finish once the repository has been created. Its response will be the created Repository.

Parameters
NameDescription
parentLocationName

Required. The name of the parent resource where the repository will be created.

repositoryRepository

The repository to be created.

repositoryIdstring

The repository id to use for this repository.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskOperationRepositoryOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
Repository repository = new Repository();
string repositoryId = "";
// Make the request
Operation<Repository, OperationMetadata> response = await artifactRegistryClient.CreateRepositoryAsync(parent, repository, repositoryId);

// Poll until the returned long-running operation is complete
Operation<Repository, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Repository 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<Repository, OperationMetadata> retrievedResponse = await artifactRegistryClient.PollOnceCreateRepositoryAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Repository retrievedResult = retrievedResponse.Result;
}

CreateRepositoryAsync(LocationName, Repository, string, CancellationToken)

public virtual Task<Operation<Repository, OperationMetadata>> CreateRepositoryAsync(LocationName parent, Repository repository, string repositoryId, CancellationToken cancellationToken)

Creates a repository. The returned Operation will finish once the repository has been created. Its response will be the created Repository.

Parameters
NameDescription
parentLocationName

Required. The name of the parent resource where the repository will be created.

repositoryRepository

The repository to be created.

repositoryIdstring

The repository id to use for this repository.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskOperationRepositoryOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
Repository repository = new Repository();
string repositoryId = "";
// Make the request
Operation<Repository, OperationMetadata> response = await artifactRegistryClient.CreateRepositoryAsync(parent, repository, repositoryId);

// Poll until the returned long-running operation is complete
Operation<Repository, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Repository 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<Repository, OperationMetadata> retrievedResponse = await artifactRegistryClient.PollOnceCreateRepositoryAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Repository retrievedResult = retrievedResponse.Result;
}

CreateRepositoryAsync(CreateRepositoryRequest, CallSettings)

public virtual Task<Operation<Repository, OperationMetadata>> CreateRepositoryAsync(CreateRepositoryRequest request, CallSettings callSettings = null)

Creates a repository. The returned Operation will finish once the repository has been created. Its response will be the created Repository.

Parameters
NameDescription
requestCreateRepositoryRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskOperationRepositoryOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
CreateRepositoryRequest request = new CreateRepositoryRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    RepositoryId = "",
    Repository = new Repository(),
};
// Make the request
Operation<Repository, OperationMetadata> response = await artifactRegistryClient.CreateRepositoryAsync(request);

// Poll until the returned long-running operation is complete
Operation<Repository, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Repository 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<Repository, OperationMetadata> retrievedResponse = await artifactRegistryClient.PollOnceCreateRepositoryAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Repository retrievedResult = retrievedResponse.Result;
}

CreateRepositoryAsync(CreateRepositoryRequest, CancellationToken)

public virtual Task<Operation<Repository, OperationMetadata>> CreateRepositoryAsync(CreateRepositoryRequest request, CancellationToken cancellationToken)

Creates a repository. The returned Operation will finish once the repository has been created. Its response will be the created Repository.

Parameters
NameDescription
requestCreateRepositoryRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskOperationRepositoryOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
CreateRepositoryRequest request = new CreateRepositoryRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    RepositoryId = "",
    Repository = new Repository(),
};
// Make the request
Operation<Repository, OperationMetadata> response = await artifactRegistryClient.CreateRepositoryAsync(request);

// Poll until the returned long-running operation is complete
Operation<Repository, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Repository 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<Repository, OperationMetadata> retrievedResponse = await artifactRegistryClient.PollOnceCreateRepositoryAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Repository retrievedResult = retrievedResponse.Result;
}

CreateRepositoryAsync(string, Repository, string, CallSettings)

public virtual Task<Operation<Repository, OperationMetadata>> CreateRepositoryAsync(string parent, Repository repository, string repositoryId, CallSettings callSettings = null)

Creates a repository. The returned Operation will finish once the repository has been created. Its response will be the created Repository.

Parameters
NameDescription
parentstring

Required. The name of the parent resource where the repository will be created.

repositoryRepository

The repository to be created.

repositoryIdstring

The repository id to use for this repository.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskOperationRepositoryOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
Repository repository = new Repository();
string repositoryId = "";
// Make the request
Operation<Repository, OperationMetadata> response = await artifactRegistryClient.CreateRepositoryAsync(parent, repository, repositoryId);

// Poll until the returned long-running operation is complete
Operation<Repository, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Repository 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<Repository, OperationMetadata> retrievedResponse = await artifactRegistryClient.PollOnceCreateRepositoryAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Repository retrievedResult = retrievedResponse.Result;
}

CreateRepositoryAsync(string, Repository, string, CancellationToken)

public virtual Task<Operation<Repository, OperationMetadata>> CreateRepositoryAsync(string parent, Repository repository, string repositoryId, CancellationToken cancellationToken)

Creates a repository. The returned Operation will finish once the repository has been created. Its response will be the created Repository.

Parameters
NameDescription
parentstring

Required. The name of the parent resource where the repository will be created.

repositoryRepository

The repository to be created.

repositoryIdstring

The repository id to use for this repository.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskOperationRepositoryOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
Repository repository = new Repository();
string repositoryId = "";
// Make the request
Operation<Repository, OperationMetadata> response = await artifactRegistryClient.CreateRepositoryAsync(parent, repository, repositoryId);

// Poll until the returned long-running operation is complete
Operation<Repository, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Repository 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<Repository, OperationMetadata> retrievedResponse = await artifactRegistryClient.PollOnceCreateRepositoryAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Repository retrievedResult = retrievedResponse.Result;
}

CreateTag(CreateTagRequest, CallSettings)

public virtual Tag CreateTag(CreateTagRequest request, CallSettings callSettings = null)

Creates a tag.

Parameters
NameDescription
requestCreateTagRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Tag

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
CreateTagRequest request = new CreateTagRequest
{
    Parent = "",
    TagId = "",
    Tag = new Tag(),
};
// Make the request
Tag response = artifactRegistryClient.CreateTag(request);

CreateTag(string, Tag, string, CallSettings)

public virtual Tag CreateTag(string parent, Tag tag, string tagId, CallSettings callSettings = null)

Creates a tag.

Parameters
NameDescription
parentstring

The name of the parent resource where the tag will be created.

tagTag

The tag to be created.

tagIdstring

The tag id to use for this repository.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Tag

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string parent = "";
Tag tag = new Tag();
string tagId = "";
// Make the request
Tag response = artifactRegistryClient.CreateTag(parent, tag, tagId);

CreateTagAsync(CreateTagRequest, CallSettings)

public virtual Task<Tag> CreateTagAsync(CreateTagRequest request, CallSettings callSettings = null)

Creates a tag.

Parameters
NameDescription
requestCreateTagRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskTag

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
CreateTagRequest request = new CreateTagRequest
{
    Parent = "",
    TagId = "",
    Tag = new Tag(),
};
// Make the request
Tag response = await artifactRegistryClient.CreateTagAsync(request);

CreateTagAsync(CreateTagRequest, CancellationToken)

public virtual Task<Tag> CreateTagAsync(CreateTagRequest request, CancellationToken cancellationToken)

Creates a tag.

Parameters
NameDescription
requestCreateTagRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskTag

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
CreateTagRequest request = new CreateTagRequest
{
    Parent = "",
    TagId = "",
    Tag = new Tag(),
};
// Make the request
Tag response = await artifactRegistryClient.CreateTagAsync(request);

CreateTagAsync(string, Tag, string, CallSettings)

public virtual Task<Tag> CreateTagAsync(string parent, Tag tag, string tagId, CallSettings callSettings = null)

Creates a tag.

Parameters
NameDescription
parentstring

The name of the parent resource where the tag will be created.

tagTag

The tag to be created.

tagIdstring

The tag id to use for this repository.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskTag

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string parent = "";
Tag tag = new Tag();
string tagId = "";
// Make the request
Tag response = await artifactRegistryClient.CreateTagAsync(parent, tag, tagId);

CreateTagAsync(string, Tag, string, CancellationToken)

public virtual Task<Tag> CreateTagAsync(string parent, Tag tag, string tagId, CancellationToken cancellationToken)

Creates a tag.

Parameters
NameDescription
parentstring

The name of the parent resource where the tag will be created.

tagTag

The tag to be created.

tagIdstring

The tag id to use for this repository.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskTag

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string parent = "";
Tag tag = new Tag();
string tagId = "";
// Make the request
Tag response = await artifactRegistryClient.CreateTagAsync(parent, tag, tagId);

DeletePackage(DeletePackageRequest, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeletePackage(DeletePackageRequest request, CallSettings callSettings = null)

Deletes a package and all of its versions and tags. The returned operation will complete once the package has been deleted.

Parameters
NameDescription
requestDeletePackageRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
DeletePackageRequest request = new DeletePackageRequest
{
    PackageName = PackageName.FromProjectLocationRepositoryPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PACKAGE]"),
};
// Make the request
Operation<Empty, OperationMetadata> response = artifactRegistryClient.DeletePackage(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 = artifactRegistryClient.PollOnceDeletePackage(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;
}

DeletePackage(PackageName, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeletePackage(PackageName name, CallSettings callSettings = null)

Deletes a package and all of its versions and tags. The returned operation will complete once the package has been deleted.

Parameters
NameDescription
namePackageName

Required. The name of the package to delete.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
PackageName name = PackageName.FromProjectLocationRepositoryPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PACKAGE]");
// Make the request
Operation<Empty, OperationMetadata> response = artifactRegistryClient.DeletePackage(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 = artifactRegistryClient.PollOnceDeletePackage(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;
}

DeletePackage(string, CallSettings)

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

Deletes a package and all of its versions and tags. The returned operation will complete once the package has been deleted.

Parameters
NameDescription
namestring

Required. The name of the package to delete.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/packages/[PACKAGE]";
// Make the request
Operation<Empty, OperationMetadata> response = artifactRegistryClient.DeletePackage(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 = artifactRegistryClient.PollOnceDeletePackage(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;
}

DeletePackageAsync(DeletePackageRequest, CallSettings)

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

Deletes a package and all of its versions and tags. The returned operation will complete once the package has been deleted.

Parameters
NameDescription
requestDeletePackageRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
DeletePackageRequest request = new DeletePackageRequest
{
    PackageName = PackageName.FromProjectLocationRepositoryPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PACKAGE]"),
};
// Make the request
Operation<Empty, OperationMetadata> response = await artifactRegistryClient.DeletePackageAsync(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 artifactRegistryClient.PollOnceDeletePackageAsync(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;
}

DeletePackageAsync(DeletePackageRequest, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeletePackageAsync(DeletePackageRequest request, CancellationToken cancellationToken)

Deletes a package and all of its versions and tags. The returned operation will complete once the package has been deleted.

Parameters
NameDescription
requestDeletePackageRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
DeletePackageRequest request = new DeletePackageRequest
{
    PackageName = PackageName.FromProjectLocationRepositoryPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PACKAGE]"),
};
// Make the request
Operation<Empty, OperationMetadata> response = await artifactRegistryClient.DeletePackageAsync(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 artifactRegistryClient.PollOnceDeletePackageAsync(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;
}

DeletePackageAsync(PackageName, CallSettings)

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

Deletes a package and all of its versions and tags. The returned operation will complete once the package has been deleted.

Parameters
NameDescription
namePackageName

Required. The name of the package to delete.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
PackageName name = PackageName.FromProjectLocationRepositoryPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PACKAGE]");
// Make the request
Operation<Empty, OperationMetadata> response = await artifactRegistryClient.DeletePackageAsync(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 artifactRegistryClient.PollOnceDeletePackageAsync(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;
}

DeletePackageAsync(PackageName, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeletePackageAsync(PackageName name, CancellationToken cancellationToken)

Deletes a package and all of its versions and tags. The returned operation will complete once the package has been deleted.

Parameters
NameDescription
namePackageName

Required. The name of the package to delete.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
PackageName name = PackageName.FromProjectLocationRepositoryPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PACKAGE]");
// Make the request
Operation<Empty, OperationMetadata> response = await artifactRegistryClient.DeletePackageAsync(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 artifactRegistryClient.PollOnceDeletePackageAsync(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;
}

DeletePackageAsync(string, CallSettings)

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

Deletes a package and all of its versions and tags. The returned operation will complete once the package has been deleted.

Parameters
NameDescription
namestring

Required. The name of the package to delete.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/packages/[PACKAGE]";
// Make the request
Operation<Empty, OperationMetadata> response = await artifactRegistryClient.DeletePackageAsync(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 artifactRegistryClient.PollOnceDeletePackageAsync(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;
}

DeletePackageAsync(string, CancellationToken)

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

Deletes a package and all of its versions and tags. The returned operation will complete once the package has been deleted.

Parameters
NameDescription
namestring

Required. The name of the package to delete.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/packages/[PACKAGE]";
// Make the request
Operation<Empty, OperationMetadata> response = await artifactRegistryClient.DeletePackageAsync(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 artifactRegistryClient.PollOnceDeletePackageAsync(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;
}

DeleteRepository(DeleteRepositoryRequest, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteRepository(DeleteRepositoryRequest request, CallSettings callSettings = null)

Deletes a repository and all of its contents. The returned Operation will finish once the repository has been deleted. It will not have any Operation metadata and will return a google.protobuf.Empty response.

Parameters
NameDescription
requestDeleteRepositoryRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
DeleteRepositoryRequest request = new DeleteRepositoryRequest
{
    RepositoryName = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]"),
};
// Make the request
Operation<Empty, OperationMetadata> response = artifactRegistryClient.DeleteRepository(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 = artifactRegistryClient.PollOnceDeleteRepository(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;
}

DeleteRepository(RepositoryName, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteRepository(RepositoryName name, CallSettings callSettings = null)

Deletes a repository and all of its contents. The returned Operation will finish once the repository has been deleted. It will not have any Operation metadata and will return a google.protobuf.Empty response.

Parameters
NameDescription
nameRepositoryName

Required. The name of the repository to delete.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
RepositoryName name = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
// Make the request
Operation<Empty, OperationMetadata> response = artifactRegistryClient.DeleteRepository(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 = artifactRegistryClient.PollOnceDeleteRepository(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;
}

DeleteRepository(string, CallSettings)

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

Deletes a repository and all of its contents. The returned Operation will finish once the repository has been deleted. It will not have any Operation metadata and will return a google.protobuf.Empty response.

Parameters
NameDescription
namestring

Required. The name of the repository to delete.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]";
// Make the request
Operation<Empty, OperationMetadata> response = artifactRegistryClient.DeleteRepository(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 = artifactRegistryClient.PollOnceDeleteRepository(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;
}

DeleteRepositoryAsync(DeleteRepositoryRequest, CallSettings)

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

Deletes a repository and all of its contents. The returned Operation will finish once the repository has been deleted. It will not have any Operation metadata and will return a google.protobuf.Empty response.

Parameters
NameDescription
requestDeleteRepositoryRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
DeleteRepositoryRequest request = new DeleteRepositoryRequest
{
    RepositoryName = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]"),
};
// Make the request
Operation<Empty, OperationMetadata> response = await artifactRegistryClient.DeleteRepositoryAsync(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 artifactRegistryClient.PollOnceDeleteRepositoryAsync(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;
}

DeleteRepositoryAsync(DeleteRepositoryRequest, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteRepositoryAsync(DeleteRepositoryRequest request, CancellationToken cancellationToken)

Deletes a repository and all of its contents. The returned Operation will finish once the repository has been deleted. It will not have any Operation metadata and will return a google.protobuf.Empty response.

Parameters
NameDescription
requestDeleteRepositoryRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
DeleteRepositoryRequest request = new DeleteRepositoryRequest
{
    RepositoryName = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]"),
};
// Make the request
Operation<Empty, OperationMetadata> response = await artifactRegistryClient.DeleteRepositoryAsync(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 artifactRegistryClient.PollOnceDeleteRepositoryAsync(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;
}

DeleteRepositoryAsync(RepositoryName, CallSettings)

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

Deletes a repository and all of its contents. The returned Operation will finish once the repository has been deleted. It will not have any Operation metadata and will return a google.protobuf.Empty response.

Parameters
NameDescription
nameRepositoryName

Required. The name of the repository to delete.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
RepositoryName name = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
// Make the request
Operation<Empty, OperationMetadata> response = await artifactRegistryClient.DeleteRepositoryAsync(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 artifactRegistryClient.PollOnceDeleteRepositoryAsync(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;
}

DeleteRepositoryAsync(RepositoryName, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteRepositoryAsync(RepositoryName name, CancellationToken cancellationToken)

Deletes a repository and all of its contents. The returned Operation will finish once the repository has been deleted. It will not have any Operation metadata and will return a google.protobuf.Empty response.

Parameters
NameDescription
nameRepositoryName

Required. The name of the repository to delete.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
RepositoryName name = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
// Make the request
Operation<Empty, OperationMetadata> response = await artifactRegistryClient.DeleteRepositoryAsync(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 artifactRegistryClient.PollOnceDeleteRepositoryAsync(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;
}

DeleteRepositoryAsync(string, CallSettings)

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

Deletes a repository and all of its contents. The returned Operation will finish once the repository has been deleted. It will not have any Operation metadata and will return a google.protobuf.Empty response.

Parameters
NameDescription
namestring

Required. The name of the repository to delete.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]";
// Make the request
Operation<Empty, OperationMetadata> response = await artifactRegistryClient.DeleteRepositoryAsync(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 artifactRegistryClient.PollOnceDeleteRepositoryAsync(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;
}

DeleteRepositoryAsync(string, CancellationToken)

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

Deletes a repository and all of its contents. The returned Operation will finish once the repository has been deleted. It will not have any Operation metadata and will return a google.protobuf.Empty response.

Parameters
NameDescription
namestring

Required. The name of the repository to delete.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]";
// Make the request
Operation<Empty, OperationMetadata> response = await artifactRegistryClient.DeleteRepositoryAsync(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 artifactRegistryClient.PollOnceDeleteRepositoryAsync(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;
}

DeleteTag(DeleteTagRequest, CallSettings)

public virtual void DeleteTag(DeleteTagRequest request, CallSettings callSettings = null)

Deletes a tag.

Parameters
NameDescription
requestDeleteTagRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
DeleteTagRequest request = new DeleteTagRequest { Name = "", };
// Make the request
artifactRegistryClient.DeleteTag(request);

DeleteTag(string, CallSettings)

public virtual void DeleteTag(string name, CallSettings callSettings = null)

Deletes a tag.

Parameters
NameDescription
namestring

The name of the tag to delete.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string name = "";
// Make the request
artifactRegistryClient.DeleteTag(name);

DeleteTagAsync(DeleteTagRequest, CallSettings)

public virtual Task DeleteTagAsync(DeleteTagRequest request, CallSettings callSettings = null)

Deletes a tag.

Parameters
NameDescription
requestDeleteTagRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
DeleteTagRequest request = new DeleteTagRequest { Name = "", };
// Make the request
await artifactRegistryClient.DeleteTagAsync(request);

DeleteTagAsync(DeleteTagRequest, CancellationToken)

public virtual Task DeleteTagAsync(DeleteTagRequest request, CancellationToken cancellationToken)

Deletes a tag.

Parameters
NameDescription
requestDeleteTagRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
DeleteTagRequest request = new DeleteTagRequest { Name = "", };
// Make the request
await artifactRegistryClient.DeleteTagAsync(request);

DeleteTagAsync(string, CallSettings)

public virtual Task DeleteTagAsync(string name, CallSettings callSettings = null)

Deletes a tag.

Parameters
NameDescription
namestring

The name of the tag to delete.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
await artifactRegistryClient.DeleteTagAsync(name);

DeleteTagAsync(string, CancellationToken)

public virtual Task DeleteTagAsync(string name, CancellationToken cancellationToken)

Deletes a tag.

Parameters
NameDescription
namestring

The name of the tag to delete.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
await artifactRegistryClient.DeleteTagAsync(name);

DeleteVersion(DeleteVersionRequest, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteVersion(DeleteVersionRequest request, CallSettings callSettings = null)

Deletes a version and all of its content. The returned operation will complete once the version has been deleted.

Parameters
NameDescription
requestDeleteVersionRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
DeleteVersionRequest request = new DeleteVersionRequest
{
    Name = "",
    Force = false,
};
// Make the request
Operation<Empty, OperationMetadata> response = artifactRegistryClient.DeleteVersion(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 = artifactRegistryClient.PollOnceDeleteVersion(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;
}

DeleteVersion(string, CallSettings)

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

Deletes a version and all of its content. The returned operation will complete once the version has been deleted.

Parameters
NameDescription
namestring

The name of the version to delete.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
OperationEmptyOperationMetadata

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Empty, OperationMetadata> response = artifactRegistryClient.DeleteVersion(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 = artifactRegistryClient.PollOnceDeleteVersion(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;
}

DeleteVersionAsync(DeleteVersionRequest, CallSettings)

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

Deletes a version and all of its content. The returned operation will complete once the version has been deleted.

Parameters
NameDescription
requestDeleteVersionRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
DeleteVersionRequest request = new DeleteVersionRequest
{
    Name = "",
    Force = false,
};
// Make the request
Operation<Empty, OperationMetadata> response = await artifactRegistryClient.DeleteVersionAsync(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 artifactRegistryClient.PollOnceDeleteVersionAsync(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;
}

DeleteVersionAsync(DeleteVersionRequest, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteVersionAsync(DeleteVersionRequest request, CancellationToken cancellationToken)

Deletes a version and all of its content. The returned operation will complete once the version has been deleted.

Parameters
NameDescription
requestDeleteVersionRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
DeleteVersionRequest request = new DeleteVersionRequest
{
    Name = "",
    Force = false,
};
// Make the request
Operation<Empty, OperationMetadata> response = await artifactRegistryClient.DeleteVersionAsync(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 artifactRegistryClient.PollOnceDeleteVersionAsync(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;
}

DeleteVersionAsync(string, CallSettings)

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

Deletes a version and all of its content. The returned operation will complete once the version has been deleted.

Parameters
NameDescription
namestring

The name of the version to delete.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Empty, OperationMetadata> response = await artifactRegistryClient.DeleteVersionAsync(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 artifactRegistryClient.PollOnceDeleteVersionAsync(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;
}

DeleteVersionAsync(string, CancellationToken)

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

Deletes a version and all of its content. The returned operation will complete once the version has been deleted.

Parameters
NameDescription
namestring

The name of the version to delete.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskOperationEmptyOperationMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Empty, OperationMetadata> response = await artifactRegistryClient.DeleteVersionAsync(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 artifactRegistryClient.PollOnceDeleteVersionAsync(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;
}

GetDockerImage(DockerImageName, CallSettings)

public virtual DockerImage GetDockerImage(DockerImageName name, CallSettings callSettings = null)

Gets a docker image.

Parameters
NameDescription
nameDockerImageName

Required. The name of the docker images.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
DockerImage

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
DockerImageName name = DockerImageName.FromProjectLocationRepositoryDockerImage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[DOCKER_IMAGE]");
// Make the request
DockerImage response = artifactRegistryClient.GetDockerImage(name);

GetDockerImage(GetDockerImageRequest, CallSettings)

public virtual DockerImage GetDockerImage(GetDockerImageRequest request, CallSettings callSettings = null)

Gets a docker image.

Parameters
NameDescription
requestGetDockerImageRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
DockerImage

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
GetDockerImageRequest request = new GetDockerImageRequest
{
    DockerImageName = DockerImageName.FromProjectLocationRepositoryDockerImage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[DOCKER_IMAGE]"),
};
// Make the request
DockerImage response = artifactRegistryClient.GetDockerImage(request);

GetDockerImage(string, CallSettings)

public virtual DockerImage GetDockerImage(string name, CallSettings callSettings = null)

Gets a docker image.

Parameters
NameDescription
namestring

Required. The name of the docker images.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
DockerImage

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/dockerImages/[DOCKER_IMAGE]";
// Make the request
DockerImage response = artifactRegistryClient.GetDockerImage(name);

GetDockerImageAsync(DockerImageName, CallSettings)

public virtual Task<DockerImage> GetDockerImageAsync(DockerImageName name, CallSettings callSettings = null)

Gets a docker image.

Parameters
NameDescription
nameDockerImageName

Required. The name of the docker images.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskDockerImage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
DockerImageName name = DockerImageName.FromProjectLocationRepositoryDockerImage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[DOCKER_IMAGE]");
// Make the request
DockerImage response = await artifactRegistryClient.GetDockerImageAsync(name);

GetDockerImageAsync(DockerImageName, CancellationToken)

public virtual Task<DockerImage> GetDockerImageAsync(DockerImageName name, CancellationToken cancellationToken)

Gets a docker image.

Parameters
NameDescription
nameDockerImageName

Required. The name of the docker images.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskDockerImage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
DockerImageName name = DockerImageName.FromProjectLocationRepositoryDockerImage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[DOCKER_IMAGE]");
// Make the request
DockerImage response = await artifactRegistryClient.GetDockerImageAsync(name);

GetDockerImageAsync(GetDockerImageRequest, CallSettings)

public virtual Task<DockerImage> GetDockerImageAsync(GetDockerImageRequest request, CallSettings callSettings = null)

Gets a docker image.

Parameters
NameDescription
requestGetDockerImageRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskDockerImage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetDockerImageRequest request = new GetDockerImageRequest
{
    DockerImageName = DockerImageName.FromProjectLocationRepositoryDockerImage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[DOCKER_IMAGE]"),
};
// Make the request
DockerImage response = await artifactRegistryClient.GetDockerImageAsync(request);

GetDockerImageAsync(GetDockerImageRequest, CancellationToken)

public virtual Task<DockerImage> GetDockerImageAsync(GetDockerImageRequest request, CancellationToken cancellationToken)

Gets a docker image.

Parameters
NameDescription
requestGetDockerImageRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskDockerImage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetDockerImageRequest request = new GetDockerImageRequest
{
    DockerImageName = DockerImageName.FromProjectLocationRepositoryDockerImage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[DOCKER_IMAGE]"),
};
// Make the request
DockerImage response = await artifactRegistryClient.GetDockerImageAsync(request);

GetDockerImageAsync(string, CallSettings)

public virtual Task<DockerImage> GetDockerImageAsync(string name, CallSettings callSettings = null)

Gets a docker image.

Parameters
NameDescription
namestring

Required. The name of the docker images.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskDockerImage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/dockerImages/[DOCKER_IMAGE]";
// Make the request
DockerImage response = await artifactRegistryClient.GetDockerImageAsync(name);

GetDockerImageAsync(string, CancellationToken)

public virtual Task<DockerImage> GetDockerImageAsync(string name, CancellationToken cancellationToken)

Gets a docker image.

Parameters
NameDescription
namestring

Required. The name of the docker images.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskDockerImage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/dockerImages/[DOCKER_IMAGE]";
// Make the request
DockerImage response = await artifactRegistryClient.GetDockerImageAsync(name);

GetFile(FileName, CallSettings)

public virtual File GetFile(FileName name, CallSettings callSettings = null)

Gets a file.

Parameters
NameDescription
nameFileName

Required. The name of the file to retrieve.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
File

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
FileName name = FileName.FromProjectLocationRepositoryFile("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[FILE]");
// Make the request
File response = artifactRegistryClient.GetFile(name);

GetFile(GetFileRequest, CallSettings)

public virtual File GetFile(GetFileRequest request, CallSettings callSettings = null)

Gets a file.

Parameters
NameDescription
requestGetFileRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
File

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
GetFileRequest request = new GetFileRequest
{
    FileName = FileName.FromProjectLocationRepositoryFile("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[FILE]"),
};
// Make the request
File response = artifactRegistryClient.GetFile(request);

GetFile(string, CallSettings)

public virtual File GetFile(string name, CallSettings callSettings = null)

Gets a file.

Parameters
NameDescription
namestring

Required. The name of the file to retrieve.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
File

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/files/[FILE]";
// Make the request
File response = artifactRegistryClient.GetFile(name);

GetFileAsync(FileName, CallSettings)

public virtual Task<File> GetFileAsync(FileName name, CallSettings callSettings = null)

Gets a file.

Parameters
NameDescription
nameFileName

Required. The name of the file to retrieve.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskFile

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
FileName name = FileName.FromProjectLocationRepositoryFile("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[FILE]");
// Make the request
File response = await artifactRegistryClient.GetFileAsync(name);

GetFileAsync(FileName, CancellationToken)

public virtual Task<File> GetFileAsync(FileName name, CancellationToken cancellationToken)

Gets a file.

Parameters
NameDescription
nameFileName

Required. The name of the file to retrieve.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskFile

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
FileName name = FileName.FromProjectLocationRepositoryFile("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[FILE]");
// Make the request
File response = await artifactRegistryClient.GetFileAsync(name);

GetFileAsync(GetFileRequest, CallSettings)

public virtual Task<File> GetFileAsync(GetFileRequest request, CallSettings callSettings = null)

Gets a file.

Parameters
NameDescription
requestGetFileRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskFile

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetFileRequest request = new GetFileRequest
{
    FileName = FileName.FromProjectLocationRepositoryFile("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[FILE]"),
};
// Make the request
File response = await artifactRegistryClient.GetFileAsync(request);

GetFileAsync(GetFileRequest, CancellationToken)

public virtual Task<File> GetFileAsync(GetFileRequest request, CancellationToken cancellationToken)

Gets a file.

Parameters
NameDescription
requestGetFileRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskFile

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetFileRequest request = new GetFileRequest
{
    FileName = FileName.FromProjectLocationRepositoryFile("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[FILE]"),
};
// Make the request
File response = await artifactRegistryClient.GetFileAsync(request);

GetFileAsync(string, CallSettings)

public virtual Task<File> GetFileAsync(string name, CallSettings callSettings = null)

Gets a file.

Parameters
NameDescription
namestring

Required. The name of the file to retrieve.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskFile

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/files/[FILE]";
// Make the request
File response = await artifactRegistryClient.GetFileAsync(name);

GetFileAsync(string, CancellationToken)

public virtual Task<File> GetFileAsync(string name, CancellationToken cancellationToken)

Gets a file.

Parameters
NameDescription
namestring

Required. The name of the file to retrieve.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskFile

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/files/[FILE]";
// Make the request
File response = await artifactRegistryClient.GetFileAsync(name);

GetIamPolicy(GetIamPolicyRequest, CallSettings)

public virtual Policy GetIamPolicy(GetIamPolicyRequest request, CallSettings callSettings = null)

Gets the IAM policy for a given resource.

Parameters
NameDescription
requestGetIamPolicyRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Policy

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
GetIamPolicyRequest request = new GetIamPolicyRequest
{
    ResourceAsResourceName = new UnparsedResourceName("a/wildcard/resource"),
    Options = new GetPolicyOptions(),
};
// Make the request
Policy response = artifactRegistryClient.GetIamPolicy(request);

GetIamPolicyAsync(GetIamPolicyRequest, CallSettings)

public virtual Task<Policy> GetIamPolicyAsync(GetIamPolicyRequest request, CallSettings callSettings = null)

Gets the IAM policy for a given resource.

Parameters
NameDescription
requestGetIamPolicyRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskPolicy

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetIamPolicyRequest request = new GetIamPolicyRequest
{
    ResourceAsResourceName = new UnparsedResourceName("a/wildcard/resource"),
    Options = new GetPolicyOptions(),
};
// Make the request
Policy response = await artifactRegistryClient.GetIamPolicyAsync(request);

GetIamPolicyAsync(GetIamPolicyRequest, CancellationToken)

public virtual Task<Policy> GetIamPolicyAsync(GetIamPolicyRequest request, CancellationToken cancellationToken)

Gets the IAM policy for a given resource.

Parameters
NameDescription
requestGetIamPolicyRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskPolicy

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetIamPolicyRequest request = new GetIamPolicyRequest
{
    ResourceAsResourceName = new UnparsedResourceName("a/wildcard/resource"),
    Options = new GetPolicyOptions(),
};
// Make the request
Policy response = await artifactRegistryClient.GetIamPolicyAsync(request);

GetMavenArtifact(GetMavenArtifactRequest, CallSettings)

public virtual MavenArtifact GetMavenArtifact(GetMavenArtifactRequest request, CallSettings callSettings = null)

Gets a maven artifact.

Parameters
NameDescription
requestGetMavenArtifactRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
MavenArtifact

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
GetMavenArtifactRequest request = new GetMavenArtifactRequest
{
    MavenArtifactName = MavenArtifactName.FromProjectLocationRepositoryMavenArtifact("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[MAVEN_ARTIFACT]"),
};
// Make the request
MavenArtifact response = artifactRegistryClient.GetMavenArtifact(request);

GetMavenArtifact(MavenArtifactName, CallSettings)

public virtual MavenArtifact GetMavenArtifact(MavenArtifactName name, CallSettings callSettings = null)

Gets a maven artifact.

Parameters
NameDescription
nameMavenArtifactName

Required. The name of the maven artifact.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
MavenArtifact

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
MavenArtifactName name = MavenArtifactName.FromProjectLocationRepositoryMavenArtifact("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[MAVEN_ARTIFACT]");
// Make the request
MavenArtifact response = artifactRegistryClient.GetMavenArtifact(name);

GetMavenArtifact(string, CallSettings)

public virtual MavenArtifact GetMavenArtifact(string name, CallSettings callSettings = null)

Gets a maven artifact.

Parameters
NameDescription
namestring

Required. The name of the maven artifact.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
MavenArtifact

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/mavenArtifacts/[MAVEN_ARTIFACT]";
// Make the request
MavenArtifact response = artifactRegistryClient.GetMavenArtifact(name);

GetMavenArtifactAsync(GetMavenArtifactRequest, CallSettings)

public virtual Task<MavenArtifact> GetMavenArtifactAsync(GetMavenArtifactRequest request, CallSettings callSettings = null)

Gets a maven artifact.

Parameters
NameDescription
requestGetMavenArtifactRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskMavenArtifact

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetMavenArtifactRequest request = new GetMavenArtifactRequest
{
    MavenArtifactName = MavenArtifactName.FromProjectLocationRepositoryMavenArtifact("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[MAVEN_ARTIFACT]"),
};
// Make the request
MavenArtifact response = await artifactRegistryClient.GetMavenArtifactAsync(request);

GetMavenArtifactAsync(GetMavenArtifactRequest, CancellationToken)

public virtual Task<MavenArtifact> GetMavenArtifactAsync(GetMavenArtifactRequest request, CancellationToken cancellationToken)

Gets a maven artifact.

Parameters
NameDescription
requestGetMavenArtifactRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskMavenArtifact

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetMavenArtifactRequest request = new GetMavenArtifactRequest
{
    MavenArtifactName = MavenArtifactName.FromProjectLocationRepositoryMavenArtifact("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[MAVEN_ARTIFACT]"),
};
// Make the request
MavenArtifact response = await artifactRegistryClient.GetMavenArtifactAsync(request);

GetMavenArtifactAsync(MavenArtifactName, CallSettings)

public virtual Task<MavenArtifact> GetMavenArtifactAsync(MavenArtifactName name, CallSettings callSettings = null)

Gets a maven artifact.

Parameters
NameDescription
nameMavenArtifactName

Required. The name of the maven artifact.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskMavenArtifact

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
MavenArtifactName name = MavenArtifactName.FromProjectLocationRepositoryMavenArtifact("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[MAVEN_ARTIFACT]");
// Make the request
MavenArtifact response = await artifactRegistryClient.GetMavenArtifactAsync(name);

GetMavenArtifactAsync(MavenArtifactName, CancellationToken)

public virtual Task<MavenArtifact> GetMavenArtifactAsync(MavenArtifactName name, CancellationToken cancellationToken)

Gets a maven artifact.

Parameters
NameDescription
nameMavenArtifactName

Required. The name of the maven artifact.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskMavenArtifact

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
MavenArtifactName name = MavenArtifactName.FromProjectLocationRepositoryMavenArtifact("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[MAVEN_ARTIFACT]");
// Make the request
MavenArtifact response = await artifactRegistryClient.GetMavenArtifactAsync(name);

GetMavenArtifactAsync(string, CallSettings)

public virtual Task<MavenArtifact> GetMavenArtifactAsync(string name, CallSettings callSettings = null)

Gets a maven artifact.

Parameters
NameDescription
namestring

Required. The name of the maven artifact.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskMavenArtifact

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/mavenArtifacts/[MAVEN_ARTIFACT]";
// Make the request
MavenArtifact response = await artifactRegistryClient.GetMavenArtifactAsync(name);

GetMavenArtifactAsync(string, CancellationToken)

public virtual Task<MavenArtifact> GetMavenArtifactAsync(string name, CancellationToken cancellationToken)

Gets a maven artifact.

Parameters
NameDescription
namestring

Required. The name of the maven artifact.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskMavenArtifact

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/mavenArtifacts/[MAVEN_ARTIFACT]";
// Make the request
MavenArtifact response = await artifactRegistryClient.GetMavenArtifactAsync(name);

GetNpmPackage(GetNpmPackageRequest, CallSettings)

public virtual NpmPackage GetNpmPackage(GetNpmPackageRequest request, CallSettings callSettings = null)

Gets a npm package.

Parameters
NameDescription
requestGetNpmPackageRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
NpmPackage

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
GetNpmPackageRequest request = new GetNpmPackageRequest
{
    NpmPackageName = NpmPackageName.FromProjectLocationRepositoryNpmPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[NPM_PACKAGE]"),
};
// Make the request
NpmPackage response = artifactRegistryClient.GetNpmPackage(request);

GetNpmPackage(NpmPackageName, CallSettings)

public virtual NpmPackage GetNpmPackage(NpmPackageName name, CallSettings callSettings = null)

Gets a npm package.

Parameters
NameDescription
nameNpmPackageName

Required. The name of the npm package.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
NpmPackage

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
NpmPackageName name = NpmPackageName.FromProjectLocationRepositoryNpmPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[NPM_PACKAGE]");
// Make the request
NpmPackage response = artifactRegistryClient.GetNpmPackage(name);

GetNpmPackage(string, CallSettings)

public virtual NpmPackage GetNpmPackage(string name, CallSettings callSettings = null)

Gets a npm package.

Parameters
NameDescription
namestring

Required. The name of the npm package.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
NpmPackage

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/npmPackages/[NPM_PACKAGE]";
// Make the request
NpmPackage response = artifactRegistryClient.GetNpmPackage(name);

GetNpmPackageAsync(GetNpmPackageRequest, CallSettings)

public virtual Task<NpmPackage> GetNpmPackageAsync(GetNpmPackageRequest request, CallSettings callSettings = null)

Gets a npm package.

Parameters
NameDescription
requestGetNpmPackageRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskNpmPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetNpmPackageRequest request = new GetNpmPackageRequest
{
    NpmPackageName = NpmPackageName.FromProjectLocationRepositoryNpmPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[NPM_PACKAGE]"),
};
// Make the request
NpmPackage response = await artifactRegistryClient.GetNpmPackageAsync(request);

GetNpmPackageAsync(GetNpmPackageRequest, CancellationToken)

public virtual Task<NpmPackage> GetNpmPackageAsync(GetNpmPackageRequest request, CancellationToken cancellationToken)

Gets a npm package.

Parameters
NameDescription
requestGetNpmPackageRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskNpmPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetNpmPackageRequest request = new GetNpmPackageRequest
{
    NpmPackageName = NpmPackageName.FromProjectLocationRepositoryNpmPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[NPM_PACKAGE]"),
};
// Make the request
NpmPackage response = await artifactRegistryClient.GetNpmPackageAsync(request);

GetNpmPackageAsync(NpmPackageName, CallSettings)

public virtual Task<NpmPackage> GetNpmPackageAsync(NpmPackageName name, CallSettings callSettings = null)

Gets a npm package.

Parameters
NameDescription
nameNpmPackageName

Required. The name of the npm package.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskNpmPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
NpmPackageName name = NpmPackageName.FromProjectLocationRepositoryNpmPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[NPM_PACKAGE]");
// Make the request
NpmPackage response = await artifactRegistryClient.GetNpmPackageAsync(name);

GetNpmPackageAsync(NpmPackageName, CancellationToken)

public virtual Task<NpmPackage> GetNpmPackageAsync(NpmPackageName name, CancellationToken cancellationToken)

Gets a npm package.

Parameters
NameDescription
nameNpmPackageName

Required. The name of the npm package.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskNpmPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
NpmPackageName name = NpmPackageName.FromProjectLocationRepositoryNpmPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[NPM_PACKAGE]");
// Make the request
NpmPackage response = await artifactRegistryClient.GetNpmPackageAsync(name);

GetNpmPackageAsync(string, CallSettings)

public virtual Task<NpmPackage> GetNpmPackageAsync(string name, CallSettings callSettings = null)

Gets a npm package.

Parameters
NameDescription
namestring

Required. The name of the npm package.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskNpmPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/npmPackages/[NPM_PACKAGE]";
// Make the request
NpmPackage response = await artifactRegistryClient.GetNpmPackageAsync(name);

GetNpmPackageAsync(string, CancellationToken)

public virtual Task<NpmPackage> GetNpmPackageAsync(string name, CancellationToken cancellationToken)

Gets a npm package.

Parameters
NameDescription
namestring

Required. The name of the npm package.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskNpmPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/npmPackages/[NPM_PACKAGE]";
// Make the request
NpmPackage response = await artifactRegistryClient.GetNpmPackageAsync(name);

GetPackage(GetPackageRequest, CallSettings)

public virtual Package GetPackage(GetPackageRequest request, CallSettings callSettings = null)

Gets a package.

Parameters
NameDescription
requestGetPackageRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Package

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
GetPackageRequest request = new GetPackageRequest
{
    PackageName = PackageName.FromProjectLocationRepositoryPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PACKAGE]"),
};
// Make the request
Package response = artifactRegistryClient.GetPackage(request);

GetPackage(PackageName, CallSettings)

public virtual Package GetPackage(PackageName name, CallSettings callSettings = null)

Gets a package.

Parameters
NameDescription
namePackageName

Required. The name of the package to retrieve.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Package

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
PackageName name = PackageName.FromProjectLocationRepositoryPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PACKAGE]");
// Make the request
Package response = artifactRegistryClient.GetPackage(name);

GetPackage(string, CallSettings)

public virtual Package GetPackage(string name, CallSettings callSettings = null)

Gets a package.

Parameters
NameDescription
namestring

Required. The name of the package to retrieve.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Package

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/packages/[PACKAGE]";
// Make the request
Package response = artifactRegistryClient.GetPackage(name);

GetPackageAsync(GetPackageRequest, CallSettings)

public virtual Task<Package> GetPackageAsync(GetPackageRequest request, CallSettings callSettings = null)

Gets a package.

Parameters
NameDescription
requestGetPackageRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetPackageRequest request = new GetPackageRequest
{
    PackageName = PackageName.FromProjectLocationRepositoryPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PACKAGE]"),
};
// Make the request
Package response = await artifactRegistryClient.GetPackageAsync(request);

GetPackageAsync(GetPackageRequest, CancellationToken)

public virtual Task<Package> GetPackageAsync(GetPackageRequest request, CancellationToken cancellationToken)

Gets a package.

Parameters
NameDescription
requestGetPackageRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetPackageRequest request = new GetPackageRequest
{
    PackageName = PackageName.FromProjectLocationRepositoryPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PACKAGE]"),
};
// Make the request
Package response = await artifactRegistryClient.GetPackageAsync(request);

GetPackageAsync(PackageName, CallSettings)

public virtual Task<Package> GetPackageAsync(PackageName name, CallSettings callSettings = null)

Gets a package.

Parameters
NameDescription
namePackageName

Required. The name of the package to retrieve.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
PackageName name = PackageName.FromProjectLocationRepositoryPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PACKAGE]");
// Make the request
Package response = await artifactRegistryClient.GetPackageAsync(name);

GetPackageAsync(PackageName, CancellationToken)

public virtual Task<Package> GetPackageAsync(PackageName name, CancellationToken cancellationToken)

Gets a package.

Parameters
NameDescription
namePackageName

Required. The name of the package to retrieve.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
PackageName name = PackageName.FromProjectLocationRepositoryPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PACKAGE]");
// Make the request
Package response = await artifactRegistryClient.GetPackageAsync(name);

GetPackageAsync(string, CallSettings)

public virtual Task<Package> GetPackageAsync(string name, CallSettings callSettings = null)

Gets a package.

Parameters
NameDescription
namestring

Required. The name of the package to retrieve.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/packages/[PACKAGE]";
// Make the request
Package response = await artifactRegistryClient.GetPackageAsync(name);

GetPackageAsync(string, CancellationToken)

public virtual Task<Package> GetPackageAsync(string name, CancellationToken cancellationToken)

Gets a package.

Parameters
NameDescription
namestring

Required. The name of the package to retrieve.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/packages/[PACKAGE]";
// Make the request
Package response = await artifactRegistryClient.GetPackageAsync(name);

GetProjectSettings(GetProjectSettingsRequest, CallSettings)

public virtual ProjectSettings GetProjectSettings(GetProjectSettingsRequest request, CallSettings callSettings = null)

Retrieves the Settings for the Project.

Parameters
NameDescription
requestGetProjectSettingsRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
ProjectSettings

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
GetProjectSettingsRequest request = new GetProjectSettingsRequest
{
    ProjectSettingsName = ProjectSettingsName.FromProject("[PROJECT]"),
};
// Make the request
ProjectSettings response = artifactRegistryClient.GetProjectSettings(request);

GetProjectSettings(ProjectSettingsName, CallSettings)

public virtual ProjectSettings GetProjectSettings(ProjectSettingsName name, CallSettings callSettings = null)

Retrieves the Settings for the Project.

Parameters
NameDescription
nameProjectSettingsName

Required. The name of the projectSettings resource.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
ProjectSettings

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
ProjectSettingsName name = ProjectSettingsName.FromProject("[PROJECT]");
// Make the request
ProjectSettings response = artifactRegistryClient.GetProjectSettings(name);

GetProjectSettings(string, CallSettings)

public virtual ProjectSettings GetProjectSettings(string name, CallSettings callSettings = null)

Retrieves the Settings for the Project.

Parameters
NameDescription
namestring

Required. The name of the projectSettings resource.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
ProjectSettings

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/projectSettings";
// Make the request
ProjectSettings response = artifactRegistryClient.GetProjectSettings(name);

GetProjectSettingsAsync(GetProjectSettingsRequest, CallSettings)

public virtual Task<ProjectSettings> GetProjectSettingsAsync(GetProjectSettingsRequest request, CallSettings callSettings = null)

Retrieves the Settings for the Project.

Parameters
NameDescription
requestGetProjectSettingsRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskProjectSettings

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetProjectSettingsRequest request = new GetProjectSettingsRequest
{
    ProjectSettingsName = ProjectSettingsName.FromProject("[PROJECT]"),
};
// Make the request
ProjectSettings response = await artifactRegistryClient.GetProjectSettingsAsync(request);

GetProjectSettingsAsync(GetProjectSettingsRequest, CancellationToken)

public virtual Task<ProjectSettings> GetProjectSettingsAsync(GetProjectSettingsRequest request, CancellationToken cancellationToken)

Retrieves the Settings for the Project.

Parameters
NameDescription
requestGetProjectSettingsRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskProjectSettings

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetProjectSettingsRequest request = new GetProjectSettingsRequest
{
    ProjectSettingsName = ProjectSettingsName.FromProject("[PROJECT]"),
};
// Make the request
ProjectSettings response = await artifactRegistryClient.GetProjectSettingsAsync(request);

GetProjectSettingsAsync(ProjectSettingsName, CallSettings)

public virtual Task<ProjectSettings> GetProjectSettingsAsync(ProjectSettingsName name, CallSettings callSettings = null)

Retrieves the Settings for the Project.

Parameters
NameDescription
nameProjectSettingsName

Required. The name of the projectSettings resource.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskProjectSettings

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
ProjectSettingsName name = ProjectSettingsName.FromProject("[PROJECT]");
// Make the request
ProjectSettings response = await artifactRegistryClient.GetProjectSettingsAsync(name);

GetProjectSettingsAsync(ProjectSettingsName, CancellationToken)

public virtual Task<ProjectSettings> GetProjectSettingsAsync(ProjectSettingsName name, CancellationToken cancellationToken)

Retrieves the Settings for the Project.

Parameters
NameDescription
nameProjectSettingsName

Required. The name of the projectSettings resource.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskProjectSettings

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
ProjectSettingsName name = ProjectSettingsName.FromProject("[PROJECT]");
// Make the request
ProjectSettings response = await artifactRegistryClient.GetProjectSettingsAsync(name);

GetProjectSettingsAsync(string, CallSettings)

public virtual Task<ProjectSettings> GetProjectSettingsAsync(string name, CallSettings callSettings = null)

Retrieves the Settings for the Project.

Parameters
NameDescription
namestring

Required. The name of the projectSettings resource.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskProjectSettings

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/projectSettings";
// Make the request
ProjectSettings response = await artifactRegistryClient.GetProjectSettingsAsync(name);

GetProjectSettingsAsync(string, CancellationToken)

public virtual Task<ProjectSettings> GetProjectSettingsAsync(string name, CancellationToken cancellationToken)

Retrieves the Settings for the Project.

Parameters
NameDescription
namestring

Required. The name of the projectSettings resource.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskProjectSettings

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/projectSettings";
// Make the request
ProjectSettings response = await artifactRegistryClient.GetProjectSettingsAsync(name);

GetPythonPackage(GetPythonPackageRequest, CallSettings)

public virtual PythonPackage GetPythonPackage(GetPythonPackageRequest request, CallSettings callSettings = null)

Gets a python package.

Parameters
NameDescription
requestGetPythonPackageRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PythonPackage

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
GetPythonPackageRequest request = new GetPythonPackageRequest
{
    PythonPackageName = PythonPackageName.FromProjectLocationRepositoryPythonPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PYTHON_PACKAGE]"),
};
// Make the request
PythonPackage response = artifactRegistryClient.GetPythonPackage(request);

GetPythonPackage(PythonPackageName, CallSettings)

public virtual PythonPackage GetPythonPackage(PythonPackageName name, CallSettings callSettings = null)

Gets a python package.

Parameters
NameDescription
namePythonPackageName

Required. The name of the python package.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PythonPackage

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
PythonPackageName name = PythonPackageName.FromProjectLocationRepositoryPythonPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PYTHON_PACKAGE]");
// Make the request
PythonPackage response = artifactRegistryClient.GetPythonPackage(name);

GetPythonPackage(string, CallSettings)

public virtual PythonPackage GetPythonPackage(string name, CallSettings callSettings = null)

Gets a python package.

Parameters
NameDescription
namestring

Required. The name of the python package.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PythonPackage

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/pythonPackages/[PYTHON_PACKAGE]";
// Make the request
PythonPackage response = artifactRegistryClient.GetPythonPackage(name);

GetPythonPackageAsync(GetPythonPackageRequest, CallSettings)

public virtual Task<PythonPackage> GetPythonPackageAsync(GetPythonPackageRequest request, CallSettings callSettings = null)

Gets a python package.

Parameters
NameDescription
requestGetPythonPackageRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskPythonPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetPythonPackageRequest request = new GetPythonPackageRequest
{
    PythonPackageName = PythonPackageName.FromProjectLocationRepositoryPythonPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PYTHON_PACKAGE]"),
};
// Make the request
PythonPackage response = await artifactRegistryClient.GetPythonPackageAsync(request);

GetPythonPackageAsync(GetPythonPackageRequest, CancellationToken)

public virtual Task<PythonPackage> GetPythonPackageAsync(GetPythonPackageRequest request, CancellationToken cancellationToken)

Gets a python package.

Parameters
NameDescription
requestGetPythonPackageRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskPythonPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetPythonPackageRequest request = new GetPythonPackageRequest
{
    PythonPackageName = PythonPackageName.FromProjectLocationRepositoryPythonPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PYTHON_PACKAGE]"),
};
// Make the request
PythonPackage response = await artifactRegistryClient.GetPythonPackageAsync(request);

GetPythonPackageAsync(PythonPackageName, CallSettings)

public virtual Task<PythonPackage> GetPythonPackageAsync(PythonPackageName name, CallSettings callSettings = null)

Gets a python package.

Parameters
NameDescription
namePythonPackageName

Required. The name of the python package.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskPythonPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
PythonPackageName name = PythonPackageName.FromProjectLocationRepositoryPythonPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PYTHON_PACKAGE]");
// Make the request
PythonPackage response = await artifactRegistryClient.GetPythonPackageAsync(name);

GetPythonPackageAsync(PythonPackageName, CancellationToken)

public virtual Task<PythonPackage> GetPythonPackageAsync(PythonPackageName name, CancellationToken cancellationToken)

Gets a python package.

Parameters
NameDescription
namePythonPackageName

Required. The name of the python package.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskPythonPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
PythonPackageName name = PythonPackageName.FromProjectLocationRepositoryPythonPackage("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[PYTHON_PACKAGE]");
// Make the request
PythonPackage response = await artifactRegistryClient.GetPythonPackageAsync(name);

GetPythonPackageAsync(string, CallSettings)

public virtual Task<PythonPackage> GetPythonPackageAsync(string name, CallSettings callSettings = null)

Gets a python package.

Parameters
NameDescription
namestring

Required. The name of the python package.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskPythonPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/pythonPackages/[PYTHON_PACKAGE]";
// Make the request
PythonPackage response = await artifactRegistryClient.GetPythonPackageAsync(name);

GetPythonPackageAsync(string, CancellationToken)

public virtual Task<PythonPackage> GetPythonPackageAsync(string name, CancellationToken cancellationToken)

Gets a python package.

Parameters
NameDescription
namestring

Required. The name of the python package.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskPythonPackage

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]/pythonPackages/[PYTHON_PACKAGE]";
// Make the request
PythonPackage response = await artifactRegistryClient.GetPythonPackageAsync(name);

GetRepository(GetRepositoryRequest, CallSettings)

public virtual Repository GetRepository(GetRepositoryRequest request, CallSettings callSettings = null)

Gets a repository.

Parameters
NameDescription
requestGetRepositoryRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Repository

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
GetRepositoryRequest request = new GetRepositoryRequest
{
    RepositoryName = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]"),
};
// Make the request
Repository response = artifactRegistryClient.GetRepository(request);

GetRepository(RepositoryName, CallSettings)

public virtual Repository GetRepository(RepositoryName name, CallSettings callSettings = null)

Gets a repository.

Parameters
NameDescription
nameRepositoryName

Required. The name of the repository to retrieve.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Repository

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
RepositoryName name = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
// Make the request
Repository response = artifactRegistryClient.GetRepository(name);

GetRepository(string, CallSettings)

public virtual Repository GetRepository(string name, CallSettings callSettings = null)

Gets a repository.

Parameters
NameDescription
namestring

Required. The name of the repository to retrieve.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Repository

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]";
// Make the request
Repository response = artifactRegistryClient.GetRepository(name);

GetRepositoryAsync(GetRepositoryRequest, CallSettings)

public virtual Task<Repository> GetRepositoryAsync(GetRepositoryRequest request, CallSettings callSettings = null)

Gets a repository.

Parameters
NameDescription
requestGetRepositoryRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskRepository

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetRepositoryRequest request = new GetRepositoryRequest
{
    RepositoryName = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]"),
};
// Make the request
Repository response = await artifactRegistryClient.GetRepositoryAsync(request);

GetRepositoryAsync(GetRepositoryRequest, CancellationToken)

public virtual Task<Repository> GetRepositoryAsync(GetRepositoryRequest request, CancellationToken cancellationToken)

Gets a repository.

Parameters
NameDescription
requestGetRepositoryRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskRepository

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetRepositoryRequest request = new GetRepositoryRequest
{
    RepositoryName = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]"),
};
// Make the request
Repository response = await artifactRegistryClient.GetRepositoryAsync(request);

GetRepositoryAsync(RepositoryName, CallSettings)

public virtual Task<Repository> GetRepositoryAsync(RepositoryName name, CallSettings callSettings = null)

Gets a repository.

Parameters
NameDescription
nameRepositoryName

Required. The name of the repository to retrieve.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskRepository

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
RepositoryName name = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
// Make the request
Repository response = await artifactRegistryClient.GetRepositoryAsync(name);

GetRepositoryAsync(RepositoryName, CancellationToken)

public virtual Task<Repository> GetRepositoryAsync(RepositoryName name, CancellationToken cancellationToken)

Gets a repository.

Parameters
NameDescription
nameRepositoryName

Required. The name of the repository to retrieve.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskRepository

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
RepositoryName name = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
// Make the request
Repository response = await artifactRegistryClient.GetRepositoryAsync(name);

GetRepositoryAsync(string, CallSettings)

public virtual Task<Repository> GetRepositoryAsync(string name, CallSettings callSettings = null)

Gets a repository.

Parameters
NameDescription
namestring

Required. The name of the repository to retrieve.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskRepository

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]";
// Make the request
Repository response = await artifactRegistryClient.GetRepositoryAsync(name);

GetRepositoryAsync(string, CancellationToken)

public virtual Task<Repository> GetRepositoryAsync(string name, CancellationToken cancellationToken)

Gets a repository.

Parameters
NameDescription
namestring

Required. The name of the repository to retrieve.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskRepository

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]";
// Make the request
Repository response = await artifactRegistryClient.GetRepositoryAsync(name);

GetTag(GetTagRequest, CallSettings)

public virtual Tag GetTag(GetTagRequest request, CallSettings callSettings = null)

Gets a tag.

Parameters
NameDescription
requestGetTagRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Tag

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
GetTagRequest request = new GetTagRequest { Name = "", };
// Make the request
Tag response = artifactRegistryClient.GetTag(request);

GetTag(string, CallSettings)

public virtual Tag GetTag(string name, CallSettings callSettings = null)

Gets a tag.

Parameters
NameDescription
namestring

The name of the tag to retrieve.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Tag

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string name = "";
// Make the request
Tag response = artifactRegistryClient.GetTag(name);

GetTagAsync(GetTagRequest, CallSettings)

public virtual Task<Tag> GetTagAsync(GetTagRequest request, CallSettings callSettings = null)

Gets a tag.

Parameters
NameDescription
requestGetTagRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskTag

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetTagRequest request = new GetTagRequest { Name = "", };
// Make the request
Tag response = await artifactRegistryClient.GetTagAsync(request);

GetTagAsync(GetTagRequest, CancellationToken)

public virtual Task<Tag> GetTagAsync(GetTagRequest request, CancellationToken cancellationToken)

Gets a tag.

Parameters
NameDescription
requestGetTagRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskTag

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetTagRequest request = new GetTagRequest { Name = "", };
// Make the request
Tag response = await artifactRegistryClient.GetTagAsync(request);

GetTagAsync(string, CallSettings)

public virtual Task<Tag> GetTagAsync(string name, CallSettings callSettings = null)

Gets a tag.

Parameters
NameDescription
namestring

The name of the tag to retrieve.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskTag

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
Tag response = await artifactRegistryClient.GetTagAsync(name);

GetTagAsync(string, CancellationToken)

public virtual Task<Tag> GetTagAsync(string name, CancellationToken cancellationToken)

Gets a tag.

Parameters
NameDescription
namestring

The name of the tag to retrieve.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskTag

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
Tag response = await artifactRegistryClient.GetTagAsync(name);

GetVersion(GetVersionRequest, CallSettings)

public virtual Version GetVersion(GetVersionRequest request, CallSettings callSettings = null)

Gets a version

Parameters
NameDescription
requestGetVersionRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Version

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
GetVersionRequest request = new GetVersionRequest
{
    Name = "",
    View = VersionView.Unspecified,
};
// Make the request
gcav::Version response = artifactRegistryClient.GetVersion(request);

GetVersion(string, CallSettings)

public virtual Version GetVersion(string name, CallSettings callSettings = null)

Gets a version

Parameters
NameDescription
namestring

The name of the version to retrieve.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Version

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string name = "";
// Make the request
gcav::Version response = artifactRegistryClient.GetVersion(name);

GetVersionAsync(GetVersionRequest, CallSettings)

public virtual Task<Version> GetVersionAsync(GetVersionRequest request, CallSettings callSettings = null)

Gets a version

Parameters
NameDescription
requestGetVersionRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskVersion

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetVersionRequest request = new GetVersionRequest
{
    Name = "",
    View = VersionView.Unspecified,
};
// Make the request
gcav::Version response = await artifactRegistryClient.GetVersionAsync(request);

GetVersionAsync(GetVersionRequest, CancellationToken)

public virtual Task<Version> GetVersionAsync(GetVersionRequest request, CancellationToken cancellationToken)

Gets a version

Parameters
NameDescription
requestGetVersionRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskVersion

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetVersionRequest request = new GetVersionRequest
{
    Name = "",
    View = VersionView.Unspecified,
};
// Make the request
gcav::Version response = await artifactRegistryClient.GetVersionAsync(request);

GetVersionAsync(string, CallSettings)

public virtual Task<Version> GetVersionAsync(string name, CallSettings callSettings = null)

Gets a version

Parameters
NameDescription
namestring

The name of the version to retrieve.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskVersion

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
gcav::Version response = await artifactRegistryClient.GetVersionAsync(name);

GetVersionAsync(string, CancellationToken)

public virtual Task<Version> GetVersionAsync(string name, CancellationToken cancellationToken)

Gets a version

Parameters
NameDescription
namestring

The name of the version to retrieve.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskVersion

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
gcav::Version response = await artifactRegistryClient.GetVersionAsync(name);

GetVPCSCConfig(GetVPCSCConfigRequest, CallSettings)

public virtual VPCSCConfig GetVPCSCConfig(GetVPCSCConfigRequest request, CallSettings callSettings = null)

Retrieves the VPCSC Config for the Project.

Parameters
NameDescription
requestGetVPCSCConfigRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
VPCSCConfig

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
GetVPCSCConfigRequest request = new GetVPCSCConfigRequest
{
    VpcscConfigName = VpcscConfigName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
};
// Make the request
VPCSCConfig response = artifactRegistryClient.GetVPCSCConfig(request);

GetVPCSCConfig(VpcscConfigName, CallSettings)

public virtual VPCSCConfig GetVPCSCConfig(VpcscConfigName name, CallSettings callSettings = null)

Retrieves the VPCSC Config for the Project.

Parameters
NameDescription
nameVpcscConfigName

Required. The name of the VPCSCConfig resource.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
VPCSCConfig

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
VpcscConfigName name = VpcscConfigName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
VPCSCConfig response = artifactRegistryClient.GetVPCSCConfig(name);

GetVPCSCConfig(string, CallSettings)

public virtual VPCSCConfig GetVPCSCConfig(string name, CallSettings callSettings = null)

Retrieves the VPCSC Config for the Project.

Parameters
NameDescription
namestring

Required. The name of the VPCSCConfig resource.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
VPCSCConfig

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/vpcscConfig";
// Make the request
VPCSCConfig response = artifactRegistryClient.GetVPCSCConfig(name);

GetVPCSCConfigAsync(GetVPCSCConfigRequest, CallSettings)

public virtual Task<VPCSCConfig> GetVPCSCConfigAsync(GetVPCSCConfigRequest request, CallSettings callSettings = null)

Retrieves the VPCSC Config for the Project.

Parameters
NameDescription
requestGetVPCSCConfigRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskVPCSCConfig

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetVPCSCConfigRequest request = new GetVPCSCConfigRequest
{
    VpcscConfigName = VpcscConfigName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
};
// Make the request
VPCSCConfig response = await artifactRegistryClient.GetVPCSCConfigAsync(request);

GetVPCSCConfigAsync(GetVPCSCConfigRequest, CancellationToken)

public virtual Task<VPCSCConfig> GetVPCSCConfigAsync(GetVPCSCConfigRequest request, CancellationToken cancellationToken)

Retrieves the VPCSC Config for the Project.

Parameters
NameDescription
requestGetVPCSCConfigRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskVPCSCConfig

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
GetVPCSCConfigRequest request = new GetVPCSCConfigRequest
{
    VpcscConfigName = VpcscConfigName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
};
// Make the request
VPCSCConfig response = await artifactRegistryClient.GetVPCSCConfigAsync(request);

GetVPCSCConfigAsync(VpcscConfigName, CallSettings)

public virtual Task<VPCSCConfig> GetVPCSCConfigAsync(VpcscConfigName name, CallSettings callSettings = null)

Retrieves the VPCSC Config for the Project.

Parameters
NameDescription
nameVpcscConfigName

Required. The name of the VPCSCConfig resource.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskVPCSCConfig

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
VpcscConfigName name = VpcscConfigName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
VPCSCConfig response = await artifactRegistryClient.GetVPCSCConfigAsync(name);

GetVPCSCConfigAsync(VpcscConfigName, CancellationToken)

public virtual Task<VPCSCConfig> GetVPCSCConfigAsync(VpcscConfigName name, CancellationToken cancellationToken)

Retrieves the VPCSC Config for the Project.

Parameters
NameDescription
nameVpcscConfigName

Required. The name of the VPCSCConfig resource.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskVPCSCConfig

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
VpcscConfigName name = VpcscConfigName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
VPCSCConfig response = await artifactRegistryClient.GetVPCSCConfigAsync(name);

GetVPCSCConfigAsync(string, CallSettings)

public virtual Task<VPCSCConfig> GetVPCSCConfigAsync(string name, CallSettings callSettings = null)

Retrieves the VPCSC Config for the Project.

Parameters
NameDescription
namestring

Required. The name of the VPCSCConfig resource.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskVPCSCConfig

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/vpcscConfig";
// Make the request
VPCSCConfig response = await artifactRegistryClient.GetVPCSCConfigAsync(name);

GetVPCSCConfigAsync(string, CancellationToken)

public virtual Task<VPCSCConfig> GetVPCSCConfigAsync(string name, CancellationToken cancellationToken)

Retrieves the VPCSC Config for the Project.

Parameters
NameDescription
namestring

Required. The name of the VPCSCConfig resource.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskVPCSCConfig

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/vpcscConfig";
// Make the request
VPCSCConfig response = await artifactRegistryClient.GetVPCSCConfigAsync(name);

ImportAptArtifacts(ImportAptArtifactsRequest, CallSettings)

public virtual Operation<ImportAptArtifactsResponse, ImportAptArtifactsMetadata> ImportAptArtifacts(ImportAptArtifactsRequest request, CallSettings callSettings = null)

Imports Apt artifacts. The returned Operation will complete once the resources are imported. Package, Version, and File resources are created based on the imported artifacts. Imported artifacts that conflict with existing resources are ignored.

Parameters
NameDescription
requestImportAptArtifactsRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
OperationImportAptArtifactsResponseImportAptArtifactsMetadata

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
ImportAptArtifactsRequest request = new ImportAptArtifactsRequest
{
    Parent = "",
    GcsSource = new ImportAptArtifactsGcsSource(),
};
// Make the request
Operation<ImportAptArtifactsResponse, ImportAptArtifactsMetadata> response = artifactRegistryClient.ImportAptArtifacts(request);

// Poll until the returned long-running operation is complete
Operation<ImportAptArtifactsResponse, ImportAptArtifactsMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
ImportAptArtifactsResponse 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<ImportAptArtifactsResponse, ImportAptArtifactsMetadata> retrievedResponse = artifactRegistryClient.PollOnceImportAptArtifacts(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    ImportAptArtifactsResponse retrievedResult = retrievedResponse.Result;
}

ImportAptArtifactsAsync(ImportAptArtifactsRequest, CallSettings)

public virtual Task<Operation<ImportAptArtifactsResponse, ImportAptArtifactsMetadata>> ImportAptArtifactsAsync(ImportAptArtifactsRequest request, CallSettings callSettings = null)

Imports Apt artifacts. The returned Operation will complete once the resources are imported. Package, Version, and File resources are created based on the imported artifacts. Imported artifacts that conflict with existing resources are ignored.

Parameters
NameDescription
requestImportAptArtifactsRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskOperationImportAptArtifactsResponseImportAptArtifactsMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
ImportAptArtifactsRequest request = new ImportAptArtifactsRequest
{
    Parent = "",
    GcsSource = new ImportAptArtifactsGcsSource(),
};
// Make the request
Operation<ImportAptArtifactsResponse, ImportAptArtifactsMetadata> response = await artifactRegistryClient.ImportAptArtifactsAsync(request);

// Poll until the returned long-running operation is complete
Operation<ImportAptArtifactsResponse, ImportAptArtifactsMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
ImportAptArtifactsResponse 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<ImportAptArtifactsResponse, ImportAptArtifactsMetadata> retrievedResponse = await artifactRegistryClient.PollOnceImportAptArtifactsAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    ImportAptArtifactsResponse retrievedResult = retrievedResponse.Result;
}

ImportAptArtifactsAsync(ImportAptArtifactsRequest, CancellationToken)

public virtual Task<Operation<ImportAptArtifactsResponse, ImportAptArtifactsMetadata>> ImportAptArtifactsAsync(ImportAptArtifactsRequest request, CancellationToken cancellationToken)

Imports Apt artifacts. The returned Operation will complete once the resources are imported. Package, Version, and File resources are created based on the imported artifacts. Imported artifacts that conflict with existing resources are ignored.

Parameters
NameDescription
requestImportAptArtifactsRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskOperationImportAptArtifactsResponseImportAptArtifactsMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
ImportAptArtifactsRequest request = new ImportAptArtifactsRequest
{
    Parent = "",
    GcsSource = new ImportAptArtifactsGcsSource(),
};
// Make the request
Operation<ImportAptArtifactsResponse, ImportAptArtifactsMetadata> response = await artifactRegistryClient.ImportAptArtifactsAsync(request);

// Poll until the returned long-running operation is complete
Operation<ImportAptArtifactsResponse, ImportAptArtifactsMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
ImportAptArtifactsResponse 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<ImportAptArtifactsResponse, ImportAptArtifactsMetadata> retrievedResponse = await artifactRegistryClient.PollOnceImportAptArtifactsAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    ImportAptArtifactsResponse retrievedResult = retrievedResponse.Result;
}

ImportYumArtifacts(ImportYumArtifactsRequest, CallSettings)

public virtual Operation<ImportYumArtifactsResponse, ImportYumArtifactsMetadata> ImportYumArtifacts(ImportYumArtifactsRequest request, CallSettings callSettings = null)

Imports Yum (RPM) artifacts. The returned Operation will complete once the resources are imported. Package, Version, and File resources are created based on the imported artifacts. Imported artifacts that conflict with existing resources are ignored.

Parameters
NameDescription
requestImportYumArtifactsRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
OperationImportYumArtifactsResponseImportYumArtifactsMetadata

The RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
ImportYumArtifactsRequest request = new ImportYumArtifactsRequest
{
    Parent = "",
    GcsSource = new ImportYumArtifactsGcsSource(),
};
// Make the request
Operation<ImportYumArtifactsResponse, ImportYumArtifactsMetadata> response = artifactRegistryClient.ImportYumArtifacts(request);

// Poll until the returned long-running operation is complete
Operation<ImportYumArtifactsResponse, ImportYumArtifactsMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
ImportYumArtifactsResponse 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<ImportYumArtifactsResponse, ImportYumArtifactsMetadata> retrievedResponse = artifactRegistryClient.PollOnceImportYumArtifacts(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    ImportYumArtifactsResponse retrievedResult = retrievedResponse.Result;
}

ImportYumArtifactsAsync(ImportYumArtifactsRequest, CallSettings)

public virtual Task<Operation<ImportYumArtifactsResponse, ImportYumArtifactsMetadata>> ImportYumArtifactsAsync(ImportYumArtifactsRequest request, CallSettings callSettings = null)

Imports Yum (RPM) artifacts. The returned Operation will complete once the resources are imported. Package, Version, and File resources are created based on the imported artifacts. Imported artifacts that conflict with existing resources are ignored.

Parameters
NameDescription
requestImportYumArtifactsRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskOperationImportYumArtifactsResponseImportYumArtifactsMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
ImportYumArtifactsRequest request = new ImportYumArtifactsRequest
{
    Parent = "",
    GcsSource = new ImportYumArtifactsGcsSource(),
};
// Make the request
Operation<ImportYumArtifactsResponse, ImportYumArtifactsMetadata> response = await artifactRegistryClient.ImportYumArtifactsAsync(request);

// Poll until the returned long-running operation is complete
Operation<ImportYumArtifactsResponse, ImportYumArtifactsMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
ImportYumArtifactsResponse 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<ImportYumArtifactsResponse, ImportYumArtifactsMetadata> retrievedResponse = await artifactRegistryClient.PollOnceImportYumArtifactsAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    ImportYumArtifactsResponse retrievedResult = retrievedResponse.Result;
}

ImportYumArtifactsAsync(ImportYumArtifactsRequest, CancellationToken)

public virtual Task<Operation<ImportYumArtifactsResponse, ImportYumArtifactsMetadata>> ImportYumArtifactsAsync(ImportYumArtifactsRequest request, CancellationToken cancellationToken)

Imports Yum (RPM) artifacts. The returned Operation will complete once the resources are imported. Package, Version, and File resources are created based on the imported artifacts. Imported artifacts that conflict with existing resources are ignored.

Parameters
NameDescription
requestImportYumArtifactsRequest

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

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskOperationImportYumArtifactsResponseImportYumArtifactsMetadata

A Task containing the RPC response.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
ImportYumArtifactsRequest request = new ImportYumArtifactsRequest
{
    Parent = "",
    GcsSource = new ImportYumArtifactsGcsSource(),
};
// Make the request
Operation<ImportYumArtifactsResponse, ImportYumArtifactsMetadata> response = await artifactRegistryClient.ImportYumArtifactsAsync(request);

// Poll until the returned long-running operation is complete
Operation<ImportYumArtifactsResponse, ImportYumArtifactsMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
ImportYumArtifactsResponse 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<ImportYumArtifactsResponse, ImportYumArtifactsMetadata> retrievedResponse = await artifactRegistryClient.PollOnceImportYumArtifactsAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    ImportYumArtifactsResponse retrievedResult = retrievedResponse.Result;
}

ListDockerImages(ListDockerImagesRequest, CallSettings)

public virtual PagedEnumerable<ListDockerImagesResponse, DockerImage> ListDockerImages(ListDockerImagesRequest request, CallSettings callSettings = null)

Lists docker images.

Parameters
NameDescription
requestListDockerImagesRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListDockerImagesResponseDockerImage

A pageable sequence of DockerImage resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
ListDockerImagesRequest request = new ListDockerImagesRequest
{
    Parent = "",
    OrderBy = "",
};
// Make the request
PagedEnumerable<ListDockerImagesResponse, DockerImage> response = artifactRegistryClient.ListDockerImages(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (DockerImage 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 (ListDockerImagesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DockerImage 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<DockerImage> 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 (DockerImage 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;

ListDockerImages(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListDockerImagesResponse, DockerImage> ListDockerImages(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists docker images.

Parameters
NameDescription
parentstring

Required. The name of the parent resource whose docker images will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListDockerImagesResponseDockerImage

A pageable sequence of DockerImage resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string parent = "";
// Make the request
PagedEnumerable<ListDockerImagesResponse, DockerImage> response = artifactRegistryClient.ListDockerImages(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (DockerImage 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 (ListDockerImagesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DockerImage 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<DockerImage> 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 (DockerImage 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;

ListDockerImagesAsync(ListDockerImagesRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListDockerImagesResponse, DockerImage> ListDockerImagesAsync(ListDockerImagesRequest request, CallSettings callSettings = null)

Lists docker images.

Parameters
NameDescription
requestListDockerImagesRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListDockerImagesResponseDockerImage

A pageable asynchronous sequence of DockerImage resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
ListDockerImagesRequest request = new ListDockerImagesRequest
{
    Parent = "",
    OrderBy = "",
};
// Make the request
PagedAsyncEnumerable<ListDockerImagesResponse, DockerImage> response = artifactRegistryClient.ListDockerImagesAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((DockerImage item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListDockerImagesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DockerImage 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<DockerImage> 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 (DockerImage 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;

ListDockerImagesAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListDockerImagesResponse, DockerImage> ListDockerImagesAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists docker images.

Parameters
NameDescription
parentstring

Required. The name of the parent resource whose docker images will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListDockerImagesResponseDockerImage

A pageable asynchronous sequence of DockerImage resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string parent = "";
// Make the request
PagedAsyncEnumerable<ListDockerImagesResponse, DockerImage> response = artifactRegistryClient.ListDockerImagesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((DockerImage item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListDockerImagesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (DockerImage 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<DockerImage> 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 (DockerImage 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;

ListFiles(ListFilesRequest, CallSettings)

public virtual PagedEnumerable<ListFilesResponse, File> ListFiles(ListFilesRequest request, CallSettings callSettings = null)

Lists files.

Parameters
NameDescription
requestListFilesRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListFilesResponseFile

A pageable sequence of File resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
ListFilesRequest request = new ListFilesRequest
{
    ParentAsRepositoryName = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedEnumerable<ListFilesResponse, File> response = artifactRegistryClient.ListFiles(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (File 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 (ListFilesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (File 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<File> 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 (File 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;

ListFiles(RepositoryName, string, int?, CallSettings)

public virtual PagedEnumerable<ListFilesResponse, File> ListFiles(RepositoryName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists files.

Parameters
NameDescription
parentRepositoryName

Required. The name of the repository whose files will be listed. For example: "projects/p1/locations/us-central1/repositories/repo1

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListFilesResponseFile

A pageable sequence of File resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
RepositoryName parent = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
// Make the request
PagedEnumerable<ListFilesResponse, File> response = artifactRegistryClient.ListFiles(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (File 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 (ListFilesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (File 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<File> 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 (File 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;

ListFiles(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListFilesResponse, File> ListFiles(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists files.

Parameters
NameDescription
parentstring

Required. The name of the repository whose files will be listed. For example: "projects/p1/locations/us-central1/repositories/repo1

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListFilesResponseFile

A pageable sequence of File resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]";
// Make the request
PagedEnumerable<ListFilesResponse, File> response = artifactRegistryClient.ListFiles(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (File 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 (ListFilesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (File 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<File> 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 (File 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;

ListFilesAsync(ListFilesRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListFilesResponse, File> ListFilesAsync(ListFilesRequest request, CallSettings callSettings = null)

Lists files.

Parameters
NameDescription
requestListFilesRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListFilesResponseFile

A pageable asynchronous sequence of File resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
ListFilesRequest request = new ListFilesRequest
{
    ParentAsRepositoryName = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]"),
    Filter = "",
    OrderBy = "",
};
// Make the request
PagedAsyncEnumerable<ListFilesResponse, File> response = artifactRegistryClient.ListFilesAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((File item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListFilesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (File 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<File> 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 (File 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;

ListFilesAsync(RepositoryName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListFilesResponse, File> ListFilesAsync(RepositoryName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists files.

Parameters
NameDescription
parentRepositoryName

Required. The name of the repository whose files will be listed. For example: "projects/p1/locations/us-central1/repositories/repo1

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListFilesResponseFile

A pageable asynchronous sequence of File resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
RepositoryName parent = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
// Make the request
PagedAsyncEnumerable<ListFilesResponse, File> response = artifactRegistryClient.ListFilesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((File item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListFilesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (File 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<File> 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 (File 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;

ListFilesAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListFilesResponse, File> ListFilesAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists files.

Parameters
NameDescription
parentstring

Required. The name of the repository whose files will be listed. For example: "projects/p1/locations/us-central1/repositories/repo1

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListFilesResponseFile

A pageable asynchronous sequence of File resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]";
// Make the request
PagedAsyncEnumerable<ListFilesResponse, File> response = artifactRegistryClient.ListFilesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((File item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListFilesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (File 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<File> 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 (File 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;

ListMavenArtifacts(ListMavenArtifactsRequest, CallSettings)

public virtual PagedEnumerable<ListMavenArtifactsResponse, MavenArtifact> ListMavenArtifacts(ListMavenArtifactsRequest request, CallSettings callSettings = null)

Lists maven artifacts.

Parameters
NameDescription
requestListMavenArtifactsRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListMavenArtifactsResponseMavenArtifact

A pageable sequence of MavenArtifact resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
ListMavenArtifactsRequest request = new ListMavenArtifactsRequest
{
    ParentAsRepositoryName = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]"),
};
// Make the request
PagedEnumerable<ListMavenArtifactsResponse, MavenArtifact> response = artifactRegistryClient.ListMavenArtifacts(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (MavenArtifact 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 (ListMavenArtifactsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (MavenArtifact 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<MavenArtifact> 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 (MavenArtifact 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;

ListMavenArtifacts(RepositoryName, string, int?, CallSettings)

public virtual PagedEnumerable<ListMavenArtifactsResponse, MavenArtifact> ListMavenArtifacts(RepositoryName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists maven artifacts.

Parameters
NameDescription
parentRepositoryName

Required. The name of the parent resource whose maven artifacts will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListMavenArtifactsResponseMavenArtifact

A pageable sequence of MavenArtifact resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
RepositoryName parent = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
// Make the request
PagedEnumerable<ListMavenArtifactsResponse, MavenArtifact> response = artifactRegistryClient.ListMavenArtifacts(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (MavenArtifact 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 (ListMavenArtifactsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (MavenArtifact 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<MavenArtifact> 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 (MavenArtifact 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;

ListMavenArtifacts(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListMavenArtifactsResponse, MavenArtifact> ListMavenArtifacts(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists maven artifacts.

Parameters
NameDescription
parentstring

Required. The name of the parent resource whose maven artifacts will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListMavenArtifactsResponseMavenArtifact

A pageable sequence of MavenArtifact resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]";
// Make the request
PagedEnumerable<ListMavenArtifactsResponse, MavenArtifact> response = artifactRegistryClient.ListMavenArtifacts(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (MavenArtifact 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 (ListMavenArtifactsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (MavenArtifact 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<MavenArtifact> 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 (MavenArtifact 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;

ListMavenArtifactsAsync(ListMavenArtifactsRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListMavenArtifactsResponse, MavenArtifact> ListMavenArtifactsAsync(ListMavenArtifactsRequest request, CallSettings callSettings = null)

Lists maven artifacts.

Parameters
NameDescription
requestListMavenArtifactsRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListMavenArtifactsResponseMavenArtifact

A pageable asynchronous sequence of MavenArtifact resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
ListMavenArtifactsRequest request = new ListMavenArtifactsRequest
{
    ParentAsRepositoryName = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]"),
};
// Make the request
PagedAsyncEnumerable<ListMavenArtifactsResponse, MavenArtifact> response = artifactRegistryClient.ListMavenArtifactsAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((MavenArtifact item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListMavenArtifactsResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (MavenArtifact 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<MavenArtifact> 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 (MavenArtifact 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;

ListMavenArtifactsAsync(RepositoryName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListMavenArtifactsResponse, MavenArtifact> ListMavenArtifactsAsync(RepositoryName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists maven artifacts.

Parameters
NameDescription
parentRepositoryName

Required. The name of the parent resource whose maven artifacts will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListMavenArtifactsResponseMavenArtifact

A pageable asynchronous sequence of MavenArtifact resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
RepositoryName parent = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
// Make the request
PagedAsyncEnumerable<ListMavenArtifactsResponse, MavenArtifact> response = artifactRegistryClient.ListMavenArtifactsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((MavenArtifact item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListMavenArtifactsResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (MavenArtifact 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<MavenArtifact> 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 (MavenArtifact 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;

ListMavenArtifactsAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListMavenArtifactsResponse, MavenArtifact> ListMavenArtifactsAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists maven artifacts.

Parameters
NameDescription
parentstring

Required. The name of the parent resource whose maven artifacts will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListMavenArtifactsResponseMavenArtifact

A pageable asynchronous sequence of MavenArtifact resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]";
// Make the request
PagedAsyncEnumerable<ListMavenArtifactsResponse, MavenArtifact> response = artifactRegistryClient.ListMavenArtifactsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((MavenArtifact item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListMavenArtifactsResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (MavenArtifact 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<MavenArtifact> 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 (MavenArtifact 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;

ListNpmPackages(ListNpmPackagesRequest, CallSettings)

public virtual PagedEnumerable<ListNpmPackagesResponse, NpmPackage> ListNpmPackages(ListNpmPackagesRequest request, CallSettings callSettings = null)

Lists npm packages.

Parameters
NameDescription
requestListNpmPackagesRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListNpmPackagesResponseNpmPackage

A pageable sequence of NpmPackage resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
ListNpmPackagesRequest request = new ListNpmPackagesRequest
{
    ParentAsRepositoryName = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]"),
};
// Make the request
PagedEnumerable<ListNpmPackagesResponse, NpmPackage> response = artifactRegistryClient.ListNpmPackages(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (NpmPackage 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 (ListNpmPackagesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (NpmPackage 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<NpmPackage> 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 (NpmPackage 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;

ListNpmPackages(RepositoryName, string, int?, CallSettings)

public virtual PagedEnumerable<ListNpmPackagesResponse, NpmPackage> ListNpmPackages(RepositoryName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists npm packages.

Parameters
NameDescription
parentRepositoryName

Required. The name of the parent resource whose npm packages will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListNpmPackagesResponseNpmPackage

A pageable sequence of NpmPackage resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
RepositoryName parent = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
// Make the request
PagedEnumerable<ListNpmPackagesResponse, NpmPackage> response = artifactRegistryClient.ListNpmPackages(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (NpmPackage 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 (ListNpmPackagesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (NpmPackage 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<NpmPackage> 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 (NpmPackage 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;

ListNpmPackages(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListNpmPackagesResponse, NpmPackage> ListNpmPackages(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists npm packages.

Parameters
NameDescription
parentstring

Required. The name of the parent resource whose npm packages will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListNpmPackagesResponseNpmPackage

A pageable sequence of NpmPackage resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]";
// Make the request
PagedEnumerable<ListNpmPackagesResponse, NpmPackage> response = artifactRegistryClient.ListNpmPackages(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (NpmPackage 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 (ListNpmPackagesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (NpmPackage 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<NpmPackage> 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 (NpmPackage 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;

ListNpmPackagesAsync(ListNpmPackagesRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListNpmPackagesResponse, NpmPackage> ListNpmPackagesAsync(ListNpmPackagesRequest request, CallSettings callSettings = null)

Lists npm packages.

Parameters
NameDescription
requestListNpmPackagesRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListNpmPackagesResponseNpmPackage

A pageable asynchronous sequence of NpmPackage resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
ListNpmPackagesRequest request = new ListNpmPackagesRequest
{
    ParentAsRepositoryName = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]"),
};
// Make the request
PagedAsyncEnumerable<ListNpmPackagesResponse, NpmPackage> response = artifactRegistryClient.ListNpmPackagesAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((NpmPackage item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListNpmPackagesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (NpmPackage 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<NpmPackage> 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 (NpmPackage 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;

ListNpmPackagesAsync(RepositoryName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListNpmPackagesResponse, NpmPackage> ListNpmPackagesAsync(RepositoryName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists npm packages.

Parameters
NameDescription
parentRepositoryName

Required. The name of the parent resource whose npm packages will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListNpmPackagesResponseNpmPackage

A pageable asynchronous sequence of NpmPackage resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
RepositoryName parent = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
// Make the request
PagedAsyncEnumerable<ListNpmPackagesResponse, NpmPackage> response = artifactRegistryClient.ListNpmPackagesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((NpmPackage item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListNpmPackagesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (NpmPackage 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<NpmPackage> 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 (NpmPackage 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;

ListNpmPackagesAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListNpmPackagesResponse, NpmPackage> ListNpmPackagesAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists npm packages.

Parameters
NameDescription
parentstring

Required. The name of the parent resource whose npm packages will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListNpmPackagesResponseNpmPackage

A pageable asynchronous sequence of NpmPackage resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]";
// Make the request
PagedAsyncEnumerable<ListNpmPackagesResponse, NpmPackage> response = artifactRegistryClient.ListNpmPackagesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((NpmPackage item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListNpmPackagesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (NpmPackage 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<NpmPackage> 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 (NpmPackage 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;

ListPackages(ListPackagesRequest, CallSettings)

public virtual PagedEnumerable<ListPackagesResponse, Package> ListPackages(ListPackagesRequest request, CallSettings callSettings = null)

Lists packages.

Parameters
NameDescription
requestListPackagesRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListPackagesResponsePackage

A pageable sequence of Package resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
ListPackagesRequest request = new ListPackagesRequest
{
    ParentAsRepositoryName = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]"),
};
// Make the request
PagedEnumerable<ListPackagesResponse, Package> response = artifactRegistryClient.ListPackages(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (Package 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 (ListPackagesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Package 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<Package> 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 (Package 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;

ListPackages(RepositoryName, string, int?, CallSettings)

public virtual PagedEnumerable<ListPackagesResponse, Package> ListPackages(RepositoryName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists packages.

Parameters
NameDescription
parentRepositoryName

Required. The name of the parent resource whose packages will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListPackagesResponsePackage

A pageable sequence of Package resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
RepositoryName parent = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
// Make the request
PagedEnumerable<ListPackagesResponse, Package> response = artifactRegistryClient.ListPackages(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (Package 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 (ListPackagesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Package 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<Package> 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 (Package 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;

ListPackages(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListPackagesResponse, Package> ListPackages(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists packages.

Parameters
NameDescription
parentstring

Required. The name of the parent resource whose packages will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListPackagesResponsePackage

A pageable sequence of Package resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]";
// Make the request
PagedEnumerable<ListPackagesResponse, Package> response = artifactRegistryClient.ListPackages(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (Package 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 (ListPackagesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Package 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<Package> 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 (Package 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;

ListPackagesAsync(ListPackagesRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListPackagesResponse, Package> ListPackagesAsync(ListPackagesRequest request, CallSettings callSettings = null)

Lists packages.

Parameters
NameDescription
requestListPackagesRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListPackagesResponsePackage

A pageable asynchronous sequence of Package resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
ListPackagesRequest request = new ListPackagesRequest
{
    ParentAsRepositoryName = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]"),
};
// Make the request
PagedAsyncEnumerable<ListPackagesResponse, Package> response = artifactRegistryClient.ListPackagesAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Package item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListPackagesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Package 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<Package> 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 (Package 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;

ListPackagesAsync(RepositoryName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListPackagesResponse, Package> ListPackagesAsync(RepositoryName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists packages.

Parameters
NameDescription
parentRepositoryName

Required. The name of the parent resource whose packages will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListPackagesResponsePackage

A pageable asynchronous sequence of Package resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
RepositoryName parent = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
// Make the request
PagedAsyncEnumerable<ListPackagesResponse, Package> response = artifactRegistryClient.ListPackagesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Package item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListPackagesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Package 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<Package> 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 (Package 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;

ListPackagesAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListPackagesResponse, Package> ListPackagesAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists packages.

Parameters
NameDescription
parentstring

Required. The name of the parent resource whose packages will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListPackagesResponsePackage

A pageable asynchronous sequence of Package resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]";
// Make the request
PagedAsyncEnumerable<ListPackagesResponse, Package> response = artifactRegistryClient.ListPackagesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Package item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListPackagesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Package 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<Package> 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 (Package 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;

ListPythonPackages(ListPythonPackagesRequest, CallSettings)

public virtual PagedEnumerable<ListPythonPackagesResponse, PythonPackage> ListPythonPackages(ListPythonPackagesRequest request, CallSettings callSettings = null)

Lists python packages.

Parameters
NameDescription
requestListPythonPackagesRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListPythonPackagesResponsePythonPackage

A pageable sequence of PythonPackage resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
ListPythonPackagesRequest request = new ListPythonPackagesRequest
{
    ParentAsRepositoryName = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]"),
};
// Make the request
PagedEnumerable<ListPythonPackagesResponse, PythonPackage> response = artifactRegistryClient.ListPythonPackages(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (PythonPackage 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 (ListPythonPackagesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (PythonPackage 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<PythonPackage> 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 (PythonPackage 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;

ListPythonPackages(RepositoryName, string, int?, CallSettings)

public virtual PagedEnumerable<ListPythonPackagesResponse, PythonPackage> ListPythonPackages(RepositoryName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists python packages.

Parameters
NameDescription
parentRepositoryName

Required. The name of the parent resource whose python packages will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListPythonPackagesResponsePythonPackage

A pageable sequence of PythonPackage resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
RepositoryName parent = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
// Make the request
PagedEnumerable<ListPythonPackagesResponse, PythonPackage> response = artifactRegistryClient.ListPythonPackages(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (PythonPackage 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 (ListPythonPackagesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (PythonPackage 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<PythonPackage> 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 (PythonPackage 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;

ListPythonPackages(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListPythonPackagesResponse, PythonPackage> ListPythonPackages(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists python packages.

Parameters
NameDescription
parentstring

Required. The name of the parent resource whose python packages will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListPythonPackagesResponsePythonPackage

A pageable sequence of PythonPackage resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]";
// Make the request
PagedEnumerable<ListPythonPackagesResponse, PythonPackage> response = artifactRegistryClient.ListPythonPackages(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (PythonPackage 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 (ListPythonPackagesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (PythonPackage 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<PythonPackage> 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 (PythonPackage 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;

ListPythonPackagesAsync(ListPythonPackagesRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListPythonPackagesResponse, PythonPackage> ListPythonPackagesAsync(ListPythonPackagesRequest request, CallSettings callSettings = null)

Lists python packages.

Parameters
NameDescription
requestListPythonPackagesRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListPythonPackagesResponsePythonPackage

A pageable asynchronous sequence of PythonPackage resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
ListPythonPackagesRequest request = new ListPythonPackagesRequest
{
    ParentAsRepositoryName = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]"),
};
// Make the request
PagedAsyncEnumerable<ListPythonPackagesResponse, PythonPackage> response = artifactRegistryClient.ListPythonPackagesAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((PythonPackage item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListPythonPackagesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (PythonPackage 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<PythonPackage> 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 (PythonPackage 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;

ListPythonPackagesAsync(RepositoryName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListPythonPackagesResponse, PythonPackage> ListPythonPackagesAsync(RepositoryName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists python packages.

Parameters
NameDescription
parentRepositoryName

Required. The name of the parent resource whose python packages will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListPythonPackagesResponsePythonPackage

A pageable asynchronous sequence of PythonPackage resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
RepositoryName parent = RepositoryName.FromProjectLocationRepository("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
// Make the request
PagedAsyncEnumerable<ListPythonPackagesResponse, PythonPackage> response = artifactRegistryClient.ListPythonPackagesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((PythonPackage item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListPythonPackagesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (PythonPackage 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<PythonPackage> 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 (PythonPackage 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;

ListPythonPackagesAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListPythonPackagesResponse, PythonPackage> ListPythonPackagesAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists python packages.

Parameters
NameDescription
parentstring

Required. The name of the parent resource whose python packages will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListPythonPackagesResponsePythonPackage

A pageable asynchronous sequence of PythonPackage resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/repositories/[REPOSITORY]";
// Make the request
PagedAsyncEnumerable<ListPythonPackagesResponse, PythonPackage> response = artifactRegistryClient.ListPythonPackagesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((PythonPackage item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListPythonPackagesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (PythonPackage 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<PythonPackage> 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 (PythonPackage 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;

ListRepositories(LocationName, string, int?, CallSettings)

public virtual PagedEnumerable<ListRepositoriesResponse, Repository> ListRepositories(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists repositories.

Parameters
NameDescription
parentLocationName

Required. The name of the parent resource whose repositories will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListRepositoriesResponseRepository

A pageable sequence of Repository resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedEnumerable<ListRepositoriesResponse, Repository> response = artifactRegistryClient.ListRepositories(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (Repository 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 (ListRepositoriesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Repository 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<Repository> 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 (Repository 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;

ListRepositories(ListRepositoriesRequest, CallSettings)

public virtual PagedEnumerable<ListRepositoriesResponse, Repository> ListRepositories(ListRepositoriesRequest request, CallSettings callSettings = null)

Lists repositories.

Parameters
NameDescription
requestListRepositoriesRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListRepositoriesResponseRepository

A pageable sequence of Repository resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
ListRepositoriesRequest request = new ListRepositoriesRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
};
// Make the request
PagedEnumerable<ListRepositoriesResponse, Repository> response = artifactRegistryClient.ListRepositories(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (Repository 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 (ListRepositoriesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Repository 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<Repository> 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 (Repository 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;

ListRepositories(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListRepositoriesResponse, Repository> ListRepositories(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists repositories.

Parameters
NameDescription
parentstring

Required. The name of the parent resource whose repositories will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListRepositoriesResponseRepository

A pageable sequence of Repository resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedEnumerable<ListRepositoriesResponse, Repository> response = artifactRegistryClient.ListRepositories(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (Repository 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 (ListRepositoriesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Repository 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<Repository> 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 (Repository 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;

ListRepositoriesAsync(LocationName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListRepositoriesResponse, Repository> ListRepositoriesAsync(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists repositories.

Parameters
NameDescription
parentLocationName

Required. The name of the parent resource whose repositories will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListRepositoriesResponseRepository

A pageable asynchronous sequence of Repository resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedAsyncEnumerable<ListRepositoriesResponse, Repository> response = artifactRegistryClient.ListRepositoriesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Repository item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListRepositoriesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Repository 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<Repository> 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 (Repository 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;

ListRepositoriesAsync(ListRepositoriesRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListRepositoriesResponse, Repository> ListRepositoriesAsync(ListRepositoriesRequest request, CallSettings callSettings = null)

Lists repositories.

Parameters
NameDescription
requestListRepositoriesRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListRepositoriesResponseRepository

A pageable asynchronous sequence of Repository resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
ListRepositoriesRequest request = new ListRepositoriesRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
};
// Make the request
PagedAsyncEnumerable<ListRepositoriesResponse, Repository> response = artifactRegistryClient.ListRepositoriesAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Repository item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListRepositoriesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Repository 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<Repository> 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 (Repository 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;

ListRepositoriesAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListRepositoriesResponse, Repository> ListRepositoriesAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists repositories.

Parameters
NameDescription
parentstring

Required. The name of the parent resource whose repositories will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerableListRepositoriesResponseRepository

A pageable asynchronous sequence of Repository resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = await ArtifactRegistryClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedAsyncEnumerable<ListRepositoriesResponse, Repository> response = artifactRegistryClient.ListRepositoriesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Repository item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListRepositoriesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Repository 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<Repository> 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 (Repository 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;

ListTags(ListTagsRequest, CallSettings)

public virtual PagedEnumerable<ListTagsResponse, Tag> ListTags(ListTagsRequest request, CallSettings callSettings = null)

Lists tags.

Parameters
NameDescription
requestListTagsRequest

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

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListTagsResponseTag

A pageable sequence of Tag resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
ListTagsRequest request = new ListTagsRequest
{
    Parent = "",
    Filter = "",
};
// Make the request
PagedEnumerable<ListTagsResponse, Tag> response = artifactRegistryClient.ListTags(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (Tag 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 (ListTagsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Tag 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<Tag> 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 (Tag 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;

ListTags(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListTagsResponse, Tag> ListTags(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists tags.

Parameters
NameDescription
parentstring

The name of the parent resource whose tags will be listed.

pageTokenstring

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

pageSizeint

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.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerableListTagsResponseTag

A pageable sequence of Tag resources.

Example
// Create client
ArtifactRegistryClient artifactRegistryClient = ArtifactRegistryClient.Create();
// Initialize request argument(s)
string parent = "";
// Make the request
PagedEnumerable<ListTagsResponse, Tag> response = artifactRegistryClient.ListTags(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (Tag 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 (ListTagsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Tag 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<Tag> 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 (Tag 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;