Condividi tramite


NetworkExtensions.GetLoadBalancers Method

Definition

Overloads

GetLoadBalancers(ResourceGroupResource)

Gets a collection of LoadBalancerResources in the ResourceGroupResource. MockingTo mock this method, please mock GetLoadBalancers() instead.

GetLoadBalancers(SubscriptionResource, CancellationToken)

Gets all the load balancers in a subscription.

  • Request Path: /subscriptions/{subscriptionId}/providers/Microsoft.Network/loadBalancers
  • Operation Id: LoadBalancers_ListAll
  • Default Api Version: 2024-03-01
  • Resource: LoadBalancerResource

GetLoadBalancers(ResourceGroupResource)

Source:
NetworkExtensions.cs
Source:
NetworkExtensions.cs

Gets a collection of LoadBalancerResources in the ResourceGroupResource. MockingTo mock this method, please mock GetLoadBalancers() instead.

public static Azure.ResourceManager.Network.LoadBalancerCollection GetLoadBalancers (this Azure.ResourceManager.Resources.ResourceGroupResource resourceGroupResource);
static member GetLoadBalancers : Azure.ResourceManager.Resources.ResourceGroupResource -> Azure.ResourceManager.Network.LoadBalancerCollection
<Extension()>
Public Function GetLoadBalancers (resourceGroupResource As ResourceGroupResource) As LoadBalancerCollection

Parameters

resourceGroupResource
ResourceGroupResource

The ResourceGroupResource instance the method will execute against.

Returns

An object representing collection of LoadBalancerResources and their operations over a LoadBalancerResource.

Exceptions

resourceGroupResource is null.

Applies to

GetLoadBalancers(SubscriptionResource, CancellationToken)

Source:
NetworkExtensions.cs
Source:
NetworkExtensions.cs

Gets all the load balancers in a subscription.

  • Request Path: /subscriptions/{subscriptionId}/providers/Microsoft.Network/loadBalancers
  • Operation Id: LoadBalancers_ListAll
  • Default Api Version: 2024-03-01
  • Resource: LoadBalancerResource
public static Azure.Pageable<Azure.ResourceManager.Network.LoadBalancerResource> GetLoadBalancers (this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default);
static member GetLoadBalancers : Azure.ResourceManager.Resources.SubscriptionResource * System.Threading.CancellationToken -> Azure.Pageable<Azure.ResourceManager.Network.LoadBalancerResource>
<Extension()>
Public Function GetLoadBalancers (subscriptionResource As SubscriptionResource, Optional cancellationToken As CancellationToken = Nothing) As Pageable(Of LoadBalancerResource)

Parameters

subscriptionResource
SubscriptionResource

The SubscriptionResource instance the method will execute against.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

A collection of LoadBalancerResource that may take multiple service requests to iterate over.

Exceptions

subscriptionResource is null.

Applies to