Share via


NetworkExtensions.GetVpnGateways Method

Definition

Overloads

GetVpnGateways(SubscriptionResource, CancellationToken)

Lists all the VpnGateways in a subscription.

  • Request Path: /subscriptions/{subscriptionId}/providers/Microsoft.Network/vpnGateways
  • Operation Id: VpnGateways_List
  • Default Api Version: 2024-03-01
  • Resource: VpnGatewayResource
GetVpnGateways(ResourceGroupResource)

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

GetVpnGateways(SubscriptionResource, CancellationToken)

Source:
NetworkExtensions.cs
Source:
NetworkExtensions.cs

Lists all the VpnGateways in a subscription.

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

Parameters

subscriptionResource
SubscriptionResource

The SubscriptionResource instance the method will execute against.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

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

Exceptions

subscriptionResource is null.

Applies to

GetVpnGateways(ResourceGroupResource)

Source:
NetworkExtensions.cs
Source:
NetworkExtensions.cs

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

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

Parameters

resourceGroupResource
ResourceGroupResource

The ResourceGroupResource instance the method will execute against.

Returns

An object representing collection of VpnGatewayResources and their operations over a VpnGatewayResource.

Exceptions

resourceGroupResource is null.

Applies to