LoadBalancerCollection.GetAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
| Name | Description |
|---|---|
| GetAsync(String, String, Nullable<LoadBalancerDetailLevel>, CancellationToken) |
Gets the specified load balancer.
|
| GetAsync(String, String, CancellationToken) |
Invokes the GetAsync compatibility operation. |
GetAsync(String, String, Nullable<LoadBalancerDetailLevel>, CancellationToken)
- Source:
- LoadBalancerCollection.cs
Gets the specified load balancer.
- Request Path. : /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/loadBalancers/{loadBalancerName}.
- Operation Id. : LoadBalancers_Get.
- Default Api Version. : 2025-07-01.
public virtual System.Threading.Tasks.Task<Azure.Response<Azure.ResourceManager.Network.LoadBalancerResource>> GetAsync(string loadBalancerName, string expand = default, Azure.ResourceManager.Network.Models.LoadBalancerDetailLevel? detailLevel = default, System.Threading.CancellationToken cancellationToken = default);
abstract member GetAsync : string * string * Nullable<Azure.ResourceManager.Network.Models.LoadBalancerDetailLevel> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.ResourceManager.Network.LoadBalancerResource>>
override this.GetAsync : string * string * Nullable<Azure.ResourceManager.Network.Models.LoadBalancerDetailLevel> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.ResourceManager.Network.LoadBalancerResource>>
Public Overridable Function GetAsync (loadBalancerName As String, Optional expand As String = Nothing, Optional detailLevel As Nullable(Of LoadBalancerDetailLevel) = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of LoadBalancerResource))
Parameters
- loadBalancerName
- String
The name of the load balancer.
- expand
- String
Expands referenced resources.
- detailLevel
- Nullable<LoadBalancerDetailLevel>
Controls verbosity of the returned load balancer resource. When set to 'Reduced', read-only back-reference collections (e.g., rules referencing frontendIPConfigurations) are omitted from the response.
- cancellationToken
- CancellationToken
The cancellation token to use.
Returns
Exceptions
loadBalancerName is null.
loadBalancerName is an empty string, and was expected to be non-empty.
Applies to
GetAsync(String, String, CancellationToken)
- Source:
- LoadBalancerCollection.cs
- Source:
- LoadBalancerCollection.cs
Invokes the GetAsync compatibility operation.
public virtual System.Threading.Tasks.Task<Azure.Response<Azure.ResourceManager.Network.LoadBalancerResource>> GetAsync(string p0, string p1, System.Threading.CancellationToken p2);
public virtual System.Threading.Tasks.Task<Azure.Response<Azure.ResourceManager.Network.LoadBalancerResource>> GetAsync(string loadBalancerName, string expand = default, System.Threading.CancellationToken cancellationToken = default);
abstract member GetAsync : string * string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.ResourceManager.Network.LoadBalancerResource>>
override this.GetAsync : string * string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.ResourceManager.Network.LoadBalancerResource>>
abstract member GetAsync : string * string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.ResourceManager.Network.LoadBalancerResource>>
override this.GetAsync : string * string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.ResourceManager.Network.LoadBalancerResource>>
Public Overridable Function GetAsync (p0 As String, p1 As String, p2 As CancellationToken) As Task(Of Response(Of LoadBalancerResource))
Public Overridable Function GetAsync (loadBalancerName As String, Optional expand As String = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of LoadBalancerResource))
Parameters
- p0loadBalancerName
- String
- p1expand
- String
- p2cancellationToken
- CancellationToken
Returns
Exceptions
loadBalancerName is an empty string, and was expected to be non-empty.
loadBalancerName is null.