Share via


DeploymentEnvironmentsClient.GetCatalogs Method

Definition

Overloads

GetCatalogs(String, RequestContext)

[Protocol Method] Lists all of the catalogs available for a project.

GetCatalogs(String, CancellationToken)

Lists all of the catalogs available for a project.

GetCatalogs(String, Nullable<Int32>, RequestContext)

[Protocol Method] Lists all of the catalogs available for a project.

  • This protocol method allows explicit creation of the request and processing of the response for advanced scenarios.

GetCatalogs(String, RequestContext)

Source:
DeploymentEnvironmentsClient.cs

[Protocol Method] Lists all of the catalogs available for a project.

public virtual Azure.Pageable<BinaryData> GetCatalogs (string projectName, Azure.RequestContext context);
abstract member GetCatalogs : string * Azure.RequestContext -> Azure.Pageable<BinaryData>
override this.GetCatalogs : string * Azure.RequestContext -> Azure.Pageable<BinaryData>
Public Overridable Function GetCatalogs (projectName As String, context As RequestContext) As Pageable(Of BinaryData)

Parameters

projectName
String

Name of the project.

context
RequestContext

The request context, which can override default behaviors of the client pipeline on a per-call basis.

Returns

The Pageable<T> from the service containing a list of BinaryData objects. Details of the body schema for each item in the collection are in the Remarks section below.

Exceptions

projectName is null.

projectName is an empty string, and was expected to be non-empty.

Service returned a non-success status code.

Examples

This sample shows how to call GetCatalogs and parse the result.

Uri endpoint = new Uri("<https://my-service.azure.com>");
TokenCredential credential = new DefaultAzureCredential();
DeploymentEnvironmentsClient client = new DeploymentEnvironmentsClient(endpoint, credential);

foreach (BinaryData item in client.GetCatalogs("<projectName>", null))
{
    JsonElement result = JsonDocument.Parse(item.ToStream()).RootElement;
    Console.WriteLine(result.GetProperty("name").ToString());
}

This sample shows how to call GetCatalogs with all parameters and parse the result.

Uri endpoint = new Uri("<https://my-service.azure.com>");
TokenCredential credential = new DefaultAzureCredential();
DeploymentEnvironmentsClient client = new DeploymentEnvironmentsClient(endpoint, credential);

foreach (BinaryData item in client.GetCatalogs("<projectName>", null))
{
    JsonElement result = JsonDocument.Parse(item.ToStream()).RootElement;
    Console.WriteLine(result.GetProperty("name").ToString());
}

Applies to

GetCatalogs(String, CancellationToken)

Source:
DeploymentEnvironmentsClient.cs

Lists all of the catalogs available for a project.

public virtual Azure.Pageable<Azure.Developer.DevCenter.Models.DevCenterCatalog> GetCatalogs (string projectName, System.Threading.CancellationToken cancellationToken = default);
abstract member GetCatalogs : string * System.Threading.CancellationToken -> Azure.Pageable<Azure.Developer.DevCenter.Models.DevCenterCatalog>
override this.GetCatalogs : string * System.Threading.CancellationToken -> Azure.Pageable<Azure.Developer.DevCenter.Models.DevCenterCatalog>
Public Overridable Function GetCatalogs (projectName As String, Optional cancellationToken As CancellationToken = Nothing) As Pageable(Of DevCenterCatalog)

Parameters

projectName
String

Name of the project.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

projectName is null.

projectName is an empty string, and was expected to be non-empty.

Examples

This sample shows how to call GetCatalogs.

Uri endpoint = new Uri("<https://my-service.azure.com>");
TokenCredential credential = new DefaultAzureCredential();
DeploymentEnvironmentsClient client = new DeploymentEnvironmentsClient(endpoint, credential);

foreach (DevCenterCatalog item in client.GetCatalogs("<projectName>"))
{
}

This sample shows how to call GetCatalogs with all parameters.

Uri endpoint = new Uri("<https://my-service.azure.com>");
TokenCredential credential = new DefaultAzureCredential();
DeploymentEnvironmentsClient client = new DeploymentEnvironmentsClient(endpoint, credential);

foreach (DevCenterCatalog item in client.GetCatalogs("<projectName>"))
{
}

Applies to

GetCatalogs(String, Nullable<Int32>, RequestContext)

Source:
DeploymentEnvironmentsClient.cs

[Protocol Method] Lists all of the catalogs available for a project.

  • This protocol method allows explicit creation of the request and processing of the response for advanced scenarios.
public virtual Azure.Pageable<BinaryData> GetCatalogs (string projectName, int? maxCount, Azure.RequestContext context);
abstract member GetCatalogs : string * Nullable<int> * Azure.RequestContext -> Azure.Pageable<BinaryData>
override this.GetCatalogs : string * Nullable<int> * Azure.RequestContext -> Azure.Pageable<BinaryData>
Public Overridable Function GetCatalogs (projectName As String, maxCount As Nullable(Of Integer), context As RequestContext) As Pageable(Of BinaryData)

Parameters

projectName
String

The DevCenter Project upon which to execute operations.

maxCount
Nullable<Int32>

The maximum number of resources to return from the operation. Example: 'top=10'.

context
RequestContext

The request context, which can override default behaviors of the client pipeline on a per-call basis.

Returns

The Pageable<T> from the service containing a list of BinaryData objects. Details of the body schema for each item in the collection are in the Remarks section below.

Exceptions

projectName is null.

projectName is an empty string, and was expected to be non-empty.

Service returned a non-success status code.

Examples

This sample shows how to call GetCatalogs and parse the result.

Uri endpoint = new Uri("<https://my-service.azure.com>");
TokenCredential credential = new DefaultAzureCredential();
DeploymentEnvironmentsClient client = new DeploymentEnvironmentsClient(endpoint, credential);

foreach (BinaryData item in client.GetCatalogs("<projectName>", null, null))
{
    JsonElement result = JsonDocument.Parse(item.ToStream()).RootElement;
    Console.WriteLine(result.GetProperty("name").ToString());
}

This sample shows how to call GetCatalogs with all parameters and parse the result.

Uri endpoint = new Uri("<https://my-service.azure.com>");
TokenCredential credential = new DefaultAzureCredential();
DeploymentEnvironmentsClient client = new DeploymentEnvironmentsClient(endpoint, credential);

foreach (BinaryData item in client.GetCatalogs("<projectName>", 1234, null))
{
    JsonElement result = JsonDocument.Parse(item.ToStream()).RootElement;
    Console.WriteLine(result.GetProperty("name").ToString());
}

Applies to