WorkloadImpactCollection.GetIfExists(String, CancellationToken) Method

Definition

Tries to get details for this resource from the service.

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

Parameters

workloadImpactName
String

workloadImpact resource .

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

workloadImpactName is null.

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

Applies to