ImpactCategoryCollection.GetIfExistsAsync(String, CancellationToken) Method

Definition

Tries to get details for this resource from the service.

  • Request Path. : /subscriptions/{subscriptionId}/providers/Microsoft.Impact/impactCategories/{impactCategoryName}.
  • Operation Id. : ImpactCategories_Get.
  • Default Api Version. : 2024-05-01-preview.
public virtual System.Threading.Tasks.Task<Azure.NullableResponse<Azure.ResourceManager.ImpactReporting.ImpactCategoryResource>> GetIfExistsAsync(string impactCategoryName, System.Threading.CancellationToken cancellationToken = default);
abstract member GetIfExistsAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.NullableResponse<Azure.ResourceManager.ImpactReporting.ImpactCategoryResource>>
override this.GetIfExistsAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.NullableResponse<Azure.ResourceManager.ImpactReporting.ImpactCategoryResource>>
Public Overridable Function GetIfExistsAsync (impactCategoryName As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of NullableResponse(Of ImpactCategoryResource))

Parameters

impactCategoryName
String

Name of the impact category.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

impactCategoryName is null.

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

Applies to