public async Task <Response <PrivateEndpointConnectionListResult> > ListByConfigurationStoreAsync(string resourceGroupName, string configStoreName, CancellationToken cancellationToken = default) { if (resourceGroupName == null) { throw new ArgumentNullException(nameof(resourceGroupName)); } if (configStoreName == null) { throw new ArgumentNullException(nameof(configStoreName)); } using var message = CreateListByConfigurationStoreRequest(resourceGroupName, configStoreName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: { PrivateEndpointConnectionListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); if (document.RootElement.ValueKind == JsonValueKind.Null) { value = null; } else { value = PrivateEndpointConnectionListResult.DeserializePrivateEndpointConnectionListResult(document.RootElement); } return(Response.FromValue(value, message.Response)); }
public async Task <Response <PrivateEndpointConnectionListResult> > ListByAccountAsync(string subscriptionId, string resourceGroupName, string accountName, CancellationToken cancellationToken = default) { if (subscriptionId == null) { throw new ArgumentNullException(nameof(subscriptionId)); } if (resourceGroupName == null) { throw new ArgumentNullException(nameof(resourceGroupName)); } if (accountName == null) { throw new ArgumentNullException(nameof(accountName)); } using var message = CreateListByAccountRequest(subscriptionId, resourceGroupName, accountName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: { PrivateEndpointConnectionListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); value = PrivateEndpointConnectionListResult.DeserializePrivateEndpointConnectionListResult(document.RootElement); return(Response.FromValue(value, message.Response)); }
public async Task <Response <PrivateEndpointConnectionListResult> > ListAsync(string subscriptionId, string resourceGroupName, string namespaceName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(namespaceName, nameof(namespaceName)); using var message = CreateListRequest(subscriptionId, resourceGroupName, namespaceName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: { PrivateEndpointConnectionListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); value = PrivateEndpointConnectionListResult.DeserializePrivateEndpointConnectionListResult(document.RootElement); return(Response.FromValue(value, message.Response)); }