Share via


ScriptPackageCollection.GetIfExists(String, CancellationToken) Method

Definition

Tries to get details for this resource from the service.

  • Request Path: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AVS/privateClouds/{privateCloudName}/scriptPackages/{scriptPackageName}
  • Operation Id: ScriptPackages_Get
  • Default Api Version: 2023-03-01
  • Resource: ScriptPackageResource
public virtual Azure.NullableResponse<Azure.ResourceManager.Avs.ScriptPackageResource> GetIfExists (string scriptPackageName, System.Threading.CancellationToken cancellationToken = default);
abstract member GetIfExists : string * System.Threading.CancellationToken -> Azure.NullableResponse<Azure.ResourceManager.Avs.ScriptPackageResource>
override this.GetIfExists : string * System.Threading.CancellationToken -> Azure.NullableResponse<Azure.ResourceManager.Avs.ScriptPackageResource>
Public Overridable Function GetIfExists (scriptPackageName As String, Optional cancellationToken As CancellationToken = Nothing) As NullableResponse(Of ScriptPackageResource)

Parameters

scriptPackageName
String

Name of the script package in the private cloud.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

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

scriptPackageName is null.

Applies to