From e43efb57a44460bc7d5c62af09009d0833a6b768 Mon Sep 17 00:00:00 2001 From: Azure SDK for Python bot Date: Thu, 26 Jul 2018 17:57:00 +0000 Subject: [PATCH] Generated from 664600e3132d147f15bb414e19f742a1d8030a2c Update network management Node.js package version to 6.0.0 --- lib/services/networkManagement2/LICENSE.txt | 42 +- .../lib/models/applicationGateway.js | 43 +- ...icationGatewayAuthenticationCertificate.js | 4 +- .../applicationGatewayAutoscaleBounds.js | 63 + ...pplicationGatewayAutoscaleConfiguration.js | 59 + .../applicationGatewayBackendAddressPool.js | 4 +- ...icationGatewayBackendHealthHttpSettings.js | 13 +- .../applicationGatewayBackendHealthPool.js | 4 +- .../applicationGatewayBackendHttpSettings.js | 11 +- ...plicationGatewayFrontendIPConfiguration.js | 4 +- .../models/applicationGatewayFrontendPort.js | 4 +- .../models/applicationGatewayHttpListener.js | 8 +- .../applicationGatewayIPConfiguration.js | 4 +- .../lib/models/applicationGatewayPathRule.js | 4 +- .../lib/models/applicationGatewayProbe.js | 8 +- ...applicationGatewayRedirectConfiguration.js | 4 +- .../applicationGatewayRequestRoutingRule.js | 8 +- .../lib/models/applicationGatewaySku.js | 4 +- .../applicationGatewaySslCertificate.js | 4 +- .../applicationGatewaySslPredefinedPolicy.js | 2 +- .../models/applicationGatewayUrlPathMap.js | 4 +- .../lib/models/azureFirewall.js | 163 + .../models/azureFirewallApplicationRule.js | 109 + .../azureFirewallApplicationRuleCollection.js | 125 + .../azureFirewallApplicationRuleProtocol.js | 66 + .../models/azureFirewallIPConfiguration.js | 125 + .../lib/models/azureFirewallListResult.js | 67 + .../lib/models/azureFirewallNetworkRule.js | 121 + .../azureFirewallNetworkRuleCollection.js | 125 + .../lib/models/azureFirewallRCAction.js | 53 + .../lib/models/connectionSharedKey.js | 13 +- .../lib/models/ddosProtectionPlan.js | 10 +- .../lib/models/deviceProperties.js | 68 + .../lib/models/expressRouteCircuitArpTable.js | 4 +- .../models/expressRouteCircuitRoutesTable.js | 12 +- .../expressRouteCircuitRoutesTableSummary.js | 2 +- .../lib/models/expressRouteCrossConnection.js | 3 - .../expressRouteCrossConnectionPeering.js | 1 - .../lib/models/flowLogInformation.js | 28 +- .../lib/models/flowLogStatusParameters.js | 5 +- .../models/getVpnSitesConfigurationRequest.js | 72 + .../lib/models/hubVirtualNetworkConnection.js | 141 + .../networkManagement2/lib/models/index.d.ts | 847 +- .../networkManagement2/lib/models/index.js | 31 +- .../listHubVirtualNetworkConnectionsResult.js | 69 + .../lib/models/listVirtualHubsResult.js | 69 + .../lib/models/listVirtualWANsResult.js | 69 + .../lib/models/listVpnConnectionsResult.js | 70 + .../lib/models/listVpnGatewaysResult.js | 69 + .../lib/models/listVpnSitesResult.js | 69 + .../networkManagement2/lib/models/policies.js | 62 + .../networkManagement2/lib/models/probe.js | 8 +- ...trafficAnalyticsConfigurationProperties.js | 76 + .../lib/models/trafficAnalyticsProperties.js | 65 + .../lib/models/virtualHub.js | 148 + .../lib/models/virtualNetworkGateway.js | 6 +- .../models/virtualNetworkGatewayConnection.js | 12 +- .../lib/models/virtualNetworkGatewaySku.js | 6 +- .../lib/models/virtualWAN.js | 155 + .../lib/models/vpnConnection.js | 199 + .../lib/models/vpnGateway.js | 166 + .../networkManagement2/lib/models/vpnSite.js | 178 + .../lib/models/vpnSiteId.js | 54 + .../lib/networkManagementClient.d.ts | 10 +- .../lib/networkManagementClient.js | 15 +- .../lib/operations/applicationGateways.js | 198 +- .../operations/applicationSecurityGroups.js | 30 +- .../operations/availableEndpointServices.js | 6 +- .../lib/operations/azureFirewalls.js | 2042 ++ .../lib/operations/bgpServiceCommunities.js | 6 +- .../lib/operations/connectionMonitors.js | 42 +- .../lib/operations/ddosProtectionPlans.js | 42 +- .../lib/operations/defaultSecurityRules.js | 12 +- .../expressRouteCircuitAuthorizations.js | 24 +- .../expressRouteCircuitConnections.js | 18 +- .../operations/expressRouteCircuitPeerings.js | 30 +- .../lib/operations/expressRouteCircuits.js | 66 +- .../expressRouteCrossConnectionPeerings.js | 42 +- .../expressRouteCrossConnections.js | 108 +- .../expressRouteServiceProviders.js | 6 +- .../hubVirtualNetworkConnections.js | 720 + .../lib/operations/inboundNatRules.js | 24 +- .../lib/operations/index.d.ts | 29978 +++++++++------- .../lib/operations/index.js | 8 + .../loadBalancerBackendAddressPools.js | 12 +- .../loadBalancerFrontendIPConfigurations.js | 12 +- .../loadBalancerLoadBalancingRules.js | 12 +- .../loadBalancerNetworkInterfaces.js | 6 +- .../lib/operations/loadBalancerProbes.js | 12 +- .../lib/operations/loadBalancers.js | 36 +- .../lib/operations/localNetworkGateways.js | 30 +- .../networkInterfaceIPConfigurations.js | 12 +- .../networkInterfaceLoadBalancers.js | 6 +- .../lib/operations/networkInterfaces.js | 58 +- .../lib/operations/networkSecurityGroups.js | 36 +- .../lib/operations/networkWatchers.js | 300 +- .../lib/operations/operations.js | 6 +- .../lib/operations/packetCaptures.js | 36 +- .../lib/operations/publicIPAddresses.js | 42 +- .../lib/operations/routeFilterRules.js | 30 +- .../lib/operations/routeFilters.js | 36 +- .../lib/operations/routeTables.js | 36 +- .../lib/operations/routes.js | 24 +- .../lib/operations/securityRules.js | 24 +- .../lib/operations/subnets.js | 24 +- .../lib/operations/usages.js | 6 +- .../lib/operations/virtualHubs.js | 2519 ++ .../virtualNetworkGatewayConnections.js | 124 +- .../lib/operations/virtualNetworkGateways.js | 138 +- .../lib/operations/virtualNetworkPeerings.js | 24 +- .../lib/operations/virtualNetworks.js | 48 +- .../lib/operations/virtualWANs.js | 2471 ++ .../lib/operations/vpnConnections.js | 1745 + .../lib/operations/vpnGateways.js | 2627 ++ .../lib/operations/vpnSites.js | 2687 ++ .../lib/operations/vpnSitesConfiguration.js | 473 + lib/services/networkManagement2/package.json | 9 +- 117 files changed, 37485 insertions(+), 13645 deletions(-) create mode 100644 lib/services/networkManagement2/lib/models/applicationGatewayAutoscaleBounds.js create mode 100644 lib/services/networkManagement2/lib/models/applicationGatewayAutoscaleConfiguration.js create mode 100644 lib/services/networkManagement2/lib/models/azureFirewall.js create mode 100644 lib/services/networkManagement2/lib/models/azureFirewallApplicationRule.js create mode 100644 lib/services/networkManagement2/lib/models/azureFirewallApplicationRuleCollection.js create mode 100644 lib/services/networkManagement2/lib/models/azureFirewallApplicationRuleProtocol.js create mode 100644 lib/services/networkManagement2/lib/models/azureFirewallIPConfiguration.js create mode 100644 lib/services/networkManagement2/lib/models/azureFirewallListResult.js create mode 100644 lib/services/networkManagement2/lib/models/azureFirewallNetworkRule.js create mode 100644 lib/services/networkManagement2/lib/models/azureFirewallNetworkRuleCollection.js create mode 100644 lib/services/networkManagement2/lib/models/azureFirewallRCAction.js create mode 100644 lib/services/networkManagement2/lib/models/deviceProperties.js create mode 100644 lib/services/networkManagement2/lib/models/getVpnSitesConfigurationRequest.js create mode 100644 lib/services/networkManagement2/lib/models/hubVirtualNetworkConnection.js create mode 100644 lib/services/networkManagement2/lib/models/listHubVirtualNetworkConnectionsResult.js create mode 100644 lib/services/networkManagement2/lib/models/listVirtualHubsResult.js create mode 100644 lib/services/networkManagement2/lib/models/listVirtualWANsResult.js create mode 100644 lib/services/networkManagement2/lib/models/listVpnConnectionsResult.js create mode 100644 lib/services/networkManagement2/lib/models/listVpnGatewaysResult.js create mode 100644 lib/services/networkManagement2/lib/models/listVpnSitesResult.js create mode 100644 lib/services/networkManagement2/lib/models/policies.js create mode 100644 lib/services/networkManagement2/lib/models/trafficAnalyticsConfigurationProperties.js create mode 100644 lib/services/networkManagement2/lib/models/trafficAnalyticsProperties.js create mode 100644 lib/services/networkManagement2/lib/models/virtualHub.js create mode 100644 lib/services/networkManagement2/lib/models/virtualWAN.js create mode 100644 lib/services/networkManagement2/lib/models/vpnConnection.js create mode 100644 lib/services/networkManagement2/lib/models/vpnGateway.js create mode 100644 lib/services/networkManagement2/lib/models/vpnSite.js create mode 100644 lib/services/networkManagement2/lib/models/vpnSiteId.js create mode 100644 lib/services/networkManagement2/lib/operations/azureFirewalls.js create mode 100644 lib/services/networkManagement2/lib/operations/hubVirtualNetworkConnections.js create mode 100644 lib/services/networkManagement2/lib/operations/virtualHubs.js create mode 100644 lib/services/networkManagement2/lib/operations/virtualWANs.js create mode 100644 lib/services/networkManagement2/lib/operations/vpnConnections.js create mode 100644 lib/services/networkManagement2/lib/operations/vpnGateways.js create mode 100644 lib/services/networkManagement2/lib/operations/vpnSites.js create mode 100644 lib/services/networkManagement2/lib/operations/vpnSitesConfiguration.js diff --git a/lib/services/networkManagement2/LICENSE.txt b/lib/services/networkManagement2/LICENSE.txt index a70e8cf660..5431ba98b9 100644 --- a/lib/services/networkManagement2/LICENSE.txt +++ b/lib/services/networkManagement2/LICENSE.txt @@ -1,21 +1,21 @@ -The MIT License (MIT) - -Copyright (c) 2018 Microsoft - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +The MIT License (MIT) + +Copyright (c) 2018 Microsoft + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lib/services/networkManagement2/lib/models/applicationGateway.js b/lib/services/networkManagement2/lib/models/applicationGateway.js index 47ddea3f90..e6578da902 100644 --- a/lib/services/networkManagement2/lib/models/applicationGateway.js +++ b/lib/services/networkManagement2/lib/models/applicationGateway.js @@ -23,9 +23,9 @@ class ApplicationGateway extends models['Resource'] { * @member {object} [sku] SKU of the application gateway resource. * @member {string} [sku.name] Name of an application gateway SKU. Possible * values include: 'Standard_Small', 'Standard_Medium', 'Standard_Large', - * 'WAF_Medium', 'WAF_Large' + * 'WAF_Medium', 'WAF_Large', 'Standard_v2', 'WAF_v2' * @member {string} [sku.tier] Tier of an application gateway. Possible - * values include: 'Standard', 'WAF' + * values include: 'Standard', 'WAF', 'Standard_v2', 'WAF_v2' * @member {number} [sku.capacity] Capacity (instance count) of an * application gateway. * @member {object} [sslPolicy] SSL policy of the application gateway @@ -88,6 +88,14 @@ class ApplicationGateway extends models['Resource'] { * Maxium request body size for WAF. * @member {boolean} [enableHttp2] Whether HTTP2 is enabled on the * application gateway resource. + * @member {boolean} [enableFips] Whether FIPS is enabled on the application + * gateway resource. + * @member {object} [autoscaleConfiguration] Autoscale Configuration. + * @member {object} [autoscaleConfiguration.bounds] Autoscale bounds + * @member {number} [autoscaleConfiguration.bounds.min] Lower bound on number + * of Application Gateway instances. + * @member {number} [autoscaleConfiguration.bounds.max] Upper bound on number + * of Application Gateway instances. * @member {string} [resourceGuid] Resource GUID property of the application * gateway resource. * @member {string} [provisioningState] Provisioning state of the application @@ -95,6 +103,8 @@ class ApplicationGateway extends models['Resource'] { * 'Failed'. * @member {string} [etag] A unique read-only string that changes whenever * the resource is updated. + * @member {array} [zones] A list of availability zones denoting where the + * resource needs to come from. */ constructor() { super(); @@ -377,6 +387,21 @@ class ApplicationGateway extends models['Resource'] { name: 'Boolean' } }, + enableFips: { + required: false, + serializedName: 'properties.enableFips', + type: { + name: 'Boolean' + } + }, + autoscaleConfiguration: { + required: false, + serializedName: 'properties.autoscaleConfiguration', + type: { + name: 'Composite', + className: 'ApplicationGatewayAutoscaleConfiguration' + } + }, resourceGuid: { required: false, serializedName: 'properties.resourceGuid', @@ -397,6 +422,20 @@ class ApplicationGateway extends models['Resource'] { type: { name: 'String' } + }, + zones: { + required: false, + serializedName: 'zones', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'StringElementType', + type: { + name: 'String' + } + } + } } } } diff --git a/lib/services/networkManagement2/lib/models/applicationGatewayAuthenticationCertificate.js b/lib/services/networkManagement2/lib/models/applicationGatewayAuthenticationCertificate.js index 14cb3e2832..5836499b6b 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewayAuthenticationCertificate.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewayAuthenticationCertificate.js @@ -24,8 +24,8 @@ class ApplicationGatewayAuthenticationCertificate extends models['SubResource'] * @member {string} [provisioningState] Provisioning state of the * authentication certificate resource. Possible values are: 'Updating', * 'Deleting', and 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the authentication certificate that is + * unique within an Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever * the resource is updated. * @member {string} [type] Type of the resource. diff --git a/lib/services/networkManagement2/lib/models/applicationGatewayAutoscaleBounds.js b/lib/services/networkManagement2/lib/models/applicationGatewayAutoscaleBounds.js new file mode 100644 index 0000000000..65931cdbf8 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/applicationGatewayAutoscaleBounds.js @@ -0,0 +1,63 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +/** + * Application Gateway autoscale bounds on number of Application Gateway + * instance. + * + */ +class ApplicationGatewayAutoscaleBounds { + /** + * Create a ApplicationGatewayAutoscaleBounds. + * @member {number} min Lower bound on number of Application Gateway + * instances. + * @member {number} max Upper bound on number of Application Gateway + * instances. + */ + constructor() { + } + + /** + * Defines the metadata of ApplicationGatewayAutoscaleBounds + * + * @returns {object} metadata of ApplicationGatewayAutoscaleBounds + * + */ + mapper() { + return { + required: false, + serializedName: 'ApplicationGatewayAutoscaleBounds', + type: { + name: 'Composite', + className: 'ApplicationGatewayAutoscaleBounds', + modelProperties: { + min: { + required: true, + serializedName: 'min', + type: { + name: 'Number' + } + }, + max: { + required: true, + serializedName: 'max', + type: { + name: 'Number' + } + } + } + } + }; + } +} + +module.exports = ApplicationGatewayAutoscaleBounds; diff --git a/lib/services/networkManagement2/lib/models/applicationGatewayAutoscaleConfiguration.js b/lib/services/networkManagement2/lib/models/applicationGatewayAutoscaleConfiguration.js new file mode 100644 index 0000000000..1cdf898a49 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/applicationGatewayAutoscaleConfiguration.js @@ -0,0 +1,59 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const models = require('./index'); + +/** + * Application Gateway autoscale configuration. + * + */ +class ApplicationGatewayAutoscaleConfiguration { + /** + * Create a ApplicationGatewayAutoscaleConfiguration. + * @member {object} bounds Autoscale bounds + * @member {number} [bounds.min] Lower bound on number of Application Gateway + * instances. + * @member {number} [bounds.max] Upper bound on number of Application Gateway + * instances. + */ + constructor() { + } + + /** + * Defines the metadata of ApplicationGatewayAutoscaleConfiguration + * + * @returns {object} metadata of ApplicationGatewayAutoscaleConfiguration + * + */ + mapper() { + return { + required: false, + serializedName: 'ApplicationGatewayAutoscaleConfiguration', + type: { + name: 'Composite', + className: 'ApplicationGatewayAutoscaleConfiguration', + modelProperties: { + bounds: { + required: true, + serializedName: 'bounds', + type: { + name: 'Composite', + className: 'ApplicationGatewayAutoscaleBounds' + } + } + } + } + }; + } +} + +module.exports = ApplicationGatewayAutoscaleConfiguration; diff --git a/lib/services/networkManagement2/lib/models/applicationGatewayBackendAddressPool.js b/lib/services/networkManagement2/lib/models/applicationGatewayBackendAddressPool.js index 54daf5779f..17c091ffd8 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewayBackendAddressPool.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewayBackendAddressPool.js @@ -26,8 +26,8 @@ class ApplicationGatewayBackendAddressPool extends models['SubResource'] { * @member {string} [provisioningState] Provisioning state of the backend * address pool resource. Possible values are: 'Updating', 'Deleting', and * 'Failed'. - * @member {string} [name] Resource that is unique within a resource group. - * This name can be used to access the resource. + * @member {string} [name] Name of the backend address pool that is unique + * within an Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever * the resource is updated. * @member {string} [type] Type of the resource. diff --git a/lib/services/networkManagement2/lib/models/applicationGatewayBackendHealthHttpSettings.js b/lib/services/networkManagement2/lib/models/applicationGatewayBackendHealthHttpSettings.js index 082f243482..8cc553dbe8 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewayBackendHealthHttpSettings.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewayBackendHealthHttpSettings.js @@ -21,9 +21,11 @@ class ApplicationGatewayBackendHealthHttpSettings { * Create a ApplicationGatewayBackendHealthHttpSettings. * @member {object} [backendHttpSettings] Reference of an * ApplicationGatewayBackendHttpSettings resource. - * @member {number} [backendHttpSettings.port] Port - * @member {string} [backendHttpSettings.protocol] Protocol. Possible values - * include: 'Http', 'Https' + * @member {number} [backendHttpSettings.port] The destination port on the + * backend. + * @member {string} [backendHttpSettings.protocol] The protocol used to + * communicate with the backend. Possible values are 'Http' and 'Https'. + * Possible values include: 'Http', 'Https' * @member {string} [backendHttpSettings.cookieBasedAffinity] Cookie based * affinity. Possible values include: 'Enabled', 'Disabled' * @member {number} [backendHttpSettings.requestTimeout] Request timeout in @@ -58,9 +60,8 @@ class ApplicationGatewayBackendHealthHttpSettings { * @member {string} [backendHttpSettings.provisioningState] Provisioning * state of the backend http settings resource. Possible values are: * 'Updating', 'Deleting', and 'Failed'. - * @member {string} [backendHttpSettings.name] Name of the resource that is - * unique within a resource group. This name can be used to access the - * resource. + * @member {string} [backendHttpSettings.name] Name of the backend http + * settings that is unique within an Application Gateway. * @member {string} [backendHttpSettings.etag] A unique read-only string that * changes whenever the resource is updated. * @member {string} [backendHttpSettings.type] Type of the resource. diff --git a/lib/services/networkManagement2/lib/models/applicationGatewayBackendHealthPool.js b/lib/services/networkManagement2/lib/models/applicationGatewayBackendHealthPool.js index 15cdacf101..12e33bee6b 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewayBackendHealthPool.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewayBackendHealthPool.js @@ -27,8 +27,8 @@ class ApplicationGatewayBackendHealthPool { * @member {string} [backendAddressPool.provisioningState] Provisioning state * of the backend address pool resource. Possible values are: 'Updating', * 'Deleting', and 'Failed'. - * @member {string} [backendAddressPool.name] Resource that is unique within - * a resource group. This name can be used to access the resource. + * @member {string} [backendAddressPool.name] Name of the backend address + * pool that is unique within an Application Gateway. * @member {string} [backendAddressPool.etag] A unique read-only string that * changes whenever the resource is updated. * @member {string} [backendAddressPool.type] Type of the resource. diff --git a/lib/services/networkManagement2/lib/models/applicationGatewayBackendHttpSettings.js b/lib/services/networkManagement2/lib/models/applicationGatewayBackendHttpSettings.js index 5d294aaa9c..fe3cf2b152 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewayBackendHttpSettings.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewayBackendHttpSettings.js @@ -20,9 +20,10 @@ const models = require('./index'); class ApplicationGatewayBackendHttpSettings extends models['SubResource'] { /** * Create a ApplicationGatewayBackendHttpSettings. - * @member {number} [port] Port - * @member {string} [protocol] Protocol. Possible values include: 'Http', - * 'Https' + * @member {number} [port] The destination port on the backend. + * @member {string} [protocol] The protocol used to communicate with the + * backend. Possible values are 'Http' and 'Https'. Possible values include: + * 'Http', 'Https' * @member {string} [cookieBasedAffinity] Cookie based affinity. Possible * values include: 'Enabled', 'Disabled' * @member {number} [requestTimeout] Request timeout in seconds. Application @@ -52,8 +53,8 @@ class ApplicationGatewayBackendHttpSettings extends models['SubResource'] { * @member {string} [provisioningState] Provisioning state of the backend * http settings resource. Possible values are: 'Updating', 'Deleting', and * 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the backend http settings that is unique + * within an Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever * the resource is updated. * @member {string} [type] Type of the resource. diff --git a/lib/services/networkManagement2/lib/models/applicationGatewayFrontendIPConfiguration.js b/lib/services/networkManagement2/lib/models/applicationGatewayFrontendIPConfiguration.js index 36c3964d12..67aba664c9 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewayFrontendIPConfiguration.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewayFrontendIPConfiguration.js @@ -30,8 +30,8 @@ class ApplicationGatewayFrontendIPConfiguration extends models['SubResource'] { * @member {string} [publicIPAddress.id] Resource ID. * @member {string} [provisioningState] Provisioning state of the public IP * resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the frontend IP configuration that is + * unique within an Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever * the resource is updated. * @member {string} [type] Type of the resource. diff --git a/lib/services/networkManagement2/lib/models/applicationGatewayFrontendPort.js b/lib/services/networkManagement2/lib/models/applicationGatewayFrontendPort.js index 1eff4ee554..fcd3586a0b 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewayFrontendPort.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewayFrontendPort.js @@ -23,8 +23,8 @@ class ApplicationGatewayFrontendPort extends models['SubResource'] { * @member {number} [port] Frontend port * @member {string} [provisioningState] Provisioning state of the frontend * port resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the frontend port that is unique within an + * Application Gateway * @member {string} [etag] A unique read-only string that changes whenever * the resource is updated. * @member {string} [type] Type of the resource. diff --git a/lib/services/networkManagement2/lib/models/applicationGatewayHttpListener.js b/lib/services/networkManagement2/lib/models/applicationGatewayHttpListener.js index edd2db76d3..72b5481ad9 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewayHttpListener.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewayHttpListener.js @@ -26,8 +26,8 @@ class ApplicationGatewayHttpListener extends models['SubResource'] { * @member {object} [frontendPort] Frontend port resource of an application * gateway. * @member {string} [frontendPort.id] Resource ID. - * @member {string} [protocol] Protocol. Possible values include: 'Http', - * 'Https' + * @member {string} [protocol] Protocol of the HTTP listener. Possible values + * are 'Http' and 'Https'. Possible values include: 'Http', 'Https' * @member {string} [hostName] Host name of HTTP listener. * @member {object} [sslCertificate] SSL certificate resource of an * application gateway. @@ -37,8 +37,8 @@ class ApplicationGatewayHttpListener extends models['SubResource'] { * @member {string} [provisioningState] Provisioning state of the HTTP * listener resource. Possible values are: 'Updating', 'Deleting', and * 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the HTTP listener that is unique within an + * Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever * the resource is updated. * @member {string} [type] Type of the resource. diff --git a/lib/services/networkManagement2/lib/models/applicationGatewayIPConfiguration.js b/lib/services/networkManagement2/lib/models/applicationGatewayIPConfiguration.js index 6e170ed225..e8b43dce54 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewayIPConfiguration.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewayIPConfiguration.js @@ -27,8 +27,8 @@ class ApplicationGatewayIPConfiguration extends models['SubResource'] { * @member {string} [provisioningState] Provisioning state of the application * gateway subnet resource. Possible values are: 'Updating', 'Deleting', and * 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the IP configuration that is unique within + * an Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever * the resource is updated. * @member {string} [type] Type of the resource. diff --git a/lib/services/networkManagement2/lib/models/applicationGatewayPathRule.js b/lib/services/networkManagement2/lib/models/applicationGatewayPathRule.js index 7f52241d11..2d32927d50 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewayPathRule.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewayPathRule.js @@ -32,8 +32,8 @@ class ApplicationGatewayPathRule extends models['SubResource'] { * @member {string} [redirectConfiguration.id] Resource ID. * @member {string} [provisioningState] Path rule of URL path map resource. * Possible values are: 'Updating', 'Deleting', and 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the path rule that is unique within an + * Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever * the resource is updated. * @member {string} [type] Type of the resource. diff --git a/lib/services/networkManagement2/lib/models/applicationGatewayProbe.js b/lib/services/networkManagement2/lib/models/applicationGatewayProbe.js index 78e535c3b8..df581e90a0 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewayProbe.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewayProbe.js @@ -20,8 +20,8 @@ const models = require('./index'); class ApplicationGatewayProbe extends models['SubResource'] { /** * Create a ApplicationGatewayProbe. - * @member {string} [protocol] Protocol. Possible values include: 'Http', - * 'Https' + * @member {string} [protocol] The protocol used for the probe. Possible + * values are 'Http' and 'Https'. Possible values include: 'Http', 'Https' * @member {string} [host] Host name to send the probe to. * @member {string} [path] Relative path of probe. Valid path starts from * '/'. Probe is sent to ://: @@ -48,8 +48,8 @@ class ApplicationGatewayProbe extends models['SubResource'] { * @member {string} [provisioningState] Provisioning state of the backend * http settings resource. Possible values are: 'Updating', 'Deleting', and * 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the probe that is unique within an + * Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever * the resource is updated. * @member {string} [type] Type of the resource. diff --git a/lib/services/networkManagement2/lib/models/applicationGatewayRedirectConfiguration.js b/lib/services/networkManagement2/lib/models/applicationGatewayRedirectConfiguration.js index 9e1947b563..73285d6a03 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewayRedirectConfiguration.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewayRedirectConfiguration.js @@ -35,8 +35,8 @@ class ApplicationGatewayRedirectConfiguration extends models['SubResource'] { * @member {array} [urlPathMaps] Url path maps specifying default redirect * configuration. * @member {array} [pathRules] Path rules specifying redirect configuration. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the redirect configuration that is unique + * within an Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever * the resource is updated. * @member {string} [type] Type of the resource. diff --git a/lib/services/networkManagement2/lib/models/applicationGatewayRequestRoutingRule.js b/lib/services/networkManagement2/lib/models/applicationGatewayRequestRoutingRule.js index 22878d6912..50ee73657f 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewayRequestRoutingRule.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewayRequestRoutingRule.js @@ -25,8 +25,8 @@ class ApplicationGatewayRequestRoutingRule extends models['SubResource'] { * @member {object} [backendAddressPool] Backend address pool resource of the * application gateway. * @member {string} [backendAddressPool.id] Resource ID. - * @member {object} [backendHttpSettings] Frontend port resource of the - * application gateway. + * @member {object} [backendHttpSettings] Backend http settings resource of + * the application gateway. * @member {string} [backendHttpSettings.id] Resource ID. * @member {object} [httpListener] Http listener resource of the application * gateway. @@ -40,8 +40,8 @@ class ApplicationGatewayRequestRoutingRule extends models['SubResource'] { * @member {string} [provisioningState] Provisioning state of the request * routing rule resource. Possible values are: 'Updating', 'Deleting', and * 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the request routing rule that is unique + * within an Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever * the resource is updated. * @member {string} [type] Type of the resource. diff --git a/lib/services/networkManagement2/lib/models/applicationGatewaySku.js b/lib/services/networkManagement2/lib/models/applicationGatewaySku.js index 2bf5af52f6..7e76996b52 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewaySku.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewaySku.js @@ -19,9 +19,9 @@ class ApplicationGatewaySku { * Create a ApplicationGatewaySku. * @member {string} [name] Name of an application gateway SKU. Possible * values include: 'Standard_Small', 'Standard_Medium', 'Standard_Large', - * 'WAF_Medium', 'WAF_Large' + * 'WAF_Medium', 'WAF_Large', 'Standard_v2', 'WAF_v2' * @member {string} [tier] Tier of an application gateway. Possible values - * include: 'Standard', 'WAF' + * include: 'Standard', 'WAF', 'Standard_v2', 'WAF_v2' * @member {number} [capacity] Capacity (instance count) of an application * gateway. */ diff --git a/lib/services/networkManagement2/lib/models/applicationGatewaySslCertificate.js b/lib/services/networkManagement2/lib/models/applicationGatewaySslCertificate.js index 0c13a53284..7881235bf0 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewaySslCertificate.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewaySslCertificate.js @@ -29,8 +29,8 @@ class ApplicationGatewaySslCertificate extends models['SubResource'] { * @member {string} [provisioningState] Provisioning state of the SSL * certificate resource Possible values are: 'Updating', 'Deleting', and * 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the SSL certificate that is unique within + * an Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever * the resource is updated. * @member {string} [type] Type of the resource. diff --git a/lib/services/networkManagement2/lib/models/applicationGatewaySslPredefinedPolicy.js b/lib/services/networkManagement2/lib/models/applicationGatewaySslPredefinedPolicy.js index 8c522f4c52..7e979bed83 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewaySslPredefinedPolicy.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewaySslPredefinedPolicy.js @@ -20,7 +20,7 @@ const models = require('./index'); class ApplicationGatewaySslPredefinedPolicy extends models['SubResource'] { /** * Create a ApplicationGatewaySslPredefinedPolicy. - * @member {string} [name] Name of Ssl predefined policy. + * @member {string} [name] Name of the Ssl predefined policy. * @member {array} [cipherSuites] Ssl cipher suites to be enabled in the * specified order for application gateway. * @member {string} [minProtocolVersion] Minimum version of Ssl protocol to diff --git a/lib/services/networkManagement2/lib/models/applicationGatewayUrlPathMap.js b/lib/services/networkManagement2/lib/models/applicationGatewayUrlPathMap.js index c49cf43292..29032c22f2 100644 --- a/lib/services/networkManagement2/lib/models/applicationGatewayUrlPathMap.js +++ b/lib/services/networkManagement2/lib/models/applicationGatewayUrlPathMap.js @@ -34,8 +34,8 @@ class ApplicationGatewayUrlPathMap extends models['SubResource'] { * @member {string} [provisioningState] Provisioning state of the backend * http settings resource. Possible values are: 'Updating', 'Deleting', and * 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the URL path map that is unique within an + * Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever * the resource is updated. * @member {string} [type] Type of the resource. diff --git a/lib/services/networkManagement2/lib/models/azureFirewall.js b/lib/services/networkManagement2/lib/models/azureFirewall.js new file mode 100644 index 0000000000..977817bd58 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/azureFirewall.js @@ -0,0 +1,163 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const models = require('./index'); + +/** + * Azure Firewall resource + * + * @extends models['Resource'] + */ +class AzureFirewall extends models['Resource'] { + /** + * Create a AzureFirewall. + * @member {array} [applicationRuleCollections] Collection of application + * rule collections used by a Azure Firewall. + * @member {array} [networkRuleCollections] Collection of network rule + * collections used by a Azure Firewall. + * @member {array} [ipConfigurations] IP configuration of the Azure Firewall + * resource. + * @member {string} [provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * @member {string} [etag] Gets a unique read-only string that changes + * whenever the resource is updated. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of AzureFirewall + * + * @returns {object} metadata of AzureFirewall + * + */ + mapper() { + return { + required: false, + serializedName: 'AzureFirewall', + type: { + name: 'Composite', + className: 'AzureFirewall', + modelProperties: { + id: { + required: false, + serializedName: 'id', + type: { + name: 'String' + } + }, + name: { + required: false, + readOnly: true, + serializedName: 'name', + type: { + name: 'String' + } + }, + type: { + required: false, + readOnly: true, + serializedName: 'type', + type: { + name: 'String' + } + }, + location: { + required: false, + serializedName: 'location', + type: { + name: 'String' + } + }, + tags: { + required: false, + serializedName: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serializedName: 'StringElementType', + type: { + name: 'String' + } + } + } + }, + applicationRuleCollections: { + required: false, + serializedName: 'properties.applicationRuleCollections', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'AzureFirewallApplicationRuleCollectionElementType', + type: { + name: 'Composite', + className: 'AzureFirewallApplicationRuleCollection' + } + } + } + }, + networkRuleCollections: { + required: false, + serializedName: 'properties.networkRuleCollections', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'AzureFirewallNetworkRuleCollectionElementType', + type: { + name: 'Composite', + className: 'AzureFirewallNetworkRuleCollection' + } + } + } + }, + ipConfigurations: { + required: false, + serializedName: 'properties.ipConfigurations', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'AzureFirewallIPConfigurationElementType', + type: { + name: 'Composite', + className: 'AzureFirewallIPConfiguration' + } + } + } + }, + provisioningState: { + required: false, + serializedName: 'properties.provisioningState', + type: { + name: 'String' + } + }, + etag: { + required: false, + readOnly: true, + serializedName: 'etag', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = AzureFirewall; diff --git a/lib/services/networkManagement2/lib/models/azureFirewallApplicationRule.js b/lib/services/networkManagement2/lib/models/azureFirewallApplicationRule.js new file mode 100644 index 0000000000..309a13d64f --- /dev/null +++ b/lib/services/networkManagement2/lib/models/azureFirewallApplicationRule.js @@ -0,0 +1,109 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const models = require('./index'); + +/** + * Properties of an application rule. + * + */ +class AzureFirewallApplicationRule { + /** + * Create a AzureFirewallApplicationRule. + * @member {string} [name] Name of the application rule. + * @member {string} [description] Description of the rule. + * @member {array} [sourceAddresses] List of source IP addresses for this + * rule. + * @member {array} [protocols] Array of ApplicationRuleProtocols. + * @member {array} [targetUrls] List of URLs for this rule. + */ + constructor() { + } + + /** + * Defines the metadata of AzureFirewallApplicationRule + * + * @returns {object} metadata of AzureFirewallApplicationRule + * + */ + mapper() { + return { + required: false, + serializedName: 'AzureFirewallApplicationRule', + type: { + name: 'Composite', + className: 'AzureFirewallApplicationRule', + modelProperties: { + name: { + required: false, + serializedName: 'name', + type: { + name: 'String' + } + }, + description: { + required: false, + serializedName: 'description', + type: { + name: 'String' + } + }, + sourceAddresses: { + required: false, + serializedName: 'sourceAddresses', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'StringElementType', + type: { + name: 'String' + } + } + } + }, + protocols: { + required: false, + serializedName: 'protocols', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'AzureFirewallApplicationRuleProtocolElementType', + type: { + name: 'Composite', + className: 'AzureFirewallApplicationRuleProtocol' + } + } + } + }, + targetUrls: { + required: false, + serializedName: 'targetUrls', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'StringElementType', + type: { + name: 'String' + } + } + } + } + } + } + }; + } +} + +module.exports = AzureFirewallApplicationRule; diff --git a/lib/services/networkManagement2/lib/models/azureFirewallApplicationRuleCollection.js b/lib/services/networkManagement2/lib/models/azureFirewallApplicationRuleCollection.js new file mode 100644 index 0000000000..4e883e0ad6 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/azureFirewallApplicationRuleCollection.js @@ -0,0 +1,125 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const models = require('./index'); + +/** + * Application rule collection resource + * + * @extends models['SubResource'] + */ +class AzureFirewallApplicationRuleCollection extends models['SubResource'] { + /** + * Create a AzureFirewallApplicationRuleCollection. + * @member {number} [priority] Priority of the application rule collection + * resource. + * @member {object} [action] The action type of a rule collection + * @member {string} [action.type] The type of action. Possible values + * include: 'Allow', 'Deny' + * @member {array} [rules] Collection of rules used by a application rule + * collection. + * @member {string} [provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * @member {string} [name] Gets name of the resource that is unique within a + * resource group. This name can be used to access the resource. + * @member {string} [etag] Gets a unique read-only string that changes + * whenever the resource is updated. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of AzureFirewallApplicationRuleCollection + * + * @returns {object} metadata of AzureFirewallApplicationRuleCollection + * + */ + mapper() { + return { + required: false, + serializedName: 'AzureFirewallApplicationRuleCollection', + type: { + name: 'Composite', + className: 'AzureFirewallApplicationRuleCollection', + modelProperties: { + id: { + required: false, + serializedName: 'id', + type: { + name: 'String' + } + }, + priority: { + required: false, + serializedName: 'properties.priority', + constraints: { + InclusiveMaximum: 65000, + InclusiveMinimum: 100 + }, + type: { + name: 'Number' + } + }, + action: { + required: false, + serializedName: 'properties.action', + type: { + name: 'Composite', + className: 'AzureFirewallRCAction' + } + }, + rules: { + required: false, + serializedName: 'properties.rules', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'AzureFirewallApplicationRuleElementType', + type: { + name: 'Composite', + className: 'AzureFirewallApplicationRule' + } + } + } + }, + provisioningState: { + required: false, + serializedName: 'properties.provisioningState', + type: { + name: 'String' + } + }, + name: { + required: false, + serializedName: 'name', + type: { + name: 'String' + } + }, + etag: { + required: false, + readOnly: true, + serializedName: 'etag', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = AzureFirewallApplicationRuleCollection; diff --git a/lib/services/networkManagement2/lib/models/azureFirewallApplicationRuleProtocol.js b/lib/services/networkManagement2/lib/models/azureFirewallApplicationRuleProtocol.js new file mode 100644 index 0000000000..92347d2624 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/azureFirewallApplicationRuleProtocol.js @@ -0,0 +1,66 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +/** + * Properties of the application rule protocol. + * + */ +class AzureFirewallApplicationRuleProtocol { + /** + * Create a AzureFirewallApplicationRuleProtocol. + * @member {string} [protocolType] Protocol type. Possible values include: + * 'Http', 'Https' + * @member {number} [port] Port number for the protocol, cannot be greater + * than 64000. This field is optional. + */ + constructor() { + } + + /** + * Defines the metadata of AzureFirewallApplicationRuleProtocol + * + * @returns {object} metadata of AzureFirewallApplicationRuleProtocol + * + */ + mapper() { + return { + required: false, + serializedName: 'AzureFirewallApplicationRuleProtocol', + type: { + name: 'Composite', + className: 'AzureFirewallApplicationRuleProtocol', + modelProperties: { + protocolType: { + required: false, + serializedName: 'protocolType', + type: { + name: 'String' + } + }, + port: { + required: false, + serializedName: 'port', + constraints: { + InclusiveMaximum: 64000, + InclusiveMinimum: 0 + }, + type: { + name: 'Number' + } + } + } + } + }; + } +} + +module.exports = AzureFirewallApplicationRuleProtocol; diff --git a/lib/services/networkManagement2/lib/models/azureFirewallIPConfiguration.js b/lib/services/networkManagement2/lib/models/azureFirewallIPConfiguration.js new file mode 100644 index 0000000000..c3f6ec2326 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/azureFirewallIPConfiguration.js @@ -0,0 +1,125 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const models = require('./index'); + +/** + * IP configuration of an Azure Firewall. + * + * @extends models['SubResource'] + */ +class AzureFirewallIPConfiguration extends models['SubResource'] { + /** + * Create a AzureFirewallIPConfiguration. + * @member {string} [privateIPAddress] The Firewall Internal Load Balancer IP + * to be used as the next hop in User Defined Routes. + * @member {object} [subnet] Reference of the subnet resource. This resource + * must be named 'AzureFirewallSubnet'. + * @member {string} [subnet.id] Resource ID. + * @member {object} [internalPublicIpAddress] Reference of the PublicIP + * resource. This field is a mandatory input. + * @member {string} [internalPublicIpAddress.id] Resource ID. + * @member {object} [publicIPAddress] Reference of the PublicIP resource. + * This field is populated in the output. + * @member {string} [publicIPAddress.id] Resource ID. + * @member {string} [provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * @member {string} [name] Name of the resource that is unique within a + * resource group. This name can be used to access the resource. + * @member {string} [etag] A unique read-only string that changes whenever + * the resource is updated. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of AzureFirewallIPConfiguration + * + * @returns {object} metadata of AzureFirewallIPConfiguration + * + */ + mapper() { + return { + required: false, + serializedName: 'AzureFirewallIPConfiguration', + type: { + name: 'Composite', + className: 'AzureFirewallIPConfiguration', + modelProperties: { + id: { + required: false, + serializedName: 'id', + type: { + name: 'String' + } + }, + privateIPAddress: { + required: false, + serializedName: 'properties.privateIPAddress', + type: { + name: 'String' + } + }, + subnet: { + required: false, + serializedName: 'properties.subnet', + type: { + name: 'Composite', + className: 'SubResource' + } + }, + internalPublicIpAddress: { + required: false, + serializedName: 'properties.internalPublicIpAddress', + type: { + name: 'Composite', + className: 'SubResource' + } + }, + publicIPAddress: { + required: false, + serializedName: 'properties.publicIPAddress', + type: { + name: 'Composite', + className: 'SubResource' + } + }, + provisioningState: { + required: false, + serializedName: 'properties.provisioningState', + type: { + name: 'String' + } + }, + name: { + required: false, + serializedName: 'name', + type: { + name: 'String' + } + }, + etag: { + required: false, + serializedName: 'etag', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = AzureFirewallIPConfiguration; diff --git a/lib/services/networkManagement2/lib/models/azureFirewallListResult.js b/lib/services/networkManagement2/lib/models/azureFirewallListResult.js new file mode 100644 index 0000000000..fb1febc884 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/azureFirewallListResult.js @@ -0,0 +1,67 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +/** + * Response for ListAzureFirewalls API service call. + */ +class AzureFirewallListResult extends Array { + /** + * Create a AzureFirewallListResult. + * @member {string} [nextLink] URL to get the next set of results. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of AzureFirewallListResult + * + * @returns {object} metadata of AzureFirewallListResult + * + */ + mapper() { + return { + required: false, + serializedName: 'AzureFirewallListResult', + type: { + name: 'Composite', + className: 'AzureFirewallListResult', + modelProperties: { + value: { + required: false, + serializedName: '', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'AzureFirewallElementType', + type: { + name: 'Composite', + className: 'AzureFirewall' + } + } + } + }, + nextLink: { + required: false, + serializedName: 'nextLink', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = AzureFirewallListResult; diff --git a/lib/services/networkManagement2/lib/models/azureFirewallNetworkRule.js b/lib/services/networkManagement2/lib/models/azureFirewallNetworkRule.js new file mode 100644 index 0000000000..0608539f82 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/azureFirewallNetworkRule.js @@ -0,0 +1,121 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +/** + * Properties of the network rule. + * + */ +class AzureFirewallNetworkRule { + /** + * Create a AzureFirewallNetworkRule. + * @member {string} [name] Name of the network rule. + * @member {string} [description] Description of the rule. + * @member {array} [protocols] Array of AzureFirewallNetworkRuleProtocols. + * @member {array} [sourceAddresses] List of source IP addresses for this + * rule. + * @member {array} [destinationAddresses] List of destination IP addresses. + * @member {array} [destinationPorts] List of destination ports. + */ + constructor() { + } + + /** + * Defines the metadata of AzureFirewallNetworkRule + * + * @returns {object} metadata of AzureFirewallNetworkRule + * + */ + mapper() { + return { + required: false, + serializedName: 'AzureFirewallNetworkRule', + type: { + name: 'Composite', + className: 'AzureFirewallNetworkRule', + modelProperties: { + name: { + required: false, + serializedName: 'name', + type: { + name: 'String' + } + }, + description: { + required: false, + serializedName: 'description', + type: { + name: 'String' + } + }, + protocols: { + required: false, + serializedName: 'protocols', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'StringElementType', + type: { + name: 'String' + } + } + } + }, + sourceAddresses: { + required: false, + serializedName: 'sourceAddresses', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'StringElementType', + type: { + name: 'String' + } + } + } + }, + destinationAddresses: { + required: false, + serializedName: 'destinationAddresses', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'StringElementType', + type: { + name: 'String' + } + } + } + }, + destinationPorts: { + required: false, + serializedName: 'destinationPorts', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'StringElementType', + type: { + name: 'String' + } + } + } + } + } + } + }; + } +} + +module.exports = AzureFirewallNetworkRule; diff --git a/lib/services/networkManagement2/lib/models/azureFirewallNetworkRuleCollection.js b/lib/services/networkManagement2/lib/models/azureFirewallNetworkRuleCollection.js new file mode 100644 index 0000000000..7a073e2e1f --- /dev/null +++ b/lib/services/networkManagement2/lib/models/azureFirewallNetworkRuleCollection.js @@ -0,0 +1,125 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const models = require('./index'); + +/** + * Network rule collection resource + * + * @extends models['SubResource'] + */ +class AzureFirewallNetworkRuleCollection extends models['SubResource'] { + /** + * Create a AzureFirewallNetworkRuleCollection. + * @member {number} [priority] Priority of the network rule collection + * resource. + * @member {object} [action] The action type of a rule collection + * @member {string} [action.type] The type of action. Possible values + * include: 'Allow', 'Deny' + * @member {array} [rules] Collection of rules used by a network rule + * collection. + * @member {string} [provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * @member {string} [name] Gets name of the resource that is unique within a + * resource group. This name can be used to access the resource. + * @member {string} [etag] Gets a unique read-only string that changes + * whenever the resource is updated. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of AzureFirewallNetworkRuleCollection + * + * @returns {object} metadata of AzureFirewallNetworkRuleCollection + * + */ + mapper() { + return { + required: false, + serializedName: 'AzureFirewallNetworkRuleCollection', + type: { + name: 'Composite', + className: 'AzureFirewallNetworkRuleCollection', + modelProperties: { + id: { + required: false, + serializedName: 'id', + type: { + name: 'String' + } + }, + priority: { + required: false, + serializedName: 'properties.priority', + constraints: { + InclusiveMaximum: 65000, + InclusiveMinimum: 100 + }, + type: { + name: 'Number' + } + }, + action: { + required: false, + serializedName: 'properties.action', + type: { + name: 'Composite', + className: 'AzureFirewallRCAction' + } + }, + rules: { + required: false, + serializedName: 'properties.rules', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'AzureFirewallNetworkRuleElementType', + type: { + name: 'Composite', + className: 'AzureFirewallNetworkRule' + } + } + } + }, + provisioningState: { + required: false, + serializedName: 'properties.provisioningState', + type: { + name: 'String' + } + }, + name: { + required: false, + serializedName: 'name', + type: { + name: 'String' + } + }, + etag: { + required: false, + readOnly: true, + serializedName: 'etag', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = AzureFirewallNetworkRuleCollection; diff --git a/lib/services/networkManagement2/lib/models/azureFirewallRCAction.js b/lib/services/networkManagement2/lib/models/azureFirewallRCAction.js new file mode 100644 index 0000000000..24277357c5 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/azureFirewallRCAction.js @@ -0,0 +1,53 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +/** + * Properties of the AzureFirewallRCAction. + * + */ +class AzureFirewallRCAction { + /** + * Create a AzureFirewallRCAction. + * @member {string} [type] The type of action. Possible values include: + * 'Allow', 'Deny' + */ + constructor() { + } + + /** + * Defines the metadata of AzureFirewallRCAction + * + * @returns {object} metadata of AzureFirewallRCAction + * + */ + mapper() { + return { + required: false, + serializedName: 'AzureFirewallRCAction', + type: { + name: 'Composite', + className: 'AzureFirewallRCAction', + modelProperties: { + type: { + required: false, + serializedName: 'type', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = AzureFirewallRCAction; diff --git a/lib/services/networkManagement2/lib/models/connectionSharedKey.js b/lib/services/networkManagement2/lib/models/connectionSharedKey.js index a74b9eeeca..ad71412918 100644 --- a/lib/services/networkManagement2/lib/models/connectionSharedKey.js +++ b/lib/services/networkManagement2/lib/models/connectionSharedKey.js @@ -10,16 +10,20 @@ 'use strict'; +const models = require('./index'); + /** * Response for GetConnectionSharedKey API service call * + * @extends models['SubResource'] */ -class ConnectionSharedKey { +class ConnectionSharedKey extends models['SubResource'] { /** * Create a ConnectionSharedKey. * @member {string} value The virtual network connection shared key value. */ constructor() { + super(); } /** @@ -36,6 +40,13 @@ class ConnectionSharedKey { name: 'Composite', className: 'ConnectionSharedKey', modelProperties: { + id: { + required: false, + serializedName: 'id', + type: { + name: 'String' + } + }, value: { required: true, serializedName: 'value', diff --git a/lib/services/networkManagement2/lib/models/ddosProtectionPlan.js b/lib/services/networkManagement2/lib/models/ddosProtectionPlan.js index d246e24d1f..562069dfc6 100644 --- a/lib/services/networkManagement2/lib/models/ddosProtectionPlan.js +++ b/lib/services/networkManagement2/lib/models/ddosProtectionPlan.js @@ -15,11 +15,16 @@ const models = require('./index'); /** * A DDoS protection plan in a resource group. * - * @extends models['Resource'] + * @extends models['BaseResource'] */ -class DdosProtectionPlan extends models['Resource'] { +class DdosProtectionPlan extends models['BaseResource'] { /** * Create a DdosProtectionPlan. + * @member {string} [id] Resource ID. + * @member {string} [name] Resource name. + * @member {string} [type] Resource type. + * @member {string} [location] Resource location. + * @member {object} [tags] Resource tags. * @member {string} [resourceGuid] The resource GUID property of the DDoS * protection plan resource. It uniquely identifies the resource, even if the * user changes its name or migrate the resource across subscriptions or @@ -52,6 +57,7 @@ class DdosProtectionPlan extends models['Resource'] { modelProperties: { id: { required: false, + readOnly: true, serializedName: 'id', type: { name: 'String' diff --git a/lib/services/networkManagement2/lib/models/deviceProperties.js b/lib/services/networkManagement2/lib/models/deviceProperties.js new file mode 100644 index 0000000000..c9652c5cd9 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/deviceProperties.js @@ -0,0 +1,68 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +/** + * List of properties of the device. + * + */ +class DeviceProperties { + /** + * Create a DeviceProperties. + * @member {string} [deviceVendor] Name of the device Vendor. + * @member {string} [deviceModel] Model of the device. + * @member {number} [linkSpeedInMbps] Link speed. + */ + constructor() { + } + + /** + * Defines the metadata of DeviceProperties + * + * @returns {object} metadata of DeviceProperties + * + */ + mapper() { + return { + required: false, + serializedName: 'DeviceProperties', + type: { + name: 'Composite', + className: 'DeviceProperties', + modelProperties: { + deviceVendor: { + required: false, + serializedName: 'deviceVendor', + type: { + name: 'String' + } + }, + deviceModel: { + required: false, + serializedName: 'deviceModel', + type: { + name: 'String' + } + }, + linkSpeedInMbps: { + required: false, + serializedName: 'linkSpeedInMbps', + type: { + name: 'Number' + } + } + } + } + }; + } +} + +module.exports = DeviceProperties; diff --git a/lib/services/networkManagement2/lib/models/expressRouteCircuitArpTable.js b/lib/services/networkManagement2/lib/models/expressRouteCircuitArpTable.js index 5eb3544870..4fc37d0452 100644 --- a/lib/services/networkManagement2/lib/models/expressRouteCircuitArpTable.js +++ b/lib/services/networkManagement2/lib/models/expressRouteCircuitArpTable.js @@ -17,8 +17,8 @@ class ExpressRouteCircuitArpTable { /** * Create a ExpressRouteCircuitArpTable. - * @member {number} [age] Age - * @member {string} [interfaceProperty] Interface + * @member {number} [age] Entry age in minutes + * @member {string} [interfaceProperty] Interface address * @member {string} [ipAddress] The IP address. * @member {string} [macAddress] The MAC address. */ diff --git a/lib/services/networkManagement2/lib/models/expressRouteCircuitRoutesTable.js b/lib/services/networkManagement2/lib/models/expressRouteCircuitRoutesTable.js index d3a4e5f351..aca3c55463 100644 --- a/lib/services/networkManagement2/lib/models/expressRouteCircuitRoutesTable.js +++ b/lib/services/networkManagement2/lib/models/expressRouteCircuitRoutesTable.js @@ -17,11 +17,13 @@ class ExpressRouteCircuitRoutesTable { /** * Create a ExpressRouteCircuitRoutesTable. - * @member {string} [network] network - * @member {string} [nextHop] nextHop - * @member {string} [locPrf] locPrf - * @member {number} [weight] weight. - * @member {string} [path] path + * @member {string} [network] IP address of a network entity + * @member {string} [nextHop] NextHop address + * @member {string} [locPrf] Local preference value as set with the set + * local-preference route-map configuration command + * @member {number} [weight] Route Weight. + * @member {string} [path] Autonomous system paths to the destination + * network. */ constructor() { } diff --git a/lib/services/networkManagement2/lib/models/expressRouteCircuitRoutesTableSummary.js b/lib/services/networkManagement2/lib/models/expressRouteCircuitRoutesTableSummary.js index 9faca22420..a7c16eec66 100644 --- a/lib/services/networkManagement2/lib/models/expressRouteCircuitRoutesTableSummary.js +++ b/lib/services/networkManagement2/lib/models/expressRouteCircuitRoutesTableSummary.js @@ -17,7 +17,7 @@ class ExpressRouteCircuitRoutesTableSummary { /** * Create a ExpressRouteCircuitRoutesTableSummary. - * @member {string} [neighbor] Neighbor + * @member {string} [neighbor] IP address of the neighbor. * @member {number} [v] BGP version number spoken to the neighbor. * @member {number} [as] Autonomous system number. * @member {string} [upDown] The length of time that the BGP session has been diff --git a/lib/services/networkManagement2/lib/models/expressRouteCrossConnection.js b/lib/services/networkManagement2/lib/models/expressRouteCrossConnection.js index 21e3b6f300..180429e70e 100644 --- a/lib/services/networkManagement2/lib/models/expressRouteCrossConnection.js +++ b/lib/services/networkManagement2/lib/models/expressRouteCrossConnection.js @@ -130,7 +130,6 @@ class ExpressRouteCrossConnection extends models['Resource'] { }, peeringLocation: { required: false, - readOnly: true, serializedName: 'properties.peeringLocation', type: { name: 'String' @@ -138,7 +137,6 @@ class ExpressRouteCrossConnection extends models['Resource'] { }, bandwidthInMbps: { required: false, - readOnly: true, serializedName: 'properties.bandwidthInMbps', type: { name: 'Number' @@ -146,7 +144,6 @@ class ExpressRouteCrossConnection extends models['Resource'] { }, expressRouteCircuit: { required: false, - readOnly: true, serializedName: 'properties.expressRouteCircuit', type: { name: 'Composite', diff --git a/lib/services/networkManagement2/lib/models/expressRouteCrossConnectionPeering.js b/lib/services/networkManagement2/lib/models/expressRouteCrossConnectionPeering.js index 31abfbf098..1fe2499774 100644 --- a/lib/services/networkManagement2/lib/models/expressRouteCrossConnectionPeering.js +++ b/lib/services/networkManagement2/lib/models/expressRouteCrossConnectionPeering.js @@ -221,7 +221,6 @@ class ExpressRouteCrossConnectionPeering extends models['SubResource'] { }, gatewayManagerEtag: { required: false, - readOnly: true, serializedName: 'properties.gatewayManagerEtag', type: { name: 'String' diff --git a/lib/services/networkManagement2/lib/models/flowLogInformation.js b/lib/services/networkManagement2/lib/models/flowLogInformation.js index 9efb176e4e..2ec3d71a8e 100644 --- a/lib/services/networkManagement2/lib/models/flowLogInformation.js +++ b/lib/services/networkManagement2/lib/models/flowLogInformation.js @@ -13,14 +13,15 @@ const models = require('./index'); /** - * Information on the configuration of flow log. + * Information on the configuration of flow log and traffic analytics + * (optional) . * */ class FlowLogInformation { /** * Create a FlowLogInformation. * @member {string} targetResourceId The ID of the resource to configure for - * flow logging. + * flow log and traffic analytics (optional) . * @member {string} storageId ID of the storage account which is used to * store the flow log. * @member {boolean} enabled Flag to enable/disable flow logging. @@ -29,6 +30,21 @@ class FlowLogInformation { * records. * @member {boolean} [retentionPolicy.enabled] Flag to enable/disable * retention. + * @member {object} [flowAnalyticsConfiguration] + * @member {object} + * [flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration] + * @member {boolean} + * [flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.enabled] + * Flag to enable/disable traffic analytics. + * @member {string} + * [flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceId] + * The resource guid of the attached workspace + * @member {string} + * [flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceRegion] + * The location of the attached workspace + * @member {string} + * [flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceResourceId] + * Resource Id of the attached workspace */ constructor() { } @@ -75,6 +91,14 @@ class FlowLogInformation { name: 'Composite', className: 'RetentionPolicyParameters' } + }, + flowAnalyticsConfiguration: { + required: false, + serializedName: 'flowAnalyticsConfiguration', + type: { + name: 'Composite', + className: 'TrafficAnalyticsProperties' + } } } } diff --git a/lib/services/networkManagement2/lib/models/flowLogStatusParameters.js b/lib/services/networkManagement2/lib/models/flowLogStatusParameters.js index 0f9221918d..f3ebc41d6e 100644 --- a/lib/services/networkManagement2/lib/models/flowLogStatusParameters.js +++ b/lib/services/networkManagement2/lib/models/flowLogStatusParameters.js @@ -11,14 +11,15 @@ 'use strict'; /** - * Parameters that define a resource to query flow log status. + * Parameters that define a resource to query flow log and traffic analytics + * (optional) status. * */ class FlowLogStatusParameters { /** * Create a FlowLogStatusParameters. * @member {string} targetResourceId The target resource where getting the - * flow logging status. + * flow log and traffic analytics (optional) status. */ constructor() { } diff --git a/lib/services/networkManagement2/lib/models/getVpnSitesConfigurationRequest.js b/lib/services/networkManagement2/lib/models/getVpnSitesConfigurationRequest.js new file mode 100644 index 0000000000..43fd740986 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/getVpnSitesConfigurationRequest.js @@ -0,0 +1,72 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const models = require('./index'); + +/** + * List of Vpn-Sites + * + */ +class GetVpnSitesConfigurationRequest { + /** + * Create a GetVpnSitesConfigurationRequest. + * @member {array} [vpnSites] List of resource-ids of the vpn-sites for which + * config is to be downloaded. + * @member {string} [outputBlobSasUrl] The sas-url to download the + * configurations for vpn-sites + */ + constructor() { + } + + /** + * Defines the metadata of GetVpnSitesConfigurationRequest + * + * @returns {object} metadata of GetVpnSitesConfigurationRequest + * + */ + mapper() { + return { + required: false, + serializedName: 'GetVpnSitesConfigurationRequest', + type: { + name: 'Composite', + className: 'GetVpnSitesConfigurationRequest', + modelProperties: { + vpnSites: { + required: false, + serializedName: 'vpnSites', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'SubResourceElementType', + type: { + name: 'Composite', + className: 'SubResource' + } + } + } + }, + outputBlobSasUrl: { + required: false, + serializedName: 'outputBlobSasUrl', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = GetVpnSitesConfigurationRequest; diff --git a/lib/services/networkManagement2/lib/models/hubVirtualNetworkConnection.js b/lib/services/networkManagement2/lib/models/hubVirtualNetworkConnection.js new file mode 100644 index 0000000000..b534f34173 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/hubVirtualNetworkConnection.js @@ -0,0 +1,141 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const models = require('./index'); + +/** + * HubVirtualNetworkConnection Resource. + * + * @extends models['Resource'] + */ +class HubVirtualNetworkConnection extends models['Resource'] { + /** + * Create a HubVirtualNetworkConnection. + * @member {object} [remoteVirtualNetwork] Reference to the remote virtual + * network. + * @member {string} [remoteVirtualNetwork.id] Resource ID. + * @member {boolean} [allowHubToRemoteVnetTransit] VirtualHub to RemoteVnet + * transit to enabled or not. + * @member {boolean} [allowRemoteVnetToUseHubVnetGateways] Allow RemoteVnet + * to use Virtual Hub's gateways. + * @member {string} [provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * @member {string} [etag] Gets a unique read-only string that changes + * whenever the resource is updated. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of HubVirtualNetworkConnection + * + * @returns {object} metadata of HubVirtualNetworkConnection + * + */ + mapper() { + return { + required: false, + serializedName: 'HubVirtualNetworkConnection', + type: { + name: 'Composite', + className: 'HubVirtualNetworkConnection', + modelProperties: { + id: { + required: false, + serializedName: 'id', + type: { + name: 'String' + } + }, + name: { + required: false, + readOnly: true, + serializedName: 'name', + type: { + name: 'String' + } + }, + type: { + required: false, + readOnly: true, + serializedName: 'type', + type: { + name: 'String' + } + }, + location: { + required: false, + serializedName: 'location', + type: { + name: 'String' + } + }, + tags: { + required: false, + serializedName: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serializedName: 'StringElementType', + type: { + name: 'String' + } + } + } + }, + remoteVirtualNetwork: { + required: false, + serializedName: 'properties.remoteVirtualNetwork', + type: { + name: 'Composite', + className: 'SubResource' + } + }, + allowHubToRemoteVnetTransit: { + required: false, + serializedName: 'properties.allowHubToRemoteVnetTransit', + type: { + name: 'Boolean' + } + }, + allowRemoteVnetToUseHubVnetGateways: { + required: false, + serializedName: 'properties.allowRemoteVnetToUseHubVnetGateways', + type: { + name: 'Boolean' + } + }, + provisioningState: { + required: false, + serializedName: 'properties.provisioningState', + type: { + name: 'String' + } + }, + etag: { + required: false, + readOnly: true, + serializedName: 'etag', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = HubVirtualNetworkConnection; diff --git a/lib/services/networkManagement2/lib/models/index.d.ts b/lib/services/networkManagement2/lib/models/index.d.ts index e620b9e1f6..dc2fde51e5 100644 --- a/lib/services/networkManagement2/lib/models/index.d.ts +++ b/lib/services/networkManagement2/lib/models/index.d.ts @@ -28,6 +28,214 @@ export interface SubResource extends BaseResource { id?: string; } +/** + * @class + * Initializes a new instance of the AzureFirewallIPConfiguration class. + * @constructor + * IP configuration of an Azure Firewall. + * + * @member {string} [privateIPAddress] The Firewall Internal Load Balancer IP + * to be used as the next hop in User Defined Routes. + * @member {object} [subnet] Reference of the subnet resource. This resource + * must be named 'AzureFirewallSubnet'. + * @member {string} [subnet.id] Resource ID. + * @member {object} [internalPublicIpAddress] Reference of the PublicIP + * resource. This field is a mandatory input. + * @member {string} [internalPublicIpAddress.id] Resource ID. + * @member {object} [publicIPAddress] Reference of the PublicIP resource. This + * field is populated in the output. + * @member {string} [publicIPAddress.id] Resource ID. + * @member {string} [provisioningState] The provisioning state of the resource. + * Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed' + * @member {string} [name] Name of the resource that is unique within a + * resource group. This name can be used to access the resource. + * @member {string} [etag] A unique read-only string that changes whenever the + * resource is updated. + */ +export interface AzureFirewallIPConfiguration extends SubResource { + privateIPAddress?: string; + subnet?: SubResource; + internalPublicIpAddress?: SubResource; + publicIPAddress?: SubResource; + provisioningState?: string; + name?: string; + etag?: string; +} + +/** + * @class + * Initializes a new instance of the AzureFirewallRCAction class. + * @constructor + * Properties of the AzureFirewallRCAction. + * + * @member {string} [type] The type of action. Possible values include: + * 'Allow', 'Deny' + */ +export interface AzureFirewallRCAction { + type?: string; +} + +/** + * @class + * Initializes a new instance of the AzureFirewallApplicationRuleProtocol class. + * @constructor + * Properties of the application rule protocol. + * + * @member {string} [protocolType] Protocol type. Possible values include: + * 'Http', 'Https' + * @member {number} [port] Port number for the protocol, cannot be greater than + * 64000. This field is optional. + */ +export interface AzureFirewallApplicationRuleProtocol { + protocolType?: string; + port?: number; +} + +/** + * @class + * Initializes a new instance of the AzureFirewallApplicationRule class. + * @constructor + * Properties of an application rule. + * + * @member {string} [name] Name of the application rule. + * @member {string} [description] Description of the rule. + * @member {array} [sourceAddresses] List of source IP addresses for this rule. + * @member {array} [protocols] Array of ApplicationRuleProtocols. + * @member {array} [targetUrls] List of URLs for this rule. + */ +export interface AzureFirewallApplicationRule { + name?: string; + description?: string; + sourceAddresses?: string[]; + protocols?: AzureFirewallApplicationRuleProtocol[]; + targetUrls?: string[]; +} + +/** + * @class + * Initializes a new instance of the AzureFirewallApplicationRuleCollection class. + * @constructor + * Application rule collection resource + * + * @member {number} [priority] Priority of the application rule collection + * resource. + * @member {object} [action] The action type of a rule collection + * @member {string} [action.type] The type of action. Possible values include: + * 'Allow', 'Deny' + * @member {array} [rules] Collection of rules used by a application rule + * collection. + * @member {string} [provisioningState] The provisioning state of the resource. + * Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed' + * @member {string} [name] Gets name of the resource that is unique within a + * resource group. This name can be used to access the resource. + * @member {string} [etag] Gets a unique read-only string that changes whenever + * the resource is updated. + */ +export interface AzureFirewallApplicationRuleCollection extends SubResource { + priority?: number; + action?: AzureFirewallRCAction; + rules?: AzureFirewallApplicationRule[]; + provisioningState?: string; + name?: string; + readonly etag?: string; +} + +/** + * @class + * Initializes a new instance of the AzureFirewallNetworkRule class. + * @constructor + * Properties of the network rule. + * + * @member {string} [name] Name of the network rule. + * @member {string} [description] Description of the rule. + * @member {array} [protocols] Array of AzureFirewallNetworkRuleProtocols. + * @member {array} [sourceAddresses] List of source IP addresses for this rule. + * @member {array} [destinationAddresses] List of destination IP addresses. + * @member {array} [destinationPorts] List of destination ports. + */ +export interface AzureFirewallNetworkRule { + name?: string; + description?: string; + protocols?: string[]; + sourceAddresses?: string[]; + destinationAddresses?: string[]; + destinationPorts?: string[]; +} + +/** + * @class + * Initializes a new instance of the AzureFirewallNetworkRuleCollection class. + * @constructor + * Network rule collection resource + * + * @member {number} [priority] Priority of the network rule collection + * resource. + * @member {object} [action] The action type of a rule collection + * @member {string} [action.type] The type of action. Possible values include: + * 'Allow', 'Deny' + * @member {array} [rules] Collection of rules used by a network rule + * collection. + * @member {string} [provisioningState] The provisioning state of the resource. + * Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed' + * @member {string} [name] Gets name of the resource that is unique within a + * resource group. This name can be used to access the resource. + * @member {string} [etag] Gets a unique read-only string that changes whenever + * the resource is updated. + */ +export interface AzureFirewallNetworkRuleCollection extends SubResource { + priority?: number; + action?: AzureFirewallRCAction; + rules?: AzureFirewallNetworkRule[]; + provisioningState?: string; + name?: string; + readonly etag?: string; +} + +/** + * @class + * Initializes a new instance of the Resource class. + * @constructor + * Common resource representation. + * + * @member {string} [id] Resource ID. + * @member {string} [name] Resource name. + * @member {string} [type] Resource type. + * @member {string} [location] Resource location. + * @member {object} [tags] Resource tags. + */ +export interface Resource extends BaseResource { + id?: string; + readonly name?: string; + readonly type?: string; + location?: string; + tags?: { [propertyName: string]: string }; +} + +/** + * @class + * Initializes a new instance of the AzureFirewall class. + * @constructor + * Azure Firewall resource + * + * @member {array} [applicationRuleCollections] Collection of application rule + * collections used by a Azure Firewall. + * @member {array} [networkRuleCollections] Collection of network rule + * collections used by a Azure Firewall. + * @member {array} [ipConfigurations] IP configuration of the Azure Firewall + * resource. + * @member {string} [provisioningState] The provisioning state of the resource. + * Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed' + * @member {string} [etag] Gets a unique read-only string that changes whenever + * the resource is updated. + */ +export interface AzureFirewall extends Resource { + applicationRuleCollections?: AzureFirewallApplicationRuleCollection[]; + networkRuleCollections?: AzureFirewallNetworkRuleCollection[]; + ipConfigurations?: AzureFirewallIPConfiguration[]; + provisioningState?: string; + readonly etag?: string; +} + /** * @class * Initializes a new instance of the BackendAddressPool class. @@ -332,26 +540,6 @@ export interface InboundNatRule extends SubResource { etag?: string; } -/** - * @class - * Initializes a new instance of the Resource class. - * @constructor - * Common resource representation. - * - * @member {string} [id] Resource ID. - * @member {string} [name] Resource name. - * @member {string} [type] Resource type. - * @member {string} [location] Resource location. - * @member {object} [tags] Resource tags. - */ -export interface Resource extends BaseResource { - id?: string; - readonly name?: string; - readonly type?: string; - location?: string; - tags?: { [propertyName: string]: string }; -} - /** * @class * Initializes a new instance of the ApplicationSecurityGroup class. @@ -1267,8 +1455,8 @@ export interface ApplicationGatewayBackendAddress { * @member {string} [provisioningState] Provisioning state of the backend * address pool resource. Possible values are: 'Updating', 'Deleting', and * 'Failed'. - * @member {string} [name] Resource that is unique within a resource group. - * This name can be used to access the resource. + * @member {string} [name] Name of the backend address pool that is unique + * within an Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever the * resource is updated. * @member {string} [type] Type of the resource. @@ -1305,9 +1493,10 @@ export interface ApplicationGatewayConnectionDraining { * @constructor * Backend address pool settings of an application gateway. * - * @member {number} [port] Port - * @member {string} [protocol] Protocol. Possible values include: 'Http', - * 'Https' + * @member {number} [port] The destination port on the backend. + * @member {string} [protocol] The protocol used to communicate with the + * backend. Possible values are 'Http' and 'Https'. Possible values include: + * 'Http', 'Https' * @member {string} [cookieBasedAffinity] Cookie based affinity. Possible * values include: 'Enabled', 'Disabled' * @member {number} [requestTimeout] Request timeout in seconds. Application @@ -1337,8 +1526,8 @@ export interface ApplicationGatewayConnectionDraining { * @member {string} [provisioningState] Provisioning state of the backend http * settings resource. Possible values are: 'Updating', 'Deleting', and * 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the backend http settings that is unique + * within an Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever the * resource is updated. * @member {string} [type] Type of the resource. @@ -1604,9 +1793,11 @@ export interface ApplicationGatewayBackendHealthServer { * * @member {object} [backendHttpSettings] Reference of an * ApplicationGatewayBackendHttpSettings resource. - * @member {number} [backendHttpSettings.port] Port - * @member {string} [backendHttpSettings.protocol] Protocol. Possible values - * include: 'Http', 'Https' + * @member {number} [backendHttpSettings.port] The destination port on the + * backend. + * @member {string} [backendHttpSettings.protocol] The protocol used to + * communicate with the backend. Possible values are 'Http' and 'Https'. + * Possible values include: 'Http', 'Https' * @member {string} [backendHttpSettings.cookieBasedAffinity] Cookie based * affinity. Possible values include: 'Enabled', 'Disabled' * @member {number} [backendHttpSettings.requestTimeout] Request timeout in @@ -1640,9 +1831,8 @@ export interface ApplicationGatewayBackendHealthServer { * @member {string} [backendHttpSettings.provisioningState] Provisioning state * of the backend http settings resource. Possible values are: 'Updating', * 'Deleting', and 'Failed'. - * @member {string} [backendHttpSettings.name] Name of the resource that is - * unique within a resource group. This name can be used to access the - * resource. + * @member {string} [backendHttpSettings.name] Name of the backend http + * settings that is unique within an Application Gateway. * @member {string} [backendHttpSettings.etag] A unique read-only string that * changes whenever the resource is updated. * @member {string} [backendHttpSettings.type] Type of the resource. @@ -1668,8 +1858,8 @@ export interface ApplicationGatewayBackendHealthHttpSettings { * @member {string} [backendAddressPool.provisioningState] Provisioning state * of the backend address pool resource. Possible values are: 'Updating', * 'Deleting', and 'Failed'. - * @member {string} [backendAddressPool.name] Resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [backendAddressPool.name] Name of the backend address pool + * that is unique within an Application Gateway. * @member {string} [backendAddressPool.etag] A unique read-only string that * changes whenever the resource is updated. * @member {string} [backendAddressPool.type] Type of the resource. @@ -1701,9 +1891,9 @@ export interface ApplicationGatewayBackendHealth { * * @member {string} [name] Name of an application gateway SKU. Possible values * include: 'Standard_Small', 'Standard_Medium', 'Standard_Large', - * 'WAF_Medium', 'WAF_Large' + * 'WAF_Medium', 'WAF_Large', 'Standard_v2', 'WAF_v2' * @member {string} [tier] Tier of an application gateway. Possible values - * include: 'Standard', 'WAF' + * include: 'Standard', 'WAF', 'Standard_v2', 'WAF_v2' * @member {number} [capacity] Capacity (instance count) of an application * gateway. */ @@ -1753,8 +1943,8 @@ export interface ApplicationGatewaySslPolicy { * @member {string} [provisioningState] Provisioning state of the application * gateway subnet resource. Possible values are: 'Updating', 'Deleting', and * 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the IP configuration that is unique within + * an Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever the * resource is updated. * @member {string} [type] Type of the resource. @@ -1777,8 +1967,8 @@ export interface ApplicationGatewayIPConfiguration extends SubResource { * @member {string} [provisioningState] Provisioning state of the * authentication certificate resource. Possible values are: 'Updating', * 'Deleting', and 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the authentication certificate that is + * unique within an Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever the * resource is updated. * @member {string} [type] Type of the resource. @@ -1806,8 +1996,8 @@ export interface ApplicationGatewayAuthenticationCertificate extends SubResource * @member {string} [provisioningState] Provisioning state of the SSL * certificate resource Possible values are: 'Updating', 'Deleting', and * 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the SSL certificate that is unique within an + * Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever the * resource is updated. * @member {string} [type] Type of the resource. @@ -1838,8 +2028,8 @@ export interface ApplicationGatewaySslCertificate extends SubResource { * @member {string} [publicIPAddress.id] Resource ID. * @member {string} [provisioningState] Provisioning state of the public IP * resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the frontend IP configuration that is unique + * within an Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever the * resource is updated. * @member {string} [type] Type of the resource. @@ -1864,8 +2054,8 @@ export interface ApplicationGatewayFrontendIPConfiguration extends SubResource { * @member {number} [port] Frontend port * @member {string} [provisioningState] Provisioning state of the frontend port * resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the frontend port that is unique within an + * Application Gateway * @member {string} [etag] A unique read-only string that changes whenever the * resource is updated. * @member {string} [type] Type of the resource. @@ -1890,8 +2080,8 @@ export interface ApplicationGatewayFrontendPort extends SubResource { * @member {object} [frontendPort] Frontend port resource of an application * gateway. * @member {string} [frontendPort.id] Resource ID. - * @member {string} [protocol] Protocol. Possible values include: 'Http', - * 'Https' + * @member {string} [protocol] Protocol of the HTTP listener. Possible values + * are 'Http' and 'Https'. Possible values include: 'Http', 'Https' * @member {string} [hostName] Host name of HTTP listener. * @member {object} [sslCertificate] SSL certificate resource of an application * gateway. @@ -1900,8 +2090,8 @@ export interface ApplicationGatewayFrontendPort extends SubResource { * is https. Enables SNI for multi-hosting. * @member {string} [provisioningState] Provisioning state of the HTTP listener * resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the HTTP listener that is unique within an + * Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever the * resource is updated. * @member {string} [type] Type of the resource. @@ -1937,8 +2127,8 @@ export interface ApplicationGatewayHttpListener extends SubResource { * @member {string} [redirectConfiguration.id] Resource ID. * @member {string} [provisioningState] Path rule of URL path map resource. * Possible values are: 'Updating', 'Deleting', and 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the path rule that is unique within an + * Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever the * resource is updated. * @member {string} [type] Type of the resource. @@ -1976,8 +2166,8 @@ export interface ApplicationGatewayProbeHealthResponseMatch { * @constructor * Probe of the application gateway. * - * @member {string} [protocol] Protocol. Possible values include: 'Http', - * 'Https' + * @member {string} [protocol] The protocol used for the probe. Possible values + * are 'Http' and 'Https'. Possible values include: 'Http', 'Https' * @member {string} [host] Host name to send the probe to. * @member {string} [path] Relative path of probe. Valid path starts from '/'. * Probe is sent to ://: @@ -2003,8 +2193,8 @@ export interface ApplicationGatewayProbeHealthResponseMatch { * @member {string} [provisioningState] Provisioning state of the backend http * settings resource. Possible values are: 'Updating', 'Deleting', and * 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the probe that is unique within an + * Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever the * resource is updated. * @member {string} [type] Type of the resource. @@ -2036,7 +2226,7 @@ export interface ApplicationGatewayProbe extends SubResource { * @member {object} [backendAddressPool] Backend address pool resource of the * application gateway. * @member {string} [backendAddressPool.id] Resource ID. - * @member {object} [backendHttpSettings] Frontend port resource of the + * @member {object} [backendHttpSettings] Backend http settings resource of the * application gateway. * @member {string} [backendHttpSettings.id] Resource ID. * @member {object} [httpListener] Http listener resource of the application @@ -2051,8 +2241,8 @@ export interface ApplicationGatewayProbe extends SubResource { * @member {string} [provisioningState] Provisioning state of the request * routing rule resource. Possible values are: 'Updating', 'Deleting', and * 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the request routing rule that is unique + * within an Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever the * resource is updated. * @member {string} [type] Type of the resource. @@ -2091,8 +2281,8 @@ export interface ApplicationGatewayRequestRoutingRule extends SubResource { * @member {array} [urlPathMaps] Url path maps specifying default redirect * configuration. * @member {array} [pathRules] Path rules specifying redirect configuration. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the redirect configuration that is unique + * within an Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever the * resource is updated. * @member {string} [type] Type of the resource. @@ -2131,8 +2321,8 @@ export interface ApplicationGatewayRedirectConfiguration extends SubResource { * @member {string} [provisioningState] Provisioning state of the backend http * settings resource. Possible values are: 'Updating', 'Deleting', and * 'Failed'. - * @member {string} [name] Name of the resource that is unique within a - * resource group. This name can be used to access the resource. + * @member {string} [name] Name of the URL path map that is unique within an + * Application Gateway. * @member {string} [etag] A unique read-only string that changes whenever the * resource is updated. * @member {string} [type] Type of the resource. @@ -2192,6 +2382,37 @@ export interface ApplicationGatewayWebApplicationFirewallConfiguration { maxRequestBodySize?: number; } +/** + * @class + * Initializes a new instance of the ApplicationGatewayAutoscaleBounds class. + * @constructor + * Application Gateway autoscale bounds on number of Application Gateway + * instance. + * + * @member {number} min Lower bound on number of Application Gateway instances. + * @member {number} max Upper bound on number of Application Gateway instances. + */ +export interface ApplicationGatewayAutoscaleBounds { + min: number; + max: number; +} + +/** + * @class + * Initializes a new instance of the ApplicationGatewayAutoscaleConfiguration class. + * @constructor + * Application Gateway autoscale configuration. + * + * @member {object} bounds Autoscale bounds + * @member {number} [bounds.min] Lower bound on number of Application Gateway + * instances. + * @member {number} [bounds.max] Upper bound on number of Application Gateway + * instances. + */ +export interface ApplicationGatewayAutoscaleConfiguration { + bounds: ApplicationGatewayAutoscaleBounds; +} + /** * @class * Initializes a new instance of the ApplicationGateway class. @@ -2201,9 +2422,9 @@ export interface ApplicationGatewayWebApplicationFirewallConfiguration { * @member {object} [sku] SKU of the application gateway resource. * @member {string} [sku.name] Name of an application gateway SKU. Possible * values include: 'Standard_Small', 'Standard_Medium', 'Standard_Large', - * 'WAF_Medium', 'WAF_Large' + * 'WAF_Medium', 'WAF_Large', 'Standard_v2', 'WAF_v2' * @member {string} [sku.tier] Tier of an application gateway. Possible values - * include: 'Standard', 'WAF' + * include: 'Standard', 'WAF', 'Standard_v2', 'WAF_v2' * @member {number} [sku.capacity] Capacity (instance count) of an application * gateway. * @member {object} [sslPolicy] SSL policy of the application gateway resource. @@ -2264,12 +2485,22 @@ export interface ApplicationGatewayWebApplicationFirewallConfiguration { * Maxium request body size for WAF. * @member {boolean} [enableHttp2] Whether HTTP2 is enabled on the application * gateway resource. + * @member {boolean} [enableFips] Whether FIPS is enabled on the application + * gateway resource. + * @member {object} [autoscaleConfiguration] Autoscale Configuration. + * @member {object} [autoscaleConfiguration.bounds] Autoscale bounds + * @member {number} [autoscaleConfiguration.bounds.min] Lower bound on number + * of Application Gateway instances. + * @member {number} [autoscaleConfiguration.bounds.max] Upper bound on number + * of Application Gateway instances. * @member {string} [resourceGuid] Resource GUID property of the application * gateway resource. * @member {string} [provisioningState] Provisioning state of the application * gateway resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. * @member {string} [etag] A unique read-only string that changes whenever the * resource is updated. + * @member {array} [zones] A list of availability zones denoting where the + * resource needs to come from. */ export interface ApplicationGateway extends Resource { sku?: ApplicationGatewaySku; @@ -2289,9 +2520,12 @@ export interface ApplicationGateway extends Resource { redirectConfigurations?: ApplicationGatewayRedirectConfiguration[]; webApplicationFirewallConfiguration?: ApplicationGatewayWebApplicationFirewallConfiguration; enableHttp2?: boolean; + enableFips?: boolean; + autoscaleConfiguration?: ApplicationGatewayAutoscaleConfiguration; resourceGuid?: string; provisioningState?: string; etag?: string; + zones?: string[]; } /** @@ -2389,7 +2623,7 @@ export interface ApplicationGatewayAvailableSslOptions extends Resource { * @constructor * An Ssl predefined policy * - * @member {string} [name] Name of Ssl predefined policy. + * @member {string} [name] Name of the Ssl predefined policy. * @member {array} [cipherSuites] Ssl cipher suites to be enabled in the * specified order for application gateway. * @member {string} [minProtocolVersion] Minimum version of Ssl protocol to be @@ -2432,6 +2666,11 @@ export interface DnsNameAvailabilityResult { * @constructor * A DDoS protection plan in a resource group. * + * @member {string} [id] Resource ID. + * @member {string} [name] Resource name. + * @member {string} [type] Resource type. + * @member {string} [location] Resource location. + * @member {object} [tags] Resource tags. * @member {string} [resourceGuid] The resource GUID property of the DDoS * protection plan resource. It uniquely identifies the resource, even if the * user changes its name or migrate the resource across subscriptions or @@ -2444,7 +2683,12 @@ export interface DnsNameAvailabilityResult { * @member {string} [etag] A unique read-only string that changes whenever the * resource is updated. */ -export interface DdosProtectionPlan extends Resource { +export interface DdosProtectionPlan extends BaseResource { + readonly id?: string; + readonly name?: string; + readonly type?: string; + location?: string; + tags?: { [propertyName: string]: string }; readonly resourceGuid?: string; readonly provisioningState?: string; readonly virtualNetworks?: SubResource[]; @@ -2890,8 +3134,8 @@ export interface ExpressRouteCircuit extends Resource { * @constructor * The ARP table associated with the ExpressRouteCircuit. * - * @member {number} [age] Age - * @member {string} [interfaceProperty] Interface + * @member {number} [age] Entry age in minutes + * @member {string} [interfaceProperty] Interface address * @member {string} [ipAddress] The IP address. * @member {string} [macAddress] The MAC address. */ @@ -2922,11 +3166,12 @@ export interface ExpressRouteCircuitsArpTableListResult { * @constructor * The routes table associated with the ExpressRouteCircuit * - * @member {string} [network] network - * @member {string} [nextHop] nextHop - * @member {string} [locPrf] locPrf - * @member {number} [weight] weight. - * @member {string} [path] path + * @member {string} [network] IP address of a network entity + * @member {string} [nextHop] NextHop address + * @member {string} [locPrf] Local preference value as set with the set + * local-preference route-map configuration command + * @member {number} [weight] Route Weight. + * @member {string} [path] Autonomous system paths to the destination network. */ export interface ExpressRouteCircuitRoutesTable { network?: string; @@ -2956,7 +3201,7 @@ export interface ExpressRouteCircuitsRoutesTableListResult { * @constructor * The routes table associated with the ExpressRouteCircuit. * - * @member {string} [neighbor] Neighbor + * @member {string} [neighbor] IP address of the neighbor. * @member {number} [v] BGP version number spoken to the neighbor. * @member {number} [as] Autonomous system number. * @member {string} [upDown] The length of time that the BGP session has been @@ -3164,7 +3409,7 @@ export interface ExpressRouteCrossConnectionPeering extends SubResource { vlanId?: number; microsoftPeeringConfig?: ExpressRouteCircuitPeeringConfig; readonly provisioningState?: string; - readonly gatewayManagerEtag?: string; + gatewayManagerEtag?: string; lastModifiedBy?: string; ipv6PeeringConfig?: Ipv6ExpressRouteCircuitPeeringConfig; name?: string; @@ -3203,9 +3448,9 @@ export interface ExpressRouteCrossConnection extends Resource { readonly primaryAzurePort?: string; readonly secondaryAzurePort?: string; readonly sTag?: number; - readonly peeringLocation?: string; - readonly bandwidthInMbps?: number; - readonly expressRouteCircuit?: ExpressRouteCircuitReference; + peeringLocation?: string; + bandwidthInMbps?: number; + expressRouteCircuit?: ExpressRouteCircuitReference; serviceProviderProvisioningState?: string; serviceProviderNotes?: string; readonly provisioningState?: string; @@ -3502,10 +3747,10 @@ export interface LoadBalancingRule extends SubResource { * @member {array} [loadBalancingRules] The load balancer rules that use this * probe. * @member {string} protocol The protocol of the end point. Possible values - * are: 'Http' or 'Tcp'. If 'Tcp' is specified, a received ACK is required for - * the probe to be successful. If 'Http' is specified, a 200 OK response from - * the specifies URI is required for the probe to be successful. Possible - * values include: 'Http', 'Tcp' + * are: 'Http', 'Tcp', or 'Https'. If 'Tcp' is specified, a received ACK is + * required for the probe to be successful. If 'Http' or 'Https' is specified, + * a 200 OK response from the specifies URI is required for the probe to be + * successful. Possible values include: 'Http', 'Tcp', 'Https' * @member {number} port The port for communicating the probe. Possible values * range from 1 to 65535, inclusive. * @member {number} [intervalInSeconds] The interval, in seconds, for how @@ -4502,23 +4747,64 @@ export interface RetentionPolicyParameters { * @class * Initializes a new instance of the FlowLogStatusParameters class. * @constructor - * Parameters that define a resource to query flow log status. + * Parameters that define a resource to query flow log and traffic analytics + * (optional) status. * * @member {string} targetResourceId The target resource where getting the flow - * logging status. + * log and traffic analytics (optional) status. */ export interface FlowLogStatusParameters { targetResourceId: string; } +/** + * @class + * Initializes a new instance of the TrafficAnalyticsConfigurationProperties class. + * @constructor + * Parameters that define the configuration of traffic analytics. + * + * @member {boolean} enabled Flag to enable/disable traffic analytics. + * @member {string} workspaceId The resource guid of the attached workspace + * @member {string} workspaceRegion The location of the attached workspace + * @member {string} workspaceResourceId Resource Id of the attached workspace + */ +export interface TrafficAnalyticsConfigurationProperties { + enabled: boolean; + workspaceId: string; + workspaceRegion: string; + workspaceResourceId: string; +} + +/** + * @class + * Initializes a new instance of the TrafficAnalyticsProperties class. + * @constructor + * Parameters that define the configuration of traffic analytics. + * + * @member {object} networkWatcherFlowAnalyticsConfiguration + * @member {boolean} [networkWatcherFlowAnalyticsConfiguration.enabled] Flag to + * enable/disable traffic analytics. + * @member {string} [networkWatcherFlowAnalyticsConfiguration.workspaceId] The + * resource guid of the attached workspace + * @member {string} [networkWatcherFlowAnalyticsConfiguration.workspaceRegion] + * The location of the attached workspace + * @member {string} + * [networkWatcherFlowAnalyticsConfiguration.workspaceResourceId] Resource Id + * of the attached workspace + */ +export interface TrafficAnalyticsProperties { + networkWatcherFlowAnalyticsConfiguration: TrafficAnalyticsConfigurationProperties; +} + /** * @class * Initializes a new instance of the FlowLogInformation class. * @constructor - * Information on the configuration of flow log. + * Information on the configuration of flow log and traffic analytics + * (optional) . * * @member {string} targetResourceId The ID of the resource to configure for - * flow logging. + * flow log and traffic analytics (optional) . * @member {string} storageId ID of the storage account which is used to store * the flow log. * @member {boolean} enabled Flag to enable/disable flow logging. @@ -4527,12 +4813,28 @@ export interface FlowLogStatusParameters { * records. * @member {boolean} [retentionPolicy.enabled] Flag to enable/disable * retention. + * @member {object} [flowAnalyticsConfiguration] + * @member {object} + * [flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration] + * @member {boolean} + * [flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.enabled] + * Flag to enable/disable traffic analytics. + * @member {string} + * [flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceId] + * The resource guid of the attached workspace + * @member {string} + * [flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceRegion] + * The location of the attached workspace + * @member {string} + * [flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceResourceId] + * Resource Id of the attached workspace */ export interface FlowLogInformation { targetResourceId: string; storageId: string; enabled: boolean; retentionPolicy?: RetentionPolicyParameters; + flowAnalyticsConfiguration?: TrafficAnalyticsProperties; } /** @@ -5567,10 +5869,12 @@ export interface VirtualNetworkGatewayIPConfiguration extends SubResource { * * @member {string} [name] Gateway SKU name. Possible values include: 'Basic', * 'HighPerformance', 'Standard', 'UltraPerformance', 'VpnGw1', 'VpnGw2', - * 'VpnGw3' + * 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', + * 'ErGw3AZ' * @member {string} [tier] Gateway SKU tier. Possible values include: 'Basic', * 'HighPerformance', 'Standard', 'UltraPerformance', 'VpnGw1', 'VpnGw2', - * 'VpnGw3' + * 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', + * 'ErGw3AZ' * @member {number} [capacity] The capacity. */ export interface VirtualNetworkGatewaySku { @@ -5794,10 +6098,12 @@ export interface GatewayRoute { * resource which represents the SKU selected for Virtual network gateway. * @member {string} [sku.name] Gateway SKU name. Possible values include: * 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', 'VpnGw1', - * 'VpnGw2', 'VpnGw3' + * 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * @member {string} [sku.tier] Gateway SKU tier. Possible values include: * 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', 'VpnGw1', - * 'VpnGw2', 'VpnGw3' + * 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * @member {number} [sku.capacity] The capacity. * @member {object} [vpnClientConfiguration] The reference of the * VpnClientConfiguration resource which represents the P2S VpnClient @@ -5992,10 +6298,12 @@ export interface LocalNetworkGateway extends Resource { * Virtual network gateway. * @member {string} [virtualNetworkGateway1.sku.name] Gateway SKU name. * Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * @member {string} [virtualNetworkGateway1.sku.tier] Gateway SKU tier. * Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * @member {number} [virtualNetworkGateway1.sku.capacity] The capacity. * @member {object} [virtualNetworkGateway1.vpnClientConfiguration] The * reference of the VpnClientConfiguration resource which represents the P2S @@ -6065,10 +6373,12 @@ export interface LocalNetworkGateway extends Resource { * Virtual network gateway. * @member {string} [virtualNetworkGateway2.sku.name] Gateway SKU name. * Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * @member {string} [virtualNetworkGateway2.sku.tier] Gateway SKU tier. * Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * @member {number} [virtualNetworkGateway2.sku.capacity] The capacity. * @member {object} [virtualNetworkGateway2.vpnClientConfiguration] The * reference of the VpnClientConfiguration resource which represents the P2S @@ -6211,7 +6521,7 @@ export interface ConnectionResetSharedKey { * * @member {string} value The virtual network connection shared key value. */ -export interface ConnectionSharedKey { +export interface ConnectionSharedKey extends SubResource { value: string; } @@ -6354,6 +6664,264 @@ export interface VpnDeviceScriptParameters { firmwareVersion?: string; } +/** + * @class + * Initializes a new instance of the VirtualWAN class. + * @constructor + * VirtualWAN Resource. + * + * @member {boolean} [disableVpnEncryption] Vpn encryption to be disabled or + * not. + * @member {array} [virtualHubs] List of VirtualHubs in the VirtualWAN. + * @member {array} [vpnSites] + * @member {string} [provisioningState] The provisioning state of the resource. + * Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed' + * @member {string} [etag] Gets a unique read-only string that changes whenever + * the resource is updated. + */ +export interface VirtualWAN extends Resource { + disableVpnEncryption?: boolean; + readonly virtualHubs?: SubResource[]; + readonly vpnSites?: SubResource[]; + provisioningState?: string; + readonly etag?: string; +} + +/** + * @class + * Initializes a new instance of the DeviceProperties class. + * @constructor + * List of properties of the device. + * + * @member {string} [deviceVendor] Name of the device Vendor. + * @member {string} [deviceModel] Model of the device. + * @member {number} [linkSpeedInMbps] Link speed. + */ +export interface DeviceProperties { + deviceVendor?: string; + deviceModel?: string; + linkSpeedInMbps?: number; +} + +/** + * @class + * Initializes a new instance of the VpnSite class. + * @constructor + * VpnSite Resource. + * + * @member {object} [virtualWAN] The VirtualWAN to which the vpnSite belongs + * @member {string} [virtualWAN.id] Resource ID. + * @member {object} [deviceProperties] The device properties + * @member {string} [deviceProperties.deviceVendor] Name of the device Vendor. + * @member {string} [deviceProperties.deviceModel] Model of the device. + * @member {number} [deviceProperties.linkSpeedInMbps] Link speed. + * @member {string} [ipAddress] The ip-address for the vpn-site. + * @member {string} [siteKey] The key for vpn-site that can be used for + * connections. + * @member {object} [addressSpace] The AddressSpace that contains an array of + * IP address ranges. + * @member {array} [addressSpace.addressPrefixes] A list of address blocks + * reserved for this virtual network in CIDR notation. + * @member {object} [bgpProperties] The set of bgp properties. + * @member {number} [bgpProperties.asn] The BGP speaker's ASN. + * @member {string} [bgpProperties.bgpPeeringAddress] The BGP peering address + * and BGP identifier of this BGP speaker. + * @member {number} [bgpProperties.peerWeight] The weight added to routes + * learned from this BGP speaker. + * @member {string} [provisioningState] The provisioning state of the resource. + * Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed' + * @member {string} [etag] Gets a unique read-only string that changes whenever + * the resource is updated. + */ +export interface VpnSite extends Resource { + virtualWAN?: SubResource; + deviceProperties?: DeviceProperties; + ipAddress?: string; + siteKey?: string; + addressSpace?: AddressSpace; + bgpProperties?: BgpSettings; + provisioningState?: string; + readonly etag?: string; +} + +/** + * @class + * Initializes a new instance of the GetVpnSitesConfigurationRequest class. + * @constructor + * List of Vpn-Sites + * + * @member {array} [vpnSites] List of resource-ids of the vpn-sites for which + * config is to be downloaded. + * @member {string} [outputBlobSasUrl] The sas-url to download the + * configurations for vpn-sites + */ +export interface GetVpnSitesConfigurationRequest { + vpnSites?: SubResource[]; + outputBlobSasUrl?: string; +} + +/** + * @class + * Initializes a new instance of the HubVirtualNetworkConnection class. + * @constructor + * HubVirtualNetworkConnection Resource. + * + * @member {object} [remoteVirtualNetwork] Reference to the remote virtual + * network. + * @member {string} [remoteVirtualNetwork.id] Resource ID. + * @member {boolean} [allowHubToRemoteVnetTransit] VirtualHub to RemoteVnet + * transit to enabled or not. + * @member {boolean} [allowRemoteVnetToUseHubVnetGateways] Allow RemoteVnet to + * use Virtual Hub's gateways. + * @member {string} [provisioningState] The provisioning state of the resource. + * Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed' + * @member {string} [etag] Gets a unique read-only string that changes whenever + * the resource is updated. + */ +export interface HubVirtualNetworkConnection extends Resource { + remoteVirtualNetwork?: SubResource; + allowHubToRemoteVnetTransit?: boolean; + allowRemoteVnetToUseHubVnetGateways?: boolean; + provisioningState?: string; + readonly etag?: string; +} + +/** + * @class + * Initializes a new instance of the VirtualHub class. + * @constructor + * VirtualHub Resource. + * + * @member {object} [virtualWan] The VirtualWAN to which the VirtualHub belongs + * @member {string} [virtualWan.id] Resource ID. + * @member {array} [hubVirtualNetworkConnections] list of all vnet connections + * with this VirtualHub. + * @member {string} [addressPrefix] Address-prefix for this VirtualHub. + * @member {string} [provisioningState] The provisioning state of the resource. + * Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed' + * @member {string} [etag] Gets a unique read-only string that changes whenever + * the resource is updated. + */ +export interface VirtualHub extends Resource { + virtualWan?: SubResource; + hubVirtualNetworkConnections?: HubVirtualNetworkConnection[]; + addressPrefix?: string; + provisioningState?: string; + readonly etag?: string; +} + +/** + * @class + * Initializes a new instance of the VpnConnection class. + * @constructor + * VpnConnection Resource. + * + * @member {object} [remoteVpnSite] Id of the connected vpn site. + * @member {string} [remoteVpnSite.id] Resource ID. + * @member {number} [routingWeight] routing weight for vpn connection. + * @member {string} [connectionStatus] The connection status. Possible values + * include: 'Unknown', 'Connecting', 'Connected', 'NotConnected' + * @member {number} [ingressBytesTransferred] Ingress bytes transferred. + * @member {number} [egressBytesTransferred] Egress bytes transferred. + * @member {number} [connectionBandwidthInMbps] Expected bandwidth in MBPS. + * @member {string} [sharedKey] SharedKey for the vpn connection. + * @member {boolean} [enableBgp] EnableBgp flag + * @member {array} [ipsecPolicies] The IPSec Policies to be considered by this + * connection. + * @member {string} [provisioningState] The provisioning state of the resource. + * Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed' + * @member {string} [etag] Gets a unique read-only string that changes whenever + * the resource is updated. + */ +export interface VpnConnection extends Resource { + remoteVpnSite?: SubResource; + routingWeight?: number; + connectionStatus?: string; + readonly ingressBytesTransferred?: number; + readonly egressBytesTransferred?: number; + readonly connectionBandwidthInMbps?: number; + sharedKey?: string; + enableBgp?: boolean; + ipsecPolicies?: IpsecPolicy[]; + provisioningState?: string; + readonly etag?: string; +} + +/** + * @class + * Initializes a new instance of the Policies class. + * @constructor + * Policies for vpn gateway. + * + * @member {boolean} [allowBranchToBranchTraffic] True if branch to branch + * traffic is allowed. + * @member {boolean} [allowVnetToVnetTraffic] True if Vnet to Vnet traffic is + * allowed. + */ +export interface Policies { + allowBranchToBranchTraffic?: boolean; + allowVnetToVnetTraffic?: boolean; +} + +/** + * @class + * Initializes a new instance of the VpnGateway class. + * @constructor + * VpnGateway Resource. + * + * @member {object} [virtualHub] The VirtualHub to which the gateway belongs + * @member {string} [virtualHub.id] Resource ID. + * @member {array} [connections] list of all vpn connections to the gateway. + * @member {object} [bgpSettings] Local network gateway's BGP speaker settings. + * @member {number} [bgpSettings.asn] The BGP speaker's ASN. + * @member {string} [bgpSettings.bgpPeeringAddress] The BGP peering address and + * BGP identifier of this BGP speaker. + * @member {number} [bgpSettings.peerWeight] The weight added to routes learned + * from this BGP speaker. + * @member {string} [provisioningState] The provisioning state of the resource. + * Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed' + * @member {object} [policies] The policies applied to this vpn gateway. + * @member {boolean} [policies.allowBranchToBranchTraffic] True if branch to + * branch traffic is allowed. + * @member {boolean} [policies.allowVnetToVnetTraffic] True if Vnet to Vnet + * traffic is allowed. + * @member {string} [etag] Gets a unique read-only string that changes whenever + * the resource is updated. + */ +export interface VpnGateway extends Resource { + virtualHub?: SubResource; + connections?: VpnConnection[]; + bgpSettings?: BgpSettings; + provisioningState?: string; + policies?: Policies; + readonly etag?: string; +} + +/** + * @class + * Initializes a new instance of the VpnSiteId class. + * @constructor + * VpnSite Resource. + * + * @member {string} [vpnSite] The resource-uri of the vpn-site for which config + * is to be fetched. + */ +export interface VpnSiteId { + readonly vpnSite?: string; +} + + +/** + * @class + * Initializes a new instance of the AzureFirewallListResult class. + * @constructor + * Response for ListAzureFirewalls API service call. + * + * @member {string} [nextLink] URL to get the next set of results. + */ +export interface AzureFirewallListResult extends Array { + nextLink?: string; +} /** * @class @@ -6848,3 +7416,88 @@ export interface VirtualNetworkGatewayConnectionListResult extends Array { readonly nextLink?: string; } + +/** + * @class + * Initializes a new instance of the ListVirtualWANsResult class. + * @constructor + * Result of the request to list VirtualWANs. It contains a list of VirtualWANs + * and a URL nextLink to get the next set of results. + * + * @member {string} [nextLink] URL to get the next set of operation list + * results if there are any. + */ +export interface ListVirtualWANsResult extends Array { + nextLink?: string; +} + +/** + * @class + * Initializes a new instance of the ListVpnSitesResult class. + * @constructor + * Result of the request to list VpnSites. It contains a list of VpnSites and a + * URL nextLink to get the next set of results. + * + * @member {string} [nextLink] URL to get the next set of operation list + * results if there are any. + */ +export interface ListVpnSitesResult extends Array { + nextLink?: string; +} + +/** + * @class + * Initializes a new instance of the ListVirtualHubsResult class. + * @constructor + * Result of the request to list VirtualHubs. It contains a list of VirtualHubs + * and a URL nextLink to get the next set of results. + * + * @member {string} [nextLink] URL to get the next set of operation list + * results if there are any. + */ +export interface ListVirtualHubsResult extends Array { + nextLink?: string; +} + +/** + * @class + * Initializes a new instance of the ListHubVirtualNetworkConnectionsResult class. + * @constructor + * List of HubVirtualNetworkConnections and a URL nextLink to get the next set + * of results. + * + * @member {string} [nextLink] URL to get the next set of operation list + * results if there are any. + */ +export interface ListHubVirtualNetworkConnectionsResult extends Array { + nextLink?: string; +} + +/** + * @class + * Initializes a new instance of the ListVpnGatewaysResult class. + * @constructor + * Result of the request to list VpnGateways. It contains a list of VpnGateways + * and a URL nextLink to get the next set of results. + * + * @member {string} [nextLink] URL to get the next set of operation list + * results if there are any. + */ +export interface ListVpnGatewaysResult extends Array { + nextLink?: string; +} + +/** + * @class + * Initializes a new instance of the ListVpnConnectionsResult class. + * @constructor + * Result of the request to list all vpn connections to a virtual wan vpn + * gateway. It contains a list of Vpn Connections and a URL nextLink to get the + * next set of results. + * + * @member {string} [nextLink] URL to get the next set of operation list + * results if there are any. + */ +export interface ListVpnConnectionsResult extends Array { + nextLink?: string; +} diff --git a/lib/services/networkManagement2/lib/models/index.js b/lib/services/networkManagement2/lib/models/index.js index 4f242870be..bd50b1261c 100644 --- a/lib/services/networkManagement2/lib/models/index.js +++ b/lib/services/networkManagement2/lib/models/index.js @@ -19,9 +19,17 @@ var msRestAzure = require('ms-rest-azure'); exports.BaseResource = msRestAzure.BaseResource; exports.CloudError = msRestAzure.CloudError; exports.SubResource = require('./subResource'); +exports.AzureFirewallIPConfiguration = require('./azureFirewallIPConfiguration'); +exports.AzureFirewallRCAction = require('./azureFirewallRCAction'); +exports.AzureFirewallApplicationRuleProtocol = require('./azureFirewallApplicationRuleProtocol'); +exports.AzureFirewallApplicationRule = require('./azureFirewallApplicationRule'); +exports.AzureFirewallApplicationRuleCollection = require('./azureFirewallApplicationRuleCollection'); +exports.AzureFirewallNetworkRule = require('./azureFirewallNetworkRule'); +exports.AzureFirewallNetworkRuleCollection = require('./azureFirewallNetworkRuleCollection'); +exports.Resource = require('./resource'); +exports.AzureFirewall = require('./azureFirewall'); exports.BackendAddressPool = require('./backendAddressPool'); exports.InboundNatRule = require('./inboundNatRule'); -exports.Resource = require('./resource'); exports.ApplicationSecurityGroup = require('./applicationSecurityGroup'); exports.SecurityRule = require('./securityRule'); exports.NetworkInterfaceDnsSettings = require('./networkInterfaceDnsSettings'); @@ -62,6 +70,8 @@ exports.ApplicationGatewayRedirectConfiguration = require('./applicationGatewayR exports.ApplicationGatewayUrlPathMap = require('./applicationGatewayUrlPathMap'); exports.ApplicationGatewayFirewallDisabledRuleGroup = require('./applicationGatewayFirewallDisabledRuleGroup'); exports.ApplicationGatewayWebApplicationFirewallConfiguration = require('./applicationGatewayWebApplicationFirewallConfiguration'); +exports.ApplicationGatewayAutoscaleBounds = require('./applicationGatewayAutoscaleBounds'); +exports.ApplicationGatewayAutoscaleConfiguration = require('./applicationGatewayAutoscaleConfiguration'); exports.ApplicationGateway = require('./applicationGateway'); exports.ApplicationGatewayFirewallRule = require('./applicationGatewayFirewallRule'); exports.ApplicationGatewayFirewallRuleGroup = require('./applicationGatewayFirewallRuleGroup'); @@ -141,6 +151,8 @@ exports.TroubleshootingDetails = require('./troubleshootingDetails'); exports.TroubleshootingResult = require('./troubleshootingResult'); exports.RetentionPolicyParameters = require('./retentionPolicyParameters'); exports.FlowLogStatusParameters = require('./flowLogStatusParameters'); +exports.TrafficAnalyticsConfigurationProperties = require('./trafficAnalyticsConfigurationProperties'); +exports.TrafficAnalyticsProperties = require('./trafficAnalyticsProperties'); exports.FlowLogInformation = require('./flowLogInformation'); exports.ConnectivitySource = require('./connectivitySource'); exports.ConnectivityDestination = require('./connectivityDestination'); @@ -210,6 +222,17 @@ exports.VpnClientIPsecParameters = require('./vpnClientIPsecParameters'); exports.VirtualNetworkConnectionGatewayReference = require('./virtualNetworkConnectionGatewayReference'); exports.VirtualNetworkGatewayConnectionListEntity = require('./virtualNetworkGatewayConnectionListEntity'); exports.VpnDeviceScriptParameters = require('./vpnDeviceScriptParameters'); +exports.VirtualWAN = require('./virtualWAN'); +exports.DeviceProperties = require('./deviceProperties'); +exports.VpnSite = require('./vpnSite'); +exports.GetVpnSitesConfigurationRequest = require('./getVpnSitesConfigurationRequest'); +exports.HubVirtualNetworkConnection = require('./hubVirtualNetworkConnection'); +exports.VirtualHub = require('./virtualHub'); +exports.VpnConnection = require('./vpnConnection'); +exports.Policies = require('./policies'); +exports.VpnGateway = require('./vpnGateway'); +exports.VpnSiteId = require('./vpnSiteId'); +exports.AzureFirewallListResult = require('./azureFirewallListResult'); exports.ApplicationGatewayListResult = require('./applicationGatewayListResult'); exports.ApplicationGatewayAvailableSslPredefinedPolicies = require('./applicationGatewayAvailableSslPredefinedPolicies'); exports.ApplicationSecurityGroupListResult = require('./applicationSecurityGroupListResult'); @@ -251,3 +274,9 @@ exports.VirtualNetworkGatewayListResult = require('./virtualNetworkGatewayListRe exports.VirtualNetworkGatewayListConnectionsResult = require('./virtualNetworkGatewayListConnectionsResult'); exports.VirtualNetworkGatewayConnectionListResult = require('./virtualNetworkGatewayConnectionListResult'); exports.LocalNetworkGatewayListResult = require('./localNetworkGatewayListResult'); +exports.ListVirtualWANsResult = require('./listVirtualWANsResult'); +exports.ListVpnSitesResult = require('./listVpnSitesResult'); +exports.ListVirtualHubsResult = require('./listVirtualHubsResult'); +exports.ListHubVirtualNetworkConnectionsResult = require('./listHubVirtualNetworkConnectionsResult'); +exports.ListVpnGatewaysResult = require('./listVpnGatewaysResult'); +exports.ListVpnConnectionsResult = require('./listVpnConnectionsResult'); diff --git a/lib/services/networkManagement2/lib/models/listHubVirtualNetworkConnectionsResult.js b/lib/services/networkManagement2/lib/models/listHubVirtualNetworkConnectionsResult.js new file mode 100644 index 0000000000..8c7741dbc1 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/listHubVirtualNetworkConnectionsResult.js @@ -0,0 +1,69 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +/** + * List of HubVirtualNetworkConnections and a URL nextLink to get the next set + * of results. + */ +class ListHubVirtualNetworkConnectionsResult extends Array { + /** + * Create a ListHubVirtualNetworkConnectionsResult. + * @member {string} [nextLink] URL to get the next set of operation list + * results if there are any. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of ListHubVirtualNetworkConnectionsResult + * + * @returns {object} metadata of ListHubVirtualNetworkConnectionsResult + * + */ + mapper() { + return { + required: false, + serializedName: 'ListHubVirtualNetworkConnectionsResult', + type: { + name: 'Composite', + className: 'ListHubVirtualNetworkConnectionsResult', + modelProperties: { + value: { + required: false, + serializedName: '', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'HubVirtualNetworkConnectionElementType', + type: { + name: 'Composite', + className: 'HubVirtualNetworkConnection' + } + } + } + }, + nextLink: { + required: false, + serializedName: 'nextLink', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = ListHubVirtualNetworkConnectionsResult; diff --git a/lib/services/networkManagement2/lib/models/listVirtualHubsResult.js b/lib/services/networkManagement2/lib/models/listVirtualHubsResult.js new file mode 100644 index 0000000000..60052e6e7d --- /dev/null +++ b/lib/services/networkManagement2/lib/models/listVirtualHubsResult.js @@ -0,0 +1,69 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +/** + * Result of the request to list VirtualHubs. It contains a list of VirtualHubs + * and a URL nextLink to get the next set of results. + */ +class ListVirtualHubsResult extends Array { + /** + * Create a ListVirtualHubsResult. + * @member {string} [nextLink] URL to get the next set of operation list + * results if there are any. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of ListVirtualHubsResult + * + * @returns {object} metadata of ListVirtualHubsResult + * + */ + mapper() { + return { + required: false, + serializedName: 'ListVirtualHubsResult', + type: { + name: 'Composite', + className: 'ListVirtualHubsResult', + modelProperties: { + value: { + required: false, + serializedName: '', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'VirtualHubElementType', + type: { + name: 'Composite', + className: 'VirtualHub' + } + } + } + }, + nextLink: { + required: false, + serializedName: 'nextLink', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = ListVirtualHubsResult; diff --git a/lib/services/networkManagement2/lib/models/listVirtualWANsResult.js b/lib/services/networkManagement2/lib/models/listVirtualWANsResult.js new file mode 100644 index 0000000000..2f58389096 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/listVirtualWANsResult.js @@ -0,0 +1,69 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +/** + * Result of the request to list VirtualWANs. It contains a list of VirtualWANs + * and a URL nextLink to get the next set of results. + */ +class ListVirtualWANsResult extends Array { + /** + * Create a ListVirtualWANsResult. + * @member {string} [nextLink] URL to get the next set of operation list + * results if there are any. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of ListVirtualWANsResult + * + * @returns {object} metadata of ListVirtualWANsResult + * + */ + mapper() { + return { + required: false, + serializedName: 'ListVirtualWANsResult', + type: { + name: 'Composite', + className: 'ListVirtualWANsResult', + modelProperties: { + value: { + required: false, + serializedName: '', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'VirtualWANElementType', + type: { + name: 'Composite', + className: 'VirtualWAN' + } + } + } + }, + nextLink: { + required: false, + serializedName: 'nextLink', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = ListVirtualWANsResult; diff --git a/lib/services/networkManagement2/lib/models/listVpnConnectionsResult.js b/lib/services/networkManagement2/lib/models/listVpnConnectionsResult.js new file mode 100644 index 0000000000..91652c5497 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/listVpnConnectionsResult.js @@ -0,0 +1,70 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +/** + * Result of the request to list all vpn connections to a virtual wan vpn + * gateway. It contains a list of Vpn Connections and a URL nextLink to get the + * next set of results. + */ +class ListVpnConnectionsResult extends Array { + /** + * Create a ListVpnConnectionsResult. + * @member {string} [nextLink] URL to get the next set of operation list + * results if there are any. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of ListVpnConnectionsResult + * + * @returns {object} metadata of ListVpnConnectionsResult + * + */ + mapper() { + return { + required: false, + serializedName: 'ListVpnConnectionsResult', + type: { + name: 'Composite', + className: 'ListVpnConnectionsResult', + modelProperties: { + value: { + required: false, + serializedName: '', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'VpnConnectionElementType', + type: { + name: 'Composite', + className: 'VpnConnection' + } + } + } + }, + nextLink: { + required: false, + serializedName: 'nextLink', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = ListVpnConnectionsResult; diff --git a/lib/services/networkManagement2/lib/models/listVpnGatewaysResult.js b/lib/services/networkManagement2/lib/models/listVpnGatewaysResult.js new file mode 100644 index 0000000000..b840abe313 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/listVpnGatewaysResult.js @@ -0,0 +1,69 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +/** + * Result of the request to list VpnGateways. It contains a list of VpnGateways + * and a URL nextLink to get the next set of results. + */ +class ListVpnGatewaysResult extends Array { + /** + * Create a ListVpnGatewaysResult. + * @member {string} [nextLink] URL to get the next set of operation list + * results if there are any. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of ListVpnGatewaysResult + * + * @returns {object} metadata of ListVpnGatewaysResult + * + */ + mapper() { + return { + required: false, + serializedName: 'ListVpnGatewaysResult', + type: { + name: 'Composite', + className: 'ListVpnGatewaysResult', + modelProperties: { + value: { + required: false, + serializedName: '', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'VpnGatewayElementType', + type: { + name: 'Composite', + className: 'VpnGateway' + } + } + } + }, + nextLink: { + required: false, + serializedName: 'nextLink', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = ListVpnGatewaysResult; diff --git a/lib/services/networkManagement2/lib/models/listVpnSitesResult.js b/lib/services/networkManagement2/lib/models/listVpnSitesResult.js new file mode 100644 index 0000000000..b704f0b2e5 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/listVpnSitesResult.js @@ -0,0 +1,69 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +/** + * Result of the request to list VpnSites. It contains a list of VpnSites and a + * URL nextLink to get the next set of results. + */ +class ListVpnSitesResult extends Array { + /** + * Create a ListVpnSitesResult. + * @member {string} [nextLink] URL to get the next set of operation list + * results if there are any. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of ListVpnSitesResult + * + * @returns {object} metadata of ListVpnSitesResult + * + */ + mapper() { + return { + required: false, + serializedName: 'ListVpnSitesResult', + type: { + name: 'Composite', + className: 'ListVpnSitesResult', + modelProperties: { + value: { + required: false, + serializedName: '', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'VpnSiteElementType', + type: { + name: 'Composite', + className: 'VpnSite' + } + } + } + }, + nextLink: { + required: false, + serializedName: 'nextLink', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = ListVpnSitesResult; diff --git a/lib/services/networkManagement2/lib/models/policies.js b/lib/services/networkManagement2/lib/models/policies.js new file mode 100644 index 0000000000..4e6e439be3 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/policies.js @@ -0,0 +1,62 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +/** + * Policies for vpn gateway. + * + */ +class Policies { + /** + * Create a Policies. + * @member {boolean} [allowBranchToBranchTraffic] True if branch to branch + * traffic is allowed. + * @member {boolean} [allowVnetToVnetTraffic] True if Vnet to Vnet traffic is + * allowed. + */ + constructor() { + } + + /** + * Defines the metadata of Policies + * + * @returns {object} metadata of Policies + * + */ + mapper() { + return { + required: false, + serializedName: 'Policies', + type: { + name: 'Composite', + className: 'Policies', + modelProperties: { + allowBranchToBranchTraffic: { + required: false, + serializedName: 'allowBranchToBranchTraffic', + type: { + name: 'Boolean' + } + }, + allowVnetToVnetTraffic: { + required: false, + serializedName: 'allowVnetToVnetTraffic', + type: { + name: 'Boolean' + } + } + } + } + }; + } +} + +module.exports = Policies; diff --git a/lib/services/networkManagement2/lib/models/probe.js b/lib/services/networkManagement2/lib/models/probe.js index 667f984b64..48081c251c 100644 --- a/lib/services/networkManagement2/lib/models/probe.js +++ b/lib/services/networkManagement2/lib/models/probe.js @@ -23,10 +23,10 @@ class Probe extends models['SubResource'] { * @member {array} [loadBalancingRules] The load balancer rules that use this * probe. * @member {string} protocol The protocol of the end point. Possible values - * are: 'Http' or 'Tcp'. If 'Tcp' is specified, a received ACK is required - * for the probe to be successful. If 'Http' is specified, a 200 OK response - * from the specifies URI is required for the probe to be successful. - * Possible values include: 'Http', 'Tcp' + * are: 'Http', 'Tcp', or 'Https'. If 'Tcp' is specified, a received ACK is + * required for the probe to be successful. If 'Http' or 'Https' is + * specified, a 200 OK response from the specifies URI is required for the + * probe to be successful. Possible values include: 'Http', 'Tcp', 'Https' * @member {number} port The port for communicating the probe. Possible * values range from 1 to 65535, inclusive. * @member {number} [intervalInSeconds] The interval, in seconds, for how diff --git a/lib/services/networkManagement2/lib/models/trafficAnalyticsConfigurationProperties.js b/lib/services/networkManagement2/lib/models/trafficAnalyticsConfigurationProperties.js new file mode 100644 index 0000000000..58b762cb24 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/trafficAnalyticsConfigurationProperties.js @@ -0,0 +1,76 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +/** + * Parameters that define the configuration of traffic analytics. + * + */ +class TrafficAnalyticsConfigurationProperties { + /** + * Create a TrafficAnalyticsConfigurationProperties. + * @member {boolean} enabled Flag to enable/disable traffic analytics. + * @member {string} workspaceId The resource guid of the attached workspace + * @member {string} workspaceRegion The location of the attached workspace + * @member {string} workspaceResourceId Resource Id of the attached workspace + */ + constructor() { + } + + /** + * Defines the metadata of TrafficAnalyticsConfigurationProperties + * + * @returns {object} metadata of TrafficAnalyticsConfigurationProperties + * + */ + mapper() { + return { + required: false, + serializedName: 'TrafficAnalyticsConfigurationProperties', + type: { + name: 'Composite', + className: 'TrafficAnalyticsConfigurationProperties', + modelProperties: { + enabled: { + required: true, + serializedName: 'enabled', + type: { + name: 'Boolean' + } + }, + workspaceId: { + required: true, + serializedName: 'workspaceId', + type: { + name: 'String' + } + }, + workspaceRegion: { + required: true, + serializedName: 'workspaceRegion', + type: { + name: 'String' + } + }, + workspaceResourceId: { + required: true, + serializedName: 'workspaceResourceId', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = TrafficAnalyticsConfigurationProperties; diff --git a/lib/services/networkManagement2/lib/models/trafficAnalyticsProperties.js b/lib/services/networkManagement2/lib/models/trafficAnalyticsProperties.js new file mode 100644 index 0000000000..2ce9c0f663 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/trafficAnalyticsProperties.js @@ -0,0 +1,65 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const models = require('./index'); + +/** + * Parameters that define the configuration of traffic analytics. + * + */ +class TrafficAnalyticsProperties { + /** + * Create a TrafficAnalyticsProperties. + * @member {object} networkWatcherFlowAnalyticsConfiguration + * @member {boolean} [networkWatcherFlowAnalyticsConfiguration.enabled] Flag + * to enable/disable traffic analytics. + * @member {string} [networkWatcherFlowAnalyticsConfiguration.workspaceId] + * The resource guid of the attached workspace + * @member {string} + * [networkWatcherFlowAnalyticsConfiguration.workspaceRegion] The location of + * the attached workspace + * @member {string} + * [networkWatcherFlowAnalyticsConfiguration.workspaceResourceId] Resource Id + * of the attached workspace + */ + constructor() { + } + + /** + * Defines the metadata of TrafficAnalyticsProperties + * + * @returns {object} metadata of TrafficAnalyticsProperties + * + */ + mapper() { + return { + required: false, + serializedName: 'TrafficAnalyticsProperties', + type: { + name: 'Composite', + className: 'TrafficAnalyticsProperties', + modelProperties: { + networkWatcherFlowAnalyticsConfiguration: { + required: true, + serializedName: 'networkWatcherFlowAnalyticsConfiguration', + type: { + name: 'Composite', + className: 'TrafficAnalyticsConfigurationProperties' + } + } + } + } + }; + } +} + +module.exports = TrafficAnalyticsProperties; diff --git a/lib/services/networkManagement2/lib/models/virtualHub.js b/lib/services/networkManagement2/lib/models/virtualHub.js new file mode 100644 index 0000000000..57bb504dfe --- /dev/null +++ b/lib/services/networkManagement2/lib/models/virtualHub.js @@ -0,0 +1,148 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const models = require('./index'); + +/** + * VirtualHub Resource. + * + * @extends models['Resource'] + */ +class VirtualHub extends models['Resource'] { + /** + * Create a VirtualHub. + * @member {object} [virtualWan] The VirtualWAN to which the VirtualHub + * belongs + * @member {string} [virtualWan.id] Resource ID. + * @member {array} [hubVirtualNetworkConnections] list of all vnet + * connections with this VirtualHub. + * @member {string} [addressPrefix] Address-prefix for this VirtualHub. + * @member {string} [provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * @member {string} [etag] Gets a unique read-only string that changes + * whenever the resource is updated. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of VirtualHub + * + * @returns {object} metadata of VirtualHub + * + */ + mapper() { + return { + required: false, + serializedName: 'VirtualHub', + type: { + name: 'Composite', + className: 'VirtualHub', + modelProperties: { + id: { + required: false, + serializedName: 'id', + type: { + name: 'String' + } + }, + name: { + required: false, + readOnly: true, + serializedName: 'name', + type: { + name: 'String' + } + }, + type: { + required: false, + readOnly: true, + serializedName: 'type', + type: { + name: 'String' + } + }, + location: { + required: false, + serializedName: 'location', + type: { + name: 'String' + } + }, + tags: { + required: false, + serializedName: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serializedName: 'StringElementType', + type: { + name: 'String' + } + } + } + }, + virtualWan: { + required: false, + serializedName: 'properties.virtualWan', + type: { + name: 'Composite', + className: 'SubResource' + } + }, + hubVirtualNetworkConnections: { + required: false, + serializedName: 'properties.hubVirtualNetworkConnections', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'HubVirtualNetworkConnectionElementType', + type: { + name: 'Composite', + className: 'HubVirtualNetworkConnection' + } + } + } + }, + addressPrefix: { + required: false, + serializedName: 'properties.addressPrefix', + type: { + name: 'String' + } + }, + provisioningState: { + required: false, + serializedName: 'properties.provisioningState', + type: { + name: 'String' + } + }, + etag: { + required: false, + readOnly: true, + serializedName: 'etag', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = VirtualHub; diff --git a/lib/services/networkManagement2/lib/models/virtualNetworkGateway.js b/lib/services/networkManagement2/lib/models/virtualNetworkGateway.js index a8853085dc..1447f48628 100644 --- a/lib/services/networkManagement2/lib/models/virtualNetworkGateway.js +++ b/lib/services/networkManagement2/lib/models/virtualNetworkGateway.js @@ -40,10 +40,12 @@ class VirtualNetworkGateway extends models['Resource'] { * resource which represents the SKU selected for Virtual network gateway. * @member {string} [sku.name] Gateway SKU name. Possible values include: * 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', 'VpnGw1', - * 'VpnGw2', 'VpnGw3' + * 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * @member {string} [sku.tier] Gateway SKU tier. Possible values include: * 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', 'VpnGw1', - * 'VpnGw2', 'VpnGw3' + * 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * @member {number} [sku.capacity] The capacity. * @member {object} [vpnClientConfiguration] The reference of the * VpnClientConfiguration resource which represents the P2S VpnClient diff --git a/lib/services/networkManagement2/lib/models/virtualNetworkGatewayConnection.js b/lib/services/networkManagement2/lib/models/virtualNetworkGatewayConnection.js index b6dc8791ef..ec5d8f580a 100644 --- a/lib/services/networkManagement2/lib/models/virtualNetworkGatewayConnection.js +++ b/lib/services/networkManagement2/lib/models/virtualNetworkGatewayConnection.js @@ -45,10 +45,12 @@ class VirtualNetworkGatewayConnection extends models['Resource'] { * Virtual network gateway. * @member {string} [virtualNetworkGateway1.sku.name] Gateway SKU name. * Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * @member {string} [virtualNetworkGateway1.sku.tier] Gateway SKU tier. * Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * @member {number} [virtualNetworkGateway1.sku.capacity] The capacity. * @member {object} [virtualNetworkGateway1.vpnClientConfiguration] The * reference of the VpnClientConfiguration resource which represents the P2S @@ -120,10 +122,12 @@ class VirtualNetworkGatewayConnection extends models['Resource'] { * Virtual network gateway. * @member {string} [virtualNetworkGateway2.sku.name] Gateway SKU name. * Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * @member {string} [virtualNetworkGateway2.sku.tier] Gateway SKU tier. * Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * @member {number} [virtualNetworkGateway2.sku.capacity] The capacity. * @member {object} [virtualNetworkGateway2.vpnClientConfiguration] The * reference of the VpnClientConfiguration resource which represents the P2S diff --git a/lib/services/networkManagement2/lib/models/virtualNetworkGatewaySku.js b/lib/services/networkManagement2/lib/models/virtualNetworkGatewaySku.js index cea2349ade..27313b7a45 100644 --- a/lib/services/networkManagement2/lib/models/virtualNetworkGatewaySku.js +++ b/lib/services/networkManagement2/lib/models/virtualNetworkGatewaySku.js @@ -19,10 +19,12 @@ class VirtualNetworkGatewaySku { * Create a VirtualNetworkGatewaySku. * @member {string} [name] Gateway SKU name. Possible values include: * 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', 'VpnGw1', - * 'VpnGw2', 'VpnGw3' + * 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * @member {string} [tier] Gateway SKU tier. Possible values include: * 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', 'VpnGw1', - * 'VpnGw2', 'VpnGw3' + * 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * @member {number} [capacity] The capacity. */ constructor() { diff --git a/lib/services/networkManagement2/lib/models/virtualWAN.js b/lib/services/networkManagement2/lib/models/virtualWAN.js new file mode 100644 index 0000000000..7e36a55266 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/virtualWAN.js @@ -0,0 +1,155 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const models = require('./index'); + +/** + * VirtualWAN Resource. + * + * @extends models['Resource'] + */ +class VirtualWAN extends models['Resource'] { + /** + * Create a VirtualWAN. + * @member {boolean} [disableVpnEncryption] Vpn encryption to be disabled or + * not. + * @member {array} [virtualHubs] List of VirtualHubs in the VirtualWAN. + * @member {array} [vpnSites] + * @member {string} [provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * @member {string} [etag] Gets a unique read-only string that changes + * whenever the resource is updated. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of VirtualWAN + * + * @returns {object} metadata of VirtualWAN + * + */ + mapper() { + return { + required: false, + serializedName: 'VirtualWAN', + type: { + name: 'Composite', + className: 'VirtualWAN', + modelProperties: { + id: { + required: false, + serializedName: 'id', + type: { + name: 'String' + } + }, + name: { + required: false, + readOnly: true, + serializedName: 'name', + type: { + name: 'String' + } + }, + type: { + required: false, + readOnly: true, + serializedName: 'type', + type: { + name: 'String' + } + }, + location: { + required: false, + serializedName: 'location', + type: { + name: 'String' + } + }, + tags: { + required: false, + serializedName: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serializedName: 'StringElementType', + type: { + name: 'String' + } + } + } + }, + disableVpnEncryption: { + required: false, + serializedName: 'properties.disableVpnEncryption', + type: { + name: 'Boolean' + } + }, + virtualHubs: { + required: false, + readOnly: true, + serializedName: 'properties.virtualHubs', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'SubResourceElementType', + type: { + name: 'Composite', + className: 'SubResource' + } + } + } + }, + vpnSites: { + required: false, + readOnly: true, + serializedName: 'properties.vpnSites', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'SubResourceElementType', + type: { + name: 'Composite', + className: 'SubResource' + } + } + } + }, + provisioningState: { + required: false, + serializedName: 'properties.provisioningState', + type: { + name: 'String' + } + }, + etag: { + required: false, + readOnly: true, + serializedName: 'etag', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = VirtualWAN; diff --git a/lib/services/networkManagement2/lib/models/vpnConnection.js b/lib/services/networkManagement2/lib/models/vpnConnection.js new file mode 100644 index 0000000000..7b6eac00b2 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/vpnConnection.js @@ -0,0 +1,199 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const models = require('./index'); + +/** + * VpnConnection Resource. + * + * @extends models['Resource'] + */ +class VpnConnection extends models['Resource'] { + /** + * Create a VpnConnection. + * @member {object} [remoteVpnSite] Id of the connected vpn site. + * @member {string} [remoteVpnSite.id] Resource ID. + * @member {number} [routingWeight] routing weight for vpn connection. + * @member {string} [connectionStatus] The connection status. Possible values + * include: 'Unknown', 'Connecting', 'Connected', 'NotConnected' + * @member {number} [ingressBytesTransferred] Ingress bytes transferred. + * @member {number} [egressBytesTransferred] Egress bytes transferred. + * @member {number} [connectionBandwidthInMbps] Expected bandwidth in MBPS. + * @member {string} [sharedKey] SharedKey for the vpn connection. + * @member {boolean} [enableBgp] EnableBgp flag + * @member {array} [ipsecPolicies] The IPSec Policies to be considered by + * this connection. + * @member {string} [provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * @member {string} [etag] Gets a unique read-only string that changes + * whenever the resource is updated. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of VpnConnection + * + * @returns {object} metadata of VpnConnection + * + */ + mapper() { + return { + required: false, + serializedName: 'VpnConnection', + type: { + name: 'Composite', + className: 'VpnConnection', + modelProperties: { + id: { + required: false, + serializedName: 'id', + type: { + name: 'String' + } + }, + name: { + required: false, + readOnly: true, + serializedName: 'name', + type: { + name: 'String' + } + }, + type: { + required: false, + readOnly: true, + serializedName: 'type', + type: { + name: 'String' + } + }, + location: { + required: false, + serializedName: 'location', + type: { + name: 'String' + } + }, + tags: { + required: false, + serializedName: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serializedName: 'StringElementType', + type: { + name: 'String' + } + } + } + }, + remoteVpnSite: { + required: false, + serializedName: 'properties.remoteVpnSite', + type: { + name: 'Composite', + className: 'SubResource' + } + }, + routingWeight: { + required: false, + serializedName: 'properties.routingWeight', + type: { + name: 'Number' + } + }, + connectionStatus: { + required: false, + serializedName: 'properties.connectionStatus', + type: { + name: 'String' + } + }, + ingressBytesTransferred: { + required: false, + readOnly: true, + serializedName: 'properties.ingressBytesTransferred', + type: { + name: 'Number' + } + }, + egressBytesTransferred: { + required: false, + readOnly: true, + serializedName: 'properties.egressBytesTransferred', + type: { + name: 'Number' + } + }, + connectionBandwidthInMbps: { + required: false, + readOnly: true, + serializedName: 'properties.connectionBandwidthInMbps', + type: { + name: 'Number' + } + }, + sharedKey: { + required: false, + serializedName: 'properties.sharedKey', + type: { + name: 'String' + } + }, + enableBgp: { + required: false, + serializedName: 'properties.enableBgp', + type: { + name: 'Boolean' + } + }, + ipsecPolicies: { + required: false, + serializedName: 'properties.ipsecPolicies', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'IpsecPolicyElementType', + type: { + name: 'Composite', + className: 'IpsecPolicy' + } + } + } + }, + provisioningState: { + required: false, + serializedName: 'properties.provisioningState', + type: { + name: 'String' + } + }, + etag: { + required: false, + readOnly: true, + serializedName: 'etag', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = VpnConnection; diff --git a/lib/services/networkManagement2/lib/models/vpnGateway.js b/lib/services/networkManagement2/lib/models/vpnGateway.js new file mode 100644 index 0000000000..574f18446e --- /dev/null +++ b/lib/services/networkManagement2/lib/models/vpnGateway.js @@ -0,0 +1,166 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const models = require('./index'); + +/** + * VpnGateway Resource. + * + * @extends models['Resource'] + */ +class VpnGateway extends models['Resource'] { + /** + * Create a VpnGateway. + * @member {object} [virtualHub] The VirtualHub to which the gateway belongs + * @member {string} [virtualHub.id] Resource ID. + * @member {array} [connections] list of all vpn connections to the gateway. + * @member {object} [bgpSettings] Local network gateway's BGP speaker + * settings. + * @member {number} [bgpSettings.asn] The BGP speaker's ASN. + * @member {string} [bgpSettings.bgpPeeringAddress] The BGP peering address + * and BGP identifier of this BGP speaker. + * @member {number} [bgpSettings.peerWeight] The weight added to routes + * learned from this BGP speaker. + * @member {string} [provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * @member {object} [policies] The policies applied to this vpn gateway. + * @member {boolean} [policies.allowBranchToBranchTraffic] True if branch to + * branch traffic is allowed. + * @member {boolean} [policies.allowVnetToVnetTraffic] True if Vnet to Vnet + * traffic is allowed. + * @member {string} [etag] Gets a unique read-only string that changes + * whenever the resource is updated. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of VpnGateway + * + * @returns {object} metadata of VpnGateway + * + */ + mapper() { + return { + required: false, + serializedName: 'VpnGateway', + type: { + name: 'Composite', + className: 'VpnGateway', + modelProperties: { + id: { + required: false, + serializedName: 'id', + type: { + name: 'String' + } + }, + name: { + required: false, + readOnly: true, + serializedName: 'name', + type: { + name: 'String' + } + }, + type: { + required: false, + readOnly: true, + serializedName: 'type', + type: { + name: 'String' + } + }, + location: { + required: false, + serializedName: 'location', + type: { + name: 'String' + } + }, + tags: { + required: false, + serializedName: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serializedName: 'StringElementType', + type: { + name: 'String' + } + } + } + }, + virtualHub: { + required: false, + serializedName: 'properties.virtualHub', + type: { + name: 'Composite', + className: 'SubResource' + } + }, + connections: { + required: false, + serializedName: 'properties.connections', + type: { + name: 'Sequence', + element: { + required: false, + serializedName: 'VpnConnectionElementType', + type: { + name: 'Composite', + className: 'VpnConnection' + } + } + } + }, + bgpSettings: { + required: false, + serializedName: 'properties.bgpSettings', + type: { + name: 'Composite', + className: 'BgpSettings' + } + }, + provisioningState: { + required: false, + serializedName: 'properties.provisioningState', + type: { + name: 'String' + } + }, + policies: { + required: false, + serializedName: 'properties.policies', + type: { + name: 'Composite', + className: 'Policies' + } + }, + etag: { + required: false, + readOnly: true, + serializedName: 'etag', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = VpnGateway; diff --git a/lib/services/networkManagement2/lib/models/vpnSite.js b/lib/services/networkManagement2/lib/models/vpnSite.js new file mode 100644 index 0000000000..c7dab1c028 --- /dev/null +++ b/lib/services/networkManagement2/lib/models/vpnSite.js @@ -0,0 +1,178 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const models = require('./index'); + +/** + * VpnSite Resource. + * + * @extends models['Resource'] + */ +class VpnSite extends models['Resource'] { + /** + * Create a VpnSite. + * @member {object} [virtualWAN] The VirtualWAN to which the vpnSite belongs + * @member {string} [virtualWAN.id] Resource ID. + * @member {object} [deviceProperties] The device properties + * @member {string} [deviceProperties.deviceVendor] Name of the device + * Vendor. + * @member {string} [deviceProperties.deviceModel] Model of the device. + * @member {number} [deviceProperties.linkSpeedInMbps] Link speed. + * @member {string} [ipAddress] The ip-address for the vpn-site. + * @member {string} [siteKey] The key for vpn-site that can be used for + * connections. + * @member {object} [addressSpace] The AddressSpace that contains an array of + * IP address ranges. + * @member {array} [addressSpace.addressPrefixes] A list of address blocks + * reserved for this virtual network in CIDR notation. + * @member {object} [bgpProperties] The set of bgp properties. + * @member {number} [bgpProperties.asn] The BGP speaker's ASN. + * @member {string} [bgpProperties.bgpPeeringAddress] The BGP peering address + * and BGP identifier of this BGP speaker. + * @member {number} [bgpProperties.peerWeight] The weight added to routes + * learned from this BGP speaker. + * @member {string} [provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * @member {string} [etag] Gets a unique read-only string that changes + * whenever the resource is updated. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of VpnSite + * + * @returns {object} metadata of VpnSite + * + */ + mapper() { + return { + required: false, + serializedName: 'VpnSite', + type: { + name: 'Composite', + className: 'VpnSite', + modelProperties: { + id: { + required: false, + serializedName: 'id', + type: { + name: 'String' + } + }, + name: { + required: false, + readOnly: true, + serializedName: 'name', + type: { + name: 'String' + } + }, + type: { + required: false, + readOnly: true, + serializedName: 'type', + type: { + name: 'String' + } + }, + location: { + required: false, + serializedName: 'location', + type: { + name: 'String' + } + }, + tags: { + required: false, + serializedName: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serializedName: 'StringElementType', + type: { + name: 'String' + } + } + } + }, + virtualWAN: { + required: false, + serializedName: 'properties.virtualWAN', + type: { + name: 'Composite', + className: 'SubResource' + } + }, + deviceProperties: { + required: false, + serializedName: 'properties.deviceProperties', + type: { + name: 'Composite', + className: 'DeviceProperties' + } + }, + ipAddress: { + required: false, + serializedName: 'properties.ipAddress', + type: { + name: 'String' + } + }, + siteKey: { + required: false, + serializedName: 'properties.siteKey', + type: { + name: 'String' + } + }, + addressSpace: { + required: false, + serializedName: 'properties.addressSpace', + type: { + name: 'Composite', + className: 'AddressSpace' + } + }, + bgpProperties: { + required: false, + serializedName: 'properties.bgpProperties', + type: { + name: 'Composite', + className: 'BgpSettings' + } + }, + provisioningState: { + required: false, + serializedName: 'properties.provisioningState', + type: { + name: 'String' + } + }, + etag: { + required: false, + readOnly: true, + serializedName: 'etag', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = VpnSite; diff --git a/lib/services/networkManagement2/lib/models/vpnSiteId.js b/lib/services/networkManagement2/lib/models/vpnSiteId.js new file mode 100644 index 0000000000..f00971195c --- /dev/null +++ b/lib/services/networkManagement2/lib/models/vpnSiteId.js @@ -0,0 +1,54 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +/** + * VpnSite Resource. + * + */ +class VpnSiteId { + /** + * Create a VpnSiteId. + * @member {string} [vpnSite] The resource-uri of the vpn-site for which + * config is to be fetched. + */ + constructor() { + } + + /** + * Defines the metadata of VpnSiteId + * + * @returns {object} metadata of VpnSiteId + * + */ + mapper() { + return { + required: false, + serializedName: 'VpnSiteId', + type: { + name: 'Composite', + className: 'VpnSiteId', + modelProperties: { + vpnSite: { + required: false, + readOnly: true, + serializedName: 'vpnSite', + type: { + name: 'String' + } + } + } + } + }; + } +} + +module.exports = VpnSiteId; diff --git a/lib/services/networkManagement2/lib/networkManagementClient.d.ts b/lib/services/networkManagement2/lib/networkManagementClient.d.ts index 9286c83139..cf9957940c 100644 --- a/lib/services/networkManagement2/lib/networkManagementClient.d.ts +++ b/lib/services/networkManagement2/lib/networkManagementClient.d.ts @@ -47,8 +47,6 @@ export default class NetworkManagementClient extends AzureServiceClient { subscriptionId: string; - apiVersion: string; - acceptLanguage: string; longRunningOperationRetryTimeout: number; @@ -56,6 +54,7 @@ export default class NetworkManagementClient extends AzureServiceClient { generateClientRequestId: boolean; // Operation groups + azureFirewalls: operations.AzureFirewalls; applicationGateways: operations.ApplicationGateways; applicationSecurityGroups: operations.ApplicationSecurityGroups; ddosProtectionPlans: operations.DdosProtectionPlans; @@ -97,6 +96,13 @@ export default class NetworkManagementClient extends AzureServiceClient { virtualNetworkGateways: operations.VirtualNetworkGateways; virtualNetworkGatewayConnections: operations.VirtualNetworkGatewayConnections; localNetworkGateways: operations.LocalNetworkGateways; + virtualWANs: operations.VirtualWANs; + vpnSites: operations.VpnSites; + vpnSitesConfiguration: operations.VpnSitesConfiguration; + virtualHubs: operations.VirtualHubs; + hubVirtualNetworkConnections: operations.HubVirtualNetworkConnections; + vpnGateways: operations.VpnGateways; + vpnConnections: operations.VpnConnections; /** diff --git a/lib/services/networkManagement2/lib/networkManagementClient.js b/lib/services/networkManagement2/lib/networkManagementClient.js index 77e297060f..ca18387784 100644 --- a/lib/services/networkManagement2/lib/networkManagementClient.js +++ b/lib/services/networkManagement2/lib/networkManagementClient.js @@ -61,6 +61,7 @@ function _checkDnsNameAvailability(location, domainNameLabel, options, callback) if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (location === null || location === undefined || typeof location.valueOf() !== 'string') { @@ -69,9 +70,6 @@ function _checkDnsNameAvailability(location, domainNameLabel, options, callback) if (domainNameLabel === null || domainNameLabel === undefined || typeof domainNameLabel.valueOf() !== 'string') { throw new Error('domainNameLabel cannot be null or undefined and it must be of type string.'); } - if (this.apiVersion === null || this.apiVersion === undefined || typeof this.apiVersion.valueOf() !== 'string') { - throw new Error('this.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.subscriptionId === null || this.subscriptionId === undefined || typeof this.subscriptionId.valueOf() !== 'string') { throw new Error('this.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -89,7 +87,7 @@ function _checkDnsNameAvailability(location, domainNameLabel, options, callback) requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.subscriptionId)); let queryParameters = []; queryParameters.push('domainNameLabel=' + encodeURIComponent(domainNameLabel)); - queryParameters.push('api-version=' + encodeURIComponent(this.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -199,7 +197,6 @@ class NetworkManagementClient extends ServiceClient { super(credentials, options); - this.apiVersion = '2018-02-01'; this.acceptLanguage = 'en-US'; this.longRunningOperationRetryTimeout = 30; this.generateClientRequestId = true; @@ -221,6 +218,7 @@ class NetworkManagementClient extends ServiceClient { if(options.generateClientRequestId !== null && options.generateClientRequestId !== undefined) { this.generateClientRequestId = options.generateClientRequestId; } + this.azureFirewalls = new operations.AzureFirewalls(this); this.applicationGateways = new operations.ApplicationGateways(this); this.applicationSecurityGroups = new operations.ApplicationSecurityGroups(this); this.ddosProtectionPlans = new operations.DdosProtectionPlans(this); @@ -262,6 +260,13 @@ class NetworkManagementClient extends ServiceClient { this.virtualNetworkGateways = new operations.VirtualNetworkGateways(this); this.virtualNetworkGatewayConnections = new operations.VirtualNetworkGatewayConnections(this); this.localNetworkGateways = new operations.LocalNetworkGateways(this); + this.virtualWANs = new operations.VirtualWANs(this); + this.vpnSites = new operations.VpnSites(this); + this.vpnSitesConfiguration = new operations.VpnSitesConfiguration(this); + this.virtualHubs = new operations.VirtualHubs(this); + this.hubVirtualNetworkConnections = new operations.HubVirtualNetworkConnections(this); + this.vpnGateways = new operations.VpnGateways(this); + this.vpnConnections = new operations.VpnConnections(this); this.models = models; this._checkDnsNameAvailability = _checkDnsNameAvailability; msRest.addSerializationMixin(this); diff --git a/lib/services/networkManagement2/lib/operations/applicationGateways.js b/lib/services/networkManagement2/lib/operations/applicationGateways.js index fd66cf450b..278254c9c6 100644 --- a/lib/services/networkManagement2/lib/operations/applicationGateways.js +++ b/lib/services/networkManagement2/lib/operations/applicationGateways.js @@ -112,6 +112,7 @@ function _get(resourceGroupName, applicationGatewayName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -120,9 +121,6 @@ function _get(resourceGroupName, applicationGatewayName, options, callback) { if (applicationGatewayName === null || applicationGatewayName === undefined || typeof applicationGatewayName.valueOf() !== 'string') { throw new Error('applicationGatewayName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -140,7 +138,7 @@ function _get(resourceGroupName, applicationGatewayName, options, callback) { requestUrl = requestUrl.replace('{applicationGatewayName}', encodeURIComponent(applicationGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -237,10 +235,10 @@ function _get(resourceGroupName, applicationGatewayName, options, callback) { * * @param {string} [parameters.sku.name] Name of an application gateway SKU. * Possible values include: 'Standard_Small', 'Standard_Medium', - * 'Standard_Large', 'WAF_Medium', 'WAF_Large' + * 'Standard_Large', 'WAF_Medium', 'WAF_Large', 'Standard_v2', 'WAF_v2' * * @param {string} [parameters.sku.tier] Tier of an application gateway. - * Possible values include: 'Standard', 'WAF' + * Possible values include: 'Standard', 'WAF', 'Standard_v2', 'WAF_v2' * * @param {number} [parameters.sku.capacity] Capacity (instance count) of an * application gateway. @@ -334,6 +332,19 @@ function _get(resourceGroupName, applicationGatewayName, options, callback) { * @param {boolean} [parameters.enableHttp2] Whether HTTP2 is enabled on the * application gateway resource. * + * @param {boolean} [parameters.enableFips] Whether FIPS is enabled on the + * application gateway resource. + * + * @param {object} [parameters.autoscaleConfiguration] Autoscale Configuration. + * + * @param {object} parameters.autoscaleConfiguration.bounds Autoscale bounds + * + * @param {number} parameters.autoscaleConfiguration.bounds.min Lower bound on + * number of Application Gateway instances. + * + * @param {number} parameters.autoscaleConfiguration.bounds.max Upper bound on + * number of Application Gateway instances. + * * @param {string} [parameters.resourceGuid] Resource GUID property of the * application gateway resource. * @@ -344,6 +355,9 @@ function _get(resourceGroupName, applicationGatewayName, options, callback) { * @param {string} [parameters.etag] A unique read-only string that changes * whenever the resource is updated. * + * @param {array} [parameters.zones] A list of availability zones denoting + * where the resource needs to come from. + * * @param {string} [parameters.id] Resource ID. * * @param {string} [parameters.location] Resource location. @@ -537,14 +551,12 @@ function _list(resourceGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -561,7 +573,7 @@ function _list(resourceGroupName, options, callback) { requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -675,11 +687,9 @@ function _listAll(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -695,7 +705,7 @@ function _listAll(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/applicationGateways'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1019,11 +1029,9 @@ function _listAvailableWafRuleSets(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1039,7 +1047,7 @@ function _listAvailableWafRuleSets(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/applicationGatewayAvailableWafRuleSets'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1153,11 +1161,9 @@ function _listAvailableSslOptions(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1173,7 +1179,7 @@ function _listAvailableSslOptions(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/applicationGatewayAvailableSslOptions/default'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1288,11 +1294,9 @@ function _listAvailableSslPredefinedPolicies(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1308,7 +1312,7 @@ function _listAvailableSslPredefinedPolicies(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/applicationGatewayAvailableSslOptions/default/predefinedPolicies'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1424,11 +1428,9 @@ function _getSslPredefinedPolicy(predefinedPolicyName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1448,7 +1450,7 @@ function _getSslPredefinedPolicy(predefinedPolicyName, options, callback) { requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); requestUrl = requestUrl.replace('{predefinedPolicyName}', encodeURIComponent(predefinedPolicyName)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1564,6 +1566,7 @@ function _beginDeleteMethod(resourceGroupName, applicationGatewayName, options, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1572,9 +1575,6 @@ function _beginDeleteMethod(resourceGroupName, applicationGatewayName, options, if (applicationGatewayName === null || applicationGatewayName === undefined || typeof applicationGatewayName.valueOf() !== 'string') { throw new Error('applicationGatewayName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1592,7 +1592,7 @@ function _beginDeleteMethod(resourceGroupName, applicationGatewayName, options, requestUrl = requestUrl.replace('{applicationGatewayName}', encodeURIComponent(applicationGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1671,10 +1671,10 @@ function _beginDeleteMethod(resourceGroupName, applicationGatewayName, options, * * @param {string} [parameters.sku.name] Name of an application gateway SKU. * Possible values include: 'Standard_Small', 'Standard_Medium', - * 'Standard_Large', 'WAF_Medium', 'WAF_Large' + * 'Standard_Large', 'WAF_Medium', 'WAF_Large', 'Standard_v2', 'WAF_v2' * * @param {string} [parameters.sku.tier] Tier of an application gateway. - * Possible values include: 'Standard', 'WAF' + * Possible values include: 'Standard', 'WAF', 'Standard_v2', 'WAF_v2' * * @param {number} [parameters.sku.capacity] Capacity (instance count) of an * application gateway. @@ -1768,6 +1768,19 @@ function _beginDeleteMethod(resourceGroupName, applicationGatewayName, options, * @param {boolean} [parameters.enableHttp2] Whether HTTP2 is enabled on the * application gateway resource. * + * @param {boolean} [parameters.enableFips] Whether FIPS is enabled on the + * application gateway resource. + * + * @param {object} [parameters.autoscaleConfiguration] Autoscale Configuration. + * + * @param {object} parameters.autoscaleConfiguration.bounds Autoscale bounds + * + * @param {number} parameters.autoscaleConfiguration.bounds.min Lower bound on + * number of Application Gateway instances. + * + * @param {number} parameters.autoscaleConfiguration.bounds.max Upper bound on + * number of Application Gateway instances. + * * @param {string} [parameters.resourceGuid] Resource GUID property of the * application gateway resource. * @@ -1778,6 +1791,9 @@ function _beginDeleteMethod(resourceGroupName, applicationGatewayName, options, * @param {string} [parameters.etag] A unique read-only string that changes * whenever the resource is updated. * + * @param {array} [parameters.zones] A list of availability zones denoting + * where the resource needs to come from. + * * @param {string} [parameters.id] Resource ID. * * @param {string} [parameters.location] Resource location. @@ -1812,6 +1828,7 @@ function _beginCreateOrUpdate(resourceGroupName, applicationGatewayName, paramet if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1823,9 +1840,6 @@ function _beginCreateOrUpdate(resourceGroupName, applicationGatewayName, paramet if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1843,7 +1857,7 @@ function _beginCreateOrUpdate(resourceGroupName, applicationGatewayName, paramet requestUrl = requestUrl.replace('{applicationGatewayName}', encodeURIComponent(applicationGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1996,6 +2010,7 @@ function _beginUpdateTags(resourceGroupName, applicationGatewayName, parameters, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2007,9 +2022,6 @@ function _beginUpdateTags(resourceGroupName, applicationGatewayName, parameters, if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2027,7 +2039,7 @@ function _beginUpdateTags(resourceGroupName, applicationGatewayName, parameters, requestUrl = requestUrl.replace('{applicationGatewayName}', encodeURIComponent(applicationGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2157,6 +2169,7 @@ function _beginStart(resourceGroupName, applicationGatewayName, options, callbac if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2165,9 +2178,6 @@ function _beginStart(resourceGroupName, applicationGatewayName, options, callbac if (applicationGatewayName === null || applicationGatewayName === undefined || typeof applicationGatewayName.valueOf() !== 'string') { throw new Error('applicationGatewayName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2185,7 +2195,7 @@ function _beginStart(resourceGroupName, applicationGatewayName, options, callbac requestUrl = requestUrl.replace('{applicationGatewayName}', encodeURIComponent(applicationGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2284,6 +2294,7 @@ function _beginStop(resourceGroupName, applicationGatewayName, options, callback if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2292,9 +2303,6 @@ function _beginStop(resourceGroupName, applicationGatewayName, options, callback if (applicationGatewayName === null || applicationGatewayName === undefined || typeof applicationGatewayName.valueOf() !== 'string') { throw new Error('applicationGatewayName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2312,7 +2320,7 @@ function _beginStop(resourceGroupName, applicationGatewayName, options, callback requestUrl = requestUrl.replace('{applicationGatewayName}', encodeURIComponent(applicationGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2418,6 +2426,7 @@ function _beginBackendHealth(resourceGroupName, applicationGatewayName, options, throw new Error('callback cannot be null.'); } let expand = (options && options.expand !== undefined) ? options.expand : undefined; + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2426,9 +2435,6 @@ function _beginBackendHealth(resourceGroupName, applicationGatewayName, options, if (applicationGatewayName === null || applicationGatewayName === undefined || typeof applicationGatewayName.valueOf() !== 'string') { throw new Error('applicationGatewayName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2449,7 +2455,7 @@ function _beginBackendHealth(resourceGroupName, applicationGatewayName, options, requestUrl = requestUrl.replace('{applicationGatewayName}', encodeURIComponent(applicationGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (expand !== null && expand !== undefined) { queryParameters.push('$expand=' + encodeURIComponent(expand)); } @@ -3136,10 +3142,10 @@ class ApplicationGateways { * * @param {string} [parameters.sku.name] Name of an application gateway SKU. * Possible values include: 'Standard_Small', 'Standard_Medium', - * 'Standard_Large', 'WAF_Medium', 'WAF_Large' + * 'Standard_Large', 'WAF_Medium', 'WAF_Large', 'Standard_v2', 'WAF_v2' * * @param {string} [parameters.sku.tier] Tier of an application gateway. - * Possible values include: 'Standard', 'WAF' + * Possible values include: 'Standard', 'WAF', 'Standard_v2', 'WAF_v2' * * @param {number} [parameters.sku.capacity] Capacity (instance count) of an * application gateway. @@ -3233,6 +3239,19 @@ class ApplicationGateways { * @param {boolean} [parameters.enableHttp2] Whether HTTP2 is enabled on the * application gateway resource. * + * @param {boolean} [parameters.enableFips] Whether FIPS is enabled on the + * application gateway resource. + * + * @param {object} [parameters.autoscaleConfiguration] Autoscale Configuration. + * + * @param {object} parameters.autoscaleConfiguration.bounds Autoscale bounds + * + * @param {number} parameters.autoscaleConfiguration.bounds.min Lower bound on + * number of Application Gateway instances. + * + * @param {number} parameters.autoscaleConfiguration.bounds.max Upper bound on + * number of Application Gateway instances. + * * @param {string} [parameters.resourceGuid] Resource GUID property of the * application gateway resource. * @@ -3243,6 +3262,9 @@ class ApplicationGateways { * @param {string} [parameters.etag] A unique read-only string that changes * whenever the resource is updated. * + * @param {array} [parameters.zones] A list of availability zones denoting + * where the resource needs to come from. + * * @param {string} [parameters.id] Resource ID. * * @param {string} [parameters.location] Resource location. @@ -3288,10 +3310,10 @@ class ApplicationGateways { * * @param {string} [parameters.sku.name] Name of an application gateway SKU. * Possible values include: 'Standard_Small', 'Standard_Medium', - * 'Standard_Large', 'WAF_Medium', 'WAF_Large' + * 'Standard_Large', 'WAF_Medium', 'WAF_Large', 'Standard_v2', 'WAF_v2' * * @param {string} [parameters.sku.tier] Tier of an application gateway. - * Possible values include: 'Standard', 'WAF' + * Possible values include: 'Standard', 'WAF', 'Standard_v2', 'WAF_v2' * * @param {number} [parameters.sku.capacity] Capacity (instance count) of an * application gateway. @@ -3385,6 +3407,19 @@ class ApplicationGateways { * @param {boolean} [parameters.enableHttp2] Whether HTTP2 is enabled on the * application gateway resource. * + * @param {boolean} [parameters.enableFips] Whether FIPS is enabled on the + * application gateway resource. + * + * @param {object} [parameters.autoscaleConfiguration] Autoscale Configuration. + * + * @param {object} parameters.autoscaleConfiguration.bounds Autoscale bounds + * + * @param {number} parameters.autoscaleConfiguration.bounds.min Lower bound on + * number of Application Gateway instances. + * + * @param {number} parameters.autoscaleConfiguration.bounds.max Upper bound on + * number of Application Gateway instances. + * * @param {string} [parameters.resourceGuid] Resource GUID property of the * application gateway resource. * @@ -3395,6 +3430,9 @@ class ApplicationGateways { * @param {string} [parameters.etag] A unique read-only string that changes * whenever the resource is updated. * + * @param {array} [parameters.zones] A list of availability zones denoting + * where the resource needs to come from. + * * @param {string} [parameters.id] Resource ID. * * @param {string} [parameters.location] Resource location. @@ -4392,10 +4430,10 @@ class ApplicationGateways { * * @param {string} [parameters.sku.name] Name of an application gateway SKU. * Possible values include: 'Standard_Small', 'Standard_Medium', - * 'Standard_Large', 'WAF_Medium', 'WAF_Large' + * 'Standard_Large', 'WAF_Medium', 'WAF_Large', 'Standard_v2', 'WAF_v2' * * @param {string} [parameters.sku.tier] Tier of an application gateway. - * Possible values include: 'Standard', 'WAF' + * Possible values include: 'Standard', 'WAF', 'Standard_v2', 'WAF_v2' * * @param {number} [parameters.sku.capacity] Capacity (instance count) of an * application gateway. @@ -4489,6 +4527,19 @@ class ApplicationGateways { * @param {boolean} [parameters.enableHttp2] Whether HTTP2 is enabled on the * application gateway resource. * + * @param {boolean} [parameters.enableFips] Whether FIPS is enabled on the + * application gateway resource. + * + * @param {object} [parameters.autoscaleConfiguration] Autoscale Configuration. + * + * @param {object} parameters.autoscaleConfiguration.bounds Autoscale bounds + * + * @param {number} parameters.autoscaleConfiguration.bounds.min Lower bound on + * number of Application Gateway instances. + * + * @param {number} parameters.autoscaleConfiguration.bounds.max Upper bound on + * number of Application Gateway instances. + * * @param {string} [parameters.resourceGuid] Resource GUID property of the * application gateway resource. * @@ -4499,6 +4550,9 @@ class ApplicationGateways { * @param {string} [parameters.etag] A unique read-only string that changes * whenever the resource is updated. * + * @param {array} [parameters.zones] A list of availability zones denoting + * where the resource needs to come from. + * * @param {string} [parameters.id] Resource ID. * * @param {string} [parameters.location] Resource location. @@ -4544,10 +4598,10 @@ class ApplicationGateways { * * @param {string} [parameters.sku.name] Name of an application gateway SKU. * Possible values include: 'Standard_Small', 'Standard_Medium', - * 'Standard_Large', 'WAF_Medium', 'WAF_Large' + * 'Standard_Large', 'WAF_Medium', 'WAF_Large', 'Standard_v2', 'WAF_v2' * * @param {string} [parameters.sku.tier] Tier of an application gateway. - * Possible values include: 'Standard', 'WAF' + * Possible values include: 'Standard', 'WAF', 'Standard_v2', 'WAF_v2' * * @param {number} [parameters.sku.capacity] Capacity (instance count) of an * application gateway. @@ -4641,6 +4695,19 @@ class ApplicationGateways { * @param {boolean} [parameters.enableHttp2] Whether HTTP2 is enabled on the * application gateway resource. * + * @param {boolean} [parameters.enableFips] Whether FIPS is enabled on the + * application gateway resource. + * + * @param {object} [parameters.autoscaleConfiguration] Autoscale Configuration. + * + * @param {object} parameters.autoscaleConfiguration.bounds Autoscale bounds + * + * @param {number} parameters.autoscaleConfiguration.bounds.min Lower bound on + * number of Application Gateway instances. + * + * @param {number} parameters.autoscaleConfiguration.bounds.max Upper bound on + * number of Application Gateway instances. + * * @param {string} [parameters.resourceGuid] Resource GUID property of the * application gateway resource. * @@ -4651,6 +4718,9 @@ class ApplicationGateways { * @param {string} [parameters.etag] A unique read-only string that changes * whenever the resource is updated. * + * @param {array} [parameters.zones] A list of availability zones denoting + * where the resource needs to come from. + * * @param {string} [parameters.id] Resource ID. * * @param {string} [parameters.location] Resource location. diff --git a/lib/services/networkManagement2/lib/operations/applicationSecurityGroups.js b/lib/services/networkManagement2/lib/operations/applicationSecurityGroups.js index e72d672519..77b7f72550 100644 --- a/lib/services/networkManagement2/lib/operations/applicationSecurityGroups.js +++ b/lib/services/networkManagement2/lib/operations/applicationSecurityGroups.js @@ -115,6 +115,7 @@ function _get(resourceGroupName, applicationSecurityGroupName, options, callback if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -123,9 +124,6 @@ function _get(resourceGroupName, applicationSecurityGroupName, options, callback if (applicationSecurityGroupName === null || applicationSecurityGroupName === undefined || typeof applicationSecurityGroupName.valueOf() !== 'string') { throw new Error('applicationSecurityGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -143,7 +141,7 @@ function _get(resourceGroupName, applicationSecurityGroupName, options, callback requestUrl = requestUrl.replace('{applicationSecurityGroupName}', encodeURIComponent(applicationSecurityGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -346,11 +344,9 @@ function _listAll(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -366,7 +362,7 @@ function _listAll(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/applicationSecurityGroups'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -482,14 +478,12 @@ function _list(resourceGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -506,7 +500,7 @@ function _list(resourceGroupName, options, callback) { requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -623,6 +617,7 @@ function _beginDeleteMethod(resourceGroupName, applicationSecurityGroupName, opt if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -631,9 +626,6 @@ function _beginDeleteMethod(resourceGroupName, applicationSecurityGroupName, opt if (applicationSecurityGroupName === null || applicationSecurityGroupName === undefined || typeof applicationSecurityGroupName.valueOf() !== 'string') { throw new Error('applicationSecurityGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -651,7 +643,7 @@ function _beginDeleteMethod(resourceGroupName, applicationSecurityGroupName, opt requestUrl = requestUrl.replace('{applicationSecurityGroupName}', encodeURIComponent(applicationSecurityGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -762,6 +754,7 @@ function _beginCreateOrUpdate(resourceGroupName, applicationSecurityGroupName, p if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -773,9 +766,6 @@ function _beginCreateOrUpdate(resourceGroupName, applicationSecurityGroupName, p if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -793,7 +783,7 @@ function _beginCreateOrUpdate(resourceGroupName, applicationSecurityGroupName, p requestUrl = requestUrl.replace('{applicationSecurityGroupName}', encodeURIComponent(applicationSecurityGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/availableEndpointServices.js b/lib/services/networkManagement2/lib/operations/availableEndpointServices.js index e4a6dec6fd..5e0f85f9a8 100644 --- a/lib/services/networkManagement2/lib/operations/availableEndpointServices.js +++ b/lib/services/networkManagement2/lib/operations/availableEndpointServices.js @@ -48,14 +48,12 @@ function _list(location, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (location === null || location === undefined || typeof location.valueOf() !== 'string') { throw new Error('location cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -72,7 +70,7 @@ function _list(location, options, callback) { requestUrl = requestUrl.replace('{location}', encodeURIComponent(location)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/azureFirewalls.js b/lib/services/networkManagement2/lib/operations/azureFirewalls.js new file mode 100644 index 0000000000..792f6a1462 --- /dev/null +++ b/lib/services/networkManagement2/lib/operations/azureFirewalls.js @@ -0,0 +1,2042 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const msRest = require('ms-rest'); +const msRestAzure = require('ms-rest-azure'); +const WebResource = msRest.WebResource; + + +/** + * Deletes the specified Azure Firewall. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} azureFirewallName The name of the Azure Firewall. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _deleteMethod(resourceGroupName, azureFirewallName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginDeleteMethod(resourceGroupName, azureFirewallName, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + + return callback(null, result, httpRequest, response); + }); + }); +} + +/** + * Gets the specified Azure Firewall. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} azureFirewallName The name of the Azure Firewall. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewall} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _get(resourceGroupName, azureFirewallName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (azureFirewallName === null || azureFirewallName === undefined || typeof azureFirewallName.valueOf() !== 'string') { + throw new Error('azureFirewallName cannot be null or undefined and it must be of type string.'); + } + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/azureFirewalls/{azureFirewallName}'; + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{azureFirewallName}', encodeURIComponent(azureFirewallName)); + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + if (parsedErrorResponse.error) parsedErrorResponse = parsedErrorResponse.error; + if (parsedErrorResponse.code) error.code = parsedErrorResponse.code; + if (parsedErrorResponse.message) error.message = parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['CloudError']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['AzureFirewall']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + + +/** + * Creates or updates the specified Azure Firewall. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} azureFirewallName The name of the Azure Firewall. + * + * @param {object} parameters Parameters supplied to the create or update Azure + * Firewall operation. + * + * @param {array} [parameters.applicationRuleCollections] Collection of + * application rule collections used by a Azure Firewall. + * + * @param {array} [parameters.networkRuleCollections] Collection of network + * rule collections used by a Azure Firewall. + * + * @param {array} [parameters.ipConfigurations] IP configuration of the Azure + * Firewall resource. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewall} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _createOrUpdate(resourceGroupName, azureFirewallName, parameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginCreateOrUpdate(resourceGroupName, azureFirewallName, parameters, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['AzureFirewall']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + + return callback(null, result, httpRequest, response); + }); + }); +} + +/** + * Lists all Azure Firewalls in a resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewallListResult} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _list(resourceGroupName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/azureFirewalls'; + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + if (parsedErrorResponse.error) parsedErrorResponse = parsedErrorResponse.error; + if (parsedErrorResponse.code) error.code = parsedErrorResponse.code; + if (parsedErrorResponse.message) error.message = parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['CloudError']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['AzureFirewallListResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Gets all the Azure Firewalls in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewallListResult} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listAll(options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/azureFirewalls'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + if (parsedErrorResponse.error) parsedErrorResponse = parsedErrorResponse.error; + if (parsedErrorResponse.code) error.code = parsedErrorResponse.code; + if (parsedErrorResponse.message) error.message = parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['CloudError']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['AzureFirewallListResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Deletes the specified Azure Firewall. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} azureFirewallName The name of the Azure Firewall. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginDeleteMethod(resourceGroupName, azureFirewallName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (azureFirewallName === null || azureFirewallName === undefined || typeof azureFirewallName.valueOf() !== 'string') { + throw new Error('azureFirewallName cannot be null or undefined and it must be of type string.'); + } + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/azureFirewalls/{azureFirewallName}'; + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{azureFirewallName}', encodeURIComponent(azureFirewallName)); + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'DELETE'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 202 && statusCode !== 204) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + if (parsedErrorResponse.error) parsedErrorResponse = parsedErrorResponse.error; + if (parsedErrorResponse.code) error.code = parsedErrorResponse.code; + if (parsedErrorResponse.message) error.message = parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['CloudError']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Creates or updates the specified Azure Firewall. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} azureFirewallName The name of the Azure Firewall. + * + * @param {object} parameters Parameters supplied to the create or update Azure + * Firewall operation. + * + * @param {array} [parameters.applicationRuleCollections] Collection of + * application rule collections used by a Azure Firewall. + * + * @param {array} [parameters.networkRuleCollections] Collection of network + * rule collections used by a Azure Firewall. + * + * @param {array} [parameters.ipConfigurations] IP configuration of the Azure + * Firewall resource. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewall} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginCreateOrUpdate(resourceGroupName, azureFirewallName, parameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (azureFirewallName === null || azureFirewallName === undefined || typeof azureFirewallName.valueOf() !== 'string') { + throw new Error('azureFirewallName cannot be null or undefined and it must be of type string.'); + } + if (parameters === null || parameters === undefined) { + throw new Error('parameters cannot be null or undefined.'); + } + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/azureFirewalls/{azureFirewallName}'; + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{azureFirewallName}', encodeURIComponent(azureFirewallName)); + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'PUT'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + // Serialize Request + let requestContent = null; + let requestModel = null; + try { + if (parameters !== null && parameters !== undefined) { + let requestModelMapper = new client.models['AzureFirewall']().mapper(); + requestModel = client.serialize(requestModelMapper, parameters, 'parameters'); + requestContent = JSON.stringify(requestModel); + } + } catch (error) { + let serializationError = new Error(`Error "${error.message}" occurred in serializing the ` + + `payload - ${JSON.stringify(parameters, null, 2)}.`); + return callback(serializationError); + } + httpRequest.body = requestContent; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 201) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + if (parsedErrorResponse.error) parsedErrorResponse = parsedErrorResponse.error; + if (parsedErrorResponse.code) error.code = parsedErrorResponse.code; + if (parsedErrorResponse.message) error.message = parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['CloudError']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['AzureFirewall']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + // Deserialize Response + if (statusCode === 201) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['AzureFirewall']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError1 = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError1.request = msRest.stripRequest(httpRequest); + deserializationError1.response = msRest.stripResponse(response); + return callback(deserializationError1); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Lists all Azure Firewalls in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewallListResult} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listNext(nextPageLink, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + // Validate + try { + if (nextPageLink === null || nextPageLink === undefined || typeof nextPageLink.valueOf() !== 'string') { + throw new Error('nextPageLink cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let requestUrl = '{nextLink}'; + requestUrl = requestUrl.replace('{nextLink}', nextPageLink); + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + if (parsedErrorResponse.error) parsedErrorResponse = parsedErrorResponse.error; + if (parsedErrorResponse.code) error.code = parsedErrorResponse.code; + if (parsedErrorResponse.message) error.message = parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['CloudError']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['AzureFirewallListResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Gets all the Azure Firewalls in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewallListResult} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listAllNext(nextPageLink, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + // Validate + try { + if (nextPageLink === null || nextPageLink === undefined || typeof nextPageLink.valueOf() !== 'string') { + throw new Error('nextPageLink cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let requestUrl = '{nextLink}'; + requestUrl = requestUrl.replace('{nextLink}', nextPageLink); + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + if (parsedErrorResponse.error) parsedErrorResponse = parsedErrorResponse.error; + if (parsedErrorResponse.code) error.code = parsedErrorResponse.code; + if (parsedErrorResponse.message) error.message = parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['CloudError']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['AzureFirewallListResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** Class representing a AzureFirewalls. */ +class AzureFirewalls { + /** + * Create a AzureFirewalls. + * @param {NetworkManagementClient} client Reference to the service client. + */ + constructor(client) { + this.client = client; + this._deleteMethod = _deleteMethod; + this._get = _get; + this._createOrUpdate = _createOrUpdate; + this._list = _list; + this._listAll = _listAll; + this._beginDeleteMethod = _beginDeleteMethod; + this._beginCreateOrUpdate = _beginCreateOrUpdate; + this._listNext = _listNext; + this._listAllNext = _listAllNext; + } + + /** + * Deletes the specified Azure Firewall. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} azureFirewallName The name of the Azure Firewall. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + deleteMethodWithHttpOperationResponse(resourceGroupName, azureFirewallName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._deleteMethod(resourceGroupName, azureFirewallName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Deletes the specified Azure Firewall. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} azureFirewallName The name of the Azure Firewall. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + deleteMethod(resourceGroupName, azureFirewallName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._deleteMethod(resourceGroupName, azureFirewallName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._deleteMethod(resourceGroupName, azureFirewallName, options, optionalCallback); + } + } + + /** + * Gets the specified Azure Firewall. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} azureFirewallName The name of the Azure Firewall. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName, azureFirewallName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._get(resourceGroupName, azureFirewallName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Gets the specified Azure Firewall. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} azureFirewallName The name of the Azure Firewall. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {AzureFirewall} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewall} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName, azureFirewallName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._get(resourceGroupName, azureFirewallName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._get(resourceGroupName, azureFirewallName, options, optionalCallback); + } + } + + /** + * Creates or updates the specified Azure Firewall. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} azureFirewallName The name of the Azure Firewall. + * + * @param {object} parameters Parameters supplied to the create or update Azure + * Firewall operation. + * + * @param {array} [parameters.applicationRuleCollections] Collection of + * application rule collections used by a Azure Firewall. + * + * @param {array} [parameters.networkRuleCollections] Collection of network + * rule collections used by a Azure Firewall. + * + * @param {array} [parameters.ipConfigurations] IP configuration of the Azure + * Firewall resource. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName, azureFirewallName, parameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._createOrUpdate(resourceGroupName, azureFirewallName, parameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Creates or updates the specified Azure Firewall. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} azureFirewallName The name of the Azure Firewall. + * + * @param {object} parameters Parameters supplied to the create or update Azure + * Firewall operation. + * + * @param {array} [parameters.applicationRuleCollections] Collection of + * application rule collections used by a Azure Firewall. + * + * @param {array} [parameters.networkRuleCollections] Collection of network + * rule collections used by a Azure Firewall. + * + * @param {array} [parameters.ipConfigurations] IP configuration of the Azure + * Firewall resource. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {AzureFirewall} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewall} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName, azureFirewallName, parameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._createOrUpdate(resourceGroupName, azureFirewallName, parameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._createOrUpdate(resourceGroupName, azureFirewallName, parameters, options, optionalCallback); + } + } + + /** + * Lists all Azure Firewalls in a resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listWithHttpOperationResponse(resourceGroupName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._list(resourceGroupName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all Azure Firewalls in a resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {AzureFirewallListResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewallListResult} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + list(resourceGroupName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._list(resourceGroupName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._list(resourceGroupName, options, optionalCallback); + } + } + + /** + * Gets all the Azure Firewalls in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listAllWithHttpOperationResponse(options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listAll(options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Gets all the Azure Firewalls in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {AzureFirewallListResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewallListResult} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listAll(options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listAll(options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listAll(options, optionalCallback); + } + } + + /** + * Deletes the specified Azure Firewall. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} azureFirewallName The name of the Azure Firewall. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginDeleteMethodWithHttpOperationResponse(resourceGroupName, azureFirewallName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginDeleteMethod(resourceGroupName, azureFirewallName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Deletes the specified Azure Firewall. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} azureFirewallName The name of the Azure Firewall. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(resourceGroupName, azureFirewallName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginDeleteMethod(resourceGroupName, azureFirewallName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginDeleteMethod(resourceGroupName, azureFirewallName, options, optionalCallback); + } + } + + /** + * Creates or updates the specified Azure Firewall. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} azureFirewallName The name of the Azure Firewall. + * + * @param {object} parameters Parameters supplied to the create or update Azure + * Firewall operation. + * + * @param {array} [parameters.applicationRuleCollections] Collection of + * application rule collections used by a Azure Firewall. + * + * @param {array} [parameters.networkRuleCollections] Collection of network + * rule collections used by a Azure Firewall. + * + * @param {array} [parameters.ipConfigurations] IP configuration of the Azure + * Firewall resource. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName, azureFirewallName, parameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginCreateOrUpdate(resourceGroupName, azureFirewallName, parameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Creates or updates the specified Azure Firewall. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} azureFirewallName The name of the Azure Firewall. + * + * @param {object} parameters Parameters supplied to the create or update Azure + * Firewall operation. + * + * @param {array} [parameters.applicationRuleCollections] Collection of + * application rule collections used by a Azure Firewall. + * + * @param {array} [parameters.networkRuleCollections] Collection of network + * rule collections used by a Azure Firewall. + * + * @param {array} [parameters.ipConfigurations] IP configuration of the Azure + * Firewall resource. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {AzureFirewall} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewall} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginCreateOrUpdate(resourceGroupName, azureFirewallName, parameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginCreateOrUpdate(resourceGroupName, azureFirewallName, parameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginCreateOrUpdate(resourceGroupName, azureFirewallName, parameters, options, optionalCallback); + } + } + + /** + * Lists all Azure Firewalls in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listNext(nextPageLink, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all Azure Firewalls in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {AzureFirewallListResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewallListResult} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listNext(nextPageLink, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listNext(nextPageLink, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listNext(nextPageLink, options, optionalCallback); + } + } + + /** + * Gets all the Azure Firewalls in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listAllNextWithHttpOperationResponse(nextPageLink, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listAllNext(nextPageLink, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Gets all the Azure Firewalls in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {AzureFirewallListResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewallListResult} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listAllNext(nextPageLink, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listAllNext(nextPageLink, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listAllNext(nextPageLink, options, optionalCallback); + } + } + +} + +module.exports = AzureFirewalls; diff --git a/lib/services/networkManagement2/lib/operations/bgpServiceCommunities.js b/lib/services/networkManagement2/lib/operations/bgpServiceCommunities.js index 444d0a15e7..14fac9f202 100644 --- a/lib/services/networkManagement2/lib/operations/bgpServiceCommunities.js +++ b/lib/services/networkManagement2/lib/operations/bgpServiceCommunities.js @@ -46,11 +46,9 @@ function _list(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -66,7 +64,7 @@ function _list(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/bgpServiceCommunities'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/connectionMonitors.js b/lib/services/networkManagement2/lib/operations/connectionMonitors.js index 709e8f1564..a8ea0a1960 100644 --- a/lib/services/networkManagement2/lib/operations/connectionMonitors.js +++ b/lib/services/networkManagement2/lib/operations/connectionMonitors.js @@ -167,6 +167,7 @@ function _get(resourceGroupName, networkWatcherName, connectionMonitorName, opti if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -178,9 +179,6 @@ function _get(resourceGroupName, networkWatcherName, connectionMonitorName, opti if (connectionMonitorName === null || connectionMonitorName === undefined || typeof connectionMonitorName.valueOf() !== 'string') { throw new Error('connectionMonitorName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -199,7 +197,7 @@ function _get(resourceGroupName, networkWatcherName, connectionMonitorName, opti requestUrl = requestUrl.replace('{connectionMonitorName}', encodeURIComponent(connectionMonitorName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -599,6 +597,7 @@ function _list(resourceGroupName, networkWatcherName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -607,9 +606,6 @@ function _list(resourceGroupName, networkWatcherName, options, callback) { if (networkWatcherName === null || networkWatcherName === undefined || typeof networkWatcherName.valueOf() !== 'string') { throw new Error('networkWatcherName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -627,7 +623,7 @@ function _list(resourceGroupName, networkWatcherName, options, callback) { requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -780,6 +776,7 @@ function _beginCreateOrUpdate(resourceGroupName, networkWatcherName, connectionM if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -794,9 +791,6 @@ function _beginCreateOrUpdate(resourceGroupName, networkWatcherName, connectionM if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -815,7 +809,7 @@ function _beginCreateOrUpdate(resourceGroupName, networkWatcherName, connectionM requestUrl = requestUrl.replace('{connectionMonitorName}', encodeURIComponent(connectionMonitorName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -965,6 +959,7 @@ function _beginDeleteMethod(resourceGroupName, networkWatcherName, connectionMon if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -976,9 +971,6 @@ function _beginDeleteMethod(resourceGroupName, networkWatcherName, connectionMon if (connectionMonitorName === null || connectionMonitorName === undefined || typeof connectionMonitorName.valueOf() !== 'string') { throw new Error('connectionMonitorName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -997,7 +989,7 @@ function _beginDeleteMethod(resourceGroupName, networkWatcherName, connectionMon requestUrl = requestUrl.replace('{connectionMonitorName}', encodeURIComponent(connectionMonitorName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1099,6 +1091,7 @@ function _beginStop(resourceGroupName, networkWatcherName, connectionMonitorName if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1110,9 +1103,6 @@ function _beginStop(resourceGroupName, networkWatcherName, connectionMonitorName if (connectionMonitorName === null || connectionMonitorName === undefined || typeof connectionMonitorName.valueOf() !== 'string') { throw new Error('connectionMonitorName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1131,7 +1121,7 @@ function _beginStop(resourceGroupName, networkWatcherName, connectionMonitorName requestUrl = requestUrl.replace('{connectionMonitorName}', encodeURIComponent(connectionMonitorName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1233,6 +1223,7 @@ function _beginStart(resourceGroupName, networkWatcherName, connectionMonitorNam if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1244,9 +1235,6 @@ function _beginStart(resourceGroupName, networkWatcherName, connectionMonitorNam if (connectionMonitorName === null || connectionMonitorName === undefined || typeof connectionMonitorName.valueOf() !== 'string') { throw new Error('connectionMonitorName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1265,7 +1253,7 @@ function _beginStart(resourceGroupName, networkWatcherName, connectionMonitorNam requestUrl = requestUrl.replace('{connectionMonitorName}', encodeURIComponent(connectionMonitorName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1370,6 +1358,7 @@ function _beginQuery(resourceGroupName, networkWatcherName, connectionMonitorNam if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1381,9 +1370,6 @@ function _beginQuery(resourceGroupName, networkWatcherName, connectionMonitorNam if (connectionMonitorName === null || connectionMonitorName === undefined || typeof connectionMonitorName.valueOf() !== 'string') { throw new Error('connectionMonitorName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1402,7 +1388,7 @@ function _beginQuery(resourceGroupName, networkWatcherName, connectionMonitorNam requestUrl = requestUrl.replace('{connectionMonitorName}', encodeURIComponent(connectionMonitorName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/ddosProtectionPlans.js b/lib/services/networkManagement2/lib/operations/ddosProtectionPlans.js index aa2e109e9d..c8e8c1a02d 100644 --- a/lib/services/networkManagement2/lib/operations/ddosProtectionPlans.js +++ b/lib/services/networkManagement2/lib/operations/ddosProtectionPlans.js @@ -112,6 +112,7 @@ function _get(resourceGroupName, ddosProtectionPlanName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -120,9 +121,6 @@ function _get(resourceGroupName, ddosProtectionPlanName, options, callback) { if (ddosProtectionPlanName === null || ddosProtectionPlanName === undefined || typeof ddosProtectionPlanName.valueOf() !== 'string') { throw new Error('ddosProtectionPlanName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -140,7 +138,7 @@ function _get(resourceGroupName, ddosProtectionPlanName, options, callback) { requestUrl = requestUrl.replace('{ddosProtectionPlanName}', encodeURIComponent(ddosProtectionPlanName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -233,8 +231,6 @@ function _get(resourceGroupName, ddosProtectionPlanName, options, callback) { * @param {object} parameters Parameters supplied to the create or update * operation. * - * @param {string} [parameters.id] Resource ID. - * * @param {string} [parameters.location] Resource location. * * @param {object} [parameters.tags] Resource tags. @@ -341,11 +337,9 @@ function _list(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -361,7 +355,7 @@ function _list(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/ddosProtectionPlans'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -477,14 +471,12 @@ function _listByResourceGroup(resourceGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -501,7 +493,7 @@ function _listByResourceGroup(resourceGroupName, options, callback) { requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -617,6 +609,7 @@ function _beginDeleteMethod(resourceGroupName, ddosProtectionPlanName, options, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -625,9 +618,6 @@ function _beginDeleteMethod(resourceGroupName, ddosProtectionPlanName, options, if (ddosProtectionPlanName === null || ddosProtectionPlanName === undefined || typeof ddosProtectionPlanName.valueOf() !== 'string') { throw new Error('ddosProtectionPlanName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -645,7 +635,7 @@ function _beginDeleteMethod(resourceGroupName, ddosProtectionPlanName, options, requestUrl = requestUrl.replace('{ddosProtectionPlanName}', encodeURIComponent(ddosProtectionPlanName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -720,8 +710,6 @@ function _beginDeleteMethod(resourceGroupName, ddosProtectionPlanName, options, * @param {object} parameters Parameters supplied to the create or update * operation. * - * @param {string} [parameters.id] Resource ID. - * * @param {string} [parameters.location] Resource location. * * @param {object} [parameters.tags] Resource tags. @@ -754,6 +742,7 @@ function _beginCreateOrUpdate(resourceGroupName, ddosProtectionPlanName, paramet if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -765,9 +754,6 @@ function _beginCreateOrUpdate(resourceGroupName, ddosProtectionPlanName, paramet if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -785,7 +771,7 @@ function _beginCreateOrUpdate(resourceGroupName, ddosProtectionPlanName, paramet requestUrl = requestUrl.replace('{ddosProtectionPlanName}', encodeURIComponent(ddosProtectionPlanName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1354,8 +1340,6 @@ class DdosProtectionPlans { * @param {object} parameters Parameters supplied to the create or update * operation. * - * @param {string} [parameters.id] Resource ID. - * * @param {string} [parameters.location] Resource location. * * @param {object} [parameters.tags] Resource tags. @@ -1395,8 +1379,6 @@ class DdosProtectionPlans { * @param {object} parameters Parameters supplied to the create or update * operation. * - * @param {string} [parameters.id] Resource ID. - * * @param {string} [parameters.location] Resource location. * * @param {object} [parameters.tags] Resource tags. @@ -1705,8 +1687,6 @@ class DdosProtectionPlans { * @param {object} parameters Parameters supplied to the create or update * operation. * - * @param {string} [parameters.id] Resource ID. - * * @param {string} [parameters.location] Resource location. * * @param {object} [parameters.tags] Resource tags. @@ -1746,8 +1726,6 @@ class DdosProtectionPlans { * @param {object} parameters Parameters supplied to the create or update * operation. * - * @param {string} [parameters.id] Resource ID. - * * @param {string} [parameters.location] Resource location. * * @param {object} [parameters.tags] Resource tags. diff --git a/lib/services/networkManagement2/lib/operations/defaultSecurityRules.js b/lib/services/networkManagement2/lib/operations/defaultSecurityRules.js index 19435f09e3..76e555f2d8 100644 --- a/lib/services/networkManagement2/lib/operations/defaultSecurityRules.js +++ b/lib/services/networkManagement2/lib/operations/defaultSecurityRules.js @@ -51,6 +51,7 @@ function _list(resourceGroupName, networkSecurityGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -59,9 +60,6 @@ function _list(resourceGroupName, networkSecurityGroupName, options, callback) { if (networkSecurityGroupName === null || networkSecurityGroupName === undefined || typeof networkSecurityGroupName.valueOf() !== 'string') { throw new Error('networkSecurityGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -79,7 +77,7 @@ function _list(resourceGroupName, networkSecurityGroupName, options, callback) { requestUrl = requestUrl.replace('{networkSecurityGroupName}', encodeURIComponent(networkSecurityGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -200,6 +198,7 @@ function _get(resourceGroupName, networkSecurityGroupName, defaultSecurityRuleNa if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -211,9 +210,6 @@ function _get(resourceGroupName, networkSecurityGroupName, defaultSecurityRuleNa if (defaultSecurityRuleName === null || defaultSecurityRuleName === undefined || typeof defaultSecurityRuleName.valueOf() !== 'string') { throw new Error('defaultSecurityRuleName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -232,7 +228,7 @@ function _get(resourceGroupName, networkSecurityGroupName, defaultSecurityRuleNa requestUrl = requestUrl.replace('{defaultSecurityRuleName}', encodeURIComponent(defaultSecurityRuleName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/expressRouteCircuitAuthorizations.js b/lib/services/networkManagement2/lib/operations/expressRouteCircuitAuthorizations.js index 52d2037c8b..fa7d0adbad 100644 --- a/lib/services/networkManagement2/lib/operations/expressRouteCircuitAuthorizations.js +++ b/lib/services/networkManagement2/lib/operations/expressRouteCircuitAuthorizations.js @@ -118,6 +118,7 @@ function _get(resourceGroupName, circuitName, authorizationName, options, callba if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -129,9 +130,6 @@ function _get(resourceGroupName, circuitName, authorizationName, options, callba if (authorizationName === null || authorizationName === undefined || typeof authorizationName.valueOf() !== 'string') { throw new Error('authorizationName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -150,7 +148,7 @@ function _get(resourceGroupName, circuitName, authorizationName, options, callba requestUrl = requestUrl.replace('{authorizationName}', encodeURIComponent(authorizationName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -369,6 +367,7 @@ function _list(resourceGroupName, circuitName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -377,9 +376,6 @@ function _list(resourceGroupName, circuitName, options, callback) { if (circuitName === null || circuitName === undefined || typeof circuitName.valueOf() !== 'string') { throw new Error('circuitName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -397,7 +393,7 @@ function _list(resourceGroupName, circuitName, options, callback) { requestUrl = requestUrl.replace('{circuitName}', encodeURIComponent(circuitName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -516,6 +512,7 @@ function _beginDeleteMethod(resourceGroupName, circuitName, authorizationName, o if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -527,9 +524,6 @@ function _beginDeleteMethod(resourceGroupName, circuitName, authorizationName, o if (authorizationName === null || authorizationName === undefined || typeof authorizationName.valueOf() !== 'string') { throw new Error('authorizationName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -548,7 +542,7 @@ function _beginDeleteMethod(resourceGroupName, circuitName, authorizationName, o requestUrl = requestUrl.replace('{authorizationName}', encodeURIComponent(authorizationName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -671,6 +665,7 @@ function _beginCreateOrUpdate(resourceGroupName, circuitName, authorizationName, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -685,9 +680,6 @@ function _beginCreateOrUpdate(resourceGroupName, circuitName, authorizationName, if (authorizationParameters === null || authorizationParameters === undefined) { throw new Error('authorizationParameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -706,7 +698,7 @@ function _beginCreateOrUpdate(resourceGroupName, circuitName, authorizationName, requestUrl = requestUrl.replace('{authorizationName}', encodeURIComponent(authorizationName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/expressRouteCircuitConnections.js b/lib/services/networkManagement2/lib/operations/expressRouteCircuitConnections.js index 996630c055..a4d083ae59 100644 --- a/lib/services/networkManagement2/lib/operations/expressRouteCircuitConnections.js +++ b/lib/services/networkManagement2/lib/operations/expressRouteCircuitConnections.js @@ -125,6 +125,7 @@ function _get(resourceGroupName, circuitName, peeringName, connectionName, optio if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -139,9 +140,6 @@ function _get(resourceGroupName, circuitName, peeringName, connectionName, optio if (connectionName === null || connectionName === undefined || typeof connectionName.valueOf() !== 'string') { throw new Error('connectionName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -161,7 +159,7 @@ function _get(resourceGroupName, circuitName, peeringName, connectionName, optio requestUrl = requestUrl.replace('{connectionName}', encodeURIComponent(connectionName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -397,6 +395,7 @@ function _beginDeleteMethod(resourceGroupName, circuitName, peeringName, connect if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -411,9 +410,6 @@ function _beginDeleteMethod(resourceGroupName, circuitName, peeringName, connect if (connectionName === null || connectionName === undefined || typeof connectionName.valueOf() !== 'string') { throw new Error('connectionName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -433,7 +429,7 @@ function _beginDeleteMethod(resourceGroupName, circuitName, peeringName, connect requestUrl = requestUrl.replace('{connectionName}', encodeURIComponent(connectionName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -569,6 +565,7 @@ function _beginCreateOrUpdate(resourceGroupName, circuitName, peeringName, conne if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -586,9 +583,6 @@ function _beginCreateOrUpdate(resourceGroupName, circuitName, peeringName, conne if (expressRouteCircuitConnectionParameters === null || expressRouteCircuitConnectionParameters === undefined) { throw new Error('expressRouteCircuitConnectionParameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -608,7 +602,7 @@ function _beginCreateOrUpdate(resourceGroupName, circuitName, peeringName, conne requestUrl = requestUrl.replace('{connectionName}', encodeURIComponent(connectionName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/expressRouteCircuitPeerings.js b/lib/services/networkManagement2/lib/operations/expressRouteCircuitPeerings.js index 1647d432da..17e63f24c4 100644 --- a/lib/services/networkManagement2/lib/operations/expressRouteCircuitPeerings.js +++ b/lib/services/networkManagement2/lib/operations/expressRouteCircuitPeerings.js @@ -80,7 +80,7 @@ function _deleteMethod(resourceGroupName, circuitName, peeringName, options, cal } /** - * Gets the specified authorization from the specified express route circuit. + * Gets the specified peering for the express route circuit. * * @param {string} resourceGroupName The name of the resource group. * @@ -117,6 +117,7 @@ function _get(resourceGroupName, circuitName, peeringName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -128,9 +129,6 @@ function _get(resourceGroupName, circuitName, peeringName, options, callback) { if (peeringName === null || peeringName === undefined || typeof peeringName.valueOf() !== 'string') { throw new Error('peeringName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -149,7 +147,7 @@ function _get(resourceGroupName, circuitName, peeringName, options, callback) { requestUrl = requestUrl.replace('{peeringName}', encodeURIComponent(peeringName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -478,6 +476,7 @@ function _list(resourceGroupName, circuitName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -486,9 +485,6 @@ function _list(resourceGroupName, circuitName, options, callback) { if (circuitName === null || circuitName === undefined || typeof circuitName.valueOf() !== 'string') { throw new Error('circuitName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -506,7 +502,7 @@ function _list(resourceGroupName, circuitName, options, callback) { requestUrl = requestUrl.replace('{circuitName}', encodeURIComponent(circuitName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -624,6 +620,7 @@ function _beginDeleteMethod(resourceGroupName, circuitName, peeringName, options if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -635,9 +632,6 @@ function _beginDeleteMethod(resourceGroupName, circuitName, peeringName, options if (peeringName === null || peeringName === undefined || typeof peeringName.valueOf() !== 'string') { throw new Error('peeringName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -656,7 +650,7 @@ function _beginDeleteMethod(resourceGroupName, circuitName, peeringName, options requestUrl = requestUrl.replace('{peeringName}', encodeURIComponent(peeringName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -889,6 +883,7 @@ function _beginCreateOrUpdate(resourceGroupName, circuitName, peeringName, peeri if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -903,9 +898,6 @@ function _beginCreateOrUpdate(resourceGroupName, circuitName, peeringName, peeri if (peeringParameters === null || peeringParameters === undefined) { throw new Error('peeringParameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -924,7 +916,7 @@ function _beginCreateOrUpdate(resourceGroupName, circuitName, peeringName, peeri requestUrl = requestUrl.replace('{peeringName}', encodeURIComponent(peeringName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1272,7 +1264,7 @@ class ExpressRouteCircuitPeerings { } /** - * Gets the specified authorization from the specified express route circuit. + * Gets the specified peering for the express route circuit. * * @param {string} resourceGroupName The name of the resource group. * @@ -1306,7 +1298,7 @@ class ExpressRouteCircuitPeerings { } /** - * Gets the specified authorization from the specified express route circuit. + * Gets the specified peering for the express route circuit. * * @param {string} resourceGroupName The name of the resource group. * diff --git a/lib/services/networkManagement2/lib/operations/expressRouteCircuits.js b/lib/services/networkManagement2/lib/operations/expressRouteCircuits.js index 2ec0768228..58ed25d34d 100644 --- a/lib/services/networkManagement2/lib/operations/expressRouteCircuits.js +++ b/lib/services/networkManagement2/lib/operations/expressRouteCircuits.js @@ -112,6 +112,7 @@ function _get(resourceGroupName, circuitName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -120,9 +121,6 @@ function _get(resourceGroupName, circuitName, options, callback) { if (circuitName === null || circuitName === undefined || typeof circuitName.valueOf() !== 'string') { throw new Error('circuitName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -140,7 +138,7 @@ function _get(resourceGroupName, circuitName, options, callback) { requestUrl = requestUrl.replace('{circuitName}', encodeURIComponent(circuitName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -730,6 +728,7 @@ function _getStats(resourceGroupName, circuitName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -738,9 +737,6 @@ function _getStats(resourceGroupName, circuitName, options, callback) { if (circuitName === null || circuitName === undefined || typeof circuitName.valueOf() !== 'string') { throw new Error('circuitName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -758,7 +754,7 @@ function _getStats(resourceGroupName, circuitName, options, callback) { requestUrl = requestUrl.replace('{circuitName}', encodeURIComponent(circuitName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -878,6 +874,7 @@ function _getPeeringStats(resourceGroupName, circuitName, peeringName, options, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -889,9 +886,6 @@ function _getPeeringStats(resourceGroupName, circuitName, peeringName, options, if (peeringName === null || peeringName === undefined || typeof peeringName.valueOf() !== 'string') { throw new Error('peeringName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -910,7 +904,7 @@ function _getPeeringStats(resourceGroupName, circuitName, peeringName, options, requestUrl = requestUrl.replace('{peeringName}', encodeURIComponent(peeringName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1026,14 +1020,12 @@ function _list(resourceGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1050,7 +1042,7 @@ function _list(resourceGroupName, options, callback) { requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1164,11 +1156,9 @@ function _listAll(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1184,7 +1174,7 @@ function _listAll(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/expressRouteCircuits'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1300,6 +1290,7 @@ function _beginDeleteMethod(resourceGroupName, circuitName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1308,9 +1299,6 @@ function _beginDeleteMethod(resourceGroupName, circuitName, options, callback) { if (circuitName === null || circuitName === undefined || typeof circuitName.valueOf() !== 'string') { throw new Error('circuitName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1328,7 +1316,7 @@ function _beginDeleteMethod(resourceGroupName, circuitName, options, callback) { requestUrl = requestUrl.replace('{circuitName}', encodeURIComponent(circuitName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1486,6 +1474,7 @@ function _beginCreateOrUpdate(resourceGroupName, circuitName, parameters, option if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1497,9 +1486,6 @@ function _beginCreateOrUpdate(resourceGroupName, circuitName, parameters, option if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1517,7 +1503,7 @@ function _beginCreateOrUpdate(resourceGroupName, circuitName, parameters, option requestUrl = requestUrl.replace('{circuitName}', encodeURIComponent(circuitName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1670,6 +1656,7 @@ function _beginUpdateTags(resourceGroupName, circuitName, parameters, options, c if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1681,9 +1668,6 @@ function _beginUpdateTags(resourceGroupName, circuitName, parameters, options, c if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1701,7 +1685,7 @@ function _beginUpdateTags(resourceGroupName, circuitName, parameters, options, c requestUrl = requestUrl.replace('{circuitName}', encodeURIComponent(circuitName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1838,6 +1822,7 @@ function _beginListArpTable(resourceGroupName, circuitName, peeringName, deviceP if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1852,9 +1837,6 @@ function _beginListArpTable(resourceGroupName, circuitName, peeringName, deviceP if (devicePath === null || devicePath === undefined || typeof devicePath.valueOf() !== 'string') { throw new Error('devicePath cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1874,7 +1856,7 @@ function _beginListArpTable(resourceGroupName, circuitName, peeringName, deviceP requestUrl = requestUrl.replace('{devicePath}', encodeURIComponent(devicePath)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1997,6 +1979,7 @@ function _beginListRoutesTable(resourceGroupName, circuitName, peeringName, devi if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2011,9 +1994,6 @@ function _beginListRoutesTable(resourceGroupName, circuitName, peeringName, devi if (devicePath === null || devicePath === undefined || typeof devicePath.valueOf() !== 'string') { throw new Error('devicePath cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2033,7 +2013,7 @@ function _beginListRoutesTable(resourceGroupName, circuitName, peeringName, devi requestUrl = requestUrl.replace('{devicePath}', encodeURIComponent(devicePath)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2157,6 +2137,7 @@ function _beginListRoutesTableSummary(resourceGroupName, circuitName, peeringNam if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2171,9 +2152,6 @@ function _beginListRoutesTableSummary(resourceGroupName, circuitName, peeringNam if (devicePath === null || devicePath === undefined || typeof devicePath.valueOf() !== 'string') { throw new Error('devicePath cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2193,7 +2171,7 @@ function _beginListRoutesTableSummary(resourceGroupName, circuitName, peeringNam requestUrl = requestUrl.replace('{devicePath}', encodeURIComponent(devicePath)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/expressRouteCrossConnectionPeerings.js b/lib/services/networkManagement2/lib/operations/expressRouteCrossConnectionPeerings.js index 3a8e0f4b02..8dcd1902df 100644 --- a/lib/services/networkManagement2/lib/operations/expressRouteCrossConnectionPeerings.js +++ b/lib/services/networkManagement2/lib/operations/expressRouteCrossConnectionPeerings.js @@ -51,6 +51,7 @@ function _list(resourceGroupName, crossConnectionName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -59,9 +60,6 @@ function _list(resourceGroupName, crossConnectionName, options, callback) { if (crossConnectionName === null || crossConnectionName === undefined || typeof crossConnectionName.valueOf() !== 'string') { throw new Error('crossConnectionName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -79,7 +77,7 @@ function _list(resourceGroupName, crossConnectionName, options, callback) { requestUrl = requestUrl.replace('{crossConnectionName}', encodeURIComponent(crossConnectionName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -266,6 +264,7 @@ function _get(resourceGroupName, crossConnectionName, peeringName, options, call if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -277,9 +276,6 @@ function _get(resourceGroupName, crossConnectionName, peeringName, options, call if (peeringName === null || peeringName === undefined || typeof peeringName.valueOf() !== 'string') { throw new Error('peeringName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -298,7 +294,7 @@ function _get(resourceGroupName, crossConnectionName, peeringName, options, call requestUrl = requestUrl.replace('{peeringName}', encodeURIComponent(peeringName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -416,6 +412,9 @@ function _get(resourceGroupName, crossConnectionName, peeringName, options, call * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft * peering configuration. * + * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager + * Etag. + * * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider * or the customer last modified the peering. * @@ -596,6 +595,7 @@ function _beginDeleteMethod(resourceGroupName, crossConnectionName, peeringName, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -607,9 +607,6 @@ function _beginDeleteMethod(resourceGroupName, crossConnectionName, peeringName, if (peeringName === null || peeringName === undefined || typeof peeringName.valueOf() !== 'string') { throw new Error('peeringName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -628,7 +625,7 @@ function _beginDeleteMethod(resourceGroupName, crossConnectionName, peeringName, requestUrl = requestUrl.replace('{peeringName}', encodeURIComponent(peeringName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -728,6 +725,9 @@ function _beginDeleteMethod(resourceGroupName, crossConnectionName, peeringName, * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft * peering configuration. * + * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager + * Etag. + * * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider * or the customer last modified the peering. * @@ -829,6 +829,7 @@ function _beginCreateOrUpdate(resourceGroupName, crossConnectionName, peeringNam if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -843,9 +844,6 @@ function _beginCreateOrUpdate(resourceGroupName, crossConnectionName, peeringNam if (peeringParameters === null || peeringParameters === undefined) { throw new Error('peeringParameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -864,7 +862,7 @@ function _beginCreateOrUpdate(resourceGroupName, crossConnectionName, peeringNam requestUrl = requestUrl.replace('{peeringName}', encodeURIComponent(peeringName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1430,6 +1428,9 @@ class ExpressRouteCrossConnectionPeerings { * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft * peering configuration. * + * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager + * Etag. + * * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider * or the customer last modified the peering. * @@ -1562,6 +1563,9 @@ class ExpressRouteCrossConnectionPeerings { * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft * peering configuration. * + * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager + * Etag. + * * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider * or the customer last modified the peering. * @@ -1808,6 +1812,9 @@ class ExpressRouteCrossConnectionPeerings { * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft * peering configuration. * + * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager + * Etag. + * * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider * or the customer last modified the peering. * @@ -1940,6 +1947,9 @@ class ExpressRouteCrossConnectionPeerings { * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft * peering configuration. * + * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager + * Etag. + * * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider * or the customer last modified the peering. * diff --git a/lib/services/networkManagement2/lib/operations/expressRouteCrossConnections.js b/lib/services/networkManagement2/lib/operations/expressRouteCrossConnections.js index aa4f1a8d0d..f979ebe167 100644 --- a/lib/services/networkManagement2/lib/operations/expressRouteCrossConnections.js +++ b/lib/services/networkManagement2/lib/operations/expressRouteCrossConnections.js @@ -46,11 +46,9 @@ function _list(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -66,7 +64,7 @@ function _list(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/expressRouteCrossConnections'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -182,14 +180,12 @@ function _listByResourceGroup(resourceGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -206,7 +202,7 @@ function _listByResourceGroup(resourceGroupName, options, callback) { requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -326,6 +322,7 @@ function _get(resourceGroupName, crossConnectionName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -334,9 +331,6 @@ function _get(resourceGroupName, crossConnectionName, options, callback) { if (crossConnectionName === null || crossConnectionName === undefined || typeof crossConnectionName.valueOf() !== 'string') { throw new Error('crossConnectionName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -354,7 +348,7 @@ function _get(resourceGroupName, crossConnectionName, options, callback) { requestUrl = requestUrl.replace('{crossConnectionName}', encodeURIComponent(crossConnectionName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -448,6 +442,16 @@ function _get(resourceGroupName, crossConnectionName, options, callback) { * @param {object} parameters Parameters supplied to the update express route * crossConnection operation. * + * @param {string} [parameters.peeringLocation] The peering location of the + * ExpressRoute circuit. + * + * @param {number} [parameters.bandwidthInMbps] The circuit bandwidth In Mbps. + * + * @param {object} [parameters.expressRouteCircuit] The ExpressRouteCircuit + * + * @param {string} [parameters.expressRouteCircuit.id] Corresponding Express + * Route Circuit Id. + * * @param {string} [parameters.serviceProviderProvisioningState] The * provisioning state of the circuit in the connectivity provider system. * Possible values are 'NotProvisioned', 'Provisioning', 'Provisioned'. @@ -887,6 +891,16 @@ function _listRoutesTable(resourceGroupName, crossConnectionName, peeringName, d * @param {object} parameters Parameters supplied to the update express route * crossConnection operation. * + * @param {string} [parameters.peeringLocation] The peering location of the + * ExpressRoute circuit. + * + * @param {number} [parameters.bandwidthInMbps] The circuit bandwidth In Mbps. + * + * @param {object} [parameters.expressRouteCircuit] The ExpressRouteCircuit + * + * @param {string} [parameters.expressRouteCircuit.id] Corresponding Express + * Route Circuit Id. + * * @param {string} [parameters.serviceProviderProvisioningState] The * provisioning state of the circuit in the connectivity provider system. * Possible values are 'NotProvisioned', 'Provisioning', 'Provisioned'. @@ -933,6 +947,7 @@ function _beginCreateOrUpdate(resourceGroupName, crossConnectionName, parameters if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -944,9 +959,6 @@ function _beginCreateOrUpdate(resourceGroupName, crossConnectionName, parameters if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -964,7 +976,7 @@ function _beginCreateOrUpdate(resourceGroupName, crossConnectionName, parameters requestUrl = requestUrl.replace('{crossConnectionName}', encodeURIComponent(crossConnectionName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1101,6 +1113,7 @@ function _beginUpdateTags(resourceGroupName, crossConnectionName, crossConnectio if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1112,9 +1125,6 @@ function _beginUpdateTags(resourceGroupName, crossConnectionName, crossConnectio if (crossConnectionParameters === null || crossConnectionParameters === undefined) { throw new Error('crossConnectionParameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1132,7 +1142,7 @@ function _beginUpdateTags(resourceGroupName, crossConnectionName, crossConnectio requestUrl = requestUrl.replace('{crossConnectionName}', encodeURIComponent(crossConnectionName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1270,6 +1280,7 @@ function _beginListArpTable(resourceGroupName, crossConnectionName, peeringName, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1284,9 +1295,6 @@ function _beginListArpTable(resourceGroupName, crossConnectionName, peeringName, if (devicePath === null || devicePath === undefined || typeof devicePath.valueOf() !== 'string') { throw new Error('devicePath cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1306,7 +1314,7 @@ function _beginListArpTable(resourceGroupName, crossConnectionName, peeringName, requestUrl = requestUrl.replace('{devicePath}', encodeURIComponent(devicePath)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1431,6 +1439,7 @@ function _beginListRoutesTableSummary(resourceGroupName, crossConnectionName, pe if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1445,9 +1454,6 @@ function _beginListRoutesTableSummary(resourceGroupName, crossConnectionName, pe if (devicePath === null || devicePath === undefined || typeof devicePath.valueOf() !== 'string') { throw new Error('devicePath cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1467,7 +1473,7 @@ function _beginListRoutesTableSummary(resourceGroupName, crossConnectionName, pe requestUrl = requestUrl.replace('{devicePath}', encodeURIComponent(devicePath)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1591,6 +1597,7 @@ function _beginListRoutesTable(resourceGroupName, crossConnectionName, peeringNa if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1605,9 +1612,6 @@ function _beginListRoutesTable(resourceGroupName, crossConnectionName, peeringNa if (devicePath === null || devicePath === undefined || typeof devicePath.valueOf() !== 'string') { throw new Error('devicePath cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1627,7 +1631,7 @@ function _beginListRoutesTable(resourceGroupName, crossConnectionName, peeringNa requestUrl = requestUrl.replace('{devicePath}', encodeURIComponent(devicePath)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2254,6 +2258,16 @@ class ExpressRouteCrossConnections { * @param {object} parameters Parameters supplied to the update express route * crossConnection operation. * + * @param {string} [parameters.peeringLocation] The peering location of the + * ExpressRoute circuit. + * + * @param {number} [parameters.bandwidthInMbps] The circuit bandwidth In Mbps. + * + * @param {object} [parameters.expressRouteCircuit] The ExpressRouteCircuit + * + * @param {string} [parameters.expressRouteCircuit.id] Corresponding Express + * Route Circuit Id. + * * @param {string} [parameters.serviceProviderProvisioningState] The * provisioning state of the circuit in the connectivity provider system. * Possible values are 'NotProvisioned', 'Provisioning', 'Provisioned'. @@ -2307,6 +2321,16 @@ class ExpressRouteCrossConnections { * @param {object} parameters Parameters supplied to the update express route * crossConnection operation. * + * @param {string} [parameters.peeringLocation] The peering location of the + * ExpressRoute circuit. + * + * @param {number} [parameters.bandwidthInMbps] The circuit bandwidth In Mbps. + * + * @param {object} [parameters.expressRouteCircuit] The ExpressRouteCircuit + * + * @param {string} [parameters.expressRouteCircuit.id] Corresponding Express + * Route Circuit Id. + * * @param {string} [parameters.serviceProviderProvisioningState] The * provisioning state of the circuit in the connectivity provider system. * Possible values are 'NotProvisioned', 'Provisioning', 'Provisioned'. @@ -2778,6 +2802,16 @@ class ExpressRouteCrossConnections { * @param {object} parameters Parameters supplied to the update express route * crossConnection operation. * + * @param {string} [parameters.peeringLocation] The peering location of the + * ExpressRoute circuit. + * + * @param {number} [parameters.bandwidthInMbps] The circuit bandwidth In Mbps. + * + * @param {object} [parameters.expressRouteCircuit] The ExpressRouteCircuit + * + * @param {string} [parameters.expressRouteCircuit.id] Corresponding Express + * Route Circuit Id. + * * @param {string} [parameters.serviceProviderProvisioningState] The * provisioning state of the circuit in the connectivity provider system. * Possible values are 'NotProvisioned', 'Provisioning', 'Provisioned'. @@ -2831,6 +2865,16 @@ class ExpressRouteCrossConnections { * @param {object} parameters Parameters supplied to the update express route * crossConnection operation. * + * @param {string} [parameters.peeringLocation] The peering location of the + * ExpressRoute circuit. + * + * @param {number} [parameters.bandwidthInMbps] The circuit bandwidth In Mbps. + * + * @param {object} [parameters.expressRouteCircuit] The ExpressRouteCircuit + * + * @param {string} [parameters.expressRouteCircuit.id] Corresponding Express + * Route Circuit Id. + * * @param {string} [parameters.serviceProviderProvisioningState] The * provisioning state of the circuit in the connectivity provider system. * Possible values are 'NotProvisioned', 'Provisioning', 'Provisioned'. diff --git a/lib/services/networkManagement2/lib/operations/expressRouteServiceProviders.js b/lib/services/networkManagement2/lib/operations/expressRouteServiceProviders.js index c0c647acd9..77c53158cf 100644 --- a/lib/services/networkManagement2/lib/operations/expressRouteServiceProviders.js +++ b/lib/services/networkManagement2/lib/operations/expressRouteServiceProviders.js @@ -46,11 +46,9 @@ function _list(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -66,7 +64,7 @@ function _list(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/expressRouteServiceProviders'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/hubVirtualNetworkConnections.js b/lib/services/networkManagement2/lib/operations/hubVirtualNetworkConnections.js new file mode 100644 index 0000000000..b5355410eb --- /dev/null +++ b/lib/services/networkManagement2/lib/operations/hubVirtualNetworkConnections.js @@ -0,0 +1,720 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const msRest = require('ms-rest'); +const msRestAzure = require('ms-rest-azure'); +const WebResource = msRest.WebResource; + +/** + * Retrieves the details of a HubVirtualNetworkConnection. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {string} connectionName The name of the vpn connection. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link HubVirtualNetworkConnection} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _get(resourceGroupName, virtualHubName, connectionName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (virtualHubName === null || virtualHubName === undefined || typeof virtualHubName.valueOf() !== 'string') { + throw new Error('virtualHubName cannot be null or undefined and it must be of type string.'); + } + if (connectionName === null || connectionName === undefined || typeof connectionName.valueOf() !== 'string') { + throw new Error('connectionName cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualHubs/{virtualHubName}/hubVirtualNetworkConnections/{connectionName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{virtualHubName}', encodeURIComponent(virtualHubName)); + requestUrl = requestUrl.replace('{connectionName}', encodeURIComponent(connectionName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['HubVirtualNetworkConnection']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Retrieves the details of all HubVirtualNetworkConnections. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListHubVirtualNetworkConnectionsResult} for + * more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _list(resourceGroupName, virtualHubName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (virtualHubName === null || virtualHubName === undefined || typeof virtualHubName.valueOf() !== 'string') { + throw new Error('virtualHubName cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualHubs/{virtualHubName}/hubVirtualNetworkConnections'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{virtualHubName}', encodeURIComponent(virtualHubName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListHubVirtualNetworkConnectionsResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Retrieves the details of all HubVirtualNetworkConnections. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListHubVirtualNetworkConnectionsResult} for + * more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listNext(nextPageLink, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + // Validate + try { + if (nextPageLink === null || nextPageLink === undefined || typeof nextPageLink.valueOf() !== 'string') { + throw new Error('nextPageLink cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let requestUrl = '{nextLink}'; + requestUrl = requestUrl.replace('{nextLink}', nextPageLink); + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListHubVirtualNetworkConnectionsResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** Class representing a HubVirtualNetworkConnections. */ +class HubVirtualNetworkConnections { + /** + * Create a HubVirtualNetworkConnections. + * @param {NetworkManagementClient} client Reference to the service client. + */ + constructor(client) { + this.client = client; + this._get = _get; + this._list = _list; + this._listNext = _listNext; + } + + /** + * Retrieves the details of a HubVirtualNetworkConnection. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {string} connectionName The name of the vpn connection. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName, virtualHubName, connectionName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._get(resourceGroupName, virtualHubName, connectionName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Retrieves the details of a HubVirtualNetworkConnection. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {string} connectionName The name of the vpn connection. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {HubVirtualNetworkConnection} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link HubVirtualNetworkConnection} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName, virtualHubName, connectionName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._get(resourceGroupName, virtualHubName, connectionName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._get(resourceGroupName, virtualHubName, connectionName, options, optionalCallback); + } + } + + /** + * Retrieves the details of all HubVirtualNetworkConnections. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listWithHttpOperationResponse(resourceGroupName, virtualHubName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._list(resourceGroupName, virtualHubName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Retrieves the details of all HubVirtualNetworkConnections. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListHubVirtualNetworkConnectionsResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListHubVirtualNetworkConnectionsResult} for + * more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + list(resourceGroupName, virtualHubName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._list(resourceGroupName, virtualHubName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._list(resourceGroupName, virtualHubName, options, optionalCallback); + } + } + + /** + * Retrieves the details of all HubVirtualNetworkConnections. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listNext(nextPageLink, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Retrieves the details of all HubVirtualNetworkConnections. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListHubVirtualNetworkConnectionsResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListHubVirtualNetworkConnectionsResult} for + * more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listNext(nextPageLink, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listNext(nextPageLink, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listNext(nextPageLink, options, optionalCallback); + } + } + +} + +module.exports = HubVirtualNetworkConnections; diff --git a/lib/services/networkManagement2/lib/operations/inboundNatRules.js b/lib/services/networkManagement2/lib/operations/inboundNatRules.js index df67087433..0c9bc6715e 100644 --- a/lib/services/networkManagement2/lib/operations/inboundNatRules.js +++ b/lib/services/networkManagement2/lib/operations/inboundNatRules.js @@ -50,6 +50,7 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -58,9 +59,6 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { if (loadBalancerName === null || loadBalancerName === undefined || typeof loadBalancerName.valueOf() !== 'string') { throw new Error('loadBalancerName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -78,7 +76,7 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { requestUrl = requestUrl.replace('{loadBalancerName}', encodeURIComponent(loadBalancerName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -265,6 +263,7 @@ function _get(resourceGroupName, loadBalancerName, inboundNatRuleName, options, throw new Error('callback cannot be null.'); } let expand = (options && options.expand !== undefined) ? options.expand : undefined; + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -276,9 +275,6 @@ function _get(resourceGroupName, loadBalancerName, inboundNatRuleName, options, if (inboundNatRuleName === null || inboundNatRuleName === undefined || typeof inboundNatRuleName.valueOf() !== 'string') { throw new Error('inboundNatRuleName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -300,7 +296,7 @@ function _get(resourceGroupName, loadBalancerName, inboundNatRuleName, options, requestUrl = requestUrl.replace('{inboundNatRuleName}', encodeURIComponent(inboundNatRuleName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (expand !== null && expand !== undefined) { queryParameters.push('$expand=' + encodeURIComponent(expand)); } @@ -544,6 +540,7 @@ function _beginDeleteMethod(resourceGroupName, loadBalancerName, inboundNatRuleN if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -555,9 +552,6 @@ function _beginDeleteMethod(resourceGroupName, loadBalancerName, inboundNatRuleN if (inboundNatRuleName === null || inboundNatRuleName === undefined || typeof inboundNatRuleName.valueOf() !== 'string') { throw new Error('inboundNatRuleName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -576,7 +570,7 @@ function _beginDeleteMethod(resourceGroupName, loadBalancerName, inboundNatRuleN requestUrl = requestUrl.replace('{inboundNatRuleName}', encodeURIComponent(inboundNatRuleName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -721,6 +715,7 @@ function _beginCreateOrUpdate(resourceGroupName, loadBalancerName, inboundNatRul if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -735,9 +730,6 @@ function _beginCreateOrUpdate(resourceGroupName, loadBalancerName, inboundNatRul if (inboundNatRuleParameters === null || inboundNatRuleParameters === undefined) { throw new Error('inboundNatRuleParameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -756,7 +748,7 @@ function _beginCreateOrUpdate(resourceGroupName, loadBalancerName, inboundNatRul requestUrl = requestUrl.replace('{inboundNatRuleName}', encodeURIComponent(inboundNatRuleName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/index.d.ts b/lib/services/networkManagement2/lib/operations/index.d.ts index ebd9602206..1b50dafa65 100644 --- a/lib/services/networkManagement2/lib/operations/index.d.ts +++ b/lib/services/networkManagement2/lib/operations/index.d.ts @@ -14,19 +14,19 @@ import * as models from '../models'; /** * @class - * ApplicationGateways + * AzureFirewalls * __NOTE__: An instance of this class is automatically created for an * instance of the NetworkManagementClient. */ -export interface ApplicationGateways { +export interface AzureFirewalls { /** - * Deletes the specified application gateway. + * Deletes the specified Azure Firewall. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} applicationGatewayName The name of the application gateway. + * @param {string} azureFirewallName The name of the Azure Firewall. * * @param {object} [options] Optional Parameters. * @@ -39,14 +39,14 @@ export interface ApplicationGateways { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, azureFirewallName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified application gateway. + * Deletes the specified Azure Firewall. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} applicationGatewayName The name of the application gateway. + * @param {string} azureFirewallName The name of the Azure Firewall. * * @param {object} [options] Optional Parameters. * @@ -74,17 +74,17 @@ export interface ApplicationGateways { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, applicationGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, azureFirewallName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, azureFirewallName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, azureFirewallName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified application gateway. + * Gets the specified Azure Firewall. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} applicationGatewayName The name of the application gateway. + * @param {string} azureFirewallName The name of the Azure Firewall. * * @param {object} [options] Optional Parameters. * @@ -93,18 +93,18 @@ export interface ApplicationGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, azureFirewallName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified application gateway. + * Gets the specified Azure Firewall. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} applicationGatewayName The name of the application gateway. + * @param {string} azureFirewallName The name of the Azure Firewall. * * @param {object} [options] Optional Parameters. * @@ -118,7 +118,7 @@ export interface ApplicationGateways { * * {Promise} A promise is returned. * - * @resolve {ApplicationGateway} - The deserialized result object. + * @resolve {AzureFirewall} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -126,144 +126,125 @@ export interface ApplicationGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ApplicationGateway} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationGateway} for more information. + * {AzureFirewall} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewall} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, applicationGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, azureFirewallName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, azureFirewallName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, azureFirewallName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates the specified application gateway. + * Creates or updates the specified Azure Firewall. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} applicationGatewayName The name of the application gateway. - * - * @param {object} parameters Parameters supplied to the create or update - * application gateway operation. - * - * @param {object} [parameters.sku] SKU of the application gateway resource. + * @param {string} azureFirewallName The name of the Azure Firewall. * - * @param {string} [parameters.sku.name] Name of an application gateway SKU. - * Possible values include: 'Standard_Small', 'Standard_Medium', - * 'Standard_Large', 'WAF_Medium', 'WAF_Large' + * @param {object} parameters Parameters supplied to the create or update Azure + * Firewall operation. * - * @param {string} [parameters.sku.tier] Tier of an application gateway. - * Possible values include: 'Standard', 'WAF' + * @param {array} [parameters.applicationRuleCollections] Collection of + * application rule collections used by a Azure Firewall. * - * @param {number} [parameters.sku.capacity] Capacity (instance count) of an - * application gateway. + * @param {array} [parameters.networkRuleCollections] Collection of network + * rule collections used by a Azure Firewall. * - * @param {object} [parameters.sslPolicy] SSL policy of the application gateway - * resource. + * @param {array} [parameters.ipConfigurations] IP configuration of the Azure + * Firewall resource. * - * @param {array} [parameters.sslPolicy.disabledSslProtocols] Ssl protocols to - * be disabled on application gateway. + * @param {string} [parameters.provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' * - * @param {string} [parameters.sslPolicy.policyType] Type of Ssl Policy. - * Possible values include: 'Predefined', 'Custom' + * @param {string} [parameters.id] Resource ID. * - * @param {string} [parameters.sslPolicy.policyName] Name of Ssl predefined - * policy. Possible values include: 'AppGwSslPolicy20150501', - * 'AppGwSslPolicy20170401', 'AppGwSslPolicy20170401S' + * @param {string} [parameters.location] Resource location. * - * @param {array} [parameters.sslPolicy.cipherSuites] Ssl cipher suites to be - * enabled in the specified order to application gateway. + * @param {object} [parameters.tags] Resource tags. * - * @param {string} [parameters.sslPolicy.minProtocolVersion] Minimum version of - * Ssl protocol to be supported on application gateway. Possible values - * include: 'TLSv1_0', 'TLSv1_1', 'TLSv1_2' + * @param {object} [options] Optional Parameters. * - * @param {array} [parameters.gatewayIPConfigurations] Subnets of application - * the gateway resource. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {array} [parameters.authenticationCertificates] Authentication - * certificates of the application gateway resource. + * @returns {Promise} A promise is returned * - * @param {array} [parameters.sslCertificates] SSL certificates of the - * application gateway resource. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {array} [parameters.frontendIPConfigurations] Frontend IP addresses - * of the application gateway resource. + * @reject {Error|ServiceError} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, azureFirewallName: string, parameters: models.AzureFirewall, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates the specified Azure Firewall. * - * @param {array} [parameters.frontendPorts] Frontend ports of the application - * gateway resource. + * @param {string} resourceGroupName The name of the resource group. * - * @param {array} [parameters.probes] Probes of the application gateway - * resource. + * @param {string} azureFirewallName The name of the Azure Firewall. * - * @param {array} [parameters.backendAddressPools] Backend address pool of the - * application gateway resource. + * @param {object} parameters Parameters supplied to the create or update Azure + * Firewall operation. * - * @param {array} [parameters.backendHttpSettingsCollection] Backend http - * settings of the application gateway resource. + * @param {array} [parameters.applicationRuleCollections] Collection of + * application rule collections used by a Azure Firewall. * - * @param {array} [parameters.httpListeners] Http listeners of the application - * gateway resource. + * @param {array} [parameters.networkRuleCollections] Collection of network + * rule collections used by a Azure Firewall. * - * @param {array} [parameters.urlPathMaps] URL path map of the application - * gateway resource. + * @param {array} [parameters.ipConfigurations] IP configuration of the Azure + * Firewall resource. * - * @param {array} [parameters.requestRoutingRules] Request routing rules of the - * application gateway resource. + * @param {string} [parameters.provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' * - * @param {array} [parameters.redirectConfigurations] Redirect configurations - * of the application gateway resource. + * @param {string} [parameters.id] Resource ID. * - * @param {object} [parameters.webApplicationFirewallConfiguration] Web - * application firewall configuration. + * @param {string} [parameters.location] Resource location. * - * @param {boolean} parameters.webApplicationFirewallConfiguration.enabled - * Whether the web application firewall is enabled or not. + * @param {object} [parameters.tags] Resource tags. * - * @param {string} parameters.webApplicationFirewallConfiguration.firewallMode - * Web application firewall mode. Possible values include: 'Detection', - * 'Prevention' + * @param {object} [options] Optional Parameters. * - * @param {string} parameters.webApplicationFirewallConfiguration.ruleSetType - * The type of the web application firewall rule set. Possible values are: - * 'OWASP'. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} - * parameters.webApplicationFirewallConfiguration.ruleSetVersion The version of - * the rule set type. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {array} - * [parameters.webApplicationFirewallConfiguration.disabledRuleGroups] The - * disabled rule groups. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {boolean} - * [parameters.webApplicationFirewallConfiguration.requestBodyCheck] Whether - * allow WAF to check request Body. + * {Promise} A promise is returned. * - * @param {number} - * [parameters.webApplicationFirewallConfiguration.maxRequestBodySize] Maxium - * request body size for WAF. + * @resolve {AzureFirewall} - The deserialized result object. * - * @param {boolean} [parameters.enableHttp2] Whether HTTP2 is enabled on the - * application gateway resource. + * @reject {Error|ServiceError} - The error object. * - * @param {string} [parameters.resourceGuid] Resource GUID property of the - * application gateway resource. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} [parameters.provisioningState] Provisioning state of the - * application gateway resource. Possible values are: 'Updating', 'Deleting', - * and 'Failed'. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. + * {AzureFirewall} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewall} for more information. * - * @param {string} [parameters.id] Resource ID. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {string} [parameters.location] Resource location. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName: string, azureFirewallName: string, parameters: models.AzureFirewall, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, azureFirewallName: string, parameters: models.AzureFirewall, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, azureFirewallName: string, parameters: models.AzureFirewall, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists all Azure Firewalls in a resource group. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} resourceGroupName The name of the resource group. * * @param {object} [options] Optional Parameters. * @@ -272,138 +253,128 @@ export interface ApplicationGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, parameters: models.ApplicationGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates the specified application gateway. + * Lists all Azure Firewalls in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} applicationGatewayName The name of the application gateway. + * @param {object} [options] Optional Parameters. * - * @param {object} parameters Parameters supplied to the create or update - * application gateway operation. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} [parameters.sku] SKU of the application gateway resource. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} [parameters.sku.name] Name of an application gateway SKU. - * Possible values include: 'Standard_Small', 'Standard_Medium', - * 'Standard_Large', 'WAF_Medium', 'WAF_Large' + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {string} [parameters.sku.tier] Tier of an application gateway. - * Possible values include: 'Standard', 'WAF' + * {Promise} A promise is returned. * - * @param {number} [parameters.sku.capacity] Capacity (instance count) of an - * application gateway. + * @resolve {AzureFirewallListResult} - The deserialized result object. * - * @param {object} [parameters.sslPolicy] SSL policy of the application gateway - * resource. + * @reject {Error|ServiceError} - The error object. * - * @param {array} [parameters.sslPolicy.disabledSslProtocols] Ssl protocols to - * be disabled on application gateway. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} [parameters.sslPolicy.policyType] Type of Ssl Policy. - * Possible values include: 'Predefined', 'Custom' + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [parameters.sslPolicy.policyName] Name of Ssl predefined - * policy. Possible values include: 'AppGwSslPolicy20150501', - * 'AppGwSslPolicy20170401', 'AppGwSslPolicy20170401S' + * {AzureFirewallListResult} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewallListResult} for more + * information. * - * @param {array} [parameters.sslPolicy.cipherSuites] Ssl cipher suites to be - * enabled in the specified order to application gateway. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {string} [parameters.sslPolicy.minProtocolVersion] Minimum version of - * Ssl protocol to be supported on application gateway. Possible values - * include: 'TLSv1_0', 'TLSv1_1', 'TLSv1_2' + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all the Azure Firewalls in a subscription. * - * @param {array} [parameters.gatewayIPConfigurations] Subnets of application - * the gateway resource. + * @param {object} [options] Optional Parameters. * - * @param {array} [parameters.authenticationCertificates] Authentication - * certificates of the application gateway resource. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {array} [parameters.sslCertificates] SSL certificates of the - * application gateway resource. + * @returns {Promise} A promise is returned * - * @param {array} [parameters.frontendIPConfigurations] Frontend IP addresses - * of the application gateway resource. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {array} [parameters.frontendPorts] Frontend ports of the application - * gateway resource. + * @reject {Error|ServiceError} - The error object. + */ + listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all the Azure Firewalls in a subscription. * - * @param {array} [parameters.probes] Probes of the application gateway - * resource. + * @param {object} [options] Optional Parameters. * - * @param {array} [parameters.backendAddressPools] Backend address pool of the - * application gateway resource. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {array} [parameters.backendHttpSettingsCollection] Backend http - * settings of the application gateway resource. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {array} [parameters.httpListeners] Http listeners of the application - * gateway resource. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {array} [parameters.urlPathMaps] URL path map of the application - * gateway resource. + * {Promise} A promise is returned. * - * @param {array} [parameters.requestRoutingRules] Request routing rules of the - * application gateway resource. + * @resolve {AzureFirewallListResult} - The deserialized result object. * - * @param {array} [parameters.redirectConfigurations] Redirect configurations - * of the application gateway resource. + * @reject {Error|ServiceError} - The error object. * - * @param {object} [parameters.webApplicationFirewallConfiguration] Web - * application firewall configuration. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {boolean} parameters.webApplicationFirewallConfiguration.enabled - * Whether the web application firewall is enabled or not. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} parameters.webApplicationFirewallConfiguration.firewallMode - * Web application firewall mode. Possible values include: 'Detection', - * 'Prevention' + * {AzureFirewallListResult} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewallListResult} for more + * information. * - * @param {string} parameters.webApplicationFirewallConfiguration.ruleSetType - * The type of the web application firewall rule set. Possible values are: - * 'OWASP'. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {string} - * parameters.webApplicationFirewallConfiguration.ruleSetVersion The version of - * the rule set type. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAll(callback: ServiceCallback): void; + listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes the specified Azure Firewall. * - * @param {array} - * [parameters.webApplicationFirewallConfiguration.disabledRuleGroups] The - * disabled rule groups. + * @param {string} resourceGroupName The name of the resource group. * - * @param {boolean} - * [parameters.webApplicationFirewallConfiguration.requestBodyCheck] Whether - * allow WAF to check request Body. + * @param {string} azureFirewallName The name of the Azure Firewall. * - * @param {number} - * [parameters.webApplicationFirewallConfiguration.maxRequestBodySize] Maxium - * request body size for WAF. + * @param {object} [options] Optional Parameters. * - * @param {boolean} [parameters.enableHttp2] Whether HTTP2 is enabled on the - * application gateway resource. - * - * @param {string} [parameters.resourceGuid] Resource GUID property of the - * application gateway resource. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.provisioningState] Provisioning state of the - * application gateway resource. Possible values are: 'Updating', 'Deleting', - * and 'Failed'. + * @returns {Promise} A promise is returned * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [parameters.id] Resource ID. + * @reject {Error|ServiceError} - The error object. + */ + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, azureFirewallName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes the specified Azure Firewall. * - * @param {string} [parameters.location] Resource location. + * @param {string} resourceGroupName The name of the resource group. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} azureFirewallName The name of the Azure Firewall. * * @param {object} [options] Optional Parameters. * @@ -417,7 +388,7 @@ export interface ApplicationGateways { * * {Promise} A promise is returned. * - * @resolve {ApplicationGateway} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -425,27 +396,43 @@ export interface ApplicationGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ApplicationGateway} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationGateway} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, applicationGatewayName: string, parameters: models.ApplicationGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, applicationGatewayName: string, parameters: models.ApplicationGateway, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, applicationGatewayName: string, parameters: models.ApplicationGateway, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, azureFirewallName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, azureFirewallName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, azureFirewallName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates the specified application gateway tags. + * Creates or updates the specified Azure Firewall. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} applicationGatewayName The name of the application gateway. + * @param {string} azureFirewallName The name of the Azure Firewall. * - * @param {object} parameters Parameters supplied to update application gateway - * tags. + * @param {object} parameters Parameters supplied to the create or update Azure + * Firewall operation. + * + * @param {array} [parameters.applicationRuleCollections] Collection of + * application rule collections used by a Azure Firewall. + * + * @param {array} [parameters.networkRuleCollections] Collection of network + * rule collections used by a Azure Firewall. + * + * @param {array} [parameters.ipConfigurations] IP configuration of the Azure + * Firewall resource. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. * * @param {object} [parameters.tags] Resource tags. * @@ -456,21 +443,38 @@ export interface ApplicationGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateTagsWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, azureFirewallName: string, parameters: models.AzureFirewall, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates the specified application gateway tags. + * Creates or updates the specified Azure Firewall. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} applicationGatewayName The name of the application gateway. + * @param {string} azureFirewallName The name of the Azure Firewall. * - * @param {object} parameters Parameters supplied to update application gateway - * tags. + * @param {object} parameters Parameters supplied to the create or update Azure + * Firewall operation. + * + * @param {array} [parameters.applicationRuleCollections] Collection of + * application rule collections used by a Azure Firewall. + * + * @param {array} [parameters.networkRuleCollections] Collection of network + * rule collections used by a Azure Firewall. + * + * @param {array} [parameters.ipConfigurations] IP configuration of the Azure + * Firewall resource. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. * * @param {object} [parameters.tags] Resource tags. * @@ -486,7 +490,7 @@ export interface ApplicationGateways { * * {Promise} A promise is returned. * - * @resolve {ApplicationGateway} - The deserialized result object. + * @resolve {AzureFirewall} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -494,22 +498,23 @@ export interface ApplicationGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ApplicationGateway} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationGateway} for more information. + * {AzureFirewall} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewall} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - updateTags(resourceGroupName: string, applicationGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - updateTags(resourceGroupName: string, applicationGatewayName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - updateTags(resourceGroupName: string, applicationGatewayName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, azureFirewallName: string, parameters: models.AzureFirewall, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, azureFirewallName: string, parameters: models.AzureFirewall, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, azureFirewallName: string, parameters: models.AzureFirewall, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists all application gateways in a resource group. + * Lists all Azure Firewalls in a resource group. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -518,16 +523,17 @@ export interface ApplicationGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists all application gateways in a resource group. + * Lists all Azure Firewalls in a resource group. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -541,7 +547,7 @@ export interface ApplicationGateways { * * {Promise} A promise is returned. * - * @resolve {ApplicationGatewayListResult} - The deserialized result object. + * @resolve {AzureFirewallListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -549,21 +555,24 @@ export interface ApplicationGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ApplicationGatewayListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationGatewayListResult} for more + * {AzureFirewallListResult} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewallListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the application gateways in a subscription. + * Gets all the Azure Firewalls in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -572,14 +581,17 @@ export interface ApplicationGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the application gateways in a subscription. + * Gets all the Azure Firewalls in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -593,7 +605,7 @@ export interface ApplicationGateways { * * {Promise} A promise is returned. * - * @resolve {ApplicationGatewayListResult} - The deserialized result object. + * @resolve {AzureFirewallListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -601,21 +613,30 @@ export interface ApplicationGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ApplicationGatewayListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationGatewayListResult} for more + * {AzureFirewallListResult} [result] - The deserialized result object if an error did not occur. + * See {@link AzureFirewallListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAll(callback: ServiceCallback): void; - listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAllNext(nextPageLink: string, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ApplicationGateways + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface ApplicationGateways { /** - * Starts the specified application gateway. + * Deletes the specified application gateway. * * @param {string} resourceGroupName The name of the resource group. * @@ -632,10 +653,10 @@ export interface ApplicationGateways { * * @reject {Error|ServiceError} - The error object. */ - startWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Starts the specified application gateway. + * Deletes the specified application gateway. * * @param {string} resourceGroupName The name of the resource group. * @@ -667,13 +688,13 @@ export interface ApplicationGateways { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - start(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - start(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; - start(resourceGroupName: string, applicationGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, applicationGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Stops the specified application gateway in a resource group. + * Gets the specified application gateway. * * @param {string} resourceGroupName The name of the resource group. * @@ -686,14 +707,14 @@ export interface ApplicationGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - stopWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Stops the specified application gateway in a resource group. + * Gets the specified application gateway. * * @param {string} resourceGroupName The name of the resource group. * @@ -711,7 +732,7 @@ export interface ApplicationGateways { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ApplicationGateway} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -719,305 +740,160 @@ export interface ApplicationGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ApplicationGateway} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationGateway} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - stop(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - stop(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; - stop(resourceGroupName: string, applicationGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, applicationGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the backend health of the specified application gateway in a resource - * group. + * Creates or updates the specified application gateway. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} applicationGatewayName The name of the application gateway. * - * @param {object} [options] Optional Parameters. - * - * @param {string} [options.expand] Expands BackendAddressPool and - * BackendHttpSettings referenced in backend health. + * @param {object} parameters Parameters supplied to the create or update + * application gateway operation. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {object} [parameters.sku] SKU of the application gateway resource. * - * @returns {Promise} A promise is returned + * @param {string} [parameters.sku.name] Name of an application gateway SKU. + * Possible values include: 'Standard_Small', 'Standard_Medium', + * 'Standard_Large', 'WAF_Medium', 'WAF_Large', 'Standard_v2', 'WAF_v2' * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} [parameters.sku.tier] Tier of an application gateway. + * Possible values include: 'Standard', 'WAF', 'Standard_v2', 'WAF_v2' * - * @reject {Error|ServiceError} - The error object. - */ - backendHealthWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets the backend health of the specified application gateway in a resource - * group. + * @param {number} [parameters.sku.capacity] Capacity (instance count) of an + * application gateway. * - * @param {string} resourceGroupName The name of the resource group. + * @param {object} [parameters.sslPolicy] SSL policy of the application gateway + * resource. * - * @param {string} applicationGatewayName The name of the application gateway. + * @param {array} [parameters.sslPolicy.disabledSslProtocols] Ssl protocols to + * be disabled on application gateway. * - * @param {object} [options] Optional Parameters. + * @param {string} [parameters.sslPolicy.policyType] Type of Ssl Policy. + * Possible values include: 'Predefined', 'Custom' * - * @param {string} [options.expand] Expands BackendAddressPool and - * BackendHttpSettings referenced in backend health. + * @param {string} [parameters.sslPolicy.policyName] Name of Ssl predefined + * policy. Possible values include: 'AppGwSslPolicy20150501', + * 'AppGwSslPolicy20170401', 'AppGwSslPolicy20170401S' * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {array} [parameters.sslPolicy.cipherSuites] Ssl cipher suites to be + * enabled in the specified order to application gateway. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {string} [parameters.sslPolicy.minProtocolVersion] Minimum version of + * Ssl protocol to be supported on application gateway. Possible values + * include: 'TLSv1_0', 'TLSv1_1', 'TLSv1_2' * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {array} [parameters.gatewayIPConfigurations] Subnets of application + * the gateway resource. * - * {Promise} A promise is returned. + * @param {array} [parameters.authenticationCertificates] Authentication + * certificates of the application gateway resource. * - * @resolve {ApplicationGatewayBackendHealth} - The deserialized result object. + * @param {array} [parameters.sslCertificates] SSL certificates of the + * application gateway resource. * - * @reject {Error|ServiceError} - The error object. + * @param {array} [parameters.frontendIPConfigurations] Frontend IP addresses + * of the application gateway resource. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {array} [parameters.frontendPorts] Frontend ports of the application + * gateway resource. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {array} [parameters.probes] Probes of the application gateway + * resource. * - * {ApplicationGatewayBackendHealth} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationGatewayBackendHealth} for more - * information. + * @param {array} [parameters.backendAddressPools] Backend address pool of the + * application gateway resource. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {array} [parameters.backendHttpSettingsCollection] Backend http + * settings of the application gateway resource. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - backendHealth(resourceGroupName: string, applicationGatewayName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - backendHealth(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; - backendHealth(resourceGroupName: string, applicationGatewayName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Lists all available web application firewall rule sets. + * @param {array} [parameters.httpListeners] Http listeners of the application + * gateway resource. * - * @param {object} [options] Optional Parameters. + * @param {array} [parameters.urlPathMaps] URL path map of the application + * gateway resource. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {array} [parameters.requestRoutingRules] Request routing rules of the + * application gateway resource. * - * @returns {Promise} A promise is returned + * @param {array} [parameters.redirectConfigurations] Redirect configurations + * of the application gateway resource. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {object} [parameters.webApplicationFirewallConfiguration] Web + * application firewall configuration. * - * @reject {Error|ServiceError} - The error object. - */ - listAvailableWafRuleSetsWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Lists all available web application firewall rule sets. + * @param {boolean} parameters.webApplicationFirewallConfiguration.enabled + * Whether the web application firewall is enabled or not. * - * @param {object} [options] Optional Parameters. + * @param {string} parameters.webApplicationFirewallConfiguration.firewallMode + * Web application firewall mode. Possible values include: 'Detection', + * 'Prevention' * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} parameters.webApplicationFirewallConfiguration.ruleSetType + * The type of the web application firewall rule set. Possible values are: + * 'OWASP'. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {string} + * parameters.webApplicationFirewallConfiguration.ruleSetVersion The version of + * the rule set type. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {ApplicationGatewayAvailableWafRuleSetsResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {ApplicationGatewayAvailableWafRuleSetsResult} [result] - The deserialized result object if an error did not occur. - * See {@link - * ApplicationGatewayAvailableWafRuleSetsResult} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listAvailableWafRuleSets(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAvailableWafRuleSets(callback: ServiceCallback): void; - listAvailableWafRuleSets(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Lists available Ssl options for configuring Ssl policy. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listAvailableSslOptionsWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Lists available Ssl options for configuring Ssl policy. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {ApplicationGatewayAvailableSslOptions} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {ApplicationGatewayAvailableSslOptions} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationGatewayAvailableSslOptions} for - * more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listAvailableSslOptions(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAvailableSslOptions(callback: ServiceCallback): void; - listAvailableSslOptions(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Lists all SSL predefined policies for configuring Ssl policy. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listAvailableSslPredefinedPoliciesWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Lists all SSL predefined policies for configuring Ssl policy. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {ApplicationGatewayAvailableSslPredefinedPolicies} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {ApplicationGatewayAvailableSslPredefinedPolicies} [result] - The deserialized result object if an error did not occur. - * See {@link - * ApplicationGatewayAvailableSslPredefinedPolicies} for - * more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listAvailableSslPredefinedPolicies(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAvailableSslPredefinedPolicies(callback: ServiceCallback): void; - listAvailableSslPredefinedPolicies(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets Ssl predefined policy with the specified policy name. - * - * @param {string} predefinedPolicyName Name of Ssl predefined policy. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - getSslPredefinedPolicyWithHttpOperationResponse(predefinedPolicyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets Ssl predefined policy with the specified policy name. + * @param {array} + * [parameters.webApplicationFirewallConfiguration.disabledRuleGroups] The + * disabled rule groups. * - * @param {string} predefinedPolicyName Name of Ssl predefined policy. + * @param {boolean} + * [parameters.webApplicationFirewallConfiguration.requestBodyCheck] Whether + * allow WAF to check request Body. * - * @param {object} [options] Optional Parameters. + * @param {number} + * [parameters.webApplicationFirewallConfiguration.maxRequestBodySize] Maxium + * request body size for WAF. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {boolean} [parameters.enableHttp2] Whether HTTP2 is enabled on the + * application gateway resource. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {boolean} [parameters.enableFips] Whether FIPS is enabled on the + * application gateway resource. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {object} [parameters.autoscaleConfiguration] Autoscale Configuration. * - * {Promise} A promise is returned. + * @param {object} parameters.autoscaleConfiguration.bounds Autoscale bounds * - * @resolve {ApplicationGatewaySslPredefinedPolicy} - The deserialized result object. + * @param {number} parameters.autoscaleConfiguration.bounds.min Lower bound on + * number of Application Gateway instances. * - * @reject {Error|ServiceError} - The error object. + * @param {number} parameters.autoscaleConfiguration.bounds.max Upper bound on + * number of Application Gateway instances. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {string} [parameters.resourceGuid] Resource GUID property of the + * application gateway resource. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {string} [parameters.provisioningState] Provisioning state of the + * application gateway resource. Possible values are: 'Updating', 'Deleting', + * and 'Failed'. * - * {ApplicationGatewaySslPredefinedPolicy} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationGatewaySslPredefinedPolicy} for - * more information. + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {array} [parameters.zones] A list of availability zones denoting + * where the resource needs to come from. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - getSslPredefinedPolicy(predefinedPolicyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getSslPredefinedPolicy(predefinedPolicyName: string, callback: ServiceCallback): void; - getSslPredefinedPolicy(predefinedPolicyName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Deletes the specified application gateway. + * @param {string} [parameters.id] Resource ID. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [parameters.location] Resource location. * - * @param {string} applicationGatewayName The name of the application gateway. + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -1026,49 +902,11 @@ export interface ApplicationGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Deletes the specified application gateway. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} applicationGatewayName The name of the application gateway. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {null} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {null} [result] - The deserialized result object if an error did not occur. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginDeleteMethod(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, applicationGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, parameters: models.ApplicationGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Creates or updates the specified application gateway. @@ -1084,10 +922,10 @@ export interface ApplicationGateways { * * @param {string} [parameters.sku.name] Name of an application gateway SKU. * Possible values include: 'Standard_Small', 'Standard_Medium', - * 'Standard_Large', 'WAF_Medium', 'WAF_Large' + * 'Standard_Large', 'WAF_Medium', 'WAF_Large', 'Standard_v2', 'WAF_v2' * * @param {string} [parameters.sku.tier] Tier of an application gateway. - * Possible values include: 'Standard', 'WAF' + * Possible values include: 'Standard', 'WAF', 'Standard_v2', 'WAF_v2' * * @param {number} [parameters.sku.capacity] Capacity (instance count) of an * application gateway. @@ -1181,6 +1019,19 @@ export interface ApplicationGateways { * @param {boolean} [parameters.enableHttp2] Whether HTTP2 is enabled on the * application gateway resource. * + * @param {boolean} [parameters.enableFips] Whether FIPS is enabled on the + * application gateway resource. + * + * @param {object} [parameters.autoscaleConfiguration] Autoscale Configuration. + * + * @param {object} parameters.autoscaleConfiguration.bounds Autoscale bounds + * + * @param {number} parameters.autoscaleConfiguration.bounds.min Lower bound on + * number of Application Gateway instances. + * + * @param {number} parameters.autoscaleConfiguration.bounds.max Upper bound on + * number of Application Gateway instances. + * * @param {string} [parameters.resourceGuid] Resource GUID property of the * application gateway resource. * @@ -1191,6 +1042,9 @@ export interface ApplicationGateways { * @param {string} [parameters.etag] A unique read-only string that changes * whenever the resource is updated. * + * @param {array} [parameters.zones] A list of availability zones denoting + * where the resource needs to come from. + * * @param {string} [parameters.id] Resource ID. * * @param {string} [parameters.location] Resource location. @@ -1202,140 +1056,124 @@ export interface ApplicationGateways { * @param {object} [options.customHeaders] Headers that will be added to the * request * - * @returns {Promise} A promise is returned + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @reject {Error|ServiceError} - The error object. - */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, parameters: models.ApplicationGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Creates or updates the specified application gateway. - * - * @param {string} resourceGroupName The name of the resource group. + * {Promise} A promise is returned. * - * @param {string} applicationGatewayName The name of the application gateway. + * @resolve {ApplicationGateway} - The deserialized result object. * - * @param {object} parameters Parameters supplied to the create or update - * application gateway operation. + * @reject {Error|ServiceError} - The error object. * - * @param {object} [parameters.sku] SKU of the application gateway resource. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} [parameters.sku.name] Name of an application gateway SKU. - * Possible values include: 'Standard_Small', 'Standard_Medium', - * 'Standard_Large', 'WAF_Medium', 'WAF_Large' + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [parameters.sku.tier] Tier of an application gateway. - * Possible values include: 'Standard', 'WAF' + * {ApplicationGateway} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationGateway} for more information. * - * @param {number} [parameters.sku.capacity] Capacity (instance count) of an - * application gateway. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {object} [parameters.sslPolicy] SSL policy of the application gateway - * resource. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName: string, applicationGatewayName: string, parameters: models.ApplicationGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, applicationGatewayName: string, parameters: models.ApplicationGateway, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, applicationGatewayName: string, parameters: models.ApplicationGateway, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Updates the specified application gateway tags. * - * @param {array} [parameters.sslPolicy.disabledSslProtocols] Ssl protocols to - * be disabled on application gateway. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [parameters.sslPolicy.policyType] Type of Ssl Policy. - * Possible values include: 'Predefined', 'Custom' + * @param {string} applicationGatewayName The name of the application gateway. * - * @param {string} [parameters.sslPolicy.policyName] Name of Ssl predefined - * policy. Possible values include: 'AppGwSslPolicy20150501', - * 'AppGwSslPolicy20170401', 'AppGwSslPolicy20170401S' + * @param {object} parameters Parameters supplied to update application gateway + * tags. * - * @param {array} [parameters.sslPolicy.cipherSuites] Ssl cipher suites to be - * enabled in the specified order to application gateway. + * @param {object} [parameters.tags] Resource tags. * - * @param {string} [parameters.sslPolicy.minProtocolVersion] Minimum version of - * Ssl protocol to be supported on application gateway. Possible values - * include: 'TLSv1_0', 'TLSv1_1', 'TLSv1_2' + * @param {object} [options] Optional Parameters. * - * @param {array} [parameters.gatewayIPConfigurations] Subnets of application - * the gateway resource. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {array} [parameters.authenticationCertificates] Authentication - * certificates of the application gateway resource. + * @returns {Promise} A promise is returned * - * @param {array} [parameters.sslCertificates] SSL certificates of the - * application gateway resource. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {array} [parameters.frontendIPConfigurations] Frontend IP addresses - * of the application gateway resource. + * @reject {Error|ServiceError} - The error object. + */ + updateTagsWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Updates the specified application gateway tags. * - * @param {array} [parameters.frontendPorts] Frontend ports of the application - * gateway resource. + * @param {string} resourceGroupName The name of the resource group. * - * @param {array} [parameters.probes] Probes of the application gateway - * resource. + * @param {string} applicationGatewayName The name of the application gateway. * - * @param {array} [parameters.backendAddressPools] Backend address pool of the - * application gateway resource. + * @param {object} parameters Parameters supplied to update application gateway + * tags. * - * @param {array} [parameters.backendHttpSettingsCollection] Backend http - * settings of the application gateway resource. + * @param {object} [parameters.tags] Resource tags. * - * @param {array} [parameters.httpListeners] Http listeners of the application - * gateway resource. + * @param {object} [options] Optional Parameters. * - * @param {array} [parameters.urlPathMaps] URL path map of the application - * gateway resource. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {array} [parameters.requestRoutingRules] Request routing rules of the - * application gateway resource. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {array} [parameters.redirectConfigurations] Redirect configurations - * of the application gateway resource. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {object} [parameters.webApplicationFirewallConfiguration] Web - * application firewall configuration. + * {Promise} A promise is returned. * - * @param {boolean} parameters.webApplicationFirewallConfiguration.enabled - * Whether the web application firewall is enabled or not. + * @resolve {ApplicationGateway} - The deserialized result object. * - * @param {string} parameters.webApplicationFirewallConfiguration.firewallMode - * Web application firewall mode. Possible values include: 'Detection', - * 'Prevention' + * @reject {Error|ServiceError} - The error object. * - * @param {string} parameters.webApplicationFirewallConfiguration.ruleSetType - * The type of the web application firewall rule set. Possible values are: - * 'OWASP'. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} - * parameters.webApplicationFirewallConfiguration.ruleSetVersion The version of - * the rule set type. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {array} - * [parameters.webApplicationFirewallConfiguration.disabledRuleGroups] The - * disabled rule groups. + * {ApplicationGateway} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationGateway} for more information. * - * @param {boolean} - * [parameters.webApplicationFirewallConfiguration.requestBodyCheck] Whether - * allow WAF to check request Body. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {number} - * [parameters.webApplicationFirewallConfiguration.maxRequestBodySize] Maxium - * request body size for WAF. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + updateTags(resourceGroupName: string, applicationGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, applicationGatewayName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, applicationGatewayName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists all application gateways in a resource group. * - * @param {boolean} [parameters.enableHttp2] Whether HTTP2 is enabled on the - * application gateway resource. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [parameters.resourceGuid] Resource GUID property of the - * application gateway resource. + * @param {object} [options] Optional Parameters. * - * @param {string} [parameters.provisioningState] Provisioning state of the - * application gateway resource. Possible values are: 'Updating', 'Deleting', - * and 'Failed'. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. + * @returns {Promise} A promise is returned * - * @param {string} [parameters.id] Resource ID. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [parameters.location] Resource location. + * @reject {Error|ServiceError} - The error object. + */ + listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists all application gateways in a resource group. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} resourceGroupName The name of the resource group. * * @param {object} [options] Optional Parameters. * @@ -1349,7 +1187,7 @@ export interface ApplicationGateways { * * {Promise} A promise is returned. * - * @resolve {ApplicationGateway} - The deserialized result object. + * @resolve {ApplicationGatewayListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -1357,29 +1195,21 @@ export interface ApplicationGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ApplicationGateway} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationGateway} for more information. + * {ApplicationGatewayListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationGatewayListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, applicationGatewayName: string, parameters: models.ApplicationGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, applicationGatewayName: string, parameters: models.ApplicationGateway, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, applicationGatewayName: string, parameters: models.ApplicationGateway, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates the specified application gateway tags. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} applicationGatewayName The name of the application gateway. - * - * @param {object} parameters Parameters supplied to update application gateway - * tags. - * - * @param {object} [parameters.tags] Resource tags. + * Gets all the application gateways in a subscription. * * @param {object} [options] Optional Parameters. * @@ -1388,23 +1218,14 @@ export interface ApplicationGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates the specified application gateway tags. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} applicationGatewayName The name of the application gateway. - * - * @param {object} parameters Parameters supplied to update application gateway - * tags. - * - * @param {object} [parameters.tags] Resource tags. + * Gets all the application gateways in a subscription. * * @param {object} [options] Optional Parameters. * @@ -1418,7 +1239,7 @@ export interface ApplicationGateways { * * {Promise} A promise is returned. * - * @resolve {ApplicationGateway} - The deserialized result object. + * @resolve {ApplicationGatewayListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -1426,16 +1247,17 @@ export interface ApplicationGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ApplicationGateway} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationGateway} for more information. + * {ApplicationGatewayListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationGatewayListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdateTags(resourceGroupName: string, applicationGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdateTags(resourceGroupName: string, applicationGatewayName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - beginUpdateTags(resourceGroupName: string, applicationGatewayName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAll(callback: ServiceCallback): void; + listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -1456,7 +1278,7 @@ export interface ApplicationGateways { * * @reject {Error|ServiceError} - The error object. */ - beginStartWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + startWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Starts the specified application gateway. @@ -1491,9 +1313,9 @@ export interface ApplicationGateways { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginStart(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginStart(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; - beginStart(resourceGroupName: string, applicationGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + start(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + start(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; + start(resourceGroupName: string, applicationGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -1514,7 +1336,7 @@ export interface ApplicationGateways { * * @reject {Error|ServiceError} - The error object. */ - beginStopWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + stopWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Stops the specified application gateway in a resource group. @@ -1549,9 +1371,9 @@ export interface ApplicationGateways { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginStop(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginStop(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; - beginStop(resourceGroupName: string, applicationGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + stop(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + stop(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; + stop(resourceGroupName: string, applicationGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -1576,7 +1398,7 @@ export interface ApplicationGateways { * * @reject {Error|ServiceError} - The error object. */ - beginBackendHealthWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + backendHealthWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Gets the backend health of the specified application gateway in a resource @@ -1617,16 +1439,13 @@ export interface ApplicationGateways { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginBackendHealth(resourceGroupName: string, applicationGatewayName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - beginBackendHealth(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; - beginBackendHealth(resourceGroupName: string, applicationGatewayName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + backendHealth(resourceGroupName: string, applicationGatewayName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + backendHealth(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; + backendHealth(resourceGroupName: string, applicationGatewayName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists all application gateways in a resource group. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * Lists all available web application firewall rule sets. * * @param {object} [options] Optional Parameters. * @@ -1635,17 +1454,14 @@ export interface ApplicationGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAvailableWafRuleSetsWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists all application gateways in a resource group. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * Lists all available web application firewall rule sets. * * @param {object} [options] Optional Parameters. * @@ -1659,7 +1475,7 @@ export interface ApplicationGateways { * * {Promise} A promise is returned. * - * @resolve {ApplicationGatewayListResult} - The deserialized result object. + * @resolve {ApplicationGatewayAvailableWafRuleSetsResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -1667,24 +1483,22 @@ export interface ApplicationGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ApplicationGatewayListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationGatewayListResult} for more + * {ApplicationGatewayAvailableWafRuleSetsResult} [result] - The deserialized result object if an error did not occur. + * See {@link + * ApplicationGatewayAvailableWafRuleSetsResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAvailableWafRuleSets(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAvailableWafRuleSets(callback: ServiceCallback): void; + listAvailableWafRuleSets(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the application gateways in a subscription. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * Lists available Ssl options for configuring Ssl policy. * * @param {object} [options] Optional Parameters. * @@ -1693,17 +1507,14 @@ export interface ApplicationGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAvailableSslOptionsWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the application gateways in a subscription. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * Lists available Ssl options for configuring Ssl policy. * * @param {object} [options] Optional Parameters. * @@ -1717,7 +1528,7 @@ export interface ApplicationGateways { * * {Promise} A promise is returned. * - * @resolve {ApplicationGatewayListResult} - The deserialized result object. + * @resolve {ApplicationGatewayAvailableSslOptions} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -1725,25 +1536,22 @@ export interface ApplicationGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ApplicationGatewayListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationGatewayListResult} for more - * information. + * {ApplicationGatewayAvailableSslOptions} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationGatewayAvailableSslOptions} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAllNext(nextPageLink: string, callback: ServiceCallback): void; - listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAvailableSslOptions(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAvailableSslOptions(callback: ServiceCallback): void; + listAvailableSslOptions(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Lists all SSL predefined policies for configuring Ssl policy. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -1755,14 +1563,11 @@ export interface ApplicationGateways { * * @reject {Error|ServiceError} - The error object. */ - listAvailableSslPredefinedPoliciesNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAvailableSslPredefinedPoliciesWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Lists all SSL predefined policies for configuring Ssl policy. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -1792,27 +1597,15 @@ export interface ApplicationGateways { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAvailableSslPredefinedPoliciesNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAvailableSslPredefinedPoliciesNext(nextPageLink: string, callback: ServiceCallback): void; - listAvailableSslPredefinedPoliciesNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * ApplicationSecurityGroups - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface ApplicationSecurityGroups { + listAvailableSslPredefinedPolicies(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAvailableSslPredefinedPolicies(callback: ServiceCallback): void; + listAvailableSslPredefinedPolicies(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified application security group. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets Ssl predefined policy with the specified policy name. * - * @param {string} applicationSecurityGroupName The name of the application - * security group. + * @param {string} predefinedPolicyName Name of Ssl predefined policy. * * @param {object} [options] Optional Parameters. * @@ -1821,19 +1614,16 @@ export interface ApplicationSecurityGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, applicationSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getSslPredefinedPolicyWithHttpOperationResponse(predefinedPolicyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified application security group. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets Ssl predefined policy with the specified policy name. * - * @param {string} applicationSecurityGroupName The name of the application - * security group. + * @param {string} predefinedPolicyName Name of Ssl predefined policy. * * @param {object} [options] Optional Parameters. * @@ -1847,7 +1637,7 @@ export interface ApplicationSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ApplicationGatewaySslPredefinedPolicy} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -1855,24 +1645,25 @@ export interface ApplicationSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ApplicationGatewaySslPredefinedPolicy} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationGatewaySslPredefinedPolicy} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, applicationSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, applicationSecurityGroupName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, applicationSecurityGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + getSslPredefinedPolicy(predefinedPolicyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getSslPredefinedPolicy(predefinedPolicyName: string, callback: ServiceCallback): void; + getSslPredefinedPolicy(predefinedPolicyName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets information about the specified application security group. + * Deletes the specified application gateway. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} applicationSecurityGroupName The name of the application - * security group. + * @param {string} applicationGatewayName The name of the application gateway. * * @param {object} [options] Optional Parameters. * @@ -1881,19 +1672,18 @@ export interface ApplicationSecurityGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, applicationSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets information about the specified application security group. + * Deletes the specified application gateway. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} applicationSecurityGroupName The name of the application - * security group. + * @param {string} applicationGatewayName The name of the application gateway. * * @param {object} [options] Optional Parameters. * @@ -1907,7 +1697,7 @@ export interface ApplicationSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {ApplicationSecurityGroup} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -1915,155 +1705,159 @@ export interface ApplicationSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ApplicationSecurityGroup} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationSecurityGroup} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, applicationSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, applicationSecurityGroupName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, applicationSecurityGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, applicationGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates an application security group. + * Creates or updates the specified application gateway. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} applicationSecurityGroupName The name of the application - * security group. + * @param {string} applicationGatewayName The name of the application gateway. * * @param {object} parameters Parameters supplied to the create or update - * ApplicationSecurityGroup operation. + * application gateway operation. * - * @param {string} [parameters.id] Resource ID. + * @param {object} [parameters.sku] SKU of the application gateway resource. * - * @param {string} [parameters.location] Resource location. + * @param {string} [parameters.sku.name] Name of an application gateway SKU. + * Possible values include: 'Standard_Small', 'Standard_Medium', + * 'Standard_Large', 'WAF_Medium', 'WAF_Large', 'Standard_v2', 'WAF_v2' * - * @param {object} [parameters.tags] Resource tags. + * @param {string} [parameters.sku.tier] Tier of an application gateway. + * Possible values include: 'Standard', 'WAF', 'Standard_v2', 'WAF_v2' * - * @param {object} [options] Optional Parameters. + * @param {number} [parameters.sku.capacity] Capacity (instance count) of an + * application gateway. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {object} [parameters.sslPolicy] SSL policy of the application gateway + * resource. * - * @returns {Promise} A promise is returned + * @param {array} [parameters.sslPolicy.disabledSslProtocols] Ssl protocols to + * be disabled on application gateway. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} [parameters.sslPolicy.policyType] Type of Ssl Policy. + * Possible values include: 'Predefined', 'Custom' * - * @reject {Error|ServiceError} - The error object. - */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, applicationSecurityGroupName: string, parameters: models.ApplicationSecurityGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Creates or updates an application security group. + * @param {string} [parameters.sslPolicy.policyName] Name of Ssl predefined + * policy. Possible values include: 'AppGwSslPolicy20150501', + * 'AppGwSslPolicy20170401', 'AppGwSslPolicy20170401S' * - * @param {string} resourceGroupName The name of the resource group. + * @param {array} [parameters.sslPolicy.cipherSuites] Ssl cipher suites to be + * enabled in the specified order to application gateway. * - * @param {string} applicationSecurityGroupName The name of the application - * security group. + * @param {string} [parameters.sslPolicy.minProtocolVersion] Minimum version of + * Ssl protocol to be supported on application gateway. Possible values + * include: 'TLSv1_0', 'TLSv1_1', 'TLSv1_2' * - * @param {object} parameters Parameters supplied to the create or update - * ApplicationSecurityGroup operation. + * @param {array} [parameters.gatewayIPConfigurations] Subnets of application + * the gateway resource. * - * @param {string} [parameters.id] Resource ID. + * @param {array} [parameters.authenticationCertificates] Authentication + * certificates of the application gateway resource. * - * @param {string} [parameters.location] Resource location. + * @param {array} [parameters.sslCertificates] SSL certificates of the + * application gateway resource. * - * @param {object} [parameters.tags] Resource tags. + * @param {array} [parameters.frontendIPConfigurations] Frontend IP addresses + * of the application gateway resource. * - * @param {object} [options] Optional Parameters. + * @param {array} [parameters.frontendPorts] Frontend ports of the application + * gateway resource. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {array} [parameters.probes] Probes of the application gateway + * resource. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {array} [parameters.backendAddressPools] Backend address pool of the + * application gateway resource. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {array} [parameters.backendHttpSettingsCollection] Backend http + * settings of the application gateway resource. * - * {Promise} A promise is returned. + * @param {array} [parameters.httpListeners] Http listeners of the application + * gateway resource. * - * @resolve {ApplicationSecurityGroup} - The deserialized result object. + * @param {array} [parameters.urlPathMaps] URL path map of the application + * gateway resource. * - * @reject {Error|ServiceError} - The error object. + * @param {array} [parameters.requestRoutingRules] Request routing rules of the + * application gateway resource. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {array} [parameters.redirectConfigurations] Redirect configurations + * of the application gateway resource. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {object} [parameters.webApplicationFirewallConfiguration] Web + * application firewall configuration. * - * {ApplicationSecurityGroup} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationSecurityGroup} for more - * information. + * @param {boolean} parameters.webApplicationFirewallConfiguration.enabled + * Whether the web application firewall is enabled or not. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {string} parameters.webApplicationFirewallConfiguration.firewallMode + * Web application firewall mode. Possible values include: 'Detection', + * 'Prevention' * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - createOrUpdate(resourceGroupName: string, applicationSecurityGroupName: string, parameters: models.ApplicationSecurityGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, applicationSecurityGroupName: string, parameters: models.ApplicationSecurityGroup, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, applicationSecurityGroupName: string, parameters: models.ApplicationSecurityGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets all application security groups in a subscription. + * @param {string} parameters.webApplicationFirewallConfiguration.ruleSetType + * The type of the web application firewall rule set. Possible values are: + * 'OWASP'. * - * @param {object} [options] Optional Parameters. + * @param {string} + * parameters.webApplicationFirewallConfiguration.ruleSetVersion The version of + * the rule set type. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {array} + * [parameters.webApplicationFirewallConfiguration.disabledRuleGroups] The + * disabled rule groups. * - * @returns {Promise} A promise is returned + * @param {boolean} + * [parameters.webApplicationFirewallConfiguration.requestBodyCheck] Whether + * allow WAF to check request Body. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {number} + * [parameters.webApplicationFirewallConfiguration.maxRequestBodySize] Maxium + * request body size for WAF. * - * @reject {Error|ServiceError} - The error object. - */ - listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets all application security groups in a subscription. + * @param {boolean} [parameters.enableHttp2] Whether HTTP2 is enabled on the + * application gateway resource. * - * @param {object} [options] Optional Parameters. + * @param {boolean} [parameters.enableFips] Whether FIPS is enabled on the + * application gateway resource. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {object} [parameters.autoscaleConfiguration] Autoscale Configuration. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {object} parameters.autoscaleConfiguration.bounds Autoscale bounds * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {number} parameters.autoscaleConfiguration.bounds.min Lower bound on + * number of Application Gateway instances. * - * {Promise} A promise is returned. + * @param {number} parameters.autoscaleConfiguration.bounds.max Upper bound on + * number of Application Gateway instances. * - * @resolve {ApplicationSecurityGroupListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. + * @param {string} [parameters.resourceGuid] Resource GUID property of the + * application gateway resource. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {string} [parameters.provisioningState] Provisioning state of the + * application gateway resource. Possible values are: 'Updating', 'Deleting', + * and 'Failed'. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. * - * {ApplicationSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationSecurityGroupListResult} for more - * information. + * @param {array} [parameters.zones] A list of availability zones denoting + * where the resource needs to come from. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {string} [parameters.id] Resource ID. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAll(callback: ServiceCallback): void; - listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets all the application security groups in a resource group. + * @param {string} [parameters.location] Resource location. * - * @param {string} resourceGroupName The name of the resource group. + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -2072,78 +1866,154 @@ export interface ApplicationSecurityGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, parameters: models.ApplicationGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the application security groups in a resource group. + * Creates or updates the specified application gateway. * * @param {string} resourceGroupName The name of the resource group. * - * @param {object} [options] Optional Parameters. + * @param {string} applicationGatewayName The name of the application gateway. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {object} parameters Parameters supplied to the create or update + * application gateway operation. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {object} [parameters.sku] SKU of the application gateway resource. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {string} [parameters.sku.name] Name of an application gateway SKU. + * Possible values include: 'Standard_Small', 'Standard_Medium', + * 'Standard_Large', 'WAF_Medium', 'WAF_Large', 'Standard_v2', 'WAF_v2' * - * {Promise} A promise is returned. + * @param {string} [parameters.sku.tier] Tier of an application gateway. + * Possible values include: 'Standard', 'WAF', 'Standard_v2', 'WAF_v2' * - * @resolve {ApplicationSecurityGroupListResult} - The deserialized result object. + * @param {number} [parameters.sku.capacity] Capacity (instance count) of an + * application gateway. * - * @reject {Error|ServiceError} - The error object. + * @param {object} [parameters.sslPolicy] SSL policy of the application gateway + * resource. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {array} [parameters.sslPolicy.disabledSslProtocols] Ssl protocols to + * be disabled on application gateway. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {string} [parameters.sslPolicy.policyType] Type of Ssl Policy. + * Possible values include: 'Predefined', 'Custom' * - * {ApplicationSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationSecurityGroupListResult} for more - * information. + * @param {string} [parameters.sslPolicy.policyName] Name of Ssl predefined + * policy. Possible values include: 'AppGwSslPolicy20150501', + * 'AppGwSslPolicy20170401', 'AppGwSslPolicy20170401S' * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {array} [parameters.sslPolicy.cipherSuites] Ssl cipher suites to be + * enabled in the specified order to application gateway. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Deletes the specified application security group. + * @param {string} [parameters.sslPolicy.minProtocolVersion] Minimum version of + * Ssl protocol to be supported on application gateway. Possible values + * include: 'TLSv1_0', 'TLSv1_1', 'TLSv1_2' * - * @param {string} resourceGroupName The name of the resource group. + * @param {array} [parameters.gatewayIPConfigurations] Subnets of application + * the gateway resource. * - * @param {string} applicationSecurityGroupName The name of the application - * security group. + * @param {array} [parameters.authenticationCertificates] Authentication + * certificates of the application gateway resource. * - * @param {object} [options] Optional Parameters. + * @param {array} [parameters.sslCertificates] SSL certificates of the + * application gateway resource. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {array} [parameters.frontendIPConfigurations] Frontend IP addresses + * of the application gateway resource. * - * @returns {Promise} A promise is returned + * @param {array} [parameters.frontendPorts] Frontend ports of the application + * gateway resource. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {array} [parameters.probes] Probes of the application gateway + * resource. * - * @reject {Error|ServiceError} - The error object. - */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, applicationSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Deletes the specified application security group. + * @param {array} [parameters.backendAddressPools] Backend address pool of the + * application gateway resource. * - * @param {string} resourceGroupName The name of the resource group. + * @param {array} [parameters.backendHttpSettingsCollection] Backend http + * settings of the application gateway resource. * - * @param {string} applicationSecurityGroupName The name of the application - * security group. + * @param {array} [parameters.httpListeners] Http listeners of the application + * gateway resource. + * + * @param {array} [parameters.urlPathMaps] URL path map of the application + * gateway resource. + * + * @param {array} [parameters.requestRoutingRules] Request routing rules of the + * application gateway resource. + * + * @param {array} [parameters.redirectConfigurations] Redirect configurations + * of the application gateway resource. + * + * @param {object} [parameters.webApplicationFirewallConfiguration] Web + * application firewall configuration. + * + * @param {boolean} parameters.webApplicationFirewallConfiguration.enabled + * Whether the web application firewall is enabled or not. + * + * @param {string} parameters.webApplicationFirewallConfiguration.firewallMode + * Web application firewall mode. Possible values include: 'Detection', + * 'Prevention' + * + * @param {string} parameters.webApplicationFirewallConfiguration.ruleSetType + * The type of the web application firewall rule set. Possible values are: + * 'OWASP'. + * + * @param {string} + * parameters.webApplicationFirewallConfiguration.ruleSetVersion The version of + * the rule set type. + * + * @param {array} + * [parameters.webApplicationFirewallConfiguration.disabledRuleGroups] The + * disabled rule groups. + * + * @param {boolean} + * [parameters.webApplicationFirewallConfiguration.requestBodyCheck] Whether + * allow WAF to check request Body. + * + * @param {number} + * [parameters.webApplicationFirewallConfiguration.maxRequestBodySize] Maxium + * request body size for WAF. + * + * @param {boolean} [parameters.enableHttp2] Whether HTTP2 is enabled on the + * application gateway resource. + * + * @param {boolean} [parameters.enableFips] Whether FIPS is enabled on the + * application gateway resource. + * + * @param {object} [parameters.autoscaleConfiguration] Autoscale Configuration. + * + * @param {object} parameters.autoscaleConfiguration.bounds Autoscale bounds + * + * @param {number} parameters.autoscaleConfiguration.bounds.min Lower bound on + * number of Application Gateway instances. + * + * @param {number} parameters.autoscaleConfiguration.bounds.max Upper bound on + * number of Application Gateway instances. + * + * @param {string} [parameters.resourceGuid] Resource GUID property of the + * application gateway resource. + * + * @param {string} [parameters.provisioningState] Provisioning state of the + * application gateway resource. Possible values are: 'Updating', 'Deleting', + * and 'Failed'. + * + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. + * + * @param {array} [parameters.zones] A list of availability zones denoting + * where the resource needs to come from. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -2157,7 +2027,7 @@ export interface ApplicationSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ApplicationGateway} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -2165,31 +2035,27 @@ export interface ApplicationSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ApplicationGateway} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationGateway} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, applicationSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, applicationSecurityGroupName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, applicationSecurityGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, applicationGatewayName: string, parameters: models.ApplicationGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, applicationGatewayName: string, parameters: models.ApplicationGateway, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, applicationGatewayName: string, parameters: models.ApplicationGateway, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates an application security group. + * Updates the specified application gateway tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} applicationSecurityGroupName The name of the application - * security group. - * - * @param {object} parameters Parameters supplied to the create or update - * ApplicationSecurityGroup operation. - * - * @param {string} [parameters.id] Resource ID. + * @param {string} applicationGatewayName The name of the application gateway. * - * @param {string} [parameters.location] Resource location. + * @param {object} parameters Parameters supplied to update application gateway + * tags. * * @param {object} [parameters.tags] Resource tags. * @@ -2200,26 +2066,21 @@ export interface ApplicationSecurityGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, applicationSecurityGroupName: string, parameters: models.ApplicationSecurityGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates an application security group. + * Updates the specified application gateway tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} applicationSecurityGroupName The name of the application - * security group. - * - * @param {object} parameters Parameters supplied to the create or update - * ApplicationSecurityGroup operation. - * - * @param {string} [parameters.id] Resource ID. + * @param {string} applicationGatewayName The name of the application gateway. * - * @param {string} [parameters.location] Resource location. + * @param {object} parameters Parameters supplied to update application gateway + * tags. * * @param {object} [parameters.tags] Resource tags. * @@ -2235,7 +2096,7 @@ export interface ApplicationSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {ApplicationSecurityGroup} - The deserialized result object. + * @resolve {ApplicationGateway} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -2243,24 +2104,24 @@ export interface ApplicationSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ApplicationSecurityGroup} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationSecurityGroup} for more - * information. + * {ApplicationGateway} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationGateway} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, applicationSecurityGroupName: string, parameters: models.ApplicationSecurityGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, applicationSecurityGroupName: string, parameters: models.ApplicationSecurityGroup, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, applicationSecurityGroupName: string, parameters: models.ApplicationSecurityGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, applicationGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdateTags(resourceGroupName: string, applicationGatewayName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, applicationGatewayName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all application security groups in a subscription. + * Starts the specified application gateway. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} applicationGatewayName The name of the application gateway. * * @param {object} [options] Optional Parameters. * @@ -2269,17 +2130,18 @@ export interface ApplicationSecurityGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginStartWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all application security groups in a subscription. + * Starts the specified application gateway. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} applicationGatewayName The name of the application gateway. * * @param {object} [options] Optional Parameters. * @@ -2293,7 +2155,7 @@ export interface ApplicationSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {ApplicationSecurityGroupListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -2301,24 +2163,23 @@ export interface ApplicationSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ApplicationSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationSecurityGroupListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAllNext(nextPageLink: string, callback: ServiceCallback): void; - listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginStart(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginStart(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; + beginStart(resourceGroupName: string, applicationGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the application security groups in a resource group. + * Stops the specified application gateway in a resource group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} applicationGatewayName The name of the application gateway. * * @param {object} [options] Optional Parameters. * @@ -2327,17 +2188,18 @@ export interface ApplicationSecurityGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginStopWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the application security groups in a resource group. + * Stops the specified application gateway in a resource group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} applicationGatewayName The name of the application gateway. * * @param {object} [options] Optional Parameters. * @@ -2351,7 +2213,7 @@ export interface ApplicationSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {ApplicationSecurityGroupListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -2359,57 +2221,54 @@ export interface ApplicationSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ApplicationSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ApplicationSecurityGroupListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * DdosProtectionPlans - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface DdosProtectionPlans { + beginStop(resourceGroupName: string, applicationGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginStop(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; + beginStop(resourceGroupName: string, applicationGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified DDoS protection plan. + * Gets the backend health of the specified application gateway in a resource + * group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. + * @param {string} applicationGatewayName The name of the application gateway. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands BackendAddressPool and + * BackendHttpSettings referenced in backend health. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, ddosProtectionPlanName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginBackendHealthWithHttpOperationResponse(resourceGroupName: string, applicationGatewayName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified DDoS protection plan. + * Gets the backend health of the specified application gateway in a resource + * group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. + * @param {string} applicationGatewayName The name of the application gateway. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands BackendAddressPool and + * BackendHttpSettings referenced in backend health. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -2420,7 +2279,7 @@ export interface DdosProtectionPlans { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ApplicationGatewayBackendHealth} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -2428,23 +2287,24 @@ export interface DdosProtectionPlans { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ApplicationGatewayBackendHealth} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationGatewayBackendHealth} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, ddosProtectionPlanName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, ddosProtectionPlanName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, ddosProtectionPlanName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginBackendHealth(resourceGroupName: string, applicationGatewayName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + beginBackendHealth(resourceGroupName: string, applicationGatewayName: string, callback: ServiceCallback): void; + beginBackendHealth(resourceGroupName: string, applicationGatewayName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets information about the specified DDoS protection plan. - * - * @param {string} resourceGroupName The name of the resource group. + * Lists all application gateways in a resource group. * - * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -2453,18 +2313,17 @@ export interface DdosProtectionPlans { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, ddosProtectionPlanName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets information about the specified DDoS protection plan. - * - * @param {string} resourceGroupName The name of the resource group. + * Lists all application gateways in a resource group. * - * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -2478,7 +2337,7 @@ export interface DdosProtectionPlans { * * {Promise} A promise is returned. * - * @resolve {DdosProtectionPlan} - The deserialized result object. + * @resolve {ApplicationGatewayListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -2486,33 +2345,24 @@ export interface DdosProtectionPlans { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {DdosProtectionPlan} [result] - The deserialized result object if an error did not occur. - * See {@link DdosProtectionPlan} for more information. + * {ApplicationGatewayListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationGatewayListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, ddosProtectionPlanName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, ddosProtectionPlanName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, ddosProtectionPlanName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a DDoS protection plan. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. - * - * @param {object} parameters Parameters supplied to the create or update - * operation. - * - * @param {string} [parameters.id] Resource ID. - * - * @param {string} [parameters.location] Resource location. + * Gets all the application gateways in a subscription. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -2521,27 +2371,17 @@ export interface DdosProtectionPlans { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, ddosProtectionPlanName: string, parameters: models.DdosProtectionPlan, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a DDoS protection plan. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. - * - * @param {object} parameters Parameters supplied to the create or update - * operation. - * - * @param {string} [parameters.id] Resource ID. - * - * @param {string} [parameters.location] Resource location. + * Gets all the application gateways in a subscription. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -2555,7 +2395,7 @@ export interface DdosProtectionPlans { * * {Promise} A promise is returned. * - * @resolve {DdosProtectionPlan} - The deserialized result object. + * @resolve {ApplicationGatewayListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -2563,20 +2403,24 @@ export interface DdosProtectionPlans { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {DdosProtectionPlan} [result] - The deserialized result object if an error did not occur. - * See {@link DdosProtectionPlan} for more information. + * {ApplicationGatewayListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationGatewayListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, ddosProtectionPlanName: string, parameters: models.DdosProtectionPlan, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, ddosProtectionPlanName: string, parameters: models.DdosProtectionPlan, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, ddosProtectionPlanName: string, parameters: models.DdosProtectionPlan, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAllNext(nextPageLink: string, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all DDoS protection plans in a subscription. + * Lists all SSL predefined policies for configuring Ssl policy. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -2585,14 +2429,17 @@ export interface DdosProtectionPlans { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAvailableSslPredefinedPoliciesNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all DDoS protection plans in a subscription. + * Lists all SSL predefined policies for configuring Ssl policy. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -2606,7 +2453,7 @@ export interface DdosProtectionPlans { * * {Promise} A promise is returned. * - * @resolve {DdosProtectionPlanListResult} - The deserialized result object. + * @resolve {ApplicationGatewayAvailableSslPredefinedPolicies} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -2614,24 +2461,37 @@ export interface DdosProtectionPlans { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {DdosProtectionPlanListResult} [result] - The deserialized result object if an error did not occur. - * See {@link DdosProtectionPlanListResult} for more - * information. + * {ApplicationGatewayAvailableSslPredefinedPolicies} [result] - The deserialized result object if an error did not occur. + * See {@link + * ApplicationGatewayAvailableSslPredefinedPolicies} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(callback: ServiceCallback): void; - list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAvailableSslPredefinedPoliciesNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAvailableSslPredefinedPoliciesNext(nextPageLink: string, callback: ServiceCallback): void; + listAvailableSslPredefinedPoliciesNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ApplicationSecurityGroups + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface ApplicationSecurityGroups { /** - * Gets all the DDoS protection plans in a resource group. + * Deletes the specified application security group. * * @param {string} resourceGroupName The name of the resource group. * + * @param {string} applicationSecurityGroupName The name of the application + * security group. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -2639,17 +2499,20 @@ export interface DdosProtectionPlans { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByResourceGroupWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, applicationSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the DDoS protection plans in a resource group. + * Deletes the specified application security group. * * @param {string} resourceGroupName The name of the resource group. * + * @param {string} applicationSecurityGroupName The name of the application + * security group. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -2662,7 +2525,7 @@ export interface DdosProtectionPlans { * * {Promise} A promise is returned. * - * @resolve {DdosProtectionPlanListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -2670,25 +2533,24 @@ export interface DdosProtectionPlans { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {DdosProtectionPlanListResult} [result] - The deserialized result object if an error did not occur. - * See {@link DdosProtectionPlanListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByResourceGroup(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByResourceGroup(resourceGroupName: string, callback: ServiceCallback): void; - listByResourceGroup(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, applicationSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, applicationSecurityGroupName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, applicationSecurityGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified DDoS protection plan. + * Gets information about the specified application security group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. + * @param {string} applicationSecurityGroupName The name of the application + * security group. * * @param {object} [options] Optional Parameters. * @@ -2697,18 +2559,19 @@ export interface DdosProtectionPlans { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, ddosProtectionPlanName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, applicationSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified DDoS protection plan. + * Gets information about the specified application security group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. + * @param {string} applicationSecurityGroupName The name of the application + * security group. * * @param {object} [options] Optional Parameters. * @@ -2722,7 +2585,7 @@ export interface DdosProtectionPlans { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ApplicationSecurityGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -2730,26 +2593,29 @@ export interface DdosProtectionPlans { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ApplicationSecurityGroup} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationSecurityGroup} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, ddosProtectionPlanName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, ddosProtectionPlanName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, ddosProtectionPlanName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, applicationSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, applicationSecurityGroupName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, applicationSecurityGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a DDoS protection plan. + * Creates or updates an application security group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. + * @param {string} applicationSecurityGroupName The name of the application + * security group. * * @param {object} parameters Parameters supplied to the create or update - * operation. + * ApplicationSecurityGroup operation. * * @param {string} [parameters.id] Resource ID. * @@ -2764,21 +2630,22 @@ export interface DdosProtectionPlans { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, ddosProtectionPlanName: string, parameters: models.DdosProtectionPlan, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, applicationSecurityGroupName: string, parameters: models.ApplicationSecurityGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a DDoS protection plan. + * Creates or updates an application security group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. + * @param {string} applicationSecurityGroupName The name of the application + * security group. * * @param {object} parameters Parameters supplied to the create or update - * operation. + * ApplicationSecurityGroup operation. * * @param {string} [parameters.id] Resource ID. * @@ -2798,7 +2665,7 @@ export interface DdosProtectionPlans { * * {Promise} A promise is returned. * - * @resolve {DdosProtectionPlan} - The deserialized result object. + * @resolve {ApplicationSecurityGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -2806,23 +2673,21 @@ export interface DdosProtectionPlans { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {DdosProtectionPlan} [result] - The deserialized result object if an error did not occur. - * See {@link DdosProtectionPlan} for more information. + * {ApplicationSecurityGroup} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationSecurityGroup} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, ddosProtectionPlanName: string, parameters: models.DdosProtectionPlan, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, ddosProtectionPlanName: string, parameters: models.DdosProtectionPlan, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, ddosProtectionPlanName: string, parameters: models.DdosProtectionPlan, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, applicationSecurityGroupName: string, parameters: models.ApplicationSecurityGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, applicationSecurityGroupName: string, parameters: models.ApplicationSecurityGroup, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, applicationSecurityGroupName: string, parameters: models.ApplicationSecurityGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all DDoS protection plans in a subscription. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * Gets all application security groups in a subscription. * * @param {object} [options] Optional Parameters. * @@ -2831,17 +2696,14 @@ export interface DdosProtectionPlans { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all DDoS protection plans in a subscription. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * Gets all application security groups in a subscription. * * @param {object} [options] Optional Parameters. * @@ -2855,7 +2717,7 @@ export interface DdosProtectionPlans { * * {Promise} A promise is returned. * - * @resolve {DdosProtectionPlanListResult} - The deserialized result object. + * @resolve {ApplicationSecurityGroupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -2863,24 +2725,23 @@ export interface DdosProtectionPlans { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {DdosProtectionPlanListResult} [result] - The deserialized result object if an error did not occur. - * See {@link DdosProtectionPlanListResult} for more + * {ApplicationSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationSecurityGroupListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAll(callback: ServiceCallback): void; + listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the DDoS protection plans in a resource group. + * Gets all the application security groups in a resource group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. * * @param {object} [options] Optional Parameters. * @@ -2889,17 +2750,16 @@ export interface DdosProtectionPlans { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByResourceGroupNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the DDoS protection plans in a resource group. + * Gets all the application security groups in a resource group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. * * @param {object} [options] Optional Parameters. * @@ -2913,7 +2773,7 @@ export interface DdosProtectionPlans { * * {Promise} A promise is returned. * - * @resolve {DdosProtectionPlanListResult} - The deserialized result object. + * @resolve {ApplicationSecurityGroupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -2921,32 +2781,26 @@ export interface DdosProtectionPlans { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {DdosProtectionPlanListResult} [result] - The deserialized result object if an error did not occur. - * See {@link DdosProtectionPlanListResult} for more + * {ApplicationSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationSecurityGroupListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByResourceGroupNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByResourceGroupNext(nextPageLink: string, callback: ServiceCallback): void; - listByResourceGroupNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * AvailableEndpointServices - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface AvailableEndpointServices { + list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * List what values of endpoint services are available for use. + * Deletes the specified application security group. * - * @param {string} location The location to check available endpoint services. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} applicationSecurityGroupName The name of the application + * security group. * * @param {object} [options] Optional Parameters. * @@ -2955,16 +2809,19 @@ export interface AvailableEndpointServices { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(location: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, applicationSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * List what values of endpoint services are available for use. + * Deletes the specified application security group. * - * @param {string} location The location to check available endpoint services. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} applicationSecurityGroupName The name of the application + * security group. * * @param {object} [options] Optional Parameters. * @@ -2978,7 +2835,7 @@ export interface AvailableEndpointServices { * * {Promise} A promise is returned. * - * @resolve {EndpointServicesListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -2986,24 +2843,33 @@ export interface AvailableEndpointServices { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {EndpointServicesListResult} [result] - The deserialized result object if an error did not occur. - * See {@link EndpointServicesListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(location: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(location: string, callback: ServiceCallback): void; - list(location: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, applicationSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, applicationSecurityGroupName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, applicationSecurityGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * List what values of endpoint services are available for use. + * Creates or updates an application security group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} applicationSecurityGroupName The name of the application + * security group. + * + * @param {object} parameters Parameters supplied to the create or update + * ApplicationSecurityGroup operation. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -3012,17 +2878,28 @@ export interface AvailableEndpointServices { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, applicationSecurityGroupName: string, parameters: models.ApplicationSecurityGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * List what values of endpoint services are available for use. + * Creates or updates an application security group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} applicationSecurityGroupName The name of the application + * security group. + * + * @param {object} parameters Parameters supplied to the create or update + * ApplicationSecurityGroup operation. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -3036,7 +2913,7 @@ export interface AvailableEndpointServices { * * {Promise} A promise is returned. * - * @resolve {EndpointServicesListResult} - The deserialized result object. + * @resolve {ApplicationSecurityGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -3044,37 +2921,24 @@ export interface AvailableEndpointServices { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {EndpointServicesListResult} [result] - The deserialized result object if an error did not occur. - * See {@link EndpointServicesListResult} for more + * {ApplicationSecurityGroup} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationSecurityGroup} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * ExpressRouteCircuitAuthorizations - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface ExpressRouteCircuitAuthorizations { + beginCreateOrUpdate(resourceGroupName: string, applicationSecurityGroupName: string, parameters: models.ApplicationSecurityGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, applicationSecurityGroupName: string, parameters: models.ApplicationSecurityGroup, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, applicationSecurityGroupName: string, parameters: models.ApplicationSecurityGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified authorization from the specified express route - * circuit. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} circuitName The name of the express route circuit. + * Gets all application security groups in a subscription. * - * @param {string} authorizationName The name of the authorization. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -3083,21 +2947,17 @@ export interface ExpressRouteCircuitAuthorizations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, circuitName: string, authorizationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified authorization from the specified express route - * circuit. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} circuitName The name of the express route circuit. + * Gets all application security groups in a subscription. * - * @param {string} authorizationName The name of the authorization. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -3111,7 +2971,7 @@ export interface ExpressRouteCircuitAuthorizations { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ApplicationSecurityGroupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -3119,25 +2979,24 @@ export interface ExpressRouteCircuitAuthorizations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ApplicationSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationSecurityGroupListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, circuitName: string, authorizationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, circuitName: string, authorizationName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, circuitName: string, authorizationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAllNext(nextPageLink: string, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified authorization from the specified express route circuit. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} circuitName The name of the express route circuit. + * Gets all the application security groups in a resource group. * - * @param {string} authorizationName The name of the authorization. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -3146,20 +3005,17 @@ export interface ExpressRouteCircuitAuthorizations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, circuitName: string, authorizationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified authorization from the specified express route circuit. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} circuitName The name of the express route circuit. + * Gets all the application security groups in a resource group. * - * @param {string} authorizationName The name of the authorization. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -3173,7 +3029,7 @@ export interface ExpressRouteCircuitAuthorizations { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitAuthorization} - The deserialized result object. + * @resolve {ApplicationSecurityGroupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -3181,47 +3037,34 @@ export interface ExpressRouteCircuitAuthorizations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitAuthorization} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitAuthorization} for more + * {ApplicationSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ApplicationSecurityGroupListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, circuitName: string, authorizationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, circuitName: string, authorizationName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, circuitName: string, authorizationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * DdosProtectionPlans + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface DdosProtectionPlans { /** - * Creates or updates an authorization in the specified express route circuit. + * Deletes the specified DDoS protection plan. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} circuitName The name of the express route circuit. - * - * @param {string} authorizationName The name of the authorization. - * - * @param {object} authorizationParameters Parameters supplied to the create or - * update express route circuit authorization operation. - * - * @param {string} [authorizationParameters.authorizationKey] The authorization - * key. - * - * @param {string} [authorizationParameters.authorizationUseStatus] - * AuthorizationUseStatus. Possible values are: 'Available' and 'InUse'. - * Possible values include: 'Available', 'InUse' - * - * @param {string} [authorizationParameters.provisioningState] Gets the - * provisioning state of the public IP resource. Possible values are: - * 'Updating', 'Deleting', and 'Failed'. - * - * @param {string} [authorizationParameters.name] Gets name of the resource - * that is unique within a resource group. This name can be used to access the - * resource. - * - * @param {string} [authorizationParameters.id] Resource ID. + * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. * * @param {object} [options] Optional Parameters. * @@ -3230,40 +3073,18 @@ export interface ExpressRouteCircuitAuthorizations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, circuitName: string, authorizationName: string, authorizationParameters: models.ExpressRouteCircuitAuthorization, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, ddosProtectionPlanName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates an authorization in the specified express route circuit. + * Deletes the specified DDoS protection plan. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} circuitName The name of the express route circuit. - * - * @param {string} authorizationName The name of the authorization. - * - * @param {object} authorizationParameters Parameters supplied to the create or - * update express route circuit authorization operation. - * - * @param {string} [authorizationParameters.authorizationKey] The authorization - * key. - * - * @param {string} [authorizationParameters.authorizationUseStatus] - * AuthorizationUseStatus. Possible values are: 'Available' and 'InUse'. - * Possible values include: 'Available', 'InUse' - * - * @param {string} [authorizationParameters.provisioningState] Gets the - * provisioning state of the public IP resource. Possible values are: - * 'Updating', 'Deleting', and 'Failed'. - * - * @param {string} [authorizationParameters.name] Gets name of the resource - * that is unique within a resource group. This name can be used to access the - * resource. - * - * @param {string} [authorizationParameters.id] Resource ID. + * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. * * @param {object} [options] Optional Parameters. * @@ -3277,7 +3098,7 @@ export interface ExpressRouteCircuitAuthorizations { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitAuthorization} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -3285,25 +3106,23 @@ export interface ExpressRouteCircuitAuthorizations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitAuthorization} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitAuthorization} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, circuitName: string, authorizationName: string, authorizationParameters: models.ExpressRouteCircuitAuthorization, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, circuitName: string, authorizationName: string, authorizationParameters: models.ExpressRouteCircuitAuthorization, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, circuitName: string, authorizationName: string, authorizationParameters: models.ExpressRouteCircuitAuthorization, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, ddosProtectionPlanName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, ddosProtectionPlanName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, ddosProtectionPlanName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all authorizations in an express route circuit. + * Gets information about the specified DDoS protection plan. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} circuitName The name of the circuit. + * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. * * @param {object} [options] Optional Parameters. * @@ -3312,18 +3131,18 @@ export interface ExpressRouteCircuitAuthorizations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, ddosProtectionPlanName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all authorizations in an express route circuit. + * Gets information about the specified DDoS protection plan. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} circuitName The name of the circuit. + * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. * * @param {object} [options] Optional Parameters. * @@ -3337,7 +3156,7 @@ export interface ExpressRouteCircuitAuthorizations { * * {Promise} A promise is returned. * - * @resolve {AuthorizationListResult} - The deserialized result object. + * @resolve {DdosProtectionPlan} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -3345,28 +3164,31 @@ export interface ExpressRouteCircuitAuthorizations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {AuthorizationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link AuthorizationListResult} for more - * information. + * {DdosProtectionPlan} [result] - The deserialized result object if an error did not occur. + * See {@link DdosProtectionPlan} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, circuitName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, circuitName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, ddosProtectionPlanName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, ddosProtectionPlanName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, ddosProtectionPlanName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified authorization from the specified express route - * circuit. + * Creates or updates a DDoS protection plan. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} circuitName The name of the express route circuit. + * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. * - * @param {string} authorizationName The name of the authorization. + * @param {object} parameters Parameters supplied to the create or update + * operation. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -3375,21 +3197,25 @@ export interface ExpressRouteCircuitAuthorizations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, circuitName: string, authorizationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, ddosProtectionPlanName: string, parameters: models.DdosProtectionPlan, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified authorization from the specified express route - * circuit. + * Creates or updates a DDoS protection plan. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} circuitName The name of the express route circuit. + * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. * - * @param {string} authorizationName The name of the authorization. + * @param {object} parameters Parameters supplied to the create or update + * operation. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -3403,7 +3229,7 @@ export interface ExpressRouteCircuitAuthorizations { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {DdosProtectionPlan} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -3411,45 +3237,20 @@ export interface ExpressRouteCircuitAuthorizations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {DdosProtectionPlan} [result] - The deserialized result object if an error did not occur. + * See {@link DdosProtectionPlan} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, circuitName: string, authorizationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, circuitName: string, authorizationName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, circuitName: string, authorizationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, ddosProtectionPlanName: string, parameters: models.DdosProtectionPlan, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, ddosProtectionPlanName: string, parameters: models.DdosProtectionPlan, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, ddosProtectionPlanName: string, parameters: models.DdosProtectionPlan, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates an authorization in the specified express route circuit. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} circuitName The name of the express route circuit. - * - * @param {string} authorizationName The name of the authorization. - * - * @param {object} authorizationParameters Parameters supplied to the create or - * update express route circuit authorization operation. - * - * @param {string} [authorizationParameters.authorizationKey] The authorization - * key. - * - * @param {string} [authorizationParameters.authorizationUseStatus] - * AuthorizationUseStatus. Possible values are: 'Available' and 'InUse'. - * Possible values include: 'Available', 'InUse' - * - * @param {string} [authorizationParameters.provisioningState] Gets the - * provisioning state of the public IP resource. Possible values are: - * 'Updating', 'Deleting', and 'Failed'. - * - * @param {string} [authorizationParameters.name] Gets name of the resource - * that is unique within a resource group. This name can be used to access the - * resource. - * - * @param {string} [authorizationParameters.id] Resource ID. + * Gets all DDoS protection plans in a subscription. * * @param {object} [options] Optional Parameters. * @@ -3458,40 +3259,14 @@ export interface ExpressRouteCircuitAuthorizations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, circuitName: string, authorizationName: string, authorizationParameters: models.ExpressRouteCircuitAuthorization, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates an authorization in the specified express route circuit. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} circuitName The name of the express route circuit. - * - * @param {string} authorizationName The name of the authorization. - * - * @param {object} authorizationParameters Parameters supplied to the create or - * update express route circuit authorization operation. - * - * @param {string} [authorizationParameters.authorizationKey] The authorization - * key. - * - * @param {string} [authorizationParameters.authorizationUseStatus] - * AuthorizationUseStatus. Possible values are: 'Available' and 'InUse'. - * Possible values include: 'Available', 'InUse' - * - * @param {string} [authorizationParameters.provisioningState] Gets the - * provisioning state of the public IP resource. Possible values are: - * 'Updating', 'Deleting', and 'Failed'. - * - * @param {string} [authorizationParameters.name] Gets name of the resource - * that is unique within a resource group. This name can be used to access the - * resource. - * - * @param {string} [authorizationParameters.id] Resource ID. + * Gets all DDoS protection plans in a subscription. * * @param {object} [options] Optional Parameters. * @@ -3505,7 +3280,7 @@ export interface ExpressRouteCircuitAuthorizations { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitAuthorization} - The deserialized result object. + * @resolve {DdosProtectionPlanListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -3513,24 +3288,23 @@ export interface ExpressRouteCircuitAuthorizations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitAuthorization} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitAuthorization} for more + * {DdosProtectionPlanListResult} [result] - The deserialized result object if an error did not occur. + * See {@link DdosProtectionPlanListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, circuitName: string, authorizationName: string, authorizationParameters: models.ExpressRouteCircuitAuthorization, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, circuitName: string, authorizationName: string, authorizationParameters: models.ExpressRouteCircuitAuthorization, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, circuitName: string, authorizationName: string, authorizationParameters: models.ExpressRouteCircuitAuthorization, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(callback: ServiceCallback): void; + list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all authorizations in an express route circuit. + * Gets all the DDoS protection plans in a resource group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. * * @param {object} [options] Optional Parameters. * @@ -3539,17 +3313,16 @@ export interface ExpressRouteCircuitAuthorizations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByResourceGroupWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all authorizations in an express route circuit. + * Gets all the DDoS protection plans in a resource group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. * * @param {object} [options] Optional Parameters. * @@ -3563,7 +3336,7 @@ export interface ExpressRouteCircuitAuthorizations { * * {Promise} A promise is returned. * - * @resolve {AuthorizationListResult} - The deserialized result object. + * @resolve {DdosProtectionPlanListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -3571,36 +3344,25 @@ export interface ExpressRouteCircuitAuthorizations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {AuthorizationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link AuthorizationListResult} for more + * {DdosProtectionPlanListResult} [result] - The deserialized result object if an error did not occur. + * See {@link DdosProtectionPlanListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * ExpressRouteCircuitPeerings - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface ExpressRouteCircuitPeerings { + listByResourceGroup(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroup(resourceGroupName: string, callback: ServiceCallback): void; + listByResourceGroup(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified peering from the specified express route circuit. + * Deletes the specified DDoS protection plan. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} circuitName The name of the express route circuit. - * - * @param {string} peeringName The name of the peering. + * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. * * @param {object} [options] Optional Parameters. * @@ -3613,16 +3375,14 @@ export interface ExpressRouteCircuitPeerings { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, ddosProtectionPlanName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified peering from the specified express route circuit. + * Deletes the specified DDoS protection plan. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} circuitName The name of the express route circuit. - * - * @param {string} peeringName The name of the peering. + * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. * * @param {object} [options] Optional Parameters. * @@ -3650,19 +3410,24 @@ export interface ExpressRouteCircuitPeerings { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - + beginDeleteMethod(resourceGroupName: string, ddosProtectionPlanName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, ddosProtectionPlanName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, ddosProtectionPlanName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + /** - * Gets the specified authorization from the specified express route circuit. + * Creates or updates a DDoS protection plan. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} circuitName The name of the express route circuit. + * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. * - * @param {string} peeringName The name of the peering. + * @param {object} parameters Parameters supplied to the create or update + * operation. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -3671,20 +3436,25 @@ export interface ExpressRouteCircuitPeerings { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, ddosProtectionPlanName: string, parameters: models.DdosProtectionPlan, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified authorization from the specified express route circuit. + * Creates or updates a DDoS protection plan. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} circuitName The name of the express route circuit. + * @param {string} ddosProtectionPlanName The name of the DDoS protection plan. * - * @param {string} peeringName The name of the peering. + * @param {object} parameters Parameters supplied to the create or update + * operation. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -3698,7 +3468,7 @@ export interface ExpressRouteCircuitPeerings { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitPeering} - The deserialized result object. + * @resolve {DdosProtectionPlan} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -3706,157 +3476,147 @@ export interface ExpressRouteCircuitPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitPeering} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitPeering} for more - * information. + * {DdosProtectionPlan} [result] - The deserialized result object if an error did not occur. + * See {@link DdosProtectionPlan} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, circuitName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, circuitName: string, peeringName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, circuitName: string, peeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, ddosProtectionPlanName: string, parameters: models.DdosProtectionPlan, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, ddosProtectionPlanName: string, parameters: models.DdosProtectionPlan, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, ddosProtectionPlanName: string, parameters: models.DdosProtectionPlan, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a peering in the specified express route circuits. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} circuitName The name of the express route circuit. - * - * @param {string} peeringName The name of the peering. - * - * @param {object} peeringParameters Parameters supplied to the create or - * update express route circuit peering operation. - * - * @param {string} [peeringParameters.peeringType] The peering type. Possible - * values include: 'AzurePublicPeering', 'AzurePrivatePeering', - * 'MicrosoftPeering' + * Gets all DDoS protection plans in a subscription. * - * @param {string} [peeringParameters.state] The peering state. Possible values - * include: 'Disabled', 'Enabled' + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {number} [peeringParameters.azureASN] The Azure ASN. + * @param {object} [options] Optional Parameters. * - * @param {number} [peeringParameters.peerASN] The peer ASN. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [peeringParameters.primaryPeerAddressPrefix] The primary - * address prefix. + * @returns {Promise} A promise is returned * - * @param {string} [peeringParameters.secondaryPeerAddressPrefix] The secondary - * address prefix. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [peeringParameters.primaryAzurePort] The primary port. + * @reject {Error|ServiceError} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all DDoS protection plans in a subscription. * - * @param {string} [peeringParameters.secondaryAzurePort] The secondary port. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {string} [peeringParameters.sharedKey] The shared key. + * @param {object} [options] Optional Parameters. * - * @param {number} [peeringParameters.vlanId] The VLAN ID. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft - * peering configuration. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {object} [peeringParameters.stats] Gets peering stats. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {number} [peeringParameters.stats.primarybytesIn] Gets BytesIn of the - * peering. + * {Promise} A promise is returned. * - * @param {number} [peeringParameters.stats.primarybytesOut] Gets BytesOut of - * the peering. + * @resolve {DdosProtectionPlanListResult} - The deserialized result object. * - * @param {number} [peeringParameters.stats.secondarybytesIn] Gets BytesIn of - * the peering. + * @reject {Error|ServiceError} - The error object. * - * @param {number} [peeringParameters.stats.secondarybytesOut] Gets BytesOut of - * the peering. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} [peeringParameters.provisioningState] Gets the provisioning - * state of the public IP resource. Possible values are: 'Updating', - * 'Deleting', and 'Failed'. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager - * Etag. + * {DdosProtectionPlanListResult} [result] - The deserialized result object if an error did not occur. + * See {@link DdosProtectionPlanListResult} for more + * information. * - * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider - * or the customer last modified the peering. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {object} [peeringParameters.routeFilter] The reference of the - * RouteFilter resource. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all the DDoS protection plans in a resource group. * - * @param {object} [peeringParameters.ipv6PeeringConfig] The IPv6 peering - * configuration. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.primaryPeerAddressPrefix] The primary - * address prefix. + * @param {object} [options] Optional Parameters. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.secondaryPeerAddressPrefix] The - * secondary address prefix. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig] - * The Microsoft peering configuration. + * @returns {Promise} A promise is returned * - * @param {array} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixes] - * The reference of AdvertisedPublicPrefixes. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {array} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedCommunities] - * The communities of bgp peering. Spepcified for microsoft peering + * @reject {Error|ServiceError} - The error object. + */ + listByResourceGroupNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all the DDoS protection plans in a resource group. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixesState] - * AdvertisedPublicPrefixState of the Peering resource. Possible values are - * 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. - * Possible values include: 'NotConfigured', 'Configuring', 'Configured', - * 'ValidationNeeded' + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {number} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.legacyMode] The - * legacy mode of the peering. + * @param {object} [options] Optional Parameters. * - * @param {number} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.customerASN] The - * CustomerASN of the peering. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.routingRegistryName] - * The RoutingRegistryName of the configuration. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter] The - * reference of the RouteFilter resource. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.rules] - * Collection of RouteFilterRules contained within a route filter. + * {Promise} A promise is returned. * - * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.peerings] A - * collection of references to express route circuit peerings. + * @resolve {DdosProtectionPlanListResult} - The deserialized result object. * - * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.id] - * Resource ID. + * @reject {Error|ServiceError} - The error object. * - * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.location] - * Resource location. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter.tags] - * Resource tags. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [peeringParameters.ipv6PeeringConfig.state] The state of - * peering. Possible values are: 'Disabled' and 'Enabled'. Possible values - * include: 'Disabled', 'Enabled' + * {DdosProtectionPlanListResult} [result] - The deserialized result object if an error did not occur. + * See {@link DdosProtectionPlanListResult} for more + * information. * - * @param {array} [peeringParameters.connections] The list of circuit - * connections associated with Azure Private Peering for this circuit. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {string} [peeringParameters.name] Gets name of the resource that is - * unique within a resource group. This name can be used to access the - * resource. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listByResourceGroupNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroupNext(nextPageLink: string, callback: ServiceCallback): void; + listByResourceGroupNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * AvailableEndpointServices + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface AvailableEndpointServices { + + + /** + * List what values of endpoint services are available for use. * - * @param {string} [peeringParameters.id] Resource ID. + * @param {string} location The location to check available endpoint services. * * @param {object} [options] Optional Parameters. * @@ -3865,150 +3625,74 @@ export interface ExpressRouteCircuitPeerings { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, peeringParameters: models.ExpressRouteCircuitPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(location: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a peering in the specified express route circuits. + * List what values of endpoint services are available for use. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} location The location to check available endpoint services. * - * @param {string} circuitName The name of the express route circuit. + * @param {object} [options] Optional Parameters. * - * @param {string} peeringName The name of the peering. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} peeringParameters Parameters supplied to the create or - * update express route circuit peering operation. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} [peeringParameters.peeringType] The peering type. Possible - * values include: 'AzurePublicPeering', 'AzurePrivatePeering', - * 'MicrosoftPeering' + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {string} [peeringParameters.state] The peering state. Possible values - * include: 'Disabled', 'Enabled' + * {Promise} A promise is returned. * - * @param {number} [peeringParameters.azureASN] The Azure ASN. + * @resolve {EndpointServicesListResult} - The deserialized result object. * - * @param {number} [peeringParameters.peerASN] The peer ASN. - * - * @param {string} [peeringParameters.primaryPeerAddressPrefix] The primary - * address prefix. - * - * @param {string} [peeringParameters.secondaryPeerAddressPrefix] The secondary - * address prefix. - * - * @param {string} [peeringParameters.primaryAzurePort] The primary port. - * - * @param {string} [peeringParameters.secondaryAzurePort] The secondary port. - * - * @param {string} [peeringParameters.sharedKey] The shared key. - * - * @param {number} [peeringParameters.vlanId] The VLAN ID. - * - * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft - * peering configuration. - * - * @param {object} [peeringParameters.stats] Gets peering stats. - * - * @param {number} [peeringParameters.stats.primarybytesIn] Gets BytesIn of the - * peering. - * - * @param {number} [peeringParameters.stats.primarybytesOut] Gets BytesOut of - * the peering. - * - * @param {number} [peeringParameters.stats.secondarybytesIn] Gets BytesIn of - * the peering. - * - * @param {number} [peeringParameters.stats.secondarybytesOut] Gets BytesOut of - * the peering. - * - * @param {string} [peeringParameters.provisioningState] Gets the provisioning - * state of the public IP resource. Possible values are: 'Updating', - * 'Deleting', and 'Failed'. - * - * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager - * Etag. - * - * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider - * or the customer last modified the peering. - * - * @param {object} [peeringParameters.routeFilter] The reference of the - * RouteFilter resource. - * - * @param {object} [peeringParameters.ipv6PeeringConfig] The IPv6 peering - * configuration. - * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.primaryPeerAddressPrefix] The primary - * address prefix. - * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.secondaryPeerAddressPrefix] The - * secondary address prefix. - * - * @param {object} [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig] - * The Microsoft peering configuration. - * - * @param {array} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixes] - * The reference of AdvertisedPublicPrefixes. - * - * @param {array} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedCommunities] - * The communities of bgp peering. Spepcified for microsoft peering - * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixesState] - * AdvertisedPublicPrefixState of the Peering resource. Possible values are - * 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. - * Possible values include: 'NotConfigured', 'Configuring', 'Configured', - * 'ValidationNeeded' - * - * @param {number} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.legacyMode] The - * legacy mode of the peering. + * @reject {Error|ServiceError} - The error object. * - * @param {number} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.customerASN] The - * CustomerASN of the peering. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.routingRegistryName] - * The RoutingRegistryName of the configuration. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter] The - * reference of the RouteFilter resource. + * {EndpointServicesListResult} [result] - The deserialized result object if an error did not occur. + * See {@link EndpointServicesListResult} for more + * information. * - * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.rules] - * Collection of RouteFilterRules contained within a route filter. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.peerings] A - * collection of references to express route circuit peerings. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + list(location: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(location: string, callback: ServiceCallback): void; + list(location: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * List what values of endpoint services are available for use. * - * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.id] - * Resource ID. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.location] - * Resource location. + * @param {object} [options] Optional Parameters. * - * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter.tags] - * Resource tags. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [peeringParameters.ipv6PeeringConfig.state] The state of - * peering. Possible values are: 'Disabled' and 'Enabled'. Possible values - * include: 'Disabled', 'Enabled' + * @returns {Promise} A promise is returned * - * @param {array} [peeringParameters.connections] The list of circuit - * connections associated with Azure Private Peering for this circuit. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [peeringParameters.name] Gets name of the resource that is - * unique within a resource group. This name can be used to access the - * resource. + * @reject {Error|ServiceError} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * List what values of endpoint services are available for use. * - * @param {string} [peeringParameters.id] Resource ID. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -4022,7 +3706,7 @@ export interface ExpressRouteCircuitPeerings { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitPeering} - The deserialized result object. + * @resolve {EndpointServicesListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -4030,26 +3714,38 @@ export interface ExpressRouteCircuitPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitPeering} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitPeering} for more + * {EndpointServicesListResult} [result] - The deserialized result object if an error did not occur. + * See {@link EndpointServicesListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, peeringParameters: models.ExpressRouteCircuitPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, peeringParameters: models.ExpressRouteCircuitPeering, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, peeringParameters: models.ExpressRouteCircuitPeering, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ExpressRouteCircuitAuthorizations + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface ExpressRouteCircuitAuthorizations { /** - * Gets all peerings in a specified express route circuit. + * Deletes the specified authorization from the specified express route + * circuit. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} circuitName The name of the express route circuit. * + * @param {string} authorizationName The name of the authorization. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -4057,19 +3753,22 @@ export interface ExpressRouteCircuitPeerings { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, circuitName: string, authorizationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all peerings in a specified express route circuit. + * Deletes the specified authorization from the specified express route + * circuit. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} circuitName The name of the express route circuit. * + * @param {string} authorizationName The name of the authorization. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -4082,7 +3781,7 @@ export interface ExpressRouteCircuitPeerings { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitPeeringListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -4090,27 +3789,25 @@ export interface ExpressRouteCircuitPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitPeeringListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitPeeringListResult} for - * more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, circuitName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, circuitName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, circuitName: string, authorizationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, circuitName: string, authorizationName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, circuitName: string, authorizationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified peering from the specified express route circuit. + * Gets the specified authorization from the specified express route circuit. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} circuitName The name of the express route circuit. * - * @param {string} peeringName The name of the peering. + * @param {string} authorizationName The name of the authorization. * * @param {object} [options] Optional Parameters. * @@ -4119,20 +3816,20 @@ export interface ExpressRouteCircuitPeerings { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, circuitName: string, authorizationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified peering from the specified express route circuit. + * Gets the specified authorization from the specified express route circuit. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} circuitName The name of the express route circuit. * - * @param {string} peeringName The name of the peering. + * @param {string} authorizationName The name of the authorization. * * @param {object} [options] Optional Parameters. * @@ -4146,7 +3843,7 @@ export interface ExpressRouteCircuitPeerings { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ExpressRouteCircuitAuthorization} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -4154,155 +3851,129 @@ export interface ExpressRouteCircuitPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ExpressRouteCircuitAuthorization} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitAuthorization} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, circuitName: string, authorizationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, circuitName: string, authorizationName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, circuitName: string, authorizationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a peering in the specified express route circuits. + * Creates or updates an authorization in the specified express route circuit. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} circuitName The name of the express route circuit. * - * @param {string} peeringName The name of the peering. + * @param {string} authorizationName The name of the authorization. * - * @param {object} peeringParameters Parameters supplied to the create or - * update express route circuit peering operation. + * @param {object} authorizationParameters Parameters supplied to the create or + * update express route circuit authorization operation. * - * @param {string} [peeringParameters.peeringType] The peering type. Possible - * values include: 'AzurePublicPeering', 'AzurePrivatePeering', - * 'MicrosoftPeering' + * @param {string} [authorizationParameters.authorizationKey] The authorization + * key. * - * @param {string} [peeringParameters.state] The peering state. Possible values - * include: 'Disabled', 'Enabled' + * @param {string} [authorizationParameters.authorizationUseStatus] + * AuthorizationUseStatus. Possible values are: 'Available' and 'InUse'. + * Possible values include: 'Available', 'InUse' * - * @param {number} [peeringParameters.azureASN] The Azure ASN. + * @param {string} [authorizationParameters.provisioningState] Gets the + * provisioning state of the public IP resource. Possible values are: + * 'Updating', 'Deleting', and 'Failed'. * - * @param {number} [peeringParameters.peerASN] The peer ASN. + * @param {string} [authorizationParameters.name] Gets name of the resource + * that is unique within a resource group. This name can be used to access the + * resource. * - * @param {string} [peeringParameters.primaryPeerAddressPrefix] The primary - * address prefix. + * @param {string} [authorizationParameters.id] Resource ID. * - * @param {string} [peeringParameters.secondaryPeerAddressPrefix] The secondary - * address prefix. + * @param {object} [options] Optional Parameters. * - * @param {string} [peeringParameters.primaryAzurePort] The primary port. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [peeringParameters.secondaryAzurePort] The secondary port. + * @returns {Promise} A promise is returned * - * @param {string} [peeringParameters.sharedKey] The shared key. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {number} [peeringParameters.vlanId] The VLAN ID. + * @reject {Error|ServiceError} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, circuitName: string, authorizationName: string, authorizationParameters: models.ExpressRouteCircuitAuthorization, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates an authorization in the specified express route circuit. * - * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft - * peering configuration. + * @param {string} resourceGroupName The name of the resource group. * - * @param {object} [peeringParameters.stats] Gets peering stats. - * - * @param {number} [peeringParameters.stats.primarybytesIn] Gets BytesIn of the - * peering. - * - * @param {number} [peeringParameters.stats.primarybytesOut] Gets BytesOut of - * the peering. - * - * @param {number} [peeringParameters.stats.secondarybytesIn] Gets BytesIn of - * the peering. - * - * @param {number} [peeringParameters.stats.secondarybytesOut] Gets BytesOut of - * the peering. - * - * @param {string} [peeringParameters.provisioningState] Gets the provisioning - * state of the public IP resource. Possible values are: 'Updating', - * 'Deleting', and 'Failed'. - * - * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager - * Etag. - * - * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider - * or the customer last modified the peering. + * @param {string} circuitName The name of the express route circuit. * - * @param {object} [peeringParameters.routeFilter] The reference of the - * RouteFilter resource. + * @param {string} authorizationName The name of the authorization. * - * @param {object} [peeringParameters.ipv6PeeringConfig] The IPv6 peering - * configuration. + * @param {object} authorizationParameters Parameters supplied to the create or + * update express route circuit authorization operation. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.primaryPeerAddressPrefix] The primary - * address prefix. + * @param {string} [authorizationParameters.authorizationKey] The authorization + * key. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.secondaryPeerAddressPrefix] The - * secondary address prefix. + * @param {string} [authorizationParameters.authorizationUseStatus] + * AuthorizationUseStatus. Possible values are: 'Available' and 'InUse'. + * Possible values include: 'Available', 'InUse' * - * @param {object} [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig] - * The Microsoft peering configuration. + * @param {string} [authorizationParameters.provisioningState] Gets the + * provisioning state of the public IP resource. Possible values are: + * 'Updating', 'Deleting', and 'Failed'. * - * @param {array} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixes] - * The reference of AdvertisedPublicPrefixes. + * @param {string} [authorizationParameters.name] Gets name of the resource + * that is unique within a resource group. This name can be used to access the + * resource. * - * @param {array} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedCommunities] - * The communities of bgp peering. Spepcified for microsoft peering + * @param {string} [authorizationParameters.id] Resource ID. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixesState] - * AdvertisedPublicPrefixState of the Peering resource. Possible values are - * 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. - * Possible values include: 'NotConfigured', 'Configuring', 'Configured', - * 'ValidationNeeded' + * @param {object} [options] Optional Parameters. * - * @param {number} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.legacyMode] The - * legacy mode of the peering. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {number} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.customerASN] The - * CustomerASN of the peering. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.routingRegistryName] - * The RoutingRegistryName of the configuration. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter] The - * reference of the RouteFilter resource. + * {Promise} A promise is returned. * - * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.rules] - * Collection of RouteFilterRules contained within a route filter. + * @resolve {ExpressRouteCircuitAuthorization} - The deserialized result object. * - * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.peerings] A - * collection of references to express route circuit peerings. + * @reject {Error|ServiceError} - The error object. * - * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.id] - * Resource ID. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.location] - * Resource location. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter.tags] - * Resource tags. + * {ExpressRouteCircuitAuthorization} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitAuthorization} for more + * information. * - * @param {string} [peeringParameters.ipv6PeeringConfig.state] The state of - * peering. Possible values are: 'Disabled' and 'Enabled'. Possible values - * include: 'Disabled', 'Enabled' + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {array} [peeringParameters.connections] The list of circuit - * connections associated with Azure Private Peering for this circuit. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName: string, circuitName: string, authorizationName: string, authorizationParameters: models.ExpressRouteCircuitAuthorization, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, circuitName: string, authorizationName: string, authorizationParameters: models.ExpressRouteCircuitAuthorization, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, circuitName: string, authorizationName: string, authorizationParameters: models.ExpressRouteCircuitAuthorization, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all authorizations in an express route circuit. * - * @param {string} [peeringParameters.name] Gets name of the resource that is - * unique within a resource group. This name can be used to access the - * resource. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [peeringParameters.id] Resource ID. + * @param {string} circuitName The name of the circuit. * * @param {object} [options] Optional Parameters. * @@ -4311,150 +3982,186 @@ export interface ExpressRouteCircuitPeerings { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, peeringParameters: models.ExpressRouteCircuitPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a peering in the specified express route circuits. + * Gets all authorizations in an express route circuit. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} circuitName The name of the express route circuit. + * @param {string} circuitName The name of the circuit. * - * @param {string} peeringName The name of the peering. + * @param {object} [options] Optional Parameters. * - * @param {object} peeringParameters Parameters supplied to the create or - * update express route circuit peering operation. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [peeringParameters.peeringType] The peering type. Possible - * values include: 'AzurePublicPeering', 'AzurePrivatePeering', - * 'MicrosoftPeering' + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} [peeringParameters.state] The peering state. Possible values - * include: 'Disabled', 'Enabled' + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {number} [peeringParameters.azureASN] The Azure ASN. + * {Promise} A promise is returned. * - * @param {number} [peeringParameters.peerASN] The peer ASN. + * @resolve {AuthorizationListResult} - The deserialized result object. * - * @param {string} [peeringParameters.primaryPeerAddressPrefix] The primary - * address prefix. + * @reject {Error|ServiceError} - The error object. * - * @param {string} [peeringParameters.secondaryPeerAddressPrefix] The secondary - * address prefix. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} [peeringParameters.primaryAzurePort] The primary port. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [peeringParameters.secondaryAzurePort] The secondary port. + * {AuthorizationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link AuthorizationListResult} for more + * information. * - * @param {string} [peeringParameters.sharedKey] The shared key. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {number} [peeringParameters.vlanId] The VLAN ID. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + list(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, circuitName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, circuitName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes the specified authorization from the specified express route + * circuit. * - * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft - * peering configuration. + * @param {string} resourceGroupName The name of the resource group. * - * @param {object} [peeringParameters.stats] Gets peering stats. + * @param {string} circuitName The name of the express route circuit. * - * @param {number} [peeringParameters.stats.primarybytesIn] Gets BytesIn of the - * peering. + * @param {string} authorizationName The name of the authorization. * - * @param {number} [peeringParameters.stats.primarybytesOut] Gets BytesOut of - * the peering. + * @param {object} [options] Optional Parameters. * - * @param {number} [peeringParameters.stats.secondarybytesIn] Gets BytesIn of - * the peering. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {number} [peeringParameters.stats.secondarybytesOut] Gets BytesOut of - * the peering. + * @returns {Promise} A promise is returned * - * @param {string} [peeringParameters.provisioningState] Gets the provisioning - * state of the public IP resource. Possible values are: 'Updating', - * 'Deleting', and 'Failed'. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager - * Etag. + * @reject {Error|ServiceError} - The error object. + */ + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, circuitName: string, authorizationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes the specified authorization from the specified express route + * circuit. * - * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider - * or the customer last modified the peering. + * @param {string} resourceGroupName The name of the resource group. * - * @param {object} [peeringParameters.routeFilter] The reference of the - * RouteFilter resource. + * @param {string} circuitName The name of the express route circuit. * - * @param {object} [peeringParameters.ipv6PeeringConfig] The IPv6 peering - * configuration. + * @param {string} authorizationName The name of the authorization. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.primaryPeerAddressPrefix] The primary - * address prefix. + * @param {object} [options] Optional Parameters. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.secondaryPeerAddressPrefix] The - * secondary address prefix. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig] - * The Microsoft peering configuration. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {array} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixes] - * The reference of AdvertisedPublicPrefixes. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {array} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedCommunities] - * The communities of bgp peering. Spepcified for microsoft peering + * {Promise} A promise is returned. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixesState] - * AdvertisedPublicPrefixState of the Peering resource. Possible values are - * 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. - * Possible values include: 'NotConfigured', 'Configuring', 'Configured', - * 'ValidationNeeded' + * @resolve {null} - The deserialized result object. * - * @param {number} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.legacyMode] The - * legacy mode of the peering. + * @reject {Error|ServiceError} - The error object. * - * @param {number} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.customerASN] The - * CustomerASN of the peering. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.routingRegistryName] - * The RoutingRegistryName of the configuration. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter] The - * reference of the RouteFilter resource. + * {null} [result] - The deserialized result object if an error did not occur. * - * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.rules] - * Collection of RouteFilterRules contained within a route filter. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.peerings] A - * collection of references to express route circuit peerings. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(resourceGroupName: string, circuitName: string, authorizationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, circuitName: string, authorizationName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, circuitName: string, authorizationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Creates or updates an authorization in the specified express route circuit. * - * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.id] - * Resource ID. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.location] - * Resource location. + * @param {string} circuitName The name of the express route circuit. * - * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter.tags] - * Resource tags. + * @param {string} authorizationName The name of the authorization. * - * @param {string} [peeringParameters.ipv6PeeringConfig.state] The state of - * peering. Possible values are: 'Disabled' and 'Enabled'. Possible values - * include: 'Disabled', 'Enabled' + * @param {object} authorizationParameters Parameters supplied to the create or + * update express route circuit authorization operation. * - * @param {array} [peeringParameters.connections] The list of circuit - * connections associated with Azure Private Peering for this circuit. + * @param {string} [authorizationParameters.authorizationKey] The authorization + * key. * - * @param {string} [peeringParameters.name] Gets name of the resource that is - * unique within a resource group. This name can be used to access the + * @param {string} [authorizationParameters.authorizationUseStatus] + * AuthorizationUseStatus. Possible values are: 'Available' and 'InUse'. + * Possible values include: 'Available', 'InUse' + * + * @param {string} [authorizationParameters.provisioningState] Gets the + * provisioning state of the public IP resource. Possible values are: + * 'Updating', 'Deleting', and 'Failed'. + * + * @param {string} [authorizationParameters.name] Gets name of the resource + * that is unique within a resource group. This name can be used to access the * resource. * - * @param {string} [peeringParameters.id] Resource ID. + * @param {string} [authorizationParameters.id] Resource ID. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, circuitName: string, authorizationName: string, authorizationParameters: models.ExpressRouteCircuitAuthorization, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates an authorization in the specified express route circuit. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} circuitName The name of the express route circuit. + * + * @param {string} authorizationName The name of the authorization. + * + * @param {object} authorizationParameters Parameters supplied to the create or + * update express route circuit authorization operation. + * + * @param {string} [authorizationParameters.authorizationKey] The authorization + * key. + * + * @param {string} [authorizationParameters.authorizationUseStatus] + * AuthorizationUseStatus. Possible values are: 'Available' and 'InUse'. + * Possible values include: 'Available', 'InUse' + * + * @param {string} [authorizationParameters.provisioningState] Gets the + * provisioning state of the public IP resource. Possible values are: + * 'Updating', 'Deleting', and 'Failed'. + * + * @param {string} [authorizationParameters.name] Gets name of the resource + * that is unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [authorizationParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -4468,7 +4175,7 @@ export interface ExpressRouteCircuitPeerings { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitPeering} - The deserialized result object. + * @resolve {ExpressRouteCircuitAuthorization} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -4476,21 +4183,21 @@ export interface ExpressRouteCircuitPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitPeering} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitPeering} for more + * {ExpressRouteCircuitAuthorization} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitAuthorization} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, peeringParameters: models.ExpressRouteCircuitPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, peeringParameters: models.ExpressRouteCircuitPeering, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, peeringParameters: models.ExpressRouteCircuitPeering, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, circuitName: string, authorizationName: string, authorizationParameters: models.ExpressRouteCircuitAuthorization, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, circuitName: string, authorizationName: string, authorizationParameters: models.ExpressRouteCircuitAuthorization, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, circuitName: string, authorizationName: string, authorizationParameters: models.ExpressRouteCircuitAuthorization, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all peerings in a specified express route circuit. + * Gets all authorizations in an express route circuit. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -4502,14 +4209,14 @@ export interface ExpressRouteCircuitPeerings { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all peerings in a specified express route circuit. + * Gets all authorizations in an express route circuit. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -4526,7 +4233,7 @@ export interface ExpressRouteCircuitPeerings { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitPeeringListResult} - The deserialized result object. + * @resolve {AuthorizationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -4534,31 +4241,30 @@ export interface ExpressRouteCircuitPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitPeeringListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitPeeringListResult} for - * more information. + * {AuthorizationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link AuthorizationListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } /** * @class - * ExpressRouteCircuitConnections + * ExpressRouteCircuitPeerings * __NOTE__: An instance of this class is automatically created for an * instance of the NetworkManagementClient. */ -export interface ExpressRouteCircuitConnections { +export interface ExpressRouteCircuitPeerings { /** - * Deletes the specified Express Route Circuit Connection from the specified - * express route circuit. + * Deletes the specified peering from the specified express route circuit. * * @param {string} resourceGroupName The name of the resource group. * @@ -4566,9 +4272,6 @@ export interface ExpressRouteCircuitConnections { * * @param {string} peeringName The name of the peering. * - * @param {string} connectionName The name of the express route circuit - * connection. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -4580,11 +4283,10 @@ export interface ExpressRouteCircuitConnections { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified Express Route Circuit Connection from the specified - * express route circuit. + * Deletes the specified peering from the specified express route circuit. * * @param {string} resourceGroupName The name of the resource group. * @@ -4592,9 +4294,6 @@ export interface ExpressRouteCircuitConnections { * * @param {string} peeringName The name of the peering. * - * @param {string} connectionName The name of the express route circuit - * connection. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -4621,14 +4320,13 @@ export interface ExpressRouteCircuitConnections { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified Express Route Circuit Connection from the specified - * express route circuit. + * Gets the specified peering for the express route circuit. * * @param {string} resourceGroupName The name of the resource group. * @@ -4636,9 +4334,6 @@ export interface ExpressRouteCircuitConnections { * * @param {string} peeringName The name of the peering. * - * @param {string} connectionName The name of the express route circuit - * connection. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -4646,15 +4341,14 @@ export interface ExpressRouteCircuitConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified Express Route Circuit Connection from the specified - * express route circuit. + * Gets the specified peering for the express route circuit. * * @param {string} resourceGroupName The name of the resource group. * @@ -4662,9 +4356,6 @@ export interface ExpressRouteCircuitConnections { * * @param {string} peeringName The name of the peering. * - * @param {string} connectionName The name of the express route circuit - * connection. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -4677,7 +4368,7 @@ export interface ExpressRouteCircuitConnections { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitConnection} - The deserialized result object. + * @resolve {ExpressRouteCircuitPeering} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -4685,22 +4376,21 @@ export interface ExpressRouteCircuitConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitConnection} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitConnection} for more + * {ExpressRouteCircuitPeering} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitPeering} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, circuitName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, circuitName: string, peeringName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, circuitName: string, peeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a Express Route Circuit Connection in the specified - * express route circuits. + * Creates or updates a peering in the specified express route circuits. * * @param {string} resourceGroupName The name of the resource group. * @@ -4708,138 +4398,135 @@ export interface ExpressRouteCircuitConnections { * * @param {string} peeringName The name of the peering. * - * @param {string} connectionName The name of the express route circuit - * connection. + * @param {object} peeringParameters Parameters supplied to the create or + * update express route circuit peering operation. * - * @param {object} expressRouteCircuitConnectionParameters Parameters supplied - * to the create or update express route circuit circuit connection operation. + * @param {string} [peeringParameters.peeringType] The peering type. Possible + * values include: 'AzurePublicPeering', 'AzurePrivatePeering', + * 'MicrosoftPeering' * - * @param {object} - * [expressRouteCircuitConnectionParameters.expressRouteCircuitPeering] - * Reference to Express Route Circuit Private Peering Resource of the circuit - * initiating connection. + * @param {string} [peeringParameters.state] The peering state. Possible values + * include: 'Disabled', 'Enabled' * - * @param {object} - * [expressRouteCircuitConnectionParameters.peerExpressRouteCircuitPeering] - * Reference to Express Route Circuit Private Peering Resource of the peered - * circuit. + * @param {number} [peeringParameters.azureASN] The Azure ASN. * - * @param {string} - * [expressRouteCircuitConnectionParameters.peerExpressRouteCircuitPeering.id] - * Resource ID. + * @param {number} [peeringParameters.peerASN] The peer ASN. * - * @param {string} [expressRouteCircuitConnectionParameters.addressPrefix] /29 - * IP address space to carve out Customer addresses for tunnels. + * @param {string} [peeringParameters.primaryPeerAddressPrefix] The primary + * address prefix. * - * @param {string} [expressRouteCircuitConnectionParameters.authorizationKey] - * The authorization key. + * @param {string} [peeringParameters.secondaryPeerAddressPrefix] The secondary + * address prefix. * - * @param {string} [expressRouteCircuitConnectionParameters.name] Gets name of - * the resource that is unique within a resource group. This name can be used - * to access the resource. + * @param {string} [peeringParameters.primaryAzurePort] The primary port. * - * @param {string} [expressRouteCircuitConnectionParameters.id] Resource ID. + * @param {string} [peeringParameters.secondaryAzurePort] The secondary port. * - * @param {object} [options] Optional Parameters. + * @param {string} [peeringParameters.sharedKey] The shared key. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {number} [peeringParameters.vlanId] The VLAN ID. * - * @returns {Promise} A promise is returned + * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft + * peering configuration. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {object} [peeringParameters.stats] Gets peering stats. * - * @reject {Error|ServiceError} - The error object. - */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, expressRouteCircuitConnectionParameters: models.ExpressRouteCircuitConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Creates or updates a Express Route Circuit Connection in the specified - * express route circuits. + * @param {number} [peeringParameters.stats.primarybytesIn] Gets BytesIn of the + * peering. * - * @param {string} resourceGroupName The name of the resource group. + * @param {number} [peeringParameters.stats.primarybytesOut] Gets BytesOut of + * the peering. * - * @param {string} circuitName The name of the express route circuit. + * @param {number} [peeringParameters.stats.secondarybytesIn] Gets BytesIn of + * the peering. * - * @param {string} peeringName The name of the peering. + * @param {number} [peeringParameters.stats.secondarybytesOut] Gets BytesOut of + * the peering. * - * @param {string} connectionName The name of the express route circuit - * connection. + * @param {string} [peeringParameters.provisioningState] Gets the provisioning + * state of the public IP resource. Possible values are: 'Updating', + * 'Deleting', and 'Failed'. * - * @param {object} expressRouteCircuitConnectionParameters Parameters supplied - * to the create or update express route circuit circuit connection operation. + * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager + * Etag. * - * @param {object} - * [expressRouteCircuitConnectionParameters.expressRouteCircuitPeering] - * Reference to Express Route Circuit Private Peering Resource of the circuit - * initiating connection. + * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider + * or the customer last modified the peering. * - * @param {object} - * [expressRouteCircuitConnectionParameters.peerExpressRouteCircuitPeering] - * Reference to Express Route Circuit Private Peering Resource of the peered - * circuit. - * - * @param {string} - * [expressRouteCircuitConnectionParameters.peerExpressRouteCircuitPeering.id] - * Resource ID. + * @param {object} [peeringParameters.routeFilter] The reference of the + * RouteFilter resource. * - * @param {string} [expressRouteCircuitConnectionParameters.addressPrefix] /29 - * IP address space to carve out Customer addresses for tunnels. + * @param {object} [peeringParameters.ipv6PeeringConfig] The IPv6 peering + * configuration. * - * @param {string} [expressRouteCircuitConnectionParameters.authorizationKey] - * The authorization key. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.primaryPeerAddressPrefix] The primary + * address prefix. * - * @param {string} [expressRouteCircuitConnectionParameters.name] Gets name of - * the resource that is unique within a resource group. This name can be used - * to access the resource. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.secondaryPeerAddressPrefix] The + * secondary address prefix. * - * @param {string} [expressRouteCircuitConnectionParameters.id] Resource ID. + * @param {object} [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig] + * The Microsoft peering configuration. * - * @param {object} [options] Optional Parameters. + * @param {array} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixes] + * The reference of AdvertisedPublicPrefixes. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {array} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedCommunities] + * The communities of bgp peering. Spepcified for microsoft peering * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixesState] + * AdvertisedPublicPrefixState of the Peering resource. Possible values are + * 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. + * Possible values include: 'NotConfigured', 'Configuring', 'Configured', + * 'ValidationNeeded' * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {number} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.legacyMode] The + * legacy mode of the peering. * - * {Promise} A promise is returned. + * @param {number} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.customerASN] The + * CustomerASN of the peering. * - * @resolve {ExpressRouteCircuitConnection} - The deserialized result object. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.routingRegistryName] + * The RoutingRegistryName of the configuration. * - * @reject {Error|ServiceError} - The error object. + * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter] The + * reference of the RouteFilter resource. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.rules] + * Collection of RouteFilterRules contained within a route filter. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.peerings] A + * collection of references to express route circuit peerings. * - * {ExpressRouteCircuitConnection} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitConnection} for more - * information. + * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.id] + * Resource ID. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.location] + * Resource location. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - createOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, expressRouteCircuitConnectionParameters: models.ExpressRouteCircuitConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, expressRouteCircuitConnectionParameters: models.ExpressRouteCircuitConnection, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, expressRouteCircuitConnectionParameters: models.ExpressRouteCircuitConnection, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Deletes the specified Express Route Circuit Connection from the specified - * express route circuit. + * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter.tags] + * Resource tags. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [peeringParameters.ipv6PeeringConfig.state] The state of + * peering. Possible values are: 'Disabled' and 'Enabled'. Possible values + * include: 'Disabled', 'Enabled' * - * @param {string} circuitName The name of the express route circuit. + * @param {array} [peeringParameters.connections] The list of circuit + * connections associated with Azure Private Peering for this circuit. * - * @param {string} peeringName The name of the peering. + * @param {string} [peeringParameters.name] Gets name of the resource that is + * unique within a resource group. This name can be used to access the + * resource. * - * @param {string} connectionName The name of the express route circuit - * connection. + * @param {string} [peeringParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -4848,15 +4535,14 @@ export interface ExpressRouteCircuitConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, peeringParameters: models.ExpressRouteCircuitPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified Express Route Circuit Connection from the specified - * express route circuit. + * Creates or updates a peering in the specified express route circuits. * * @param {string} resourceGroupName The name of the resource group. * @@ -4864,136 +4550,135 @@ export interface ExpressRouteCircuitConnections { * * @param {string} peeringName The name of the peering. * - * @param {string} connectionName The name of the express route circuit - * connection. + * @param {object} peeringParameters Parameters supplied to the create or + * update express route circuit peering operation. * - * @param {object} [options] Optional Parameters. + * @param {string} [peeringParameters.peeringType] The peering type. Possible + * values include: 'AzurePublicPeering', 'AzurePrivatePeering', + * 'MicrosoftPeering' * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [peeringParameters.state] The peering state. Possible values + * include: 'Disabled', 'Enabled' * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {number} [peeringParameters.azureASN] The Azure ASN. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {number} [peeringParameters.peerASN] The peer ASN. * - * {Promise} A promise is returned. + * @param {string} [peeringParameters.primaryPeerAddressPrefix] The primary + * address prefix. * - * @resolve {null} - The deserialized result object. + * @param {string} [peeringParameters.secondaryPeerAddressPrefix] The secondary + * address prefix. * - * @reject {Error|ServiceError} - The error object. + * @param {string} [peeringParameters.primaryAzurePort] The primary port. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {string} [peeringParameters.secondaryAzurePort] The secondary port. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {string} [peeringParameters.sharedKey] The shared key. * - * {null} [result] - The deserialized result object if an error did not occur. + * @param {number} [peeringParameters.vlanId] The VLAN ID. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft + * peering configuration. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginDeleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Creates or updates a Express Route Circuit Connection in the specified - * express route circuits. + * @param {object} [peeringParameters.stats] Gets peering stats. * - * @param {string} resourceGroupName The name of the resource group. + * @param {number} [peeringParameters.stats.primarybytesIn] Gets BytesIn of the + * peering. * - * @param {string} circuitName The name of the express route circuit. + * @param {number} [peeringParameters.stats.primarybytesOut] Gets BytesOut of + * the peering. * - * @param {string} peeringName The name of the peering. + * @param {number} [peeringParameters.stats.secondarybytesIn] Gets BytesIn of + * the peering. * - * @param {string} connectionName The name of the express route circuit - * connection. + * @param {number} [peeringParameters.stats.secondarybytesOut] Gets BytesOut of + * the peering. * - * @param {object} expressRouteCircuitConnectionParameters Parameters supplied - * to the create or update express route circuit circuit connection operation. + * @param {string} [peeringParameters.provisioningState] Gets the provisioning + * state of the public IP resource. Possible values are: 'Updating', + * 'Deleting', and 'Failed'. * - * @param {object} - * [expressRouteCircuitConnectionParameters.expressRouteCircuitPeering] - * Reference to Express Route Circuit Private Peering Resource of the circuit - * initiating connection. + * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager + * Etag. * - * @param {object} - * [expressRouteCircuitConnectionParameters.peerExpressRouteCircuitPeering] - * Reference to Express Route Circuit Private Peering Resource of the peered - * circuit. + * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider + * or the customer last modified the peering. * - * @param {string} - * [expressRouteCircuitConnectionParameters.peerExpressRouteCircuitPeering.id] - * Resource ID. + * @param {object} [peeringParameters.routeFilter] The reference of the + * RouteFilter resource. * - * @param {string} [expressRouteCircuitConnectionParameters.addressPrefix] /29 - * IP address space to carve out Customer addresses for tunnels. + * @param {object} [peeringParameters.ipv6PeeringConfig] The IPv6 peering + * configuration. * - * @param {string} [expressRouteCircuitConnectionParameters.authorizationKey] - * The authorization key. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.primaryPeerAddressPrefix] The primary + * address prefix. * - * @param {string} [expressRouteCircuitConnectionParameters.name] Gets name of - * the resource that is unique within a resource group. This name can be used - * to access the resource. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.secondaryPeerAddressPrefix] The + * secondary address prefix. * - * @param {string} [expressRouteCircuitConnectionParameters.id] Resource ID. + * @param {object} [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig] + * The Microsoft peering configuration. * - * @param {object} [options] Optional Parameters. + * @param {array} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixes] + * The reference of AdvertisedPublicPrefixes. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {array} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedCommunities] + * The communities of bgp peering. Spepcified for microsoft peering * - * @returns {Promise} A promise is returned + * @param {string} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixesState] + * AdvertisedPublicPrefixState of the Peering resource. Possible values are + * 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. + * Possible values include: 'NotConfigured', 'Configuring', 'Configured', + * 'ValidationNeeded' * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {number} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.legacyMode] The + * legacy mode of the peering. * - * @reject {Error|ServiceError} - The error object. - */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, expressRouteCircuitConnectionParameters: models.ExpressRouteCircuitConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Creates or updates a Express Route Circuit Connection in the specified - * express route circuits. + * @param {number} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.customerASN] The + * CustomerASN of the peering. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.routingRegistryName] + * The RoutingRegistryName of the configuration. * - * @param {string} circuitName The name of the express route circuit. + * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter] The + * reference of the RouteFilter resource. * - * @param {string} peeringName The name of the peering. + * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.rules] + * Collection of RouteFilterRules contained within a route filter. * - * @param {string} connectionName The name of the express route circuit - * connection. + * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.peerings] A + * collection of references to express route circuit peerings. * - * @param {object} expressRouteCircuitConnectionParameters Parameters supplied - * to the create or update express route circuit circuit connection operation. + * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.id] + * Resource ID. * - * @param {object} - * [expressRouteCircuitConnectionParameters.expressRouteCircuitPeering] - * Reference to Express Route Circuit Private Peering Resource of the circuit - * initiating connection. + * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.location] + * Resource location. * - * @param {object} - * [expressRouteCircuitConnectionParameters.peerExpressRouteCircuitPeering] - * Reference to Express Route Circuit Private Peering Resource of the peered - * circuit. - * - * @param {string} - * [expressRouteCircuitConnectionParameters.peerExpressRouteCircuitPeering.id] - * Resource ID. + * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter.tags] + * Resource tags. * - * @param {string} [expressRouteCircuitConnectionParameters.addressPrefix] /29 - * IP address space to carve out Customer addresses for tunnels. + * @param {string} [peeringParameters.ipv6PeeringConfig.state] The state of + * peering. Possible values are: 'Disabled' and 'Enabled'. Possible values + * include: 'Disabled', 'Enabled' * - * @param {string} [expressRouteCircuitConnectionParameters.authorizationKey] - * The authorization key. + * @param {array} [peeringParameters.connections] The list of circuit + * connections associated with Azure Private Peering for this circuit. * - * @param {string} [expressRouteCircuitConnectionParameters.name] Gets name of - * the resource that is unique within a resource group. This name can be used - * to access the resource. + * @param {string} [peeringParameters.name] Gets name of the resource that is + * unique within a resource group. This name can be used to access the + * resource. * - * @param {string} [expressRouteCircuitConnectionParameters.id] Resource ID. + * @param {string} [peeringParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -5007,7 +4692,7 @@ export interface ExpressRouteCircuitConnections { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitConnection} - The deserialized result object. + * @resolve {ExpressRouteCircuitPeering} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -5015,30 +4700,21 @@ export interface ExpressRouteCircuitConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitConnection} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitConnection} for more + * {ExpressRouteCircuitPeering} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitPeering} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, expressRouteCircuitConnectionParameters: models.ExpressRouteCircuitConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, expressRouteCircuitConnectionParameters: models.ExpressRouteCircuitConnection, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, expressRouteCircuitConnectionParameters: models.ExpressRouteCircuitConnection, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * ExpressRouteCircuits - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface ExpressRouteCircuits { + createOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, peeringParameters: models.ExpressRouteCircuitPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, peeringParameters: models.ExpressRouteCircuitPeering, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, peeringParameters: models.ExpressRouteCircuitPeering, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified express route circuit. + * Gets all peerings in a specified express route circuit. * * @param {string} resourceGroupName The name of the resource group. * @@ -5051,14 +4727,14 @@ export interface ExpressRouteCircuits { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified express route circuit. + * Gets all peerings in a specified express route circuit. * * @param {string} resourceGroupName The name of the resource group. * @@ -5076,7 +4752,7 @@ export interface ExpressRouteCircuits { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ExpressRouteCircuitPeeringListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -5084,23 +4760,27 @@ export interface ExpressRouteCircuits { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ExpressRouteCircuitPeeringListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitPeeringListResult} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, circuitName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, circuitName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, circuitName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, circuitName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets information about the specified express route circuit. + * Deletes the specified peering from the specified express route circuit. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} circuitName The name of express route circuit. + * @param {string} circuitName The name of the express route circuit. + * + * @param {string} peeringName The name of the peering. * * @param {object} [options] Optional Parameters. * @@ -5109,18 +4789,20 @@ export interface ExpressRouteCircuits { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets information about the specified express route circuit. + * Deletes the specified peering from the specified express route circuit. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} circuitName The name of express route circuit. + * @param {string} circuitName The name of the express route circuit. + * + * @param {string} peeringName The name of the peering. * * @param {object} [options] Optional Parameters. * @@ -5134,7 +4816,7 @@ export interface ExpressRouteCircuits { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuit} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -5142,160 +4824,307 @@ export interface ExpressRouteCircuits { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuit} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuit} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, circuitName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, circuitName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates an express route circuit. + * Creates or updates a peering in the specified express route circuits. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} circuitName The name of the circuit. - * - * @param {object} parameters Parameters supplied to the create or update - * express route circuit operation. + * @param {string} circuitName The name of the express route circuit. * - * @param {object} [parameters.sku] The SKU. + * @param {string} peeringName The name of the peering. * - * @param {string} [parameters.sku.name] The name of the SKU. + * @param {object} peeringParameters Parameters supplied to the create or + * update express route circuit peering operation. * - * @param {string} [parameters.sku.tier] The tier of the SKU. Possible values - * are 'Standard' and 'Premium'. Possible values include: 'Standard', 'Premium' + * @param {string} [peeringParameters.peeringType] The peering type. Possible + * values include: 'AzurePublicPeering', 'AzurePrivatePeering', + * 'MicrosoftPeering' * - * @param {string} [parameters.sku.family] The family of the SKU. Possible - * values are: 'UnlimitedData' and 'MeteredData'. Possible values include: - * 'UnlimitedData', 'MeteredData' + * @param {string} [peeringParameters.state] The peering state. Possible values + * include: 'Disabled', 'Enabled' * - * @param {boolean} [parameters.allowClassicOperations] Allow classic - * operations + * @param {number} [peeringParameters.azureASN] The Azure ASN. * - * @param {string} [parameters.circuitProvisioningState] The - * CircuitProvisioningState state of the resource. + * @param {number} [peeringParameters.peerASN] The peer ASN. * - * @param {string} [parameters.serviceProviderProvisioningState] The - * ServiceProviderProvisioningState state of the resource. Possible values are - * 'NotProvisioned', 'Provisioning', 'Provisioned', and 'Deprovisioning'. - * Possible values include: 'NotProvisioned', 'Provisioning', 'Provisioned', - * 'Deprovisioning' + * @param {string} [peeringParameters.primaryPeerAddressPrefix] The primary + * address prefix. * - * @param {array} [parameters.authorizations] The list of authorizations. + * @param {string} [peeringParameters.secondaryPeerAddressPrefix] The secondary + * address prefix. * - * @param {array} [parameters.peerings] The list of peerings. + * @param {string} [peeringParameters.primaryAzurePort] The primary port. * - * @param {string} [parameters.serviceKey] The ServiceKey. + * @param {string} [peeringParameters.secondaryAzurePort] The secondary port. * - * @param {string} [parameters.serviceProviderNotes] The ServiceProviderNotes. + * @param {string} [peeringParameters.sharedKey] The shared key. * - * @param {object} [parameters.serviceProviderProperties] The - * ServiceProviderProperties. + * @param {number} [peeringParameters.vlanId] The VLAN ID. * - * @param {string} [parameters.serviceProviderProperties.serviceProviderName] - * The serviceProviderName. + * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft + * peering configuration. * - * @param {string} [parameters.serviceProviderProperties.peeringLocation] The - * peering location. + * @param {object} [peeringParameters.stats] Gets peering stats. * - * @param {number} [parameters.serviceProviderProperties.bandwidthInMbps] The - * BandwidthInMbps. + * @param {number} [peeringParameters.stats.primarybytesIn] Gets BytesIn of the + * peering. * - * @param {string} [parameters.provisioningState] Gets the provisioning state - * of the public IP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. + * @param {number} [peeringParameters.stats.primarybytesOut] Gets BytesOut of + * the peering. * - * @param {string} [parameters.gatewayManagerEtag] The GatewayManager Etag. + * @param {number} [peeringParameters.stats.secondarybytesIn] Gets BytesIn of + * the peering. * - * @param {string} [parameters.id] Resource ID. + * @param {number} [peeringParameters.stats.secondarybytesOut] Gets BytesOut of + * the peering. * - * @param {string} [parameters.location] Resource location. + * @param {string} [peeringParameters.provisioningState] Gets the provisioning + * state of the public IP resource. Possible values are: 'Updating', + * 'Deleting', and 'Failed'. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager + * Etag. * - * @param {object} [options] Optional Parameters. + * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider + * or the customer last modified the peering. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {object} [peeringParameters.routeFilter] The reference of the + * RouteFilter resource. * - * @returns {Promise} A promise is returned + * @param {object} [peeringParameters.ipv6PeeringConfig] The IPv6 peering + * configuration. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.primaryPeerAddressPrefix] The primary + * address prefix. * - * @reject {Error|ServiceError} - The error object. - */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, circuitName: string, parameters: models.ExpressRouteCircuit, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Creates or updates an express route circuit. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.secondaryPeerAddressPrefix] The + * secondary address prefix. * - * @param {string} resourceGroupName The name of the resource group. + * @param {object} [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig] + * The Microsoft peering configuration. * - * @param {string} circuitName The name of the circuit. + * @param {array} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixes] + * The reference of AdvertisedPublicPrefixes. * - * @param {object} parameters Parameters supplied to the create or update - * express route circuit operation. + * @param {array} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedCommunities] + * The communities of bgp peering. Spepcified for microsoft peering * - * @param {object} [parameters.sku] The SKU. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixesState] + * AdvertisedPublicPrefixState of the Peering resource. Possible values are + * 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. + * Possible values include: 'NotConfigured', 'Configuring', 'Configured', + * 'ValidationNeeded' * - * @param {string} [parameters.sku.name] The name of the SKU. + * @param {number} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.legacyMode] The + * legacy mode of the peering. * - * @param {string} [parameters.sku.tier] The tier of the SKU. Possible values - * are 'Standard' and 'Premium'. Possible values include: 'Standard', 'Premium' + * @param {number} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.customerASN] The + * CustomerASN of the peering. * - * @param {string} [parameters.sku.family] The family of the SKU. Possible - * values are: 'UnlimitedData' and 'MeteredData'. Possible values include: - * 'UnlimitedData', 'MeteredData' + * @param {string} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.routingRegistryName] + * The RoutingRegistryName of the configuration. * - * @param {boolean} [parameters.allowClassicOperations] Allow classic - * operations + * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter] The + * reference of the RouteFilter resource. * - * @param {string} [parameters.circuitProvisioningState] The - * CircuitProvisioningState state of the resource. + * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.rules] + * Collection of RouteFilterRules contained within a route filter. * - * @param {string} [parameters.serviceProviderProvisioningState] The - * ServiceProviderProvisioningState state of the resource. Possible values are - * 'NotProvisioned', 'Provisioning', 'Provisioned', and 'Deprovisioning'. - * Possible values include: 'NotProvisioned', 'Provisioning', 'Provisioned', - * 'Deprovisioning' + * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.peerings] A + * collection of references to express route circuit peerings. * - * @param {array} [parameters.authorizations] The list of authorizations. + * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.id] + * Resource ID. * - * @param {array} [parameters.peerings] The list of peerings. + * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.location] + * Resource location. * - * @param {string} [parameters.serviceKey] The ServiceKey. + * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter.tags] + * Resource tags. * - * @param {string} [parameters.serviceProviderNotes] The ServiceProviderNotes. + * @param {string} [peeringParameters.ipv6PeeringConfig.state] The state of + * peering. Possible values are: 'Disabled' and 'Enabled'. Possible values + * include: 'Disabled', 'Enabled' * - * @param {object} [parameters.serviceProviderProperties] The - * ServiceProviderProperties. + * @param {array} [peeringParameters.connections] The list of circuit + * connections associated with Azure Private Peering for this circuit. * - * @param {string} [parameters.serviceProviderProperties.serviceProviderName] - * The serviceProviderName. + * @param {string} [peeringParameters.name] Gets name of the resource that is + * unique within a resource group. This name can be used to access the + * resource. * - * @param {string} [parameters.serviceProviderProperties.peeringLocation] The - * peering location. + * @param {string} [peeringParameters.id] Resource ID. * - * @param {number} [parameters.serviceProviderProperties.bandwidthInMbps] The - * BandwidthInMbps. + * @param {object} [options] Optional Parameters. * - * @param {string} [parameters.provisioningState] Gets the provisioning state - * of the public IP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.gatewayManagerEtag] The GatewayManager Etag. + * @returns {Promise} A promise is returned * - * @param {string} [parameters.id] Resource ID. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [parameters.location] Resource location. + * @reject {Error|ServiceError} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, peeringParameters: models.ExpressRouteCircuitPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a peering in the specified express route circuits. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} circuitName The name of the express route circuit. + * + * @param {string} peeringName The name of the peering. + * + * @param {object} peeringParameters Parameters supplied to the create or + * update express route circuit peering operation. + * + * @param {string} [peeringParameters.peeringType] The peering type. Possible + * values include: 'AzurePublicPeering', 'AzurePrivatePeering', + * 'MicrosoftPeering' + * + * @param {string} [peeringParameters.state] The peering state. Possible values + * include: 'Disabled', 'Enabled' + * + * @param {number} [peeringParameters.azureASN] The Azure ASN. + * + * @param {number} [peeringParameters.peerASN] The peer ASN. + * + * @param {string} [peeringParameters.primaryPeerAddressPrefix] The primary + * address prefix. + * + * @param {string} [peeringParameters.secondaryPeerAddressPrefix] The secondary + * address prefix. + * + * @param {string} [peeringParameters.primaryAzurePort] The primary port. + * + * @param {string} [peeringParameters.secondaryAzurePort] The secondary port. + * + * @param {string} [peeringParameters.sharedKey] The shared key. + * + * @param {number} [peeringParameters.vlanId] The VLAN ID. + * + * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft + * peering configuration. + * + * @param {object} [peeringParameters.stats] Gets peering stats. + * + * @param {number} [peeringParameters.stats.primarybytesIn] Gets BytesIn of the + * peering. + * + * @param {number} [peeringParameters.stats.primarybytesOut] Gets BytesOut of + * the peering. + * + * @param {number} [peeringParameters.stats.secondarybytesIn] Gets BytesIn of + * the peering. + * + * @param {number} [peeringParameters.stats.secondarybytesOut] Gets BytesOut of + * the peering. + * + * @param {string} [peeringParameters.provisioningState] Gets the provisioning + * state of the public IP resource. Possible values are: 'Updating', + * 'Deleting', and 'Failed'. + * + * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager + * Etag. + * + * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider + * or the customer last modified the peering. + * + * @param {object} [peeringParameters.routeFilter] The reference of the + * RouteFilter resource. + * + * @param {object} [peeringParameters.ipv6PeeringConfig] The IPv6 peering + * configuration. + * + * @param {string} + * [peeringParameters.ipv6PeeringConfig.primaryPeerAddressPrefix] The primary + * address prefix. + * + * @param {string} + * [peeringParameters.ipv6PeeringConfig.secondaryPeerAddressPrefix] The + * secondary address prefix. + * + * @param {object} [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig] + * The Microsoft peering configuration. + * + * @param {array} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixes] + * The reference of AdvertisedPublicPrefixes. + * + * @param {array} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedCommunities] + * The communities of bgp peering. Spepcified for microsoft peering + * + * @param {string} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixesState] + * AdvertisedPublicPrefixState of the Peering resource. Possible values are + * 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. + * Possible values include: 'NotConfigured', 'Configuring', 'Configured', + * 'ValidationNeeded' + * + * @param {number} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.legacyMode] The + * legacy mode of the peering. + * + * @param {number} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.customerASN] The + * CustomerASN of the peering. + * + * @param {string} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.routingRegistryName] + * The RoutingRegistryName of the configuration. + * + * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter] The + * reference of the RouteFilter resource. + * + * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.rules] + * Collection of RouteFilterRules contained within a route filter. + * + * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.peerings] A + * collection of references to express route circuit peerings. + * + * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.id] + * Resource ID. + * + * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.location] + * Resource location. + * + * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter.tags] + * Resource tags. + * + * @param {string} [peeringParameters.ipv6PeeringConfig.state] The state of + * peering. Possible values are: 'Disabled' and 'Enabled'. Possible values + * include: 'Disabled', 'Enabled' + * + * @param {array} [peeringParameters.connections] The list of circuit + * connections associated with Azure Private Peering for this circuit. + * + * @param {string} [peeringParameters.name] Gets name of the resource that is + * unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [peeringParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -5309,7 +5138,7 @@ export interface ExpressRouteCircuits { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuit} - The deserialized result object. + * @resolve {ExpressRouteCircuitPeering} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -5317,29 +5146,24 @@ export interface ExpressRouteCircuits { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuit} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuit} for more information. + * {ExpressRouteCircuitPeering} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitPeering} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, circuitName: string, parameters: models.ExpressRouteCircuit, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, circuitName: string, parameters: models.ExpressRouteCircuit, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, circuitName: string, parameters: models.ExpressRouteCircuit, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, peeringParameters: models.ExpressRouteCircuitPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, peeringParameters: models.ExpressRouteCircuitPeering, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, peeringParameters: models.ExpressRouteCircuitPeering, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates an express route circuit tags. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} circuitName The name of the circuit. - * - * @param {object} parameters Parameters supplied to update express route - * circuit tags. + * Gets all peerings in a specified express route circuit. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -5348,23 +5172,17 @@ export interface ExpressRouteCircuits { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateTagsWithHttpOperationResponse(resourceGroupName: string, circuitName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates an express route circuit tags. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} circuitName The name of the circuit. - * - * @param {object} parameters Parameters supplied to update express route - * circuit tags. + * Gets all peerings in a specified express route circuit. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -5378,7 +5196,7 @@ export interface ExpressRouteCircuits { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuit} - The deserialized result object. + * @resolve {ExpressRouteCircuitPeeringListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -5386,21 +5204,31 @@ export interface ExpressRouteCircuits { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuit} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuit} for more information. + * {ExpressRouteCircuitPeeringListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitPeeringListResult} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - updateTags(resourceGroupName: string, circuitName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - updateTags(resourceGroupName: string, circuitName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - updateTags(resourceGroupName: string, circuitName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ExpressRouteCircuitConnections + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface ExpressRouteCircuitConnections { /** - * Gets the currently advertised ARP table associated with the express route - * circuit in a resource group. + * Deletes the specified Express Route Circuit Connection from the specified + * express route circuit. * * @param {string} resourceGroupName The name of the resource group. * @@ -5408,7 +5236,8 @@ export interface ExpressRouteCircuits { * * @param {string} peeringName The name of the peering. * - * @param {string} devicePath The path of the device. + * @param {string} connectionName The name of the express route circuit + * connection. * * @param {object} [options] Optional Parameters. * @@ -5417,15 +5246,15 @@ export interface ExpressRouteCircuits { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listArpTableWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the currently advertised ARP table associated with the express route - * circuit in a resource group. + * Deletes the specified Express Route Circuit Connection from the specified + * express route circuit. * * @param {string} resourceGroupName The name of the resource group. * @@ -5433,7 +5262,8 @@ export interface ExpressRouteCircuits { * * @param {string} peeringName The name of the peering. * - * @param {string} devicePath The path of the device. + * @param {string} connectionName The name of the express route circuit + * connection. * * @param {object} [options] Optional Parameters. * @@ -5447,7 +5277,7 @@ export interface ExpressRouteCircuits { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitsArpTableListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -5455,22 +5285,20 @@ export interface ExpressRouteCircuits { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitsArpTableListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitsArpTableListResult} for - * more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listArpTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listArpTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; - listArpTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the currently advertised routes table associated with the express route - * circuit in a resource group. + * Gets the specified Express Route Circuit Connection from the specified + * express route circuit. * * @param {string} resourceGroupName The name of the resource group. * @@ -5478,7 +5306,8 @@ export interface ExpressRouteCircuits { * * @param {string} peeringName The name of the peering. * - * @param {string} devicePath The path of the device. + * @param {string} connectionName The name of the express route circuit + * connection. * * @param {object} [options] Optional Parameters. * @@ -5487,15 +5316,15 @@ export interface ExpressRouteCircuits { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listRoutesTableWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the currently advertised routes table associated with the express route - * circuit in a resource group. + * Gets the specified Express Route Circuit Connection from the specified + * express route circuit. * * @param {string} resourceGroupName The name of the resource group. * @@ -5503,7 +5332,8 @@ export interface ExpressRouteCircuits { * * @param {string} peeringName The name of the peering. * - * @param {string} devicePath The path of the device. + * @param {string} connectionName The name of the express route circuit + * connection. * * @param {object} [options] Optional Parameters. * @@ -5517,7 +5347,7 @@ export interface ExpressRouteCircuits { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitsRoutesTableListResult} - The deserialized result object. + * @resolve {ExpressRouteCircuitConnection} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -5525,22 +5355,22 @@ export interface ExpressRouteCircuits { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitsRoutesTableListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitsRoutesTableListResult} - * for more information. + * {ExpressRouteCircuitConnection} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitConnection} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listRoutesTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listRoutesTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; - listRoutesTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the currently advertised routes table summary associated with the - * express route circuit in a resource group. + * Creates or updates a Express Route Circuit Connection in the specified + * express route circuits. * * @param {string} resourceGroupName The name of the resource group. * @@ -5548,7 +5378,37 @@ export interface ExpressRouteCircuits { * * @param {string} peeringName The name of the peering. * - * @param {string} devicePath The path of the device. + * @param {string} connectionName The name of the express route circuit + * connection. + * + * @param {object} expressRouteCircuitConnectionParameters Parameters supplied + * to the create or update express route circuit circuit connection operation. + * + * @param {object} + * [expressRouteCircuitConnectionParameters.expressRouteCircuitPeering] + * Reference to Express Route Circuit Private Peering Resource of the circuit + * initiating connection. + * + * @param {object} + * [expressRouteCircuitConnectionParameters.peerExpressRouteCircuitPeering] + * Reference to Express Route Circuit Private Peering Resource of the peered + * circuit. + * + * @param {string} + * [expressRouteCircuitConnectionParameters.peerExpressRouteCircuitPeering.id] + * Resource ID. + * + * @param {string} [expressRouteCircuitConnectionParameters.addressPrefix] /29 + * IP address space to carve out Customer addresses for tunnels. + * + * @param {string} [expressRouteCircuitConnectionParameters.authorizationKey] + * The authorization key. + * + * @param {string} [expressRouteCircuitConnectionParameters.name] Gets name of + * the resource that is unique within a resource group. This name can be used + * to access the resource. + * + * @param {string} [expressRouteCircuitConnectionParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -5557,15 +5417,15 @@ export interface ExpressRouteCircuits { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listRoutesTableSummaryWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, expressRouteCircuitConnectionParameters: models.ExpressRouteCircuitConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the currently advertised routes table summary associated with the - * express route circuit in a resource group. + * Creates or updates a Express Route Circuit Connection in the specified + * express route circuits. * * @param {string} resourceGroupName The name of the resource group. * @@ -5573,7 +5433,37 @@ export interface ExpressRouteCircuits { * * @param {string} peeringName The name of the peering. * - * @param {string} devicePath The path of the device. + * @param {string} connectionName The name of the express route circuit + * connection. + * + * @param {object} expressRouteCircuitConnectionParameters Parameters supplied + * to the create or update express route circuit circuit connection operation. + * + * @param {object} + * [expressRouteCircuitConnectionParameters.expressRouteCircuitPeering] + * Reference to Express Route Circuit Private Peering Resource of the circuit + * initiating connection. + * + * @param {object} + * [expressRouteCircuitConnectionParameters.peerExpressRouteCircuitPeering] + * Reference to Express Route Circuit Private Peering Resource of the peered + * circuit. + * + * @param {string} + * [expressRouteCircuitConnectionParameters.peerExpressRouteCircuitPeering.id] + * Resource ID. + * + * @param {string} [expressRouteCircuitConnectionParameters.addressPrefix] /29 + * IP address space to carve out Customer addresses for tunnels. + * + * @param {string} [expressRouteCircuitConnectionParameters.authorizationKey] + * The authorization key. + * + * @param {string} [expressRouteCircuitConnectionParameters.name] Gets name of + * the resource that is unique within a resource group. This name can be used + * to access the resource. + * + * @param {string} [expressRouteCircuitConnectionParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -5587,7 +5477,7 @@ export interface ExpressRouteCircuits { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitsRoutesTableSummaryListResult} - The deserialized result object. + * @resolve {ExpressRouteCircuitConnection} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -5595,27 +5485,32 @@ export interface ExpressRouteCircuits { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitsRoutesTableSummaryListResult} [result] - The deserialized result object if an error did not occur. - * See {@link - * ExpressRouteCircuitsRoutesTableSummaryListResult} for - * more information. + * {ExpressRouteCircuitConnection} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitConnection} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listRoutesTableSummary(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listRoutesTableSummary(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; - listRoutesTableSummary(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, expressRouteCircuitConnectionParameters: models.ExpressRouteCircuitConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, expressRouteCircuitConnectionParameters: models.ExpressRouteCircuitConnection, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, expressRouteCircuitConnectionParameters: models.ExpressRouteCircuitConnection, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the stats from an express route circuit in a resource group. + * Deletes the specified Express Route Circuit Connection from the specified + * express route circuit. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} circuitName The name of the express route circuit. * + * @param {string} peeringName The name of the peering. + * + * @param {string} connectionName The name of the express route circuit + * connection. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -5623,19 +5518,25 @@ export interface ExpressRouteCircuits { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getStatsWithHttpOperationResponse(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the stats from an express route circuit in a resource group. + * Deletes the specified Express Route Circuit Connection from the specified + * express route circuit. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} circuitName The name of the express route circuit. * + * @param {string} peeringName The name of the peering. + * + * @param {string} connectionName The name of the express route circuit + * connection. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -5648,7 +5549,7 @@ export interface ExpressRouteCircuits { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitStats} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -5656,21 +5557,20 @@ export interface ExpressRouteCircuits { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitStats} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitStats} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getStats(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getStats(resourceGroupName: string, circuitName: string, callback: ServiceCallback): void; - getStats(resourceGroupName: string, circuitName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all stats from an express route circuit in a resource group. + * Creates or updates a Express Route Circuit Connection in the specified + * express route circuits. * * @param {string} resourceGroupName The name of the resource group. * @@ -5678,6 +5578,38 @@ export interface ExpressRouteCircuits { * * @param {string} peeringName The name of the peering. * + * @param {string} connectionName The name of the express route circuit + * connection. + * + * @param {object} expressRouteCircuitConnectionParameters Parameters supplied + * to the create or update express route circuit circuit connection operation. + * + * @param {object} + * [expressRouteCircuitConnectionParameters.expressRouteCircuitPeering] + * Reference to Express Route Circuit Private Peering Resource of the circuit + * initiating connection. + * + * @param {object} + * [expressRouteCircuitConnectionParameters.peerExpressRouteCircuitPeering] + * Reference to Express Route Circuit Private Peering Resource of the peered + * circuit. + * + * @param {string} + * [expressRouteCircuitConnectionParameters.peerExpressRouteCircuitPeering.id] + * Resource ID. + * + * @param {string} [expressRouteCircuitConnectionParameters.addressPrefix] /29 + * IP address space to carve out Customer addresses for tunnels. + * + * @param {string} [expressRouteCircuitConnectionParameters.authorizationKey] + * The authorization key. + * + * @param {string} [expressRouteCircuitConnectionParameters.name] Gets name of + * the resource that is unique within a resource group. This name can be used + * to access the resource. + * + * @param {string} [expressRouteCircuitConnectionParameters.id] Resource ID. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -5685,14 +5617,15 @@ export interface ExpressRouteCircuits { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getPeeringStatsWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, expressRouteCircuitConnectionParameters: models.ExpressRouteCircuitConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all stats from an express route circuit in a resource group. + * Creates or updates a Express Route Circuit Connection in the specified + * express route circuits. * * @param {string} resourceGroupName The name of the resource group. * @@ -5700,6 +5633,38 @@ export interface ExpressRouteCircuits { * * @param {string} peeringName The name of the peering. * + * @param {string} connectionName The name of the express route circuit + * connection. + * + * @param {object} expressRouteCircuitConnectionParameters Parameters supplied + * to the create or update express route circuit circuit connection operation. + * + * @param {object} + * [expressRouteCircuitConnectionParameters.expressRouteCircuitPeering] + * Reference to Express Route Circuit Private Peering Resource of the circuit + * initiating connection. + * + * @param {object} + * [expressRouteCircuitConnectionParameters.peerExpressRouteCircuitPeering] + * Reference to Express Route Circuit Private Peering Resource of the peered + * circuit. + * + * @param {string} + * [expressRouteCircuitConnectionParameters.peerExpressRouteCircuitPeering.id] + * Resource ID. + * + * @param {string} [expressRouteCircuitConnectionParameters.addressPrefix] /29 + * IP address space to carve out Customer addresses for tunnels. + * + * @param {string} [expressRouteCircuitConnectionParameters.authorizationKey] + * The authorization key. + * + * @param {string} [expressRouteCircuitConnectionParameters.name] Gets name of + * the resource that is unique within a resource group. This name can be used + * to access the resource. + * + * @param {string} [expressRouteCircuitConnectionParameters.id] Resource ID. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -5712,7 +5677,7 @@ export interface ExpressRouteCircuits { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitStats} - The deserialized result object. + * @resolve {ExpressRouteCircuitConnection} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -5720,24 +5685,35 @@ export interface ExpressRouteCircuits { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitStats} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitStats} for more + * {ExpressRouteCircuitConnection} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitConnection} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getPeeringStats(resourceGroupName: string, circuitName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getPeeringStats(resourceGroupName: string, circuitName: string, peeringName: string, callback: ServiceCallback): void; - getPeeringStats(resourceGroupName: string, circuitName: string, peeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, expressRouteCircuitConnectionParameters: models.ExpressRouteCircuitConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, expressRouteCircuitConnectionParameters: models.ExpressRouteCircuitConnection, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, circuitName: string, peeringName: string, connectionName: string, expressRouteCircuitConnectionParameters: models.ExpressRouteCircuitConnection, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ExpressRouteCircuits + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface ExpressRouteCircuits { /** - * Gets all the express route circuits in a resource group. + * Deletes the specified express route circuit. * * @param {string} resourceGroupName The name of the resource group. * + * @param {string} circuitName The name of the express route circuit. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -5745,68 +5721,18 @@ export interface ExpressRouteCircuits { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the express route circuits in a resource group. + * Deletes the specified express route circuit. * * @param {string} resourceGroupName The name of the resource group. * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {ExpressRouteCircuitListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {ExpressRouteCircuitListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitListResult} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets all the express route circuits in a subscription. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets all the express route circuits in a subscription. + * @param {string} circuitName The name of the express route circuit. * * @param {object} [options] Optional Parameters. * @@ -5820,7 +5746,7 @@ export interface ExpressRouteCircuits { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -5828,25 +5754,23 @@ export interface ExpressRouteCircuits { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAll(callback: ServiceCallback): void; - listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, circuitName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, circuitName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified express route circuit. + * Gets information about the specified express route circuit. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} circuitName The name of the express route circuit. + * @param {string} circuitName The name of express route circuit. * * @param {object} [options] Optional Parameters. * @@ -5855,18 +5779,18 @@ export interface ExpressRouteCircuits { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified express route circuit. + * Gets information about the specified express route circuit. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} circuitName The name of the express route circuit. + * @param {string} circuitName The name of express route circuit. * * @param {object} [options] Optional Parameters. * @@ -5880,7 +5804,7 @@ export interface ExpressRouteCircuits { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ExpressRouteCircuit} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -5888,15 +5812,16 @@ export interface ExpressRouteCircuits { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ExpressRouteCircuit} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuit} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, circuitName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, circuitName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, circuitName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, circuitName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -5975,7 +5900,7 @@ export interface ExpressRouteCircuits { * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, circuitName: string, parameters: models.ExpressRouteCircuit, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, circuitName: string, parameters: models.ExpressRouteCircuit, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Creates or updates an express route circuit. @@ -6069,9 +5994,9 @@ export interface ExpressRouteCircuits { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, circuitName: string, parameters: models.ExpressRouteCircuit, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, circuitName: string, parameters: models.ExpressRouteCircuit, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, circuitName: string, parameters: models.ExpressRouteCircuit, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, circuitName: string, parameters: models.ExpressRouteCircuit, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, circuitName: string, parameters: models.ExpressRouteCircuit, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, circuitName: string, parameters: models.ExpressRouteCircuit, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -6097,7 +6022,7 @@ export interface ExpressRouteCircuits { * * @reject {Error|ServiceError} - The error object. */ - beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, circuitName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateTagsWithHttpOperationResponse(resourceGroupName: string, circuitName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Updates an express route circuit tags. @@ -6138,9 +6063,9 @@ export interface ExpressRouteCircuits { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdateTags(resourceGroupName: string, circuitName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdateTags(resourceGroupName: string, circuitName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - beginUpdateTags(resourceGroupName: string, circuitName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, circuitName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, circuitName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, circuitName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -6166,7 +6091,7 @@ export interface ExpressRouteCircuits { * * @reject {Error|ServiceError} - The error object. */ - beginListArpTableWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listArpTableWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Gets the currently advertised ARP table associated with the express route @@ -6208,9 +6133,9 @@ export interface ExpressRouteCircuits { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginListArpTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginListArpTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; - beginListArpTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listArpTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listArpTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; + listArpTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -6236,7 +6161,7 @@ export interface ExpressRouteCircuits { * * @reject {Error|ServiceError} - The error object. */ - beginListRoutesTableWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listRoutesTableWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Gets the currently advertised routes table associated with the express route @@ -6278,9 +6203,9 @@ export interface ExpressRouteCircuits { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginListRoutesTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginListRoutesTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; - beginListRoutesTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listRoutesTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listRoutesTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; + listRoutesTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -6306,7 +6231,7 @@ export interface ExpressRouteCircuits { * * @reject {Error|ServiceError} - The error object. */ - beginListRoutesTableSummaryWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listRoutesTableSummaryWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Gets the currently advertised routes table summary associated with the @@ -6349,16 +6274,17 @@ export interface ExpressRouteCircuits { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginListRoutesTableSummary(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginListRoutesTableSummary(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; - beginListRoutesTableSummary(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listRoutesTableSummary(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listRoutesTableSummary(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; + listRoutesTableSummary(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the express route circuits in a resource group. + * Gets all the stats from an express route circuit in a resource group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} circuitName The name of the express route circuit. * * @param {object} [options] Optional Parameters. * @@ -6367,17 +6293,18 @@ export interface ExpressRouteCircuits { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getStatsWithHttpOperationResponse(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the express route circuits in a resource group. + * Gets all the stats from an express route circuit in a resource group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} circuitName The name of the express route circuit. * * @param {object} [options] Optional Parameters. * @@ -6391,7 +6318,7 @@ export interface ExpressRouteCircuits { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitListResult} - The deserialized result object. + * @resolve {ExpressRouteCircuitStats} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -6399,24 +6326,27 @@ export interface ExpressRouteCircuits { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitListResult} for more + * {ExpressRouteCircuitStats} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitStats} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + getStats(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getStats(resourceGroupName: string, circuitName: string, callback: ServiceCallback): void; + getStats(resourceGroupName: string, circuitName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the express route circuits in a subscription. + * Gets all stats from an express route circuit in a resource group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} circuitName The name of the express route circuit. + * + * @param {string} peeringName The name of the peering. * * @param {object} [options] Optional Parameters. * @@ -6425,17 +6355,20 @@ export interface ExpressRouteCircuits { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getPeeringStatsWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the express route circuits in a subscription. + * Gets all stats from an express route circuit in a resource group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} circuitName The name of the express route circuit. + * + * @param {string} peeringName The name of the peering. * * @param {object} [options] Optional Parameters. * @@ -6449,7 +6382,7 @@ export interface ExpressRouteCircuits { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitListResult} - The deserialized result object. + * @resolve {ExpressRouteCircuitStats} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -6457,30 +6390,23 @@ export interface ExpressRouteCircuits { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitListResult} for more + * {ExpressRouteCircuitStats} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitStats} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAllNext(nextPageLink: string, callback: ServiceCallback): void; - listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * ExpressRouteServiceProviders - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface ExpressRouteServiceProviders { + getPeeringStats(resourceGroupName: string, circuitName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getPeeringStats(resourceGroupName: string, circuitName: string, peeringName: string, callback: ServiceCallback): void; + getPeeringStats(resourceGroupName: string, circuitName: string, peeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the available express route service providers. + * Gets all the express route circuits in a resource group. + * + * @param {string} resourceGroupName The name of the resource group. * * @param {object} [options] Optional Parameters. * @@ -6489,14 +6415,16 @@ export interface ExpressRouteServiceProviders { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the available express route service providers. + * Gets all the express route circuits in a resource group. + * + * @param {string} resourceGroupName The name of the resource group. * * @param {object} [options] Optional Parameters. * @@ -6510,7 +6438,7 @@ export interface ExpressRouteServiceProviders { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteServiceProviderListResult} - The deserialized result object. + * @resolve {ExpressRouteCircuitListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -6518,24 +6446,21 @@ export interface ExpressRouteServiceProviders { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteServiceProviderListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteServiceProviderListResult} for - * more information. + * {ExpressRouteCircuitListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(callback: ServiceCallback): void; - list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the available express route service providers. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * Gets all the express route circuits in a subscription. * * @param {object} [options] Optional Parameters. * @@ -6544,17 +6469,14 @@ export interface ExpressRouteServiceProviders { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the available express route service providers. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * Gets all the express route circuits in a subscription. * * @param {object} [options] Optional Parameters. * @@ -6568,7 +6490,7 @@ export interface ExpressRouteServiceProviders { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteServiceProviderListResult} - The deserialized result object. + * @resolve {ExpressRouteCircuitListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -6576,30 +6498,25 @@ export interface ExpressRouteServiceProviders { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteServiceProviderListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteServiceProviderListResult} for - * more information. + * {ExpressRouteCircuitListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * ExpressRouteCrossConnections - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface ExpressRouteCrossConnections { + listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAll(callback: ServiceCallback): void; + listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Retrieves all the ExpressRouteCrossConnections in a subscription. + * Deletes the specified express route circuit. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} circuitName The name of the express route circuit. * * @param {object} [options] Optional Parameters. * @@ -6608,14 +6525,18 @@ export interface ExpressRouteCrossConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Retrieves all the ExpressRouteCrossConnections in a subscription. + * Deletes the specified express route circuit. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} circuitName The name of the express route circuit. * * @param {object} [options] Optional Parameters. * @@ -6629,7 +6550,7 @@ export interface ExpressRouteCrossConnections { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCrossConnectionListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -6637,24 +6558,82 @@ export interface ExpressRouteCrossConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCrossConnectionListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCrossConnectionListResult} for - * more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(callback: ServiceCallback): void; - list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, circuitName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, circuitName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, circuitName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Retrieves all the ExpressRouteCrossConnections in a resource group. + * Creates or updates an express route circuit. * * @param {string} resourceGroupName The name of the resource group. * + * @param {string} circuitName The name of the circuit. + * + * @param {object} parameters Parameters supplied to the create or update + * express route circuit operation. + * + * @param {object} [parameters.sku] The SKU. + * + * @param {string} [parameters.sku.name] The name of the SKU. + * + * @param {string} [parameters.sku.tier] The tier of the SKU. Possible values + * are 'Standard' and 'Premium'. Possible values include: 'Standard', 'Premium' + * + * @param {string} [parameters.sku.family] The family of the SKU. Possible + * values are: 'UnlimitedData' and 'MeteredData'. Possible values include: + * 'UnlimitedData', 'MeteredData' + * + * @param {boolean} [parameters.allowClassicOperations] Allow classic + * operations + * + * @param {string} [parameters.circuitProvisioningState] The + * CircuitProvisioningState state of the resource. + * + * @param {string} [parameters.serviceProviderProvisioningState] The + * ServiceProviderProvisioningState state of the resource. Possible values are + * 'NotProvisioned', 'Provisioning', 'Provisioned', and 'Deprovisioning'. + * Possible values include: 'NotProvisioned', 'Provisioning', 'Provisioned', + * 'Deprovisioning' + * + * @param {array} [parameters.authorizations] The list of authorizations. + * + * @param {array} [parameters.peerings] The list of peerings. + * + * @param {string} [parameters.serviceKey] The ServiceKey. + * + * @param {string} [parameters.serviceProviderNotes] The ServiceProviderNotes. + * + * @param {object} [parameters.serviceProviderProperties] The + * ServiceProviderProperties. + * + * @param {string} [parameters.serviceProviderProperties.serviceProviderName] + * The serviceProviderName. + * + * @param {string} [parameters.serviceProviderProperties.peeringLocation] The + * peering location. + * + * @param {number} [parameters.serviceProviderProperties.bandwidthInMbps] The + * BandwidthInMbps. + * + * @param {string} [parameters.provisioningState] Gets the provisioning state + * of the public IP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. + * + * @param {string} [parameters.gatewayManagerEtag] The GatewayManager Etag. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -6662,17 +6641,77 @@ export interface ExpressRouteCrossConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByResourceGroupWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, circuitName: string, parameters: models.ExpressRouteCircuit, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Retrieves all the ExpressRouteCrossConnections in a resource group. + * Creates or updates an express route circuit. * * @param {string} resourceGroupName The name of the resource group. * + * @param {string} circuitName The name of the circuit. + * + * @param {object} parameters Parameters supplied to the create or update + * express route circuit operation. + * + * @param {object} [parameters.sku] The SKU. + * + * @param {string} [parameters.sku.name] The name of the SKU. + * + * @param {string} [parameters.sku.tier] The tier of the SKU. Possible values + * are 'Standard' and 'Premium'. Possible values include: 'Standard', 'Premium' + * + * @param {string} [parameters.sku.family] The family of the SKU. Possible + * values are: 'UnlimitedData' and 'MeteredData'. Possible values include: + * 'UnlimitedData', 'MeteredData' + * + * @param {boolean} [parameters.allowClassicOperations] Allow classic + * operations + * + * @param {string} [parameters.circuitProvisioningState] The + * CircuitProvisioningState state of the resource. + * + * @param {string} [parameters.serviceProviderProvisioningState] The + * ServiceProviderProvisioningState state of the resource. Possible values are + * 'NotProvisioned', 'Provisioning', 'Provisioned', and 'Deprovisioning'. + * Possible values include: 'NotProvisioned', 'Provisioning', 'Provisioned', + * 'Deprovisioning' + * + * @param {array} [parameters.authorizations] The list of authorizations. + * + * @param {array} [parameters.peerings] The list of peerings. + * + * @param {string} [parameters.serviceKey] The ServiceKey. + * + * @param {string} [parameters.serviceProviderNotes] The ServiceProviderNotes. + * + * @param {object} [parameters.serviceProviderProperties] The + * ServiceProviderProperties. + * + * @param {string} [parameters.serviceProviderProperties.serviceProviderName] + * The serviceProviderName. + * + * @param {string} [parameters.serviceProviderProperties.peeringLocation] The + * peering location. + * + * @param {number} [parameters.serviceProviderProperties.bandwidthInMbps] The + * BandwidthInMbps. + * + * @param {string} [parameters.provisioningState] Gets the provisioning state + * of the public IP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. + * + * @param {string} [parameters.gatewayManagerEtag] The GatewayManager Etag. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -6685,7 +6724,7 @@ export interface ExpressRouteCrossConnections { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCrossConnectionListResult} - The deserialized result object. + * @resolve {ExpressRouteCircuit} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -6693,27 +6732,29 @@ export interface ExpressRouteCrossConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCrossConnectionListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCrossConnectionListResult} for - * more information. + * {ExpressRouteCircuit} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuit} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByResourceGroup(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByResourceGroup(resourceGroupName: string, callback: ServiceCallback): void; - listByResourceGroup(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, circuitName: string, parameters: models.ExpressRouteCircuit, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, circuitName: string, parameters: models.ExpressRouteCircuit, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, circuitName: string, parameters: models.ExpressRouteCircuit, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets details about the specified ExpressRouteCrossConnection. + * Updates an express route circuit tags. * - * @param {string} resourceGroupName The name of the resource group (peering - * location of the circuit). + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection (service key of the circuit). + * @param {string} circuitName The name of the circuit. + * + * @param {object} parameters Parameters supplied to update express route + * circuit tags. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -6722,20 +6763,23 @@ export interface ExpressRouteCrossConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, circuitName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets details about the specified ExpressRouteCrossConnection. + * Updates an express route circuit tags. * - * @param {string} resourceGroupName The name of the resource group (peering - * location of the circuit). + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection (service key of the circuit). + * @param {string} circuitName The name of the circuit. + * + * @param {object} parameters Parameters supplied to update express route + * circuit tags. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -6749,7 +6793,7 @@ export interface ExpressRouteCrossConnections { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCrossConnection} - The deserialized result object. + * @resolve {ExpressRouteCircuit} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -6757,46 +6801,29 @@ export interface ExpressRouteCrossConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCrossConnection} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCrossConnection} for more - * information. + * {ExpressRouteCircuit} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuit} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, crossConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, crossConnectionName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, crossConnectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, circuitName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdateTags(resourceGroupName: string, circuitName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, circuitName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Update the specified ExpressRouteCrossConnection. + * Gets the currently advertised ARP table associated with the express route + * circuit in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. - * - * @param {object} parameters Parameters supplied to the update express route - * crossConnection operation. - * - * @param {string} [parameters.serviceProviderProvisioningState] The - * provisioning state of the circuit in the connectivity provider system. - * Possible values are 'NotProvisioned', 'Provisioning', 'Provisioned'. - * Possible values include: 'NotProvisioned', 'Provisioning', 'Provisioned', - * 'Deprovisioning' - * - * @param {string} [parameters.serviceProviderNotes] Additional read only notes - * set by the connectivity provider. - * - * @param {array} [parameters.peerings] The list of peerings. - * - * @param {string} [parameters.id] Resource ID. + * @param {string} circuitName The name of the express route circuit. * - * @param {string} [parameters.location] Resource location. + * @param {string} peeringName The name of the peering. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} devicePath The path of the device. * * @param {object} [options] Optional Parameters. * @@ -6805,39 +6832,23 @@ export interface ExpressRouteCrossConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, parameters: models.ExpressRouteCrossConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginListArpTableWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Update the specified ExpressRouteCrossConnection. + * Gets the currently advertised ARP table associated with the express route + * circuit in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. - * - * @param {object} parameters Parameters supplied to the update express route - * crossConnection operation. - * - * @param {string} [parameters.serviceProviderProvisioningState] The - * provisioning state of the circuit in the connectivity provider system. - * Possible values are 'NotProvisioned', 'Provisioning', 'Provisioned'. - * Possible values include: 'NotProvisioned', 'Provisioning', 'Provisioned', - * 'Deprovisioning' - * - * @param {string} [parameters.serviceProviderNotes] Additional read only notes - * set by the connectivity provider. - * - * @param {array} [parameters.peerings] The list of peerings. - * - * @param {string} [parameters.id] Resource ID. + * @param {string} circuitName The name of the express route circuit. * - * @param {string} [parameters.location] Resource location. + * @param {string} peeringName The name of the peering. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} devicePath The path of the device. * * @param {object} [options] Optional Parameters. * @@ -6851,7 +6862,7 @@ export interface ExpressRouteCrossConnections { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCrossConnection} - The deserialized result object. + * @resolve {ExpressRouteCircuitsArpTableListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -6859,30 +6870,30 @@ export interface ExpressRouteCrossConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCrossConnection} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCrossConnection} for more - * information. + * {ExpressRouteCircuitsArpTableListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitsArpTableListResult} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, crossConnectionName: string, parameters: models.ExpressRouteCrossConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, crossConnectionName: string, parameters: models.ExpressRouteCrossConnection, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, crossConnectionName: string, parameters: models.ExpressRouteCrossConnection, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginListArpTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginListArpTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; + beginListArpTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates an express route cross connection tags. + * Gets the currently advertised routes table associated with the express route + * circuit in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} crossConnectionName The name of the cross connection. + * @param {string} circuitName The name of the express route circuit. * - * @param {object} crossConnectionParameters Parameters supplied to update - * express route cross connection tags. + * @param {string} peeringName The name of the peering. * - * @param {object} [crossConnectionParameters.tags] Resource tags. + * @param {string} devicePath The path of the device. * * @param {object} [options] Optional Parameters. * @@ -6891,23 +6902,23 @@ export interface ExpressRouteCrossConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateTagsWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, crossConnectionParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginListRoutesTableWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates an express route cross connection tags. + * Gets the currently advertised routes table associated with the express route + * circuit in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} crossConnectionName The name of the cross connection. + * @param {string} circuitName The name of the express route circuit. * - * @param {object} crossConnectionParameters Parameters supplied to update - * express route cross connection tags. + * @param {string} peeringName The name of the peering. * - * @param {object} [crossConnectionParameters.tags] Resource tags. + * @param {string} devicePath The path of the device. * * @param {object} [options] Optional Parameters. * @@ -6921,7 +6932,7 @@ export interface ExpressRouteCrossConnections { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCrossConnection} - The deserialized result object. + * @resolve {ExpressRouteCircuitsRoutesTableListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -6929,31 +6940,30 @@ export interface ExpressRouteCrossConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCrossConnection} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCrossConnection} for more - * information. + * {ExpressRouteCircuitsRoutesTableListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitsRoutesTableListResult} + * for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - updateTags(resourceGroupName: string, crossConnectionName: string, crossConnectionParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - updateTags(resourceGroupName: string, crossConnectionName: string, crossConnectionParameters: models.TagsObject, callback: ServiceCallback): void; - updateTags(resourceGroupName: string, crossConnectionName: string, crossConnectionParameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginListRoutesTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginListRoutesTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; + beginListRoutesTable(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the currently advertised ARP table associated with the express route - * cross connection in a resource group. + * Gets the currently advertised routes table summary associated with the + * express route circuit in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. + * @param {string} circuitName The name of the express route circuit. * * @param {string} peeringName The name of the peering. * - * @param {string} devicePath The path of the device + * @param {string} devicePath The path of the device. * * @param {object} [options] Optional Parameters. * @@ -6962,24 +6972,23 @@ export interface ExpressRouteCrossConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listArpTableWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginListRoutesTableSummaryWithHttpOperationResponse(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the currently advertised ARP table associated with the express route - * cross connection in a resource group. + * Gets the currently advertised routes table summary associated with the + * express route circuit in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. + * @param {string} circuitName The name of the express route circuit. * * @param {string} peeringName The name of the peering. * - * @param {string} devicePath The path of the device + * @param {string} devicePath The path of the device. * * @param {object} [options] Optional Parameters. * @@ -6993,7 +7002,7 @@ export interface ExpressRouteCrossConnections { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitsArpTableListResult} - The deserialized result object. + * @resolve {ExpressRouteCircuitsRoutesTableSummaryListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -7001,31 +7010,25 @@ export interface ExpressRouteCrossConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitsArpTableListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitsArpTableListResult} for + * {ExpressRouteCircuitsRoutesTableSummaryListResult} [result] - The deserialized result object if an error did not occur. + * See {@link + * ExpressRouteCircuitsRoutesTableSummaryListResult} for * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listArpTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listArpTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; - listArpTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginListRoutesTableSummary(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginListRoutesTableSummary(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; + beginListRoutesTableSummary(resourceGroupName: string, circuitName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the route table summary associated with the express route cross - * connection in a resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. - * - * @param {string} peeringName The name of the peering. + * Gets all the express route circuits in a resource group. * - * @param {string} devicePath The path of the device. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -7034,24 +7037,17 @@ export interface ExpressRouteCrossConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listRoutesTableSummaryWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the route table summary associated with the express route cross - * connection in a resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. - * - * @param {string} peeringName The name of the peering. + * Gets all the express route circuits in a resource group. * - * @param {string} devicePath The path of the device. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -7065,7 +7061,7 @@ export interface ExpressRouteCrossConnections { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCrossConnectionsRoutesTableSummaryListResult} - The deserialized result object. + * @resolve {ExpressRouteCircuitListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -7073,32 +7069,24 @@ export interface ExpressRouteCrossConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCrossConnectionsRoutesTableSummaryListResult} [result] - The deserialized result object if an error did not occur. - * See {@link - * ExpressRouteCrossConnectionsRoutesTableSummaryListResult} - * for more information. + * {ExpressRouteCircuitListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listRoutesTableSummary(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listRoutesTableSummary(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; - listRoutesTableSummary(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the currently advertised routes table associated with the express route - * cross connection in a resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. - * - * @param {string} peeringName The name of the peering. + * Gets all the express route circuits in a subscription. * - * @param {string} devicePath The path of the device. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -7107,24 +7095,17 @@ export interface ExpressRouteCrossConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listRoutesTableWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the currently advertised routes table associated with the express route - * cross connection in a resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. - * - * @param {string} peeringName The name of the peering. + * Gets all the express route circuits in a subscription. * - * @param {string} devicePath The path of the device. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -7138,7 +7119,7 @@ export interface ExpressRouteCrossConnections { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitsRoutesTableListResult} - The deserialized result object. + * @resolve {ExpressRouteCircuitListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -7146,46 +7127,30 @@ export interface ExpressRouteCrossConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitsRoutesTableListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitsRoutesTableListResult} - * for more information. + * {ExpressRouteCircuitListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listRoutesTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listRoutesTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; - listRoutesTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAllNext(nextPageLink: string, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ExpressRouteServiceProviders + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface ExpressRouteServiceProviders { /** - * Update the specified ExpressRouteCrossConnection. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. - * - * @param {object} parameters Parameters supplied to the update express route - * crossConnection operation. - * - * @param {string} [parameters.serviceProviderProvisioningState] The - * provisioning state of the circuit in the connectivity provider system. - * Possible values are 'NotProvisioned', 'Provisioning', 'Provisioned'. - * Possible values include: 'NotProvisioned', 'Provisioning', 'Provisioned', - * 'Deprovisioning' - * - * @param {string} [parameters.serviceProviderNotes] Additional read only notes - * set by the connectivity provider. - * - * @param {array} [parameters.peerings] The list of peerings. - * - * @param {string} [parameters.id] Resource ID. - * - * @param {string} [parameters.location] Resource location. - * - * @param {object} [parameters.tags] Resource tags. + * Gets all the available express route service providers. * * @param {object} [options] Optional Parameters. * @@ -7194,53 +7159,28 @@ export interface ExpressRouteCrossConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, parameters: models.ExpressRouteCrossConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Update the specified ExpressRouteCrossConnection. + * Gets all the available express route service providers. * - * @param {string} resourceGroupName The name of the resource group. + * @param {object} [options] Optional Parameters. * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} parameters Parameters supplied to the update express route - * crossConnection operation. - * - * @param {string} [parameters.serviceProviderProvisioningState] The - * provisioning state of the circuit in the connectivity provider system. - * Possible values are 'NotProvisioned', 'Provisioning', 'Provisioned'. - * Possible values include: 'NotProvisioned', 'Provisioning', 'Provisioned', - * 'Deprovisioning' - * - * @param {string} [parameters.serviceProviderNotes] Additional read only notes - * set by the connectivity provider. - * - * @param {array} [parameters.peerings] The list of peerings. - * - * @param {string} [parameters.id] Resource ID. - * - * @param {string} [parameters.location] Resource location. - * - * @param {object} [parameters.tags] Resource tags. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * * @returns {ServiceCallback|Promise} If a callback was passed as the last * parameter then it returns the callback else returns a Promise. * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCrossConnection} - The deserialized result object. + * @resolve {ExpressRouteServiceProviderListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -7248,30 +7188,24 @@ export interface ExpressRouteCrossConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCrossConnection} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCrossConnection} for more - * information. + * {ExpressRouteServiceProviderListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteServiceProviderListResult} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, crossConnectionName: string, parameters: models.ExpressRouteCrossConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, crossConnectionName: string, parameters: models.ExpressRouteCrossConnection, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, crossConnectionName: string, parameters: models.ExpressRouteCrossConnection, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(callback: ServiceCallback): void; + list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates an express route cross connection tags. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} crossConnectionName The name of the cross connection. - * - * @param {object} crossConnectionParameters Parameters supplied to update - * express route cross connection tags. + * Gets all the available express route service providers. * - * @param {object} [crossConnectionParameters.tags] Resource tags. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -7280,23 +7214,17 @@ export interface ExpressRouteCrossConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, crossConnectionParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates an express route cross connection tags. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} crossConnectionName The name of the cross connection. - * - * @param {object} crossConnectionParameters Parameters supplied to update - * express route cross connection tags. + * Gets all the available express route service providers. * - * @param {object} [crossConnectionParameters.tags] Resource tags. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -7310,7 +7238,7 @@ export interface ExpressRouteCrossConnections { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCrossConnection} - The deserialized result object. + * @resolve {ExpressRouteServiceProviderListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -7318,31 +7246,30 @@ export interface ExpressRouteCrossConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCrossConnection} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCrossConnection} for more - * information. + * {ExpressRouteServiceProviderListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteServiceProviderListResult} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdateTags(resourceGroupName: string, crossConnectionName: string, crossConnectionParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdateTags(resourceGroupName: string, crossConnectionName: string, crossConnectionParameters: models.TagsObject, callback: ServiceCallback): void; - beginUpdateTags(resourceGroupName: string, crossConnectionName: string, crossConnectionParameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ExpressRouteCrossConnections + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface ExpressRouteCrossConnections { /** - * Gets the currently advertised ARP table associated with the express route - * cross connection in a resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. - * - * @param {string} peeringName The name of the peering. - * - * @param {string} devicePath The path of the device + * Retrieves all the ExpressRouteCrossConnections in a subscription. * * @param {object} [options] Optional Parameters. * @@ -7351,24 +7278,14 @@ export interface ExpressRouteCrossConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginListArpTableWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the currently advertised ARP table associated with the express route - * cross connection in a resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. - * - * @param {string} peeringName The name of the peering. - * - * @param {string} devicePath The path of the device + * Retrieves all the ExpressRouteCrossConnections in a subscription. * * @param {object} [options] Optional Parameters. * @@ -7382,7 +7299,7 @@ export interface ExpressRouteCrossConnections { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitsArpTableListResult} - The deserialized result object. + * @resolve {ExpressRouteCrossConnectionListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -7390,32 +7307,24 @@ export interface ExpressRouteCrossConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitsArpTableListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitsArpTableListResult} for + * {ExpressRouteCrossConnectionListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCrossConnectionListResult} for * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginListArpTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginListArpTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; - beginListArpTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(callback: ServiceCallback): void; + list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the route table summary associated with the express route cross - * connection in a resource group. + * Retrieves all the ExpressRouteCrossConnections in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. - * - * @param {string} peeringName The name of the peering. - * - * @param {string} devicePath The path of the device. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -7423,25 +7332,17 @@ export interface ExpressRouteCrossConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginListRoutesTableSummaryWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByResourceGroupWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the route table summary associated with the express route cross - * connection in a resource group. + * Retrieves all the ExpressRouteCrossConnections in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. - * - * @param {string} peeringName The name of the peering. - * - * @param {string} devicePath The path of the device. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -7454,7 +7355,7 @@ export interface ExpressRouteCrossConnections { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCrossConnectionsRoutesTableSummaryListResult} - The deserialized result object. + * @resolve {ExpressRouteCrossConnectionListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -7462,32 +7363,27 @@ export interface ExpressRouteCrossConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCrossConnectionsRoutesTableSummaryListResult} [result] - The deserialized result object if an error did not occur. - * See {@link - * ExpressRouteCrossConnectionsRoutesTableSummaryListResult} - * for more information. + * {ExpressRouteCrossConnectionListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCrossConnectionListResult} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginListRoutesTableSummary(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginListRoutesTableSummary(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; - beginListRoutesTableSummary(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByResourceGroup(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroup(resourceGroupName: string, callback: ServiceCallback): void; + listByResourceGroup(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the currently advertised routes table associated with the express route - * cross connection in a resource group. + * Gets details about the specified ExpressRouteCrossConnection. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the resource group (peering + * location of the circuit). * * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. - * - * @param {string} peeringName The name of the peering. - * - * @param {string} devicePath The path of the device. + * ExpressRouteCrossConnection (service key of the circuit). * * @param {object} [options] Optional Parameters. * @@ -7496,24 +7392,20 @@ export interface ExpressRouteCrossConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginListRoutesTableWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the currently advertised routes table associated with the express route - * cross connection in a resource group. + * Gets details about the specified ExpressRouteCrossConnection. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the resource group (peering + * location of the circuit). * * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. - * - * @param {string} peeringName The name of the peering. - * - * @param {string} devicePath The path of the device. + * ExpressRouteCrossConnection (service key of the circuit). * * @param {object} [options] Optional Parameters. * @@ -7527,7 +7419,7 @@ export interface ExpressRouteCrossConnections { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCircuitsRoutesTableListResult} - The deserialized result object. + * @resolve {ExpressRouteCrossConnection} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -7535,24 +7427,56 @@ export interface ExpressRouteCrossConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCircuitsRoutesTableListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCircuitsRoutesTableListResult} - * for more information. + * {ExpressRouteCrossConnection} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCrossConnection} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginListRoutesTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginListRoutesTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; - beginListRoutesTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, crossConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, crossConnectionName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, crossConnectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Retrieves all the ExpressRouteCrossConnections in a subscription. + * Update the specified ExpressRouteCrossConnection. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. + * + * @param {object} parameters Parameters supplied to the update express route + * crossConnection operation. + * + * @param {string} [parameters.peeringLocation] The peering location of the + * ExpressRoute circuit. + * + * @param {number} [parameters.bandwidthInMbps] The circuit bandwidth In Mbps. + * + * @param {object} [parameters.expressRouteCircuit] The ExpressRouteCircuit + * + * @param {string} [parameters.expressRouteCircuit.id] Corresponding Express + * Route Circuit Id. + * + * @param {string} [parameters.serviceProviderProvisioningState] The + * provisioning state of the circuit in the connectivity provider system. + * Possible values are 'NotProvisioned', 'Provisioning', 'Provisioned'. + * Possible values include: 'NotProvisioned', 'Provisioning', 'Provisioned', + * 'Deprovisioning' + * + * @param {string} [parameters.serviceProviderNotes] Additional read only notes + * set by the connectivity provider. + * + * @param {array} [parameters.peerings] The list of peerings. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -7561,22 +7485,54 @@ export interface ExpressRouteCrossConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, parameters: models.ExpressRouteCrossConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Retrieves all the ExpressRouteCrossConnections in a subscription. + * Update the specified ExpressRouteCrossConnection. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. * - * @param {object} [options] Optional Parameters. + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {object} parameters Parameters supplied to the update express route + * crossConnection operation. + * + * @param {string} [parameters.peeringLocation] The peering location of the + * ExpressRoute circuit. + * + * @param {number} [parameters.bandwidthInMbps] The circuit bandwidth In Mbps. + * + * @param {object} [parameters.expressRouteCircuit] The ExpressRouteCircuit + * + * @param {string} [parameters.expressRouteCircuit.id] Corresponding Express + * Route Circuit Id. + * + * @param {string} [parameters.serviceProviderProvisioningState] The + * provisioning state of the circuit in the connectivity provider system. + * Possible values are 'NotProvisioned', 'Provisioning', 'Provisioned'. + * Possible values include: 'NotProvisioned', 'Provisioning', 'Provisioned', + * 'Deprovisioning' + * + * @param {string} [parameters.serviceProviderNotes] Additional read only notes + * set by the connectivity provider. + * + * @param {array} [parameters.peerings] The list of peerings. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request * * @param {ServiceCallback} [optionalCallback] - The optional callback. * @@ -7585,7 +7541,7 @@ export interface ExpressRouteCrossConnections { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCrossConnectionListResult} - The deserialized result object. + * @resolve {ExpressRouteCrossConnection} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -7593,24 +7549,30 @@ export interface ExpressRouteCrossConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCrossConnectionListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCrossConnectionListResult} for - * more information. + * {ExpressRouteCrossConnection} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCrossConnection} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, crossConnectionName: string, parameters: models.ExpressRouteCrossConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, crossConnectionName: string, parameters: models.ExpressRouteCrossConnection, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, crossConnectionName: string, parameters: models.ExpressRouteCrossConnection, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Retrieves all the ExpressRouteCrossConnections in a resource group. + * Updates an express route cross connection tags. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} crossConnectionName The name of the cross connection. + * + * @param {object} crossConnectionParameters Parameters supplied to update + * express route cross connection tags. + * + * @param {object} [crossConnectionParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -7619,17 +7581,23 @@ export interface ExpressRouteCrossConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByResourceGroupNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateTagsWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, crossConnectionParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Retrieves all the ExpressRouteCrossConnections in a resource group. + * Updates an express route cross connection tags. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} crossConnectionName The name of the cross connection. + * + * @param {object} crossConnectionParameters Parameters supplied to update + * express route cross connection tags. + * + * @param {object} [crossConnectionParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -7643,7 +7611,7 @@ export interface ExpressRouteCrossConnections { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCrossConnectionListResult} - The deserialized result object. + * @resolve {ExpressRouteCrossConnection} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -7651,36 +7619,32 @@ export interface ExpressRouteCrossConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCrossConnectionListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCrossConnectionListResult} for - * more information. + * {ExpressRouteCrossConnection} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCrossConnection} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByResourceGroupNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByResourceGroupNext(nextPageLink: string, callback: ServiceCallback): void; - listByResourceGroupNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * ExpressRouteCrossConnectionPeerings - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface ExpressRouteCrossConnectionPeerings { + updateTags(resourceGroupName: string, crossConnectionName: string, crossConnectionParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, crossConnectionName: string, crossConnectionParameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, crossConnectionName: string, crossConnectionParameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all peerings in a specified ExpressRouteCrossConnection. + * Gets the currently advertised ARP table associated with the express route + * cross connection in a resource group. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} crossConnectionName The name of the * ExpressRouteCrossConnection. * + * @param {string} peeringName The name of the peering. + * + * @param {string} devicePath The path of the device + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -7688,20 +7652,25 @@ export interface ExpressRouteCrossConnectionPeerings { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listArpTableWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all peerings in a specified ExpressRouteCrossConnection. + * Gets the currently advertised ARP table associated with the express route + * cross connection in a resource group. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} crossConnectionName The name of the * ExpressRouteCrossConnection. * + * @param {string} peeringName The name of the peering. + * + * @param {string} devicePath The path of the device + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -7714,7 +7683,7 @@ export interface ExpressRouteCrossConnectionPeerings { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCrossConnectionPeeringList} - The deserialized result object. + * @resolve {ExpressRouteCircuitsArpTableListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -7722,21 +7691,22 @@ export interface ExpressRouteCrossConnectionPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCrossConnectionPeeringList} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCrossConnectionPeeringList} for + * {ExpressRouteCircuitsArpTableListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitsArpTableListResult} for * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, crossConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, crossConnectionName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, crossConnectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listArpTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listArpTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; + listArpTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified peering from the ExpressRouteCrossConnection. + * Gets the route table summary associated with the express route cross + * connection in a resource group. * * @param {string} resourceGroupName The name of the resource group. * @@ -7745,6 +7715,8 @@ export interface ExpressRouteCrossConnectionPeerings { * * @param {string} peeringName The name of the peering. * + * @param {string} devicePath The path of the device. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -7752,14 +7724,15 @@ export interface ExpressRouteCrossConnectionPeerings { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listRoutesTableSummaryWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified peering from the ExpressRouteCrossConnection. + * Gets the route table summary associated with the express route cross + * connection in a resource group. * * @param {string} resourceGroupName The name of the resource group. * @@ -7768,6 +7741,8 @@ export interface ExpressRouteCrossConnectionPeerings { * * @param {string} peeringName The name of the peering. * + * @param {string} devicePath The path of the device. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -7780,7 +7755,7 @@ export interface ExpressRouteCrossConnectionPeerings { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ExpressRouteCrossConnectionsRoutesTableSummaryListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -7788,19 +7763,23 @@ export interface ExpressRouteCrossConnectionPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ExpressRouteCrossConnectionsRoutesTableSummaryListResult} [result] - The deserialized result object if an error did not occur. + * See {@link + * ExpressRouteCrossConnectionsRoutesTableSummaryListResult} + * for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, crossConnectionName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, crossConnectionName: string, peeringName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, crossConnectionName: string, peeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listRoutesTableSummary(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listRoutesTableSummary(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; + listRoutesTableSummary(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified peering for the ExpressRouteCrossConnection. + * Gets the currently advertised routes table associated with the express route + * cross connection in a resource group. * * @param {string} resourceGroupName The name of the resource group. * @@ -7809,6 +7788,8 @@ export interface ExpressRouteCrossConnectionPeerings { * * @param {string} peeringName The name of the peering. * + * @param {string} devicePath The path of the device. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -7816,14 +7797,15 @@ export interface ExpressRouteCrossConnectionPeerings { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listRoutesTableWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified peering for the ExpressRouteCrossConnection. + * Gets the currently advertised routes table associated with the express route + * cross connection in a resource group. * * @param {string} resourceGroupName The name of the resource group. * @@ -7832,6 +7814,8 @@ export interface ExpressRouteCrossConnectionPeerings { * * @param {string} peeringName The name of the peering. * + * @param {string} devicePath The path of the device. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -7844,7 +7828,7 @@ export interface ExpressRouteCrossConnectionPeerings { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCrossConnectionPeering} - The deserialized result object. + * @resolve {ExpressRouteCircuitsRoutesTableListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -7852,245 +7836,249 @@ export interface ExpressRouteCrossConnectionPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCrossConnectionPeering} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCrossConnectionPeering} for more - * information. + * {ExpressRouteCircuitsRoutesTableListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitsRoutesTableListResult} + * for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, crossConnectionName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, crossConnectionName: string, peeringName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, crossConnectionName: string, peeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listRoutesTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listRoutesTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; + listRoutesTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a peering in the specified ExpressRouteCrossConnection. + * Update the specified ExpressRouteCrossConnection. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} crossConnectionName The name of the * ExpressRouteCrossConnection. * - * @param {string} peeringName The name of the peering. + * @param {object} parameters Parameters supplied to the update express route + * crossConnection operation. * - * @param {object} peeringParameters Parameters supplied to the create or - * update ExpressRouteCrossConnection peering operation. + * @param {string} [parameters.peeringLocation] The peering location of the + * ExpressRoute circuit. * - * @param {string} [peeringParameters.peeringType] The peering type. Possible - * values include: 'AzurePublicPeering', 'AzurePrivatePeering', - * 'MicrosoftPeering' + * @param {number} [parameters.bandwidthInMbps] The circuit bandwidth In Mbps. * - * @param {string} [peeringParameters.state] The peering state. Possible values - * include: 'Disabled', 'Enabled' + * @param {object} [parameters.expressRouteCircuit] The ExpressRouteCircuit * - * @param {number} [peeringParameters.peerASN] The peer ASN. + * @param {string} [parameters.expressRouteCircuit.id] Corresponding Express + * Route Circuit Id. * - * @param {string} [peeringParameters.primaryPeerAddressPrefix] The primary - * address prefix. + * @param {string} [parameters.serviceProviderProvisioningState] The + * provisioning state of the circuit in the connectivity provider system. + * Possible values are 'NotProvisioned', 'Provisioning', 'Provisioned'. + * Possible values include: 'NotProvisioned', 'Provisioning', 'Provisioned', + * 'Deprovisioning' * - * @param {string} [peeringParameters.secondaryPeerAddressPrefix] The secondary - * address prefix. + * @param {string} [parameters.serviceProviderNotes] Additional read only notes + * set by the connectivity provider. * - * @param {string} [peeringParameters.sharedKey] The shared key. + * @param {array} [parameters.peerings] The list of peerings. * - * @param {number} [peeringParameters.vlanId] The VLAN ID. + * @param {string} [parameters.id] Resource ID. * - * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft - * peering configuration. + * @param {string} [parameters.location] Resource location. * - * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider - * or the customer last modified the peering. + * @param {object} [parameters.tags] Resource tags. * - * @param {object} [peeringParameters.ipv6PeeringConfig] The IPv6 peering - * configuration. + * @param {object} [options] Optional Parameters. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.primaryPeerAddressPrefix] The primary - * address prefix. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.secondaryPeerAddressPrefix] The - * secondary address prefix. + * @returns {Promise} A promise is returned * - * @param {object} [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig] - * The Microsoft peering configuration. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {array} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixes] - * The reference of AdvertisedPublicPrefixes. + * @reject {Error|ServiceError} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, parameters: models.ExpressRouteCrossConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Update the specified ExpressRouteCrossConnection. * - * @param {array} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedCommunities] - * The communities of bgp peering. Spepcified for microsoft peering + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixesState] - * AdvertisedPublicPrefixState of the Peering resource. Possible values are - * 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. - * Possible values include: 'NotConfigured', 'Configuring', 'Configured', - * 'ValidationNeeded' + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. * - * @param {number} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.legacyMode] The - * legacy mode of the peering. + * @param {object} parameters Parameters supplied to the update express route + * crossConnection operation. * - * @param {number} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.customerASN] The - * CustomerASN of the peering. + * @param {string} [parameters.peeringLocation] The peering location of the + * ExpressRoute circuit. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.routingRegistryName] - * The RoutingRegistryName of the configuration. - * - * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter] The - * reference of the RouteFilter resource. + * @param {number} [parameters.bandwidthInMbps] The circuit bandwidth In Mbps. * - * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.rules] - * Collection of RouteFilterRules contained within a route filter. + * @param {object} [parameters.expressRouteCircuit] The ExpressRouteCircuit * - * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.peerings] A - * collection of references to express route circuit peerings. + * @param {string} [parameters.expressRouteCircuit.id] Corresponding Express + * Route Circuit Id. * - * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.id] - * Resource ID. + * @param {string} [parameters.serviceProviderProvisioningState] The + * provisioning state of the circuit in the connectivity provider system. + * Possible values are 'NotProvisioned', 'Provisioning', 'Provisioned'. + * Possible values include: 'NotProvisioned', 'Provisioning', 'Provisioned', + * 'Deprovisioning' * - * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.location] - * Resource location. + * @param {string} [parameters.serviceProviderNotes] Additional read only notes + * set by the connectivity provider. * - * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter.tags] - * Resource tags. + * @param {array} [parameters.peerings] The list of peerings. * - * @param {string} [peeringParameters.ipv6PeeringConfig.state] The state of - * peering. Possible values are: 'Disabled' and 'Enabled'. Possible values - * include: 'Disabled', 'Enabled' + * @param {string} [parameters.id] Resource ID. * - * @param {string} [peeringParameters.name] Gets name of the resource that is - * unique within a resource group. This name can be used to access the - * resource. + * @param {string} [parameters.location] Resource location. * - * @param {string} [peeringParameters.id] Resource ID. + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * - * @returns {Promise} A promise is returned + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @reject {Error|ServiceError} - The error object. + * {Promise} A promise is returned. + * + * @resolve {ExpressRouteCrossConnection} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {ExpressRouteCrossConnection} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCrossConnection} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, peeringParameters: models.ExpressRouteCrossConnectionPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdate(resourceGroupName: string, crossConnectionName: string, parameters: models.ExpressRouteCrossConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, crossConnectionName: string, parameters: models.ExpressRouteCrossConnection, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, crossConnectionName: string, parameters: models.ExpressRouteCrossConnection, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + /** - * Creates or updates a peering in the specified ExpressRouteCrossConnection. + * Updates an express route cross connection tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} crossConnectionName The name of the - * ExpressRouteCrossConnection. + * @param {string} crossConnectionName The name of the cross connection. * - * @param {string} peeringName The name of the peering. + * @param {object} crossConnectionParameters Parameters supplied to update + * express route cross connection tags. * - * @param {object} peeringParameters Parameters supplied to the create or - * update ExpressRouteCrossConnection peering operation. + * @param {object} [crossConnectionParameters.tags] Resource tags. * - * @param {string} [peeringParameters.peeringType] The peering type. Possible - * values include: 'AzurePublicPeering', 'AzurePrivatePeering', - * 'MicrosoftPeering' + * @param {object} [options] Optional Parameters. * - * @param {string} [peeringParameters.state] The peering state. Possible values - * include: 'Disabled', 'Enabled' + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {number} [peeringParameters.peerASN] The peer ASN. + * @returns {Promise} A promise is returned * - * @param {string} [peeringParameters.primaryPeerAddressPrefix] The primary - * address prefix. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [peeringParameters.secondaryPeerAddressPrefix] The secondary - * address prefix. + * @reject {Error|ServiceError} - The error object. + */ + beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, crossConnectionParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Updates an express route cross connection tags. * - * @param {string} [peeringParameters.sharedKey] The shared key. + * @param {string} resourceGroupName The name of the resource group. * - * @param {number} [peeringParameters.vlanId] The VLAN ID. + * @param {string} crossConnectionName The name of the cross connection. * - * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft - * peering configuration. + * @param {object} crossConnectionParameters Parameters supplied to update + * express route cross connection tags. * - * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider - * or the customer last modified the peering. + * @param {object} [crossConnectionParameters.tags] Resource tags. * - * @param {object} [peeringParameters.ipv6PeeringConfig] The IPv6 peering - * configuration. + * @param {object} [options] Optional Parameters. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.primaryPeerAddressPrefix] The primary - * address prefix. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.secondaryPeerAddressPrefix] The - * secondary address prefix. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {object} [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig] - * The Microsoft peering configuration. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {array} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixes] - * The reference of AdvertisedPublicPrefixes. + * {Promise} A promise is returned. * - * @param {array} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedCommunities] - * The communities of bgp peering. Spepcified for microsoft peering + * @resolve {ExpressRouteCrossConnection} - The deserialized result object. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixesState] - * AdvertisedPublicPrefixState of the Peering resource. Possible values are - * 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. - * Possible values include: 'NotConfigured', 'Configuring', 'Configured', - * 'ValidationNeeded' + * @reject {Error|ServiceError} - The error object. * - * @param {number} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.legacyMode] The - * legacy mode of the peering. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {number} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.customerASN] The - * CustomerASN of the peering. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.routingRegistryName] - * The RoutingRegistryName of the configuration. + * {ExpressRouteCrossConnection} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCrossConnection} for more + * information. * - * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter] The - * reference of the RouteFilter resource. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.rules] - * Collection of RouteFilterRules contained within a route filter. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginUpdateTags(resourceGroupName: string, crossConnectionName: string, crossConnectionParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdateTags(resourceGroupName: string, crossConnectionName: string, crossConnectionParameters: models.TagsObject, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, crossConnectionName: string, crossConnectionParameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets the currently advertised ARP table associated with the express route + * cross connection in a resource group. * - * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.peerings] A - * collection of references to express route circuit peerings. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.id] - * Resource ID. + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. * - * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.location] - * Resource location. + * @param {string} peeringName The name of the peering. * - * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter.tags] - * Resource tags. + * @param {string} devicePath The path of the device * - * @param {string} [peeringParameters.ipv6PeeringConfig.state] The state of - * peering. Possible values are: 'Disabled' and 'Enabled'. Possible values - * include: 'Disabled', 'Enabled' + * @param {object} [options] Optional Parameters. * - * @param {string} [peeringParameters.name] Gets name of the resource that is - * unique within a resource group. This name can be used to access the - * resource. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [peeringParameters.id] Resource ID. + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginListArpTableWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets the currently advertised ARP table associated with the express route + * cross connection in a resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. + * + * @param {string} peeringName The name of the peering. + * + * @param {string} devicePath The path of the device * * @param {object} [options] Optional Parameters. * @@ -8104,7 +8092,7 @@ export interface ExpressRouteCrossConnectionPeerings { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCrossConnectionPeering} - The deserialized result object. + * @resolve {ExpressRouteCircuitsArpTableListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -8112,21 +8100,22 @@ export interface ExpressRouteCrossConnectionPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCrossConnectionPeering} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCrossConnectionPeering} for more - * information. + * {ExpressRouteCircuitsArpTableListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitsArpTableListResult} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, crossConnectionName: string, peeringName: string, peeringParameters: models.ExpressRouteCrossConnectionPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, crossConnectionName: string, peeringName: string, peeringParameters: models.ExpressRouteCrossConnectionPeering, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, crossConnectionName: string, peeringName: string, peeringParameters: models.ExpressRouteCrossConnectionPeering, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginListArpTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginListArpTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; + beginListArpTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified peering from the ExpressRouteCrossConnection. + * Gets the route table summary associated with the express route cross + * connection in a resource group. * * @param {string} resourceGroupName The name of the resource group. * @@ -8135,6 +8124,8 @@ export interface ExpressRouteCrossConnectionPeerings { * * @param {string} peeringName The name of the peering. * + * @param {string} devicePath The path of the device. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -8142,14 +8133,15 @@ export interface ExpressRouteCrossConnectionPeerings { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginListRoutesTableSummaryWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified peering from the ExpressRouteCrossConnection. + * Gets the route table summary associated with the express route cross + * connection in a resource group. * * @param {string} resourceGroupName The name of the resource group. * @@ -8158,6 +8150,8 @@ export interface ExpressRouteCrossConnectionPeerings { * * @param {string} peeringName The name of the peering. * + * @param {string} devicePath The path of the device. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -8170,7 +8164,7 @@ export interface ExpressRouteCrossConnectionPeerings { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ExpressRouteCrossConnectionsRoutesTableSummaryListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -8178,19 +8172,23 @@ export interface ExpressRouteCrossConnectionPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ExpressRouteCrossConnectionsRoutesTableSummaryListResult} [result] - The deserialized result object if an error did not occur. + * See {@link + * ExpressRouteCrossConnectionsRoutesTableSummaryListResult} + * for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, crossConnectionName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, crossConnectionName: string, peeringName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, crossConnectionName: string, peeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginListRoutesTableSummary(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginListRoutesTableSummary(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; + beginListRoutesTableSummary(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a peering in the specified ExpressRouteCrossConnection. + * Gets the currently advertised routes table associated with the express route + * cross connection in a resource group. * * @param {string} resourceGroupName The name of the resource group. * @@ -8199,102 +8197,7 @@ export interface ExpressRouteCrossConnectionPeerings { * * @param {string} peeringName The name of the peering. * - * @param {object} peeringParameters Parameters supplied to the create or - * update ExpressRouteCrossConnection peering operation. - * - * @param {string} [peeringParameters.peeringType] The peering type. Possible - * values include: 'AzurePublicPeering', 'AzurePrivatePeering', - * 'MicrosoftPeering' - * - * @param {string} [peeringParameters.state] The peering state. Possible values - * include: 'Disabled', 'Enabled' - * - * @param {number} [peeringParameters.peerASN] The peer ASN. - * - * @param {string} [peeringParameters.primaryPeerAddressPrefix] The primary - * address prefix. - * - * @param {string} [peeringParameters.secondaryPeerAddressPrefix] The secondary - * address prefix. - * - * @param {string} [peeringParameters.sharedKey] The shared key. - * - * @param {number} [peeringParameters.vlanId] The VLAN ID. - * - * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft - * peering configuration. - * - * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider - * or the customer last modified the peering. - * - * @param {object} [peeringParameters.ipv6PeeringConfig] The IPv6 peering - * configuration. - * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.primaryPeerAddressPrefix] The primary - * address prefix. - * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.secondaryPeerAddressPrefix] The - * secondary address prefix. - * - * @param {object} [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig] - * The Microsoft peering configuration. - * - * @param {array} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixes] - * The reference of AdvertisedPublicPrefixes. - * - * @param {array} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedCommunities] - * The communities of bgp peering. Spepcified for microsoft peering - * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixesState] - * AdvertisedPublicPrefixState of the Peering resource. Possible values are - * 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. - * Possible values include: 'NotConfigured', 'Configuring', 'Configured', - * 'ValidationNeeded' - * - * @param {number} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.legacyMode] The - * legacy mode of the peering. - * - * @param {number} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.customerASN] The - * CustomerASN of the peering. - * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.routingRegistryName] - * The RoutingRegistryName of the configuration. - * - * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter] The - * reference of the RouteFilter resource. - * - * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.rules] - * Collection of RouteFilterRules contained within a route filter. - * - * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.peerings] A - * collection of references to express route circuit peerings. - * - * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.id] - * Resource ID. - * - * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.location] - * Resource location. - * - * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter.tags] - * Resource tags. - * - * @param {string} [peeringParameters.ipv6PeeringConfig.state] The state of - * peering. Possible values are: 'Disabled' and 'Enabled'. Possible values - * include: 'Disabled', 'Enabled' - * - * @param {string} [peeringParameters.name] Gets name of the resource that is - * unique within a resource group. This name can be used to access the - * resource. - * - * @param {string} [peeringParameters.id] Resource ID. + * @param {string} devicePath The path of the device. * * @param {object} [options] Optional Parameters. * @@ -8303,14 +8206,15 @@ export interface ExpressRouteCrossConnectionPeerings { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, peeringParameters: models.ExpressRouteCrossConnectionPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginListRoutesTableWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a peering in the specified ExpressRouteCrossConnection. + * Gets the currently advertised routes table associated with the express route + * cross connection in a resource group. * * @param {string} resourceGroupName The name of the resource group. * @@ -8319,102 +8223,65 @@ export interface ExpressRouteCrossConnectionPeerings { * * @param {string} peeringName The name of the peering. * - * @param {object} peeringParameters Parameters supplied to the create or - * update ExpressRouteCrossConnection peering operation. - * - * @param {string} [peeringParameters.peeringType] The peering type. Possible - * values include: 'AzurePublicPeering', 'AzurePrivatePeering', - * 'MicrosoftPeering' - * - * @param {string} [peeringParameters.state] The peering state. Possible values - * include: 'Disabled', 'Enabled' - * - * @param {number} [peeringParameters.peerASN] The peer ASN. - * - * @param {string} [peeringParameters.primaryPeerAddressPrefix] The primary - * address prefix. - * - * @param {string} [peeringParameters.secondaryPeerAddressPrefix] The secondary - * address prefix. - * - * @param {string} [peeringParameters.sharedKey] The shared key. - * - * @param {number} [peeringParameters.vlanId] The VLAN ID. - * - * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft - * peering configuration. - * - * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider - * or the customer last modified the peering. + * @param {string} devicePath The path of the device. * - * @param {object} [peeringParameters.ipv6PeeringConfig] The IPv6 peering - * configuration. + * @param {object} [options] Optional Parameters. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.primaryPeerAddressPrefix] The primary - * address prefix. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.secondaryPeerAddressPrefix] The - * secondary address prefix. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {object} [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig] - * The Microsoft peering configuration. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {array} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixes] - * The reference of AdvertisedPublicPrefixes. + * {Promise} A promise is returned. * - * @param {array} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedCommunities] - * The communities of bgp peering. Spepcified for microsoft peering + * @resolve {ExpressRouteCircuitsRoutesTableListResult} - The deserialized result object. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixesState] - * AdvertisedPublicPrefixState of the Peering resource. Possible values are - * 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. - * Possible values include: 'NotConfigured', 'Configuring', 'Configured', - * 'ValidationNeeded' + * @reject {Error|ServiceError} - The error object. * - * @param {number} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.legacyMode] The - * legacy mode of the peering. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {number} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.customerASN] The - * CustomerASN of the peering. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} - * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.routingRegistryName] - * The RoutingRegistryName of the configuration. + * {ExpressRouteCircuitsRoutesTableListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCircuitsRoutesTableListResult} + * for more information. * - * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter] The - * reference of the RouteFilter resource. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.rules] - * Collection of RouteFilterRules contained within a route filter. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginListRoutesTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginListRoutesTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, callback: ServiceCallback): void; + beginListRoutesTable(resourceGroupName: string, crossConnectionName: string, peeringName: string, devicePath: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Retrieves all the ExpressRouteCrossConnections in a subscription. * - * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.peerings] A - * collection of references to express route circuit peerings. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.id] - * Resource ID. + * @param {object} [options] Optional Parameters. * - * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.location] - * Resource location. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter.tags] - * Resource tags. + * @returns {Promise} A promise is returned * - * @param {string} [peeringParameters.ipv6PeeringConfig.state] The state of - * peering. Possible values are: 'Disabled' and 'Enabled'. Possible values - * include: 'Disabled', 'Enabled' + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [peeringParameters.name] Gets name of the resource that is - * unique within a resource group. This name can be used to access the - * resource. + * @reject {Error|ServiceError} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Retrieves all the ExpressRouteCrossConnections in a subscription. * - * @param {string} [peeringParameters.id] Resource ID. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -8428,7 +8295,7 @@ export interface ExpressRouteCrossConnectionPeerings { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCrossConnectionPeering} - The deserialized result object. + * @resolve {ExpressRouteCrossConnectionListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -8436,21 +8303,21 @@ export interface ExpressRouteCrossConnectionPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCrossConnectionPeering} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCrossConnectionPeering} for more - * information. + * {ExpressRouteCrossConnectionListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCrossConnectionListResult} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, crossConnectionName: string, peeringName: string, peeringParameters: models.ExpressRouteCrossConnectionPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, crossConnectionName: string, peeringName: string, peeringParameters: models.ExpressRouteCrossConnectionPeering, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, crossConnectionName: string, peeringName: string, peeringParameters: models.ExpressRouteCrossConnectionPeering, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all peerings in a specified ExpressRouteCrossConnection. + * Retrieves all the ExpressRouteCrossConnections in a resource group. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -8462,14 +8329,14 @@ export interface ExpressRouteCrossConnectionPeerings { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByResourceGroupNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all peerings in a specified ExpressRouteCrossConnection. + * Retrieves all the ExpressRouteCrossConnections in a resource group. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -8486,7 +8353,7 @@ export interface ExpressRouteCrossConnectionPeerings { * * {Promise} A promise is returned. * - * @resolve {ExpressRouteCrossConnectionPeeringList} - The deserialized result object. + * @resolve {ExpressRouteCrossConnectionListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -8494,34 +8361,35 @@ export interface ExpressRouteCrossConnectionPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ExpressRouteCrossConnectionPeeringList} [result] - The deserialized result object if an error did not occur. - * See {@link ExpressRouteCrossConnectionPeeringList} for + * {ExpressRouteCrossConnectionListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCrossConnectionListResult} for * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByResourceGroupNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroupNext(nextPageLink: string, callback: ServiceCallback): void; + listByResourceGroupNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } /** * @class - * LoadBalancers + * ExpressRouteCrossConnectionPeerings * __NOTE__: An instance of this class is automatically created for an * instance of the NetworkManagementClient. */ -export interface LoadBalancers { +export interface ExpressRouteCrossConnectionPeerings { /** - * Deletes the specified load balancer. + * Gets all peerings in a specified ExpressRouteCrossConnection. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} loadBalancerName The name of the load balancer. + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. * * @param {object} [options] Optional Parameters. * @@ -8530,18 +8398,19 @@ export interface LoadBalancers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified load balancer. + * Gets all peerings in a specified ExpressRouteCrossConnection. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} loadBalancerName The name of the load balancer. + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. * * @param {object} [options] Optional Parameters. * @@ -8555,7 +8424,7 @@ export interface LoadBalancers { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ExpressRouteCrossConnectionPeeringList} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -8563,49 +8432,53 @@ export interface LoadBalancers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ExpressRouteCrossConnectionPeeringList} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCrossConnectionPeeringList} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, loadBalancerName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, crossConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, crossConnectionName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, crossConnectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified load balancer. + * Deletes the specified peering from the ExpressRouteCrossConnection. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} loadBalancerName The name of the load balancer. + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. * - * @param {object} [options] Optional Parameters. + * @param {string} peeringName The name of the peering. * - * @param {string} [options.expand] Expands referenced resources. + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified load balancer. + * Deletes the specified peering from the ExpressRouteCrossConnection. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} loadBalancerName The name of the load balancer. + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. * - * @param {object} [options] Optional Parameters. + * @param {string} peeringName The name of the peering. * - * @param {string} [options.expand] Expands referenced resources. + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request @@ -8617,7 +8490,7 @@ export interface LoadBalancers { * * {Promise} A promise is returned. * - * @resolve {LoadBalancer} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -8625,79 +8498,26 @@ export interface LoadBalancers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LoadBalancer} [result] - The deserialized result object if an error did not occur. - * See {@link LoadBalancer} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, loadBalancerName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, loadBalancerName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, crossConnectionName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, crossConnectionName: string, peeringName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, crossConnectionName: string, peeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a load balancer. + * Gets the specified peering for the ExpressRouteCrossConnection. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} loadBalancerName The name of the load balancer. - * - * @param {object} parameters Parameters supplied to the create or update load - * balancer operation. - * - * @param {object} [parameters.sku] The load balancer SKU. - * - * @param {string} [parameters.sku.name] Name of a load balancer SKU. Possible - * values include: 'Basic', 'Standard' - * - * @param {array} [parameters.frontendIPConfigurations] Object representing the - * frontend IPs to be used for the load balancer - * - * @param {array} [parameters.backendAddressPools] Collection of backend - * address pools used by a load balancer - * - * @param {array} [parameters.loadBalancingRules] Object collection - * representing the load balancing rules Gets the provisioning - * - * @param {array} [parameters.probes] Collection of probe objects used in the - * load balancer - * - * @param {array} [parameters.inboundNatRules] Collection of inbound NAT Rules - * used by a load balancer. Defining inbound NAT rules on your load balancer is - * mutually exclusive with defining an inbound NAT pool. Inbound NAT pools are - * referenced from virtual machine scale sets. NICs that are associated with - * individual virtual machines cannot reference an Inbound NAT pool. They have - * to reference individual inbound NAT rules. - * - * @param {array} [parameters.inboundNatPools] Defines an external port range - * for inbound NAT to a single backend port on NICs associated with a load - * balancer. Inbound NAT rules are created automatically for each NIC - * associated with the Load Balancer using an external port from this range. - * Defining an Inbound NAT pool on your Load Balancer is mutually exclusive - * with defining inbound Nat rules. Inbound NAT pools are referenced from - * virtual machine scale sets. NICs that are associated with individual virtual - * machines cannot reference an inbound NAT pool. They have to reference - * individual inbound NAT rules. - * - * @param {array} [parameters.outboundNatRules] The outbound NAT rules. - * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * load balancer resource. - * - * @param {string} [parameters.provisioningState] Gets the provisioning state - * of the PublicIP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. - * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. - * - * @param {string} [parameters.id] Resource ID. - * - * @param {string} [parameters.location] Resource location. + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} peeringName The name of the peering. * * @param {object} [options] Optional Parameters. * @@ -8706,73 +8526,21 @@ export interface LoadBalancers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, parameters: models.LoadBalancer, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a load balancer. + * Gets the specified peering for the ExpressRouteCrossConnection. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} loadBalancerName The name of the load balancer. - * - * @param {object} parameters Parameters supplied to the create or update load - * balancer operation. - * - * @param {object} [parameters.sku] The load balancer SKU. - * - * @param {string} [parameters.sku.name] Name of a load balancer SKU. Possible - * values include: 'Basic', 'Standard' - * - * @param {array} [parameters.frontendIPConfigurations] Object representing the - * frontend IPs to be used for the load balancer - * - * @param {array} [parameters.backendAddressPools] Collection of backend - * address pools used by a load balancer - * - * @param {array} [parameters.loadBalancingRules] Object collection - * representing the load balancing rules Gets the provisioning - * - * @param {array} [parameters.probes] Collection of probe objects used in the - * load balancer - * - * @param {array} [parameters.inboundNatRules] Collection of inbound NAT Rules - * used by a load balancer. Defining inbound NAT rules on your load balancer is - * mutually exclusive with defining an inbound NAT pool. Inbound NAT pools are - * referenced from virtual machine scale sets. NICs that are associated with - * individual virtual machines cannot reference an Inbound NAT pool. They have - * to reference individual inbound NAT rules. - * - * @param {array} [parameters.inboundNatPools] Defines an external port range - * for inbound NAT to a single backend port on NICs associated with a load - * balancer. Inbound NAT rules are created automatically for each NIC - * associated with the Load Balancer using an external port from this range. - * Defining an Inbound NAT pool on your Load Balancer is mutually exclusive - * with defining inbound Nat rules. Inbound NAT pools are referenced from - * virtual machine scale sets. NICs that are associated with individual virtual - * machines cannot reference an inbound NAT pool. They have to reference - * individual inbound NAT rules. - * - * @param {array} [parameters.outboundNatRules] The outbound NAT rules. - * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * load balancer resource. - * - * @param {string} [parameters.provisioningState] Gets the provisioning state - * of the PublicIP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. - * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. - * - * @param {string} [parameters.id] Resource ID. - * - * @param {string} [parameters.location] Resource location. + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} peeringName The name of the peering. * * @param {object} [options] Optional Parameters. * @@ -8786,7 +8554,7 @@ export interface LoadBalancers { * * {Promise} A promise is returned. * - * @resolve {LoadBalancer} - The deserialized result object. + * @resolve {ExpressRouteCrossConnectionPeering} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -8794,87 +8562,128 @@ export interface LoadBalancers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LoadBalancer} [result] - The deserialized result object if an error did not occur. - * See {@link LoadBalancer} for more information. + * {ExpressRouteCrossConnectionPeering} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCrossConnectionPeering} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, loadBalancerName: string, parameters: models.LoadBalancer, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, loadBalancerName: string, parameters: models.LoadBalancer, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, loadBalancerName: string, parameters: models.LoadBalancer, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, crossConnectionName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, crossConnectionName: string, peeringName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, crossConnectionName: string, peeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a load balancer tags. + * Creates or updates a peering in the specified ExpressRouteCrossConnection. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} loadBalancerName The name of the load balancer. - * - * @param {object} parameters Parameters supplied to update load balancer tags. + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} peeringName The name of the peering. * - * @param {object} [options] Optional Parameters. + * @param {object} peeringParameters Parameters supplied to the create or + * update ExpressRouteCrossConnection peering operation. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [peeringParameters.peeringType] The peering type. Possible + * values include: 'AzurePublicPeering', 'AzurePrivatePeering', + * 'MicrosoftPeering' * - * @returns {Promise} A promise is returned + * @param {string} [peeringParameters.state] The peering state. Possible values + * include: 'Disabled', 'Enabled' * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {number} [peeringParameters.peerASN] The peer ASN. * - * @reject {Error|ServiceError} - The error object. - */ - updateTagsWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Updates a load balancer tags. + * @param {string} [peeringParameters.primaryPeerAddressPrefix] The primary + * address prefix. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [peeringParameters.secondaryPeerAddressPrefix] The secondary + * address prefix. * - * @param {string} loadBalancerName The name of the load balancer. + * @param {string} [peeringParameters.sharedKey] The shared key. * - * @param {object} parameters Parameters supplied to update load balancer tags. + * @param {number} [peeringParameters.vlanId] The VLAN ID. * - * @param {object} [parameters.tags] Resource tags. + * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft + * peering configuration. * - * @param {object} [options] Optional Parameters. + * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager + * Etag. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider + * or the customer last modified the peering. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {object} [peeringParameters.ipv6PeeringConfig] The IPv6 peering + * configuration. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.primaryPeerAddressPrefix] The primary + * address prefix. * - * {Promise} A promise is returned. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.secondaryPeerAddressPrefix] The + * secondary address prefix. * - * @resolve {LoadBalancer} - The deserialized result object. + * @param {object} [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig] + * The Microsoft peering configuration. * - * @reject {Error|ServiceError} - The error object. + * @param {array} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixes] + * The reference of AdvertisedPublicPrefixes. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {array} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedCommunities] + * The communities of bgp peering. Spepcified for microsoft peering * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixesState] + * AdvertisedPublicPrefixState of the Peering resource. Possible values are + * 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. + * Possible values include: 'NotConfigured', 'Configuring', 'Configured', + * 'ValidationNeeded' * - * {LoadBalancer} [result] - The deserialized result object if an error did not occur. - * See {@link LoadBalancer} for more information. + * @param {number} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.legacyMode] The + * legacy mode of the peering. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {number} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.customerASN] The + * CustomerASN of the peering. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - updateTags(resourceGroupName: string, loadBalancerName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - updateTags(resourceGroupName: string, loadBalancerName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - updateTags(resourceGroupName: string, loadBalancerName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets all the load balancers in a subscription. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.routingRegistryName] + * The RoutingRegistryName of the configuration. + * + * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter] The + * reference of the RouteFilter resource. + * + * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.rules] + * Collection of RouteFilterRules contained within a route filter. + * + * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.peerings] A + * collection of references to express route circuit peerings. + * + * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.id] + * Resource ID. + * + * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.location] + * Resource location. + * + * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter.tags] + * Resource tags. + * + * @param {string} [peeringParameters.ipv6PeeringConfig.state] The state of + * peering. Possible values are: 'Disabled' and 'Enabled'. Possible values + * include: 'Disabled', 'Enabled' + * + * @param {string} [peeringParameters.name] Gets name of the resource that is + * unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [peeringParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -8883,70 +8692,121 @@ export interface LoadBalancers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, peeringParameters: models.ExpressRouteCrossConnectionPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the load balancers in a subscription. + * Creates or updates a peering in the specified ExpressRouteCrossConnection. * - * @param {object} [options] Optional Parameters. + * @param {string} resourceGroupName The name of the resource group. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {string} peeringName The name of the peering. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {object} peeringParameters Parameters supplied to the create or + * update ExpressRouteCrossConnection peering operation. * - * {Promise} A promise is returned. + * @param {string} [peeringParameters.peeringType] The peering type. Possible + * values include: 'AzurePublicPeering', 'AzurePrivatePeering', + * 'MicrosoftPeering' * - * @resolve {LoadBalancerListResult} - The deserialized result object. + * @param {string} [peeringParameters.state] The peering state. Possible values + * include: 'Disabled', 'Enabled' * - * @reject {Error|ServiceError} - The error object. + * @param {number} [peeringParameters.peerASN] The peer ASN. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {string} [peeringParameters.primaryPeerAddressPrefix] The primary + * address prefix. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {string} [peeringParameters.secondaryPeerAddressPrefix] The secondary + * address prefix. * - * {LoadBalancerListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LoadBalancerListResult} for more - * information. + * @param {string} [peeringParameters.sharedKey] The shared key. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {number} [peeringParameters.vlanId] The VLAN ID. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAll(callback: ServiceCallback): void; - listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets all the load balancers in a resource group. + * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft + * peering configuration. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager + * Etag. * - * @param {object} [options] Optional Parameters. + * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider + * or the customer last modified the peering. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {object} [peeringParameters.ipv6PeeringConfig] The IPv6 peering + * configuration. * - * @returns {Promise} A promise is returned + * @param {string} + * [peeringParameters.ipv6PeeringConfig.primaryPeerAddressPrefix] The primary + * address prefix. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.secondaryPeerAddressPrefix] The + * secondary address prefix. * - * @reject {Error|ServiceError} - The error object. - */ - listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets all the load balancers in a resource group. + * @param {object} [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig] + * The Microsoft peering configuration. * - * @param {string} resourceGroupName The name of the resource group. + * @param {array} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixes] + * The reference of AdvertisedPublicPrefixes. + * + * @param {array} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedCommunities] + * The communities of bgp peering. Spepcified for microsoft peering + * + * @param {string} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixesState] + * AdvertisedPublicPrefixState of the Peering resource. Possible values are + * 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. + * Possible values include: 'NotConfigured', 'Configuring', 'Configured', + * 'ValidationNeeded' + * + * @param {number} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.legacyMode] The + * legacy mode of the peering. + * + * @param {number} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.customerASN] The + * CustomerASN of the peering. + * + * @param {string} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.routingRegistryName] + * The RoutingRegistryName of the configuration. + * + * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter] The + * reference of the RouteFilter resource. + * + * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.rules] + * Collection of RouteFilterRules contained within a route filter. + * + * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.peerings] A + * collection of references to express route circuit peerings. + * + * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.id] + * Resource ID. + * + * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.location] + * Resource location. + * + * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter.tags] + * Resource tags. + * + * @param {string} [peeringParameters.ipv6PeeringConfig.state] The state of + * peering. Possible values are: 'Disabled' and 'Enabled'. Possible values + * include: 'Disabled', 'Enabled' + * + * @param {string} [peeringParameters.name] Gets name of the resource that is + * unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [peeringParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -8960,7 +8820,7 @@ export interface LoadBalancers { * * {Promise} A promise is returned. * - * @resolve {LoadBalancerListResult} - The deserialized result object. + * @resolve {ExpressRouteCrossConnectionPeering} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -8968,25 +8828,28 @@ export interface LoadBalancers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LoadBalancerListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LoadBalancerListResult} for more + * {ExpressRouteCrossConnectionPeering} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCrossConnectionPeering} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, crossConnectionName: string, peeringName: string, peeringParameters: models.ExpressRouteCrossConnectionPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, crossConnectionName: string, peeringName: string, peeringParameters: models.ExpressRouteCrossConnectionPeering, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, crossConnectionName: string, peeringName: string, peeringParameters: models.ExpressRouteCrossConnectionPeering, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified load balancer. + * Deletes the specified peering from the ExpressRouteCrossConnection. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} loadBalancerName The name of the load balancer. + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. + * + * @param {string} peeringName The name of the peering. * * @param {object} [options] Optional Parameters. * @@ -8999,14 +8862,17 @@ export interface LoadBalancers { * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified load balancer. + * Deletes the specified peering from the ExpressRouteCrossConnection. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} loadBalancerName The name of the load balancer. + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. + * + * @param {string} peeringName The name of the peering. * * @param {object} [options] Optional Parameters. * @@ -9034,72 +8900,120 @@ export interface LoadBalancers { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, loadBalancerName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, crossConnectionName: string, peeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, crossConnectionName: string, peeringName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, crossConnectionName: string, peeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a load balancer. + * Creates or updates a peering in the specified ExpressRouteCrossConnection. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} loadBalancerName The name of the load balancer. + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. * - * @param {object} parameters Parameters supplied to the create or update load - * balancer operation. + * @param {string} peeringName The name of the peering. * - * @param {object} [parameters.sku] The load balancer SKU. + * @param {object} peeringParameters Parameters supplied to the create or + * update ExpressRouteCrossConnection peering operation. * - * @param {string} [parameters.sku.name] Name of a load balancer SKU. Possible - * values include: 'Basic', 'Standard' + * @param {string} [peeringParameters.peeringType] The peering type. Possible + * values include: 'AzurePublicPeering', 'AzurePrivatePeering', + * 'MicrosoftPeering' * - * @param {array} [parameters.frontendIPConfigurations] Object representing the - * frontend IPs to be used for the load balancer + * @param {string} [peeringParameters.state] The peering state. Possible values + * include: 'Disabled', 'Enabled' * - * @param {array} [parameters.backendAddressPools] Collection of backend - * address pools used by a load balancer + * @param {number} [peeringParameters.peerASN] The peer ASN. * - * @param {array} [parameters.loadBalancingRules] Object collection - * representing the load balancing rules Gets the provisioning + * @param {string} [peeringParameters.primaryPeerAddressPrefix] The primary + * address prefix. * - * @param {array} [parameters.probes] Collection of probe objects used in the - * load balancer + * @param {string} [peeringParameters.secondaryPeerAddressPrefix] The secondary + * address prefix. * - * @param {array} [parameters.inboundNatRules] Collection of inbound NAT Rules - * used by a load balancer. Defining inbound NAT rules on your load balancer is - * mutually exclusive with defining an inbound NAT pool. Inbound NAT pools are - * referenced from virtual machine scale sets. NICs that are associated with - * individual virtual machines cannot reference an Inbound NAT pool. They have - * to reference individual inbound NAT rules. + * @param {string} [peeringParameters.sharedKey] The shared key. * - * @param {array} [parameters.inboundNatPools] Defines an external port range - * for inbound NAT to a single backend port on NICs associated with a load - * balancer. Inbound NAT rules are created automatically for each NIC - * associated with the Load Balancer using an external port from this range. - * Defining an Inbound NAT pool on your Load Balancer is mutually exclusive - * with defining inbound Nat rules. Inbound NAT pools are referenced from - * virtual machine scale sets. NICs that are associated with individual virtual - * machines cannot reference an inbound NAT pool. They have to reference - * individual inbound NAT rules. + * @param {number} [peeringParameters.vlanId] The VLAN ID. * - * @param {array} [parameters.outboundNatRules] The outbound NAT rules. + * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft + * peering configuration. * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * load balancer resource. + * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager + * Etag. * - * @param {string} [parameters.provisioningState] Gets the provisioning state - * of the PublicIP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. + * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider + * or the customer last modified the peering. * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. + * @param {object} [peeringParameters.ipv6PeeringConfig] The IPv6 peering + * configuration. * - * @param {string} [parameters.id] Resource ID. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.primaryPeerAddressPrefix] The primary + * address prefix. * - * @param {string} [parameters.location] Resource location. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.secondaryPeerAddressPrefix] The + * secondary address prefix. * - * @param {object} [parameters.tags] Resource tags. + * @param {object} [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig] + * The Microsoft peering configuration. + * + * @param {array} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixes] + * The reference of AdvertisedPublicPrefixes. + * + * @param {array} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedCommunities] + * The communities of bgp peering. Spepcified for microsoft peering + * + * @param {string} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixesState] + * AdvertisedPublicPrefixState of the Peering resource. Possible values are + * 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. + * Possible values include: 'NotConfigured', 'Configuring', 'Configured', + * 'ValidationNeeded' + * + * @param {number} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.legacyMode] The + * legacy mode of the peering. + * + * @param {number} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.customerASN] The + * CustomerASN of the peering. + * + * @param {string} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.routingRegistryName] + * The RoutingRegistryName of the configuration. + * + * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter] The + * reference of the RouteFilter resource. + * + * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.rules] + * Collection of RouteFilterRules contained within a route filter. + * + * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.peerings] A + * collection of references to express route circuit peerings. + * + * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.id] + * Resource ID. + * + * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.location] + * Resource location. + * + * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter.tags] + * Resource tags. + * + * @param {string} [peeringParameters.ipv6PeeringConfig.state] The state of + * peering. Possible values are: 'Disabled' and 'Enabled'. Possible values + * include: 'Disabled', 'Enabled' + * + * @param {string} [peeringParameters.name] Gets name of the resource that is + * unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [peeringParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -9108,73 +9022,121 @@ export interface LoadBalancers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, parameters: models.LoadBalancer, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, crossConnectionName: string, peeringName: string, peeringParameters: models.ExpressRouteCrossConnectionPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a load balancer. + * Creates or updates a peering in the specified ExpressRouteCrossConnection. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} loadBalancerName The name of the load balancer. + * @param {string} crossConnectionName The name of the + * ExpressRouteCrossConnection. * - * @param {object} parameters Parameters supplied to the create or update load - * balancer operation. + * @param {string} peeringName The name of the peering. * - * @param {object} [parameters.sku] The load balancer SKU. + * @param {object} peeringParameters Parameters supplied to the create or + * update ExpressRouteCrossConnection peering operation. * - * @param {string} [parameters.sku.name] Name of a load balancer SKU. Possible - * values include: 'Basic', 'Standard' + * @param {string} [peeringParameters.peeringType] The peering type. Possible + * values include: 'AzurePublicPeering', 'AzurePrivatePeering', + * 'MicrosoftPeering' * - * @param {array} [parameters.frontendIPConfigurations] Object representing the - * frontend IPs to be used for the load balancer + * @param {string} [peeringParameters.state] The peering state. Possible values + * include: 'Disabled', 'Enabled' * - * @param {array} [parameters.backendAddressPools] Collection of backend - * address pools used by a load balancer + * @param {number} [peeringParameters.peerASN] The peer ASN. * - * @param {array} [parameters.loadBalancingRules] Object collection - * representing the load balancing rules Gets the provisioning + * @param {string} [peeringParameters.primaryPeerAddressPrefix] The primary + * address prefix. * - * @param {array} [parameters.probes] Collection of probe objects used in the - * load balancer + * @param {string} [peeringParameters.secondaryPeerAddressPrefix] The secondary + * address prefix. * - * @param {array} [parameters.inboundNatRules] Collection of inbound NAT Rules - * used by a load balancer. Defining inbound NAT rules on your load balancer is - * mutually exclusive with defining an inbound NAT pool. Inbound NAT pools are - * referenced from virtual machine scale sets. NICs that are associated with - * individual virtual machines cannot reference an Inbound NAT pool. They have - * to reference individual inbound NAT rules. + * @param {string} [peeringParameters.sharedKey] The shared key. * - * @param {array} [parameters.inboundNatPools] Defines an external port range - * for inbound NAT to a single backend port on NICs associated with a load - * balancer. Inbound NAT rules are created automatically for each NIC - * associated with the Load Balancer using an external port from this range. - * Defining an Inbound NAT pool on your Load Balancer is mutually exclusive - * with defining inbound Nat rules. Inbound NAT pools are referenced from - * virtual machine scale sets. NICs that are associated with individual virtual - * machines cannot reference an inbound NAT pool. They have to reference - * individual inbound NAT rules. + * @param {number} [peeringParameters.vlanId] The VLAN ID. * - * @param {array} [parameters.outboundNatRules] The outbound NAT rules. + * @param {object} [peeringParameters.microsoftPeeringConfig] The Microsoft + * peering configuration. * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * load balancer resource. + * @param {string} [peeringParameters.gatewayManagerEtag] The GatewayManager + * Etag. * - * @param {string} [parameters.provisioningState] Gets the provisioning state - * of the PublicIP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. + * @param {string} [peeringParameters.lastModifiedBy] Gets whether the provider + * or the customer last modified the peering. * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. + * @param {object} [peeringParameters.ipv6PeeringConfig] The IPv6 peering + * configuration. * - * @param {string} [parameters.id] Resource ID. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.primaryPeerAddressPrefix] The primary + * address prefix. * - * @param {string} [parameters.location] Resource location. + * @param {string} + * [peeringParameters.ipv6PeeringConfig.secondaryPeerAddressPrefix] The + * secondary address prefix. * - * @param {object} [parameters.tags] Resource tags. + * @param {object} [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig] + * The Microsoft peering configuration. + * + * @param {array} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixes] + * The reference of AdvertisedPublicPrefixes. + * + * @param {array} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedCommunities] + * The communities of bgp peering. Spepcified for microsoft peering + * + * @param {string} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.advertisedPublicPrefixesState] + * AdvertisedPublicPrefixState of the Peering resource. Possible values are + * 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. + * Possible values include: 'NotConfigured', 'Configuring', 'Configured', + * 'ValidationNeeded' + * + * @param {number} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.legacyMode] The + * legacy mode of the peering. + * + * @param {number} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.customerASN] The + * CustomerASN of the peering. + * + * @param {string} + * [peeringParameters.ipv6PeeringConfig.microsoftPeeringConfig.routingRegistryName] + * The RoutingRegistryName of the configuration. + * + * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter] The + * reference of the RouteFilter resource. + * + * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.rules] + * Collection of RouteFilterRules contained within a route filter. + * + * @param {array} [peeringParameters.ipv6PeeringConfig.routeFilter.peerings] A + * collection of references to express route circuit peerings. + * + * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.id] + * Resource ID. + * + * @param {string} [peeringParameters.ipv6PeeringConfig.routeFilter.location] + * Resource location. + * + * @param {object} [peeringParameters.ipv6PeeringConfig.routeFilter.tags] + * Resource tags. + * + * @param {string} [peeringParameters.ipv6PeeringConfig.state] The state of + * peering. Possible values are: 'Disabled' and 'Enabled'. Possible values + * include: 'Disabled', 'Enabled' + * + * @param {string} [peeringParameters.name] Gets name of the resource that is + * unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [peeringParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -9188,7 +9150,7 @@ export interface LoadBalancers { * * {Promise} A promise is returned. * - * @resolve {LoadBalancer} - The deserialized result object. + * @resolve {ExpressRouteCrossConnectionPeering} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -9196,52 +9158,43 @@ export interface LoadBalancers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LoadBalancer} [result] - The deserialized result object if an error did not occur. - * See {@link LoadBalancer} for more information. + * {ExpressRouteCrossConnectionPeering} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCrossConnectionPeering} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, loadBalancerName: string, parameters: models.LoadBalancer, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, loadBalancerName: string, parameters: models.LoadBalancer, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, loadBalancerName: string, parameters: models.LoadBalancer, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, crossConnectionName: string, peeringName: string, peeringParameters: models.ExpressRouteCrossConnectionPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, crossConnectionName: string, peeringName: string, peeringParameters: models.ExpressRouteCrossConnectionPeering, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, crossConnectionName: string, peeringName: string, peeringParameters: models.ExpressRouteCrossConnectionPeering, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a load balancer tags. + * Gets all peerings in a specified ExpressRouteCrossConnection. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {string} loadBalancerName The name of the load balancer. - * - * @param {object} parameters Parameters supplied to update load balancer tags. - * - * @param {object} [parameters.tags] Resource tags. - * - * @param {object} [options] Optional Parameters. + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a load balancer tags. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} loadBalancerName The name of the load balancer. - * - * @param {object} parameters Parameters supplied to update load balancer tags. + * Gets all peerings in a specified ExpressRouteCrossConnection. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -9255,7 +9208,7 @@ export interface LoadBalancers { * * {Promise} A promise is returned. * - * @resolve {LoadBalancer} - The deserialized result object. + * @resolve {ExpressRouteCrossConnectionPeeringList} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -9263,23 +9216,34 @@ export interface LoadBalancers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LoadBalancer} [result] - The deserialized result object if an error did not occur. - * See {@link LoadBalancer} for more information. + * {ExpressRouteCrossConnectionPeeringList} [result] - The deserialized result object if an error did not occur. + * See {@link ExpressRouteCrossConnectionPeeringList} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdateTags(resourceGroupName: string, loadBalancerName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdateTags(resourceGroupName: string, loadBalancerName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - beginUpdateTags(resourceGroupName: string, loadBalancerName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * LoadBalancers + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface LoadBalancers { /** - * Gets all the load balancers in a subscription. + * Deletes the specified load balancer. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} loadBalancerName The name of the load balancer. * * @param {object} [options] Optional Parameters. * @@ -9288,17 +9252,18 @@ export interface LoadBalancers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the load balancers in a subscription. + * Deletes the specified load balancer. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} loadBalancerName The name of the load balancer. * * @param {object} [options] Optional Parameters. * @@ -9312,7 +9277,7 @@ export interface LoadBalancers { * * {Promise} A promise is returned. * - * @resolve {LoadBalancerListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -9320,46 +9285,50 @@ export interface LoadBalancers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LoadBalancerListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LoadBalancerListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAllNext(nextPageLink: string, callback: ServiceCallback): void; - listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, loadBalancerName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the load balancers in a resource group. + * Gets the specified load balancer. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} loadBalancerName The name of the load balancer. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands referenced resources. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the load balancers in a resource group. + * Gets the specified load balancer. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} loadBalancerName The name of the load balancer. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands referenced resources. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -9370,7 +9339,7 @@ export interface LoadBalancers { * * {Promise} A promise is returned. * - * @resolve {LoadBalancerListResult} - The deserialized result object. + * @resolve {LoadBalancer} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -9378,35 +9347,80 @@ export interface LoadBalancers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LoadBalancerListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LoadBalancerListResult} for more - * information. + * {LoadBalancer} [result] - The deserialized result object if an error did not occur. + * See {@link LoadBalancer} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * LoadBalancerBackendAddressPools - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface LoadBalancerBackendAddressPools { + get(resourceGroupName: string, loadBalancerName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, loadBalancerName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the load balancer backed address pools. + * Creates or updates a load balancer. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} loadBalancerName The name of the load balancer. * + * @param {object} parameters Parameters supplied to the create or update load + * balancer operation. + * + * @param {object} [parameters.sku] The load balancer SKU. + * + * @param {string} [parameters.sku.name] Name of a load balancer SKU. Possible + * values include: 'Basic', 'Standard' + * + * @param {array} [parameters.frontendIPConfigurations] Object representing the + * frontend IPs to be used for the load balancer + * + * @param {array} [parameters.backendAddressPools] Collection of backend + * address pools used by a load balancer + * + * @param {array} [parameters.loadBalancingRules] Object collection + * representing the load balancing rules Gets the provisioning + * + * @param {array} [parameters.probes] Collection of probe objects used in the + * load balancer + * + * @param {array} [parameters.inboundNatRules] Collection of inbound NAT Rules + * used by a load balancer. Defining inbound NAT rules on your load balancer is + * mutually exclusive with defining an inbound NAT pool. Inbound NAT pools are + * referenced from virtual machine scale sets. NICs that are associated with + * individual virtual machines cannot reference an Inbound NAT pool. They have + * to reference individual inbound NAT rules. + * + * @param {array} [parameters.inboundNatPools] Defines an external port range + * for inbound NAT to a single backend port on NICs associated with a load + * balancer. Inbound NAT rules are created automatically for each NIC + * associated with the Load Balancer using an external port from this range. + * Defining an Inbound NAT pool on your Load Balancer is mutually exclusive + * with defining inbound Nat rules. Inbound NAT pools are referenced from + * virtual machine scale sets. NICs that are associated with individual virtual + * machines cannot reference an inbound NAT pool. They have to reference + * individual inbound NAT rules. + * + * @param {array} [parameters.outboundNatRules] The outbound NAT rules. + * + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * load balancer resource. + * + * @param {string} [parameters.provisioningState] Gets the provisioning state + * of the PublicIP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. + * + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -9414,19 +9428,74 @@ export interface LoadBalancerBackendAddressPools { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, parameters: models.LoadBalancer, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the load balancer backed address pools. + * Creates or updates a load balancer. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} loadBalancerName The name of the load balancer. * + * @param {object} parameters Parameters supplied to the create or update load + * balancer operation. + * + * @param {object} [parameters.sku] The load balancer SKU. + * + * @param {string} [parameters.sku.name] Name of a load balancer SKU. Possible + * values include: 'Basic', 'Standard' + * + * @param {array} [parameters.frontendIPConfigurations] Object representing the + * frontend IPs to be used for the load balancer + * + * @param {array} [parameters.backendAddressPools] Collection of backend + * address pools used by a load balancer + * + * @param {array} [parameters.loadBalancingRules] Object collection + * representing the load balancing rules Gets the provisioning + * + * @param {array} [parameters.probes] Collection of probe objects used in the + * load balancer + * + * @param {array} [parameters.inboundNatRules] Collection of inbound NAT Rules + * used by a load balancer. Defining inbound NAT rules on your load balancer is + * mutually exclusive with defining an inbound NAT pool. Inbound NAT pools are + * referenced from virtual machine scale sets. NICs that are associated with + * individual virtual machines cannot reference an Inbound NAT pool. They have + * to reference individual inbound NAT rules. + * + * @param {array} [parameters.inboundNatPools] Defines an external port range + * for inbound NAT to a single backend port on NICs associated with a load + * balancer. Inbound NAT rules are created automatically for each NIC + * associated with the Load Balancer using an external port from this range. + * Defining an Inbound NAT pool on your Load Balancer is mutually exclusive + * with defining inbound Nat rules. Inbound NAT pools are referenced from + * virtual machine scale sets. NICs that are associated with individual virtual + * machines cannot reference an inbound NAT pool. They have to reference + * individual inbound NAT rules. + * + * @param {array} [parameters.outboundNatRules] The outbound NAT rules. + * + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * load balancer resource. + * + * @param {string} [parameters.provisioningState] Gets the provisioning state + * of the PublicIP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. + * + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -9439,7 +9508,7 @@ export interface LoadBalancerBackendAddressPools { * * {Promise} A promise is returned. * - * @resolve {LoadBalancerBackendAddressPoolListResult} - The deserialized result object. + * @resolve {LoadBalancer} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -9447,27 +9516,28 @@ export interface LoadBalancerBackendAddressPools { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LoadBalancerBackendAddressPoolListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LoadBalancerBackendAddressPoolListResult} - * for more information. + * {LoadBalancer} [result] - The deserialized result object if an error did not occur. + * See {@link LoadBalancer} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, loadBalancerName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, loadBalancerName: string, parameters: models.LoadBalancer, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, loadBalancerName: string, parameters: models.LoadBalancer, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, loadBalancerName: string, parameters: models.LoadBalancer, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets load balancer backend address pool. + * Updates a load balancer tags. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} loadBalancerName The name of the load balancer. * - * @param {string} backendAddressPoolName The name of the backend address pool. + * @param {object} parameters Parameters supplied to update load balancer tags. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -9476,20 +9546,22 @@ export interface LoadBalancerBackendAddressPools { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, backendAddressPoolName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateTagsWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets load balancer backend address pool. + * Updates a load balancer tags. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} loadBalancerName The name of the load balancer. * - * @param {string} backendAddressPoolName The name of the backend address pool. + * @param {object} parameters Parameters supplied to update load balancer tags. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -9503,7 +9575,7 @@ export interface LoadBalancerBackendAddressPools { * * {Promise} A promise is returned. * - * @resolve {BackendAddressPool} - The deserialized result object. + * @resolve {LoadBalancer} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -9511,23 +9583,20 @@ export interface LoadBalancerBackendAddressPools { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {BackendAddressPool} [result] - The deserialized result object if an error did not occur. - * See {@link BackendAddressPool} for more information. + * {LoadBalancer} [result] - The deserialized result object if an error did not occur. + * See {@link LoadBalancer} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, loadBalancerName: string, backendAddressPoolName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, loadBalancerName: string, backendAddressPoolName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, loadBalancerName: string, backendAddressPoolName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, loadBalancerName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, loadBalancerName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, loadBalancerName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the load balancer backed address pools. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * Gets all the load balancers in a subscription. * * @param {object} [options] Optional Parameters. * @@ -9536,17 +9605,14 @@ export interface LoadBalancerBackendAddressPools { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the load balancer backed address pools. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * Gets all the load balancers in a subscription. * * @param {object} [options] Optional Parameters. * @@ -9560,7 +9626,7 @@ export interface LoadBalancerBackendAddressPools { * * {Promise} A promise is returned. * - * @resolve {LoadBalancerBackendAddressPoolListResult} - The deserialized result object. + * @resolve {LoadBalancerListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -9568,35 +9634,24 @@ export interface LoadBalancerBackendAddressPools { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LoadBalancerBackendAddressPoolListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LoadBalancerBackendAddressPoolListResult} - * for more information. + * {LoadBalancerListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LoadBalancerListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * LoadBalancerFrontendIPConfigurations - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface LoadBalancerFrontendIPConfigurations { + listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAll(callback: ServiceCallback): void; + listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the load balancer frontend IP configurations. + * Gets all the load balancers in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} loadBalancerName The name of the load balancer. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -9604,19 +9659,17 @@ export interface LoadBalancerFrontendIPConfigurations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the load balancer frontend IP configurations. + * Gets all the load balancers in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} loadBalancerName The name of the load balancer. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -9629,7 +9682,7 @@ export interface LoadBalancerFrontendIPConfigurations { * * {Promise} A promise is returned. * - * @resolve {LoadBalancerFrontendIPConfigurationListResult} - The deserialized result object. + * @resolve {LoadBalancerListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -9637,30 +9690,26 @@ export interface LoadBalancerFrontendIPConfigurations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LoadBalancerFrontendIPConfigurationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link - * LoadBalancerFrontendIPConfigurationListResult} for more + * {LoadBalancerListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LoadBalancerListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, loadBalancerName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets load balancer frontend IP configuration. + * Deletes the specified load balancer. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} loadBalancerName The name of the load balancer. * - * @param {string} frontendIPConfigurationName The name of the frontend IP - * configuration. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -9668,22 +9717,19 @@ export interface LoadBalancerFrontendIPConfigurations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, frontendIPConfigurationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets load balancer frontend IP configuration. + * Deletes the specified load balancer. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} loadBalancerName The name of the load balancer. * - * @param {string} frontendIPConfigurationName The name of the frontend IP - * configuration. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -9696,7 +9742,7 @@ export interface LoadBalancerFrontendIPConfigurations { * * {Promise} A promise is returned. * - * @resolve {FrontendIPConfiguration} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -9704,93 +9750,78 @@ export interface LoadBalancerFrontendIPConfigurations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {FrontendIPConfiguration} [result] - The deserialized result object if an error did not occur. - * See {@link FrontendIPConfiguration} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, loadBalancerName: string, frontendIPConfigurationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, loadBalancerName: string, frontendIPConfigurationName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, loadBalancerName: string, frontendIPConfigurationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, loadBalancerName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the load balancer frontend IP configurations. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * Creates or updates a load balancer. * - * @returns {Promise} A promise is returned + * @param {string} resourceGroupName The name of the resource group. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} loadBalancerName The name of the load balancer. * - * @reject {Error|ServiceError} - The error object. - */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets all the load balancer frontend IP configurations. + * @param {object} parameters Parameters supplied to the create or update load + * balancer operation. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {object} [parameters.sku] The load balancer SKU. * - * @param {object} [options] Optional Parameters. + * @param {string} [parameters.sku.name] Name of a load balancer SKU. Possible + * values include: 'Basic', 'Standard' * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {array} [parameters.frontendIPConfigurations] Object representing the + * frontend IPs to be used for the load balancer * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {array} [parameters.backendAddressPools] Collection of backend + * address pools used by a load balancer * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {array} [parameters.loadBalancingRules] Object collection + * representing the load balancing rules Gets the provisioning * - * {Promise} A promise is returned. + * @param {array} [parameters.probes] Collection of probe objects used in the + * load balancer * - * @resolve {LoadBalancerFrontendIPConfigurationListResult} - The deserialized result object. + * @param {array} [parameters.inboundNatRules] Collection of inbound NAT Rules + * used by a load balancer. Defining inbound NAT rules on your load balancer is + * mutually exclusive with defining an inbound NAT pool. Inbound NAT pools are + * referenced from virtual machine scale sets. NICs that are associated with + * individual virtual machines cannot reference an Inbound NAT pool. They have + * to reference individual inbound NAT rules. * - * @reject {Error|ServiceError} - The error object. + * @param {array} [parameters.inboundNatPools] Defines an external port range + * for inbound NAT to a single backend port on NICs associated with a load + * balancer. Inbound NAT rules are created automatically for each NIC + * associated with the Load Balancer using an external port from this range. + * Defining an Inbound NAT pool on your Load Balancer is mutually exclusive + * with defining inbound Nat rules. Inbound NAT pools are referenced from + * virtual machine scale sets. NICs that are associated with individual virtual + * machines cannot reference an inbound NAT pool. They have to reference + * individual inbound NAT rules. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {array} [parameters.outboundNatRules] The outbound NAT rules. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * load balancer resource. * - * {LoadBalancerFrontendIPConfigurationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link - * LoadBalancerFrontendIPConfigurationListResult} for more - * information. + * @param {string} [parameters.provisioningState] Gets the provisioning state + * of the PublicIP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * InboundNatRules - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface InboundNatRules { - - - /** - * Gets all the inbound nat rules in a load balancer. + * @param {string} [parameters.id] Resource ID. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [parameters.location] Resource location. * - * @param {string} loadBalancerName The name of the load balancer. + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -9799,82 +9830,73 @@ export interface InboundNatRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, parameters: models.LoadBalancer, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the inbound nat rules in a load balancer. + * Creates or updates a load balancer. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} loadBalancerName The name of the load balancer. * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {object} parameters Parameters supplied to the create or update load + * balancer operation. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {object} [parameters.sku] The load balancer SKU. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {string} [parameters.sku.name] Name of a load balancer SKU. Possible + * values include: 'Basic', 'Standard' * - * {Promise} A promise is returned. + * @param {array} [parameters.frontendIPConfigurations] Object representing the + * frontend IPs to be used for the load balancer * - * @resolve {InboundNatRuleListResult} - The deserialized result object. + * @param {array} [parameters.backendAddressPools] Collection of backend + * address pools used by a load balancer * - * @reject {Error|ServiceError} - The error object. + * @param {array} [parameters.loadBalancingRules] Object collection + * representing the load balancing rules Gets the provisioning * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {array} [parameters.probes] Collection of probe objects used in the + * load balancer * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {array} [parameters.inboundNatRules] Collection of inbound NAT Rules + * used by a load balancer. Defining inbound NAT rules on your load balancer is + * mutually exclusive with defining an inbound NAT pool. Inbound NAT pools are + * referenced from virtual machine scale sets. NICs that are associated with + * individual virtual machines cannot reference an Inbound NAT pool. They have + * to reference individual inbound NAT rules. * - * {InboundNatRuleListResult} [result] - The deserialized result object if an error did not occur. - * See {@link InboundNatRuleListResult} for more - * information. + * @param {array} [parameters.inboundNatPools] Defines an external port range + * for inbound NAT to a single backend port on NICs associated with a load + * balancer. Inbound NAT rules are created automatically for each NIC + * associated with the Load Balancer using an external port from this range. + * Defining an Inbound NAT pool on your Load Balancer is mutually exclusive + * with defining inbound Nat rules. Inbound NAT pools are referenced from + * virtual machine scale sets. NICs that are associated with individual virtual + * machines cannot reference an inbound NAT pool. They have to reference + * individual inbound NAT rules. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {array} [parameters.outboundNatRules] The outbound NAT rules. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - list(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, loadBalancerName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Deletes the specified load balancer inbound nat rule. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} loadBalancerName The name of the load balancer. - * - * @param {string} inboundNatRuleName The name of the inbound nat rule. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * load balancer resource. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} [parameters.provisioningState] Gets the provisioning state + * of the PublicIP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. * - * @reject {Error|ServiceError} - The error object. - */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Deletes the specified load balancer inbound nat rule. + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [parameters.id] Resource ID. * - * @param {string} loadBalancerName The name of the load balancer. + * @param {string} [parameters.location] Resource location. * - * @param {string} inboundNatRuleName The name of the inbound nat rule. + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -9888,7 +9910,7 @@ export interface InboundNatRules { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {LoadBalancer} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -9896,53 +9918,54 @@ export interface InboundNatRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {LoadBalancer} [result] - The deserialized result object if an error did not occur. + * See {@link LoadBalancer} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, loadBalancerName: string, parameters: models.LoadBalancer, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, loadBalancerName: string, parameters: models.LoadBalancer, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, loadBalancerName: string, parameters: models.LoadBalancer, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified load balancer inbound nat rule. + * Updates a load balancer tags. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} loadBalancerName The name of the load balancer. * - * @param {string} inboundNatRuleName The name of the inbound nat rule. + * @param {object} parameters Parameters supplied to update load balancer tags. * - * @param {object} [options] Optional Parameters. + * @param {object} [parameters.tags] Resource tags. * - * @param {string} [options.expand] Expands referenced resources. + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified load balancer inbound nat rule. + * Updates a load balancer tags. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} loadBalancerName The name of the load balancer. * - * @param {string} inboundNatRuleName The name of the inbound nat rule. + * @param {object} parameters Parameters supplied to update load balancer tags. * - * @param {object} [options] Optional Parameters. + * @param {object} [parameters.tags] Resource tags. * - * @param {string} [options.expand] Expands referenced resources. + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request @@ -9954,7 +9977,7 @@ export interface InboundNatRules { * * {Promise} A promise is returned. * - * @resolve {InboundNatRule} - The deserialized result object. + * @resolve {LoadBalancer} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -9962,69 +9985,23 @@ export interface InboundNatRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {InboundNatRule} [result] - The deserialized result object if an error did not occur. - * See {@link InboundNatRule} for more information. + * {LoadBalancer} [result] - The deserialized result object if an error did not occur. + * See {@link LoadBalancer} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, loadBalancerName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdateTags(resourceGroupName: string, loadBalancerName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, loadBalancerName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a load balancer inbound nat rule. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} loadBalancerName The name of the load balancer. - * - * @param {string} inboundNatRuleName The name of the inbound nat rule. - * - * @param {object} inboundNatRuleParameters Parameters supplied to the create - * or update inbound nat rule operation. - * - * @param {object} [inboundNatRuleParameters.frontendIPConfiguration] A - * reference to frontend IP addresses. - * - * @param {string} [inboundNatRuleParameters.frontendIPConfiguration.id] - * Resource ID. - * - * @param {string} [inboundNatRuleParameters.protocol] Possible values include: - * 'Udp', 'Tcp', 'All' - * - * @param {number} [inboundNatRuleParameters.frontendPort] The port for the - * external endpoint. Port numbers for each rule must be unique within the Load - * Balancer. Acceptable values range from 1 to 65534. - * - * @param {number} [inboundNatRuleParameters.backendPort] The port used for the - * internal endpoint. Acceptable values range from 1 to 65535. - * - * @param {number} [inboundNatRuleParameters.idleTimeoutInMinutes] The timeout - * for the TCP idle connection. The value can be set between 4 and 30 minutes. - * The default value is 4 minutes. This element is only used when the protocol - * is set to TCP. - * - * @param {boolean} [inboundNatRuleParameters.enableFloatingIP] Configures a - * virtual machine's endpoint for the floating IP capability required to - * configure a SQL AlwaysOn Availability Group. This setting is required when - * using the SQL AlwaysOn Availability Groups in SQL server. This setting can't - * be changed after you create the endpoint. - * - * @param {string} [inboundNatRuleParameters.provisioningState] Gets the - * provisioning state of the public IP resource. Possible values are: - * 'Updating', 'Deleting', and 'Failed'. - * - * @param {string} [inboundNatRuleParameters.name] Gets name of the resource - * that is unique within a resource group. This name can be used to access the - * resource. - * - * @param {string} [inboundNatRuleParameters.etag] A unique read-only string - * that changes whenever the resource is updated. + * Gets all the load balancers in a subscription. * - * @param {string} [inboundNatRuleParameters.id] Resource ID. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -10033,63 +10010,17 @@ export interface InboundNatRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, inboundNatRuleParameters: models.InboundNatRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a load balancer inbound nat rule. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} loadBalancerName The name of the load balancer. - * - * @param {string} inboundNatRuleName The name of the inbound nat rule. - * - * @param {object} inboundNatRuleParameters Parameters supplied to the create - * or update inbound nat rule operation. - * - * @param {object} [inboundNatRuleParameters.frontendIPConfiguration] A - * reference to frontend IP addresses. - * - * @param {string} [inboundNatRuleParameters.frontendIPConfiguration.id] - * Resource ID. - * - * @param {string} [inboundNatRuleParameters.protocol] Possible values include: - * 'Udp', 'Tcp', 'All' - * - * @param {number} [inboundNatRuleParameters.frontendPort] The port for the - * external endpoint. Port numbers for each rule must be unique within the Load - * Balancer. Acceptable values range from 1 to 65534. - * - * @param {number} [inboundNatRuleParameters.backendPort] The port used for the - * internal endpoint. Acceptable values range from 1 to 65535. - * - * @param {number} [inboundNatRuleParameters.idleTimeoutInMinutes] The timeout - * for the TCP idle connection. The value can be set between 4 and 30 minutes. - * The default value is 4 minutes. This element is only used when the protocol - * is set to TCP. - * - * @param {boolean} [inboundNatRuleParameters.enableFloatingIP] Configures a - * virtual machine's endpoint for the floating IP capability required to - * configure a SQL AlwaysOn Availability Group. This setting is required when - * using the SQL AlwaysOn Availability Groups in SQL server. This setting can't - * be changed after you create the endpoint. - * - * @param {string} [inboundNatRuleParameters.provisioningState] Gets the - * provisioning state of the public IP resource. Possible values are: - * 'Updating', 'Deleting', and 'Failed'. - * - * @param {string} [inboundNatRuleParameters.name] Gets name of the resource - * that is unique within a resource group. This name can be used to access the - * resource. - * - * @param {string} [inboundNatRuleParameters.etag] A unique read-only string - * that changes whenever the resource is updated. + * Gets all the load balancers in a subscription. * - * @param {string} [inboundNatRuleParameters.id] Resource ID. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -10103,7 +10034,7 @@ export interface InboundNatRules { * * {Promise} A promise is returned. * - * @resolve {InboundNatRule} - The deserialized result object. + * @resolve {LoadBalancerListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10111,26 +10042,24 @@ export interface InboundNatRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {InboundNatRule} [result] - The deserialized result object if an error did not occur. - * See {@link InboundNatRule} for more information. + * {LoadBalancerListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LoadBalancerListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, inboundNatRuleParameters: models.InboundNatRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, inboundNatRuleParameters: models.InboundNatRule, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, inboundNatRuleParameters: models.InboundNatRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAllNext(nextPageLink: string, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified load balancer inbound nat rule. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} loadBalancerName The name of the load balancer. + * Gets all the load balancers in a resource group. * - * @param {string} inboundNatRuleName The name of the inbound nat rule. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -10139,20 +10068,17 @@ export interface InboundNatRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified load balancer inbound nat rule. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} loadBalancerName The name of the load balancer. + * Gets all the load balancers in a resource group. * - * @param {string} inboundNatRuleName The name of the inbound nat rule. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -10166,7 +10092,7 @@ export interface InboundNatRules { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {LoadBalancerListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10174,133 +10100,118 @@ export interface InboundNatRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {LoadBalancerListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LoadBalancerListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * LoadBalancerBackendAddressPools + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface LoadBalancerBackendAddressPools { /** - * Creates or updates a load balancer inbound nat rule. + * Gets all the load balancer backed address pools. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} loadBalancerName The name of the load balancer. * - * @param {string} inboundNatRuleName The name of the inbound nat rule. - * - * @param {object} inboundNatRuleParameters Parameters supplied to the create - * or update inbound nat rule operation. + * @param {object} [options] Optional Parameters. * - * @param {object} [inboundNatRuleParameters.frontendIPConfiguration] A - * reference to frontend IP addresses. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [inboundNatRuleParameters.frontendIPConfiguration.id] - * Resource ID. + * @returns {Promise} A promise is returned * - * @param {string} [inboundNatRuleParameters.protocol] Possible values include: - * 'Udp', 'Tcp', 'All' + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {number} [inboundNatRuleParameters.frontendPort] The port for the - * external endpoint. Port numbers for each rule must be unique within the Load - * Balancer. Acceptable values range from 1 to 65534. + * @reject {Error|ServiceError} - The error object. + */ + listWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all the load balancer backed address pools. * - * @param {number} [inboundNatRuleParameters.backendPort] The port used for the - * internal endpoint. Acceptable values range from 1 to 65535. + * @param {string} resourceGroupName The name of the resource group. * - * @param {number} [inboundNatRuleParameters.idleTimeoutInMinutes] The timeout - * for the TCP idle connection. The value can be set between 4 and 30 minutes. - * The default value is 4 minutes. This element is only used when the protocol - * is set to TCP. + * @param {string} loadBalancerName The name of the load balancer. * - * @param {boolean} [inboundNatRuleParameters.enableFloatingIP] Configures a - * virtual machine's endpoint for the floating IP capability required to - * configure a SQL AlwaysOn Availability Group. This setting is required when - * using the SQL AlwaysOn Availability Groups in SQL server. This setting can't - * be changed after you create the endpoint. + * @param {object} [options] Optional Parameters. * - * @param {string} [inboundNatRuleParameters.provisioningState] Gets the - * provisioning state of the public IP resource. Possible values are: - * 'Updating', 'Deleting', and 'Failed'. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [inboundNatRuleParameters.name] Gets name of the resource - * that is unique within a resource group. This name can be used to access the - * resource. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} [inboundNatRuleParameters.etag] A unique read-only string - * that changes whenever the resource is updated. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {string} [inboundNatRuleParameters.id] Resource ID. + * {Promise} A promise is returned. * - * @param {object} [options] Optional Parameters. + * @resolve {LoadBalancerBackendAddressPoolListResult} - The deserialized result object. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @reject {Error|ServiceError} - The error object. * - * @returns {Promise} A promise is returned + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @resolve {HttpOperationResponse} - The deserialized result object. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @reject {Error|ServiceError} - The error object. + * {LoadBalancerBackendAddressPoolListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LoadBalancerBackendAddressPoolListResult} + * for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, inboundNatRuleParameters: models.InboundNatRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + list(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, loadBalancerName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + /** - * Creates or updates a load balancer inbound nat rule. + * Gets load balancer backend address pool. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} loadBalancerName The name of the load balancer. * - * @param {string} inboundNatRuleName The name of the inbound nat rule. - * - * @param {object} inboundNatRuleParameters Parameters supplied to the create - * or update inbound nat rule operation. - * - * @param {object} [inboundNatRuleParameters.frontendIPConfiguration] A - * reference to frontend IP addresses. - * - * @param {string} [inboundNatRuleParameters.frontendIPConfiguration.id] - * Resource ID. - * - * @param {string} [inboundNatRuleParameters.protocol] Possible values include: - * 'Udp', 'Tcp', 'All' + * @param {string} backendAddressPoolName The name of the backend address pool. * - * @param {number} [inboundNatRuleParameters.frontendPort] The port for the - * external endpoint. Port numbers for each rule must be unique within the Load - * Balancer. Acceptable values range from 1 to 65534. + * @param {object} [options] Optional Parameters. * - * @param {number} [inboundNatRuleParameters.backendPort] The port used for the - * internal endpoint. Acceptable values range from 1 to 65535. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {number} [inboundNatRuleParameters.idleTimeoutInMinutes] The timeout - * for the TCP idle connection. The value can be set between 4 and 30 minutes. - * The default value is 4 minutes. This element is only used when the protocol - * is set to TCP. + * @returns {Promise} A promise is returned * - * @param {boolean} [inboundNatRuleParameters.enableFloatingIP] Configures a - * virtual machine's endpoint for the floating IP capability required to - * configure a SQL AlwaysOn Availability Group. This setting is required when - * using the SQL AlwaysOn Availability Groups in SQL server. This setting can't - * be changed after you create the endpoint. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [inboundNatRuleParameters.provisioningState] Gets the - * provisioning state of the public IP resource. Possible values are: - * 'Updating', 'Deleting', and 'Failed'. + * @reject {Error|ServiceError} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, backendAddressPoolName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets load balancer backend address pool. * - * @param {string} [inboundNatRuleParameters.name] Gets name of the resource - * that is unique within a resource group. This name can be used to access the - * resource. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [inboundNatRuleParameters.etag] A unique read-only string - * that changes whenever the resource is updated. + * @param {string} loadBalancerName The name of the load balancer. * - * @param {string} [inboundNatRuleParameters.id] Resource ID. + * @param {string} backendAddressPoolName The name of the backend address pool. * * @param {object} [options] Optional Parameters. * @@ -10314,7 +10225,7 @@ export interface InboundNatRules { * * {Promise} A promise is returned. * - * @resolve {InboundNatRule} - The deserialized result object. + * @resolve {BackendAddressPool} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10322,20 +10233,20 @@ export interface InboundNatRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {InboundNatRule} [result] - The deserialized result object if an error did not occur. - * See {@link InboundNatRule} for more information. + * {BackendAddressPool} [result] - The deserialized result object if an error did not occur. + * See {@link BackendAddressPool} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, inboundNatRuleParameters: models.InboundNatRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, inboundNatRuleParameters: models.InboundNatRule, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, inboundNatRuleParameters: models.InboundNatRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, loadBalancerName: string, backendAddressPoolName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, loadBalancerName: string, backendAddressPoolName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, loadBalancerName: string, backendAddressPoolName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the inbound nat rules in a load balancer. + * Gets all the load balancer backed address pools. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -10347,14 +10258,14 @@ export interface InboundNatRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the inbound nat rules in a load balancer. + * Gets all the load balancer backed address pools. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -10371,7 +10282,7 @@ export interface InboundNatRules { * * {Promise} A promise is returned. * - * @resolve {InboundNatRuleListResult} - The deserialized result object. + * @resolve {LoadBalancerBackendAddressPoolListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10379,30 +10290,30 @@ export interface InboundNatRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {InboundNatRuleListResult} [result] - The deserialized result object if an error did not occur. - * See {@link InboundNatRuleListResult} for more - * information. + * {LoadBalancerBackendAddressPoolListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LoadBalancerBackendAddressPoolListResult} + * for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } /** * @class - * LoadBalancerLoadBalancingRules + * LoadBalancerFrontendIPConfigurations * __NOTE__: An instance of this class is automatically created for an * instance of the NetworkManagementClient. */ -export interface LoadBalancerLoadBalancingRules { +export interface LoadBalancerFrontendIPConfigurations { /** - * Gets all the load balancing rules in a load balancer. + * Gets all the load balancer frontend IP configurations. * * @param {string} resourceGroupName The name of the resource group. * @@ -10415,14 +10326,14 @@ export interface LoadBalancerLoadBalancingRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the load balancing rules in a load balancer. + * Gets all the load balancer frontend IP configurations. * * @param {string} resourceGroupName The name of the resource group. * @@ -10440,7 +10351,7 @@ export interface LoadBalancerLoadBalancingRules { * * {Promise} A promise is returned. * - * @resolve {LoadBalancerLoadBalancingRuleListResult} - The deserialized result object. + * @resolve {LoadBalancerFrontendIPConfigurationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10448,27 +10359,29 @@ export interface LoadBalancerLoadBalancingRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LoadBalancerLoadBalancingRuleListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LoadBalancerLoadBalancingRuleListResult} for - * more information. + * {LoadBalancerFrontendIPConfigurationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link + * LoadBalancerFrontendIPConfigurationListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, loadBalancerName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, loadBalancerName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified load balancer load balancing rule. + * Gets load balancer frontend IP configuration. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} loadBalancerName The name of the load balancer. * - * @param {string} loadBalancingRuleName The name of the load balancing rule. + * @param {string} frontendIPConfigurationName The name of the frontend IP + * configuration. * * @param {object} [options] Optional Parameters. * @@ -10477,20 +10390,21 @@ export interface LoadBalancerLoadBalancingRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, loadBalancingRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, frontendIPConfigurationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified load balancer load balancing rule. + * Gets load balancer frontend IP configuration. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} loadBalancerName The name of the load balancer. * - * @param {string} loadBalancingRuleName The name of the load balancing rule. + * @param {string} frontendIPConfigurationName The name of the frontend IP + * configuration. * * @param {object} [options] Optional Parameters. * @@ -10504,7 +10418,7 @@ export interface LoadBalancerLoadBalancingRules { * * {Promise} A promise is returned. * - * @resolve {LoadBalancingRule} - The deserialized result object. + * @resolve {FrontendIPConfiguration} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10512,20 +10426,21 @@ export interface LoadBalancerLoadBalancingRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LoadBalancingRule} [result] - The deserialized result object if an error did not occur. - * See {@link LoadBalancingRule} for more information. + * {FrontendIPConfiguration} [result] - The deserialized result object if an error did not occur. + * See {@link FrontendIPConfiguration} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, loadBalancerName: string, loadBalancingRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, loadBalancerName: string, loadBalancingRuleName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, loadBalancerName: string, loadBalancingRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, loadBalancerName: string, frontendIPConfigurationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, loadBalancerName: string, frontendIPConfigurationName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, loadBalancerName: string, frontendIPConfigurationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the load balancing rules in a load balancer. + * Gets all the load balancer frontend IP configurations. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -10537,14 +10452,14 @@ export interface LoadBalancerLoadBalancingRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the load balancing rules in a load balancer. + * Gets all the load balancer frontend IP configurations. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -10561,7 +10476,7 @@ export interface LoadBalancerLoadBalancingRules { * * {Promise} A promise is returned. * - * @resolve {LoadBalancerLoadBalancingRuleListResult} - The deserialized result object. + * @resolve {LoadBalancerFrontendIPConfigurationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10569,30 +10484,31 @@ export interface LoadBalancerLoadBalancingRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LoadBalancerLoadBalancingRuleListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LoadBalancerLoadBalancingRuleListResult} for - * more information. + * {LoadBalancerFrontendIPConfigurationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link + * LoadBalancerFrontendIPConfigurationListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } /** * @class - * LoadBalancerNetworkInterfaces + * InboundNatRules * __NOTE__: An instance of this class is automatically created for an * instance of the NetworkManagementClient. */ -export interface LoadBalancerNetworkInterfaces { +export interface InboundNatRules { /** - * Gets associated load balancer network interfaces. + * Gets all the inbound nat rules in a load balancer. * * @param {string} resourceGroupName The name of the resource group. * @@ -10605,14 +10521,14 @@ export interface LoadBalancerNetworkInterfaces { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets associated load balancer network interfaces. + * Gets all the inbound nat rules in a load balancer. * * @param {string} resourceGroupName The name of the resource group. * @@ -10630,7 +10546,7 @@ export interface LoadBalancerNetworkInterfaces { * * {Promise} A promise is returned. * - * @resolve {NetworkInterfaceListResult} - The deserialized result object. + * @resolve {InboundNatRuleListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10638,24 +10554,27 @@ export interface LoadBalancerNetworkInterfaces { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkInterfaceListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkInterfaceListResult} for more + * {InboundNatRuleListResult} [result] - The deserialized result object if an error did not occur. + * See {@link InboundNatRuleListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, loadBalancerName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - + list(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, loadBalancerName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + /** - * Gets associated load balancer network interfaces. + * Deletes the specified load balancer inbound nat rule. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} loadBalancerName The name of the load balancer. + * + * @param {string} inboundNatRuleName The name of the inbound nat rule. * * @param {object} [options] Optional Parameters. * @@ -10664,17 +10583,20 @@ export interface LoadBalancerNetworkInterfaces { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets associated load balancer network interfaces. + * Deletes the specified load balancer inbound nat rule. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} loadBalancerName The name of the load balancer. + * + * @param {string} inboundNatRuleName The name of the inbound nat rule. * * @param {object} [options] Optional Parameters. * @@ -10688,7 +10610,7 @@ export interface LoadBalancerNetworkInterfaces { * * {Promise} A promise is returned. * - * @resolve {NetworkInterfaceListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10696,57 +10618,54 @@ export interface LoadBalancerNetworkInterfaces { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkInterfaceListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkInterfaceListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * LoadBalancerProbes - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface LoadBalancerProbes { + deleteMethod(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the load balancer probes. + * Gets the specified load balancer inbound nat rule. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} loadBalancerName The name of the load balancer. * + * @param {string} inboundNatRuleName The name of the inbound nat rule. + * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands referenced resources. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the load balancer probes. + * Gets the specified load balancer inbound nat rule. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} loadBalancerName The name of the load balancer. * + * @param {string} inboundNatRuleName The name of the inbound nat rule. + * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands referenced resources. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -10757,7 +10676,7 @@ export interface LoadBalancerProbes { * * {Promise} A promise is returned. * - * @resolve {LoadBalancerProbeListResult} - The deserialized result object. + * @resolve {InboundNatRule} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10765,106 +10684,134 @@ export interface LoadBalancerProbes { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LoadBalancerProbeListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LoadBalancerProbeListResult} for more - * information. + * {InboundNatRule} [result] - The deserialized result object if an error did not occur. + * See {@link InboundNatRule} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, loadBalancerName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets load balancer probe. + * Creates or updates a load balancer inbound nat rule. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} loadBalancerName The name of the load balancer. * - * @param {string} probeName The name of the probe. + * @param {string} inboundNatRuleName The name of the inbound nat rule. * - * @param {object} [options] Optional Parameters. + * @param {object} inboundNatRuleParameters Parameters supplied to the create + * or update inbound nat rule operation. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {object} [inboundNatRuleParameters.frontendIPConfiguration] A + * reference to frontend IP addresses. * - * @returns {Promise} A promise is returned + * @param {string} [inboundNatRuleParameters.frontendIPConfiguration.id] + * Resource ID. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} [inboundNatRuleParameters.protocol] Possible values include: + * 'Udp', 'Tcp', 'All' * - * @reject {Error|ServiceError} - The error object. - */ - getWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, probeName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets load balancer probe. + * @param {number} [inboundNatRuleParameters.frontendPort] The port for the + * external endpoint. Port numbers for each rule must be unique within the Load + * Balancer. Acceptable values range from 1 to 65534. * - * @param {string} resourceGroupName The name of the resource group. + * @param {number} [inboundNatRuleParameters.backendPort] The port used for the + * internal endpoint. Acceptable values range from 1 to 65535. * - * @param {string} loadBalancerName The name of the load balancer. + * @param {number} [inboundNatRuleParameters.idleTimeoutInMinutes] The timeout + * for the TCP idle connection. The value can be set between 4 and 30 minutes. + * The default value is 4 minutes. This element is only used when the protocol + * is set to TCP. * - * @param {string} probeName The name of the probe. + * @param {boolean} [inboundNatRuleParameters.enableFloatingIP] Configures a + * virtual machine's endpoint for the floating IP capability required to + * configure a SQL AlwaysOn Availability Group. This setting is required when + * using the SQL AlwaysOn Availability Groups in SQL server. This setting can't + * be changed after you create the endpoint. + * + * @param {string} [inboundNatRuleParameters.provisioningState] Gets the + * provisioning state of the public IP resource. Possible values are: + * 'Updating', 'Deleting', and 'Failed'. + * + * @param {string} [inboundNatRuleParameters.name] Gets name of the resource + * that is unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [inboundNatRuleParameters.etag] A unique read-only string + * that changes whenever the resource is updated. + * + * @param {string} [inboundNatRuleParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @returns {Promise} A promise is returned * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * {Promise} A promise is returned. + * @reject {Error|ServiceError} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, inboundNatRuleParameters: models.InboundNatRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a load balancer inbound nat rule. * - * @resolve {Probe} - The deserialized result object. + * @param {string} resourceGroupName The name of the resource group. * - * @reject {Error|ServiceError} - The error object. + * @param {string} loadBalancerName The name of the load balancer. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {string} inboundNatRuleName The name of the inbound nat rule. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {object} inboundNatRuleParameters Parameters supplied to the create + * or update inbound nat rule operation. * - * {Probe} [result] - The deserialized result object if an error did not occur. - * See {@link Probe} for more information. + * @param {object} [inboundNatRuleParameters.frontendIPConfiguration] A + * reference to frontend IP addresses. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {string} [inboundNatRuleParameters.frontendIPConfiguration.id] + * Resource ID. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - get(resourceGroupName: string, loadBalancerName: string, probeName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, loadBalancerName: string, probeName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, loadBalancerName: string, probeName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets all the load balancer probes. + * @param {string} [inboundNatRuleParameters.protocol] Possible values include: + * 'Udp', 'Tcp', 'All' * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {number} [inboundNatRuleParameters.frontendPort] The port for the + * external endpoint. Port numbers for each rule must be unique within the Load + * Balancer. Acceptable values range from 1 to 65534. * - * @param {object} [options] Optional Parameters. + * @param {number} [inboundNatRuleParameters.backendPort] The port used for the + * internal endpoint. Acceptable values range from 1 to 65535. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {number} [inboundNatRuleParameters.idleTimeoutInMinutes] The timeout + * for the TCP idle connection. The value can be set between 4 and 30 minutes. + * The default value is 4 minutes. This element is only used when the protocol + * is set to TCP. * - * @returns {Promise} A promise is returned + * @param {boolean} [inboundNatRuleParameters.enableFloatingIP] Configures a + * virtual machine's endpoint for the floating IP capability required to + * configure a SQL AlwaysOn Availability Group. This setting is required when + * using the SQL AlwaysOn Availability Groups in SQL server. This setting can't + * be changed after you create the endpoint. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} [inboundNatRuleParameters.provisioningState] Gets the + * provisioning state of the public IP resource. Possible values are: + * 'Updating', 'Deleting', and 'Failed'. * - * @reject {Error|ServiceError} - The error object. - */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets all the load balancer probes. + * @param {string} [inboundNatRuleParameters.name] Gets name of the resource + * that is unique within a resource group. This name can be used to access the + * resource. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} [inboundNatRuleParameters.etag] A unique read-only string + * that changes whenever the resource is updated. + * + * @param {string} [inboundNatRuleParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -10878,7 +10825,7 @@ export interface LoadBalancerProbes { * * {Promise} A promise is returned. * - * @resolve {LoadBalancerProbeListResult} - The deserialized result object. + * @resolve {InboundNatRule} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10886,34 +10833,26 @@ export interface LoadBalancerProbes { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LoadBalancerProbeListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LoadBalancerProbeListResult} for more - * information. + * {InboundNatRule} [result] - The deserialized result object if an error did not occur. + * See {@link InboundNatRule} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * NetworkInterfaces - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface NetworkInterfaces { + createOrUpdate(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, inboundNatRuleParameters: models.InboundNatRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, inboundNatRuleParameters: models.InboundNatRule, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, inboundNatRuleParameters: models.InboundNatRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified network interface. + * Deletes the specified load balancer inbound nat rule. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkInterfaceName The name of the network interface. + * @param {string} loadBalancerName The name of the load balancer. + * + * @param {string} inboundNatRuleName The name of the inbound nat rule. * * @param {object} [options] Optional Parameters. * @@ -10926,14 +10865,16 @@ export interface NetworkInterfaces { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified network interface. + * Deletes the specified load balancer inbound nat rule. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkInterfaceName The name of the network interface. + * @param {string} loadBalancerName The name of the load balancer. + * + * @param {string} inboundNatRuleName The name of the inbound nat rule. * * @param {object} [options] Optional Parameters. * @@ -10961,43 +10902,129 @@ export interface NetworkInterfaces { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, networkInterfaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets information about the specified network interface. + * Creates or updates a load balancer inbound nat rule. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkInterfaceName The name of the network interface. + * @param {string} loadBalancerName The name of the load balancer. * - * @param {object} [options] Optional Parameters. + * @param {string} inboundNatRuleName The name of the inbound nat rule. * - * @param {string} [options.expand] Expands referenced resources. + * @param {object} inboundNatRuleParameters Parameters supplied to the create + * or update inbound nat rule operation. + * + * @param {object} [inboundNatRuleParameters.frontendIPConfiguration] A + * reference to frontend IP addresses. + * + * @param {string} [inboundNatRuleParameters.frontendIPConfiguration.id] + * Resource ID. + * + * @param {string} [inboundNatRuleParameters.protocol] Possible values include: + * 'Udp', 'Tcp', 'All' + * + * @param {number} [inboundNatRuleParameters.frontendPort] The port for the + * external endpoint. Port numbers for each rule must be unique within the Load + * Balancer. Acceptable values range from 1 to 65534. + * + * @param {number} [inboundNatRuleParameters.backendPort] The port used for the + * internal endpoint. Acceptable values range from 1 to 65535. + * + * @param {number} [inboundNatRuleParameters.idleTimeoutInMinutes] The timeout + * for the TCP idle connection. The value can be set between 4 and 30 minutes. + * The default value is 4 minutes. This element is only used when the protocol + * is set to TCP. + * + * @param {boolean} [inboundNatRuleParameters.enableFloatingIP] Configures a + * virtual machine's endpoint for the floating IP capability required to + * configure a SQL AlwaysOn Availability Group. This setting is required when + * using the SQL AlwaysOn Availability Groups in SQL server. This setting can't + * be changed after you create the endpoint. + * + * @param {string} [inboundNatRuleParameters.provisioningState] Gets the + * provisioning state of the public IP resource. Possible values are: + * 'Updating', 'Deleting', and 'Failed'. + * + * @param {string} [inboundNatRuleParameters.name] Gets name of the resource + * that is unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [inboundNatRuleParameters.etag] A unique read-only string + * that changes whenever the resource is updated. + * + * @param {string} [inboundNatRuleParameters.id] Resource ID. + * + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, inboundNatRuleParameters: models.InboundNatRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets information about the specified network interface. + * Creates or updates a load balancer inbound nat rule. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkInterfaceName The name of the network interface. + * @param {string} loadBalancerName The name of the load balancer. * - * @param {object} [options] Optional Parameters. + * @param {string} inboundNatRuleName The name of the inbound nat rule. * - * @param {string} [options.expand] Expands referenced resources. + * @param {object} inboundNatRuleParameters Parameters supplied to the create + * or update inbound nat rule operation. + * + * @param {object} [inboundNatRuleParameters.frontendIPConfiguration] A + * reference to frontend IP addresses. + * + * @param {string} [inboundNatRuleParameters.frontendIPConfiguration.id] + * Resource ID. + * + * @param {string} [inboundNatRuleParameters.protocol] Possible values include: + * 'Udp', 'Tcp', 'All' + * + * @param {number} [inboundNatRuleParameters.frontendPort] The port for the + * external endpoint. Port numbers for each rule must be unique within the Load + * Balancer. Acceptable values range from 1 to 65534. + * + * @param {number} [inboundNatRuleParameters.backendPort] The port used for the + * internal endpoint. Acceptable values range from 1 to 65535. + * + * @param {number} [inboundNatRuleParameters.idleTimeoutInMinutes] The timeout + * for the TCP idle connection. The value can be set between 4 and 30 minutes. + * The default value is 4 minutes. This element is only used when the protocol + * is set to TCP. + * + * @param {boolean} [inboundNatRuleParameters.enableFloatingIP] Configures a + * virtual machine's endpoint for the floating IP capability required to + * configure a SQL AlwaysOn Availability Group. This setting is required when + * using the SQL AlwaysOn Availability Groups in SQL server. This setting can't + * be changed after you create the endpoint. + * + * @param {string} [inboundNatRuleParameters.provisioningState] Gets the + * provisioning state of the public IP resource. Possible values are: + * 'Updating', 'Deleting', and 'Failed'. + * + * @param {string} [inboundNatRuleParameters.name] Gets name of the resource + * that is unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [inboundNatRuleParameters.etag] A unique read-only string + * that changes whenever the resource is updated. + * + * @param {string} [inboundNatRuleParameters.id] Resource ID. + * + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request @@ -11009,7 +11036,7 @@ export interface NetworkInterfaces { * * {Promise} A promise is returned. * - * @resolve {NetworkInterface} - The deserialized result object. + * @resolve {InboundNatRule} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11017,115 +11044,91 @@ export interface NetworkInterfaces { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkInterface} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkInterface} for more information. + * {InboundNatRule} [result] - The deserialized result object if an error did not occur. + * See {@link InboundNatRule} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, networkInterfaceName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, networkInterfaceName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, inboundNatRuleParameters: models.InboundNatRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, inboundNatRuleParameters: models.InboundNatRule, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, loadBalancerName: string, inboundNatRuleName: string, inboundNatRuleParameters: models.InboundNatRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a network interface. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkInterfaceName The name of the network interface. - * - * @param {object} parameters Parameters supplied to the create or update - * network interface operation. - * - * @param {object} [parameters.virtualMachine] The reference of a virtual - * machine. - * - * @param {string} [parameters.virtualMachine.id] Resource ID. - * - * @param {object} [parameters.networkSecurityGroup] The reference of the - * NetworkSecurityGroup resource. - * - * @param {array} [parameters.networkSecurityGroup.securityRules] A collection - * of security rules of the network security group. - * - * @param {array} [parameters.networkSecurityGroup.defaultSecurityRules] The - * default security rules of network security group. - * - * @param {string} [parameters.networkSecurityGroup.resourceGuid] The resource - * GUID property of the network security group resource. - * - * @param {string} [parameters.networkSecurityGroup.provisioningState] The - * provisioning state of the public IP resource. Possible values are: - * 'Updating', 'Deleting', and 'Failed'. + * Gets all the inbound nat rules in a load balancer. * - * @param {string} [parameters.networkSecurityGroup.etag] A unique read-only - * string that changes whenever the resource is updated. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {string} [parameters.networkSecurityGroup.id] Resource ID. + * @param {object} [options] Optional Parameters. * - * @param {string} [parameters.networkSecurityGroup.location] Resource - * location. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} [parameters.networkSecurityGroup.tags] Resource tags. + * @returns {Promise} A promise is returned * - * @param {array} [parameters.ipConfigurations] A list of IPConfigurations of - * the network interface. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {object} [parameters.dnsSettings] The DNS settings in network - * interface. + * @reject {Error|ServiceError} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all the inbound nat rules in a load balancer. * - * @param {array} [parameters.dnsSettings.dnsServers] List of DNS servers IP - * addresses. Use 'AzureProvidedDNS' to switch to azure provided DNS - * resolution. 'AzureProvidedDNS' value cannot be combined with other IPs, it - * must be the only value in dnsServers collection. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {array} [parameters.dnsSettings.appliedDnsServers] If the VM that - * uses this NIC is part of an Availability Set, then this list will have the - * union of all DNS servers from all NICs that are part of the Availability - * Set. This property is what is configured on each of those VMs. + * @param {object} [options] Optional Parameters. * - * @param {string} [parameters.dnsSettings.internalDnsNameLabel] Relative DNS - * name for this NIC used for internal communications between VMs in the same - * virtual network. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.dnsSettings.internalFqdn] Fully qualified DNS - * name supporting internal communications between VMs in the same virtual - * network. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} [parameters.dnsSettings.internalDomainNameSuffix] Even if - * internalDnsNameLabel is not specified, a DNS entry is created for the - * primary NIC of the VM. This DNS name can be constructed by concatenating the - * VM name with the value of internalDomainNameSuffix. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {string} [parameters.macAddress] The MAC address of the network - * interface. + * {Promise} A promise is returned. * - * @param {boolean} [parameters.primary] Gets whether this is a primary network - * interface on a virtual machine. + * @resolve {InboundNatRuleListResult} - The deserialized result object. * - * @param {boolean} [parameters.enableAcceleratedNetworking] If the network - * interface is accelerated networking enabled. + * @reject {Error|ServiceError} - The error object. * - * @param {boolean} [parameters.enableIPForwarding] Indicates whether IP - * forwarding is enabled on this network interface. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * network interface resource. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [parameters.provisioningState] The provisioning state of the - * public IP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. + * {InboundNatRuleListResult} [result] - The deserialized result object if an error did not occur. + * See {@link InboundNatRuleListResult} for more + * information. * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {string} [parameters.id] Resource ID. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * LoadBalancerLoadBalancingRules + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface LoadBalancerLoadBalancingRules { + + + /** + * Gets all the load balancing rules in a load balancer. * - * @param {string} [parameters.location] Resource location. + * @param {string} resourceGroupName The name of the resource group. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} loadBalancerName The name of the load balancer. * * @param {object} [options] Optional Parameters. * @@ -11134,109 +11137,82 @@ export interface NetworkInterfaces { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, parameters: models.NetworkInterface, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a network interface. + * Gets all the load balancing rules in a load balancer. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkInterfaceName The name of the network interface. + * @param {string} loadBalancerName The name of the load balancer. * - * @param {object} parameters Parameters supplied to the create or update - * network interface operation. + * @param {object} [options] Optional Parameters. * - * @param {object} [parameters.virtualMachine] The reference of a virtual - * machine. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.virtualMachine.id] Resource ID. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {object} [parameters.networkSecurityGroup] The reference of the - * NetworkSecurityGroup resource. - * - * @param {array} [parameters.networkSecurityGroup.securityRules] A collection - * of security rules of the network security group. - * - * @param {array} [parameters.networkSecurityGroup.defaultSecurityRules] The - * default security rules of network security group. - * - * @param {string} [parameters.networkSecurityGroup.resourceGuid] The resource - * GUID property of the network security group resource. - * - * @param {string} [parameters.networkSecurityGroup.provisioningState] The - * provisioning state of the public IP resource. Possible values are: - * 'Updating', 'Deleting', and 'Failed'. - * - * @param {string} [parameters.networkSecurityGroup.etag] A unique read-only - * string that changes whenever the resource is updated. - * - * @param {string} [parameters.networkSecurityGroup.id] Resource ID. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {string} [parameters.networkSecurityGroup.location] Resource - * location. + * {Promise} A promise is returned. * - * @param {object} [parameters.networkSecurityGroup.tags] Resource tags. + * @resolve {LoadBalancerLoadBalancingRuleListResult} - The deserialized result object. * - * @param {array} [parameters.ipConfigurations] A list of IPConfigurations of - * the network interface. + * @reject {Error|ServiceError} - The error object. * - * @param {object} [parameters.dnsSettings] The DNS settings in network - * interface. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {array} [parameters.dnsSettings.dnsServers] List of DNS servers IP - * addresses. Use 'AzureProvidedDNS' to switch to azure provided DNS - * resolution. 'AzureProvidedDNS' value cannot be combined with other IPs, it - * must be the only value in dnsServers collection. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {array} [parameters.dnsSettings.appliedDnsServers] If the VM that - * uses this NIC is part of an Availability Set, then this list will have the - * union of all DNS servers from all NICs that are part of the Availability - * Set. This property is what is configured on each of those VMs. + * {LoadBalancerLoadBalancingRuleListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LoadBalancerLoadBalancingRuleListResult} for + * more information. * - * @param {string} [parameters.dnsSettings.internalDnsNameLabel] Relative DNS - * name for this NIC used for internal communications between VMs in the same - * virtual network. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {string} [parameters.dnsSettings.internalFqdn] Fully qualified DNS - * name supporting internal communications between VMs in the same virtual - * network. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + list(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, loadBalancerName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets the specified load balancer load balancing rule. * - * @param {string} [parameters.dnsSettings.internalDomainNameSuffix] Even if - * internalDnsNameLabel is not specified, a DNS entry is created for the - * primary NIC of the VM. This DNS name can be constructed by concatenating the - * VM name with the value of internalDomainNameSuffix. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [parameters.macAddress] The MAC address of the network - * interface. + * @param {string} loadBalancerName The name of the load balancer. * - * @param {boolean} [parameters.primary] Gets whether this is a primary network - * interface on a virtual machine. + * @param {string} loadBalancingRuleName The name of the load balancing rule. * - * @param {boolean} [parameters.enableAcceleratedNetworking] If the network - * interface is accelerated networking enabled. + * @param {object} [options] Optional Parameters. * - * @param {boolean} [parameters.enableIPForwarding] Indicates whether IP - * forwarding is enabled on this network interface. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * network interface resource. + * @returns {Promise} A promise is returned * - * @param {string} [parameters.provisioningState] The provisioning state of the - * public IP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. + * @reject {Error|ServiceError} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, loadBalancingRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets the specified load balancer load balancing rule. * - * @param {string} [parameters.id] Resource ID. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [parameters.location] Resource location. + * @param {string} loadBalancerName The name of the load balancer. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} loadBalancingRuleName The name of the load balancing rule. * * @param {object} [options] Optional Parameters. * @@ -11250,7 +11226,7 @@ export interface NetworkInterfaces { * * {Promise} A promise is returned. * - * @resolve {NetworkInterface} - The deserialized result object. + * @resolve {LoadBalancingRule} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11258,29 +11234,23 @@ export interface NetworkInterfaces { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkInterface} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkInterface} for more information. + * {LoadBalancingRule} [result] - The deserialized result object if an error did not occur. + * See {@link LoadBalancingRule} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, networkInterfaceName: string, parameters: models.NetworkInterface, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, networkInterfaceName: string, parameters: models.NetworkInterface, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, networkInterfaceName: string, parameters: models.NetworkInterface, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, loadBalancerName: string, loadBalancingRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, loadBalancerName: string, loadBalancingRuleName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, loadBalancerName: string, loadBalancingRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a network interface tags. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkInterfaceName The name of the network interface. - * - * @param {object} parameters Parameters supplied to update network interface - * tags. + * Gets all the load balancing rules in a load balancer. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -11289,23 +11259,17 @@ export interface NetworkInterfaces { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateTagsWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a network interface tags. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkInterfaceName The name of the network interface. - * - * @param {object} parameters Parameters supplied to update network interface - * tags. + * Gets all the load balancing rules in a load balancer. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -11319,7 +11283,7 @@ export interface NetworkInterfaces { * * {Promise} A promise is returned. * - * @resolve {NetworkInterface} - The deserialized result object. + * @resolve {LoadBalancerLoadBalancingRuleListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11327,20 +11291,34 @@ export interface NetworkInterfaces { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkInterface} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkInterface} for more information. + * {LoadBalancerLoadBalancingRuleListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LoadBalancerLoadBalancingRuleListResult} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - updateTags(resourceGroupName: string, networkInterfaceName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - updateTags(resourceGroupName: string, networkInterfaceName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - updateTags(resourceGroupName: string, networkInterfaceName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * LoadBalancerNetworkInterfaces + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface LoadBalancerNetworkInterfaces { /** - * Gets all network interfaces in a subscription. + * Gets associated load balancer network interfaces. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} loadBalancerName The name of the load balancer. * * @param {object} [options] Optional Parameters. * @@ -11353,10 +11331,14 @@ export interface NetworkInterfaces { * * @reject {Error|ServiceError} - The error object. */ - listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all network interfaces in a subscription. + * Gets associated load balancer network interfaces. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} loadBalancerName The name of the load balancer. * * @param {object} [options] Optional Parameters. * @@ -11386,15 +11368,16 @@ export interface NetworkInterfaces { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAll(callback: ServiceCallback): void; - listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, loadBalancerName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all network interfaces in a resource group. + * Gets associated load balancer network interfaces. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -11407,12 +11390,13 @@ export interface NetworkInterfaces { * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all network interfaces in a resource group. + * Gets associated load balancer network interfaces. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -11442,17 +11426,26 @@ export interface NetworkInterfaces { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * LoadBalancerProbes + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface LoadBalancerProbes { /** - * Gets all route tables applied to a network interface. + * Gets all the load balancer probes. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkInterfaceName The name of the network interface. + * @param {string} loadBalancerName The name of the load balancer. * * @param {object} [options] Optional Parameters. * @@ -11461,18 +11454,18 @@ export interface NetworkInterfaces { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getEffectiveRouteTableWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all route tables applied to a network interface. + * Gets all the load balancer probes. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkInterfaceName The name of the network interface. + * @param {string} loadBalancerName The name of the load balancer. * * @param {object} [options] Optional Parameters. * @@ -11486,7 +11479,7 @@ export interface NetworkInterfaces { * * {Promise} A promise is returned. * - * @resolve {EffectiveRouteListResult} - The deserialized result object. + * @resolve {LoadBalancerProbeListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11494,25 +11487,27 @@ export interface NetworkInterfaces { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {EffectiveRouteListResult} [result] - The deserialized result object if an error did not occur. - * See {@link EffectiveRouteListResult} for more + * {LoadBalancerProbeListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LoadBalancerProbeListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getEffectiveRouteTable(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getEffectiveRouteTable(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; - getEffectiveRouteTable(resourceGroupName: string, networkInterfaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, loadBalancerName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, loadBalancerName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, loadBalancerName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all network security groups applied to a network interface. + * Gets load balancer probe. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkInterfaceName The name of the network interface. + * @param {string} loadBalancerName The name of the load balancer. + * + * @param {string} probeName The name of the probe. * * @param {object} [options] Optional Parameters. * @@ -11521,18 +11516,20 @@ export interface NetworkInterfaces { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listEffectiveNetworkSecurityGroupsWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, loadBalancerName: string, probeName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all network security groups applied to a network interface. + * Gets load balancer probe. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkInterfaceName The name of the network interface. + * @param {string} loadBalancerName The name of the load balancer. + * + * @param {string} probeName The name of the probe. * * @param {object} [options] Optional Parameters. * @@ -11546,7 +11543,7 @@ export interface NetworkInterfaces { * * {Promise} A promise is returned. * - * @resolve {EffectiveNetworkSecurityGroupListResult} - The deserialized result object. + * @resolve {Probe} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11554,29 +11551,23 @@ export interface NetworkInterfaces { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {EffectiveNetworkSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link EffectiveNetworkSecurityGroupListResult} for - * more information. + * {Probe} [result] - The deserialized result object if an error did not occur. + * See {@link Probe} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listEffectiveNetworkSecurityGroups(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listEffectiveNetworkSecurityGroups(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; - listEffectiveNetworkSecurityGroups(resourceGroupName: string, networkInterfaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, loadBalancerName: string, probeName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, loadBalancerName: string, probeName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, loadBalancerName: string, probeName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets information about all network interfaces in a virtual machine in a - * virtual machine scale set. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualMachineScaleSetName The name of the virtual machine - * scale set. + * Gets all the load balancer probes. * - * @param {string} virtualmachineIndex The virtual machine index. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -11585,22 +11576,17 @@ export interface NetworkInterfaces { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listVirtualMachineScaleSetVMNetworkInterfacesWithHttpOperationResponse(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets information about all network interfaces in a virtual machine in a - * virtual machine scale set. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualMachineScaleSetName The name of the virtual machine - * scale set. + * Gets all the load balancer probes. * - * @param {string} virtualmachineIndex The virtual machine index. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -11614,7 +11600,7 @@ export interface NetworkInterfaces { * * {Promise} A promise is returned. * - * @resolve {NetworkInterfaceListResult} - The deserialized result object. + * @resolve {LoadBalancerProbeListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11622,26 +11608,34 @@ export interface NetworkInterfaces { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkInterfaceListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkInterfaceListResult} for more + * {LoadBalancerProbeListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LoadBalancerProbeListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listVirtualMachineScaleSetVMNetworkInterfaces(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listVirtualMachineScaleSetVMNetworkInterfaces(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, callback: ServiceCallback): void; - listVirtualMachineScaleSetVMNetworkInterfaces(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * NetworkInterfaces + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface NetworkInterfaces { /** - * Gets all network interfaces in a virtual machine scale set. + * Deletes the specified network interface. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualMachineScaleSetName The name of the virtual machine - * scale set. + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * @@ -11650,19 +11644,18 @@ export interface NetworkInterfaces { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listVirtualMachineScaleSetNetworkInterfacesWithHttpOperationResponse(resourceGroupName: string, virtualMachineScaleSetName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all network interfaces in a virtual machine scale set. + * Deletes the specified network interface. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualMachineScaleSetName The name of the virtual machine - * scale set. + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * @@ -11676,7 +11669,7 @@ export interface NetworkInterfaces { * * {Promise} A promise is returned. * - * @resolve {NetworkInterfaceListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11684,29 +11677,22 @@ export interface NetworkInterfaces { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkInterfaceListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkInterfaceListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listVirtualMachineScaleSetNetworkInterfaces(resourceGroupName: string, virtualMachineScaleSetName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listVirtualMachineScaleSetNetworkInterfaces(resourceGroupName: string, virtualMachineScaleSetName: string, callback: ServiceCallback): void; - listVirtualMachineScaleSetNetworkInterfaces(resourceGroupName: string, virtualMachineScaleSetName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, networkInterfaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Get the specified network interface in a virtual machine scale set. + * Gets information about the specified network interface. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualMachineScaleSetName The name of the virtual machine - * scale set. - * - * @param {string} virtualmachineIndex The virtual machine index. - * * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. @@ -11722,18 +11708,13 @@ export interface NetworkInterfaces { * * @reject {Error|ServiceError} - The error object. */ - getVirtualMachineScaleSetNetworkInterfaceWithHttpOperationResponse(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Get the specified network interface in a virtual machine scale set. + * Gets information about the specified network interface. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualMachineScaleSetName The name of the virtual machine - * scale set. - * - * @param {string} virtualmachineIndex The virtual machine index. - * * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. @@ -11765,362 +11746,148 @@ export interface NetworkInterfaces { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getVirtualMachineScaleSetNetworkInterface(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - getVirtualMachineScaleSetNetworkInterface(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, callback: ServiceCallback): void; - getVirtualMachineScaleSetNetworkInterface(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, networkInterfaceName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, networkInterfaceName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Get the specified network interface ip configuration in a virtual machine - * scale set. + * Creates or updates a network interface. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualMachineScaleSetName The name of the virtual machine - * scale set. - * - * @param {string} virtualmachineIndex The virtual machine index. - * * @param {string} networkInterfaceName The name of the network interface. * - * @param {object} [options] Optional Parameters. + * @param {object} parameters Parameters supplied to the create or update + * network interface operation. * - * @param {string} [options.expand] Expands referenced resources. + * @param {object} [parameters.virtualMachine] The reference of a virtual + * machine. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [parameters.virtualMachine.id] Resource ID. * - * @returns {Promise} A promise is returned + * @param {object} [parameters.networkSecurityGroup] The reference of the + * NetworkSecurityGroup resource. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {array} [parameters.networkSecurityGroup.securityRules] A collection + * of security rules of the network security group. * - * @reject {Error|ServiceError} - The error object. - */ - listVirtualMachineScaleSetIpConfigurationsWithHttpOperationResponse(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Get the specified network interface ip configuration in a virtual machine - * scale set. + * @param {array} [parameters.networkSecurityGroup.defaultSecurityRules] The + * default security rules of network security group. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [parameters.networkSecurityGroup.resourceGuid] The resource + * GUID property of the network security group resource. * - * @param {string} virtualMachineScaleSetName The name of the virtual machine - * scale set. + * @param {string} [parameters.networkSecurityGroup.provisioningState] The + * provisioning state of the public IP resource. Possible values are: + * 'Updating', 'Deleting', and 'Failed'. * - * @param {string} virtualmachineIndex The virtual machine index. + * @param {string} [parameters.networkSecurityGroup.etag] A unique read-only + * string that changes whenever the resource is updated. * - * @param {string} networkInterfaceName The name of the network interface. + * @param {string} [parameters.networkSecurityGroup.id] Resource ID. * - * @param {object} [options] Optional Parameters. + * @param {string} [parameters.networkSecurityGroup.location] Resource + * location. * - * @param {string} [options.expand] Expands referenced resources. + * @param {object} [parameters.networkSecurityGroup.tags] Resource tags. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {array} [parameters.ipConfigurations] A list of IPConfigurations of + * the network interface. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {object} [parameters.dnsSettings] The DNS settings in network + * interface. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {array} [parameters.dnsSettings.dnsServers] List of DNS servers IP + * addresses. Use 'AzureProvidedDNS' to switch to azure provided DNS + * resolution. 'AzureProvidedDNS' value cannot be combined with other IPs, it + * must be the only value in dnsServers collection. * - * {Promise} A promise is returned. + * @param {array} [parameters.dnsSettings.appliedDnsServers] If the VM that + * uses this NIC is part of an Availability Set, then this list will have the + * union of all DNS servers from all NICs that are part of the Availability + * Set. This property is what is configured on each of those VMs. * - * @resolve {NetworkInterfaceIPConfigurationListResult} - The deserialized result object. + * @param {string} [parameters.dnsSettings.internalDnsNameLabel] Relative DNS + * name for this NIC used for internal communications between VMs in the same + * virtual network. * - * @reject {Error|ServiceError} - The error object. + * @param {string} [parameters.dnsSettings.internalFqdn] Fully qualified DNS + * name supporting internal communications between VMs in the same virtual + * network. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {string} [parameters.dnsSettings.internalDomainNameSuffix] Even if + * internalDnsNameLabel is not specified, a DNS entry is created for the + * primary NIC of the VM. This DNS name can be constructed by concatenating the + * VM name with the value of internalDomainNameSuffix. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {string} [parameters.macAddress] The MAC address of the network + * interface. * - * {NetworkInterfaceIPConfigurationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkInterfaceIPConfigurationListResult} - * for more information. + * @param {boolean} [parameters.primary] Gets whether this is a primary network + * interface on a virtual machine. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {boolean} [parameters.enableAcceleratedNetworking] If the network + * interface is accelerated networking enabled. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listVirtualMachineScaleSetIpConfigurations(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - listVirtualMachineScaleSetIpConfigurations(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, callback: ServiceCallback): void; - listVirtualMachineScaleSetIpConfigurations(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Get the specified network interface ip configuration in a virtual machine - * scale set. + * @param {boolean} [parameters.enableIPForwarding] Indicates whether IP + * forwarding is enabled on this network interface. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * network interface resource. * - * @param {string} virtualMachineScaleSetName The name of the virtual machine - * scale set. + * @param {string} [parameters.provisioningState] The provisioning state of the + * public IP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. * - * @param {string} virtualmachineIndex The virtual machine index. + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. * - * @param {string} networkInterfaceName The name of the network interface. + * @param {string} [parameters.id] Resource ID. * - * @param {string} ipConfigurationName The name of the ip configuration. + * @param {string} [parameters.location] Resource location. * - * @param {object} [options] Optional Parameters. + * @param {object} [parameters.tags] Resource tags. * - * @param {string} [options.expand] Expands referenced resources. + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getVirtualMachineScaleSetIpConfigurationWithHttpOperationResponse(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, parameters: models.NetworkInterface, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Get the specified network interface ip configuration in a virtual machine - * scale set. + * Creates or updates a network interface. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualMachineScaleSetName The name of the virtual machine - * scale set. - * - * @param {string} virtualmachineIndex The virtual machine index. - * * @param {string} networkInterfaceName The name of the network interface. * - * @param {string} ipConfigurationName The name of the ip configuration. + * @param {object} parameters Parameters supplied to the create or update + * network interface operation. * - * @param {object} [options] Optional Parameters. + * @param {object} [parameters.virtualMachine] The reference of a virtual + * machine. * - * @param {string} [options.expand] Expands referenced resources. + * @param {string} [parameters.virtualMachine.id] Resource ID. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {object} [parameters.networkSecurityGroup] The reference of the + * NetworkSecurityGroup resource. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {array} [parameters.networkSecurityGroup.securityRules] A collection + * of security rules of the network security group. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {array} [parameters.networkSecurityGroup.defaultSecurityRules] The + * default security rules of network security group. * - * {Promise} A promise is returned. - * - * @resolve {NetworkInterfaceIPConfiguration} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {NetworkInterfaceIPConfiguration} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkInterfaceIPConfiguration} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - getVirtualMachineScaleSetIpConfiguration(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - getVirtualMachineScaleSetIpConfiguration(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, callback: ServiceCallback): void; - getVirtualMachineScaleSetIpConfiguration(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Deletes the specified network interface. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkInterfaceName The name of the network interface. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Deletes the specified network interface. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkInterfaceName The name of the network interface. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {null} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {null} [result] - The deserialized result object if an error did not occur. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginDeleteMethod(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, networkInterfaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Creates or updates a network interface. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkInterfaceName The name of the network interface. - * - * @param {object} parameters Parameters supplied to the create or update - * network interface operation. - * - * @param {object} [parameters.virtualMachine] The reference of a virtual - * machine. - * - * @param {string} [parameters.virtualMachine.id] Resource ID. - * - * @param {object} [parameters.networkSecurityGroup] The reference of the - * NetworkSecurityGroup resource. - * - * @param {array} [parameters.networkSecurityGroup.securityRules] A collection - * of security rules of the network security group. - * - * @param {array} [parameters.networkSecurityGroup.defaultSecurityRules] The - * default security rules of network security group. - * - * @param {string} [parameters.networkSecurityGroup.resourceGuid] The resource - * GUID property of the network security group resource. - * - * @param {string} [parameters.networkSecurityGroup.provisioningState] The - * provisioning state of the public IP resource. Possible values are: - * 'Updating', 'Deleting', and 'Failed'. - * - * @param {string} [parameters.networkSecurityGroup.etag] A unique read-only - * string that changes whenever the resource is updated. - * - * @param {string} [parameters.networkSecurityGroup.id] Resource ID. - * - * @param {string} [parameters.networkSecurityGroup.location] Resource - * location. - * - * @param {object} [parameters.networkSecurityGroup.tags] Resource tags. - * - * @param {array} [parameters.ipConfigurations] A list of IPConfigurations of - * the network interface. - * - * @param {object} [parameters.dnsSettings] The DNS settings in network - * interface. - * - * @param {array} [parameters.dnsSettings.dnsServers] List of DNS servers IP - * addresses. Use 'AzureProvidedDNS' to switch to azure provided DNS - * resolution. 'AzureProvidedDNS' value cannot be combined with other IPs, it - * must be the only value in dnsServers collection. - * - * @param {array} [parameters.dnsSettings.appliedDnsServers] If the VM that - * uses this NIC is part of an Availability Set, then this list will have the - * union of all DNS servers from all NICs that are part of the Availability - * Set. This property is what is configured on each of those VMs. - * - * @param {string} [parameters.dnsSettings.internalDnsNameLabel] Relative DNS - * name for this NIC used for internal communications between VMs in the same - * virtual network. - * - * @param {string} [parameters.dnsSettings.internalFqdn] Fully qualified DNS - * name supporting internal communications between VMs in the same virtual - * network. - * - * @param {string} [parameters.dnsSettings.internalDomainNameSuffix] Even if - * internalDnsNameLabel is not specified, a DNS entry is created for the - * primary NIC of the VM. This DNS name can be constructed by concatenating the - * VM name with the value of internalDomainNameSuffix. - * - * @param {string} [parameters.macAddress] The MAC address of the network - * interface. - * - * @param {boolean} [parameters.primary] Gets whether this is a primary network - * interface on a virtual machine. - * - * @param {boolean} [parameters.enableAcceleratedNetworking] If the network - * interface is accelerated networking enabled. - * - * @param {boolean} [parameters.enableIPForwarding] Indicates whether IP - * forwarding is enabled on this network interface. - * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * network interface resource. - * - * @param {string} [parameters.provisioningState] The provisioning state of the - * public IP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. - * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. - * - * @param {string} [parameters.id] Resource ID. - * - * @param {string} [parameters.location] Resource location. - * - * @param {object} [parameters.tags] Resource tags. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, parameters: models.NetworkInterface, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Creates or updates a network interface. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkInterfaceName The name of the network interface. - * - * @param {object} parameters Parameters supplied to the create or update - * network interface operation. - * - * @param {object} [parameters.virtualMachine] The reference of a virtual - * machine. - * - * @param {string} [parameters.virtualMachine.id] Resource ID. - * - * @param {object} [parameters.networkSecurityGroup] The reference of the - * NetworkSecurityGroup resource. - * - * @param {array} [parameters.networkSecurityGroup.securityRules] A collection - * of security rules of the network security group. - * - * @param {array} [parameters.networkSecurityGroup.defaultSecurityRules] The - * default security rules of network security group. - * - * @param {string} [parameters.networkSecurityGroup.resourceGuid] The resource - * GUID property of the network security group resource. + * @param {string} [parameters.networkSecurityGroup.resourceGuid] The resource + * GUID property of the network security group resource. * * @param {string} [parameters.networkSecurityGroup.provisioningState] The * provisioning state of the public IP resource. Possible values are: @@ -12220,9 +11987,9 @@ export interface NetworkInterfaces { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, networkInterfaceName: string, parameters: models.NetworkInterface, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, networkInterfaceName: string, parameters: models.NetworkInterface, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, networkInterfaceName: string, parameters: models.NetworkInterface, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, networkInterfaceName: string, parameters: models.NetworkInterface, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, networkInterfaceName: string, parameters: models.NetworkInterface, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, networkInterfaceName: string, parameters: models.NetworkInterface, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -12248,7 +12015,7 @@ export interface NetworkInterfaces { * * @reject {Error|ServiceError} - The error object. */ - beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateTagsWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Updates a network interface tags. @@ -12289,17 +12056,13 @@ export interface NetworkInterfaces { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdateTags(resourceGroupName: string, networkInterfaceName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdateTags(resourceGroupName: string, networkInterfaceName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - beginUpdateTags(resourceGroupName: string, networkInterfaceName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, networkInterfaceName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, networkInterfaceName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, networkInterfaceName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all route tables applied to a network interface. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkInterfaceName The name of the network interface. + * Gets all network interfaces in a subscription. * * @param {object} [options] Optional Parameters. * @@ -12308,18 +12071,14 @@ export interface NetworkInterfaces { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginGetEffectiveRouteTableWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all route tables applied to a network interface. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkInterfaceName The name of the network interface. + * Gets all network interfaces in a subscription. * * @param {object} [options] Optional Parameters. * @@ -12333,7 +12092,7 @@ export interface NetworkInterfaces { * * {Promise} A promise is returned. * - * @resolve {EffectiveRouteListResult} - The deserialized result object. + * @resolve {NetworkInterfaceListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12341,26 +12100,24 @@ export interface NetworkInterfaces { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {EffectiveRouteListResult} [result] - The deserialized result object if an error did not occur. - * See {@link EffectiveRouteListResult} for more + * {NetworkInterfaceListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkInterfaceListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginGetEffectiveRouteTable(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginGetEffectiveRouteTable(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; - beginGetEffectiveRouteTable(resourceGroupName: string, networkInterfaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAll(callback: ServiceCallback): void; + listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all network security groups applied to a network interface. + * Gets all network interfaces in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkInterfaceName The name of the network interface. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -12368,19 +12125,17 @@ export interface NetworkInterfaces { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginListEffectiveNetworkSecurityGroupsWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all network security groups applied to a network interface. + * Gets all network interfaces in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkInterfaceName The name of the network interface. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -12393,7 +12148,7 @@ export interface NetworkInterfaces { * * {Promise} A promise is returned. * - * @resolve {EffectiveNetworkSecurityGroupListResult} - The deserialized result object. + * @resolve {NetworkInterfaceListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12401,24 +12156,25 @@ export interface NetworkInterfaces { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {EffectiveNetworkSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link EffectiveNetworkSecurityGroupListResult} for - * more information. + * {NetworkInterfaceListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkInterfaceListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginListEffectiveNetworkSecurityGroups(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginListEffectiveNetworkSecurityGroups(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; - beginListEffectiveNetworkSecurityGroups(resourceGroupName: string, networkInterfaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all network interfaces in a subscription. + * Gets all route tables applied to a network interface. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * @@ -12427,17 +12183,18 @@ export interface NetworkInterfaces { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getEffectiveRouteTableWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all network interfaces in a subscription. + * Gets all route tables applied to a network interface. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * @@ -12451,7 +12208,7 @@ export interface NetworkInterfaces { * * {Promise} A promise is returned. * - * @resolve {NetworkInterfaceListResult} - The deserialized result object. + * @resolve {EffectiveRouteListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12459,24 +12216,25 @@ export interface NetworkInterfaces { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkInterfaceListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkInterfaceListResult} for more + * {EffectiveRouteListResult} [result] - The deserialized result object if an error did not occur. + * See {@link EffectiveRouteListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAllNext(nextPageLink: string, callback: ServiceCallback): void; - listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + getEffectiveRouteTable(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getEffectiveRouteTable(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; + getEffectiveRouteTable(resourceGroupName: string, networkInterfaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all network interfaces in a resource group. + * Gets all network security groups applied to a network interface. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * @@ -12485,17 +12243,18 @@ export interface NetworkInterfaces { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listEffectiveNetworkSecurityGroupsWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all network interfaces in a resource group. + * Gets all network security groups applied to a network interface. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * @@ -12509,7 +12268,7 @@ export interface NetworkInterfaces { * * {Promise} A promise is returned. * - * @resolve {NetworkInterfaceListResult} - The deserialized result object. + * @resolve {EffectiveNetworkSecurityGroupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12517,25 +12276,29 @@ export interface NetworkInterfaces { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkInterfaceListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkInterfaceListResult} for more - * information. + * {EffectiveNetworkSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link EffectiveNetworkSecurityGroupListResult} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listEffectiveNetworkSecurityGroups(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listEffectiveNetworkSecurityGroups(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; + listEffectiveNetworkSecurityGroups(resourceGroupName: string, networkInterfaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Gets information about all network interfaces in a virtual machine in a * virtual machine scale set. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualMachineScaleSetName The name of the virtual machine + * scale set. + * + * @param {string} virtualmachineIndex The virtual machine index. * * @param {object} [options] Optional Parameters. * @@ -12548,14 +12311,18 @@ export interface NetworkInterfaces { * * @reject {Error|ServiceError} - The error object. */ - listVirtualMachineScaleSetVMNetworkInterfacesNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listVirtualMachineScaleSetVMNetworkInterfacesWithHttpOperationResponse(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Gets information about all network interfaces in a virtual machine in a * virtual machine scale set. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualMachineScaleSetName The name of the virtual machine + * scale set. + * + * @param {string} virtualmachineIndex The virtual machine index. * * @param {object} [options] Optional Parameters. * @@ -12585,16 +12352,18 @@ export interface NetworkInterfaces { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listVirtualMachineScaleSetVMNetworkInterfacesNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listVirtualMachineScaleSetVMNetworkInterfacesNext(nextPageLink: string, callback: ServiceCallback): void; - listVirtualMachineScaleSetVMNetworkInterfacesNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listVirtualMachineScaleSetVMNetworkInterfaces(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listVirtualMachineScaleSetVMNetworkInterfaces(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, callback: ServiceCallback): void; + listVirtualMachineScaleSetVMNetworkInterfaces(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Gets all network interfaces in a virtual machine scale set. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualMachineScaleSetName The name of the virtual machine + * scale set. * * @param {object} [options] Optional Parameters. * @@ -12607,13 +12376,15 @@ export interface NetworkInterfaces { * * @reject {Error|ServiceError} - The error object. */ - listVirtualMachineScaleSetNetworkInterfacesNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listVirtualMachineScaleSetNetworkInterfacesWithHttpOperationResponse(resourceGroupName: string, virtualMachineScaleSetName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Gets all network interfaces in a virtual machine scale set. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualMachineScaleSetName The name of the virtual machine + * scale set. * * @param {object} [options] Optional Parameters. * @@ -12643,40 +12414,54 @@ export interface NetworkInterfaces { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listVirtualMachineScaleSetNetworkInterfacesNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listVirtualMachineScaleSetNetworkInterfacesNext(nextPageLink: string, callback: ServiceCallback): void; - listVirtualMachineScaleSetNetworkInterfacesNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listVirtualMachineScaleSetNetworkInterfaces(resourceGroupName: string, virtualMachineScaleSetName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listVirtualMachineScaleSetNetworkInterfaces(resourceGroupName: string, virtualMachineScaleSetName: string, callback: ServiceCallback): void; + listVirtualMachineScaleSetNetworkInterfaces(resourceGroupName: string, virtualMachineScaleSetName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Get the specified network interface ip configuration in a virtual machine + * Get the specified network interface in a virtual machine scale set. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualMachineScaleSetName The name of the virtual machine * scale set. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} virtualmachineIndex The virtual machine index. + * + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands referenced resources. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listVirtualMachineScaleSetIpConfigurationsNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getVirtualMachineScaleSetNetworkInterfaceWithHttpOperationResponse(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Get the specified network interface ip configuration in a virtual machine + * Get the specified network interface in a virtual machine scale set. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualMachineScaleSetName The name of the virtual machine * scale set. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} virtualmachineIndex The virtual machine index. + * + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands referenced resources. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -12687,7 +12472,7 @@ export interface NetworkInterfaces { * * {Promise} A promise is returned. * - * @resolve {NetworkInterfaceIPConfigurationListResult} - The deserialized result object. + * @resolve {NetworkInterface} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12695,37 +12480,35 @@ export interface NetworkInterfaces { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkInterfaceIPConfigurationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkInterfaceIPConfigurationListResult} - * for more information. + * {NetworkInterface} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkInterface} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listVirtualMachineScaleSetIpConfigurationsNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listVirtualMachineScaleSetIpConfigurationsNext(nextPageLink: string, callback: ServiceCallback): void; - listVirtualMachineScaleSetIpConfigurationsNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * NetworkInterfaceIPConfigurations - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface NetworkInterfaceIPConfigurations { + getVirtualMachineScaleSetNetworkInterface(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + getVirtualMachineScaleSetNetworkInterface(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, callback: ServiceCallback): void; + getVirtualMachineScaleSetNetworkInterface(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Get all ip configurations in a network interface + * Get the specified network interface ip configuration in a virtual machine + * scale set. * * @param {string} resourceGroupName The name of the resource group. * + * @param {string} virtualMachineScaleSetName The name of the virtual machine + * scale set. + * + * @param {string} virtualmachineIndex The virtual machine index. + * * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands referenced resources. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -12735,17 +12518,25 @@ export interface NetworkInterfaceIPConfigurations { * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listVirtualMachineScaleSetIpConfigurationsWithHttpOperationResponse(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Get all ip configurations in a network interface + * Get the specified network interface ip configuration in a virtual machine + * scale set. * * @param {string} resourceGroupName The name of the resource group. * + * @param {string} virtualMachineScaleSetName The name of the virtual machine + * scale set. + * + * @param {string} virtualmachineIndex The virtual machine index. + * * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands referenced resources. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -12772,22 +12563,30 @@ export interface NetworkInterfaceIPConfigurations { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, networkInterfaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listVirtualMachineScaleSetIpConfigurations(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + listVirtualMachineScaleSetIpConfigurations(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, callback: ServiceCallback): void; + listVirtualMachineScaleSetIpConfigurations(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified network interface ip configuration. + * Get the specified network interface ip configuration in a virtual machine + * scale set. * * @param {string} resourceGroupName The name of the resource group. * + * @param {string} virtualMachineScaleSetName The name of the virtual machine + * scale set. + * + * @param {string} virtualmachineIndex The virtual machine index. + * * @param {string} networkInterfaceName The name of the network interface. * - * @param {string} ipConfigurationName The name of the ip configuration name. + * @param {string} ipConfigurationName The name of the ip configuration. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands referenced resources. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -12797,19 +12596,27 @@ export interface NetworkInterfaceIPConfigurations { * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, ipConfigurationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getVirtualMachineScaleSetIpConfigurationWithHttpOperationResponse(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified network interface ip configuration. + * Get the specified network interface ip configuration in a virtual machine + * scale set. * * @param {string} resourceGroupName The name of the resource group. * + * @param {string} virtualMachineScaleSetName The name of the virtual machine + * scale set. + * + * @param {string} virtualmachineIndex The virtual machine index. + * * @param {string} networkInterfaceName The name of the network interface. * - * @param {string} ipConfigurationName The name of the ip configuration name. + * @param {string} ipConfigurationName The name of the ip configuration. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands referenced resources. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -12836,16 +12643,17 @@ export interface NetworkInterfaceIPConfigurations { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, networkInterfaceName: string, ipConfigurationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, networkInterfaceName: string, ipConfigurationName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, networkInterfaceName: string, ipConfigurationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + getVirtualMachineScaleSetIpConfiguration(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + getVirtualMachineScaleSetIpConfiguration(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, callback: ServiceCallback): void; + getVirtualMachineScaleSetIpConfiguration(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Get all ip configurations in a network interface + * Deletes the specified network interface. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * @@ -12854,17 +12662,18 @@ export interface NetworkInterfaceIPConfigurations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Get all ip configurations in a network interface + * Deletes the specified network interface. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * @@ -12878,7 +12687,7 @@ export interface NetworkInterfaceIPConfigurations { * * {Promise} A promise is returned. * - * @resolve {NetworkInterfaceIPConfigurationListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12886,35 +12695,115 @@ export interface NetworkInterfaceIPConfigurations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkInterfaceIPConfigurationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkInterfaceIPConfigurationListResult} - * for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * NetworkInterfaceLoadBalancers - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface NetworkInterfaceLoadBalancers { + beginDeleteMethod(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, networkInterfaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * List all load balancers in a network interface. + * Creates or updates a network interface. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkInterfaceName The name of the network interface. * + * @param {object} parameters Parameters supplied to the create or update + * network interface operation. + * + * @param {object} [parameters.virtualMachine] The reference of a virtual + * machine. + * + * @param {string} [parameters.virtualMachine.id] Resource ID. + * + * @param {object} [parameters.networkSecurityGroup] The reference of the + * NetworkSecurityGroup resource. + * + * @param {array} [parameters.networkSecurityGroup.securityRules] A collection + * of security rules of the network security group. + * + * @param {array} [parameters.networkSecurityGroup.defaultSecurityRules] The + * default security rules of network security group. + * + * @param {string} [parameters.networkSecurityGroup.resourceGuid] The resource + * GUID property of the network security group resource. + * + * @param {string} [parameters.networkSecurityGroup.provisioningState] The + * provisioning state of the public IP resource. Possible values are: + * 'Updating', 'Deleting', and 'Failed'. + * + * @param {string} [parameters.networkSecurityGroup.etag] A unique read-only + * string that changes whenever the resource is updated. + * + * @param {string} [parameters.networkSecurityGroup.id] Resource ID. + * + * @param {string} [parameters.networkSecurityGroup.location] Resource + * location. + * + * @param {object} [parameters.networkSecurityGroup.tags] Resource tags. + * + * @param {array} [parameters.ipConfigurations] A list of IPConfigurations of + * the network interface. + * + * @param {object} [parameters.dnsSettings] The DNS settings in network + * interface. + * + * @param {array} [parameters.dnsSettings.dnsServers] List of DNS servers IP + * addresses. Use 'AzureProvidedDNS' to switch to azure provided DNS + * resolution. 'AzureProvidedDNS' value cannot be combined with other IPs, it + * must be the only value in dnsServers collection. + * + * @param {array} [parameters.dnsSettings.appliedDnsServers] If the VM that + * uses this NIC is part of an Availability Set, then this list will have the + * union of all DNS servers from all NICs that are part of the Availability + * Set. This property is what is configured on each of those VMs. + * + * @param {string} [parameters.dnsSettings.internalDnsNameLabel] Relative DNS + * name for this NIC used for internal communications between VMs in the same + * virtual network. + * + * @param {string} [parameters.dnsSettings.internalFqdn] Fully qualified DNS + * name supporting internal communications between VMs in the same virtual + * network. + * + * @param {string} [parameters.dnsSettings.internalDomainNameSuffix] Even if + * internalDnsNameLabel is not specified, a DNS entry is created for the + * primary NIC of the VM. This DNS name can be constructed by concatenating the + * VM name with the value of internalDomainNameSuffix. + * + * @param {string} [parameters.macAddress] The MAC address of the network + * interface. + * + * @param {boolean} [parameters.primary] Gets whether this is a primary network + * interface on a virtual machine. + * + * @param {boolean} [parameters.enableAcceleratedNetworking] If the network + * interface is accelerated networking enabled. + * + * @param {boolean} [parameters.enableIPForwarding] Indicates whether IP + * forwarding is enabled on this network interface. + * + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * network interface resource. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * public IP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. + * + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -12922,76 +12811,109 @@ export interface NetworkInterfaceLoadBalancers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, parameters: models.NetworkInterface, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * List all load balancers in a network interface. + * Creates or updates a network interface. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkInterfaceName The name of the network interface. * - * @param {object} [options] Optional Parameters. + * @param {object} parameters Parameters supplied to the create or update + * network interface operation. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {object} [parameters.virtualMachine] The reference of a virtual + * machine. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {string} [parameters.virtualMachine.id] Resource ID. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {object} [parameters.networkSecurityGroup] The reference of the + * NetworkSecurityGroup resource. * - * {Promise} A promise is returned. + * @param {array} [parameters.networkSecurityGroup.securityRules] A collection + * of security rules of the network security group. * - * @resolve {NetworkInterfaceLoadBalancerListResult} - The deserialized result object. + * @param {array} [parameters.networkSecurityGroup.defaultSecurityRules] The + * default security rules of network security group. * - * @reject {Error|ServiceError} - The error object. + * @param {string} [parameters.networkSecurityGroup.resourceGuid] The resource + * GUID property of the network security group resource. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {string} [parameters.networkSecurityGroup.provisioningState] The + * provisioning state of the public IP resource. Possible values are: + * 'Updating', 'Deleting', and 'Failed'. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {string} [parameters.networkSecurityGroup.etag] A unique read-only + * string that changes whenever the resource is updated. * - * {NetworkInterfaceLoadBalancerListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkInterfaceLoadBalancerListResult} for - * more information. + * @param {string} [parameters.networkSecurityGroup.id] Resource ID. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {string} [parameters.networkSecurityGroup.location] Resource + * location. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - list(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, networkInterfaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * List all load balancers in a network interface. + * @param {object} [parameters.networkSecurityGroup.tags] Resource tags. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {array} [parameters.ipConfigurations] A list of IPConfigurations of + * the network interface. * - * @param {object} [options] Optional Parameters. + * @param {object} [parameters.dnsSettings] The DNS settings in network + * interface. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {array} [parameters.dnsSettings.dnsServers] List of DNS servers IP + * addresses. Use 'AzureProvidedDNS' to switch to azure provided DNS + * resolution. 'AzureProvidedDNS' value cannot be combined with other IPs, it + * must be the only value in dnsServers collection. * - * @returns {Promise} A promise is returned + * @param {array} [parameters.dnsSettings.appliedDnsServers] If the VM that + * uses this NIC is part of an Availability Set, then this list will have the + * union of all DNS servers from all NICs that are part of the Availability + * Set. This property is what is configured on each of those VMs. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} [parameters.dnsSettings.internalDnsNameLabel] Relative DNS + * name for this NIC used for internal communications between VMs in the same + * virtual network. * - * @reject {Error|ServiceError} - The error object. - */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * List all load balancers in a network interface. + * @param {string} [parameters.dnsSettings.internalFqdn] Fully qualified DNS + * name supporting internal communications between VMs in the same virtual + * network. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} [parameters.dnsSettings.internalDomainNameSuffix] Even if + * internalDnsNameLabel is not specified, a DNS entry is created for the + * primary NIC of the VM. This DNS name can be constructed by concatenating the + * VM name with the value of internalDomainNameSuffix. + * + * @param {string} [parameters.macAddress] The MAC address of the network + * interface. + * + * @param {boolean} [parameters.primary] Gets whether this is a primary network + * interface on a virtual machine. + * + * @param {boolean} [parameters.enableAcceleratedNetworking] If the network + * interface is accelerated networking enabled. + * + * @param {boolean} [parameters.enableIPForwarding] Indicates whether IP + * forwarding is enabled on this network interface. + * + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * network interface resource. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * public IP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. + * + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -13005,7 +12927,7 @@ export interface NetworkInterfaceLoadBalancers { * * {Promise} A promise is returned. * - * @resolve {NetworkInterfaceLoadBalancerListResult} - The deserialized result object. + * @resolve {NetworkInterface} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13013,35 +12935,29 @@ export interface NetworkInterfaceLoadBalancers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkInterfaceLoadBalancerListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkInterfaceLoadBalancerListResult} for - * more information. + * {NetworkInterface} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkInterface} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * NetworkSecurityGroups - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface NetworkSecurityGroups { + beginCreateOrUpdate(resourceGroupName: string, networkInterfaceName: string, parameters: models.NetworkInterface, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, networkInterfaceName: string, parameters: models.NetworkInterface, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, networkInterfaceName: string, parameters: models.NetworkInterface, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified network security group. + * Updates a network interface tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkSecurityGroupName The name of the network security - * group. + * @param {string} networkInterfaceName The name of the network interface. + * + * @param {object} parameters Parameters supplied to update network interface + * tags. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -13050,19 +12966,23 @@ export interface NetworkSecurityGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified network security group. + * Updates a network interface tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkSecurityGroupName The name of the network security - * group. + * @param {string} networkInterfaceName The name of the network interface. + * + * @param {object} parameters Parameters supplied to update network interface + * tags. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -13076,7 +12996,7 @@ export interface NetworkSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {NetworkInterface} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13084,52 +13004,47 @@ export interface NetworkSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {NetworkInterface} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkInterface} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, networkSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, networkSecurityGroupName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, networkSecurityGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, networkInterfaceName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdateTags(resourceGroupName: string, networkInterfaceName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, networkInterfaceName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified network security group. + * Gets all route tables applied to a network interface. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkSecurityGroupName The name of the network security - * group. + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.expand] Expands referenced resources. - * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + beginGetEffectiveRouteTableWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified network security group. + * Gets all route tables applied to a network interface. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkSecurityGroupName The name of the network security - * group. + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.expand] Expands referenced resources. - * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -13140,7 +13055,7 @@ export interface NetworkSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {NetworkSecurityGroup} - The deserialized result object. + * @resolve {EffectiveRouteListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13148,50 +13063,25 @@ export interface NetworkSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkSecurityGroup} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkSecurityGroup} for more information. + * {EffectiveRouteListResult} [result] - The deserialized result object if an error did not occur. + * See {@link EffectiveRouteListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, networkSecurityGroupName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, networkSecurityGroupName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, networkSecurityGroupName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginGetEffectiveRouteTable(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginGetEffectiveRouteTable(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; + beginGetEffectiveRouteTable(resourceGroupName: string, networkInterfaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a network security group in the specified resource group. + * Gets all network security groups applied to a network interface. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkSecurityGroupName The name of the network security - * group. - * - * @param {object} parameters Parameters supplied to the create or update - * network security group operation. - * - * @param {array} [parameters.securityRules] A collection of security rules of - * the network security group. - * - * @param {array} [parameters.defaultSecurityRules] The default security rules - * of network security group. - * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * network security group resource. - * - * @param {string} [parameters.provisioningState] The provisioning state of the - * public IP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. - * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. - * - * @param {string} [parameters.id] Resource ID. - * - * @param {string} [parameters.location] Resource location. - * - * @param {object} [parameters.tags] Resource tags. + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * @@ -13200,44 +13090,18 @@ export interface NetworkSecurityGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.NetworkSecurityGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginListEffectiveNetworkSecurityGroupsWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a network security group in the specified resource group. + * Gets all network security groups applied to a network interface. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkSecurityGroupName The name of the network security - * group. - * - * @param {object} parameters Parameters supplied to the create or update - * network security group operation. - * - * @param {array} [parameters.securityRules] A collection of security rules of - * the network security group. - * - * @param {array} [parameters.defaultSecurityRules] The default security rules - * of network security group. - * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * network security group resource. - * - * @param {string} [parameters.provisioningState] The provisioning state of the - * public IP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. - * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. - * - * @param {string} [parameters.id] Resource ID. - * - * @param {string} [parameters.location] Resource location. - * - * @param {object} [parameters.tags] Resource tags. + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * @@ -13251,7 +13115,7 @@ export interface NetworkSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {NetworkSecurityGroup} - The deserialized result object. + * @resolve {EffectiveNetworkSecurityGroupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13259,30 +13123,24 @@ export interface NetworkSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkSecurityGroup} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkSecurityGroup} for more information. + * {EffectiveNetworkSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link EffectiveNetworkSecurityGroupListResult} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.NetworkSecurityGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.NetworkSecurityGroup, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.NetworkSecurityGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginListEffectiveNetworkSecurityGroups(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginListEffectiveNetworkSecurityGroups(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; + beginListEffectiveNetworkSecurityGroups(resourceGroupName: string, networkInterfaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a network security group tags. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkSecurityGroupName The name of the network security - * group. - * - * @param {object} parameters Parameters supplied to update network security - * group tags. + * Gets all network interfaces in a subscription. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13291,24 +13149,17 @@ export interface NetworkSecurityGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateTagsWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a network security group tags. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkSecurityGroupName The name of the network security - * group. - * - * @param {object} parameters Parameters supplied to update network security - * group tags. + * Gets all network interfaces in a subscription. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13322,7 +13173,7 @@ export interface NetworkSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {NetworkSecurityGroup} - The deserialized result object. + * @resolve {NetworkInterfaceListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13330,20 +13181,24 @@ export interface NetworkSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkSecurityGroup} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkSecurityGroup} for more information. + * {NetworkInterfaceListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkInterfaceListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - updateTags(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - updateTags(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - updateTags(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAllNext(nextPageLink: string, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all network security groups in a subscription. + * Gets all network interfaces in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13352,14 +13207,17 @@ export interface NetworkSecurityGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all network security groups in a subscription. + * Gets all network interfaces in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13373,7 +13231,7 @@ export interface NetworkSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {NetworkSecurityGroupListResult} - The deserialized result object. + * @resolve {NetworkInterfaceListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13381,23 +13239,25 @@ export interface NetworkSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkSecurityGroupListResult} for more + * {NetworkInterfaceListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkInterfaceListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAll(callback: ServiceCallback): void; - listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all network security groups in a resource group. + * Gets information about all network interfaces in a virtual machine in a + * virtual machine scale set. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13406,16 +13266,18 @@ export interface NetworkSecurityGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listVirtualMachineScaleSetVMNetworkInterfacesNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all network security groups in a resource group. + * Gets information about all network interfaces in a virtual machine in a + * virtual machine scale set. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13429,7 +13291,7 @@ export interface NetworkSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {NetworkSecurityGroupListResult} - The deserialized result object. + * @resolve {NetworkInterfaceListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13437,26 +13299,24 @@ export interface NetworkSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkSecurityGroupListResult} for more + * {NetworkInterfaceListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkInterfaceListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listVirtualMachineScaleSetVMNetworkInterfacesNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listVirtualMachineScaleSetVMNetworkInterfacesNext(nextPageLink: string, callback: ServiceCallback): void; + listVirtualMachineScaleSetVMNetworkInterfacesNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified network security group. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets all network interfaces in a virtual machine scale set. * - * @param {string} networkSecurityGroupName The name of the network security - * group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13465,19 +13325,17 @@ export interface NetworkSecurityGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listVirtualMachineScaleSetNetworkInterfacesNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified network security group. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets all network interfaces in a virtual machine scale set. * - * @param {string} networkSecurityGroupName The name of the network security - * group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13491,7 +13349,7 @@ export interface NetworkSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {NetworkInterfaceListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13499,49 +13357,25 @@ export interface NetworkSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {NetworkInterfaceListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkInterfaceListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, networkSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, networkSecurityGroupName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, networkSecurityGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listVirtualMachineScaleSetNetworkInterfacesNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listVirtualMachineScaleSetNetworkInterfacesNext(nextPageLink: string, callback: ServiceCallback): void; + listVirtualMachineScaleSetNetworkInterfacesNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a network security group in the specified resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkSecurityGroupName The name of the network security - * group. - * - * @param {object} parameters Parameters supplied to the create or update - * network security group operation. - * - * @param {array} [parameters.securityRules] A collection of security rules of - * the network security group. - * - * @param {array} [parameters.defaultSecurityRules] The default security rules - * of network security group. - * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * network security group resource. - * - * @param {string} [parameters.provisioningState] The provisioning state of the - * public IP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. - * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. - * - * @param {string} [parameters.id] Resource ID. - * - * @param {string} [parameters.location] Resource location. + * Get the specified network interface ip configuration in a virtual machine + * scale set. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13550,44 +13384,18 @@ export interface NetworkSecurityGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.NetworkSecurityGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listVirtualMachineScaleSetIpConfigurationsNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a network security group in the specified resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkSecurityGroupName The name of the network security - * group. - * - * @param {object} parameters Parameters supplied to the create or update - * network security group operation. - * - * @param {array} [parameters.securityRules] A collection of security rules of - * the network security group. - * - * @param {array} [parameters.defaultSecurityRules] The default security rules - * of network security group. - * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * network security group resource. - * - * @param {string} [parameters.provisioningState] The provisioning state of the - * public IP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. - * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. - * - * @param {string} [parameters.id] Resource ID. - * - * @param {string} [parameters.location] Resource location. + * Get the specified network interface ip configuration in a virtual machine + * scale set. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13601,7 +13409,7 @@ export interface NetworkSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {NetworkSecurityGroup} - The deserialized result object. + * @resolve {NetworkInterfaceIPConfigurationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13609,30 +13417,34 @@ export interface NetworkSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkSecurityGroup} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkSecurityGroup} for more information. + * {NetworkInterfaceIPConfigurationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkInterfaceIPConfigurationListResult} + * for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.NetworkSecurityGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.NetworkSecurityGroup, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.NetworkSecurityGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listVirtualMachineScaleSetIpConfigurationsNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listVirtualMachineScaleSetIpConfigurationsNext(nextPageLink: string, callback: ServiceCallback): void; + listVirtualMachineScaleSetIpConfigurationsNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * NetworkInterfaceIPConfigurations + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface NetworkInterfaceIPConfigurations { /** - * Updates a network security group tags. + * Get all ip configurations in a network interface * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkSecurityGroupName The name of the network security - * group. - * - * @param {object} parameters Parameters supplied to update network security - * group tags. - * - * @param {object} [parameters.tags] Resource tags. + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * @@ -13641,24 +13453,18 @@ export interface NetworkSecurityGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a network security group tags. + * Get all ip configurations in a network interface * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkSecurityGroupName The name of the network security - * group. - * - * @param {object} parameters Parameters supplied to update network security - * group tags. - * - * @param {object} [parameters.tags] Resource tags. + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * @@ -13672,7 +13478,7 @@ export interface NetworkSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {NetworkSecurityGroup} - The deserialized result object. + * @resolve {NetworkInterfaceIPConfigurationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13680,23 +13486,27 @@ export interface NetworkSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkSecurityGroup} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkSecurityGroup} for more information. + * {NetworkInterfaceIPConfigurationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkInterfaceIPConfigurationListResult} + * for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdateTags(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdateTags(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - beginUpdateTags(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, networkInterfaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all network security groups in a subscription. + * Gets the specified network interface ip configuration. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} networkInterfaceName The name of the network interface. + * + * @param {string} ipConfigurationName The name of the ip configuration name. * * @param {object} [options] Optional Parameters. * @@ -13705,17 +13515,20 @@ export interface NetworkSecurityGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, ipConfigurationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all network security groups in a subscription. + * Gets the specified network interface ip configuration. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} networkInterfaceName The name of the network interface. + * + * @param {string} ipConfigurationName The name of the ip configuration name. * * @param {object} [options] Optional Parameters. * @@ -13729,7 +13542,7 @@ export interface NetworkSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {NetworkSecurityGroupListResult} - The deserialized result object. + * @resolve {NetworkInterfaceIPConfiguration} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13737,21 +13550,21 @@ export interface NetworkSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkSecurityGroupListResult} for more + * {NetworkInterfaceIPConfiguration} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkInterfaceIPConfiguration} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAllNext(nextPageLink: string, callback: ServiceCallback): void; - listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, networkInterfaceName: string, ipConfigurationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, networkInterfaceName: string, ipConfigurationName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, networkInterfaceName: string, ipConfigurationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all network security groups in a resource group. + * Get all ip configurations in a network interface * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -13763,14 +13576,14 @@ export interface NetworkSecurityGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all network security groups in a resource group. + * Get all ip configurations in a network interface * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -13787,7 +13600,7 @@ export interface NetworkSecurityGroups { * * {Promise} A promise is returned. * - * @resolve {NetworkSecurityGroupListResult} - The deserialized result object. + * @resolve {NetworkInterfaceIPConfigurationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13795,37 +13608,34 @@ export interface NetworkSecurityGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkSecurityGroupListResult} for more - * information. + * {NetworkInterfaceIPConfigurationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkInterfaceIPConfigurationListResult} + * for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } /** * @class - * SecurityRules + * NetworkInterfaceLoadBalancers * __NOTE__: An instance of this class is automatically created for an * instance of the NetworkManagementClient. */ -export interface SecurityRules { +export interface NetworkInterfaceLoadBalancers { /** - * Deletes the specified network security rule. + * List all load balancers in a network interface. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkSecurityGroupName The name of the network security - * group. - * - * @param {string} securityRuleName The name of the security rule. + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * @@ -13834,21 +13644,18 @@ export interface SecurityRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified network security rule. + * List all load balancers in a network interface. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkSecurityGroupName The name of the network security - * group. - * - * @param {string} securityRuleName The name of the security rule. + * @param {string} networkInterfaceName The name of the network interface. * * @param {object} [options] Optional Parameters. * @@ -13862,7 +13669,7 @@ export interface SecurityRules { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {NetworkInterfaceLoadBalancerListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13870,26 +13677,24 @@ export interface SecurityRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {NetworkInterfaceLoadBalancerListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkInterfaceLoadBalancerListResult} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, networkInterfaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, networkInterfaceName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, networkInterfaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Get the specified network security rule. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkSecurityGroupName The name of the network security - * group. + * List all load balancers in a network interface. * - * @param {string} securityRuleName The name of the security rule. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13898,21 +13703,17 @@ export interface SecurityRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Get the specified network security rule. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkSecurityGroupName The name of the network security - * group. + * List all load balancers in a network interface. * - * @param {string} securityRuleName The name of the security rule. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13926,7 +13727,7 @@ export interface SecurityRules { * * {Promise} A promise is returned. * - * @resolve {SecurityRule} - The deserialized result object. + * @resolve {NetworkInterfaceLoadBalancerListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13934,102 +13735,36 @@ export interface SecurityRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SecurityRule} [result] - The deserialized result object if an error did not occur. - * See {@link SecurityRule} for more information. + * {NetworkInterfaceLoadBalancerListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkInterfaceLoadBalancerListResult} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * NetworkSecurityGroups + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface NetworkSecurityGroups { /** - * Creates or updates a security rule in the specified network security group. + * Deletes the specified network security group. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkSecurityGroupName The name of the network security * group. * - * @param {string} securityRuleName The name of the security rule. - * - * @param {object} securityRuleParameters Parameters supplied to the create or - * update network security rule operation. - * - * @param {string} [securityRuleParameters.description] A description for this - * rule. Restricted to 140 chars. - * - * @param {string} securityRuleParameters.protocol Network protocol this rule - * applies to. Possible values are 'Tcp', 'Udp', and '*'. Possible values - * include: 'Tcp', 'Udp', '*' - * - * @param {string} [securityRuleParameters.sourcePortRange] The source port or - * range. Integer or range between 0 and 65535. Asterix '*' can also be used to - * match all ports. - * - * @param {string} [securityRuleParameters.destinationPortRange] The - * destination port or range. Integer or range between 0 and 65535. Asterix '*' - * can also be used to match all ports. - * - * @param {string} [securityRuleParameters.sourceAddressPrefix] The CIDR or - * source IP range. Asterix '*' can also be used to match all source IPs. - * Default tags such as 'VirtualNetwork', 'AzureLoadBalancer' and 'Internet' - * can also be used. If this is an ingress rule, specifies where network - * traffic originates from. - * - * @param {array} [securityRuleParameters.sourceAddressPrefixes] The CIDR or - * source IP ranges. - * - * @param {array} [securityRuleParameters.sourceApplicationSecurityGroups] The - * application security group specified as source. - * - * @param {string} [securityRuleParameters.destinationAddressPrefix] The - * destination address prefix. CIDR or destination IP range. Asterix '*' can - * also be used to match all source IPs. Default tags such as 'VirtualNetwork', - * 'AzureLoadBalancer' and 'Internet' can also be used. - * - * @param {array} [securityRuleParameters.destinationAddressPrefixes] The - * destination address prefixes. CIDR or destination IP ranges. - * - * @param {array} [securityRuleParameters.destinationApplicationSecurityGroups] - * The application security group specified as destination. - * - * @param {array} [securityRuleParameters.sourcePortRanges] The source port - * ranges. - * - * @param {array} [securityRuleParameters.destinationPortRanges] The - * destination port ranges. - * - * @param {string} securityRuleParameters.access The network traffic is allowed - * or denied. Possible values are: 'Allow' and 'Deny'. Possible values include: - * 'Allow', 'Deny' - * - * @param {number} [securityRuleParameters.priority] The priority of the rule. - * The value can be between 100 and 4096. The priority number must be unique - * for each rule in the collection. The lower the priority number, the higher - * the priority of the rule. - * - * @param {string} securityRuleParameters.direction The direction of the rule. - * The direction specifies if rule will be evaluated on incoming or outcoming - * traffic. Possible values are: 'Inbound' and 'Outbound'. Possible values - * include: 'Inbound', 'Outbound' - * - * @param {string} [securityRuleParameters.provisioningState] The provisioning - * state of the public IP resource. Possible values are: 'Updating', - * 'Deleting', and 'Failed'. - * - * @param {string} [securityRuleParameters.name] The name of the resource that - * is unique within a resource group. This name can be used to access the - * resource. - * - * @param {string} [securityRuleParameters.etag] A unique read-only string that - * changes whenever the resource is updated. - * - * @param {string} [securityRuleParameters.id] Resource ID. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -14037,96 +13772,20 @@ export interface SecurityRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, securityRuleParameters: models.SecurityRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a security rule in the specified network security group. + * Deletes the specified network security group. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkSecurityGroupName The name of the network security * group. * - * @param {string} securityRuleName The name of the security rule. - * - * @param {object} securityRuleParameters Parameters supplied to the create or - * update network security rule operation. - * - * @param {string} [securityRuleParameters.description] A description for this - * rule. Restricted to 140 chars. - * - * @param {string} securityRuleParameters.protocol Network protocol this rule - * applies to. Possible values are 'Tcp', 'Udp', and '*'. Possible values - * include: 'Tcp', 'Udp', '*' - * - * @param {string} [securityRuleParameters.sourcePortRange] The source port or - * range. Integer or range between 0 and 65535. Asterix '*' can also be used to - * match all ports. - * - * @param {string} [securityRuleParameters.destinationPortRange] The - * destination port or range. Integer or range between 0 and 65535. Asterix '*' - * can also be used to match all ports. - * - * @param {string} [securityRuleParameters.sourceAddressPrefix] The CIDR or - * source IP range. Asterix '*' can also be used to match all source IPs. - * Default tags such as 'VirtualNetwork', 'AzureLoadBalancer' and 'Internet' - * can also be used. If this is an ingress rule, specifies where network - * traffic originates from. - * - * @param {array} [securityRuleParameters.sourceAddressPrefixes] The CIDR or - * source IP ranges. - * - * @param {array} [securityRuleParameters.sourceApplicationSecurityGroups] The - * application security group specified as source. - * - * @param {string} [securityRuleParameters.destinationAddressPrefix] The - * destination address prefix. CIDR or destination IP range. Asterix '*' can - * also be used to match all source IPs. Default tags such as 'VirtualNetwork', - * 'AzureLoadBalancer' and 'Internet' can also be used. - * - * @param {array} [securityRuleParameters.destinationAddressPrefixes] The - * destination address prefixes. CIDR or destination IP ranges. - * - * @param {array} [securityRuleParameters.destinationApplicationSecurityGroups] - * The application security group specified as destination. - * - * @param {array} [securityRuleParameters.sourcePortRanges] The source port - * ranges. - * - * @param {array} [securityRuleParameters.destinationPortRanges] The - * destination port ranges. - * - * @param {string} securityRuleParameters.access The network traffic is allowed - * or denied. Possible values are: 'Allow' and 'Deny'. Possible values include: - * 'Allow', 'Deny' - * - * @param {number} [securityRuleParameters.priority] The priority of the rule. - * The value can be between 100 and 4096. The priority number must be unique - * for each rule in the collection. The lower the priority number, the higher - * the priority of the rule. - * - * @param {string} securityRuleParameters.direction The direction of the rule. - * The direction specifies if rule will be evaluated on incoming or outcoming - * traffic. Possible values are: 'Inbound' and 'Outbound'. Possible values - * include: 'Inbound', 'Outbound' - * - * @param {string} [securityRuleParameters.provisioningState] The provisioning - * state of the public IP resource. Possible values are: 'Updating', - * 'Deleting', and 'Failed'. - * - * @param {string} [securityRuleParameters.name] The name of the resource that - * is unique within a resource group. This name can be used to access the - * resource. - * - * @param {string} [securityRuleParameters.etag] A unique read-only string that - * changes whenever the resource is updated. - * - * @param {string} [securityRuleParameters.id] Resource ID. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -14139,7 +13798,7 @@ export interface SecurityRules { * * {Promise} A promise is returned. * - * @resolve {SecurityRule} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14147,20 +13806,19 @@ export interface SecurityRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SecurityRule} [result] - The deserialized result object if an error did not occur. - * See {@link SecurityRule} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, securityRuleParameters: models.SecurityRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, securityRuleParameters: models.SecurityRule, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, securityRuleParameters: models.SecurityRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, networkSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, networkSecurityGroupName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, networkSecurityGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all security rules in a network security group. + * Gets the specified network security group. * * @param {string} resourceGroupName The name of the resource group. * @@ -14169,19 +13827,21 @@ export interface SecurityRules { * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands referenced resources. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all security rules in a network security group. + * Gets the specified network security group. * * @param {string} resourceGroupName The name of the resource group. * @@ -14190,6 +13850,8 @@ export interface SecurityRules { * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands referenced resources. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -14200,7 +13862,7 @@ export interface SecurityRules { * * {Promise} A promise is returned. * - * @resolve {SecurityRuleListResult} - The deserialized result object. + * @resolve {NetworkSecurityGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14208,28 +13870,50 @@ export interface SecurityRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SecurityRuleListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SecurityRuleListResult} for more - * information. + * {NetworkSecurityGroup} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkSecurityGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, networkSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, networkSecurityGroupName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, networkSecurityGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, networkSecurityGroupName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, networkSecurityGroupName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, networkSecurityGroupName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified network security rule. + * Creates or updates a network security group in the specified resource group. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkSecurityGroupName The name of the network security * group. * - * @param {string} securityRuleName The name of the security rule. + * @param {object} parameters Parameters supplied to the create or update + * network security group operation. + * + * @param {array} [parameters.securityRules] A collection of security rules of + * the network security group. + * + * @param {array} [parameters.defaultSecurityRules] The default security rules + * of network security group. + * + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * network security group resource. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * public IP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. + * + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -14238,21 +13922,44 @@ export interface SecurityRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.NetworkSecurityGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified network security rule. + * Creates or updates a network security group in the specified resource group. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkSecurityGroupName The name of the network security * group. * - * @param {string} securityRuleName The name of the security rule. + * @param {object} parameters Parameters supplied to the create or update + * network security group operation. + * + * @param {array} [parameters.securityRules] A collection of security rules of + * the network security group. + * + * @param {array} [parameters.defaultSecurityRules] The default security rules + * of network security group. + * + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * network security group resource. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * public IP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. + * + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -14266,7 +13973,7 @@ export interface SecurityRules { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {NetworkSecurityGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14274,100 +13981,30 @@ export interface SecurityRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {NetworkSecurityGroup} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkSecurityGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.NetworkSecurityGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.NetworkSecurityGroup, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.NetworkSecurityGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a security rule in the specified network security group. + * Updates a network security group tags. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkSecurityGroupName The name of the network security * group. * - * @param {string} securityRuleName The name of the security rule. - * - * @param {object} securityRuleParameters Parameters supplied to the create or - * update network security rule operation. - * - * @param {string} [securityRuleParameters.description] A description for this - * rule. Restricted to 140 chars. - * - * @param {string} securityRuleParameters.protocol Network protocol this rule - * applies to. Possible values are 'Tcp', 'Udp', and '*'. Possible values - * include: 'Tcp', 'Udp', '*' - * - * @param {string} [securityRuleParameters.sourcePortRange] The source port or - * range. Integer or range between 0 and 65535. Asterix '*' can also be used to - * match all ports. - * - * @param {string} [securityRuleParameters.destinationPortRange] The - * destination port or range. Integer or range between 0 and 65535. Asterix '*' - * can also be used to match all ports. - * - * @param {string} [securityRuleParameters.sourceAddressPrefix] The CIDR or - * source IP range. Asterix '*' can also be used to match all source IPs. - * Default tags such as 'VirtualNetwork', 'AzureLoadBalancer' and 'Internet' - * can also be used. If this is an ingress rule, specifies where network - * traffic originates from. - * - * @param {array} [securityRuleParameters.sourceAddressPrefixes] The CIDR or - * source IP ranges. - * - * @param {array} [securityRuleParameters.sourceApplicationSecurityGroups] The - * application security group specified as source. - * - * @param {string} [securityRuleParameters.destinationAddressPrefix] The - * destination address prefix. CIDR or destination IP range. Asterix '*' can - * also be used to match all source IPs. Default tags such as 'VirtualNetwork', - * 'AzureLoadBalancer' and 'Internet' can also be used. - * - * @param {array} [securityRuleParameters.destinationAddressPrefixes] The - * destination address prefixes. CIDR or destination IP ranges. - * - * @param {array} [securityRuleParameters.destinationApplicationSecurityGroups] - * The application security group specified as destination. - * - * @param {array} [securityRuleParameters.sourcePortRanges] The source port - * ranges. - * - * @param {array} [securityRuleParameters.destinationPortRanges] The - * destination port ranges. - * - * @param {string} securityRuleParameters.access The network traffic is allowed - * or denied. Possible values are: 'Allow' and 'Deny'. Possible values include: - * 'Allow', 'Deny' - * - * @param {number} [securityRuleParameters.priority] The priority of the rule. - * The value can be between 100 and 4096. The priority number must be unique - * for each rule in the collection. The lower the priority number, the higher - * the priority of the rule. - * - * @param {string} securityRuleParameters.direction The direction of the rule. - * The direction specifies if rule will be evaluated on incoming or outcoming - * traffic. Possible values are: 'Inbound' and 'Outbound'. Possible values - * include: 'Inbound', 'Outbound' - * - * @param {string} [securityRuleParameters.provisioningState] The provisioning - * state of the public IP resource. Possible values are: 'Updating', - * 'Deleting', and 'Failed'. - * - * @param {string} [securityRuleParameters.name] The name of the resource that - * is unique within a resource group. This name can be used to access the - * resource. - * - * @param {string} [securityRuleParameters.etag] A unique read-only string that - * changes whenever the resource is updated. + * @param {object} parameters Parameters supplied to update network security + * group tags. * - * @param {string} [securityRuleParameters.id] Resource ID. + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -14376,95 +14013,75 @@ export interface SecurityRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, securityRuleParameters: models.SecurityRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateTagsWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a security rule in the specified network security group. + * Updates a network security group tags. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkSecurityGroupName The name of the network security * group. * - * @param {string} securityRuleName The name of the security rule. - * - * @param {object} securityRuleParameters Parameters supplied to the create or - * update network security rule operation. - * - * @param {string} [securityRuleParameters.description] A description for this - * rule. Restricted to 140 chars. + * @param {object} parameters Parameters supplied to update network security + * group tags. * - * @param {string} securityRuleParameters.protocol Network protocol this rule - * applies to. Possible values are 'Tcp', 'Udp', and '*'. Possible values - * include: 'Tcp', 'Udp', '*' + * @param {object} [parameters.tags] Resource tags. * - * @param {string} [securityRuleParameters.sourcePortRange] The source port or - * range. Integer or range between 0 and 65535. Asterix '*' can also be used to - * match all ports. + * @param {object} [options] Optional Parameters. * - * @param {string} [securityRuleParameters.destinationPortRange] The - * destination port or range. Integer or range between 0 and 65535. Asterix '*' - * can also be used to match all ports. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [securityRuleParameters.sourceAddressPrefix] The CIDR or - * source IP range. Asterix '*' can also be used to match all source IPs. - * Default tags such as 'VirtualNetwork', 'AzureLoadBalancer' and 'Internet' - * can also be used. If this is an ingress rule, specifies where network - * traffic originates from. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {array} [securityRuleParameters.sourceAddressPrefixes] The CIDR or - * source IP ranges. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {array} [securityRuleParameters.sourceApplicationSecurityGroups] The - * application security group specified as source. + * {Promise} A promise is returned. * - * @param {string} [securityRuleParameters.destinationAddressPrefix] The - * destination address prefix. CIDR or destination IP range. Asterix '*' can - * also be used to match all source IPs. Default tags such as 'VirtualNetwork', - * 'AzureLoadBalancer' and 'Internet' can also be used. + * @resolve {NetworkSecurityGroup} - The deserialized result object. * - * @param {array} [securityRuleParameters.destinationAddressPrefixes] The - * destination address prefixes. CIDR or destination IP ranges. + * @reject {Error|ServiceError} - The error object. * - * @param {array} [securityRuleParameters.destinationApplicationSecurityGroups] - * The application security group specified as destination. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {array} [securityRuleParameters.sourcePortRanges] The source port - * ranges. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {array} [securityRuleParameters.destinationPortRanges] The - * destination port ranges. + * {NetworkSecurityGroup} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkSecurityGroup} for more information. * - * @param {string} securityRuleParameters.access The network traffic is allowed - * or denied. Possible values are: 'Allow' and 'Deny'. Possible values include: - * 'Allow', 'Deny' + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {number} [securityRuleParameters.priority] The priority of the rule. - * The value can be between 100 and 4096. The priority number must be unique - * for each rule in the collection. The lower the priority number, the higher - * the priority of the rule. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + updateTags(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all network security groups in a subscription. * - * @param {string} securityRuleParameters.direction The direction of the rule. - * The direction specifies if rule will be evaluated on incoming or outcoming - * traffic. Possible values are: 'Inbound' and 'Outbound'. Possible values - * include: 'Inbound', 'Outbound' + * @param {object} [options] Optional Parameters. * - * @param {string} [securityRuleParameters.provisioningState] The provisioning - * state of the public IP resource. Possible values are: 'Updating', - * 'Deleting', and 'Failed'. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [securityRuleParameters.name] The name of the resource that - * is unique within a resource group. This name can be used to access the - * resource. + * @returns {Promise} A promise is returned * - * @param {string} [securityRuleParameters.etag] A unique read-only string that - * changes whenever the resource is updated. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [securityRuleParameters.id] Resource ID. + * @reject {Error|ServiceError} - The error object. + */ + listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all network security groups in a subscription. * * @param {object} [options] Optional Parameters. * @@ -14478,7 +14095,7 @@ export interface SecurityRules { * * {Promise} A promise is returned. * - * @resolve {SecurityRule} - The deserialized result object. + * @resolve {NetworkSecurityGroupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14486,23 +14103,23 @@ export interface SecurityRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SecurityRule} [result] - The deserialized result object if an error did not occur. - * See {@link SecurityRule} for more information. + * {NetworkSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkSecurityGroupListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, securityRuleParameters: models.SecurityRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, securityRuleParameters: models.SecurityRule, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, securityRuleParameters: models.SecurityRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAll(callback: ServiceCallback): void; + listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all security rules in a network security group. + * Gets all network security groups in a resource group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. * * @param {object} [options] Optional Parameters. * @@ -14511,17 +14128,16 @@ export interface SecurityRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all security rules in a network security group. + * Gets all network security groups in a resource group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. * * @param {object} [options] Optional Parameters. * @@ -14535,7 +14151,7 @@ export interface SecurityRules { * * {Promise} A promise is returned. * - * @resolve {SecurityRuleListResult} - The deserialized result object. + * @resolve {NetworkSecurityGroupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14543,30 +14159,21 @@ export interface SecurityRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SecurityRuleListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SecurityRuleListResult} for more + * {NetworkSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkSecurityGroupListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * DefaultSecurityRules - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface DefaultSecurityRules { + list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all default security rules in a network security group. + * Deletes the specified network security group. * * @param {string} resourceGroupName The name of the resource group. * @@ -14580,14 +14187,14 @@ export interface DefaultSecurityRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all default security rules in a network security group. + * Deletes the specified network security group. * * @param {string} resourceGroupName The name of the resource group. * @@ -14606,7 +14213,7 @@ export interface DefaultSecurityRules { * * {Promise} A promise is returned. * - * @resolve {SecurityRuleListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14614,110 +14221,95 @@ export interface DefaultSecurityRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SecurityRuleListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SecurityRuleListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, networkSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, networkSecurityGroupName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, networkSecurityGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, networkSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, networkSecurityGroupName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, networkSecurityGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Get the specified default network security rule. + * Creates or updates a network security group in the specified resource group. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkSecurityGroupName The name of the network security * group. * - * @param {string} defaultSecurityRuleName The name of the default security - * rule. + * @param {object} parameters Parameters supplied to the create or update + * network security group operation. * - * @param {object} [options] Optional Parameters. + * @param {array} [parameters.securityRules] A collection of security rules of + * the network security group. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {array} [parameters.defaultSecurityRules] The default security rules + * of network security group. * - * @returns {Promise} A promise is returned + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * network security group resource. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} [parameters.provisioningState] The provisioning state of the + * public IP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. * - * @reject {Error|ServiceError} - The error object. - */ - getWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, defaultSecurityRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Get the specified default network security rule. + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [parameters.id] Resource ID. * - * @param {string} networkSecurityGroupName The name of the network security - * group. + * @param {string} [parameters.location] Resource location. * - * @param {string} defaultSecurityRuleName The name of the default security - * rule. + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SecurityRule} - The deserialized result object. + * @returns {Promise} A promise is returned * - * @reject {Error|ServiceError} - The error object. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @reject {Error|ServiceError} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.NetworkSecurityGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a network security group in the specified resource group. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {string} resourceGroupName The name of the resource group. * - * {SecurityRule} [result] - The deserialized result object if an error did not occur. - * See {@link SecurityRule} for more information. + * @param {string} networkSecurityGroupName The name of the network security + * group. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {object} parameters Parameters supplied to the create or update + * network security group operation. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - get(resourceGroupName: string, networkSecurityGroupName: string, defaultSecurityRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, networkSecurityGroupName: string, defaultSecurityRuleName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, networkSecurityGroupName: string, defaultSecurityRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets all default security rules in a network security group. + * @param {array} [parameters.securityRules] A collection of security rules of + * the network security group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {array} [parameters.defaultSecurityRules] The default security rules + * of network security group. * - * @param {object} [options] Optional Parameters. + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * network security group resource. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [parameters.provisioningState] The provisioning state of the + * public IP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. * - * @returns {Promise} A promise is returned + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} [parameters.id] Resource ID. * - * @reject {Error|ServiceError} - The error object. - */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets all default security rules in a network security group. + * @param {string} [parameters.location] Resource location. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -14731,7 +14323,7 @@ export interface DefaultSecurityRules { * * {Promise} A promise is returned. * - * @resolve {SecurityRuleListResult} - The deserialized result object. + * @resolve {NetworkSecurityGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14739,44 +14331,28 @@ export interface DefaultSecurityRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SecurityRuleListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SecurityRuleListResult} for more - * information. + * {NetworkSecurityGroup} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkSecurityGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * NetworkWatchers - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface NetworkWatchers { + beginCreateOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.NetworkSecurityGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.NetworkSecurityGroup, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.NetworkSecurityGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a network watcher in the specified resource group. + * Updates a network security group tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher. - * - * @param {object} parameters Parameters that define the network watcher - * resource. - * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. - * - * @param {string} [parameters.id] Resource ID. + * @param {string} networkSecurityGroupName The name of the network security + * group. * - * @param {string} [parameters.location] Resource location. + * @param {object} parameters Parameters supplied to update network security + * group tags. * * @param {object} [parameters.tags] Resource tags. * @@ -14787,28 +14363,22 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.NetworkWatcher, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a network watcher in the specified resource group. + * Updates a network security group tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher. - * - * @param {object} parameters Parameters that define the network watcher - * resource. - * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. - * - * @param {string} [parameters.id] Resource ID. + * @param {string} networkSecurityGroupName The name of the network security + * group. * - * @param {string} [parameters.location] Resource location. + * @param {object} parameters Parameters supplied to update network security + * group tags. * * @param {object} [parameters.tags] Resource tags. * @@ -14824,7 +14394,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {NetworkWatcher} - The deserialized result object. + * @resolve {NetworkSecurityGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14832,24 +14402,23 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkWatcher} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkWatcher} for more information. + * {NetworkSecurityGroup} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkSecurityGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, networkWatcherName: string, parameters: models.NetworkWatcher, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, networkWatcherName: string, parameters: models.NetworkWatcher, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, networkWatcherName: string, parameters: models.NetworkWatcher, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdateTags(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, networkSecurityGroupName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified network watcher by resource group. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets all network security groups in a subscription. * - * @param {string} networkWatcherName The name of the network watcher. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -14858,18 +14427,17 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified network watcher by resource group. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets all network security groups in a subscription. * - * @param {string} networkWatcherName The name of the network watcher. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -14883,7 +14451,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {NetworkWatcher} - The deserialized result object. + * @resolve {NetworkSecurityGroupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14891,24 +14459,24 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkWatcher} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkWatcher} for more information. + * {NetworkSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkSecurityGroupListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, networkWatcherName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, networkWatcherName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAllNext(nextPageLink: string, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified network watcher resource. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets all network security groups in a resource group. * - * @param {string} networkWatcherName The name of the network watcher. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -14917,18 +14485,17 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified network watcher resource. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets all network security groups in a resource group. * - * @param {string} networkWatcherName The name of the network watcher. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -14942,7 +14509,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {NetworkSecurityGroupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14950,28 +14517,37 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {NetworkSecurityGroupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkSecurityGroupListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, networkWatcherName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, networkWatcherName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * SecurityRules + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface SecurityRules { /** - * Updates a network watcher tags. + * Deletes the specified network security rule. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher. - * - * @param {object} parameters Parameters supplied to update network watcher - * tags. + * @param {string} networkSecurityGroupName The name of the network security + * group. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} securityRuleName The name of the security rule. * * @param {object} [options] Optional Parameters. * @@ -14980,23 +14556,21 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateTagsWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a network watcher tags. + * Deletes the specified network security rule. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher. - * - * @param {object} parameters Parameters supplied to update network watcher - * tags. + * @param {string} networkSecurityGroupName The name of the network security + * group. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} securityRuleName The name of the security rule. * * @param {object} [options] Optional Parameters. * @@ -15010,7 +14584,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {NetworkWatcher} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15018,23 +14592,27 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkWatcher} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkWatcher} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - updateTags(resourceGroupName: string, networkWatcherName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - updateTags(resourceGroupName: string, networkWatcherName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - updateTags(resourceGroupName: string, networkWatcherName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all network watchers by resource group. + * Get the specified network security rule. * * @param {string} resourceGroupName The name of the resource group. * + * @param {string} networkSecurityGroupName The name of the network security + * group. + * + * @param {string} securityRuleName The name of the security rule. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -15042,17 +14620,22 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all network watchers by resource group. + * Get the specified network security rule. * * @param {string} resourceGroupName The name of the resource group. * + * @param {string} networkSecurityGroupName The name of the network security + * group. + * + * @param {string} securityRuleName The name of the security rule. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -15065,7 +14648,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {NetworkWatcherListResult} - The deserialized result object. + * @resolve {SecurityRule} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15073,91 +14656,101 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NetworkWatcherListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkWatcherListResult} for more - * information. + * {SecurityRule} [result] - The deserialized result object if an error did not occur. + * See {@link SecurityRule} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all network watchers by subscription. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * Creates or updates a security rule in the specified network security group. * - * @returns {Promise} A promise is returned + * @param {string} resourceGroupName The name of the resource group. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} networkSecurityGroupName The name of the network security + * group. * - * @reject {Error|ServiceError} - The error object. - */ - listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets all network watchers by subscription. + * @param {string} securityRuleName The name of the security rule. * - * @param {object} [options] Optional Parameters. + * @param {object} securityRuleParameters Parameters supplied to the create or + * update network security rule operation. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [securityRuleParameters.description] A description for this + * rule. Restricted to 140 chars. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {string} securityRuleParameters.protocol Network protocol this rule + * applies to. Possible values are 'Tcp', 'Udp', and '*'. Possible values + * include: 'Tcp', 'Udp', '*' * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {string} [securityRuleParameters.sourcePortRange] The source port or + * range. Integer or range between 0 and 65535. Asterix '*' can also be used to + * match all ports. * - * {Promise} A promise is returned. + * @param {string} [securityRuleParameters.destinationPortRange] The + * destination port or range. Integer or range between 0 and 65535. Asterix '*' + * can also be used to match all ports. * - * @resolve {NetworkWatcherListResult} - The deserialized result object. + * @param {string} [securityRuleParameters.sourceAddressPrefix] The CIDR or + * source IP range. Asterix '*' can also be used to match all source IPs. + * Default tags such as 'VirtualNetwork', 'AzureLoadBalancer' and 'Internet' + * can also be used. If this is an ingress rule, specifies where network + * traffic originates from. * - * @reject {Error|ServiceError} - The error object. + * @param {array} [securityRuleParameters.sourceAddressPrefixes] The CIDR or + * source IP ranges. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {array} [securityRuleParameters.sourceApplicationSecurityGroups] The + * application security group specified as source. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {string} [securityRuleParameters.destinationAddressPrefix] The + * destination address prefix. CIDR or destination IP range. Asterix '*' can + * also be used to match all source IPs. Default tags such as 'VirtualNetwork', + * 'AzureLoadBalancer' and 'Internet' can also be used. * - * {NetworkWatcherListResult} [result] - The deserialized result object if an error did not occur. - * See {@link NetworkWatcherListResult} for more - * information. + * @param {array} [securityRuleParameters.destinationAddressPrefixes] The + * destination address prefixes. CIDR or destination IP ranges. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {array} [securityRuleParameters.destinationApplicationSecurityGroups] + * The application security group specified as destination. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAll(callback: ServiceCallback): void; - listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets the current network topology by resource group. + * @param {array} [securityRuleParameters.sourcePortRanges] The source port + * ranges. * - * @param {string} resourceGroupName The name of the resource group. + * @param {array} [securityRuleParameters.destinationPortRanges] The + * destination port ranges. * - * @param {string} networkWatcherName The name of the network watcher. + * @param {string} securityRuleParameters.access The network traffic is allowed + * or denied. Possible values are: 'Allow' and 'Deny'. Possible values include: + * 'Allow', 'Deny' * - * @param {object} parameters Parameters that define the representation of - * topology. + * @param {number} [securityRuleParameters.priority] The priority of the rule. + * The value can be between 100 and 4096. The priority number must be unique + * for each rule in the collection. The lower the priority number, the higher + * the priority of the rule. * - * @param {string} [parameters.targetResourceGroupName] The name of the target - * resource group to perform topology on. + * @param {string} securityRuleParameters.direction The direction of the rule. + * The direction specifies if rule will be evaluated on incoming or outcoming + * traffic. Possible values are: 'Inbound' and 'Outbound'. Possible values + * include: 'Inbound', 'Outbound' * - * @param {object} [parameters.targetVirtualNetwork] The reference of the - * Virtual Network resource. + * @param {string} [securityRuleParameters.provisioningState] The provisioning + * state of the public IP resource. Possible values are: 'Updating', + * 'Deleting', and 'Failed'. * - * @param {object} [parameters.targetSubnet] The reference of the Subnet + * @param {string} [securityRuleParameters.name] The name of the resource that + * is unique within a resource group. This name can be used to access the * resource. * - * @param {string} [parameters.targetSubnet.id] Resource ID. + * @param {string} [securityRuleParameters.etag] A unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [securityRuleParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -15166,153 +14759,95 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getTopologyWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.TopologyParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, securityRuleParameters: models.SecurityRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the current network topology by resource group. + * Creates or updates a security rule in the specified network security group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher. + * @param {string} networkSecurityGroupName The name of the network security + * group. * - * @param {object} parameters Parameters that define the representation of - * topology. + * @param {string} securityRuleName The name of the security rule. * - * @param {string} [parameters.targetResourceGroupName] The name of the target - * resource group to perform topology on. + * @param {object} securityRuleParameters Parameters supplied to the create or + * update network security rule operation. * - * @param {object} [parameters.targetVirtualNetwork] The reference of the - * Virtual Network resource. + * @param {string} [securityRuleParameters.description] A description for this + * rule. Restricted to 140 chars. * - * @param {object} [parameters.targetSubnet] The reference of the Subnet - * resource. + * @param {string} securityRuleParameters.protocol Network protocol this rule + * applies to. Possible values are 'Tcp', 'Udp', and '*'. Possible values + * include: 'Tcp', 'Udp', '*' * - * @param {string} [parameters.targetSubnet.id] Resource ID. + * @param {string} [securityRuleParameters.sourcePortRange] The source port or + * range. Integer or range between 0 and 65535. Asterix '*' can also be used to + * match all ports. * - * @param {object} [options] Optional Parameters. + * @param {string} [securityRuleParameters.destinationPortRange] The + * destination port or range. Integer or range between 0 and 65535. Asterix '*' + * can also be used to match all ports. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [securityRuleParameters.sourceAddressPrefix] The CIDR or + * source IP range. Asterix '*' can also be used to match all source IPs. + * Default tags such as 'VirtualNetwork', 'AzureLoadBalancer' and 'Internet' + * can also be used. If this is an ingress rule, specifies where network + * traffic originates from. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {array} [securityRuleParameters.sourceAddressPrefixes] The CIDR or + * source IP ranges. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {array} [securityRuleParameters.sourceApplicationSecurityGroups] The + * application security group specified as source. * - * {Promise} A promise is returned. + * @param {string} [securityRuleParameters.destinationAddressPrefix] The + * destination address prefix. CIDR or destination IP range. Asterix '*' can + * also be used to match all source IPs. Default tags such as 'VirtualNetwork', + * 'AzureLoadBalancer' and 'Internet' can also be used. * - * @resolve {Topology} - The deserialized result object. + * @param {array} [securityRuleParameters.destinationAddressPrefixes] The + * destination address prefixes. CIDR or destination IP ranges. * - * @reject {Error|ServiceError} - The error object. + * @param {array} [securityRuleParameters.destinationApplicationSecurityGroups] + * The application security group specified as destination. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {array} [securityRuleParameters.sourcePortRanges] The source port + * ranges. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {array} [securityRuleParameters.destinationPortRanges] The + * destination port ranges. * - * {Topology} [result] - The deserialized result object if an error did not occur. - * See {@link Topology} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - getTopology(resourceGroupName: string, networkWatcherName: string, parameters: models.TopologyParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getTopology(resourceGroupName: string, networkWatcherName: string, parameters: models.TopologyParameters, callback: ServiceCallback): void; - getTopology(resourceGroupName: string, networkWatcherName: string, parameters: models.TopologyParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Verify IP flow from the specified VM to a location given the currently - * configured NSG rules. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkWatcherName The name of the network watcher. - * - * @param {object} parameters Parameters that define the IP flow to be - * verified. - * - * @param {string} parameters.targetResourceId The ID of the target resource to - * perform next-hop on. - * - * @param {string} parameters.direction The direction of the packet represented - * as a 5-tuple. Possible values include: 'Inbound', 'Outbound' - * - * @param {string} parameters.protocol Protocol to be verified on. Possible - * values include: 'TCP', 'UDP' - * - * @param {string} parameters.localPort The local port. Acceptable values are a - * single integer in the range (0-65535). Support for * for the source port, - * which depends on the direction. - * - * @param {string} parameters.remotePort The remote port. Acceptable values are - * a single integer in the range (0-65535). Support for * for the source port, - * which depends on the direction. - * - * @param {string} parameters.localIPAddress The local IP address. Acceptable - * values are valid IPv4 addresses. - * - * @param {string} parameters.remoteIPAddress The remote IP address. Acceptable - * values are valid IPv4 addresses. - * - * @param {string} [parameters.targetNicResourceId] The NIC ID. (If VM has - * multiple NICs and IP forwarding is enabled on any of them, then this - * parameter must be specified. Otherwise optional). - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - verifyIPFlowWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.VerificationIPFlowParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Verify IP flow from the specified VM to a location given the currently - * configured NSG rules. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkWatcherName The name of the network watcher. - * - * @param {object} parameters Parameters that define the IP flow to be - * verified. - * - * @param {string} parameters.targetResourceId The ID of the target resource to - * perform next-hop on. - * - * @param {string} parameters.direction The direction of the packet represented - * as a 5-tuple. Possible values include: 'Inbound', 'Outbound' + * @param {string} securityRuleParameters.access The network traffic is allowed + * or denied. Possible values are: 'Allow' and 'Deny'. Possible values include: + * 'Allow', 'Deny' * - * @param {string} parameters.protocol Protocol to be verified on. Possible - * values include: 'TCP', 'UDP' + * @param {number} [securityRuleParameters.priority] The priority of the rule. + * The value can be between 100 and 4096. The priority number must be unique + * for each rule in the collection. The lower the priority number, the higher + * the priority of the rule. * - * @param {string} parameters.localPort The local port. Acceptable values are a - * single integer in the range (0-65535). Support for * for the source port, - * which depends on the direction. + * @param {string} securityRuleParameters.direction The direction of the rule. + * The direction specifies if rule will be evaluated on incoming or outcoming + * traffic. Possible values are: 'Inbound' and 'Outbound'. Possible values + * include: 'Inbound', 'Outbound' * - * @param {string} parameters.remotePort The remote port. Acceptable values are - * a single integer in the range (0-65535). Support for * for the source port, - * which depends on the direction. + * @param {string} [securityRuleParameters.provisioningState] The provisioning + * state of the public IP resource. Possible values are: 'Updating', + * 'Deleting', and 'Failed'. * - * @param {string} parameters.localIPAddress The local IP address. Acceptable - * values are valid IPv4 addresses. + * @param {string} [securityRuleParameters.name] The name of the resource that + * is unique within a resource group. This name can be used to access the + * resource. * - * @param {string} parameters.remoteIPAddress The remote IP address. Acceptable - * values are valid IPv4 addresses. + * @param {string} [securityRuleParameters.etag] A unique read-only string that + * changes whenever the resource is updated. * - * @param {string} [parameters.targetNicResourceId] The NIC ID. (If VM has - * multiple NICs and IP forwarding is enabled on any of them, then this - * parameter must be specified. Otherwise optional). + * @param {string} [securityRuleParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -15326,7 +14861,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {VerificationIPFlowResult} - The deserialized result object. + * @resolve {SecurityRule} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15334,39 +14869,25 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VerificationIPFlowResult} [result] - The deserialized result object if an error did not occur. - * See {@link VerificationIPFlowResult} for more - * information. + * {SecurityRule} [result] - The deserialized result object if an error did not occur. + * See {@link SecurityRule} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - verifyIPFlow(resourceGroupName: string, networkWatcherName: string, parameters: models.VerificationIPFlowParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - verifyIPFlow(resourceGroupName: string, networkWatcherName: string, parameters: models.VerificationIPFlowParameters, callback: ServiceCallback): void; - verifyIPFlow(resourceGroupName: string, networkWatcherName: string, parameters: models.VerificationIPFlowParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, securityRuleParameters: models.SecurityRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, securityRuleParameters: models.SecurityRule, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, securityRuleParameters: models.SecurityRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the next hop from the specified VM. + * Gets all security rules in a network security group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher. - * - * @param {object} parameters Parameters that define the source and destination - * endpoint. - * - * @param {string} parameters.targetResourceId The resource identifier of the - * target resource against which the action is to be performed. - * - * @param {string} parameters.sourceIPAddress The source IP address. - * - * @param {string} parameters.destinationIPAddress The destination IP address. - * - * @param {string} [parameters.targetNicResourceId] The NIC ID. (If VM has - * multiple NICs and IP forwarding is enabled on any of the nics, then this - * parameter must be specified. Otherwise optional). + * @param {string} networkSecurityGroupName The name of the network security + * group. * * @param {object} [options] Optional Parameters. * @@ -15375,32 +14896,19 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getNextHopWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.NextHopParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the next hop from the specified VM. + * Gets all security rules in a network security group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher. - * - * @param {object} parameters Parameters that define the source and destination - * endpoint. - * - * @param {string} parameters.targetResourceId The resource identifier of the - * target resource against which the action is to be performed. - * - * @param {string} parameters.sourceIPAddress The source IP address. - * - * @param {string} parameters.destinationIPAddress The destination IP address. - * - * @param {string} [parameters.targetNicResourceId] The NIC ID. (If VM has - * multiple NICs and IP forwarding is enabled on any of the nics, then this - * parameter must be specified. Otherwise optional). + * @param {string} networkSecurityGroupName The name of the network security + * group. * * @param {object} [options] Optional Parameters. * @@ -15414,7 +14922,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {NextHopResult} - The deserialized result object. + * @resolve {SecurityRuleListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15422,29 +14930,28 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NextHopResult} [result] - The deserialized result object if an error did not occur. - * See {@link NextHopResult} for more information. + * {SecurityRuleListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SecurityRuleListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getNextHop(resourceGroupName: string, networkWatcherName: string, parameters: models.NextHopParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getNextHop(resourceGroupName: string, networkWatcherName: string, parameters: models.NextHopParameters, callback: ServiceCallback): void; - getNextHop(resourceGroupName: string, networkWatcherName: string, parameters: models.NextHopParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, networkSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, networkSecurityGroupName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, networkSecurityGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the configured and effective security group rules on the specified VM. + * Deletes the specified network security rule. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher. - * - * @param {object} parameters Parameters that define the VM to check security - * groups for. + * @param {string} networkSecurityGroupName The name of the network security + * group. * - * @param {string} parameters.targetResourceId ID of the target VM. + * @param {string} securityRuleName The name of the security rule. * * @param {object} [options] Optional Parameters. * @@ -15453,23 +14960,21 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getVMSecurityRulesWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.SecurityGroupViewParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the configured and effective security group rules on the specified VM. + * Deletes the specified network security rule. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher. - * - * @param {object} parameters Parameters that define the VM to check security - * groups for. + * @param {string} networkSecurityGroupName The name of the network security + * group. * - * @param {string} parameters.targetResourceId ID of the target VM. + * @param {string} securityRuleName The name of the security rule. * * @param {object} [options] Optional Parameters. * @@ -15483,7 +14988,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {SecurityGroupViewResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15491,140 +14996,197 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SecurityGroupViewResult} [result] - The deserialized result object if an error did not occur. - * See {@link SecurityGroupViewResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getVMSecurityRules(resourceGroupName: string, networkWatcherName: string, parameters: models.SecurityGroupViewParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getVMSecurityRules(resourceGroupName: string, networkWatcherName: string, parameters: models.SecurityGroupViewParameters, callback: ServiceCallback): void; - getVMSecurityRules(resourceGroupName: string, networkWatcherName: string, parameters: models.SecurityGroupViewParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Initiate troubleshooting on a specified resource + * Creates or updates a security rule in the specified network security group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher resource. + * @param {string} networkSecurityGroupName The name of the network security + * group. * - * @param {object} parameters Parameters that define the resource to - * troubleshoot. + * @param {string} securityRuleName The name of the security rule. * - * @param {string} parameters.targetResourceId The target resource to - * troubleshoot. + * @param {object} securityRuleParameters Parameters supplied to the create or + * update network security rule operation. * - * @param {string} parameters.storageId The ID for the storage account to save - * the troubleshoot result. + * @param {string} [securityRuleParameters.description] A description for this + * rule. Restricted to 140 chars. * - * @param {string} parameters.storagePath The path to the blob to save the - * troubleshoot result in. + * @param {string} securityRuleParameters.protocol Network protocol this rule + * applies to. Possible values are 'Tcp', 'Udp', and '*'. Possible values + * include: 'Tcp', 'Udp', '*' * - * @param {object} [options] Optional Parameters. + * @param {string} [securityRuleParameters.sourcePortRange] The source port or + * range. Integer or range between 0 and 65535. Asterix '*' can also be used to + * match all ports. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [securityRuleParameters.destinationPortRange] The + * destination port or range. Integer or range between 0 and 65535. Asterix '*' + * can also be used to match all ports. * - * @returns {Promise} A promise is returned + * @param {string} [securityRuleParameters.sourceAddressPrefix] The CIDR or + * source IP range. Asterix '*' can also be used to match all source IPs. + * Default tags such as 'VirtualNetwork', 'AzureLoadBalancer' and 'Internet' + * can also be used. If this is an ingress rule, specifies where network + * traffic originates from. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {array} [securityRuleParameters.sourceAddressPrefixes] The CIDR or + * source IP ranges. * - * @reject {Error|ServiceError} - The error object. - */ - getTroubleshootingWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.TroubleshootingParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Initiate troubleshooting on a specified resource - * - * @param {string} resourceGroupName The name of the resource group. + * @param {array} [securityRuleParameters.sourceApplicationSecurityGroups] The + * application security group specified as source. * - * @param {string} networkWatcherName The name of the network watcher resource. + * @param {string} [securityRuleParameters.destinationAddressPrefix] The + * destination address prefix. CIDR or destination IP range. Asterix '*' can + * also be used to match all source IPs. Default tags such as 'VirtualNetwork', + * 'AzureLoadBalancer' and 'Internet' can also be used. * - * @param {object} parameters Parameters that define the resource to - * troubleshoot. + * @param {array} [securityRuleParameters.destinationAddressPrefixes] The + * destination address prefixes. CIDR or destination IP ranges. * - * @param {string} parameters.targetResourceId The target resource to - * troubleshoot. + * @param {array} [securityRuleParameters.destinationApplicationSecurityGroups] + * The application security group specified as destination. * - * @param {string} parameters.storageId The ID for the storage account to save - * the troubleshoot result. + * @param {array} [securityRuleParameters.sourcePortRanges] The source port + * ranges. * - * @param {string} parameters.storagePath The path to the blob to save the - * troubleshoot result in. + * @param {array} [securityRuleParameters.destinationPortRanges] The + * destination port ranges. * - * @param {object} [options] Optional Parameters. + * @param {string} securityRuleParameters.access The network traffic is allowed + * or denied. Possible values are: 'Allow' and 'Deny'. Possible values include: + * 'Allow', 'Deny' * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {number} [securityRuleParameters.priority] The priority of the rule. + * The value can be between 100 and 4096. The priority number must be unique + * for each rule in the collection. The lower the priority number, the higher + * the priority of the rule. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {string} securityRuleParameters.direction The direction of the rule. + * The direction specifies if rule will be evaluated on incoming or outcoming + * traffic. Possible values are: 'Inbound' and 'Outbound'. Possible values + * include: 'Inbound', 'Outbound' * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {string} [securityRuleParameters.provisioningState] The provisioning + * state of the public IP resource. Possible values are: 'Updating', + * 'Deleting', and 'Failed'. * - * {Promise} A promise is returned. + * @param {string} [securityRuleParameters.name] The name of the resource that + * is unique within a resource group. This name can be used to access the + * resource. * - * @resolve {TroubleshootingResult} - The deserialized result object. + * @param {string} [securityRuleParameters.etag] A unique read-only string that + * changes whenever the resource is updated. * - * @reject {Error|ServiceError} - The error object. + * @param {string} [securityRuleParameters.id] Resource ID. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {object} [options] Optional Parameters. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * {TroubleshootingResult} [result] - The deserialized result object if an error did not occur. - * See {@link TroubleshootingResult} for more information. + * @returns {Promise} A promise is returned * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + * @reject {Error|ServiceError} - The error object. */ - getTroubleshooting(resourceGroupName: string, networkWatcherName: string, parameters: models.TroubleshootingParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getTroubleshooting(resourceGroupName: string, networkWatcherName: string, parameters: models.TroubleshootingParameters, callback: ServiceCallback): void; - getTroubleshooting(resourceGroupName: string, networkWatcherName: string, parameters: models.TroubleshootingParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, securityRuleParameters: models.SecurityRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Get the last completed troubleshooting result on a specified resource + * Creates or updates a security rule in the specified network security group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher resource. + * @param {string} networkSecurityGroupName The name of the network security + * group. * - * @param {object} parameters Parameters that define the resource to query the - * troubleshooting result. + * @param {string} securityRuleName The name of the security rule. * - * @param {string} parameters.targetResourceId The target resource ID to query - * the troubleshooting result. + * @param {object} securityRuleParameters Parameters supplied to the create or + * update network security rule operation. * - * @param {object} [options] Optional Parameters. + * @param {string} [securityRuleParameters.description] A description for this + * rule. Restricted to 140 chars. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} securityRuleParameters.protocol Network protocol this rule + * applies to. Possible values are 'Tcp', 'Udp', and '*'. Possible values + * include: 'Tcp', 'Udp', '*' * - * @returns {Promise} A promise is returned + * @param {string} [securityRuleParameters.sourcePortRange] The source port or + * range. Integer or range between 0 and 65535. Asterix '*' can also be used to + * match all ports. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} [securityRuleParameters.destinationPortRange] The + * destination port or range. Integer or range between 0 and 65535. Asterix '*' + * can also be used to match all ports. * - * @reject {Error|ServiceError} - The error object. - */ - getTroubleshootingResultWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.QueryTroubleshootingParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Get the last completed troubleshooting result on a specified resource + * @param {string} [securityRuleParameters.sourceAddressPrefix] The CIDR or + * source IP range. Asterix '*' can also be used to match all source IPs. + * Default tags such as 'VirtualNetwork', 'AzureLoadBalancer' and 'Internet' + * can also be used. If this is an ingress rule, specifies where network + * traffic originates from. * - * @param {string} resourceGroupName The name of the resource group. + * @param {array} [securityRuleParameters.sourceAddressPrefixes] The CIDR or + * source IP ranges. * - * @param {string} networkWatcherName The name of the network watcher resource. + * @param {array} [securityRuleParameters.sourceApplicationSecurityGroups] The + * application security group specified as source. * - * @param {object} parameters Parameters that define the resource to query the - * troubleshooting result. + * @param {string} [securityRuleParameters.destinationAddressPrefix] The + * destination address prefix. CIDR or destination IP range. Asterix '*' can + * also be used to match all source IPs. Default tags such as 'VirtualNetwork', + * 'AzureLoadBalancer' and 'Internet' can also be used. * - * @param {string} parameters.targetResourceId The target resource ID to query - * the troubleshooting result. + * @param {array} [securityRuleParameters.destinationAddressPrefixes] The + * destination address prefixes. CIDR or destination IP ranges. + * + * @param {array} [securityRuleParameters.destinationApplicationSecurityGroups] + * The application security group specified as destination. + * + * @param {array} [securityRuleParameters.sourcePortRanges] The source port + * ranges. + * + * @param {array} [securityRuleParameters.destinationPortRanges] The + * destination port ranges. + * + * @param {string} securityRuleParameters.access The network traffic is allowed + * or denied. Possible values are: 'Allow' and 'Deny'. Possible values include: + * 'Allow', 'Deny' + * + * @param {number} [securityRuleParameters.priority] The priority of the rule. + * The value can be between 100 and 4096. The priority number must be unique + * for each rule in the collection. The lower the priority number, the higher + * the priority of the rule. + * + * @param {string} securityRuleParameters.direction The direction of the rule. + * The direction specifies if rule will be evaluated on incoming or outcoming + * traffic. Possible values are: 'Inbound' and 'Outbound'. Possible values + * include: 'Inbound', 'Outbound' + * + * @param {string} [securityRuleParameters.provisioningState] The provisioning + * state of the public IP resource. Possible values are: 'Updating', + * 'Deleting', and 'Failed'. + * + * @param {string} [securityRuleParameters.name] The name of the resource that + * is unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [securityRuleParameters.etag] A unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [securityRuleParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -15638,7 +15200,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {TroubleshootingResult} - The deserialized result object. + * @resolve {SecurityRule} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15646,44 +15208,23 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {TroubleshootingResult} [result] - The deserialized result object if an error did not occur. - * See {@link TroubleshootingResult} for more information. + * {SecurityRule} [result] - The deserialized result object if an error did not occur. + * See {@link SecurityRule} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getTroubleshootingResult(resourceGroupName: string, networkWatcherName: string, parameters: models.QueryTroubleshootingParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getTroubleshootingResult(resourceGroupName: string, networkWatcherName: string, parameters: models.QueryTroubleshootingParameters, callback: ServiceCallback): void; - getTroubleshootingResult(resourceGroupName: string, networkWatcherName: string, parameters: models.QueryTroubleshootingParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, securityRuleParameters: models.SecurityRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, securityRuleParameters: models.SecurityRule, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, networkSecurityGroupName: string, securityRuleName: string, securityRuleParameters: models.SecurityRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Configures flow log on a specified resource. - * - * @param {string} resourceGroupName The name of the network watcher resource - * group. - * - * @param {string} networkWatcherName The name of the network watcher resource. - * - * @param {object} parameters Parameters that define the configuration of flow - * log. - * - * @param {string} parameters.targetResourceId The ID of the resource to - * configure for flow logging. - * - * @param {string} parameters.storageId ID of the storage account which is used - * to store the flow log. - * - * @param {boolean} parameters.enabled Flag to enable/disable flow logging. - * - * @param {object} [parameters.retentionPolicy] - * - * @param {number} [parameters.retentionPolicy.days] Number of days to retain - * flow log records. + * Gets all security rules in a network security group. * - * @param {boolean} [parameters.retentionPolicy.enabled] Flag to enable/disable - * retention. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -15692,38 +15233,17 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - setFlowLogConfigurationWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogInformation, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Configures flow log on a specified resource. - * - * @param {string} resourceGroupName The name of the network watcher resource - * group. - * - * @param {string} networkWatcherName The name of the network watcher resource. - * - * @param {object} parameters Parameters that define the configuration of flow - * log. - * - * @param {string} parameters.targetResourceId The ID of the resource to - * configure for flow logging. - * - * @param {string} parameters.storageId ID of the storage account which is used - * to store the flow log. - * - * @param {boolean} parameters.enabled Flag to enable/disable flow logging. - * - * @param {object} [parameters.retentionPolicy] - * - * @param {number} [parameters.retentionPolicy.days] Number of days to retain - * flow log records. + * Gets all security rules in a network security group. * - * @param {boolean} [parameters.retentionPolicy.enabled] Flag to enable/disable - * retention. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -15737,7 +15257,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {FlowLogInformation} - The deserialized result object. + * @resolve {SecurityRuleListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15745,31 +15265,35 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {FlowLogInformation} [result] - The deserialized result object if an error did not occur. - * See {@link FlowLogInformation} for more information. + * {SecurityRuleListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SecurityRuleListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - setFlowLogConfiguration(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogInformation, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - setFlowLogConfiguration(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogInformation, callback: ServiceCallback): void; - setFlowLogConfiguration(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogInformation, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * DefaultSecurityRules + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface DefaultSecurityRules { /** - * Queries status of flow log on a specified resource. - * - * @param {string} resourceGroupName The name of the network watcher resource - * group. - * - * @param {string} networkWatcherName The name of the network watcher resource. + * Gets all default security rules in a network security group. * - * @param {object} parameters Parameters that define a resource to query flow - * log status. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} parameters.targetResourceId The target resource where - * getting the flow logging status. + * @param {string} networkSecurityGroupName The name of the network security + * group. * * @param {object} [options] Optional Parameters. * @@ -15778,25 +15302,19 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getFlowLogStatusWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogStatusParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Queries status of flow log on a specified resource. - * - * @param {string} resourceGroupName The name of the network watcher resource - * group. - * - * @param {string} networkWatcherName The name of the network watcher resource. + * Gets all default security rules in a network security group. * - * @param {object} parameters Parameters that define a resource to query flow - * log status. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} parameters.targetResourceId The target resource where - * getting the flow logging status. + * @param {string} networkSecurityGroupName The name of the network security + * group. * * @param {object} [options] Optional Parameters. * @@ -15810,7 +15328,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {FlowLogInformation} - The deserialized result object. + * @resolve {SecurityRuleListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15818,66 +15336,29 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {FlowLogInformation} [result] - The deserialized result object if an error did not occur. - * See {@link FlowLogInformation} for more information. + * {SecurityRuleListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SecurityRuleListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getFlowLogStatus(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogStatusParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getFlowLogStatus(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogStatusParameters, callback: ServiceCallback): void; - getFlowLogStatus(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogStatusParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, networkSecurityGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, networkSecurityGroupName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, networkSecurityGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Verifies the possibility of establishing a direct TCP connection from a - * virtual machine to a given endpoint including another VM or an arbitrary - * remote server. - * - * @param {string} resourceGroupName The name of the network watcher resource - * group. - * - * @param {string} networkWatcherName The name of the network watcher resource. - * - * @param {object} parameters Parameters that determine how the connectivity - * check will be performed. - * - * @param {object} parameters.source - * - * @param {string} parameters.source.resourceId The ID of the resource from - * which a connectivity check will be initiated. - * - * @param {number} [parameters.source.port] The source port from which a - * connectivity check will be performed. - * - * @param {object} parameters.destination - * - * @param {string} [parameters.destination.resourceId] The ID of the resource - * to which a connection attempt will be made. - * - * @param {string} [parameters.destination.address] The IP address or URI the - * resource to which a connection attempt will be made. - * - * @param {number} [parameters.destination.port] Port on which check - * connectivity will be performed. - * - * @param {string} [parameters.protocol] Network protocol. Possible values - * include: 'Tcp', 'Http', 'Https', 'Icmp' - * - * @param {object} [parameters.protocolConfiguration] - * - * @param {object} [parameters.protocolConfiguration.hTTPConfiguration] + * Get the specified default network security rule. * - * @param {string} [parameters.protocolConfiguration.hTTPConfiguration.method] - * HTTP method. Possible values include: 'Get' + * @param {string} resourceGroupName The name of the resource group. * - * @param {array} [parameters.protocolConfiguration.hTTPConfiguration.headers] - * List of HTTP headers. + * @param {string} networkSecurityGroupName The name of the network security + * group. * - * @param {array} - * [parameters.protocolConfiguration.hTTPConfiguration.validStatusCodes] Valid - * status codes. + * @param {string} defaultSecurityRuleName The name of the default security + * rule. * * @param {object} [options] Optional Parameters. * @@ -15886,60 +15367,22 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - checkConnectivityWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.ConnectivityParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, networkSecurityGroupName: string, defaultSecurityRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Verifies the possibility of establishing a direct TCP connection from a - * virtual machine to a given endpoint including another VM or an arbitrary - * remote server. - * - * @param {string} resourceGroupName The name of the network watcher resource - * group. - * - * @param {string} networkWatcherName The name of the network watcher resource. - * - * @param {object} parameters Parameters that determine how the connectivity - * check will be performed. - * - * @param {object} parameters.source - * - * @param {string} parameters.source.resourceId The ID of the resource from - * which a connectivity check will be initiated. - * - * @param {number} [parameters.source.port] The source port from which a - * connectivity check will be performed. - * - * @param {object} parameters.destination - * - * @param {string} [parameters.destination.resourceId] The ID of the resource - * to which a connection attempt will be made. - * - * @param {string} [parameters.destination.address] The IP address or URI the - * resource to which a connection attempt will be made. - * - * @param {number} [parameters.destination.port] Port on which check - * connectivity will be performed. - * - * @param {string} [parameters.protocol] Network protocol. Possible values - * include: 'Tcp', 'Http', 'Https', 'Icmp' - * - * @param {object} [parameters.protocolConfiguration] - * - * @param {object} [parameters.protocolConfiguration.hTTPConfiguration] + * Get the specified default network security rule. * - * @param {string} [parameters.protocolConfiguration.hTTPConfiguration.method] - * HTTP method. Possible values include: 'Get' + * @param {string} resourceGroupName The name of the resource group. * - * @param {array} [parameters.protocolConfiguration.hTTPConfiguration.headers] - * List of HTTP headers. + * @param {string} networkSecurityGroupName The name of the network security + * group. * - * @param {array} - * [parameters.protocolConfiguration.hTTPConfiguration.validStatusCodes] Valid - * status codes. + * @param {string} defaultSecurityRuleName The name of the default security + * rule. * * @param {object} [options] Optional Parameters. * @@ -15953,7 +15396,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {ConnectivityInformation} - The deserialized result object. + * @resolve {SecurityRule} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15961,50 +15404,23 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ConnectivityInformation} [result] - The deserialized result object if an error did not occur. - * See {@link ConnectivityInformation} for more - * information. + * {SecurityRule} [result] - The deserialized result object if an error did not occur. + * See {@link SecurityRule} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - checkConnectivity(resourceGroupName: string, networkWatcherName: string, parameters: models.ConnectivityParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - checkConnectivity(resourceGroupName: string, networkWatcherName: string, parameters: models.ConnectivityParameters, callback: ServiceCallback): void; - checkConnectivity(resourceGroupName: string, networkWatcherName: string, parameters: models.ConnectivityParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, networkSecurityGroupName: string, defaultSecurityRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, networkSecurityGroupName: string, defaultSecurityRuleName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, networkSecurityGroupName: string, defaultSecurityRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the relative latency score for internet service providers from a - * specified location to Azure regions. - * - * @param {string} resourceGroupName The name of the network watcher resource - * group. - * - * @param {string} networkWatcherName The name of the network watcher resource. - * - * @param {object} parameters Parameters that determine Azure reachability - * report configuration. - * - * @param {object} parameters.providerLocation - * - * @param {string} parameters.providerLocation.country The name of the country. - * - * @param {string} [parameters.providerLocation.state] The name of the state. - * - * @param {string} [parameters.providerLocation.city] The name of the city or - * town. - * - * @param {array} [parameters.providers] List of Internet service providers. - * - * @param {array} [parameters.azureLocations] Optional Azure regions to scope - * the query to. - * - * @param {date} parameters.startTime The start time for the Azure reachability - * report. + * Gets all default security rules in a network security group. * - * @param {date} parameters.endTime The end time for the Azure reachability - * report. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -16013,43 +15429,17 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getAzureReachabilityReportWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.AzureReachabilityReportParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the relative latency score for internet service providers from a - * specified location to Azure regions. - * - * @param {string} resourceGroupName The name of the network watcher resource - * group. - * - * @param {string} networkWatcherName The name of the network watcher resource. - * - * @param {object} parameters Parameters that determine Azure reachability - * report configuration. - * - * @param {object} parameters.providerLocation - * - * @param {string} parameters.providerLocation.country The name of the country. - * - * @param {string} [parameters.providerLocation.state] The name of the state. - * - * @param {string} [parameters.providerLocation.city] The name of the city or - * town. - * - * @param {array} [parameters.providers] List of Internet service providers. - * - * @param {array} [parameters.azureLocations] Optional Azure regions to scope - * the query to. - * - * @param {date} parameters.startTime The start time for the Azure reachability - * report. + * Gets all default security rules in a network security group. * - * @param {date} parameters.endTime The end time for the Azure reachability - * report. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -16063,7 +15453,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {AzureReachabilityReport} - The deserialized result object. + * @resolve {SecurityRuleListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16071,39 +15461,46 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {AzureReachabilityReport} [result] - The deserialized result object if an error did not occur. - * See {@link AzureReachabilityReport} for more + * {SecurityRuleListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SecurityRuleListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getAzureReachabilityReport(resourceGroupName: string, networkWatcherName: string, parameters: models.AzureReachabilityReportParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getAzureReachabilityReport(resourceGroupName: string, networkWatcherName: string, parameters: models.AzureReachabilityReportParameters, callback: ServiceCallback): void; - getAzureReachabilityReport(resourceGroupName: string, networkWatcherName: string, parameters: models.AzureReachabilityReportParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * NetworkWatchers + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface NetworkWatchers { /** - * Lists all available internet service providers for a specified Azure region. + * Creates or updates a network watcher in the specified resource group. * - * @param {string} resourceGroupName The name of the network watcher resource - * group. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher resource. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {object} parameters Parameters that scope the list of available - * providers. + * @param {object} parameters Parameters that define the network watcher + * resource. * - * @param {array} [parameters.azureLocations] A list of Azure regions. + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. * - * @param {string} [parameters.country] The country for available providers - * list. + * @param {string} [parameters.id] Resource ID. * - * @param {string} [parameters.state] The state for available providers list. + * @param {string} [parameters.location] Resource location. * - * @param {string} [parameters.city] The city or town for available providers - * list. + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -16112,32 +15509,30 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listAvailableProvidersWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.AvailableProvidersListParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.NetworkWatcher, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists all available internet service providers for a specified Azure region. + * Creates or updates a network watcher in the specified resource group. * - * @param {string} resourceGroupName The name of the network watcher resource - * group. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher resource. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {object} parameters Parameters that scope the list of available - * providers. + * @param {object} parameters Parameters that define the network watcher + * resource. * - * @param {array} [parameters.azureLocations] A list of Azure regions. + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. * - * @param {string} [parameters.country] The country for available providers - * list. + * @param {string} [parameters.id] Resource ID. * - * @param {string} [parameters.state] The state for available providers list. + * @param {string} [parameters.location] Resource location. * - * @param {string} [parameters.city] The city or town for available providers - * list. + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -16151,7 +15546,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {AvailableProvidersList} - The deserialized result object. + * @resolve {NetworkWatcher} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16159,21 +15554,20 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {AvailableProvidersList} [result] - The deserialized result object if an error did not occur. - * See {@link AvailableProvidersList} for more - * information. + * {NetworkWatcher} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkWatcher} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAvailableProviders(resourceGroupName: string, networkWatcherName: string, parameters: models.AvailableProvidersListParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAvailableProviders(resourceGroupName: string, networkWatcherName: string, parameters: models.AvailableProvidersListParameters, callback: ServiceCallback): void; - listAvailableProviders(resourceGroupName: string, networkWatcherName: string, parameters: models.AvailableProvidersListParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, networkWatcherName: string, parameters: models.NetworkWatcher, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, networkWatcherName: string, parameters: models.NetworkWatcher, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, networkWatcherName: string, parameters: models.NetworkWatcher, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified network watcher resource. + * Gets the specified network watcher by resource group. * * @param {string} resourceGroupName The name of the resource group. * @@ -16186,14 +15580,14 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified network watcher resource. + * Gets the specified network watcher by resource group. * * @param {string} resourceGroupName The name of the resource group. * @@ -16211,7 +15605,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {NetworkWatcher} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16219,55 +15613,25 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {NetworkWatcher} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkWatcher} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, networkWatcherName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, networkWatcherName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Verify IP flow from the specified VM to a location given the currently - * configured NSG rules. + * Deletes the specified network watcher resource. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the network watcher. * - * @param {object} parameters Parameters that define the IP flow to be - * verified. - * - * @param {string} parameters.targetResourceId The ID of the target resource to - * perform next-hop on. - * - * @param {string} parameters.direction The direction of the packet represented - * as a 5-tuple. Possible values include: 'Inbound', 'Outbound' - * - * @param {string} parameters.protocol Protocol to be verified on. Possible - * values include: 'TCP', 'UDP' - * - * @param {string} parameters.localPort The local port. Acceptable values are a - * single integer in the range (0-65535). Support for * for the source port, - * which depends on the direction. - * - * @param {string} parameters.remotePort The remote port. Acceptable values are - * a single integer in the range (0-65535). Support for * for the source port, - * which depends on the direction. - * - * @param {string} parameters.localIPAddress The local IP address. Acceptable - * values are valid IPv4 addresses. - * - * @param {string} parameters.remoteIPAddress The remote IP address. Acceptable - * values are valid IPv4 addresses. - * - * @param {string} [parameters.targetNicResourceId] The NIC ID. (If VM has - * multiple NICs and IP forwarding is enabled on any of them, then this - * parameter must be specified. Otherwise optional). - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -16275,50 +15639,19 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginVerifyIPFlowWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.VerificationIPFlowParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Verify IP flow from the specified VM to a location given the currently - * configured NSG rules. + * Deletes the specified network watcher resource. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the network watcher. * - * @param {object} parameters Parameters that define the IP flow to be - * verified. - * - * @param {string} parameters.targetResourceId The ID of the target resource to - * perform next-hop on. - * - * @param {string} parameters.direction The direction of the packet represented - * as a 5-tuple. Possible values include: 'Inbound', 'Outbound' - * - * @param {string} parameters.protocol Protocol to be verified on. Possible - * values include: 'TCP', 'UDP' - * - * @param {string} parameters.localPort The local port. Acceptable values are a - * single integer in the range (0-65535). Support for * for the source port, - * which depends on the direction. - * - * @param {string} parameters.remotePort The remote port. Acceptable values are - * a single integer in the range (0-65535). Support for * for the source port, - * which depends on the direction. - * - * @param {string} parameters.localIPAddress The local IP address. Acceptable - * values are valid IPv4 addresses. - * - * @param {string} parameters.remoteIPAddress The remote IP address. Acceptable - * values are valid IPv4 addresses. - * - * @param {string} [parameters.targetNicResourceId] The NIC ID. (If VM has - * multiple NICs and IP forwarding is enabled on any of them, then this - * parameter must be specified. Otherwise optional). - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -16331,7 +15664,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {VerificationIPFlowResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16339,39 +15672,28 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VerificationIPFlowResult} [result] - The deserialized result object if an error did not occur. - * See {@link VerificationIPFlowResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginVerifyIPFlow(resourceGroupName: string, networkWatcherName: string, parameters: models.VerificationIPFlowParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginVerifyIPFlow(resourceGroupName: string, networkWatcherName: string, parameters: models.VerificationIPFlowParameters, callback: ServiceCallback): void; - beginVerifyIPFlow(resourceGroupName: string, networkWatcherName: string, parameters: models.VerificationIPFlowParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, networkWatcherName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, networkWatcherName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the next hop from the specified VM. + * Updates a network watcher tags. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the network watcher. * - * @param {object} parameters Parameters that define the source and destination - * endpoint. - * - * @param {string} parameters.targetResourceId The resource identifier of the - * target resource against which the action is to be performed. - * - * @param {string} parameters.sourceIPAddress The source IP address. - * - * @param {string} parameters.destinationIPAddress The destination IP address. + * @param {object} parameters Parameters supplied to update network watcher + * tags. * - * @param {string} [parameters.targetNicResourceId] The NIC ID. (If VM has - * multiple NICs and IP forwarding is enabled on any of the nics, then this - * parameter must be specified. Otherwise optional). + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -16380,32 +15702,23 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginGetNextHopWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.NextHopParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateTagsWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the next hop from the specified VM. + * Updates a network watcher tags. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the network watcher. * - * @param {object} parameters Parameters that define the source and destination - * endpoint. - * - * @param {string} parameters.targetResourceId The resource identifier of the - * target resource against which the action is to be performed. - * - * @param {string} parameters.sourceIPAddress The source IP address. - * - * @param {string} parameters.destinationIPAddress The destination IP address. + * @param {object} parameters Parameters supplied to update network watcher + * tags. * - * @param {string} [parameters.targetNicResourceId] The NIC ID. (If VM has - * multiple NICs and IP forwarding is enabled on any of the nics, then this - * parameter must be specified. Otherwise optional). + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -16419,7 +15732,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {NextHopResult} - The deserialized result object. + * @resolve {NetworkWatcher} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16427,30 +15740,23 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {NextHopResult} [result] - The deserialized result object if an error did not occur. - * See {@link NextHopResult} for more information. + * {NetworkWatcher} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkWatcher} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginGetNextHop(resourceGroupName: string, networkWatcherName: string, parameters: models.NextHopParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginGetNextHop(resourceGroupName: string, networkWatcherName: string, parameters: models.NextHopParameters, callback: ServiceCallback): void; - beginGetNextHop(resourceGroupName: string, networkWatcherName: string, parameters: models.NextHopParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, networkWatcherName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, networkWatcherName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, networkWatcherName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the configured and effective security group rules on the specified VM. + * Gets all network watchers by resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher. - * - * @param {object} parameters Parameters that define the VM to check security - * groups for. - * - * @param {string} parameters.targetResourceId ID of the target VM. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -16458,24 +15764,17 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginGetVMSecurityRulesWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.SecurityGroupViewParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the configured and effective security group rules on the specified VM. + * Gets all network watchers by resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher. - * - * @param {object} parameters Parameters that define the VM to check security - * groups for. - * - * @param {string} parameters.targetResourceId ID of the target VM. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -16488,7 +15787,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {SecurityGroupViewResult} - The deserialized result object. + * @resolve {NetworkWatcherListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16496,37 +15795,21 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SecurityGroupViewResult} [result] - The deserialized result object if an error did not occur. - * See {@link SecurityGroupViewResult} for more + * {NetworkWatcherListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkWatcherListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginGetVMSecurityRules(resourceGroupName: string, networkWatcherName: string, parameters: models.SecurityGroupViewParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginGetVMSecurityRules(resourceGroupName: string, networkWatcherName: string, parameters: models.SecurityGroupViewParameters, callback: ServiceCallback): void; - beginGetVMSecurityRules(resourceGroupName: string, networkWatcherName: string, parameters: models.SecurityGroupViewParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Initiate troubleshooting on a specified resource - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkWatcherName The name of the network watcher resource. - * - * @param {object} parameters Parameters that define the resource to - * troubleshoot. - * - * @param {string} parameters.targetResourceId The target resource to - * troubleshoot. - * - * @param {string} parameters.storageId The ID for the storage account to save - * the troubleshoot result. - * - * @param {string} parameters.storagePath The path to the blob to save the - * troubleshoot result in. + * Gets all network watchers by subscription. * * @param {object} [options] Optional Parameters. * @@ -16535,30 +15818,14 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginGetTroubleshootingWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.TroubleshootingParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Initiate troubleshooting on a specified resource - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} networkWatcherName The name of the network watcher resource. - * - * @param {object} parameters Parameters that define the resource to - * troubleshoot. - * - * @param {string} parameters.targetResourceId The target resource to - * troubleshoot. - * - * @param {string} parameters.storageId The ID for the storage account to save - * the troubleshoot result. - * - * @param {string} parameters.storagePath The path to the blob to save the - * troubleshoot result in. + * Gets all network watchers by subscription. * * @param {object} [options] Optional Parameters. * @@ -16572,7 +15839,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {TroubleshootingResult} - The deserialized result object. + * @resolve {NetworkWatcherListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16580,30 +15847,39 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {TroubleshootingResult} [result] - The deserialized result object if an error did not occur. - * See {@link TroubleshootingResult} for more information. + * {NetworkWatcherListResult} [result] - The deserialized result object if an error did not occur. + * See {@link NetworkWatcherListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginGetTroubleshooting(resourceGroupName: string, networkWatcherName: string, parameters: models.TroubleshootingParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginGetTroubleshooting(resourceGroupName: string, networkWatcherName: string, parameters: models.TroubleshootingParameters, callback: ServiceCallback): void; - beginGetTroubleshooting(resourceGroupName: string, networkWatcherName: string, parameters: models.TroubleshootingParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAll(callback: ServiceCallback): void; + listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Get the last completed troubleshooting result on a specified resource + * Gets the current network topology by resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher resource. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {object} parameters Parameters that define the resource to query the - * troubleshooting result. + * @param {object} parameters Parameters that define the representation of + * topology. * - * @param {string} parameters.targetResourceId The target resource ID to query - * the troubleshooting result. + * @param {string} [parameters.targetResourceGroupName] The name of the target + * resource group to perform topology on. + * + * @param {object} [parameters.targetVirtualNetwork] The reference of the + * Virtual Network resource. + * + * @param {object} [parameters.targetSubnet] The reference of the Subnet + * resource. + * + * @param {string} [parameters.targetSubnet.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -16612,24 +15888,32 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginGetTroubleshootingResultWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.QueryTroubleshootingParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getTopologyWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.TopologyParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Get the last completed troubleshooting result on a specified resource + * Gets the current network topology by resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher resource. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {object} parameters Parameters that define the resource to query the - * troubleshooting result. + * @param {object} parameters Parameters that define the representation of + * topology. * - * @param {string} parameters.targetResourceId The target resource ID to query - * the troubleshooting result. + * @param {string} [parameters.targetResourceGroupName] The name of the target + * resource group to perform topology on. + * + * @param {object} [parameters.targetVirtualNetwork] The reference of the + * Virtual Network resource. + * + * @param {object} [parameters.targetSubnet] The reference of the Subnet + * resource. + * + * @param {string} [parameters.targetSubnet.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -16643,7 +15927,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {TroubleshootingResult} - The deserialized result object. + * @resolve {Topology} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16651,44 +15935,55 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {TroubleshootingResult} [result] - The deserialized result object if an error did not occur. - * See {@link TroubleshootingResult} for more information. + * {Topology} [result] - The deserialized result object if an error did not occur. + * See {@link Topology} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginGetTroubleshootingResult(resourceGroupName: string, networkWatcherName: string, parameters: models.QueryTroubleshootingParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginGetTroubleshootingResult(resourceGroupName: string, networkWatcherName: string, parameters: models.QueryTroubleshootingParameters, callback: ServiceCallback): void; - beginGetTroubleshootingResult(resourceGroupName: string, networkWatcherName: string, parameters: models.QueryTroubleshootingParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + getTopology(resourceGroupName: string, networkWatcherName: string, parameters: models.TopologyParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getTopology(resourceGroupName: string, networkWatcherName: string, parameters: models.TopologyParameters, callback: ServiceCallback): void; + getTopology(resourceGroupName: string, networkWatcherName: string, parameters: models.TopologyParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Configures flow log on a specified resource. + * Verify IP flow from the specified VM to a location given the currently + * configured NSG rules. * - * @param {string} resourceGroupName The name of the network watcher resource - * group. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher resource. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {object} parameters Parameters that define the configuration of flow - * log. + * @param {object} parameters Parameters that define the IP flow to be + * verified. * - * @param {string} parameters.targetResourceId The ID of the resource to - * configure for flow logging. + * @param {string} parameters.targetResourceId The ID of the target resource to + * perform next-hop on. * - * @param {string} parameters.storageId ID of the storage account which is used - * to store the flow log. + * @param {string} parameters.direction The direction of the packet represented + * as a 5-tuple. Possible values include: 'Inbound', 'Outbound' * - * @param {boolean} parameters.enabled Flag to enable/disable flow logging. + * @param {string} parameters.protocol Protocol to be verified on. Possible + * values include: 'TCP', 'UDP' * - * @param {object} [parameters.retentionPolicy] + * @param {string} parameters.localPort The local port. Acceptable values are a + * single integer in the range (0-65535). Support for * for the source port, + * which depends on the direction. * - * @param {number} [parameters.retentionPolicy.days] Number of days to retain - * flow log records. + * @param {string} parameters.remotePort The remote port. Acceptable values are + * a single integer in the range (0-65535). Support for * for the source port, + * which depends on the direction. * - * @param {boolean} [parameters.retentionPolicy.enabled] Flag to enable/disable - * retention. + * @param {string} parameters.localIPAddress The local IP address. Acceptable + * values are valid IPv4 addresses. + * + * @param {string} parameters.remoteIPAddress The remote IP address. Acceptable + * values are valid IPv4 addresses. + * + * @param {string} [parameters.targetNicResourceId] The NIC ID. (If VM has + * multiple NICs and IP forwarding is enabled on any of them, then this + * parameter must be specified. Otherwise optional). * * @param {object} [options] Optional Parameters. * @@ -16697,38 +15992,49 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginSetFlowLogConfigurationWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogInformation, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + verifyIPFlowWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.VerificationIPFlowParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Configures flow log on a specified resource. + * Verify IP flow from the specified VM to a location given the currently + * configured NSG rules. * - * @param {string} resourceGroupName The name of the network watcher resource - * group. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher resource. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {object} parameters Parameters that define the configuration of flow - * log. + * @param {object} parameters Parameters that define the IP flow to be + * verified. * - * @param {string} parameters.targetResourceId The ID of the resource to - * configure for flow logging. + * @param {string} parameters.targetResourceId The ID of the target resource to + * perform next-hop on. * - * @param {string} parameters.storageId ID of the storage account which is used - * to store the flow log. + * @param {string} parameters.direction The direction of the packet represented + * as a 5-tuple. Possible values include: 'Inbound', 'Outbound' * - * @param {boolean} parameters.enabled Flag to enable/disable flow logging. + * @param {string} parameters.protocol Protocol to be verified on. Possible + * values include: 'TCP', 'UDP' * - * @param {object} [parameters.retentionPolicy] + * @param {string} parameters.localPort The local port. Acceptable values are a + * single integer in the range (0-65535). Support for * for the source port, + * which depends on the direction. * - * @param {number} [parameters.retentionPolicy.days] Number of days to retain - * flow log records. + * @param {string} parameters.remotePort The remote port. Acceptable values are + * a single integer in the range (0-65535). Support for * for the source port, + * which depends on the direction. * - * @param {boolean} [parameters.retentionPolicy.enabled] Flag to enable/disable - * retention. + * @param {string} parameters.localIPAddress The local IP address. Acceptable + * values are valid IPv4 addresses. + * + * @param {string} parameters.remoteIPAddress The remote IP address. Acceptable + * values are valid IPv4 addresses. + * + * @param {string} [parameters.targetNicResourceId] The NIC ID. (If VM has + * multiple NICs and IP forwarding is enabled on any of them, then this + * parameter must be specified. Otherwise optional). * * @param {object} [options] Optional Parameters. * @@ -16742,7 +16048,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {FlowLogInformation} - The deserialized result object. + * @resolve {VerificationIPFlowResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16750,31 +16056,39 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {FlowLogInformation} [result] - The deserialized result object if an error did not occur. - * See {@link FlowLogInformation} for more information. + * {VerificationIPFlowResult} [result] - The deserialized result object if an error did not occur. + * See {@link VerificationIPFlowResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginSetFlowLogConfiguration(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogInformation, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginSetFlowLogConfiguration(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogInformation, callback: ServiceCallback): void; - beginSetFlowLogConfiguration(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogInformation, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + verifyIPFlow(resourceGroupName: string, networkWatcherName: string, parameters: models.VerificationIPFlowParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + verifyIPFlow(resourceGroupName: string, networkWatcherName: string, parameters: models.VerificationIPFlowParameters, callback: ServiceCallback): void; + verifyIPFlow(resourceGroupName: string, networkWatcherName: string, parameters: models.VerificationIPFlowParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Queries status of flow log on a specified resource. + * Gets the next hop from the specified VM. * - * @param {string} resourceGroupName The name of the network watcher resource - * group. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher resource. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {object} parameters Parameters that define a resource to query flow - * log status. + * @param {object} parameters Parameters that define the source and destination + * endpoint. * - * @param {string} parameters.targetResourceId The target resource where - * getting the flow logging status. + * @param {string} parameters.targetResourceId The resource identifier of the + * target resource against which the action is to be performed. + * + * @param {string} parameters.sourceIPAddress The source IP address. + * + * @param {string} parameters.destinationIPAddress The destination IP address. + * + * @param {string} [parameters.targetNicResourceId] The NIC ID. (If VM has + * multiple NICs and IP forwarding is enabled on any of the nics, then this + * parameter must be specified. Otherwise optional). * * @param {object} [options] Optional Parameters. * @@ -16783,25 +16097,32 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginGetFlowLogStatusWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogStatusParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getNextHopWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.NextHopParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Queries status of flow log on a specified resource. + * Gets the next hop from the specified VM. * - * @param {string} resourceGroupName The name of the network watcher resource - * group. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher resource. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {object} parameters Parameters that define a resource to query flow - * log status. + * @param {object} parameters Parameters that define the source and destination + * endpoint. * - * @param {string} parameters.targetResourceId The target resource where - * getting the flow logging status. + * @param {string} parameters.targetResourceId The resource identifier of the + * target resource against which the action is to be performed. + * + * @param {string} parameters.sourceIPAddress The source IP address. + * + * @param {string} parameters.destinationIPAddress The destination IP address. + * + * @param {string} [parameters.targetNicResourceId] The NIC ID. (If VM has + * multiple NICs and IP forwarding is enabled on any of the nics, then this + * parameter must be specified. Otherwise optional). * * @param {object} [options] Optional Parameters. * @@ -16815,7 +16136,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {FlowLogInformation} - The deserialized result object. + * @resolve {NextHopResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16823,66 +16144,29 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {FlowLogInformation} [result] - The deserialized result object if an error did not occur. - * See {@link FlowLogInformation} for more information. + * {NextHopResult} [result] - The deserialized result object if an error did not occur. + * See {@link NextHopResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginGetFlowLogStatus(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogStatusParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginGetFlowLogStatus(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogStatusParameters, callback: ServiceCallback): void; - beginGetFlowLogStatus(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogStatusParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + getNextHop(resourceGroupName: string, networkWatcherName: string, parameters: models.NextHopParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getNextHop(resourceGroupName: string, networkWatcherName: string, parameters: models.NextHopParameters, callback: ServiceCallback): void; + getNextHop(resourceGroupName: string, networkWatcherName: string, parameters: models.NextHopParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Verifies the possibility of establishing a direct TCP connection from a - * virtual machine to a given endpoint including another VM or an arbitrary - * remote server. + * Gets the configured and effective security group rules on the specified VM. * - * @param {string} resourceGroupName The name of the network watcher resource - * group. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the network watcher resource. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {object} parameters Parameters that determine how the connectivity - * check will be performed. + * @param {object} parameters Parameters that define the VM to check security + * groups for. * - * @param {object} parameters.source - * - * @param {string} parameters.source.resourceId The ID of the resource from - * which a connectivity check will be initiated. - * - * @param {number} [parameters.source.port] The source port from which a - * connectivity check will be performed. - * - * @param {object} parameters.destination - * - * @param {string} [parameters.destination.resourceId] The ID of the resource - * to which a connection attempt will be made. - * - * @param {string} [parameters.destination.address] The IP address or URI the - * resource to which a connection attempt will be made. - * - * @param {number} [parameters.destination.port] Port on which check - * connectivity will be performed. - * - * @param {string} [parameters.protocol] Network protocol. Possible values - * include: 'Tcp', 'Http', 'Https', 'Icmp' - * - * @param {object} [parameters.protocolConfiguration] - * - * @param {object} [parameters.protocolConfiguration.hTTPConfiguration] - * - * @param {string} [parameters.protocolConfiguration.hTTPConfiguration.method] - * HTTP method. Possible values include: 'Get' - * - * @param {array} [parameters.protocolConfiguration.hTTPConfiguration.headers] - * List of HTTP headers. - * - * @param {array} - * [parameters.protocolConfiguration.hTTPConfiguration.validStatusCodes] Valid - * status codes. + * @param {string} parameters.targetResourceId ID of the target VM. * * @param {object} [options] Optional Parameters. * @@ -16891,60 +16175,23 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCheckConnectivityWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.ConnectivityParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getVMSecurityRulesWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.SecurityGroupViewParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Verifies the possibility of establishing a direct TCP connection from a - * virtual machine to a given endpoint including another VM or an arbitrary - * remote server. - * - * @param {string} resourceGroupName The name of the network watcher resource - * group. - * - * @param {string} networkWatcherName The name of the network watcher resource. - * - * @param {object} parameters Parameters that determine how the connectivity - * check will be performed. - * - * @param {object} parameters.source - * - * @param {string} parameters.source.resourceId The ID of the resource from - * which a connectivity check will be initiated. - * - * @param {number} [parameters.source.port] The source port from which a - * connectivity check will be performed. - * - * @param {object} parameters.destination - * - * @param {string} [parameters.destination.resourceId] The ID of the resource - * to which a connection attempt will be made. - * - * @param {string} [parameters.destination.address] The IP address or URI the - * resource to which a connection attempt will be made. - * - * @param {number} [parameters.destination.port] Port on which check - * connectivity will be performed. - * - * @param {string} [parameters.protocol] Network protocol. Possible values - * include: 'Tcp', 'Http', 'Https', 'Icmp' - * - * @param {object} [parameters.protocolConfiguration] + * Gets the configured and effective security group rules on the specified VM. * - * @param {object} [parameters.protocolConfiguration.hTTPConfiguration] + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [parameters.protocolConfiguration.hTTPConfiguration.method] - * HTTP method. Possible values include: 'Get' + * @param {string} networkWatcherName The name of the network watcher. * - * @param {array} [parameters.protocolConfiguration.hTTPConfiguration.headers] - * List of HTTP headers. + * @param {object} parameters Parameters that define the VM to check security + * groups for. * - * @param {array} - * [parameters.protocolConfiguration.hTTPConfiguration.validStatusCodes] Valid - * status codes. + * @param {string} parameters.targetResourceId ID of the target VM. * * @param {object} [options] Optional Parameters. * @@ -16958,7 +16205,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {ConnectivityInformation} - The deserialized result object. + * @resolve {SecurityGroupViewResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16966,50 +16213,37 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ConnectivityInformation} [result] - The deserialized result object if an error did not occur. - * See {@link ConnectivityInformation} for more + * {SecurityGroupViewResult} [result] - The deserialized result object if an error did not occur. + * See {@link SecurityGroupViewResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCheckConnectivity(resourceGroupName: string, networkWatcherName: string, parameters: models.ConnectivityParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCheckConnectivity(resourceGroupName: string, networkWatcherName: string, parameters: models.ConnectivityParameters, callback: ServiceCallback): void; - beginCheckConnectivity(resourceGroupName: string, networkWatcherName: string, parameters: models.ConnectivityParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + getVMSecurityRules(resourceGroupName: string, networkWatcherName: string, parameters: models.SecurityGroupViewParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getVMSecurityRules(resourceGroupName: string, networkWatcherName: string, parameters: models.SecurityGroupViewParameters, callback: ServiceCallback): void; + getVMSecurityRules(resourceGroupName: string, networkWatcherName: string, parameters: models.SecurityGroupViewParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the relative latency score for internet service providers from a - * specified location to Azure regions. + * Initiate troubleshooting on a specified resource * - * @param {string} resourceGroupName The name of the network watcher resource - * group. + * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {object} parameters Parameters that determine Azure reachability - * report configuration. - * - * @param {object} parameters.providerLocation - * - * @param {string} parameters.providerLocation.country The name of the country. - * - * @param {string} [parameters.providerLocation.state] The name of the state. - * - * @param {string} [parameters.providerLocation.city] The name of the city or - * town. - * - * @param {array} [parameters.providers] List of Internet service providers. + * @param {object} parameters Parameters that define the resource to + * troubleshoot. * - * @param {array} [parameters.azureLocations] Optional Azure regions to scope - * the query to. + * @param {string} parameters.targetResourceId The target resource to + * troubleshoot. * - * @param {date} parameters.startTime The start time for the Azure reachability - * report. + * @param {string} parameters.storageId The ID for the storage account to save + * the troubleshoot result. * - * @param {date} parameters.endTime The end time for the Azure reachability - * report. + * @param {string} parameters.storagePath The path to the blob to save the + * troubleshoot result in. * * @param {object} [options] Optional Parameters. * @@ -17018,43 +16252,30 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginGetAzureReachabilityReportWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.AzureReachabilityReportParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getTroubleshootingWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.TroubleshootingParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the relative latency score for internet service providers from a - * specified location to Azure regions. + * Initiate troubleshooting on a specified resource * - * @param {string} resourceGroupName The name of the network watcher resource - * group. + * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {object} parameters Parameters that determine Azure reachability - * report configuration. - * - * @param {object} parameters.providerLocation - * - * @param {string} parameters.providerLocation.country The name of the country. - * - * @param {string} [parameters.providerLocation.state] The name of the state. - * - * @param {string} [parameters.providerLocation.city] The name of the city or - * town. - * - * @param {array} [parameters.providers] List of Internet service providers. + * @param {object} parameters Parameters that define the resource to + * troubleshoot. * - * @param {array} [parameters.azureLocations] Optional Azure regions to scope - * the query to. + * @param {string} parameters.targetResourceId The target resource to + * troubleshoot. * - * @param {date} parameters.startTime The start time for the Azure reachability - * report. + * @param {string} parameters.storageId The ID for the storage account to save + * the troubleshoot result. * - * @param {date} parameters.endTime The end time for the Azure reachability - * report. + * @param {string} parameters.storagePath The path to the blob to save the + * troubleshoot result in. * * @param {object} [options] Optional Parameters. * @@ -17068,7 +16289,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {AzureReachabilityReport} - The deserialized result object. + * @resolve {TroubleshootingResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17076,39 +16297,30 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {AzureReachabilityReport} [result] - The deserialized result object if an error did not occur. - * See {@link AzureReachabilityReport} for more - * information. + * {TroubleshootingResult} [result] - The deserialized result object if an error did not occur. + * See {@link TroubleshootingResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginGetAzureReachabilityReport(resourceGroupName: string, networkWatcherName: string, parameters: models.AzureReachabilityReportParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginGetAzureReachabilityReport(resourceGroupName: string, networkWatcherName: string, parameters: models.AzureReachabilityReportParameters, callback: ServiceCallback): void; - beginGetAzureReachabilityReport(resourceGroupName: string, networkWatcherName: string, parameters: models.AzureReachabilityReportParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + getTroubleshooting(resourceGroupName: string, networkWatcherName: string, parameters: models.TroubleshootingParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getTroubleshooting(resourceGroupName: string, networkWatcherName: string, parameters: models.TroubleshootingParameters, callback: ServiceCallback): void; + getTroubleshooting(resourceGroupName: string, networkWatcherName: string, parameters: models.TroubleshootingParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists all available internet service providers for a specified Azure region. + * Get the last completed troubleshooting result on a specified resource * - * @param {string} resourceGroupName The name of the network watcher resource - * group. + * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {object} parameters Parameters that scope the list of available - * providers. - * - * @param {array} [parameters.azureLocations] A list of Azure regions. - * - * @param {string} [parameters.country] The country for available providers - * list. - * - * @param {string} [parameters.state] The state for available providers list. + * @param {object} parameters Parameters that define the resource to query the + * troubleshooting result. * - * @param {string} [parameters.city] The city or town for available providers - * list. + * @param {string} parameters.targetResourceId The target resource ID to query + * the troubleshooting result. * * @param {object} [options] Optional Parameters. * @@ -17117,32 +16329,24 @@ export interface NetworkWatchers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginListAvailableProvidersWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.AvailableProvidersListParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getTroubleshootingResultWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.QueryTroubleshootingParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists all available internet service providers for a specified Azure region. + * Get the last completed troubleshooting result on a specified resource * - * @param {string} resourceGroupName The name of the network watcher resource - * group. + * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {object} parameters Parameters that scope the list of available - * providers. - * - * @param {array} [parameters.azureLocations] A list of Azure regions. - * - * @param {string} [parameters.country] The country for available providers - * list. - * - * @param {string} [parameters.state] The state for available providers list. + * @param {object} parameters Parameters that define the resource to query the + * troubleshooting result. * - * @param {string} [parameters.city] The city or town for available providers - * list. + * @param {string} parameters.targetResourceId The target resource ID to query + * the troubleshooting result. * * @param {object} [options] Optional Parameters. * @@ -17156,7 +16360,7 @@ export interface NetworkWatchers { * * {Promise} A promise is returned. * - * @resolve {AvailableProvidersList} - The deserialized result object. + * @resolve {TroubleshootingResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17164,68 +16368,66 @@ export interface NetworkWatchers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {AvailableProvidersList} [result] - The deserialized result object if an error did not occur. - * See {@link AvailableProvidersList} for more - * information. + * {TroubleshootingResult} [result] - The deserialized result object if an error did not occur. + * See {@link TroubleshootingResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginListAvailableProviders(resourceGroupName: string, networkWatcherName: string, parameters: models.AvailableProvidersListParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginListAvailableProviders(resourceGroupName: string, networkWatcherName: string, parameters: models.AvailableProvidersListParameters, callback: ServiceCallback): void; - beginListAvailableProviders(resourceGroupName: string, networkWatcherName: string, parameters: models.AvailableProvidersListParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * PacketCaptures - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface PacketCaptures { + getTroubleshootingResult(resourceGroupName: string, networkWatcherName: string, parameters: models.QueryTroubleshootingParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getTroubleshootingResult(resourceGroupName: string, networkWatcherName: string, parameters: models.QueryTroubleshootingParameters, callback: ServiceCallback): void; + getTroubleshootingResult(resourceGroupName: string, networkWatcherName: string, parameters: models.QueryTroubleshootingParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Create and start a packet capture on the specified VM. + * Configures flow log and traffic analytics (optional) on a specified + * resource. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the network watcher. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} packetCaptureName The name of the packet capture session. + * @param {object} parameters Parameters that define the configuration of flow + * log. * - * @param {object} parameters Parameters that define the create packet capture - * operation. + * @param {string} parameters.targetResourceId The ID of the resource to + * configure for flow log and traffic analytics (optional) . * - * @param {string} parameters.target The ID of the targeted resource, only VM - * is currently supported. + * @param {string} parameters.storageId ID of the storage account which is used + * to store the flow log. * - * @param {number} [parameters.bytesToCapturePerPacket] Number of bytes - * captured per packet, the remaining bytes are truncated. + * @param {boolean} parameters.enabled Flag to enable/disable flow logging. * - * @param {number} [parameters.totalBytesPerSession] Maximum size of the - * capture output. + * @param {object} [parameters.retentionPolicy] * - * @param {number} [parameters.timeLimitInSeconds] Maximum duration of the - * capture session in seconds. + * @param {number} [parameters.retentionPolicy.days] Number of days to retain + * flow log records. * - * @param {object} parameters.storageLocation + * @param {boolean} [parameters.retentionPolicy.enabled] Flag to enable/disable + * retention. * - * @param {string} [parameters.storageLocation.storageId] The ID of the storage - * account to save the packet capture session. Required if no local file path - * is provided. + * @param {object} [parameters.flowAnalyticsConfiguration] * - * @param {string} [parameters.storageLocation.storagePath] The URI of the - * storage path to save the packet capture. Must be a well-formed URI - * describing the location to save the packet capture. + * @param {object} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration * - * @param {string} [parameters.storageLocation.filePath] A valid local path on - * the targeting VM. Must include the name of the capture file (*.cap). For - * linux virtual machine it must start with /var/captures. Required if no - * storage ID is provided, otherwise optional. + * @param {boolean} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.enabled + * Flag to enable/disable traffic analytics. * - * @param {array} [parameters.filters] + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceId + * The resource guid of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceRegion + * The location of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceResourceId + * Resource Id of the attached workspace * * @param {object} [options] Optional Parameters. * @@ -17234,52 +16436,60 @@ export interface PacketCaptures { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, parameters: models.PacketCapture, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + setFlowLogConfigurationWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogInformation, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Create and start a packet capture on the specified VM. + * Configures flow log and traffic analytics (optional) on a specified + * resource. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the network watcher. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} packetCaptureName The name of the packet capture session. + * @param {object} parameters Parameters that define the configuration of flow + * log. * - * @param {object} parameters Parameters that define the create packet capture - * operation. + * @param {string} parameters.targetResourceId The ID of the resource to + * configure for flow log and traffic analytics (optional) . * - * @param {string} parameters.target The ID of the targeted resource, only VM - * is currently supported. + * @param {string} parameters.storageId ID of the storage account which is used + * to store the flow log. * - * @param {number} [parameters.bytesToCapturePerPacket] Number of bytes - * captured per packet, the remaining bytes are truncated. + * @param {boolean} parameters.enabled Flag to enable/disable flow logging. * - * @param {number} [parameters.totalBytesPerSession] Maximum size of the - * capture output. + * @param {object} [parameters.retentionPolicy] * - * @param {number} [parameters.timeLimitInSeconds] Maximum duration of the - * capture session in seconds. + * @param {number} [parameters.retentionPolicy.days] Number of days to retain + * flow log records. * - * @param {object} parameters.storageLocation + * @param {boolean} [parameters.retentionPolicy.enabled] Flag to enable/disable + * retention. * - * @param {string} [parameters.storageLocation.storageId] The ID of the storage - * account to save the packet capture session. Required if no local file path - * is provided. + * @param {object} [parameters.flowAnalyticsConfiguration] * - * @param {string} [parameters.storageLocation.storagePath] The URI of the - * storage path to save the packet capture. Must be a well-formed URI - * describing the location to save the packet capture. + * @param {object} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration * - * @param {string} [parameters.storageLocation.filePath] A valid local path on - * the targeting VM. Must include the name of the capture file (*.cap). For - * linux virtual machine it must start with /var/captures. Required if no - * storage ID is provided, otherwise optional. + * @param {boolean} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.enabled + * Flag to enable/disable traffic analytics. * - * @param {array} [parameters.filters] + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceId + * The resource guid of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceRegion + * The location of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceResourceId + * Resource Id of the attached workspace * * @param {object} [options] Optional Parameters. * @@ -17293,7 +16503,7 @@ export interface PacketCaptures { * * {Promise} A promise is returned. * - * @resolve {PacketCaptureResult} - The deserialized result object. + * @resolve {FlowLogInformation} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17301,26 +16511,32 @@ export interface PacketCaptures { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PacketCaptureResult} [result] - The deserialized result object if an error did not occur. - * See {@link PacketCaptureResult} for more information. + * {FlowLogInformation} [result] - The deserialized result object if an error did not occur. + * See {@link FlowLogInformation} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - create(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, parameters: models.PacketCapture, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - create(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, parameters: models.PacketCapture, callback: ServiceCallback): void; - create(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, parameters: models.PacketCapture, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + setFlowLogConfiguration(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogInformation, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + setFlowLogConfiguration(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogInformation, callback: ServiceCallback): void; + setFlowLogConfiguration(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogInformation, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a packet capture session by name. + * Queries status of flow log and traffic analytics (optional) on a specified + * resource. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the network watcher. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} packetCaptureName The name of the packet capture session. + * @param {object} parameters Parameters that define a resource to query flow + * log and traffic analytics (optional) status. + * + * @param {string} parameters.targetResourceId The target resource where + * getting the flow log and traffic analytics (optional) status. * * @param {object} [options] Optional Parameters. * @@ -17329,20 +16545,26 @@ export interface PacketCaptures { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getFlowLogStatusWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogStatusParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a packet capture session by name. + * Queries status of flow log and traffic analytics (optional) on a specified + * resource. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the network watcher. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} packetCaptureName The name of the packet capture session. + * @param {object} parameters Parameters that define a resource to query flow + * log and traffic analytics (optional) status. + * + * @param {string} parameters.targetResourceId The target resource where + * getting the flow log and traffic analytics (optional) status. * * @param {object} [options] Optional Parameters. * @@ -17356,7 +16578,7 @@ export interface PacketCaptures { * * {Promise} A promise is returned. * - * @resolve {PacketCaptureResult} - The deserialized result object. + * @resolve {FlowLogInformation} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17364,26 +16586,66 @@ export interface PacketCaptures { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PacketCaptureResult} [result] - The deserialized result object if an error did not occur. - * See {@link PacketCaptureResult} for more information. + * {FlowLogInformation} [result] - The deserialized result object if an error did not occur. + * See {@link FlowLogInformation} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + getFlowLogStatus(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogStatusParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getFlowLogStatus(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogStatusParameters, callback: ServiceCallback): void; + getFlowLogStatus(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogStatusParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified packet capture session. + * Verifies the possibility of establishing a direct TCP connection from a + * virtual machine to a given endpoint including another VM or an arbitrary + * remote server. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the network watcher. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} packetCaptureName The name of the packet capture session. + * @param {object} parameters Parameters that determine how the connectivity + * check will be performed. + * + * @param {object} parameters.source + * + * @param {string} parameters.source.resourceId The ID of the resource from + * which a connectivity check will be initiated. + * + * @param {number} [parameters.source.port] The source port from which a + * connectivity check will be performed. + * + * @param {object} parameters.destination + * + * @param {string} [parameters.destination.resourceId] The ID of the resource + * to which a connection attempt will be made. + * + * @param {string} [parameters.destination.address] The IP address or URI the + * resource to which a connection attempt will be made. + * + * @param {number} [parameters.destination.port] Port on which check + * connectivity will be performed. + * + * @param {string} [parameters.protocol] Network protocol. Possible values + * include: 'Tcp', 'Http', 'Https', 'Icmp' + * + * @param {object} [parameters.protocolConfiguration] + * + * @param {object} [parameters.protocolConfiguration.hTTPConfiguration] + * + * @param {string} [parameters.protocolConfiguration.hTTPConfiguration.method] + * HTTP method. Possible values include: 'Get' + * + * @param {array} [parameters.protocolConfiguration.hTTPConfiguration.headers] + * List of HTTP headers. + * + * @param {array} + * [parameters.protocolConfiguration.hTTPConfiguration.validStatusCodes] Valid + * status codes. * * @param {object} [options] Optional Parameters. * @@ -17392,20 +16654,60 @@ export interface PacketCaptures { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + checkConnectivityWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.ConnectivityParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified packet capture session. + * Verifies the possibility of establishing a direct TCP connection from a + * virtual machine to a given endpoint including another VM or an arbitrary + * remote server. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the network watcher. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} packetCaptureName The name of the packet capture session. + * @param {object} parameters Parameters that determine how the connectivity + * check will be performed. + * + * @param {object} parameters.source + * + * @param {string} parameters.source.resourceId The ID of the resource from + * which a connectivity check will be initiated. + * + * @param {number} [parameters.source.port] The source port from which a + * connectivity check will be performed. + * + * @param {object} parameters.destination + * + * @param {string} [parameters.destination.resourceId] The ID of the resource + * to which a connection attempt will be made. + * + * @param {string} [parameters.destination.address] The IP address or URI the + * resource to which a connection attempt will be made. + * + * @param {number} [parameters.destination.port] Port on which check + * connectivity will be performed. + * + * @param {string} [parameters.protocol] Network protocol. Possible values + * include: 'Tcp', 'Http', 'Https', 'Icmp' + * + * @param {object} [parameters.protocolConfiguration] + * + * @param {object} [parameters.protocolConfiguration.hTTPConfiguration] + * + * @param {string} [parameters.protocolConfiguration.hTTPConfiguration.method] + * HTTP method. Possible values include: 'Get' + * + * @param {array} [parameters.protocolConfiguration.hTTPConfiguration.headers] + * List of HTTP headers. + * + * @param {array} + * [parameters.protocolConfiguration.hTTPConfiguration.validStatusCodes] Valid + * status codes. * * @param {object} [options] Optional Parameters. * @@ -17419,7 +16721,7 @@ export interface PacketCaptures { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ConnectivityInformation} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17427,25 +16729,50 @@ export interface PacketCaptures { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ConnectivityInformation} [result] - The deserialized result object if an error did not occur. + * See {@link ConnectivityInformation} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + checkConnectivity(resourceGroupName: string, networkWatcherName: string, parameters: models.ConnectivityParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + checkConnectivity(resourceGroupName: string, networkWatcherName: string, parameters: models.ConnectivityParameters, callback: ServiceCallback): void; + checkConnectivity(resourceGroupName: string, networkWatcherName: string, parameters: models.ConnectivityParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Stops a specified packet capture session. + * Gets the relative latency score for internet service providers from a + * specified location to Azure regions. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the network watcher. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} packetCaptureName The name of the packet capture session. + * @param {object} parameters Parameters that determine Azure reachability + * report configuration. + * + * @param {object} parameters.providerLocation + * + * @param {string} parameters.providerLocation.country The name of the country. + * + * @param {string} [parameters.providerLocation.state] The name of the state. + * + * @param {string} [parameters.providerLocation.city] The name of the city or + * town. + * + * @param {array} [parameters.providers] List of Internet service providers. + * + * @param {array} [parameters.azureLocations] Optional Azure regions to scope + * the query to. + * + * @param {date} parameters.startTime The start time for the Azure reachability + * report. + * + * @param {date} parameters.endTime The end time for the Azure reachability + * report. * * @param {object} [options] Optional Parameters. * @@ -17454,20 +16781,43 @@ export interface PacketCaptures { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - stopWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getAzureReachabilityReportWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.AzureReachabilityReportParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Stops a specified packet capture session. + * Gets the relative latency score for internet service providers from a + * specified location to Azure regions. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the network watcher. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} packetCaptureName The name of the packet capture session. + * @param {object} parameters Parameters that determine Azure reachability + * report configuration. + * + * @param {object} parameters.providerLocation + * + * @param {string} parameters.providerLocation.country The name of the country. + * + * @param {string} [parameters.providerLocation.state] The name of the state. + * + * @param {string} [parameters.providerLocation.city] The name of the city or + * town. + * + * @param {array} [parameters.providers] List of Internet service providers. + * + * @param {array} [parameters.azureLocations] Optional Azure regions to scope + * the query to. + * + * @param {date} parameters.startTime The start time for the Azure reachability + * report. + * + * @param {date} parameters.endTime The end time for the Azure reachability + * report. * * @param {object} [options] Optional Parameters. * @@ -17481,7 +16831,7 @@ export interface PacketCaptures { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {AzureReachabilityReport} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17489,26 +16839,39 @@ export interface PacketCaptures { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {AzureReachabilityReport} [result] - The deserialized result object if an error did not occur. + * See {@link AzureReachabilityReport} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - stop(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - stop(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, callback: ServiceCallback): void; - stop(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + getAzureReachabilityReport(resourceGroupName: string, networkWatcherName: string, parameters: models.AzureReachabilityReportParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getAzureReachabilityReport(resourceGroupName: string, networkWatcherName: string, parameters: models.AzureReachabilityReportParameters, callback: ServiceCallback): void; + getAzureReachabilityReport(resourceGroupName: string, networkWatcherName: string, parameters: models.AzureReachabilityReportParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Query the status of a running packet capture session. + * Lists all available internet service providers for a specified Azure region. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} packetCaptureName The name given to the packet capture - * session. + * @param {object} parameters Parameters that scope the list of available + * providers. + * + * @param {array} [parameters.azureLocations] A list of Azure regions. + * + * @param {string} [parameters.country] The country for available providers + * list. + * + * @param {string} [parameters.state] The state for available providers list. + * + * @param {string} [parameters.city] The city or town for available providers + * list. * * @param {object} [options] Optional Parameters. * @@ -17517,21 +16880,32 @@ export interface PacketCaptures { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getStatusWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAvailableProvidersWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.AvailableProvidersListParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Query the status of a running packet capture session. + * Lists all available internet service providers for a specified Azure region. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} packetCaptureName The name given to the packet capture - * session. + * @param {object} parameters Parameters that scope the list of available + * providers. + * + * @param {array} [parameters.azureLocations] A list of Azure regions. + * + * @param {string} [parameters.country] The country for available providers + * list. + * + * @param {string} [parameters.state] The state for available providers list. + * + * @param {string} [parameters.city] The city or town for available providers + * list. * * @param {object} [options] Optional Parameters. * @@ -17545,7 +16919,7 @@ export interface PacketCaptures { * * {Promise} A promise is returned. * - * @resolve {PacketCaptureQueryStatusResult} - The deserialized result object. + * @resolve {AvailableProvidersList} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17553,25 +16927,25 @@ export interface PacketCaptures { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PacketCaptureQueryStatusResult} [result] - The deserialized result object if an error did not occur. - * See {@link PacketCaptureQueryStatusResult} for more + * {AvailableProvidersList} [result] - The deserialized result object if an error did not occur. + * See {@link AvailableProvidersList} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getStatus(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getStatus(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, callback: ServiceCallback): void; - getStatus(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAvailableProviders(resourceGroupName: string, networkWatcherName: string, parameters: models.AvailableProvidersListParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAvailableProviders(resourceGroupName: string, networkWatcherName: string, parameters: models.AvailableProvidersListParameters, callback: ServiceCallback): void; + listAvailableProviders(resourceGroupName: string, networkWatcherName: string, parameters: models.AvailableProvidersListParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists all packet capture sessions within the specified resource group. + * Deletes the specified network watcher resource. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher. * * @param {object} [options] Optional Parameters. * @@ -17580,18 +16954,18 @@ export interface PacketCaptures { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists all packet capture sessions within the specified resource group. + * Deletes the specified network watcher resource. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher. * * @param {object} [options] Optional Parameters. * @@ -17605,7 +16979,7 @@ export interface PacketCaptures { * * {Promise} A promise is returned. * - * @resolve {PacketCaptureListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17613,59 +16987,54 @@ export interface PacketCaptures { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PacketCaptureListResult} [result] - The deserialized result object if an error did not occur. - * See {@link PacketCaptureListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, networkWatcherName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, networkWatcherName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Create and start a packet capture on the specified VM. + * Verify IP flow from the specified VM to a location given the currently + * configured NSG rules. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the network watcher. * - * @param {string} packetCaptureName The name of the packet capture session. - * - * @param {object} parameters Parameters that define the create packet capture - * operation. - * - * @param {string} parameters.target The ID of the targeted resource, only VM - * is currently supported. + * @param {object} parameters Parameters that define the IP flow to be + * verified. * - * @param {number} [parameters.bytesToCapturePerPacket] Number of bytes - * captured per packet, the remaining bytes are truncated. + * @param {string} parameters.targetResourceId The ID of the target resource to + * perform next-hop on. * - * @param {number} [parameters.totalBytesPerSession] Maximum size of the - * capture output. + * @param {string} parameters.direction The direction of the packet represented + * as a 5-tuple. Possible values include: 'Inbound', 'Outbound' * - * @param {number} [parameters.timeLimitInSeconds] Maximum duration of the - * capture session in seconds. + * @param {string} parameters.protocol Protocol to be verified on. Possible + * values include: 'TCP', 'UDP' * - * @param {object} parameters.storageLocation + * @param {string} parameters.localPort The local port. Acceptable values are a + * single integer in the range (0-65535). Support for * for the source port, + * which depends on the direction. * - * @param {string} [parameters.storageLocation.storageId] The ID of the storage - * account to save the packet capture session. Required if no local file path - * is provided. + * @param {string} parameters.remotePort The remote port. Acceptable values are + * a single integer in the range (0-65535). Support for * for the source port, + * which depends on the direction. * - * @param {string} [parameters.storageLocation.storagePath] The URI of the - * storage path to save the packet capture. Must be a well-formed URI - * describing the location to save the packet capture. + * @param {string} parameters.localIPAddress The local IP address. Acceptable + * values are valid IPv4 addresses. * - * @param {string} [parameters.storageLocation.filePath] A valid local path on - * the targeting VM. Must include the name of the capture file (*.cap). For - * linux virtual machine it must start with /var/captures. Required if no - * storage ID is provided, otherwise optional. + * @param {string} parameters.remoteIPAddress The remote IP address. Acceptable + * values are valid IPv4 addresses. * - * @param {array} [parameters.filters] + * @param {string} [parameters.targetNicResourceId] The NIC ID. (If VM has + * multiple NICs and IP forwarding is enabled on any of them, then this + * parameter must be specified. Otherwise optional). * * @param {object} [options] Optional Parameters. * @@ -17674,52 +17043,49 @@ export interface PacketCaptures { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, parameters: models.PacketCapture, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginVerifyIPFlowWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.VerificationIPFlowParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Create and start a packet capture on the specified VM. + * Verify IP flow from the specified VM to a location given the currently + * configured NSG rules. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the network watcher. * - * @param {string} packetCaptureName The name of the packet capture session. + * @param {object} parameters Parameters that define the IP flow to be + * verified. * - * @param {object} parameters Parameters that define the create packet capture - * operation. + * @param {string} parameters.targetResourceId The ID of the target resource to + * perform next-hop on. * - * @param {string} parameters.target The ID of the targeted resource, only VM - * is currently supported. + * @param {string} parameters.direction The direction of the packet represented + * as a 5-tuple. Possible values include: 'Inbound', 'Outbound' * - * @param {number} [parameters.bytesToCapturePerPacket] Number of bytes - * captured per packet, the remaining bytes are truncated. + * @param {string} parameters.protocol Protocol to be verified on. Possible + * values include: 'TCP', 'UDP' * - * @param {number} [parameters.totalBytesPerSession] Maximum size of the - * capture output. + * @param {string} parameters.localPort The local port. Acceptable values are a + * single integer in the range (0-65535). Support for * for the source port, + * which depends on the direction. * - * @param {number} [parameters.timeLimitInSeconds] Maximum duration of the - * capture session in seconds. + * @param {string} parameters.remotePort The remote port. Acceptable values are + * a single integer in the range (0-65535). Support for * for the source port, + * which depends on the direction. * - * @param {object} parameters.storageLocation + * @param {string} parameters.localIPAddress The local IP address. Acceptable + * values are valid IPv4 addresses. * - * @param {string} [parameters.storageLocation.storageId] The ID of the storage - * account to save the packet capture session. Required if no local file path - * is provided. + * @param {string} parameters.remoteIPAddress The remote IP address. Acceptable + * values are valid IPv4 addresses. * - * @param {string} [parameters.storageLocation.storagePath] The URI of the - * storage path to save the packet capture. Must be a well-formed URI - * describing the location to save the packet capture. - * - * @param {string} [parameters.storageLocation.filePath] A valid local path on - * the targeting VM. Must include the name of the capture file (*.cap). For - * linux virtual machine it must start with /var/captures. Required if no - * storage ID is provided, otherwise optional. - * - * @param {array} [parameters.filters] + * @param {string} [parameters.targetNicResourceId] The NIC ID. (If VM has + * multiple NICs and IP forwarding is enabled on any of them, then this + * parameter must be specified. Otherwise optional). * * @param {object} [options] Optional Parameters. * @@ -17733,7 +17099,7 @@ export interface PacketCaptures { * * {Promise} A promise is returned. * - * @resolve {PacketCaptureResult} - The deserialized result object. + * @resolve {VerificationIPFlowResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17741,26 +17107,39 @@ export interface PacketCaptures { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PacketCaptureResult} [result] - The deserialized result object if an error did not occur. - * See {@link PacketCaptureResult} for more information. + * {VerificationIPFlowResult} [result] - The deserialized result object if an error did not occur. + * See {@link VerificationIPFlowResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreate(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, parameters: models.PacketCapture, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreate(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, parameters: models.PacketCapture, callback: ServiceCallback): void; - beginCreate(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, parameters: models.PacketCapture, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginVerifyIPFlow(resourceGroupName: string, networkWatcherName: string, parameters: models.VerificationIPFlowParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginVerifyIPFlow(resourceGroupName: string, networkWatcherName: string, parameters: models.VerificationIPFlowParameters, callback: ServiceCallback): void; + beginVerifyIPFlow(resourceGroupName: string, networkWatcherName: string, parameters: models.VerificationIPFlowParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified packet capture session. + * Gets the next hop from the specified VM. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the network watcher. * - * @param {string} packetCaptureName The name of the packet capture session. + * @param {object} parameters Parameters that define the source and destination + * endpoint. + * + * @param {string} parameters.targetResourceId The resource identifier of the + * target resource against which the action is to be performed. + * + * @param {string} parameters.sourceIPAddress The source IP address. + * + * @param {string} parameters.destinationIPAddress The destination IP address. + * + * @param {string} [parameters.targetNicResourceId] The NIC ID. (If VM has + * multiple NICs and IP forwarding is enabled on any of the nics, then this + * parameter must be specified. Otherwise optional). * * @param {object} [options] Optional Parameters. * @@ -17769,20 +17148,32 @@ export interface PacketCaptures { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginGetNextHopWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.NextHopParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified packet capture session. + * Gets the next hop from the specified VM. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the network watcher. * - * @param {string} packetCaptureName The name of the packet capture session. + * @param {object} parameters Parameters that define the source and destination + * endpoint. + * + * @param {string} parameters.targetResourceId The resource identifier of the + * target resource against which the action is to be performed. + * + * @param {string} parameters.sourceIPAddress The source IP address. + * + * @param {string} parameters.destinationIPAddress The destination IP address. + * + * @param {string} [parameters.targetNicResourceId] The NIC ID. (If VM has + * multiple NICs and IP forwarding is enabled on any of the nics, then this + * parameter must be specified. Otherwise optional). * * @param {object} [options] Optional Parameters. * @@ -17796,7 +17187,7 @@ export interface PacketCaptures { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {NextHopResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17804,25 +17195,29 @@ export interface PacketCaptures { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {NextHopResult} [result] - The deserialized result object if an error did not occur. + * See {@link NextHopResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginGetNextHop(resourceGroupName: string, networkWatcherName: string, parameters: models.NextHopParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginGetNextHop(resourceGroupName: string, networkWatcherName: string, parameters: models.NextHopParameters, callback: ServiceCallback): void; + beginGetNextHop(resourceGroupName: string, networkWatcherName: string, parameters: models.NextHopParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Stops a specified packet capture session. + * Gets the configured and effective security group rules on the specified VM. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the network watcher. * - * @param {string} packetCaptureName The name of the packet capture session. + * @param {object} parameters Parameters that define the VM to check security + * groups for. + * + * @param {string} parameters.targetResourceId ID of the target VM. * * @param {object} [options] Optional Parameters. * @@ -17831,20 +17226,23 @@ export interface PacketCaptures { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginStopWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginGetVMSecurityRulesWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.SecurityGroupViewParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Stops a specified packet capture session. + * Gets the configured and effective security group rules on the specified VM. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the network watcher. * - * @param {string} packetCaptureName The name of the packet capture session. + * @param {object} parameters Parameters that define the VM to check security + * groups for. + * + * @param {string} parameters.targetResourceId ID of the target VM. * * @param {object} [options] Optional Parameters. * @@ -17858,7 +17256,7 @@ export interface PacketCaptures { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {SecurityGroupViewResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17866,26 +17264,37 @@ export interface PacketCaptures { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {SecurityGroupViewResult} [result] - The deserialized result object if an error did not occur. + * See {@link SecurityGroupViewResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginStop(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginStop(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, callback: ServiceCallback): void; - beginStop(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginGetVMSecurityRules(resourceGroupName: string, networkWatcherName: string, parameters: models.SecurityGroupViewParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginGetVMSecurityRules(resourceGroupName: string, networkWatcherName: string, parameters: models.SecurityGroupViewParameters, callback: ServiceCallback): void; + beginGetVMSecurityRules(resourceGroupName: string, networkWatcherName: string, parameters: models.SecurityGroupViewParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Query the status of a running packet capture session. + * Initiate troubleshooting on a specified resource * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} packetCaptureName The name given to the packet capture - * session. + * @param {object} parameters Parameters that define the resource to + * troubleshoot. + * + * @param {string} parameters.targetResourceId The target resource to + * troubleshoot. + * + * @param {string} parameters.storageId The ID for the storage account to save + * the troubleshoot result. + * + * @param {string} parameters.storagePath The path to the blob to save the + * troubleshoot result in. * * @param {object} [options] Optional Parameters. * @@ -17894,21 +17303,30 @@ export interface PacketCaptures { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginGetStatusWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginGetTroubleshootingWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.TroubleshootingParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Query the status of a running packet capture session. + * Initiate troubleshooting on a specified resource * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} packetCaptureName The name given to the packet capture - * session. + * @param {object} parameters Parameters that define the resource to + * troubleshoot. + * + * @param {string} parameters.targetResourceId The target resource to + * troubleshoot. + * + * @param {string} parameters.storageId The ID for the storage account to save + * the troubleshoot result. + * + * @param {string} parameters.storagePath The path to the blob to save the + * troubleshoot result in. * * @param {object} [options] Optional Parameters. * @@ -17922,7 +17340,7 @@ export interface PacketCaptures { * * {Promise} A promise is returned. * - * @resolve {PacketCaptureQueryStatusResult} - The deserialized result object. + * @resolve {TroubleshootingResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17930,69 +17348,30 @@ export interface PacketCaptures { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PacketCaptureQueryStatusResult} [result] - The deserialized result object if an error did not occur. - * See {@link PacketCaptureQueryStatusResult} for more - * information. + * {TroubleshootingResult} [result] - The deserialized result object if an error did not occur. + * See {@link TroubleshootingResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginGetStatus(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginGetStatus(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, callback: ServiceCallback): void; - beginGetStatus(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * ConnectionMonitors - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface ConnectionMonitors { + beginGetTroubleshooting(resourceGroupName: string, networkWatcherName: string, parameters: models.TroubleshootingParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginGetTroubleshooting(resourceGroupName: string, networkWatcherName: string, parameters: models.TroubleshootingParameters, callback: ServiceCallback): void; + beginGetTroubleshooting(resourceGroupName: string, networkWatcherName: string, parameters: models.TroubleshootingParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Create or update a connection monitor. - * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. - * - * @param {string} networkWatcherName The name of the Network Watcher resource. - * - * @param {string} connectionMonitorName The name of the connection monitor. - * - * @param {object} parameters Parameters that define the operation to create a - * connection monitor. - * - * @param {string} [parameters.location] Connection monitor location. - * - * @param {object} [parameters.tags] Connection monitor tags. - * - * @param {object} parameters.source - * - * @param {string} parameters.source.resourceId The ID of the resource used as - * the source by connection monitor. - * - * @param {number} [parameters.source.port] The source port used by connection - * monitor. - * - * @param {object} parameters.destination - * - * @param {string} [parameters.destination.resourceId] The ID of the resource - * used as the destination by connection monitor. + * Get the last completed troubleshooting result on a specified resource * - * @param {string} [parameters.destination.address] Address of the connection - * monitor destination (IP or domain name). + * @param {string} resourceGroupName The name of the resource group. * - * @param {number} [parameters.destination.port] The destination port used by - * connection monitor. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {boolean} [parameters.autoStart] Determines if the connection monitor - * will start automatically once created. + * @param {object} parameters Parameters that define the resource to query the + * troubleshooting result. * - * @param {number} [parameters.monitoringIntervalInSeconds] Monitoring interval - * in seconds. + * @param {string} parameters.targetResourceId The target resource ID to query + * the troubleshooting result. * * @param {object} [options] Optional Parameters. * @@ -18001,53 +17380,24 @@ export interface ConnectionMonitors { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, parameters: models.ConnectionMonitor, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginGetTroubleshootingResultWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.QueryTroubleshootingParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Create or update a connection monitor. - * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. - * - * @param {string} networkWatcherName The name of the Network Watcher resource. - * - * @param {string} connectionMonitorName The name of the connection monitor. - * - * @param {object} parameters Parameters that define the operation to create a - * connection monitor. - * - * @param {string} [parameters.location] Connection monitor location. - * - * @param {object} [parameters.tags] Connection monitor tags. - * - * @param {object} parameters.source - * - * @param {string} parameters.source.resourceId The ID of the resource used as - * the source by connection monitor. - * - * @param {number} [parameters.source.port] The source port used by connection - * monitor. - * - * @param {object} parameters.destination - * - * @param {string} [parameters.destination.resourceId] The ID of the resource - * used as the destination by connection monitor. + * Get the last completed troubleshooting result on a specified resource * - * @param {string} [parameters.destination.address] Address of the connection - * monitor destination (IP or domain name). + * @param {string} resourceGroupName The name of the resource group. * - * @param {number} [parameters.destination.port] The destination port used by - * connection monitor. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {boolean} [parameters.autoStart] Determines if the connection monitor - * will start automatically once created. + * @param {object} parameters Parameters that define the resource to query the + * troubleshooting result. * - * @param {number} [parameters.monitoringIntervalInSeconds] Monitoring interval - * in seconds. + * @param {string} parameters.targetResourceId The target resource ID to query + * the troubleshooting result. * * @param {object} [options] Optional Parameters. * @@ -18061,7 +17411,7 @@ export interface ConnectionMonitors { * * {Promise} A promise is returned. * - * @resolve {ConnectionMonitorResult} - The deserialized result object. + * @resolve {TroubleshootingResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18069,28 +17419,66 @@ export interface ConnectionMonitors { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ConnectionMonitorResult} [result] - The deserialized result object if an error did not occur. - * See {@link ConnectionMonitorResult} for more - * information. + * {TroubleshootingResult} [result] - The deserialized result object if an error did not occur. + * See {@link TroubleshootingResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, parameters: models.ConnectionMonitor, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, parameters: models.ConnectionMonitor, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, parameters: models.ConnectionMonitor, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginGetTroubleshootingResult(resourceGroupName: string, networkWatcherName: string, parameters: models.QueryTroubleshootingParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginGetTroubleshootingResult(resourceGroupName: string, networkWatcherName: string, parameters: models.QueryTroubleshootingParameters, callback: ServiceCallback): void; + beginGetTroubleshootingResult(resourceGroupName: string, networkWatcherName: string, parameters: models.QueryTroubleshootingParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a connection monitor by name. + * Configures flow log and traffic analytics (optional) on a specified + * resource. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} connectionMonitorName The name of the connection monitor. + * @param {object} parameters Parameters that define the configuration of flow + * log. + * + * @param {string} parameters.targetResourceId The ID of the resource to + * configure for flow log and traffic analytics (optional) . + * + * @param {string} parameters.storageId ID of the storage account which is used + * to store the flow log. + * + * @param {boolean} parameters.enabled Flag to enable/disable flow logging. + * + * @param {object} [parameters.retentionPolicy] + * + * @param {number} [parameters.retentionPolicy.days] Number of days to retain + * flow log records. + * + * @param {boolean} [parameters.retentionPolicy.enabled] Flag to enable/disable + * retention. + * + * @param {object} [parameters.flowAnalyticsConfiguration] + * + * @param {object} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration + * + * @param {boolean} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.enabled + * Flag to enable/disable traffic analytics. + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceId + * The resource guid of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceRegion + * The location of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceResourceId + * Resource Id of the attached workspace * * @param {object} [options] Optional Parameters. * @@ -18099,21 +17487,60 @@ export interface ConnectionMonitors { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginSetFlowLogConfigurationWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogInformation, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a connection monitor by name. + * Configures flow log and traffic analytics (optional) on a specified + * resource. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} connectionMonitorName The name of the connection monitor. + * @param {object} parameters Parameters that define the configuration of flow + * log. + * + * @param {string} parameters.targetResourceId The ID of the resource to + * configure for flow log and traffic analytics (optional) . + * + * @param {string} parameters.storageId ID of the storage account which is used + * to store the flow log. + * + * @param {boolean} parameters.enabled Flag to enable/disable flow logging. + * + * @param {object} [parameters.retentionPolicy] + * + * @param {number} [parameters.retentionPolicy.days] Number of days to retain + * flow log records. + * + * @param {boolean} [parameters.retentionPolicy.enabled] Flag to enable/disable + * retention. + * + * @param {object} [parameters.flowAnalyticsConfiguration] + * + * @param {object} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration + * + * @param {boolean} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.enabled + * Flag to enable/disable traffic analytics. + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceId + * The resource guid of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceRegion + * The location of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceResourceId + * Resource Id of the attached workspace * * @param {object} [options] Optional Parameters. * @@ -18127,7 +17554,7 @@ export interface ConnectionMonitors { * * {Promise} A promise is returned. * - * @resolve {ConnectionMonitorResult} - The deserialized result object. + * @resolve {FlowLogInformation} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18135,28 +17562,32 @@ export interface ConnectionMonitors { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ConnectionMonitorResult} [result] - The deserialized result object if an error did not occur. - * See {@link ConnectionMonitorResult} for more - * information. + * {FlowLogInformation} [result] - The deserialized result object if an error did not occur. + * See {@link FlowLogInformation} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginSetFlowLogConfiguration(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogInformation, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginSetFlowLogConfiguration(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogInformation, callback: ServiceCallback): void; + beginSetFlowLogConfiguration(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogInformation, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified connection monitor. + * Queries status of flow log and traffic analytics (optional) on a specified + * resource. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} connectionMonitorName The name of the connection monitor. + * @param {object} parameters Parameters that define a resource to query flow + * log and traffic analytics (optional) status. + * + * @param {string} parameters.targetResourceId The target resource where + * getting the flow log and traffic analytics (optional) status. * * @param {object} [options] Optional Parameters. * @@ -18165,21 +17596,26 @@ export interface ConnectionMonitors { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginGetFlowLogStatusWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogStatusParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified connection monitor. + * Queries status of flow log and traffic analytics (optional) on a specified + * resource. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} connectionMonitorName The name of the connection monitor. + * @param {object} parameters Parameters that define a resource to query flow + * log and traffic analytics (optional) status. + * + * @param {string} parameters.targetResourceId The target resource where + * getting the flow log and traffic analytics (optional) status. * * @param {object} [options] Optional Parameters. * @@ -18193,7 +17629,7 @@ export interface ConnectionMonitors { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {FlowLogInformation} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18201,26 +17637,66 @@ export interface ConnectionMonitors { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {FlowLogInformation} [result] - The deserialized result object if an error did not occur. + * See {@link FlowLogInformation} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginGetFlowLogStatus(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogStatusParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginGetFlowLogStatus(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogStatusParameters, callback: ServiceCallback): void; + beginGetFlowLogStatus(resourceGroupName: string, networkWatcherName: string, parameters: models.FlowLogStatusParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Stops the specified connection monitor. + * Verifies the possibility of establishing a direct TCP connection from a + * virtual machine to a given endpoint including another VM or an arbitrary + * remote server. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} connectionMonitorName The name of the connection monitor. + * @param {object} parameters Parameters that determine how the connectivity + * check will be performed. + * + * @param {object} parameters.source + * + * @param {string} parameters.source.resourceId The ID of the resource from + * which a connectivity check will be initiated. + * + * @param {number} [parameters.source.port] The source port from which a + * connectivity check will be performed. + * + * @param {object} parameters.destination + * + * @param {string} [parameters.destination.resourceId] The ID of the resource + * to which a connection attempt will be made. + * + * @param {string} [parameters.destination.address] The IP address or URI the + * resource to which a connection attempt will be made. + * + * @param {number} [parameters.destination.port] Port on which check + * connectivity will be performed. + * + * @param {string} [parameters.protocol] Network protocol. Possible values + * include: 'Tcp', 'Http', 'Https', 'Icmp' + * + * @param {object} [parameters.protocolConfiguration] + * + * @param {object} [parameters.protocolConfiguration.hTTPConfiguration] + * + * @param {string} [parameters.protocolConfiguration.hTTPConfiguration.method] + * HTTP method. Possible values include: 'Get' + * + * @param {array} [parameters.protocolConfiguration.hTTPConfiguration.headers] + * List of HTTP headers. + * + * @param {array} + * [parameters.protocolConfiguration.hTTPConfiguration.validStatusCodes] Valid + * status codes. * * @param {object} [options] Optional Parameters. * @@ -18229,21 +17705,60 @@ export interface ConnectionMonitors { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - stopWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCheckConnectivityWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.ConnectivityParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Stops the specified connection monitor. + * Verifies the possibility of establishing a direct TCP connection from a + * virtual machine to a given endpoint including another VM or an arbitrary + * remote server. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} connectionMonitorName The name of the connection monitor. + * @param {object} parameters Parameters that determine how the connectivity + * check will be performed. + * + * @param {object} parameters.source + * + * @param {string} parameters.source.resourceId The ID of the resource from + * which a connectivity check will be initiated. + * + * @param {number} [parameters.source.port] The source port from which a + * connectivity check will be performed. + * + * @param {object} parameters.destination + * + * @param {string} [parameters.destination.resourceId] The ID of the resource + * to which a connection attempt will be made. + * + * @param {string} [parameters.destination.address] The IP address or URI the + * resource to which a connection attempt will be made. + * + * @param {number} [parameters.destination.port] Port on which check + * connectivity will be performed. + * + * @param {string} [parameters.protocol] Network protocol. Possible values + * include: 'Tcp', 'Http', 'Https', 'Icmp' + * + * @param {object} [parameters.protocolConfiguration] + * + * @param {object} [parameters.protocolConfiguration.hTTPConfiguration] + * + * @param {string} [parameters.protocolConfiguration.hTTPConfiguration.method] + * HTTP method. Possible values include: 'Get' + * + * @param {array} [parameters.protocolConfiguration.hTTPConfiguration.headers] + * List of HTTP headers. + * + * @param {array} + * [parameters.protocolConfiguration.hTTPConfiguration.validStatusCodes] Valid + * status codes. * * @param {object} [options] Optional Parameters. * @@ -18257,7 +17772,7 @@ export interface ConnectionMonitors { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ConnectivityInformation} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18265,26 +17780,50 @@ export interface ConnectionMonitors { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ConnectivityInformation} [result] - The deserialized result object if an error did not occur. + * See {@link ConnectivityInformation} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - stop(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - stop(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; - stop(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCheckConnectivity(resourceGroupName: string, networkWatcherName: string, parameters: models.ConnectivityParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCheckConnectivity(resourceGroupName: string, networkWatcherName: string, parameters: models.ConnectivityParameters, callback: ServiceCallback): void; + beginCheckConnectivity(resourceGroupName: string, networkWatcherName: string, parameters: models.ConnectivityParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Starts the specified connection monitor. + * Gets the relative latency score for internet service providers from a + * specified location to Azure regions. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} connectionMonitorName The name of the connection monitor. + * @param {object} parameters Parameters that determine Azure reachability + * report configuration. + * + * @param {object} parameters.providerLocation + * + * @param {string} parameters.providerLocation.country The name of the country. + * + * @param {string} [parameters.providerLocation.state] The name of the state. + * + * @param {string} [parameters.providerLocation.city] The name of the city or + * town. + * + * @param {array} [parameters.providers] List of Internet service providers. + * + * @param {array} [parameters.azureLocations] Optional Azure regions to scope + * the query to. + * + * @param {date} parameters.startTime The start time for the Azure reachability + * report. + * + * @param {date} parameters.endTime The end time for the Azure reachability + * report. * * @param {object} [options] Optional Parameters. * @@ -18293,21 +17832,43 @@ export interface ConnectionMonitors { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - startWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginGetAzureReachabilityReportWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.AzureReachabilityReportParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Starts the specified connection monitor. + * Gets the relative latency score for internet service providers from a + * specified location to Azure regions. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} connectionMonitorName The name of the connection monitor. + * @param {object} parameters Parameters that determine Azure reachability + * report configuration. + * + * @param {object} parameters.providerLocation + * + * @param {string} parameters.providerLocation.country The name of the country. + * + * @param {string} [parameters.providerLocation.state] The name of the state. + * + * @param {string} [parameters.providerLocation.city] The name of the city or + * town. + * + * @param {array} [parameters.providers] List of Internet service providers. + * + * @param {array} [parameters.azureLocations] Optional Azure regions to scope + * the query to. + * + * @param {date} parameters.startTime The start time for the Azure reachability + * report. + * + * @param {date} parameters.endTime The end time for the Azure reachability + * report. * * @param {object} [options] Optional Parameters. * @@ -18321,7 +17882,7 @@ export interface ConnectionMonitors { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {AzureReachabilityReport} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18329,27 +17890,39 @@ export interface ConnectionMonitors { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {AzureReachabilityReport} [result] - The deserialized result object if an error did not occur. + * See {@link AzureReachabilityReport} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - start(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - start(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; - start(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginGetAzureReachabilityReport(resourceGroupName: string, networkWatcherName: string, parameters: models.AzureReachabilityReportParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginGetAzureReachabilityReport(resourceGroupName: string, networkWatcherName: string, parameters: models.AzureReachabilityReportParameters, callback: ServiceCallback): void; + beginGetAzureReachabilityReport(resourceGroupName: string, networkWatcherName: string, parameters: models.AzureReachabilityReportParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Query a snapshot of the most recent connection states. + * Lists all available internet service providers for a specified Azure region. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} connectionMonitorName The name given to the connection - * monitor. + * @param {object} parameters Parameters that scope the list of available + * providers. + * + * @param {array} [parameters.azureLocations] A list of Azure regions. + * + * @param {string} [parameters.country] The country for available providers + * list. + * + * @param {string} [parameters.state] The state for available providers list. + * + * @param {string} [parameters.city] The city or town for available providers + * list. * * @param {object} [options] Optional Parameters. * @@ -18358,22 +17931,32 @@ export interface ConnectionMonitors { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - queryWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginListAvailableProvidersWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, parameters: models.AvailableProvidersListParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Query a snapshot of the most recent connection states. + * Lists all available internet service providers for a specified Azure region. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the network watcher resource + * group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher resource. * - * @param {string} connectionMonitorName The name given to the connection - * monitor. + * @param {object} parameters Parameters that scope the list of available + * providers. + * + * @param {array} [parameters.azureLocations] A list of Azure regions. + * + * @param {string} [parameters.country] The country for available providers + * list. + * + * @param {string} [parameters.state] The state for available providers list. + * + * @param {string} [parameters.city] The city or town for available providers + * list. * * @param {object} [options] Optional Parameters. * @@ -18387,7 +17970,7 @@ export interface ConnectionMonitors { * * {Promise} A promise is returned. * - * @resolve {ConnectionMonitorQueryResult} - The deserialized result object. + * @resolve {AvailableProvidersList} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18395,26 +17978,68 @@ export interface ConnectionMonitors { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ConnectionMonitorQueryResult} [result] - The deserialized result object if an error did not occur. - * See {@link ConnectionMonitorQueryResult} for more + * {AvailableProvidersList} [result] - The deserialized result object if an error did not occur. + * See {@link AvailableProvidersList} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - query(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - query(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; - query(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginListAvailableProviders(resourceGroupName: string, networkWatcherName: string, parameters: models.AvailableProvidersListParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginListAvailableProviders(resourceGroupName: string, networkWatcherName: string, parameters: models.AvailableProvidersListParameters, callback: ServiceCallback): void; + beginListAvailableProviders(resourceGroupName: string, networkWatcherName: string, parameters: models.AvailableProvidersListParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * PacketCaptures + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface PacketCaptures { /** - * Lists all connection monitors for the specified Network Watcher. + * Create and start a packet capture on the specified VM. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher. + * + * @param {string} packetCaptureName The name of the packet capture session. + * + * @param {object} parameters Parameters that define the create packet capture + * operation. + * + * @param {string} parameters.target The ID of the targeted resource, only VM + * is currently supported. + * + * @param {number} [parameters.bytesToCapturePerPacket] Number of bytes + * captured per packet, the remaining bytes are truncated. + * + * @param {number} [parameters.totalBytesPerSession] Maximum size of the + * capture output. + * + * @param {number} [parameters.timeLimitInSeconds] Maximum duration of the + * capture session in seconds. + * + * @param {object} parameters.storageLocation + * + * @param {string} [parameters.storageLocation.storageId] The ID of the storage + * account to save the packet capture session. Required if no local file path + * is provided. + * + * @param {string} [parameters.storageLocation.storagePath] The URI of the + * storage path to save the packet capture. Must be a well-formed URI + * describing the location to save the packet capture. + * + * @param {string} [parameters.storageLocation.filePath] A valid local path on + * the targeting VM. Must include the name of the capture file (*.cap). For + * linux virtual machine it must start with /var/captures. Required if no + * storage ID is provided, otherwise optional. + * + * @param {array} [parameters.filters] * * @param {object} [options] Optional Parameters. * @@ -18423,19 +18048,52 @@ export interface ConnectionMonitors { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, parameters: models.PacketCapture, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists all connection monitors for the specified Network Watcher. + * Create and start a packet capture on the specified VM. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher. + * + * @param {string} packetCaptureName The name of the packet capture session. + * + * @param {object} parameters Parameters that define the create packet capture + * operation. + * + * @param {string} parameters.target The ID of the targeted resource, only VM + * is currently supported. + * + * @param {number} [parameters.bytesToCapturePerPacket] Number of bytes + * captured per packet, the remaining bytes are truncated. + * + * @param {number} [parameters.totalBytesPerSession] Maximum size of the + * capture output. + * + * @param {number} [parameters.timeLimitInSeconds] Maximum duration of the + * capture session in seconds. + * + * @param {object} parameters.storageLocation + * + * @param {string} [parameters.storageLocation.storageId] The ID of the storage + * account to save the packet capture session. Required if no local file path + * is provided. + * + * @param {string} [parameters.storageLocation.storagePath] The URI of the + * storage path to save the packet capture. Must be a well-formed URI + * describing the location to save the packet capture. + * + * @param {string} [parameters.storageLocation.filePath] A valid local path on + * the targeting VM. Must include the name of the capture file (*.cap). For + * linux virtual machine it must start with /var/captures. Required if no + * storage ID is provided, otherwise optional. + * + * @param {array} [parameters.filters] * * @param {object} [options] Optional Parameters. * @@ -18449,7 +18107,7 @@ export interface ConnectionMonitors { * * {Promise} A promise is returned. * - * @resolve {ConnectionMonitorListResult} - The deserialized result object. + * @resolve {PacketCaptureResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18457,115 +18115,48 @@ export interface ConnectionMonitors { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ConnectionMonitorListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ConnectionMonitorListResult} for more - * information. + * {PacketCaptureResult} [result] - The deserialized result object if an error did not occur. + * See {@link PacketCaptureResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, networkWatcherName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, networkWatcherName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + create(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, parameters: models.PacketCapture, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + create(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, parameters: models.PacketCapture, callback: ServiceCallback): void; + create(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, parameters: models.PacketCapture, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Create or update a connection monitor. + * Gets a packet capture session by name. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {string} connectionMonitorName The name of the connection monitor. + * @param {string} packetCaptureName The name of the packet capture session. * - * @param {object} parameters Parameters that define the operation to create a - * connection monitor. + * @param {object} [options] Optional Parameters. * - * @param {string} [parameters.location] Connection monitor location. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} [parameters.tags] Connection monitor tags. + * @returns {Promise} A promise is returned * - * @param {object} parameters.source - * - * @param {string} parameters.source.resourceId The ID of the resource used as - * the source by connection monitor. - * - * @param {number} [parameters.source.port] The source port used by connection - * monitor. - * - * @param {object} parameters.destination - * - * @param {string} [parameters.destination.resourceId] The ID of the resource - * used as the destination by connection monitor. - * - * @param {string} [parameters.destination.address] Address of the connection - * monitor destination (IP or domain name). - * - * @param {number} [parameters.destination.port] The destination port used by - * connection monitor. - * - * @param {boolean} [parameters.autoStart] Determines if the connection monitor - * will start automatically once created. - * - * @param {number} [parameters.monitoringIntervalInSeconds] Monitoring interval - * in seconds. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, parameters: models.ConnectionMonitor, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Create or update a connection monitor. - * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. - * - * @param {string} networkWatcherName The name of the Network Watcher resource. - * - * @param {string} connectionMonitorName The name of the connection monitor. - * - * @param {object} parameters Parameters that define the operation to create a - * connection monitor. - * - * @param {string} [parameters.location] Connection monitor location. - * - * @param {object} [parameters.tags] Connection monitor tags. - * - * @param {object} parameters.source - * - * @param {string} parameters.source.resourceId The ID of the resource used as - * the source by connection monitor. - * - * @param {number} [parameters.source.port] The source port used by connection - * monitor. - * - * @param {object} parameters.destination - * - * @param {string} [parameters.destination.resourceId] The ID of the resource - * used as the destination by connection monitor. - * - * @param {string} [parameters.destination.address] Address of the connection - * monitor destination (IP or domain name). + * Gets a packet capture session by name. * - * @param {number} [parameters.destination.port] The destination port used by - * connection monitor. + * @param {string} resourceGroupName The name of the resource group. * - * @param {boolean} [parameters.autoStart] Determines if the connection monitor - * will start automatically once created. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {number} [parameters.monitoringIntervalInSeconds] Monitoring interval - * in seconds. + * @param {string} packetCaptureName The name of the packet capture session. * * @param {object} [options] Optional Parameters. * @@ -18579,7 +18170,7 @@ export interface ConnectionMonitors { * * {Promise} A promise is returned. * - * @resolve {ConnectionMonitorResult} - The deserialized result object. + * @resolve {PacketCaptureResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18587,28 +18178,26 @@ export interface ConnectionMonitors { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ConnectionMonitorResult} [result] - The deserialized result object if an error did not occur. - * See {@link ConnectionMonitorResult} for more - * information. + * {PacketCaptureResult} [result] - The deserialized result object if an error did not occur. + * See {@link PacketCaptureResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, parameters: models.ConnectionMonitor, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, parameters: models.ConnectionMonitor, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, parameters: models.ConnectionMonitor, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified connection monitor. + * Deletes the specified packet capture session. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {string} connectionMonitorName The name of the connection monitor. + * @param {string} packetCaptureName The name of the packet capture session. * * @param {object} [options] Optional Parameters. * @@ -18621,17 +18210,16 @@ export interface ConnectionMonitors { * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified connection monitor. + * Deletes the specified packet capture session. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {string} connectionMonitorName The name of the connection monitor. + * @param {string} packetCaptureName The name of the packet capture session. * * @param {object} [options] Optional Parameters. * @@ -18659,20 +18247,19 @@ export interface ConnectionMonitors { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Stops the specified connection monitor. + * Stops a specified packet capture session. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {string} connectionMonitorName The name of the connection monitor. + * @param {string} packetCaptureName The name of the packet capture session. * * @param {object} [options] Optional Parameters. * @@ -18685,17 +18272,16 @@ export interface ConnectionMonitors { * * @reject {Error|ServiceError} - The error object. */ - beginStopWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + stopWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Stops the specified connection monitor. + * Stops a specified packet capture session. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} networkWatcherName The name of the Network Watcher resource. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {string} connectionMonitorName The name of the connection monitor. + * @param {string} packetCaptureName The name of the packet capture session. * * @param {object} [options] Optional Parameters. * @@ -18723,20 +18309,20 @@ export interface ConnectionMonitors { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginStop(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginStop(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; - beginStop(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + stop(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + stop(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, callback: ServiceCallback): void; + stop(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Starts the specified connection monitor. + * Query the status of a running packet capture session. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {string} connectionMonitorName The name of the connection monitor. + * @param {string} packetCaptureName The name given to the packet capture + * session. * * @param {object} [options] Optional Parameters. * @@ -18745,21 +18331,21 @@ export interface ConnectionMonitors { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginStartWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getStatusWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Starts the specified connection monitor. + * Query the status of a running packet capture session. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {string} connectionMonitorName The name of the connection monitor. + * @param {string} packetCaptureName The name given to the packet capture + * session. * * @param {object} [options] Optional Parameters. * @@ -18773,7 +18359,7 @@ export interface ConnectionMonitors { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {PacketCaptureQueryStatusResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18781,28 +18367,26 @@ export interface ConnectionMonitors { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {PacketCaptureQueryStatusResult} [result] - The deserialized result object if an error did not occur. + * See {@link PacketCaptureQueryStatusResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginStart(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginStart(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; - beginStart(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + getStatus(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getStatus(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, callback: ServiceCallback): void; + getStatus(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Query a snapshot of the most recent connection states. + * Lists all packet capture sessions within the specified resource group. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {string} connectionMonitorName The name given to the connection - * monitor. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -18810,23 +18394,19 @@ export interface ConnectionMonitors { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginQueryWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Query a snapshot of the most recent connection states. + * Lists all packet capture sessions within the specified resource group. * - * @param {string} resourceGroupName The name of the resource group containing - * Network Watcher. + * @param {string} resourceGroupName The name of the resource group. * * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {string} connectionMonitorName The name given to the connection - * monitor. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -18839,7 +18419,7 @@ export interface ConnectionMonitors { * * {Promise} A promise is returned. * - * @resolve {ConnectionMonitorQueryResult} - The deserialized result object. + * @resolve {PacketCaptureListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18847,84 +18427,59 @@ export interface ConnectionMonitors { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ConnectionMonitorQueryResult} [result] - The deserialized result object if an error did not occur. - * See {@link ConnectionMonitorQueryResult} for more + * {PacketCaptureListResult} [result] - The deserialized result object if an error did not occur. + * See {@link PacketCaptureListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginQuery(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginQuery(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; - beginQuery(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * Operations - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface Operations { + list(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, networkWatcherName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, networkWatcherName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists all of the available Network Rest API operations. + * Create and start a packet capture on the specified VM. * - * @param {object} [options] Optional Parameters. + * @param {string} resourceGroupName The name of the resource group. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} networkWatcherName The name of the network watcher. * - * @returns {Promise} A promise is returned + * @param {string} packetCaptureName The name of the packet capture session. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {object} parameters Parameters that define the create packet capture + * operation. * - * @reject {Error|ServiceError} - The error object. - */ - listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Lists all of the available Network Rest API operations. + * @param {string} parameters.target The ID of the targeted resource, only VM + * is currently supported. * - * @param {object} [options] Optional Parameters. + * @param {number} [parameters.bytesToCapturePerPacket] Number of bytes + * captured per packet, the remaining bytes are truncated. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {number} [parameters.totalBytesPerSession] Maximum size of the + * capture output. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {number} [parameters.timeLimitInSeconds] Maximum duration of the + * capture session in seconds. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {object} parameters.storageLocation * - * {Promise} A promise is returned. + * @param {string} [parameters.storageLocation.storageId] The ID of the storage + * account to save the packet capture session. Required if no local file path + * is provided. * - * @resolve {OperationListResult} - The deserialized result object. + * @param {string} [parameters.storageLocation.storagePath] The URI of the + * storage path to save the packet capture. Must be a well-formed URI + * describing the location to save the packet capture. * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {OperationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link OperationListResult} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(callback: ServiceCallback): void; - list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Lists all of the available Network Rest API operations. + * @param {string} [parameters.storageLocation.filePath] A valid local path on + * the targeting VM. Must include the name of the capture file (*.cap). For + * linux virtual machine it must start with /var/captures. Required if no + * storage ID is provided, otherwise optional. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {array} [parameters.filters] * * @param {object} [options] Optional Parameters. * @@ -18933,17 +18488,52 @@ export interface Operations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, parameters: models.PacketCapture, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists all of the available Network Rest API operations. + * Create and start a packet capture on the specified VM. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} networkWatcherName The name of the network watcher. + * + * @param {string} packetCaptureName The name of the packet capture session. + * + * @param {object} parameters Parameters that define the create packet capture + * operation. + * + * @param {string} parameters.target The ID of the targeted resource, only VM + * is currently supported. + * + * @param {number} [parameters.bytesToCapturePerPacket] Number of bytes + * captured per packet, the remaining bytes are truncated. + * + * @param {number} [parameters.totalBytesPerSession] Maximum size of the + * capture output. + * + * @param {number} [parameters.timeLimitInSeconds] Maximum duration of the + * capture session in seconds. + * + * @param {object} parameters.storageLocation + * + * @param {string} [parameters.storageLocation.storageId] The ID of the storage + * account to save the packet capture session. Required if no local file path + * is provided. + * + * @param {string} [parameters.storageLocation.storagePath] The URI of the + * storage path to save the packet capture. Must be a well-formed URI + * describing the location to save the packet capture. + * + * @param {string} [parameters.storageLocation.filePath] A valid local path on + * the targeting VM. Must include the name of the capture file (*.cap). For + * linux virtual machine it must start with /var/captures. Required if no + * storage ID is provided, otherwise optional. + * + * @param {array} [parameters.filters] * * @param {object} [options] Optional Parameters. * @@ -18957,7 +18547,7 @@ export interface Operations { * * {Promise} A promise is returned. * - * @resolve {OperationListResult} - The deserialized result object. + * @resolve {PacketCaptureResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18965,33 +18555,26 @@ export interface Operations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {OperationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link OperationListResult} for more information. + * {PacketCaptureResult} [result] - The deserialized result object if an error did not occur. + * See {@link PacketCaptureResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * PublicIPAddresses - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface PublicIPAddresses { + beginCreate(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, parameters: models.PacketCapture, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreate(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, parameters: models.PacketCapture, callback: ServiceCallback): void; + beginCreate(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, parameters: models.PacketCapture, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified public IP address. + * Deletes the specified packet capture session. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} publicIpAddressName The name of the subnet. + * @param {string} networkWatcherName The name of the network watcher. + * + * @param {string} packetCaptureName The name of the packet capture session. * * @param {object} [options] Optional Parameters. * @@ -19004,14 +18587,16 @@ export interface PublicIPAddresses { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, publicIpAddressName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified public IP address. + * Deletes the specified packet capture session. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} publicIpAddressName The name of the subnet. + * @param {string} networkWatcherName The name of the network watcher. + * + * @param {string} packetCaptureName The name of the packet capture session. * * @param {object} [options] Optional Parameters. * @@ -19039,43 +18624,43 @@ export interface PublicIPAddresses { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, publicIpAddressName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, publicIpAddressName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, publicIpAddressName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified public IP address in a specified resource group. + * Stops a specified packet capture session. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} publicIpAddressName The name of the subnet. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {object} [options] Optional Parameters. + * @param {string} packetCaptureName The name of the packet capture session. * - * @param {string} [options.expand] Expands referenced resources. + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, publicIpAddressName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + beginStopWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified public IP address in a specified resource group. + * Stops a specified packet capture session. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} publicIpAddressName The name of the subnet. + * @param {string} networkWatcherName The name of the network watcher. * - * @param {object} [options] Optional Parameters. + * @param {string} packetCaptureName The name of the packet capture session. * - * @param {string} [options.expand] Expands referenced resources. + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request @@ -19087,7 +18672,7 @@ export interface PublicIPAddresses { * * {Promise} A promise is returned. * - * @resolve {PublicIPAddress} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19095,170 +18680,188 @@ export interface PublicIPAddresses { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PublicIPAddress} [result] - The deserialized result object if an error did not occur. - * See {@link PublicIPAddress} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, publicIpAddressName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, publicIpAddressName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, publicIpAddressName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginStop(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginStop(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, callback: ServiceCallback): void; + beginStop(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a static or dynamic public IP address. + * Query the status of a running packet capture session. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} publicIpAddressName The name of the public IP address. - * - * @param {object} parameters Parameters supplied to the create or update - * public IP address operation. - * - * @param {object} [parameters.sku] The public IP address SKU. - * - * @param {string} [parameters.sku.name] Name of a public IP address SKU. - * Possible values include: 'Basic', 'Standard' + * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {string} [parameters.publicIPAllocationMethod] The public IP - * allocation method. Possible values are: 'Static' and 'Dynamic'. Possible - * values include: 'Static', 'Dynamic' + * @param {string} packetCaptureName The name given to the packet capture + * session. * - * @param {string} [parameters.publicIPAddressVersion] The public IP address - * version. Possible values are: 'IPv4' and 'IPv6'. Possible values include: - * 'IPv4', 'IPv6' + * @param {object} [options] Optional Parameters. * - * @param {object} [parameters.dnsSettings] The FQDN of the DNS record - * associated with the public IP address. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.dnsSettings.domainNameLabel] Gets or sets the - * Domain name label.The concatenation of the domain name label and the - * regionalized DNS zone make up the fully qualified domain name associated - * with the public IP address. If a domain name label is specified, an A DNS - * record is created for the public IP in the Microsoft Azure DNS system. + * @returns {Promise} A promise is returned * - * @param {string} [parameters.dnsSettings.fqdn] Gets the FQDN, Fully qualified - * domain name of the A DNS record associated with the public IP. This is the - * concatenation of the domainNameLabel and the regionalized DNS zone. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [parameters.dnsSettings.reverseFqdn] Gets or Sets the - * Reverse FQDN. A user-visible, fully qualified domain name that resolves to - * this public IP address. If the reverseFqdn is specified, then a PTR DNS - * record is created pointing from the IP address in the in-addr.arpa domain to - * the reverse FQDN. + * @reject {Error|ServiceError} - The error object. + */ + beginGetStatusWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Query the status of a running packet capture session. * - * @param {array} [parameters.ipTags] The list of tags associated with the - * public IP address. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [parameters.ipAddress] The IP address associated with the - * public IP address resource. + * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {number} [parameters.idleTimeoutInMinutes] The idle timeout of the - * public IP address. + * @param {string} packetCaptureName The name given to the packet capture + * session. * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * public IP resource. + * @param {object} [options] Optional Parameters. * - * @param {string} [parameters.provisioningState] The provisioning state of the - * PublicIP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {array} [parameters.zones] A list of availability zones denoting the - * IP allocated for the resource needs to come from. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {string} [parameters.id] Resource ID. + * {Promise} A promise is returned. * - * @param {string} [parameters.location] Resource location. + * @resolve {PacketCaptureQueryStatusResult} - The deserialized result object. * - * @param {object} [parameters.tags] Resource tags. + * @reject {Error|ServiceError} - The error object. * - * @param {object} [options] Optional Parameters. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @returns {Promise} A promise is returned + * {PacketCaptureQueryStatusResult} [result] - The deserialized result object if an error did not occur. + * See {@link PacketCaptureQueryStatusResult} for more + * information. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @reject {Error|ServiceError} - The error object. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, publicIpAddressName: string, parameters: models.PublicIPAddress, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginGetStatus(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginGetStatus(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, callback: ServiceCallback): void; + beginGetStatus(resourceGroupName: string, networkWatcherName: string, packetCaptureName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ConnectionMonitors + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface ConnectionMonitors { + /** - * Creates or updates a static or dynamic public IP address. + * Create or update a connection monitor. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. * - * @param {string} publicIpAddressName The name of the public IP address. + * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {object} parameters Parameters supplied to the create or update - * public IP address operation. + * @param {string} connectionMonitorName The name of the connection monitor. * - * @param {object} [parameters.sku] The public IP address SKU. + * @param {object} parameters Parameters that define the operation to create a + * connection monitor. * - * @param {string} [parameters.sku.name] Name of a public IP address SKU. - * Possible values include: 'Basic', 'Standard' + * @param {string} [parameters.location] Connection monitor location. * - * @param {string} [parameters.publicIPAllocationMethod] The public IP - * allocation method. Possible values are: 'Static' and 'Dynamic'. Possible - * values include: 'Static', 'Dynamic' + * @param {object} [parameters.tags] Connection monitor tags. * - * @param {string} [parameters.publicIPAddressVersion] The public IP address - * version. Possible values are: 'IPv4' and 'IPv6'. Possible values include: - * 'IPv4', 'IPv6' + * @param {object} parameters.source * - * @param {object} [parameters.dnsSettings] The FQDN of the DNS record - * associated with the public IP address. + * @param {string} parameters.source.resourceId The ID of the resource used as + * the source by connection monitor. * - * @param {string} [parameters.dnsSettings.domainNameLabel] Gets or sets the - * Domain name label.The concatenation of the domain name label and the - * regionalized DNS zone make up the fully qualified domain name associated - * with the public IP address. If a domain name label is specified, an A DNS - * record is created for the public IP in the Microsoft Azure DNS system. + * @param {number} [parameters.source.port] The source port used by connection + * monitor. * - * @param {string} [parameters.dnsSettings.fqdn] Gets the FQDN, Fully qualified - * domain name of the A DNS record associated with the public IP. This is the - * concatenation of the domainNameLabel and the regionalized DNS zone. + * @param {object} parameters.destination * - * @param {string} [parameters.dnsSettings.reverseFqdn] Gets or Sets the - * Reverse FQDN. A user-visible, fully qualified domain name that resolves to - * this public IP address. If the reverseFqdn is specified, then a PTR DNS - * record is created pointing from the IP address in the in-addr.arpa domain to - * the reverse FQDN. + * @param {string} [parameters.destination.resourceId] The ID of the resource + * used as the destination by connection monitor. * - * @param {array} [parameters.ipTags] The list of tags associated with the - * public IP address. + * @param {string} [parameters.destination.address] Address of the connection + * monitor destination (IP or domain name). * - * @param {string} [parameters.ipAddress] The IP address associated with the - * public IP address resource. + * @param {number} [parameters.destination.port] The destination port used by + * connection monitor. * - * @param {number} [parameters.idleTimeoutInMinutes] The idle timeout of the - * public IP address. + * @param {boolean} [parameters.autoStart] Determines if the connection monitor + * will start automatically once created. * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * public IP resource. + * @param {number} [parameters.monitoringIntervalInSeconds] Monitoring interval + * in seconds. * - * @param {string} [parameters.provisioningState] The provisioning state of the - * PublicIP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. + * @param {object} [options] Optional Parameters. * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {array} [parameters.zones] A list of availability zones denoting the - * IP allocated for the resource needs to come from. + * @returns {Promise} A promise is returned * - * @param {string} [parameters.id] Resource ID. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [parameters.location] Resource location. + * @reject {Error|ServiceError} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, parameters: models.ConnectionMonitor, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Create or update a connection monitor. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. + * + * @param {string} networkWatcherName The name of the Network Watcher resource. + * + * @param {string} connectionMonitorName The name of the connection monitor. + * + * @param {object} parameters Parameters that define the operation to create a + * connection monitor. + * + * @param {string} [parameters.location] Connection monitor location. + * + * @param {object} [parameters.tags] Connection monitor tags. + * + * @param {object} parameters.source + * + * @param {string} parameters.source.resourceId The ID of the resource used as + * the source by connection monitor. + * + * @param {number} [parameters.source.port] The source port used by connection + * monitor. + * + * @param {object} parameters.destination + * + * @param {string} [parameters.destination.resourceId] The ID of the resource + * used as the destination by connection monitor. + * + * @param {string} [parameters.destination.address] Address of the connection + * monitor destination (IP or domain name). + * + * @param {number} [parameters.destination.port] The destination port used by + * connection monitor. + * + * @param {boolean} [parameters.autoStart] Determines if the connection monitor + * will start automatically once created. + * + * @param {number} [parameters.monitoringIntervalInSeconds] Monitoring interval + * in seconds. * * @param {object} [options] Optional Parameters. * @@ -19272,7 +18875,7 @@ export interface PublicIPAddresses { * * {Promise} A promise is returned. * - * @resolve {PublicIPAddress} - The deserialized result object. + * @resolve {ConnectionMonitorResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19280,29 +18883,28 @@ export interface PublicIPAddresses { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PublicIPAddress} [result] - The deserialized result object if an error did not occur. - * See {@link PublicIPAddress} for more information. + * {ConnectionMonitorResult} [result] - The deserialized result object if an error did not occur. + * See {@link ConnectionMonitorResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, publicIpAddressName: string, parameters: models.PublicIPAddress, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, publicIpAddressName: string, parameters: models.PublicIPAddress, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, publicIpAddressName: string, parameters: models.PublicIPAddress, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, parameters: models.ConnectionMonitor, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, parameters: models.ConnectionMonitor, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, parameters: models.ConnectionMonitor, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates public IP address tags. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets a connection monitor by name. * - * @param {string} publicIpAddressName The name of the public IP address. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. * - * @param {object} parameters Parameters supplied to update public IP address - * tags. + * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} connectionMonitorName The name of the connection monitor. * * @param {object} [options] Optional Parameters. * @@ -19311,23 +18913,21 @@ export interface PublicIPAddresses { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateTagsWithHttpOperationResponse(resourceGroupName: string, publicIpAddressName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates public IP address tags. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets a connection monitor by name. * - * @param {string} publicIpAddressName The name of the public IP address. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. * - * @param {object} parameters Parameters supplied to update public IP address - * tags. + * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} connectionMonitorName The name of the connection monitor. * * @param {object} [options] Optional Parameters. * @@ -19341,7 +18941,7 @@ export interface PublicIPAddresses { * * {Promise} A promise is returned. * - * @resolve {PublicIPAddress} - The deserialized result object. + * @resolve {ConnectionMonitorResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19349,20 +18949,28 @@ export interface PublicIPAddresses { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PublicIPAddress} [result] - The deserialized result object if an error did not occur. - * See {@link PublicIPAddress} for more information. + * {ConnectionMonitorResult} [result] - The deserialized result object if an error did not occur. + * See {@link ConnectionMonitorResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - updateTags(resourceGroupName: string, publicIpAddressName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - updateTags(resourceGroupName: string, publicIpAddressName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - updateTags(resourceGroupName: string, publicIpAddressName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the public IP addresses in a subscription. + * Deletes the specified connection monitor. + * + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. + * + * @param {string} networkWatcherName The name of the Network Watcher resource. + * + * @param {string} connectionMonitorName The name of the connection monitor. * * @param {object} [options] Optional Parameters. * @@ -19371,14 +18979,21 @@ export interface PublicIPAddresses { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the public IP addresses in a subscription. + * Deletes the specified connection monitor. + * + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. + * + * @param {string} networkWatcherName The name of the Network Watcher resource. + * + * @param {string} connectionMonitorName The name of the connection monitor. * * @param {object} [options] Optional Parameters. * @@ -19392,7 +19007,7 @@ export interface PublicIPAddresses { * * {Promise} A promise is returned. * - * @resolve {PublicIPAddressListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19400,23 +19015,26 @@ export interface PublicIPAddresses { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PublicIPAddressListResult} [result] - The deserialized result object if an error did not occur. - * See {@link PublicIPAddressListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAll(callback: ServiceCallback): void; - listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all public IP addresses in a resource group. + * Stops the specified connection monitor. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. + * + * @param {string} networkWatcherName The name of the Network Watcher resource. + * + * @param {string} connectionMonitorName The name of the connection monitor. * * @param {object} [options] Optional Parameters. * @@ -19425,16 +19043,21 @@ export interface PublicIPAddresses { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + stopWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all public IP addresses in a resource group. + * Stops the specified connection monitor. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. + * + * @param {string} networkWatcherName The name of the Network Watcher resource. + * + * @param {string} connectionMonitorName The name of the connection monitor. * * @param {object} [options] Optional Parameters. * @@ -19448,7 +19071,7 @@ export interface PublicIPAddresses { * * {Promise} A promise is returned. * - * @resolve {PublicIPAddressListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19456,27 +19079,26 @@ export interface PublicIPAddresses { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PublicIPAddressListResult} [result] - The deserialized result object if an error did not occur. - * See {@link PublicIPAddressListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + stop(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + stop(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; + stop(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets information about all public IP addresses on a virtual machine scale - * set level. + * Starts the specified connection monitor. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. * - * @param {string} virtualMachineScaleSetName The name of the virtual machine - * scale set. + * @param {string} networkWatcherName The name of the Network Watcher resource. + * + * @param {string} connectionMonitorName The name of the connection monitor. * * @param {object} [options] Optional Parameters. * @@ -19485,20 +19107,21 @@ export interface PublicIPAddresses { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listVirtualMachineScaleSetPublicIPAddressesWithHttpOperationResponse(resourceGroupName: string, virtualMachineScaleSetName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + startWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets information about all public IP addresses on a virtual machine scale - * set level. + * Starts the specified connection monitor. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. * - * @param {string} virtualMachineScaleSetName The name of the virtual machine - * scale set. + * @param {string} networkWatcherName The name of the Network Watcher resource. + * + * @param {string} connectionMonitorName The name of the connection monitor. * * @param {object} [options] Optional Parameters. * @@ -19512,7 +19135,7 @@ export interface PublicIPAddresses { * * {Promise} A promise is returned. * - * @resolve {PublicIPAddressListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19520,33 +19143,27 @@ export interface PublicIPAddresses { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PublicIPAddressListResult} [result] - The deserialized result object if an error did not occur. - * See {@link PublicIPAddressListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listVirtualMachineScaleSetPublicIPAddresses(resourceGroupName: string, virtualMachineScaleSetName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listVirtualMachineScaleSetPublicIPAddresses(resourceGroupName: string, virtualMachineScaleSetName: string, callback: ServiceCallback): void; - listVirtualMachineScaleSetPublicIPAddresses(resourceGroupName: string, virtualMachineScaleSetName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + start(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + start(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; + start(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets information about all public IP addresses in a virtual machine IP - * configuration in a virtual machine scale set. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualMachineScaleSetName The name of the virtual machine - * scale set. + * Query a snapshot of the most recent connection states. * - * @param {string} virtualmachineIndex The virtual machine index. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. * - * @param {string} networkInterfaceName The network interface name. + * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {string} ipConfigurationName The IP configuration name. + * @param {string} connectionMonitorName The name given to the connection + * monitor. * * @param {object} [options] Optional Parameters. * @@ -19555,26 +19172,84 @@ export interface PublicIPAddresses { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listVirtualMachineScaleSetVMPublicIPAddressesWithHttpOperationResponse(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + queryWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets information about all public IP addresses in a virtual machine IP - * configuration in a virtual machine scale set. + * Query a snapshot of the most recent connection states. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. * - * @param {string} virtualMachineScaleSetName The name of the virtual machine - * scale set. + * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {string} virtualmachineIndex The virtual machine index. + * @param {string} connectionMonitorName The name given to the connection + * monitor. * - * @param {string} networkInterfaceName The network interface name. + * @param {object} [options] Optional Parameters. * - * @param {string} ipConfigurationName The IP configuration name. + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {ConnectionMonitorQueryResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {ConnectionMonitorQueryResult} [result] - The deserialized result object if an error did not occur. + * See {@link ConnectionMonitorQueryResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + query(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + query(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; + query(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists all connection monitors for the specified Network Watcher. + * + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. + * + * @param {string} networkWatcherName The name of the Network Watcher resource. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists all connection monitors for the specified Network Watcher. + * + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. + * + * @param {string} networkWatcherName The name of the Network Watcher resource. * * @param {object} [options] Optional Parameters. * @@ -19588,7 +19263,7 @@ export interface PublicIPAddresses { * * {Promise} A promise is returned. * - * @resolve {PublicIPAddressListResult} - The deserialized result object. + * @resolve {ConnectionMonitorListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19596,69 +19271,117 @@ export interface PublicIPAddresses { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PublicIPAddressListResult} [result] - The deserialized result object if an error did not occur. - * See {@link PublicIPAddressListResult} for more + * {ConnectionMonitorListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ConnectionMonitorListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listVirtualMachineScaleSetVMPublicIPAddresses(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listVirtualMachineScaleSetVMPublicIPAddresses(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, callback: ServiceCallback): void; - listVirtualMachineScaleSetVMPublicIPAddresses(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, networkWatcherName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, networkWatcherName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, networkWatcherName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Get the specified public IP address in a virtual machine scale set. + * Create or update a connection monitor. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. * - * @param {string} virtualMachineScaleSetName The name of the virtual machine - * scale set. + * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {string} virtualmachineIndex The virtual machine index. + * @param {string} connectionMonitorName The name of the connection monitor. * - * @param {string} networkInterfaceName The name of the network interface. + * @param {object} parameters Parameters that define the operation to create a + * connection monitor. * - * @param {string} ipConfigurationName The name of the IP configuration. + * @param {string} [parameters.location] Connection monitor location. * - * @param {string} publicIpAddressName The name of the public IP Address. + * @param {object} [parameters.tags] Connection monitor tags. * - * @param {object} [options] Optional Parameters. + * @param {object} parameters.source * - * @param {string} [options.expand] Expands referenced resources. + * @param {string} parameters.source.resourceId The ID of the resource used as + * the source by connection monitor. + * + * @param {number} [parameters.source.port] The source port used by connection + * monitor. + * + * @param {object} parameters.destination + * + * @param {string} [parameters.destination.resourceId] The ID of the resource + * used as the destination by connection monitor. + * + * @param {string} [parameters.destination.address] Address of the connection + * monitor destination (IP or domain name). + * + * @param {number} [parameters.destination.port] The destination port used by + * connection monitor. + * + * @param {boolean} [parameters.autoStart] Determines if the connection monitor + * will start automatically once created. + * + * @param {number} [parameters.monitoringIntervalInSeconds] Monitoring interval + * in seconds. + * + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getVirtualMachineScaleSetPublicIPAddressWithHttpOperationResponse(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, publicIpAddressName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, parameters: models.ConnectionMonitor, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Get the specified public IP address in a virtual machine scale set. + * Create or update a connection monitor. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. * - * @param {string} virtualMachineScaleSetName The name of the virtual machine - * scale set. + * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {string} virtualmachineIndex The virtual machine index. + * @param {string} connectionMonitorName The name of the connection monitor. * - * @param {string} networkInterfaceName The name of the network interface. + * @param {object} parameters Parameters that define the operation to create a + * connection monitor. * - * @param {string} ipConfigurationName The name of the IP configuration. + * @param {string} [parameters.location] Connection monitor location. * - * @param {string} publicIpAddressName The name of the public IP Address. + * @param {object} [parameters.tags] Connection monitor tags. * - * @param {object} [options] Optional Parameters. + * @param {object} parameters.source * - * @param {string} [options.expand] Expands referenced resources. + * @param {string} parameters.source.resourceId The ID of the resource used as + * the source by connection monitor. + * + * @param {number} [parameters.source.port] The source port used by connection + * monitor. + * + * @param {object} parameters.destination + * + * @param {string} [parameters.destination.resourceId] The ID of the resource + * used as the destination by connection monitor. + * + * @param {string} [parameters.destination.address] Address of the connection + * monitor destination (IP or domain name). + * + * @param {number} [parameters.destination.port] The destination port used by + * connection monitor. + * + * @param {boolean} [parameters.autoStart] Determines if the connection monitor + * will start automatically once created. + * + * @param {number} [parameters.monitoringIntervalInSeconds] Monitoring interval + * in seconds. + * + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request @@ -19670,7 +19393,7 @@ export interface PublicIPAddresses { * * {Promise} A promise is returned. * - * @resolve {PublicIPAddress} - The deserialized result object. + * @resolve {ConnectionMonitorResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19678,24 +19401,28 @@ export interface PublicIPAddresses { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PublicIPAddress} [result] - The deserialized result object if an error did not occur. - * See {@link PublicIPAddress} for more information. + * {ConnectionMonitorResult} [result] - The deserialized result object if an error did not occur. + * See {@link ConnectionMonitorResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getVirtualMachineScaleSetPublicIPAddress(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, publicIpAddressName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - getVirtualMachineScaleSetPublicIPAddress(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, publicIpAddressName: string, callback: ServiceCallback): void; - getVirtualMachineScaleSetPublicIPAddress(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, publicIpAddressName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, parameters: models.ConnectionMonitor, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, parameters: models.ConnectionMonitor, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, parameters: models.ConnectionMonitor, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified public IP address. + * Deletes the specified connection monitor. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. * - * @param {string} publicIpAddressName The name of the subnet. + * @param {string} networkWatcherName The name of the Network Watcher resource. + * + * @param {string} connectionMonitorName The name of the connection monitor. * * @param {object} [options] Optional Parameters. * @@ -19708,14 +19435,17 @@ export interface PublicIPAddresses { * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, publicIpAddressName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified public IP address. + * Deletes the specified connection monitor. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. * - * @param {string} publicIpAddressName The name of the subnet. + * @param {string} networkWatcherName The name of the Network Watcher resource. + * + * @param {string} connectionMonitorName The name of the connection monitor. * * @param {object} [options] Optional Parameters. * @@ -19743,80 +19473,20 @@ export interface PublicIPAddresses { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, publicIpAddressName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, publicIpAddressName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, publicIpAddressName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a static or dynamic public IP address. + * Stops the specified connection monitor. * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} publicIpAddressName The name of the public IP address. - * - * @param {object} parameters Parameters supplied to the create or update - * public IP address operation. - * - * @param {object} [parameters.sku] The public IP address SKU. - * - * @param {string} [parameters.sku.name] Name of a public IP address SKU. - * Possible values include: 'Basic', 'Standard' - * - * @param {string} [parameters.publicIPAllocationMethod] The public IP - * allocation method. Possible values are: 'Static' and 'Dynamic'. Possible - * values include: 'Static', 'Dynamic' - * - * @param {string} [parameters.publicIPAddressVersion] The public IP address - * version. Possible values are: 'IPv4' and 'IPv6'. Possible values include: - * 'IPv4', 'IPv6' - * - * @param {object} [parameters.dnsSettings] The FQDN of the DNS record - * associated with the public IP address. - * - * @param {string} [parameters.dnsSettings.domainNameLabel] Gets or sets the - * Domain name label.The concatenation of the domain name label and the - * regionalized DNS zone make up the fully qualified domain name associated - * with the public IP address. If a domain name label is specified, an A DNS - * record is created for the public IP in the Microsoft Azure DNS system. - * - * @param {string} [parameters.dnsSettings.fqdn] Gets the FQDN, Fully qualified - * domain name of the A DNS record associated with the public IP. This is the - * concatenation of the domainNameLabel and the regionalized DNS zone. - * - * @param {string} [parameters.dnsSettings.reverseFqdn] Gets or Sets the - * Reverse FQDN. A user-visible, fully qualified domain name that resolves to - * this public IP address. If the reverseFqdn is specified, then a PTR DNS - * record is created pointing from the IP address in the in-addr.arpa domain to - * the reverse FQDN. - * - * @param {array} [parameters.ipTags] The list of tags associated with the - * public IP address. - * - * @param {string} [parameters.ipAddress] The IP address associated with the - * public IP address resource. - * - * @param {number} [parameters.idleTimeoutInMinutes] The idle timeout of the - * public IP address. - * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * public IP resource. - * - * @param {string} [parameters.provisioningState] The provisioning state of the - * PublicIP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. - * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. - * - * @param {array} [parameters.zones] A list of availability zones denoting the - * IP allocated for the resource needs to come from. - * - * @param {string} [parameters.id] Resource ID. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. * - * @param {string} [parameters.location] Resource location. + * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} connectionMonitorName The name of the connection monitor. * * @param {object} [options] Optional Parameters. * @@ -19825,81 +19495,21 @@ export interface PublicIPAddresses { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, publicIpAddressName: string, parameters: models.PublicIPAddress, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginStopWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a static or dynamic public IP address. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} publicIpAddressName The name of the public IP address. - * - * @param {object} parameters Parameters supplied to the create or update - * public IP address operation. - * - * @param {object} [parameters.sku] The public IP address SKU. - * - * @param {string} [parameters.sku.name] Name of a public IP address SKU. - * Possible values include: 'Basic', 'Standard' - * - * @param {string} [parameters.publicIPAllocationMethod] The public IP - * allocation method. Possible values are: 'Static' and 'Dynamic'. Possible - * values include: 'Static', 'Dynamic' - * - * @param {string} [parameters.publicIPAddressVersion] The public IP address - * version. Possible values are: 'IPv4' and 'IPv6'. Possible values include: - * 'IPv4', 'IPv6' - * - * @param {object} [parameters.dnsSettings] The FQDN of the DNS record - * associated with the public IP address. - * - * @param {string} [parameters.dnsSettings.domainNameLabel] Gets or sets the - * Domain name label.The concatenation of the domain name label and the - * regionalized DNS zone make up the fully qualified domain name associated - * with the public IP address. If a domain name label is specified, an A DNS - * record is created for the public IP in the Microsoft Azure DNS system. - * - * @param {string} [parameters.dnsSettings.fqdn] Gets the FQDN, Fully qualified - * domain name of the A DNS record associated with the public IP. This is the - * concatenation of the domainNameLabel and the regionalized DNS zone. - * - * @param {string} [parameters.dnsSettings.reverseFqdn] Gets or Sets the - * Reverse FQDN. A user-visible, fully qualified domain name that resolves to - * this public IP address. If the reverseFqdn is specified, then a PTR DNS - * record is created pointing from the IP address in the in-addr.arpa domain to - * the reverse FQDN. - * - * @param {array} [parameters.ipTags] The list of tags associated with the - * public IP address. - * - * @param {string} [parameters.ipAddress] The IP address associated with the - * public IP address resource. - * - * @param {number} [parameters.idleTimeoutInMinutes] The idle timeout of the - * public IP address. - * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * public IP resource. - * - * @param {string} [parameters.provisioningState] The provisioning state of the - * PublicIP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. - * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. - * - * @param {array} [parameters.zones] A list of availability zones denoting the - * IP allocated for the resource needs to come from. + * Stops the specified connection monitor. * - * @param {string} [parameters.id] Resource ID. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. * - * @param {string} [parameters.location] Resource location. + * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} connectionMonitorName The name of the connection monitor. * * @param {object} [options] Optional Parameters. * @@ -19913,7 +19523,7 @@ export interface PublicIPAddresses { * * {Promise} A promise is returned. * - * @resolve {PublicIPAddress} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19921,29 +19531,26 @@ export interface PublicIPAddresses { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PublicIPAddress} [result] - The deserialized result object if an error did not occur. - * See {@link PublicIPAddress} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, publicIpAddressName: string, parameters: models.PublicIPAddress, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, publicIpAddressName: string, parameters: models.PublicIPAddress, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, publicIpAddressName: string, parameters: models.PublicIPAddress, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginStop(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginStop(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; + beginStop(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates public IP address tags. - * - * @param {string} resourceGroupName The name of the resource group. + * Starts the specified connection monitor. * - * @param {string} publicIpAddressName The name of the public IP address. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. * - * @param {object} parameters Parameters supplied to update public IP address - * tags. + * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} connectionMonitorName The name of the connection monitor. * * @param {object} [options] Optional Parameters. * @@ -19952,23 +19559,21 @@ export interface PublicIPAddresses { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, publicIpAddressName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginStartWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates public IP address tags. - * - * @param {string} resourceGroupName The name of the resource group. + * Starts the specified connection monitor. * - * @param {string} publicIpAddressName The name of the public IP address. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. * - * @param {object} parameters Parameters supplied to update public IP address - * tags. + * @param {string} networkWatcherName The name of the Network Watcher resource. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} connectionMonitorName The name of the connection monitor. * * @param {object} [options] Optional Parameters. * @@ -19982,7 +19587,7 @@ export interface PublicIPAddresses { * * {Promise} A promise is returned. * - * @resolve {PublicIPAddress} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19990,23 +19595,27 @@ export interface PublicIPAddresses { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PublicIPAddress} [result] - The deserialized result object if an error did not occur. - * See {@link PublicIPAddress} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdateTags(resourceGroupName: string, publicIpAddressName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdateTags(resourceGroupName: string, publicIpAddressName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - beginUpdateTags(resourceGroupName: string, publicIpAddressName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginStart(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginStart(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; + beginStart(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the public IP addresses in a subscription. + * Query a snapshot of the most recent connection states. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. + * + * @param {string} networkWatcherName The name of the Network Watcher resource. + * + * @param {string} connectionMonitorName The name given to the connection + * monitor. * * @param {object} [options] Optional Parameters. * @@ -20015,17 +19624,22 @@ export interface PublicIPAddresses { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginQueryWithHttpOperationResponse(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the public IP addresses in a subscription. + * Query a snapshot of the most recent connection states. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group containing + * Network Watcher. + * + * @param {string} networkWatcherName The name of the Network Watcher resource. + * + * @param {string} connectionMonitorName The name given to the connection + * monitor. * * @param {object} [options] Optional Parameters. * @@ -20039,7 +19653,7 @@ export interface PublicIPAddresses { * * {Promise} A promise is returned. * - * @resolve {PublicIPAddressListResult} - The deserialized result object. + * @resolve {ConnectionMonitorQueryResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20047,24 +19661,30 @@ export interface PublicIPAddresses { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PublicIPAddressListResult} [result] - The deserialized result object if an error did not occur. - * See {@link PublicIPAddressListResult} for more + * {ConnectionMonitorQueryResult} [result] - The deserialized result object if an error did not occur. + * See {@link ConnectionMonitorQueryResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAllNext(nextPageLink: string, callback: ServiceCallback): void; - listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginQuery(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginQuery(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, callback: ServiceCallback): void; + beginQuery(resourceGroupName: string, networkWatcherName: string, connectionMonitorName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * Operations + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface Operations { /** - * Gets all public IP addresses in a resource group. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * Lists all of the available Network Rest API operations. * * @param {object} [options] Optional Parameters. * @@ -20073,17 +19693,14 @@ export interface PublicIPAddresses { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all public IP addresses in a resource group. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * Lists all of the available Network Rest API operations. * * @param {object} [options] Optional Parameters. * @@ -20097,7 +19714,7 @@ export interface PublicIPAddresses { * * {Promise} A promise is returned. * - * @resolve {PublicIPAddressListResult} - The deserialized result object. + * @resolve {OperationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20105,82 +19722,20 @@ export interface PublicIPAddresses { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PublicIPAddressListResult} [result] - The deserialized result object if an error did not occur. - * See {@link PublicIPAddressListResult} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets information about all public IP addresses on a virtual machine scale - * set level. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listVirtualMachineScaleSetPublicIPAddressesNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets information about all public IP addresses on a virtual machine scale - * set level. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {PublicIPAddressListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {PublicIPAddressListResult} [result] - The deserialized result object if an error did not occur. - * See {@link PublicIPAddressListResult} for more - * information. + * {OperationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link OperationListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listVirtualMachineScaleSetPublicIPAddressesNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listVirtualMachineScaleSetPublicIPAddressesNext(nextPageLink: string, callback: ServiceCallback): void; - listVirtualMachineScaleSetPublicIPAddressesNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(callback: ServiceCallback): void; + list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets information about all public IP addresses in a virtual machine IP - * configuration in a virtual machine scale set. + * Lists all of the available Network Rest API operations. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -20192,15 +19747,14 @@ export interface PublicIPAddresses { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listVirtualMachineScaleSetVMPublicIPAddressesNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets information about all public IP addresses in a virtual machine IP - * configuration in a virtual machine scale set. + * Lists all of the available Network Rest API operations. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -20217,7 +19771,7 @@ export interface PublicIPAddresses { * * {Promise} A promise is returned. * - * @resolve {PublicIPAddressListResult} - The deserialized result object. + * @resolve {OperationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20225,34 +19779,33 @@ export interface PublicIPAddresses { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {PublicIPAddressListResult} [result] - The deserialized result object if an error did not occur. - * See {@link PublicIPAddressListResult} for more - * information. + * {OperationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link OperationListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listVirtualMachineScaleSetVMPublicIPAddressesNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listVirtualMachineScaleSetVMPublicIPAddressesNext(nextPageLink: string, callback: ServiceCallback): void; - listVirtualMachineScaleSetVMPublicIPAddressesNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } /** * @class - * RouteFilters + * PublicIPAddresses * __NOTE__: An instance of this class is automatically created for an * instance of the NetworkManagementClient. */ -export interface RouteFilters { +export interface PublicIPAddresses { /** - * Deletes the specified route filter. + * Deletes the specified public IP address. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. + * @param {string} publicIpAddressName The name of the subnet. * * @param {object} [options] Optional Parameters. * @@ -20265,14 +19818,14 @@ export interface RouteFilters { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, publicIpAddressName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified route filter. + * Deletes the specified public IP address. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. + * @param {string} publicIpAddressName The name of the subnet. * * @param {object} [options] Optional Parameters. * @@ -20300,45 +19853,43 @@ export interface RouteFilters { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, routeFilterName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, routeFilterName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, routeFilterName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, publicIpAddressName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, publicIpAddressName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, publicIpAddressName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified route filter. + * Gets the specified public IP address in a specified resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. + * @param {string} publicIpAddressName The name of the subnet. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.expand] Expands referenced express route bgp - * peering resources. + * @param {string} [options.expand] Expands referenced resources. * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, publicIpAddressName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified route filter. + * Gets the specified public IP address in a specified resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. + * @param {string} publicIpAddressName The name of the subnet. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.expand] Expands referenced express route bgp - * peering resources. + * @param {string} [options.expand] Expands referenced resources. * * @param {object} [options.customHeaders] Headers that will be added to the * request @@ -20350,7 +19901,7 @@ export interface RouteFilters { * * {Promise} A promise is returned. * - * @resolve {RouteFilter} - The deserialized result object. + * @resolve {PublicIPAddress} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20358,159 +19909,170 @@ export interface RouteFilters { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteFilter} [result] - The deserialized result object if an error did not occur. - * See {@link RouteFilter} for more information. + * {PublicIPAddress} [result] - The deserialized result object if an error did not occur. + * See {@link PublicIPAddress} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, routeFilterName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, routeFilterName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, routeFilterName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, publicIpAddressName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, publicIpAddressName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, publicIpAddressName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a route filter in a specified resource group. + * Creates or updates a static or dynamic public IP address. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. + * @param {string} publicIpAddressName The name of the public IP address. * - * @param {object} routeFilterParameters Parameters supplied to the create or - * update route filter operation. + * @param {object} parameters Parameters supplied to the create or update + * public IP address operation. * - * @param {array} [routeFilterParameters.rules] Collection of RouteFilterRules - * contained within a route filter. + * @param {object} [parameters.sku] The public IP address SKU. * - * @param {array} [routeFilterParameters.peerings] A collection of references - * to express route circuit peerings. + * @param {string} [parameters.sku.name] Name of a public IP address SKU. + * Possible values include: 'Basic', 'Standard' * - * @param {string} [routeFilterParameters.id] Resource ID. + * @param {string} [parameters.publicIPAllocationMethod] The public IP + * allocation method. Possible values are: 'Static' and 'Dynamic'. Possible + * values include: 'Static', 'Dynamic' * - * @param {string} [routeFilterParameters.location] Resource location. + * @param {string} [parameters.publicIPAddressVersion] The public IP address + * version. Possible values are: 'IPv4' and 'IPv6'. Possible values include: + * 'IPv4', 'IPv6' * - * @param {object} [routeFilterParameters.tags] Resource tags. + * @param {object} [parameters.dnsSettings] The FQDN of the DNS record + * associated with the public IP address. * - * @param {object} [options] Optional Parameters. + * @param {string} [parameters.dnsSettings.domainNameLabel] Gets or sets the + * Domain name label.The concatenation of the domain name label and the + * regionalized DNS zone make up the fully qualified domain name associated + * with the public IP address. If a domain name label is specified, an A DNS + * record is created for the public IP in the Microsoft Azure DNS system. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [parameters.dnsSettings.fqdn] Gets the FQDN, Fully qualified + * domain name of the A DNS record associated with the public IP. This is the + * concatenation of the domainNameLabel and the regionalized DNS zone. * - * @returns {Promise} A promise is returned + * @param {string} [parameters.dnsSettings.reverseFqdn] Gets or Sets the + * Reverse FQDN. A user-visible, fully qualified domain name that resolves to + * this public IP address. If the reverseFqdn is specified, then a PTR DNS + * record is created pointing from the IP address in the in-addr.arpa domain to + * the reverse FQDN. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {array} [parameters.ipTags] The list of tags associated with the + * public IP address. * - * @reject {Error|ServiceError} - The error object. - */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.RouteFilter, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Creates or updates a route filter in a specified resource group. + * @param {string} [parameters.ipAddress] The IP address associated with the + * public IP address resource. * - * @param {string} resourceGroupName The name of the resource group. + * @param {number} [parameters.idleTimeoutInMinutes] The idle timeout of the + * public IP address. * - * @param {string} routeFilterName The name of the route filter. + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * public IP resource. * - * @param {object} routeFilterParameters Parameters supplied to the create or - * update route filter operation. + * @param {string} [parameters.provisioningState] The provisioning state of the + * PublicIP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. * - * @param {array} [routeFilterParameters.rules] Collection of RouteFilterRules - * contained within a route filter. + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. * - * @param {array} [routeFilterParameters.peerings] A collection of references - * to express route circuit peerings. + * @param {array} [parameters.zones] A list of availability zones denoting the + * IP allocated for the resource needs to come from. * - * @param {string} [routeFilterParameters.id] Resource ID. + * @param {string} [parameters.id] Resource ID. * - * @param {string} [routeFilterParameters.location] Resource location. + * @param {string} [parameters.location] Resource location. * - * @param {object} [routeFilterParameters.tags] Resource tags. + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {RouteFilter} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {RouteFilter} [result] - The deserialized result object if an error did not occur. - * See {@link RouteFilter} for more information. + * @returns {Promise} A promise is returned * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + * @reject {Error|ServiceError} - The error object. */ - createOrUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.RouteFilter, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.RouteFilter, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.RouteFilter, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, publicIpAddressName: string, parameters: models.PublicIPAddress, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a route filter in a specified resource group. + * Creates or updates a static or dynamic public IP address. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. - * - * @param {object} routeFilterParameters Parameters supplied to the update - * route filter operation. + * @param {string} publicIpAddressName The name of the public IP address. * - * @param {array} [routeFilterParameters.rules] Collection of RouteFilterRules - * contained within a route filter. + * @param {object} parameters Parameters supplied to the create or update + * public IP address operation. * - * @param {array} [routeFilterParameters.peerings] A collection of references - * to express route circuit peerings. + * @param {object} [parameters.sku] The public IP address SKU. * - * @param {object} [routeFilterParameters.tags] Resource tags. + * @param {string} [parameters.sku.name] Name of a public IP address SKU. + * Possible values include: 'Basic', 'Standard' * - * @param {string} [routeFilterParameters.id] Resource ID. + * @param {string} [parameters.publicIPAllocationMethod] The public IP + * allocation method. Possible values are: 'Static' and 'Dynamic'. Possible + * values include: 'Static', 'Dynamic' * - * @param {object} [options] Optional Parameters. + * @param {string} [parameters.publicIPAddressVersion] The public IP address + * version. Possible values are: 'IPv4' and 'IPv6'. Possible values include: + * 'IPv4', 'IPv6' * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {object} [parameters.dnsSettings] The FQDN of the DNS record + * associated with the public IP address. * - * @returns {Promise} A promise is returned + * @param {string} [parameters.dnsSettings.domainNameLabel] Gets or sets the + * Domain name label.The concatenation of the domain name label and the + * regionalized DNS zone make up the fully qualified domain name associated + * with the public IP address. If a domain name label is specified, an A DNS + * record is created for the public IP in the Microsoft Azure DNS system. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} [parameters.dnsSettings.fqdn] Gets the FQDN, Fully qualified + * domain name of the A DNS record associated with the public IP. This is the + * concatenation of the domainNameLabel and the regionalized DNS zone. * - * @reject {Error|ServiceError} - The error object. - */ - updateWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.PatchRouteFilter, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Updates a route filter in a specified resource group. + * @param {string} [parameters.dnsSettings.reverseFqdn] Gets or Sets the + * Reverse FQDN. A user-visible, fully qualified domain name that resolves to + * this public IP address. If the reverseFqdn is specified, then a PTR DNS + * record is created pointing from the IP address in the in-addr.arpa domain to + * the reverse FQDN. * - * @param {string} resourceGroupName The name of the resource group. + * @param {array} [parameters.ipTags] The list of tags associated with the + * public IP address. * - * @param {string} routeFilterName The name of the route filter. + * @param {string} [parameters.ipAddress] The IP address associated with the + * public IP address resource. * - * @param {object} routeFilterParameters Parameters supplied to the update - * route filter operation. + * @param {number} [parameters.idleTimeoutInMinutes] The idle timeout of the + * public IP address. * - * @param {array} [routeFilterParameters.rules] Collection of RouteFilterRules - * contained within a route filter. + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * public IP resource. * - * @param {array} [routeFilterParameters.peerings] A collection of references - * to express route circuit peerings. + * @param {string} [parameters.provisioningState] The provisioning state of the + * PublicIP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. * - * @param {object} [routeFilterParameters.tags] Resource tags. + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. * - * @param {string} [routeFilterParameters.id] Resource ID. + * @param {array} [parameters.zones] A list of availability zones denoting the + * IP allocated for the resource needs to come from. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -20524,7 +20086,7 @@ export interface RouteFilters { * * {Promise} A promise is returned. * - * @resolve {RouteFilter} - The deserialized result object. + * @resolve {PublicIPAddress} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20532,23 +20094,30 @@ export interface RouteFilters { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteFilter} [result] - The deserialized result object if an error did not occur. - * See {@link RouteFilter} for more information. + * {PublicIPAddress} [result] - The deserialized result object if an error did not occur. + * See {@link PublicIPAddress} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - update(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.PatchRouteFilter, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - update(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.PatchRouteFilter, callback: ServiceCallback): void; - update(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.PatchRouteFilter, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, publicIpAddressName: string, parameters: models.PublicIPAddress, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, publicIpAddressName: string, parameters: models.PublicIPAddress, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, publicIpAddressName: string, parameters: models.PublicIPAddress, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all route filters in a resource group. + * Updates public IP address tags. * * @param {string} resourceGroupName The name of the resource group. * + * @param {string} publicIpAddressName The name of the public IP address. + * + * @param {object} parameters Parameters supplied to update public IP address + * tags. + * + * @param {object} [parameters.tags] Resource tags. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -20556,17 +20125,24 @@ export interface RouteFilters { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByResourceGroupWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateTagsWithHttpOperationResponse(resourceGroupName: string, publicIpAddressName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all route filters in a resource group. + * Updates public IP address tags. * * @param {string} resourceGroupName The name of the resource group. * + * @param {string} publicIpAddressName The name of the public IP address. + * + * @param {object} parameters Parameters supplied to update public IP address + * tags. + * + * @param {object} [parameters.tags] Resource tags. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -20579,7 +20155,7 @@ export interface RouteFilters { * * {Promise} A promise is returned. * - * @resolve {RouteFilterListResult} - The deserialized result object. + * @resolve {PublicIPAddress} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20587,20 +20163,20 @@ export interface RouteFilters { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteFilterListResult} [result] - The deserialized result object if an error did not occur. - * See {@link RouteFilterListResult} for more information. + * {PublicIPAddress} [result] - The deserialized result object if an error did not occur. + * See {@link PublicIPAddress} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByResourceGroup(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByResourceGroup(resourceGroupName: string, callback: ServiceCallback): void; - listByResourceGroup(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, publicIpAddressName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, publicIpAddressName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, publicIpAddressName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all route filters in a subscription. + * Gets all the public IP addresses in a subscription. * * @param {object} [options] Optional Parameters. * @@ -20609,14 +20185,14 @@ export interface RouteFilters { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all route filters in a subscription. + * Gets all the public IP addresses in a subscription. * * @param {object} [options] Optional Parameters. * @@ -20630,7 +20206,7 @@ export interface RouteFilters { * * {Promise} A promise is returned. * - * @resolve {RouteFilterListResult} - The deserialized result object. + * @resolve {PublicIPAddressListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20638,25 +20214,24 @@ export interface RouteFilters { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteFilterListResult} [result] - The deserialized result object if an error did not occur. - * See {@link RouteFilterListResult} for more information. + * {PublicIPAddressListResult} [result] - The deserialized result object if an error did not occur. + * See {@link PublicIPAddressListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(callback: ServiceCallback): void; - list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAll(callback: ServiceCallback): void; + listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified route filter. + * Gets all public IP addresses in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -20664,19 +20239,17 @@ export interface RouteFilters { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified route filter. + * Gets all public IP addresses in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -20689,7 +20262,7 @@ export interface RouteFilters { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {PublicIPAddressListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20697,38 +20270,27 @@ export interface RouteFilters { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {PublicIPAddressListResult} [result] - The deserialized result object if an error did not occur. + * See {@link PublicIPAddressListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, routeFilterName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, routeFilterName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, routeFilterName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a route filter in a specified resource group. + * Gets information about all public IP addresses on a virtual machine scale + * set level. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. - * - * @param {object} routeFilterParameters Parameters supplied to the create or - * update route filter operation. - * - * @param {array} [routeFilterParameters.rules] Collection of RouteFilterRules - * contained within a route filter. - * - * @param {array} [routeFilterParameters.peerings] A collection of references - * to express route circuit peerings. - * - * @param {string} [routeFilterParameters.id] Resource ID. - * - * @param {string} [routeFilterParameters.location] Resource location. - * - * @param {object} [routeFilterParameters.tags] Resource tags. + * @param {string} virtualMachineScaleSetName The name of the virtual machine + * scale set. * * @param {object} [options] Optional Parameters. * @@ -20737,33 +20299,20 @@ export interface RouteFilters { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.RouteFilter, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listVirtualMachineScaleSetPublicIPAddressesWithHttpOperationResponse(resourceGroupName: string, virtualMachineScaleSetName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a route filter in a specified resource group. + * Gets information about all public IP addresses on a virtual machine scale + * set level. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. - * - * @param {object} routeFilterParameters Parameters supplied to the create or - * update route filter operation. - * - * @param {array} [routeFilterParameters.rules] Collection of RouteFilterRules - * contained within a route filter. - * - * @param {array} [routeFilterParameters.peerings] A collection of references - * to express route circuit peerings. - * - * @param {string} [routeFilterParameters.id] Resource ID. - * - * @param {string} [routeFilterParameters.location] Resource location. - * - * @param {object} [routeFilterParameters.tags] Resource tags. + * @param {string} virtualMachineScaleSetName The name of the virtual machine + * scale set. * * @param {object} [options] Optional Parameters. * @@ -20777,7 +20326,7 @@ export interface RouteFilters { * * {Promise} A promise is returned. * - * @resolve {RouteFilter} - The deserialized result object. + * @resolve {PublicIPAddressListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20785,37 +20334,33 @@ export interface RouteFilters { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteFilter} [result] - The deserialized result object if an error did not occur. - * See {@link RouteFilter} for more information. + * {PublicIPAddressListResult} [result] - The deserialized result object if an error did not occur. + * See {@link PublicIPAddressListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.RouteFilter, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.RouteFilter, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.RouteFilter, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listVirtualMachineScaleSetPublicIPAddresses(resourceGroupName: string, virtualMachineScaleSetName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listVirtualMachineScaleSetPublicIPAddresses(resourceGroupName: string, virtualMachineScaleSetName: string, callback: ServiceCallback): void; + listVirtualMachineScaleSetPublicIPAddresses(resourceGroupName: string, virtualMachineScaleSetName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a route filter in a specified resource group. + * Gets information about all public IP addresses in a virtual machine IP + * configuration in a virtual machine scale set. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. - * - * @param {object} routeFilterParameters Parameters supplied to the update - * route filter operation. - * - * @param {array} [routeFilterParameters.rules] Collection of RouteFilterRules - * contained within a route filter. + * @param {string} virtualMachineScaleSetName The name of the virtual machine + * scale set. * - * @param {array} [routeFilterParameters.peerings] A collection of references - * to express route circuit peerings. + * @param {string} virtualmachineIndex The virtual machine index. * - * @param {object} [routeFilterParameters.tags] Resource tags. + * @param {string} networkInterfaceName The network interface name. * - * @param {string} [routeFilterParameters.id] Resource ID. + * @param {string} ipConfigurationName The IP configuration name. * * @param {object} [options] Optional Parameters. * @@ -20824,31 +20369,26 @@ export interface RouteFilters { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginUpdateWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.PatchRouteFilter, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listVirtualMachineScaleSetVMPublicIPAddressesWithHttpOperationResponse(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a route filter in a specified resource group. + * Gets information about all public IP addresses in a virtual machine IP + * configuration in a virtual machine scale set. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. + * @param {string} virtualMachineScaleSetName The name of the virtual machine + * scale set. * - * @param {object} routeFilterParameters Parameters supplied to the update - * route filter operation. + * @param {string} virtualmachineIndex The virtual machine index. * - * @param {array} [routeFilterParameters.rules] Collection of RouteFilterRules - * contained within a route filter. - * - * @param {array} [routeFilterParameters.peerings] A collection of references - * to express route circuit peerings. - * - * @param {object} [routeFilterParameters.tags] Resource tags. + * @param {string} networkInterfaceName The network interface name. * - * @param {string} [routeFilterParameters.id] Resource ID. + * @param {string} ipConfigurationName The IP configuration name. * * @param {object} [options] Optional Parameters. * @@ -20862,7 +20402,7 @@ export interface RouteFilters { * * {Promise} A promise is returned. * - * @resolve {RouteFilter} - The deserialized result object. + * @resolve {PublicIPAddressListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20870,102 +20410,70 @@ export interface RouteFilters { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteFilter} [result] - The deserialized result object if an error did not occur. - * See {@link RouteFilter} for more information. + * {PublicIPAddressListResult} [result] - The deserialized result object if an error did not occur. + * See {@link PublicIPAddressListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.PatchRouteFilter, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.PatchRouteFilter, callback: ServiceCallback): void; - beginUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.PatchRouteFilter, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listVirtualMachineScaleSetVMPublicIPAddresses(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listVirtualMachineScaleSetVMPublicIPAddresses(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, callback: ServiceCallback): void; + listVirtualMachineScaleSetVMPublicIPAddresses(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all route filters in a resource group. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * Get the specified public IP address in a virtual machine scale set. * - * @param {object} [options] Optional Parameters. + * @param {string} resourceGroupName The name of the resource group. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} virtualMachineScaleSetName The name of the virtual machine + * scale set. * - * @returns {Promise} A promise is returned + * @param {string} virtualmachineIndex The virtual machine index. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} networkInterfaceName The name of the network interface. * - * @reject {Error|ServiceError} - The error object. - */ - listByResourceGroupNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets all route filters in a resource group. + * @param {string} ipConfigurationName The name of the IP configuration. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} publicIpAddressName The name of the public IP Address. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands referenced resources. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {RouteFilterListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {RouteFilterListResult} [result] - The deserialized result object if an error did not occur. - * See {@link RouteFilterListResult} for more information. + * @returns {Promise} A promise is returned * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + * @reject {Error|ServiceError} - The error object. */ - listByResourceGroupNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByResourceGroupNext(nextPageLink: string, callback: ServiceCallback): void; - listByResourceGroupNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - + getVirtualMachineScaleSetPublicIPAddressWithHttpOperationResponse(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, publicIpAddressName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all route filters in a subscription. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * Get the specified public IP address in a virtual machine scale set. * - * @param {object} [options] Optional Parameters. + * @param {string} resourceGroupName The name of the resource group. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} virtualMachineScaleSetName The name of the virtual machine + * scale set. * - * @returns {Promise} A promise is returned + * @param {string} virtualmachineIndex The virtual machine index. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} networkInterfaceName The name of the network interface. * - * @reject {Error|ServiceError} - The error object. - */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets all route filters in a subscription. + * @param {string} ipConfigurationName The name of the IP configuration. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} publicIpAddressName The name of the public IP Address. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands referenced resources. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -20976,7 +20484,7 @@ export interface RouteFilters { * * {Promise} A promise is returned. * - * @resolve {RouteFilterListResult} - The deserialized result object. + * @resolve {PublicIPAddress} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20984,35 +20492,24 @@ export interface RouteFilters { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteFilterListResult} [result] - The deserialized result object if an error did not occur. - * See {@link RouteFilterListResult} for more information. + * {PublicIPAddress} [result] - The deserialized result object if an error did not occur. + * See {@link PublicIPAddress} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * RouteFilterRules - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface RouteFilterRules { + getVirtualMachineScaleSetPublicIPAddress(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, publicIpAddressName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + getVirtualMachineScaleSetPublicIPAddress(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, publicIpAddressName: string, callback: ServiceCallback): void; + getVirtualMachineScaleSetPublicIPAddress(resourceGroupName: string, virtualMachineScaleSetName: string, virtualmachineIndex: string, networkInterfaceName: string, ipConfigurationName: string, publicIpAddressName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified rule from a route filter. + * Deletes the specified public IP address. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. - * - * @param {string} ruleName The name of the rule. + * @param {string} publicIpAddressName The name of the subnet. * * @param {object} [options] Optional Parameters. * @@ -21025,16 +20522,14 @@ export interface RouteFilterRules { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, ruleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, publicIpAddressName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified rule from a route filter. + * Deletes the specified public IP address. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. - * - * @param {string} ruleName The name of the rule. + * @param {string} publicIpAddressName The name of the subnet. * * @param {object} [options] Optional Parameters. * @@ -21062,140 +20557,163 @@ export interface RouteFilterRules { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, routeFilterName: string, ruleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, routeFilterName: string, ruleName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, routeFilterName: string, ruleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, publicIpAddressName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, publicIpAddressName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, publicIpAddressName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified rule from a route filter. + * Creates or updates a static or dynamic public IP address. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. + * @param {string} publicIpAddressName The name of the public IP address. * - * @param {string} ruleName The name of the rule. + * @param {object} parameters Parameters supplied to the create or update + * public IP address operation. * - * @param {object} [options] Optional Parameters. + * @param {object} [parameters.sku] The public IP address SKU. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [parameters.sku.name] Name of a public IP address SKU. + * Possible values include: 'Basic', 'Standard' * - * @returns {Promise} A promise is returned + * @param {string} [parameters.publicIPAllocationMethod] The public IP + * allocation method. Possible values are: 'Static' and 'Dynamic'. Possible + * values include: 'Static', 'Dynamic' * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} [parameters.publicIPAddressVersion] The public IP address + * version. Possible values are: 'IPv4' and 'IPv6'. Possible values include: + * 'IPv4', 'IPv6' * - * @reject {Error|ServiceError} - The error object. - */ - getWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, ruleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets the specified rule from a route filter. + * @param {object} [parameters.dnsSettings] The FQDN of the DNS record + * associated with the public IP address. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [parameters.dnsSettings.domainNameLabel] Gets or sets the + * Domain name label.The concatenation of the domain name label and the + * regionalized DNS zone make up the fully qualified domain name associated + * with the public IP address. If a domain name label is specified, an A DNS + * record is created for the public IP in the Microsoft Azure DNS system. * - * @param {string} routeFilterName The name of the route filter. + * @param {string} [parameters.dnsSettings.fqdn] Gets the FQDN, Fully qualified + * domain name of the A DNS record associated with the public IP. This is the + * concatenation of the domainNameLabel and the regionalized DNS zone. * - * @param {string} ruleName The name of the rule. + * @param {string} [parameters.dnsSettings.reverseFqdn] Gets or Sets the + * Reverse FQDN. A user-visible, fully qualified domain name that resolves to + * this public IP address. If the reverseFqdn is specified, then a PTR DNS + * record is created pointing from the IP address in the in-addr.arpa domain to + * the reverse FQDN. * - * @param {object} [options] Optional Parameters. + * @param {array} [parameters.ipTags] The list of tags associated with the + * public IP address. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [parameters.ipAddress] The IP address associated with the + * public IP address resource. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {number} [parameters.idleTimeoutInMinutes] The idle timeout of the + * public IP address. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * public IP resource. * - * {Promise} A promise is returned. + * @param {string} [parameters.provisioningState] The provisioning state of the + * PublicIP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. * - * @resolve {RouteFilterRule} - The deserialized result object. + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. * - * @reject {Error|ServiceError} - The error object. + * @param {array} [parameters.zones] A list of availability zones denoting the + * IP allocated for the resource needs to come from. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {string} [parameters.id] Resource ID. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {string} [parameters.location] Resource location. * - * {RouteFilterRule} [result] - The deserialized result object if an error did not occur. - * See {@link RouteFilterRule} for more information. + * @param {object} [parameters.tags] Resource tags. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {object} [options] Optional Parameters. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. */ - get(resourceGroupName: string, routeFilterName: string, ruleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, routeFilterName: string, ruleName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, routeFilterName: string, ruleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, publicIpAddressName: string, parameters: models.PublicIPAddress, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a route in the specified route filter. + * Creates or updates a static or dynamic public IP address. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. - * - * @param {string} ruleName The name of the route filter rule. + * @param {string} publicIpAddressName The name of the public IP address. * - * @param {object} routeFilterRuleParameters Parameters supplied to the create - * or update route filter rule operation. + * @param {object} parameters Parameters supplied to the create or update + * public IP address operation. * - * @param {string} routeFilterRuleParameters.access The access type of the - * rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', - * 'Deny' + * @param {object} [parameters.sku] The public IP address SKU. * - * @param {array} routeFilterRuleParameters.communities The collection for bgp - * community values to filter on. e.g. ['12076:5010','12076:5020'] + * @param {string} [parameters.sku.name] Name of a public IP address SKU. + * Possible values include: 'Basic', 'Standard' * - * @param {string} [routeFilterRuleParameters.name] The name of the resource - * that is unique within a resource group. This name can be used to access the - * resource. - * - * @param {string} [routeFilterRuleParameters.location] Resource location. + * @param {string} [parameters.publicIPAllocationMethod] The public IP + * allocation method. Possible values are: 'Static' and 'Dynamic'. Possible + * values include: 'Static', 'Dynamic' * - * @param {string} [routeFilterRuleParameters.id] Resource ID. + * @param {string} [parameters.publicIPAddressVersion] The public IP address + * version. Possible values are: 'IPv4' and 'IPv6'. Possible values include: + * 'IPv4', 'IPv6' * - * @param {object} [options] Optional Parameters. + * @param {object} [parameters.dnsSettings] The FQDN of the DNS record + * associated with the public IP address. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [parameters.dnsSettings.domainNameLabel] Gets or sets the + * Domain name label.The concatenation of the domain name label and the + * regionalized DNS zone make up the fully qualified domain name associated + * with the public IP address. If a domain name label is specified, an A DNS + * record is created for the public IP in the Microsoft Azure DNS system. * - * @returns {Promise} A promise is returned + * @param {string} [parameters.dnsSettings.fqdn] Gets the FQDN, Fully qualified + * domain name of the A DNS record associated with the public IP. This is the + * concatenation of the domainNameLabel and the regionalized DNS zone. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} [parameters.dnsSettings.reverseFqdn] Gets or Sets the + * Reverse FQDN. A user-visible, fully qualified domain name that resolves to + * this public IP address. If the reverseFqdn is specified, then a PTR DNS + * record is created pointing from the IP address in the in-addr.arpa domain to + * the reverse FQDN. * - * @reject {Error|ServiceError} - The error object. - */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.RouteFilterRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Creates or updates a route in the specified route filter. + * @param {array} [parameters.ipTags] The list of tags associated with the + * public IP address. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [parameters.ipAddress] The IP address associated with the + * public IP address resource. * - * @param {string} routeFilterName The name of the route filter. + * @param {number} [parameters.idleTimeoutInMinutes] The idle timeout of the + * public IP address. * - * @param {string} ruleName The name of the route filter rule. + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * public IP resource. * - * @param {object} routeFilterRuleParameters Parameters supplied to the create - * or update route filter rule operation. + * @param {string} [parameters.provisioningState] The provisioning state of the + * PublicIP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. * - * @param {string} routeFilterRuleParameters.access The access type of the - * rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', - * 'Deny' + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. * - * @param {array} routeFilterRuleParameters.communities The collection for bgp - * community values to filter on. e.g. ['12076:5010','12076:5020'] + * @param {array} [parameters.zones] A list of availability zones denoting the + * IP allocated for the resource needs to come from. * - * @param {string} [routeFilterRuleParameters.name] The name of the resource - * that is unique within a resource group. This name can be used to access the - * resource. + * @param {string} [parameters.id] Resource ID. * - * @param {string} [routeFilterRuleParameters.location] Resource location. + * @param {string} [parameters.location] Resource location. * - * @param {string} [routeFilterRuleParameters.id] Resource ID. + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -21209,7 +20727,7 @@ export interface RouteFilterRules { * * {Promise} A promise is returned. * - * @resolve {RouteFilterRule} - The deserialized result object. + * @resolve {PublicIPAddress} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -21217,38 +20735,29 @@ export interface RouteFilterRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteFilterRule} [result] - The deserialized result object if an error did not occur. - * See {@link RouteFilterRule} for more information. + * {PublicIPAddress} [result] - The deserialized result object if an error did not occur. + * See {@link PublicIPAddress} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.RouteFilterRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.RouteFilterRule, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.RouteFilterRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, publicIpAddressName: string, parameters: models.PublicIPAddress, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, publicIpAddressName: string, parameters: models.PublicIPAddress, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, publicIpAddressName: string, parameters: models.PublicIPAddress, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a route in the specified route filter. + * Updates public IP address tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. - * - * @param {string} ruleName The name of the route filter rule. - * - * @param {object} routeFilterRuleParameters Parameters supplied to the update - * route filter rule operation. - * - * @param {string} routeFilterRuleParameters.access The access type of the - * rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', - * 'Deny' + * @param {string} publicIpAddressName The name of the public IP address. * - * @param {array} routeFilterRuleParameters.communities The collection for bgp - * community values to filter on. e.g. ['12076:5010','12076:5020'] + * @param {object} parameters Parameters supplied to update public IP address + * tags. * - * @param {string} [routeFilterRuleParameters.id] Resource ID. + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -21257,32 +20766,23 @@ export interface RouteFilterRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.PatchRouteFilterRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, publicIpAddressName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a route in the specified route filter. + * Updates public IP address tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeFilterName The name of the route filter. - * - * @param {string} ruleName The name of the route filter rule. - * - * @param {object} routeFilterRuleParameters Parameters supplied to the update - * route filter rule operation. - * - * @param {string} routeFilterRuleParameters.access The access type of the - * rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', - * 'Deny' + * @param {string} publicIpAddressName The name of the public IP address. * - * @param {array} routeFilterRuleParameters.communities The collection for bgp - * community values to filter on. e.g. ['12076:5010','12076:5020'] + * @param {object} parameters Parameters supplied to update public IP address + * tags. * - * @param {string} [routeFilterRuleParameters.id] Resource ID. + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -21296,7 +20796,7 @@ export interface RouteFilterRules { * * {Promise} A promise is returned. * - * @resolve {RouteFilterRule} - The deserialized result object. + * @resolve {PublicIPAddress} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -21304,24 +20804,23 @@ export interface RouteFilterRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteFilterRule} [result] - The deserialized result object if an error did not occur. - * See {@link RouteFilterRule} for more information. + * {PublicIPAddress} [result] - The deserialized result object if an error did not occur. + * See {@link PublicIPAddress} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - update(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.PatchRouteFilterRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - update(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.PatchRouteFilterRule, callback: ServiceCallback): void; - update(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.PatchRouteFilterRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, publicIpAddressName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdateTags(resourceGroupName: string, publicIpAddressName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, publicIpAddressName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all RouteFilterRules in a route filter. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets all the public IP addresses in a subscription. * - * @param {string} routeFilterName The name of the route filter. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -21330,18 +20829,17 @@ export interface RouteFilterRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByRouteFilterWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all RouteFilterRules in a route filter. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets all the public IP addresses in a subscription. * - * @param {string} routeFilterName The name of the route filter. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -21355,7 +20853,7 @@ export interface RouteFilterRules { * * {Promise} A promise is returned. * - * @resolve {RouteFilterRuleListResult} - The deserialized result object. + * @resolve {PublicIPAddressListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -21363,27 +20861,24 @@ export interface RouteFilterRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteFilterRuleListResult} [result] - The deserialized result object if an error did not occur. - * See {@link RouteFilterRuleListResult} for more + * {PublicIPAddressListResult} [result] - The deserialized result object if an error did not occur. + * See {@link PublicIPAddressListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByRouteFilter(resourceGroupName: string, routeFilterName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByRouteFilter(resourceGroupName: string, routeFilterName: string, callback: ServiceCallback): void; - listByRouteFilter(resourceGroupName: string, routeFilterName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAllNext(nextPageLink: string, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified rule from a route filter. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} routeFilterName The name of the route filter. + * Gets all public IP addresses in a resource group. * - * @param {string} ruleName The name of the rule. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -21392,20 +20887,17 @@ export interface RouteFilterRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, ruleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified rule from a route filter. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} routeFilterName The name of the route filter. + * Gets all public IP addresses in a resource group. * - * @param {string} ruleName The name of the rule. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -21419,7 +20911,7 @@ export interface RouteFilterRules { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {PublicIPAddressListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -21427,43 +20919,25 @@ export interface RouteFilterRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {PublicIPAddressListResult} [result] - The deserialized result object if an error did not occur. + * See {@link PublicIPAddressListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, routeFilterName: string, ruleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, routeFilterName: string, ruleName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, routeFilterName: string, ruleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a route in the specified route filter. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} routeFilterName The name of the route filter. - * - * @param {string} ruleName The name of the route filter rule. - * - * @param {object} routeFilterRuleParameters Parameters supplied to the create - * or update route filter rule operation. - * - * @param {string} routeFilterRuleParameters.access The access type of the - * rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', - * 'Deny' - * - * @param {array} routeFilterRuleParameters.communities The collection for bgp - * community values to filter on. e.g. ['12076:5010','12076:5020'] - * - * @param {string} [routeFilterRuleParameters.name] The name of the resource - * that is unique within a resource group. This name can be used to access the - * resource. - * - * @param {string} [routeFilterRuleParameters.location] Resource location. + * Gets information about all public IP addresses on a virtual machine scale + * set level. * - * @param {string} [routeFilterRuleParameters.id] Resource ID. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -21472,139 +20946,32 @@ export interface RouteFilterRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.RouteFilterRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listVirtualMachineScaleSetPublicIPAddressesNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a route in the specified route filter. + * Gets information about all public IP addresses on a virtual machine scale + * set level. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {string} routeFilterName The name of the route filter. + * @param {object} [options] Optional Parameters. * - * @param {string} ruleName The name of the route filter rule. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} routeFilterRuleParameters Parameters supplied to the create - * or update route filter rule operation. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} routeFilterRuleParameters.access The access type of the - * rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', - * 'Deny' + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {array} routeFilterRuleParameters.communities The collection for bgp - * community values to filter on. e.g. ['12076:5010','12076:5020'] + * {Promise} A promise is returned. * - * @param {string} [routeFilterRuleParameters.name] The name of the resource - * that is unique within a resource group. This name can be used to access the - * resource. - * - * @param {string} [routeFilterRuleParameters.location] Resource location. - * - * @param {string} [routeFilterRuleParameters.id] Resource ID. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {RouteFilterRule} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {RouteFilterRule} [result] - The deserialized result object if an error did not occur. - * See {@link RouteFilterRule} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginCreateOrUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.RouteFilterRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.RouteFilterRule, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.RouteFilterRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Updates a route in the specified route filter. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} routeFilterName The name of the route filter. - * - * @param {string} ruleName The name of the route filter rule. - * - * @param {object} routeFilterRuleParameters Parameters supplied to the update - * route filter rule operation. - * - * @param {string} routeFilterRuleParameters.access The access type of the - * rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', - * 'Deny' - * - * @param {array} routeFilterRuleParameters.communities The collection for bgp - * community values to filter on. e.g. ['12076:5010','12076:5020'] - * - * @param {string} [routeFilterRuleParameters.id] Resource ID. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - beginUpdateWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.PatchRouteFilterRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Updates a route in the specified route filter. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} routeFilterName The name of the route filter. - * - * @param {string} ruleName The name of the route filter rule. - * - * @param {object} routeFilterRuleParameters Parameters supplied to the update - * route filter rule operation. - * - * @param {string} routeFilterRuleParameters.access The access type of the - * rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', - * 'Deny' - * - * @param {array} routeFilterRuleParameters.communities The collection for bgp - * community values to filter on. e.g. ['12076:5010','12076:5020'] - * - * @param {string} [routeFilterRuleParameters.id] Resource ID. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {RouteFilterRule} - The deserialized result object. + * @resolve {PublicIPAddressListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -21612,20 +20979,22 @@ export interface RouteFilterRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteFilterRule} [result] - The deserialized result object if an error did not occur. - * See {@link RouteFilterRule} for more information. + * {PublicIPAddressListResult} [result] - The deserialized result object if an error did not occur. + * See {@link PublicIPAddressListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.PatchRouteFilterRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.PatchRouteFilterRule, callback: ServiceCallback): void; - beginUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.PatchRouteFilterRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listVirtualMachineScaleSetPublicIPAddressesNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listVirtualMachineScaleSetPublicIPAddressesNext(nextPageLink: string, callback: ServiceCallback): void; + listVirtualMachineScaleSetPublicIPAddressesNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all RouteFilterRules in a route filter. + * Gets information about all public IP addresses in a virtual machine IP + * configuration in a virtual machine scale set. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -21637,14 +21006,15 @@ export interface RouteFilterRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByRouteFilterNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listVirtualMachineScaleSetVMPublicIPAddressesNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all RouteFilterRules in a route filter. + * Gets information about all public IP addresses in a virtual machine IP + * configuration in a virtual machine scale set. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -21661,7 +21031,7 @@ export interface RouteFilterRules { * * {Promise} A promise is returned. * - * @resolve {RouteFilterRuleListResult} - The deserialized result object. + * @resolve {PublicIPAddressListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -21669,34 +21039,34 @@ export interface RouteFilterRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteFilterRuleListResult} [result] - The deserialized result object if an error did not occur. - * See {@link RouteFilterRuleListResult} for more + * {PublicIPAddressListResult} [result] - The deserialized result object if an error did not occur. + * See {@link PublicIPAddressListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByRouteFilterNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByRouteFilterNext(nextPageLink: string, callback: ServiceCallback): void; - listByRouteFilterNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listVirtualMachineScaleSetVMPublicIPAddressesNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listVirtualMachineScaleSetVMPublicIPAddressesNext(nextPageLink: string, callback: ServiceCallback): void; + listVirtualMachineScaleSetVMPublicIPAddressesNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } /** * @class - * RouteTables + * RouteFilters * __NOTE__: An instance of this class is automatically created for an * instance of the NetworkManagementClient. */ -export interface RouteTables { +export interface RouteFilters { /** - * Deletes the specified route table. + * Deletes the specified route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. * * @param {object} [options] Optional Parameters. * @@ -21709,14 +21079,14 @@ export interface RouteTables { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified route table. + * Deletes the specified route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. * * @param {object} [options] Optional Parameters. * @@ -21744,43 +21114,45 @@ export interface RouteTables { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, routeTableName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, routeTableName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, routeTableName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, routeFilterName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, routeFilterName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, routeFilterName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified route table. + * Gets the specified route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.expand] Expands referenced resources. + * @param {string} [options.expand] Expands referenced express route bgp + * peering resources. * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified route table. + * Gets the specified route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.expand] Expands referenced resources. + * @param {string} [options.expand] Expands referenced express route bgp + * peering resources. * * @param {object} [options.customHeaders] Headers that will be added to the * request @@ -21792,7 +21164,7 @@ export interface RouteTables { * * {Promise} A promise is returned. * - * @resolve {RouteTable} - The deserialized result object. + * @resolve {RouteFilter} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -21800,46 +21172,39 @@ export interface RouteTables { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteTable} [result] - The deserialized result object if an error did not occur. - * See {@link RouteTable} for more information. + * {RouteFilter} [result] - The deserialized result object if an error did not occur. + * See {@link RouteFilter} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, routeTableName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, routeTableName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, routeTableName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, routeFilterName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, routeFilterName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, routeFilterName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Create or updates a route table in a specified resource group. + * Creates or updates a route filter in a specified resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. - * - * @param {object} parameters Parameters supplied to the create or update route - * table operation. - * - * @param {array} [parameters.routes] Collection of routes contained within a - * route table. + * @param {string} routeFilterName The name of the route filter. * - * @param {boolean} [parameters.disableBgpRoutePropagation] Gets or sets - * whether to disable the routes learned by BGP on that route table. True means - * disable. + * @param {object} routeFilterParameters Parameters supplied to the create or + * update route filter operation. * - * @param {string} [parameters.provisioningState] The provisioning state of the - * resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. + * @param {array} [routeFilterParameters.rules] Collection of RouteFilterRules + * contained within a route filter. * - * @param {string} [parameters.etag] Gets a unique read-only string that - * changes whenever the resource is updated. + * @param {array} [routeFilterParameters.peerings] A collection of references + * to express route circuit peerings. * - * @param {string} [parameters.id] Resource ID. + * @param {string} [routeFilterParameters.id] Resource ID. * - * @param {string} [parameters.location] Resource location. + * @param {string} [routeFilterParameters.location] Resource location. * - * @param {object} [parameters.tags] Resource tags. + * @param {object} [routeFilterParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -21848,40 +21213,33 @@ export interface RouteTables { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, parameters: models.RouteTable, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.RouteFilter, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Create or updates a route table in a specified resource group. + * Creates or updates a route filter in a specified resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. - * - * @param {object} parameters Parameters supplied to the create or update route - * table operation. - * - * @param {array} [parameters.routes] Collection of routes contained within a - * route table. + * @param {string} routeFilterName The name of the route filter. * - * @param {boolean} [parameters.disableBgpRoutePropagation] Gets or sets - * whether to disable the routes learned by BGP on that route table. True means - * disable. + * @param {object} routeFilterParameters Parameters supplied to the create or + * update route filter operation. * - * @param {string} [parameters.provisioningState] The provisioning state of the - * resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. + * @param {array} [routeFilterParameters.rules] Collection of RouteFilterRules + * contained within a route filter. * - * @param {string} [parameters.etag] Gets a unique read-only string that - * changes whenever the resource is updated. + * @param {array} [routeFilterParameters.peerings] A collection of references + * to express route circuit peerings. * - * @param {string} [parameters.id] Resource ID. + * @param {string} [routeFilterParameters.id] Resource ID. * - * @param {string} [parameters.location] Resource location. + * @param {string} [routeFilterParameters.location] Resource location. * - * @param {object} [parameters.tags] Resource tags. + * @param {object} [routeFilterParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -21895,7 +21253,7 @@ export interface RouteTables { * * {Promise} A promise is returned. * - * @resolve {RouteTable} - The deserialized result object. + * @resolve {RouteFilter} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -21903,28 +21261,37 @@ export interface RouteTables { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteTable} [result] - The deserialized result object if an error did not occur. - * See {@link RouteTable} for more information. + * {RouteFilter} [result] - The deserialized result object if an error did not occur. + * See {@link RouteFilter} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, routeTableName: string, parameters: models.RouteTable, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, routeTableName: string, parameters: models.RouteTable, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, routeTableName: string, parameters: models.RouteTable, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.RouteFilter, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.RouteFilter, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.RouteFilter, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a route table tags. + * Updates a route filter in a specified resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. * - * @param {object} parameters Parameters supplied to update route table tags. + * @param {object} routeFilterParameters Parameters supplied to the update + * route filter operation. * - * @param {object} [parameters.tags] Resource tags. + * @param {array} [routeFilterParameters.rules] Collection of RouteFilterRules + * contained within a route filter. + * + * @param {array} [routeFilterParameters.peerings] A collection of references + * to express route circuit peerings. + * + * @param {object} [routeFilterParameters.tags] Resource tags. + * + * @param {string} [routeFilterParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -21933,22 +21300,31 @@ export interface RouteTables { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateTagsWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.PatchRouteFilter, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a route table tags. + * Updates a route filter in a specified resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. * - * @param {object} parameters Parameters supplied to update route table tags. + * @param {object} routeFilterParameters Parameters supplied to the update + * route filter operation. * - * @param {object} [parameters.tags] Resource tags. + * @param {array} [routeFilterParameters.rules] Collection of RouteFilterRules + * contained within a route filter. + * + * @param {array} [routeFilterParameters.peerings] A collection of references + * to express route circuit peerings. + * + * @param {object} [routeFilterParameters.tags] Resource tags. + * + * @param {string} [routeFilterParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -21962,7 +21338,7 @@ export interface RouteTables { * * {Promise} A promise is returned. * - * @resolve {RouteTable} - The deserialized result object. + * @resolve {RouteFilter} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -21970,20 +21346,20 @@ export interface RouteTables { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteTable} [result] - The deserialized result object if an error did not occur. - * See {@link RouteTable} for more information. + * {RouteFilter} [result] - The deserialized result object if an error did not occur. + * See {@link RouteFilter} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - updateTags(resourceGroupName: string, routeTableName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - updateTags(resourceGroupName: string, routeTableName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - updateTags(resourceGroupName: string, routeTableName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + update(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.PatchRouteFilter, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + update(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.PatchRouteFilter, callback: ServiceCallback): void; + update(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.PatchRouteFilter, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all route tables in a resource group. + * Gets all route filters in a resource group. * * @param {string} resourceGroupName The name of the resource group. * @@ -21994,14 +21370,14 @@ export interface RouteTables { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByResourceGroupWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all route tables in a resource group. + * Gets all route filters in a resource group. * * @param {string} resourceGroupName The name of the resource group. * @@ -22017,7 +21393,7 @@ export interface RouteTables { * * {Promise} A promise is returned. * - * @resolve {RouteTableListResult} - The deserialized result object. + * @resolve {RouteFilterListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -22025,20 +21401,20 @@ export interface RouteTables { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteTableListResult} [result] - The deserialized result object if an error did not occur. - * See {@link RouteTableListResult} for more information. + * {RouteFilterListResult} [result] - The deserialized result object if an error did not occur. + * See {@link RouteFilterListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByResourceGroup(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroup(resourceGroupName: string, callback: ServiceCallback): void; + listByResourceGroup(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all route tables in a subscription. + * Gets all route filters in a subscription. * * @param {object} [options] Optional Parameters. * @@ -22047,14 +21423,14 @@ export interface RouteTables { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all route tables in a subscription. + * Gets all route filters in a subscription. * * @param {object} [options] Optional Parameters. * @@ -22068,7 +21444,7 @@ export interface RouteTables { * * {Promise} A promise is returned. * - * @resolve {RouteTableListResult} - The deserialized result object. + * @resolve {RouteFilterListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -22076,24 +21452,24 @@ export interface RouteTables { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteTableListResult} [result] - The deserialized result object if an error did not occur. - * See {@link RouteTableListResult} for more information. + * {RouteFilterListResult} [result] - The deserialized result object if an error did not occur. + * See {@link RouteFilterListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAll(callback: ServiceCallback): void; - listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(callback: ServiceCallback): void; + list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified route table. + * Deletes the specified route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. * * @param {object} [options] Optional Parameters. * @@ -22106,14 +21482,14 @@ export interface RouteTables { * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified route table. + * Deletes the specified route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. * * @param {object} [options] Optional Parameters. * @@ -22141,39 +21517,32 @@ export interface RouteTables { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, routeTableName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, routeTableName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, routeTableName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, routeFilterName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, routeFilterName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, routeFilterName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Create or updates a route table in a specified resource group. + * Creates or updates a route filter in a specified resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. - * - * @param {object} parameters Parameters supplied to the create or update route - * table operation. - * - * @param {array} [parameters.routes] Collection of routes contained within a - * route table. + * @param {string} routeFilterName The name of the route filter. * - * @param {boolean} [parameters.disableBgpRoutePropagation] Gets or sets - * whether to disable the routes learned by BGP on that route table. True means - * disable. + * @param {object} routeFilterParameters Parameters supplied to the create or + * update route filter operation. * - * @param {string} [parameters.provisioningState] The provisioning state of the - * resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. + * @param {array} [routeFilterParameters.rules] Collection of RouteFilterRules + * contained within a route filter. * - * @param {string} [parameters.etag] Gets a unique read-only string that - * changes whenever the resource is updated. + * @param {array} [routeFilterParameters.peerings] A collection of references + * to express route circuit peerings. * - * @param {string} [parameters.id] Resource ID. + * @param {string} [routeFilterParameters.id] Resource ID. * - * @param {string} [parameters.location] Resource location. + * @param {string} [routeFilterParameters.location] Resource location. * - * @param {object} [parameters.tags] Resource tags. + * @param {object} [routeFilterParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -22182,40 +21551,33 @@ export interface RouteTables { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, parameters: models.RouteTable, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.RouteFilter, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Create or updates a route table in a specified resource group. + * Creates or updates a route filter in a specified resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. - * - * @param {object} parameters Parameters supplied to the create or update route - * table operation. - * - * @param {array} [parameters.routes] Collection of routes contained within a - * route table. + * @param {string} routeFilterName The name of the route filter. * - * @param {boolean} [parameters.disableBgpRoutePropagation] Gets or sets - * whether to disable the routes learned by BGP on that route table. True means - * disable. + * @param {object} routeFilterParameters Parameters supplied to the create or + * update route filter operation. * - * @param {string} [parameters.provisioningState] The provisioning state of the - * resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. + * @param {array} [routeFilterParameters.rules] Collection of RouteFilterRules + * contained within a route filter. * - * @param {string} [parameters.etag] Gets a unique read-only string that - * changes whenever the resource is updated. + * @param {array} [routeFilterParameters.peerings] A collection of references + * to express route circuit peerings. * - * @param {string} [parameters.id] Resource ID. + * @param {string} [routeFilterParameters.id] Resource ID. * - * @param {string} [parameters.location] Resource location. + * @param {string} [routeFilterParameters.location] Resource location. * - * @param {object} [parameters.tags] Resource tags. + * @param {object} [routeFilterParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -22229,7 +21591,7 @@ export interface RouteTables { * * {Promise} A promise is returned. * - * @resolve {RouteTable} - The deserialized result object. + * @resolve {RouteFilter} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -22237,28 +21599,37 @@ export interface RouteTables { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteTable} [result] - The deserialized result object if an error did not occur. - * See {@link RouteTable} for more information. + * {RouteFilter} [result] - The deserialized result object if an error did not occur. + * See {@link RouteFilter} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, routeTableName: string, parameters: models.RouteTable, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, routeTableName: string, parameters: models.RouteTable, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, routeTableName: string, parameters: models.RouteTable, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.RouteFilter, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.RouteFilter, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.RouteFilter, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a route table tags. + * Updates a route filter in a specified resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. * - * @param {object} parameters Parameters supplied to update route table tags. + * @param {object} routeFilterParameters Parameters supplied to the update + * route filter operation. * - * @param {object} [parameters.tags] Resource tags. + * @param {array} [routeFilterParameters.rules] Collection of RouteFilterRules + * contained within a route filter. + * + * @param {array} [routeFilterParameters.peerings] A collection of references + * to express route circuit peerings. + * + * @param {object} [routeFilterParameters.tags] Resource tags. + * + * @param {string} [routeFilterParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -22267,22 +21638,31 @@ export interface RouteTables { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.PatchRouteFilter, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a route table tags. + * Updates a route filter in a specified resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. * - * @param {object} parameters Parameters supplied to update route table tags. + * @param {object} routeFilterParameters Parameters supplied to the update + * route filter operation. * - * @param {object} [parameters.tags] Resource tags. + * @param {array} [routeFilterParameters.rules] Collection of RouteFilterRules + * contained within a route filter. + * + * @param {array} [routeFilterParameters.peerings] A collection of references + * to express route circuit peerings. + * + * @param {object} [routeFilterParameters.tags] Resource tags. + * + * @param {string} [routeFilterParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -22296,7 +21676,7 @@ export interface RouteTables { * * {Promise} A promise is returned. * - * @resolve {RouteTable} - The deserialized result object. + * @resolve {RouteFilter} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -22304,20 +21684,20 @@ export interface RouteTables { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteTable} [result] - The deserialized result object if an error did not occur. - * See {@link RouteTable} for more information. + * {RouteFilter} [result] - The deserialized result object if an error did not occur. + * See {@link RouteFilter} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdateTags(resourceGroupName: string, routeTableName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdateTags(resourceGroupName: string, routeTableName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - beginUpdateTags(resourceGroupName: string, routeTableName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.PatchRouteFilter, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.PatchRouteFilter, callback: ServiceCallback): void; + beginUpdate(resourceGroupName: string, routeFilterName: string, routeFilterParameters: models.PatchRouteFilter, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all route tables in a resource group. + * Gets all route filters in a resource group. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -22329,14 +21709,14 @@ export interface RouteTables { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByResourceGroupNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all route tables in a resource group. + * Gets all route filters in a resource group. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -22353,7 +21733,7 @@ export interface RouteTables { * * {Promise} A promise is returned. * - * @resolve {RouteTableListResult} - The deserialized result object. + * @resolve {RouteFilterListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -22361,20 +21741,20 @@ export interface RouteTables { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteTableListResult} [result] - The deserialized result object if an error did not occur. - * See {@link RouteTableListResult} for more information. + * {RouteFilterListResult} [result] - The deserialized result object if an error did not occur. + * See {@link RouteFilterListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - + listByResourceGroupNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroupNext(nextPageLink: string, callback: ServiceCallback): void; + listByResourceGroupNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + /** - * Gets all route tables in a subscription. + * Gets all route filters in a subscription. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -22386,14 +21766,14 @@ export interface RouteTables { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all route tables in a subscription. + * Gets all route filters in a subscription. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -22410,7 +21790,7 @@ export interface RouteTables { * * {Promise} A promise is returned. * - * @resolve {RouteTableListResult} - The deserialized result object. + * @resolve {RouteFilterListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -22418,35 +21798,35 @@ export interface RouteTables { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteTableListResult} [result] - The deserialized result object if an error did not occur. - * See {@link RouteTableListResult} for more information. + * {RouteFilterListResult} [result] - The deserialized result object if an error did not occur. + * See {@link RouteFilterListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAllNext(nextPageLink: string, callback: ServiceCallback): void; - listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } /** * @class - * Routes + * RouteFilterRules * __NOTE__: An instance of this class is automatically created for an * instance of the NetworkManagementClient. */ -export interface Routes { +export interface RouteFilterRules { /** - * Deletes the specified route from a route table. + * Deletes the specified rule from a route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. * - * @param {string} routeName The name of the route. + * @param {string} ruleName The name of the rule. * * @param {object} [options] Optional Parameters. * @@ -22459,16 +21839,16 @@ export interface Routes { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, routeName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, ruleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified route from a route table. + * Deletes the specified rule from a route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. * - * @param {string} routeName The name of the route. + * @param {string} ruleName The name of the rule. * * @param {object} [options] Optional Parameters. * @@ -22496,19 +21876,19 @@ export interface Routes { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, routeTableName: string, routeName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, routeTableName: string, routeName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, routeTableName: string, routeName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, routeFilterName: string, ruleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, routeFilterName: string, ruleName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, routeFilterName: string, ruleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified route from a route table. + * Gets the specified rule from a route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. * - * @param {string} routeName The name of the route. + * @param {string} ruleName The name of the rule. * * @param {object} [options] Optional Parameters. * @@ -22517,20 +21897,20 @@ export interface Routes { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, routeName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, ruleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified route from a route table. + * Gets the specified rule from a route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. * - * @param {string} routeName The name of the route. + * @param {string} ruleName The name of the rule. * * @param {object} [options] Optional Parameters. * @@ -22544,7 +21924,7 @@ export interface Routes { * * {Promise} A promise is returned. * - * @resolve {Route} - The deserialized result object. + * @resolve {RouteFilterRule} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -22552,54 +21932,44 @@ export interface Routes { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {Route} [result] - The deserialized result object if an error did not occur. - * See {@link Route} for more information. + * {RouteFilterRule} [result] - The deserialized result object if an error did not occur. + * See {@link RouteFilterRule} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, routeTableName: string, routeName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, routeTableName: string, routeName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, routeTableName: string, routeName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, routeFilterName: string, ruleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, routeFilterName: string, ruleName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, routeFilterName: string, ruleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a route in the specified route table. + * Creates or updates a route in the specified route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. - * - * @param {string} routeName The name of the route. - * - * @param {object} routeParameters Parameters supplied to the create or update - * route operation. + * @param {string} routeFilterName The name of the route filter. * - * @param {string} [routeParameters.addressPrefix] The destination CIDR to - * which the route applies. + * @param {string} ruleName The name of the route filter rule. * - * @param {string} routeParameters.nextHopType The type of Azure hop the packet - * should be sent to. Possible values are: 'VirtualNetworkGateway', - * 'VnetLocal', 'Internet', 'VirtualAppliance', and 'None'. Possible values - * include: 'VirtualNetworkGateway', 'VnetLocal', 'Internet', - * 'VirtualAppliance', 'None' + * @param {object} routeFilterRuleParameters Parameters supplied to the create + * or update route filter rule operation. * - * @param {string} [routeParameters.nextHopIpAddress] The IP address packets - * should be forwarded to. Next hop values are only allowed in routes where the - * next hop type is VirtualAppliance. + * @param {string} routeFilterRuleParameters.access The access type of the + * rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', + * 'Deny' * - * @param {string} [routeParameters.provisioningState] The provisioning state - * of the resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. + * @param {array} routeFilterRuleParameters.communities The collection for bgp + * community values to filter on. e.g. ['12076:5010','12076:5020'] * - * @param {string} [routeParameters.name] The name of the resource that is - * unique within a resource group. This name can be used to access the + * @param {string} [routeFilterRuleParameters.name] The name of the resource + * that is unique within a resource group. This name can be used to access the * resource. * - * @param {string} [routeParameters.etag] A unique read-only string that - * changes whenever the resource is updated. + * @param {string} [routeFilterRuleParameters.location] Resource location. * - * @param {string} [routeParameters.id] Resource ID. + * @param {string} [routeFilterRuleParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -22608,48 +21978,38 @@ export interface Routes { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, routeName: string, routeParameters: models.Route, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.RouteFilterRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a route in the specified route table. + * Creates or updates a route in the specified route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. - * - * @param {string} routeName The name of the route. - * - * @param {object} routeParameters Parameters supplied to the create or update - * route operation. + * @param {string} routeFilterName The name of the route filter. * - * @param {string} [routeParameters.addressPrefix] The destination CIDR to - * which the route applies. + * @param {string} ruleName The name of the route filter rule. * - * @param {string} routeParameters.nextHopType The type of Azure hop the packet - * should be sent to. Possible values are: 'VirtualNetworkGateway', - * 'VnetLocal', 'Internet', 'VirtualAppliance', and 'None'. Possible values - * include: 'VirtualNetworkGateway', 'VnetLocal', 'Internet', - * 'VirtualAppliance', 'None' + * @param {object} routeFilterRuleParameters Parameters supplied to the create + * or update route filter rule operation. * - * @param {string} [routeParameters.nextHopIpAddress] The IP address packets - * should be forwarded to. Next hop values are only allowed in routes where the - * next hop type is VirtualAppliance. + * @param {string} routeFilterRuleParameters.access The access type of the + * rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', + * 'Deny' * - * @param {string} [routeParameters.provisioningState] The provisioning state - * of the resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. + * @param {array} routeFilterRuleParameters.communities The collection for bgp + * community values to filter on. e.g. ['12076:5010','12076:5020'] * - * @param {string} [routeParameters.name] The name of the resource that is - * unique within a resource group. This name can be used to access the + * @param {string} [routeFilterRuleParameters.name] The name of the resource + * that is unique within a resource group. This name can be used to access the * resource. * - * @param {string} [routeParameters.etag] A unique read-only string that - * changes whenever the resource is updated. + * @param {string} [routeFilterRuleParameters.location] Resource location. * - * @param {string} [routeParameters.id] Resource ID. + * @param {string} [routeFilterRuleParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -22663,7 +22023,7 @@ export interface Routes { * * {Promise} A promise is returned. * - * @resolve {Route} - The deserialized result object. + * @resolve {RouteFilterRule} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -22671,24 +22031,38 @@ export interface Routes { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {Route} [result] - The deserialized result object if an error did not occur. - * See {@link Route} for more information. + * {RouteFilterRule} [result] - The deserialized result object if an error did not occur. + * See {@link RouteFilterRule} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, routeTableName: string, routeName: string, routeParameters: models.Route, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, routeTableName: string, routeName: string, routeParameters: models.Route, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, routeTableName: string, routeName: string, routeParameters: models.Route, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.RouteFilterRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.RouteFilterRule, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.RouteFilterRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all routes in a route table. + * Updates a route in the specified route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. + * + * @param {string} ruleName The name of the route filter rule. + * + * @param {object} routeFilterRuleParameters Parameters supplied to the update + * route filter rule operation. + * + * @param {string} routeFilterRuleParameters.access The access type of the + * rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', + * 'Deny' + * + * @param {array} routeFilterRuleParameters.communities The collection for bgp + * community values to filter on. e.g. ['12076:5010','12076:5020'] + * + * @param {string} [routeFilterRuleParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -22697,18 +22071,32 @@ export interface Routes { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.PatchRouteFilterRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all routes in a route table. + * Updates a route in the specified route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. + * + * @param {string} ruleName The name of the route filter rule. + * + * @param {object} routeFilterRuleParameters Parameters supplied to the update + * route filter rule operation. + * + * @param {string} routeFilterRuleParameters.access The access type of the + * rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', + * 'Deny' + * + * @param {array} routeFilterRuleParameters.communities The collection for bgp + * community values to filter on. e.g. ['12076:5010','12076:5020'] + * + * @param {string} [routeFilterRuleParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -22722,7 +22110,7 @@ export interface Routes { * * {Promise} A promise is returned. * - * @resolve {RouteListResult} - The deserialized result object. + * @resolve {RouteFilterRule} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -22730,26 +22118,24 @@ export interface Routes { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteListResult} [result] - The deserialized result object if an error did not occur. - * See {@link RouteListResult} for more information. + * {RouteFilterRule} [result] - The deserialized result object if an error did not occur. + * See {@link RouteFilterRule} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, routeTableName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, routeTableName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, routeTableName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + update(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.PatchRouteFilterRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + update(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.PatchRouteFilterRule, callback: ServiceCallback): void; + update(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.PatchRouteFilterRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified route from a route table. + * Gets all RouteFilterRules in a route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. - * - * @param {string} routeName The name of the route. + * @param {string} routeFilterName The name of the route filter. * * @param {object} [options] Optional Parameters. * @@ -22758,20 +22144,18 @@ export interface Routes { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, routeName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByRouteFilterWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified route from a route table. + * Gets all RouteFilterRules in a route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. - * - * @param {string} routeName The name of the route. + * @param {string} routeFilterName The name of the route filter. * * @param {object} [options] Optional Parameters. * @@ -22785,7 +22169,7 @@ export interface Routes { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {RouteFilterRuleListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -22793,53 +22177,27 @@ export interface Routes { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {RouteFilterRuleListResult} [result] - The deserialized result object if an error did not occur. + * See {@link RouteFilterRuleListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, routeTableName: string, routeName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, routeTableName: string, routeName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, routeTableName: string, routeName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByRouteFilter(resourceGroupName: string, routeFilterName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByRouteFilter(resourceGroupName: string, routeFilterName: string, callback: ServiceCallback): void; + listByRouteFilter(resourceGroupName: string, routeFilterName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a route in the specified route table. + * Deletes the specified rule from a route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. + * @param {string} routeFilterName The name of the route filter. * - * @param {string} routeName The name of the route. - * - * @param {object} routeParameters Parameters supplied to the create or update - * route operation. - * - * @param {string} [routeParameters.addressPrefix] The destination CIDR to - * which the route applies. - * - * @param {string} routeParameters.nextHopType The type of Azure hop the packet - * should be sent to. Possible values are: 'VirtualNetworkGateway', - * 'VnetLocal', 'Internet', 'VirtualAppliance', and 'None'. Possible values - * include: 'VirtualNetworkGateway', 'VnetLocal', 'Internet', - * 'VirtualAppliance', 'None' - * - * @param {string} [routeParameters.nextHopIpAddress] The IP address packets - * should be forwarded to. Next hop values are only allowed in routes where the - * next hop type is VirtualAppliance. - * - * @param {string} [routeParameters.provisioningState] The provisioning state - * of the resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. - * - * @param {string} [routeParameters.name] The name of the resource that is - * unique within a resource group. This name can be used to access the - * resource. - * - * @param {string} [routeParameters.etag] A unique read-only string that - * changes whenever the resource is updated. - * - * @param {string} [routeParameters.id] Resource ID. + * @param {string} ruleName The name of the rule. * * @param {object} [options] Optional Parameters. * @@ -22848,48 +22206,20 @@ export interface Routes { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, routeName: string, routeParameters: models.Route, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, ruleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a route in the specified route table. + * Deletes the specified rule from a route filter. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} routeTableName The name of the route table. - * - * @param {string} routeName The name of the route. - * - * @param {object} routeParameters Parameters supplied to the create or update - * route operation. - * - * @param {string} [routeParameters.addressPrefix] The destination CIDR to - * which the route applies. - * - * @param {string} routeParameters.nextHopType The type of Azure hop the packet - * should be sent to. Possible values are: 'VirtualNetworkGateway', - * 'VnetLocal', 'Internet', 'VirtualAppliance', and 'None'. Possible values - * include: 'VirtualNetworkGateway', 'VnetLocal', 'Internet', - * 'VirtualAppliance', 'None' - * - * @param {string} [routeParameters.nextHopIpAddress] The IP address packets - * should be forwarded to. Next hop values are only allowed in routes where the - * next hop type is VirtualAppliance. - * - * @param {string} [routeParameters.provisioningState] The provisioning state - * of the resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. - * - * @param {string} [routeParameters.name] The name of the resource that is - * unique within a resource group. This name can be used to access the - * resource. - * - * @param {string} [routeParameters.etag] A unique read-only string that - * changes whenever the resource is updated. + * @param {string} routeFilterName The name of the route filter. * - * @param {string} [routeParameters.id] Resource ID. + * @param {string} ruleName The name of the rule. * * @param {object} [options] Optional Parameters. * @@ -22903,7 +22233,7 @@ export interface Routes { * * {Promise} A promise is returned. * - * @resolve {Route} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -22911,23 +22241,43 @@ export interface Routes { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {Route} [result] - The deserialized result object if an error did not occur. - * See {@link Route} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, routeTableName: string, routeName: string, routeParameters: models.Route, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, routeTableName: string, routeName: string, routeParameters: models.Route, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, routeTableName: string, routeName: string, routeParameters: models.Route, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, routeFilterName: string, ruleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, routeFilterName: string, ruleName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, routeFilterName: string, ruleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all routes in a route table. + * Creates or updates a route in the specified route filter. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} routeFilterName The name of the route filter. + * + * @param {string} ruleName The name of the route filter rule. + * + * @param {object} routeFilterRuleParameters Parameters supplied to the create + * or update route filter rule operation. + * + * @param {string} routeFilterRuleParameters.access The access type of the + * rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', + * 'Deny' + * + * @param {array} routeFilterRuleParameters.communities The collection for bgp + * community values to filter on. e.g. ['12076:5010','12076:5020'] + * + * @param {string} [routeFilterRuleParameters.name] The name of the resource + * that is unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [routeFilterRuleParameters.location] Resource location. + * + * @param {string} [routeFilterRuleParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -22936,17 +22286,38 @@ export interface Routes { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.RouteFilterRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all routes in a route table. + * Creates or updates a route in the specified route filter. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} routeFilterName The name of the route filter. + * + * @param {string} ruleName The name of the route filter rule. + * + * @param {object} routeFilterRuleParameters Parameters supplied to the create + * or update route filter rule operation. + * + * @param {string} routeFilterRuleParameters.access The access type of the + * rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', + * 'Deny' + * + * @param {array} routeFilterRuleParameters.communities The collection for bgp + * community values to filter on. e.g. ['12076:5010','12076:5020'] + * + * @param {string} [routeFilterRuleParameters.name] The name of the resource + * that is unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [routeFilterRuleParameters.location] Resource location. + * + * @param {string} [routeFilterRuleParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -22960,7 +22331,7 @@ export interface Routes { * * {Promise} A promise is returned. * - * @resolve {RouteListResult} - The deserialized result object. + * @resolve {RouteFilterRule} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -22968,29 +22339,38 @@ export interface Routes { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RouteListResult} [result] - The deserialized result object if an error did not occur. - * See {@link RouteListResult} for more information. + * {RouteFilterRule} [result] - The deserialized result object if an error did not occur. + * See {@link RouteFilterRule} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * BgpServiceCommunities - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface BgpServiceCommunities { + beginCreateOrUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.RouteFilterRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.RouteFilterRule, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.RouteFilterRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the available bgp service communities. + * Updates a route in the specified route filter. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} routeFilterName The name of the route filter. + * + * @param {string} ruleName The name of the route filter rule. + * + * @param {object} routeFilterRuleParameters Parameters supplied to the update + * route filter rule operation. + * + * @param {string} routeFilterRuleParameters.access The access type of the + * rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', + * 'Deny' + * + * @param {array} routeFilterRuleParameters.communities The collection for bgp + * community values to filter on. e.g. ['12076:5010','12076:5020'] + * + * @param {string} [routeFilterRuleParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -22999,14 +22379,32 @@ export interface BgpServiceCommunities { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateWithHttpOperationResponse(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.PatchRouteFilterRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the available bgp service communities. + * Updates a route in the specified route filter. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} routeFilterName The name of the route filter. + * + * @param {string} ruleName The name of the route filter rule. + * + * @param {object} routeFilterRuleParameters Parameters supplied to the update + * route filter rule operation. + * + * @param {string} routeFilterRuleParameters.access The access type of the + * rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', + * 'Deny' + * + * @param {array} routeFilterRuleParameters.communities The collection for bgp + * community values to filter on. e.g. ['12076:5010','12076:5020'] + * + * @param {string} [routeFilterRuleParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -23020,7 +22418,7 @@ export interface BgpServiceCommunities { * * {Promise} A promise is returned. * - * @resolve {BgpServiceCommunityListResult} - The deserialized result object. + * @resolve {RouteFilterRule} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -23028,21 +22426,20 @@ export interface BgpServiceCommunities { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {BgpServiceCommunityListResult} [result] - The deserialized result object if an error did not occur. - * See {@link BgpServiceCommunityListResult} for more - * information. + * {RouteFilterRule} [result] - The deserialized result object if an error did not occur. + * See {@link RouteFilterRule} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(callback: ServiceCallback): void; - list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.PatchRouteFilterRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.PatchRouteFilterRule, callback: ServiceCallback): void; + beginUpdate(resourceGroupName: string, routeFilterName: string, ruleName: string, routeFilterRuleParameters: models.PatchRouteFilterRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the available bgp service communities. + * Gets all RouteFilterRules in a route filter. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -23054,14 +22451,14 @@ export interface BgpServiceCommunities { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByRouteFilterNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the available bgp service communities. + * Gets all RouteFilterRules in a route filter. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -23078,7 +22475,7 @@ export interface BgpServiceCommunities { * * {Promise} A promise is returned. * - * @resolve {BgpServiceCommunityListResult} - The deserialized result object. + * @resolve {RouteFilterRuleListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -23086,32 +22483,34 @@ export interface BgpServiceCommunities { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {BgpServiceCommunityListResult} [result] - The deserialized result object if an error did not occur. - * See {@link BgpServiceCommunityListResult} for more + * {RouteFilterRuleListResult} [result] - The deserialized result object if an error did not occur. + * See {@link RouteFilterRuleListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByRouteFilterNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByRouteFilterNext(nextPageLink: string, callback: ServiceCallback): void; + listByRouteFilterNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } /** * @class - * Usages + * RouteTables * __NOTE__: An instance of this class is automatically created for an * instance of the NetworkManagementClient. */ -export interface Usages { +export interface RouteTables { /** - * List network usages for a subscription. + * Deletes the specified route table. * - * @param {string} location The location where resource usage is queried. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} routeTableName The name of the route table. * * @param {object} [options] Optional Parameters. * @@ -23120,16 +22519,18 @@ export interface Usages { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(location: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * List network usages for a subscription. + * Deletes the specified route table. * - * @param {string} location The location where resource usage is queried. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} routeTableName The name of the route table. * * @param {object} [options] Optional Parameters. * @@ -23143,7 +22544,7 @@ export interface Usages { * * {Promise} A promise is returned. * - * @resolve {UsagesListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -23151,45 +22552,50 @@ export interface Usages { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {UsagesListResult} [result] - The deserialized result object if an error did not occur. - * See {@link UsagesListResult} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(location: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(location: string, callback: ServiceCallback): void; - list(location: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, routeTableName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, routeTableName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, routeTableName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * List network usages for a subscription. + * Gets the specified route table. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} routeTableName The name of the route table. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands referenced resources. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * List network usages for a subscription. + * Gets the specified route table. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} routeTableName The name of the route table. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.expand] Expands referenced resources. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -23200,7 +22606,7 @@ export interface Usages { * * {Promise} A promise is returned. * - * @resolve {UsagesListResult} - The deserialized result object. + * @resolve {RouteTable} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -23208,33 +22614,46 @@ export interface Usages { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {UsagesListResult} [result] - The deserialized result object if an error did not occur. - * See {@link UsagesListResult} for more information. + * {RouteTable} [result] - The deserialized result object if an error did not occur. + * See {@link RouteTable} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * VirtualNetworks - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface VirtualNetworks { + get(resourceGroupName: string, routeTableName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, routeTableName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, routeTableName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified virtual network. + * Create or updates a route table in a specified resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} routeTableName The name of the route table. + * + * @param {object} parameters Parameters supplied to the create or update route + * table operation. + * + * @param {array} [parameters.routes] Collection of routes contained within a + * route table. + * + * @param {boolean} [parameters.disableBgpRoutePropagation] Gets or sets + * whether to disable the routes learned by BGP on that route table. True means + * disable. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. + * + * @param {string} [parameters.etag] Gets a unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -23243,18 +22662,40 @@ export interface VirtualNetworks { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, parameters: models.RouteTable, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified virtual network. + * Create or updates a route table in a specified resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} routeTableName The name of the route table. + * + * @param {object} parameters Parameters supplied to the create or update route + * table operation. + * + * @param {array} [parameters.routes] Collection of routes contained within a + * route table. + * + * @param {boolean} [parameters.disableBgpRoutePropagation] Gets or sets + * whether to disable the routes learned by BGP on that route table. True means + * disable. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. + * + * @param {string} [parameters.etag] Gets a unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -23268,7 +22709,7 @@ export interface VirtualNetworks { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {RouteTable} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -23276,49 +22717,54 @@ export interface VirtualNetworks { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {RouteTable} [result] - The deserialized result object if an error did not occur. + * See {@link RouteTable} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, virtualNetworkName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, virtualNetworkName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, routeTableName: string, parameters: models.RouteTable, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, routeTableName: string, parameters: models.RouteTable, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, routeTableName: string, parameters: models.RouteTable, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified virtual network by resource group. + * Updates a route table tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} routeTableName The name of the route table. * - * @param {object} [options] Optional Parameters. + * @param {object} parameters Parameters supplied to update route table tags. * - * @param {string} [options.expand] Expands referenced resources. + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + updateTagsWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified virtual network by resource group. + * Updates a route table tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} routeTableName The name of the route table. * - * @param {object} [options] Optional Parameters. + * @param {object} parameters Parameters supplied to update route table tags. * - * @param {string} [options.expand] Expands referenced resources. + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request @@ -23330,7 +22776,7 @@ export interface VirtualNetworks { * * {Promise} A promise is returned. * - * @resolve {VirtualNetwork} - The deserialized result object. + * @resolve {RouteTable} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -23338,72 +22784,75 @@ export interface VirtualNetworks { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetwork} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetwork} for more information. + * {RouteTable} [result] - The deserialized result object if an error did not occur. + * See {@link RouteTable} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, virtualNetworkName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, virtualNetworkName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, virtualNetworkName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, routeTableName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, routeTableName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, routeTableName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a virtual network in the specified resource group. + * Gets all route tables in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {object} [options] Optional Parameters. * - * @param {object} parameters Parameters supplied to the create or update - * virtual network operation + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} [parameters.addressSpace] The AddressSpace that contains an - * array of IP address ranges that can be used by subnets. + * @returns {Promise} A promise is returned * - * @param {array} [parameters.addressSpace.addressPrefixes] A list of address - * blocks reserved for this virtual network in CIDR notation. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {object} [parameters.dhcpOptions] The dhcpOptions that contains an - * array of DNS servers available to VMs deployed in the virtual network. + * @reject {Error|ServiceError} - The error object. + */ + listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all route tables in a resource group. * - * @param {array} [parameters.dhcpOptions.dnsServers] The list of DNS servers - * IP addresses. + * @param {string} resourceGroupName The name of the resource group. * - * @param {array} [parameters.subnets] A list of subnets in a Virtual Network. + * @param {object} [options] Optional Parameters. * - * @param {array} [parameters.virtualNetworkPeerings] A list of peerings in a - * Virtual Network. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.resourceGuid] The resourceGuid property of the - * Virtual Network resource. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} [parameters.provisioningState] The provisioning state of the - * PublicIP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {boolean} [parameters.enableDdosProtection] Indicates if DDoS - * protection is enabled for all the protected resources in the virtual - * network. It requires a DDoS protection plan associated with the resource. + * {Promise} A promise is returned. * - * @param {boolean} [parameters.enableVmProtection] Indicates if VM protection - * is enabled for all the subnets in the virtual network. + * @resolve {RouteTableListResult} - The deserialized result object. * - * @param {object} [parameters.ddosProtectionPlan] The DDoS protection plan - * associated with the virtual network. + * @reject {Error|ServiceError} - The error object. * - * @param {string} [parameters.ddosProtectionPlan.id] Resource ID. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} [parameters.etag] Gets a unique read-only string that - * changes whenever the resource is updated. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [parameters.id] Resource ID. + * {RouteTableListResult} [result] - The deserialized result object if an error did not occur. + * See {@link RouteTableListResult} for more information. * - * @param {string} [parameters.location] Resource location. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {object} [parameters.tags] Resource tags. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all route tables in a subscription. * * @param {object} [options] Optional Parameters. * @@ -23412,66 +22861,73 @@ export interface VirtualNetworks { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, parameters: models.VirtualNetwork, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a virtual network in the specified resource group. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets all route tables in a subscription. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {object} [options] Optional Parameters. * - * @param {object} parameters Parameters supplied to the create or update - * virtual network operation + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} [parameters.addressSpace] The AddressSpace that contains an - * array of IP address ranges that can be used by subnets. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {array} [parameters.addressSpace.addressPrefixes] A list of address - * blocks reserved for this virtual network in CIDR notation. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {object} [parameters.dhcpOptions] The dhcpOptions that contains an - * array of DNS servers available to VMs deployed in the virtual network. + * {Promise} A promise is returned. * - * @param {array} [parameters.dhcpOptions.dnsServers] The list of DNS servers - * IP addresses. + * @resolve {RouteTableListResult} - The deserialized result object. * - * @param {array} [parameters.subnets] A list of subnets in a Virtual Network. + * @reject {Error|ServiceError} - The error object. * - * @param {array} [parameters.virtualNetworkPeerings] A list of peerings in a - * Virtual Network. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} [parameters.resourceGuid] The resourceGuid property of the - * Virtual Network resource. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [parameters.provisioningState] The provisioning state of the - * PublicIP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. + * {RouteTableListResult} [result] - The deserialized result object if an error did not occur. + * See {@link RouteTableListResult} for more information. * - * @param {boolean} [parameters.enableDdosProtection] Indicates if DDoS - * protection is enabled for all the protected resources in the virtual - * network. It requires a DDoS protection plan associated with the resource. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {boolean} [parameters.enableVmProtection] Indicates if VM protection - * is enabled for all the subnets in the virtual network. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAll(callback: ServiceCallback): void; + listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes the specified route table. * - * @param {object} [parameters.ddosProtectionPlan] The DDoS protection plan - * associated with the virtual network. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [parameters.ddosProtectionPlan.id] Resource ID. + * @param {string} routeTableName The name of the route table. * - * @param {string} [parameters.etag] Gets a unique read-only string that - * changes whenever the resource is updated. + * @param {object} [options] Optional Parameters. * - * @param {string} [parameters.id] Resource ID. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.location] Resource location. + * @returns {Promise} A promise is returned * - * @param {object} [parameters.tags] Resource tags. + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes the specified route table. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} routeTableName The name of the route table. * * @param {object} [options] Optional Parameters. * @@ -23485,7 +22941,7 @@ export interface VirtualNetworks { * * {Promise} A promise is returned. * - * @resolve {VirtualNetwork} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -23493,27 +22949,43 @@ export interface VirtualNetworks { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetwork} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetwork} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, virtualNetworkName: string, parameters: models.VirtualNetwork, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, virtualNetworkName: string, parameters: models.VirtualNetwork, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, virtualNetworkName: string, parameters: models.VirtualNetwork, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, routeTableName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, routeTableName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, routeTableName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a virtual network tags. + * Create or updates a route table in a specified resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} routeTableName The name of the route table. * - * @param {object} parameters Parameters supplied to update virtual network - * tags. + * @param {object} parameters Parameters supplied to the create or update route + * table operation. + * + * @param {array} [parameters.routes] Collection of routes contained within a + * route table. + * + * @param {boolean} [parameters.disableBgpRoutePropagation] Gets or sets + * whether to disable the routes learned by BGP on that route table. True means + * disable. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. + * + * @param {string} [parameters.etag] Gets a unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. * * @param {object} [parameters.tags] Resource tags. * @@ -23524,21 +22996,38 @@ export interface VirtualNetworks { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateTagsWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, parameters: models.RouteTable, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a virtual network tags. + * Create or updates a route table in a specified resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} routeTableName The name of the route table. * - * @param {object} parameters Parameters supplied to update virtual network - * tags. + * @param {object} parameters Parameters supplied to the create or update route + * table operation. + * + * @param {array} [parameters.routes] Collection of routes contained within a + * route table. + * + * @param {boolean} [parameters.disableBgpRoutePropagation] Gets or sets + * whether to disable the routes learned by BGP on that route table. True means + * disable. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. + * + * @param {string} [parameters.etag] Gets a unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. * * @param {object} [parameters.tags] Resource tags. * @@ -23554,7 +23043,7 @@ export interface VirtualNetworks { * * {Promise} A promise is returned. * - * @resolve {VirtualNetwork} - The deserialized result object. + * @resolve {RouteTable} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -23562,20 +23051,28 @@ export interface VirtualNetworks { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetwork} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetwork} for more information. + * {RouteTable} [result] - The deserialized result object if an error did not occur. + * See {@link RouteTable} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - updateTags(resourceGroupName: string, virtualNetworkName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - updateTags(resourceGroupName: string, virtualNetworkName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - updateTags(resourceGroupName: string, virtualNetworkName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, routeTableName: string, parameters: models.RouteTable, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, routeTableName: string, parameters: models.RouteTable, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, routeTableName: string, parameters: models.RouteTable, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all virtual networks in a subscription. + * Updates a route table tags. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} routeTableName The name of the route table. + * + * @param {object} parameters Parameters supplied to update route table tags. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -23584,14 +23081,22 @@ export interface VirtualNetworks { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all virtual networks in a subscription. + * Updates a route table tags. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} routeTableName The name of the route table. + * + * @param {object} parameters Parameters supplied to update route table tags. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -23605,7 +23110,7 @@ export interface VirtualNetworks { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkListResult} - The deserialized result object. + * @resolve {RouteTable} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -23613,23 +23118,23 @@ export interface VirtualNetworks { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkListResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkListResult} for more - * information. + * {RouteTable} [result] - The deserialized result object if an error did not occur. + * See {@link RouteTable} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAll(callback: ServiceCallback): void; - listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, routeTableName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdateTags(resourceGroupName: string, routeTableName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, routeTableName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all virtual networks in a resource group. + * Gets all route tables in a resource group. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -23638,16 +23143,17 @@ export interface VirtualNetworks { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all virtual networks in a resource group. + * Gets all route tables in a resource group. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -23661,7 +23167,7 @@ export interface VirtualNetworks { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkListResult} - The deserialized result object. + * @resolve {RouteTableListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -23669,52 +23175,45 @@ export interface VirtualNetworks { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkListResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkListResult} for more - * information. + * {RouteTableListResult} [result] - The deserialized result object if an error did not occur. + * See {@link RouteTableListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Checks whether a private IP address is available for use. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets all route tables in a subscription. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.ipAddress] The private IP address to be verified. - * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - checkIPAddressAvailabilityWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, options?: { ipAddress? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Checks whether a private IP address is available for use. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets all route tables in a subscription. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.ipAddress] The private IP address to be verified. - * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -23725,7 +23224,7 @@ export interface VirtualNetworks { * * {Promise} A promise is returned. * - * @resolve {IPAddressAvailabilityResult} - The deserialized result object. + * @resolve {RouteTableListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -23733,25 +23232,35 @@ export interface VirtualNetworks { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {IPAddressAvailabilityResult} [result] - The deserialized result object if an error did not occur. - * See {@link IPAddressAvailabilityResult} for more - * information. + * {RouteTableListResult} [result] - The deserialized result object if an error did not occur. + * See {@link RouteTableListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - checkIPAddressAvailability(resourceGroupName: string, virtualNetworkName: string, options?: { ipAddress? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - checkIPAddressAvailability(resourceGroupName: string, virtualNetworkName: string, callback: ServiceCallback): void; - checkIPAddressAvailability(resourceGroupName: string, virtualNetworkName: string, options: { ipAddress? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAllNext(nextPageLink: string, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * Routes + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface Routes { /** - * Lists usage stats. + * Deletes the specified route from a route table. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} routeTableName The name of the route table. + * + * @param {string} routeName The name of the route. * * @param {object} [options] Optional Parameters. * @@ -23760,18 +23269,20 @@ export interface VirtualNetworks { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listUsageWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, routeName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists usage stats. + * Deletes the specified route from a route table. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} routeTableName The name of the route table. + * + * @param {string} routeName The name of the route. * * @param {object} [options] Optional Parameters. * @@ -23785,7 +23296,7 @@ export interface VirtualNetworks { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkListUsageResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -23793,25 +23304,25 @@ export interface VirtualNetworks { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkListUsageResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkListUsageResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listUsage(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listUsage(resourceGroupName: string, virtualNetworkName: string, callback: ServiceCallback): void; - listUsage(resourceGroupName: string, virtualNetworkName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, routeTableName: string, routeName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, routeTableName: string, routeName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, routeTableName: string, routeName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified virtual network. + * Gets the specified route from a route table. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} routeTableName The name of the route table. + * + * @param {string} routeName The name of the route. * * @param {object} [options] Optional Parameters. * @@ -23820,18 +23331,20 @@ export interface VirtualNetworks { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, routeName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified virtual network. + * Gets the specified route from a route table. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} routeTableName The name of the route table. + * + * @param {string} routeName The name of the route. * * @param {object} [options] Optional Parameters. * @@ -23845,7 +23358,7 @@ export interface VirtualNetworks { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {Route} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -23853,71 +23366,54 @@ export interface VirtualNetworks { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {Route} [result] - The deserialized result object if an error did not occur. + * See {@link Route} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, routeTableName: string, routeName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, routeTableName: string, routeName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, routeTableName: string, routeName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a virtual network in the specified resource group. + * Creates or updates a route in the specified route table. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. - * - * @param {object} parameters Parameters supplied to the create or update - * virtual network operation - * - * @param {object} [parameters.addressSpace] The AddressSpace that contains an - * array of IP address ranges that can be used by subnets. - * - * @param {array} [parameters.addressSpace.addressPrefixes] A list of address - * blocks reserved for this virtual network in CIDR notation. - * - * @param {object} [parameters.dhcpOptions] The dhcpOptions that contains an - * array of DNS servers available to VMs deployed in the virtual network. - * - * @param {array} [parameters.dhcpOptions.dnsServers] The list of DNS servers - * IP addresses. - * - * @param {array} [parameters.subnets] A list of subnets in a Virtual Network. + * @param {string} routeTableName The name of the route table. * - * @param {array} [parameters.virtualNetworkPeerings] A list of peerings in a - * Virtual Network. + * @param {string} routeName The name of the route. * - * @param {string} [parameters.resourceGuid] The resourceGuid property of the - * Virtual Network resource. + * @param {object} routeParameters Parameters supplied to the create or update + * route operation. * - * @param {string} [parameters.provisioningState] The provisioning state of the - * PublicIP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. + * @param {string} [routeParameters.addressPrefix] The destination CIDR to + * which the route applies. * - * @param {boolean} [parameters.enableDdosProtection] Indicates if DDoS - * protection is enabled for all the protected resources in the virtual - * network. It requires a DDoS protection plan associated with the resource. + * @param {string} routeParameters.nextHopType The type of Azure hop the packet + * should be sent to. Possible values are: 'VirtualNetworkGateway', + * 'VnetLocal', 'Internet', 'VirtualAppliance', and 'None'. Possible values + * include: 'VirtualNetworkGateway', 'VnetLocal', 'Internet', + * 'VirtualAppliance', 'None' * - * @param {boolean} [parameters.enableVmProtection] Indicates if VM protection - * is enabled for all the subnets in the virtual network. + * @param {string} [routeParameters.nextHopIpAddress] The IP address packets + * should be forwarded to. Next hop values are only allowed in routes where the + * next hop type is VirtualAppliance. * - * @param {object} [parameters.ddosProtectionPlan] The DDoS protection plan - * associated with the virtual network. + * @param {string} [routeParameters.provisioningState] The provisioning state + * of the resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. * - * @param {string} [parameters.ddosProtectionPlan.id] Resource ID. + * @param {string} [routeParameters.name] The name of the resource that is + * unique within a resource group. This name can be used to access the + * resource. * - * @param {string} [parameters.etag] Gets a unique read-only string that + * @param {string} [routeParameters.etag] A unique read-only string that * changes whenever the resource is updated. * - * @param {string} [parameters.id] Resource ID. - * - * @param {string} [parameters.location] Resource location. - * - * @param {object} [parameters.tags] Resource tags. + * @param {string} [routeParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -23926,66 +23422,48 @@ export interface VirtualNetworks { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, parameters: models.VirtualNetwork, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, routeName: string, routeParameters: models.Route, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a virtual network in the specified resource group. + * Creates or updates a route in the specified route table. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. - * - * @param {object} parameters Parameters supplied to the create or update - * virtual network operation - * - * @param {object} [parameters.addressSpace] The AddressSpace that contains an - * array of IP address ranges that can be used by subnets. - * - * @param {array} [parameters.addressSpace.addressPrefixes] A list of address - * blocks reserved for this virtual network in CIDR notation. - * - * @param {object} [parameters.dhcpOptions] The dhcpOptions that contains an - * array of DNS servers available to VMs deployed in the virtual network. - * - * @param {array} [parameters.dhcpOptions.dnsServers] The list of DNS servers - * IP addresses. - * - * @param {array} [parameters.subnets] A list of subnets in a Virtual Network. + * @param {string} routeTableName The name of the route table. * - * @param {array} [parameters.virtualNetworkPeerings] A list of peerings in a - * Virtual Network. + * @param {string} routeName The name of the route. * - * @param {string} [parameters.resourceGuid] The resourceGuid property of the - * Virtual Network resource. + * @param {object} routeParameters Parameters supplied to the create or update + * route operation. * - * @param {string} [parameters.provisioningState] The provisioning state of the - * PublicIP resource. Possible values are: 'Updating', 'Deleting', and - * 'Failed'. + * @param {string} [routeParameters.addressPrefix] The destination CIDR to + * which the route applies. * - * @param {boolean} [parameters.enableDdosProtection] Indicates if DDoS - * protection is enabled for all the protected resources in the virtual - * network. It requires a DDoS protection plan associated with the resource. + * @param {string} routeParameters.nextHopType The type of Azure hop the packet + * should be sent to. Possible values are: 'VirtualNetworkGateway', + * 'VnetLocal', 'Internet', 'VirtualAppliance', and 'None'. Possible values + * include: 'VirtualNetworkGateway', 'VnetLocal', 'Internet', + * 'VirtualAppliance', 'None' * - * @param {boolean} [parameters.enableVmProtection] Indicates if VM protection - * is enabled for all the subnets in the virtual network. + * @param {string} [routeParameters.nextHopIpAddress] The IP address packets + * should be forwarded to. Next hop values are only allowed in routes where the + * next hop type is VirtualAppliance. * - * @param {object} [parameters.ddosProtectionPlan] The DDoS protection plan - * associated with the virtual network. + * @param {string} [routeParameters.provisioningState] The provisioning state + * of the resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. * - * @param {string} [parameters.ddosProtectionPlan.id] Resource ID. + * @param {string} [routeParameters.name] The name of the resource that is + * unique within a resource group. This name can be used to access the + * resource. * - * @param {string} [parameters.etag] Gets a unique read-only string that + * @param {string} [routeParameters.etag] A unique read-only string that * changes whenever the resource is updated. * - * @param {string} [parameters.id] Resource ID. - * - * @param {string} [parameters.location] Resource location. - * - * @param {object} [parameters.tags] Resource tags. + * @param {string} [routeParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -23999,7 +23477,7 @@ export interface VirtualNetworks { * * {Promise} A promise is returned. * - * @resolve {VirtualNetwork} - The deserialized result object. + * @resolve {Route} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -24007,29 +23485,24 @@ export interface VirtualNetworks { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetwork} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetwork} for more information. + * {Route} [result] - The deserialized result object if an error did not occur. + * See {@link Route} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, parameters: models.VirtualNetwork, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, parameters: models.VirtualNetwork, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, parameters: models.VirtualNetwork, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, routeTableName: string, routeName: string, routeParameters: models.Route, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, routeTableName: string, routeName: string, routeParameters: models.Route, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, routeTableName: string, routeName: string, routeParameters: models.Route, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a virtual network tags. + * Gets all routes in a route table. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. - * - * @param {object} parameters Parameters supplied to update virtual network - * tags. - * - * @param {object} [parameters.tags] Resource tags. + * @param {string} routeTableName The name of the route table. * * @param {object} [options] Optional Parameters. * @@ -24038,23 +23511,18 @@ export interface VirtualNetworks { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a virtual network tags. + * Gets all routes in a route table. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. - * - * @param {object} parameters Parameters supplied to update virtual network - * tags. - * - * @param {object} [parameters.tags] Resource tags. + * @param {string} routeTableName The name of the route table. * * @param {object} [options] Optional Parameters. * @@ -24068,7 +23536,7 @@ export interface VirtualNetworks { * * {Promise} A promise is returned. * - * @resolve {VirtualNetwork} - The deserialized result object. + * @resolve {RouteListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -24076,23 +23544,26 @@ export interface VirtualNetworks { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetwork} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetwork} for more information. + * {RouteListResult} [result] - The deserialized result object if an error did not occur. + * See {@link RouteListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdateTags(resourceGroupName: string, virtualNetworkName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdateTags(resourceGroupName: string, virtualNetworkName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - beginUpdateTags(resourceGroupName: string, virtualNetworkName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, routeTableName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, routeTableName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, routeTableName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all virtual networks in a subscription. + * Deletes the specified route from a route table. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} routeTableName The name of the route table. + * + * @param {string} routeName The name of the route. * * @param {object} [options] Optional Parameters. * @@ -24101,17 +23572,20 @@ export interface VirtualNetworks { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, routeName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all virtual networks in a subscription. + * Deletes the specified route from a route table. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} routeTableName The name of the route table. + * + * @param {string} routeName The name of the route. * * @param {object} [options] Optional Parameters. * @@ -24125,7 +23599,7 @@ export interface VirtualNetworks { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -24133,43 +23607,103 @@ export interface VirtualNetworks { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkListResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listAllNext(nextPageLink: string, callback: ServiceCallback): void; - listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, routeTableName: string, routeName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, routeTableName: string, routeName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, routeTableName: string, routeName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all virtual networks in a resource group. + * Creates or updates a route in the specified route table. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. * - * @param {object} [options] Optional Parameters. + * @param {string} routeTableName The name of the route table. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} routeName The name of the route. * - * @returns {Promise} A promise is returned + * @param {object} routeParameters Parameters supplied to the create or update + * route operation. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} [routeParameters.addressPrefix] The destination CIDR to + * which the route applies. * - * @reject {Error|ServiceError} - The error object. - */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + * @param {string} routeParameters.nextHopType The type of Azure hop the packet + * should be sent to. Possible values are: 'VirtualNetworkGateway', + * 'VnetLocal', 'Internet', 'VirtualAppliance', and 'None'. Possible values + * include: 'VirtualNetworkGateway', 'VnetLocal', 'Internet', + * 'VirtualAppliance', 'None' + * + * @param {string} [routeParameters.nextHopIpAddress] The IP address packets + * should be forwarded to. Next hop values are only allowed in routes where the + * next hop type is VirtualAppliance. + * + * @param {string} [routeParameters.provisioningState] The provisioning state + * of the resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. + * + * @param {string} [routeParameters.name] The name of the resource that is + * unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [routeParameters.etag] A unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [routeParameters.id] Resource ID. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, routeTableName: string, routeName: string, routeParameters: models.Route, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all virtual networks in a resource group. + * Creates or updates a route in the specified route table. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} routeTableName The name of the route table. + * + * @param {string} routeName The name of the route. + * + * @param {object} routeParameters Parameters supplied to the create or update + * route operation. + * + * @param {string} [routeParameters.addressPrefix] The destination CIDR to + * which the route applies. + * + * @param {string} routeParameters.nextHopType The type of Azure hop the packet + * should be sent to. Possible values are: 'VirtualNetworkGateway', + * 'VnetLocal', 'Internet', 'VirtualAppliance', and 'None'. Possible values + * include: 'VirtualNetworkGateway', 'VnetLocal', 'Internet', + * 'VirtualAppliance', 'None' + * + * @param {string} [routeParameters.nextHopIpAddress] The IP address packets + * should be forwarded to. Next hop values are only allowed in routes where the + * next hop type is VirtualAppliance. + * + * @param {string} [routeParameters.provisioningState] The provisioning state + * of the resource. Possible values are: 'Updating', 'Deleting', and 'Failed'. + * + * @param {string} [routeParameters.name] The name of the resource that is + * unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [routeParameters.etag] A unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [routeParameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * @@ -24183,7 +23717,7 @@ export interface VirtualNetworks { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkListResult} - The deserialized result object. + * @resolve {Route} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -24191,21 +23725,20 @@ export interface VirtualNetworks { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkListResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkListResult} for more - * information. + * {Route} [result] - The deserialized result object if an error did not occur. + * See {@link Route} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, routeTableName: string, routeName: string, routeParameters: models.Route, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, routeTableName: string, routeName: string, routeParameters: models.Route, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, routeTableName: string, routeName: string, routeParameters: models.Route, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists usage stats. + * Gets all routes in a route table. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -24217,14 +23750,14 @@ export interface VirtualNetworks { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listUsageNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists usage stats. + * Gets all routes in a route table. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -24241,7 +23774,7 @@ export interface VirtualNetworks { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkListUsageResult} - The deserialized result object. + * @resolve {RouteListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -24249,36 +23782,29 @@ export interface VirtualNetworks { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkListUsageResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkListUsageResult} for more - * information. + * {RouteListResult} [result] - The deserialized result object if an error did not occur. + * See {@link RouteListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listUsageNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listUsageNext(nextPageLink: string, callback: ServiceCallback): void; - listUsageNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } /** * @class - * Subnets + * BgpServiceCommunities * __NOTE__: An instance of this class is automatically created for an * instance of the NetworkManagementClient. */ -export interface Subnets { +export interface BgpServiceCommunities { /** - * Deletes the specified subnet. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkName The name of the virtual network. - * - * @param {string} subnetName The name of the subnet. + * Gets all the available bgp service communities. * * @param {object} [options] Optional Parameters. * @@ -24287,20 +23813,14 @@ export interface Subnets { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified subnet. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkName The name of the virtual network. - * - * @param {string} subnetName The name of the subnet. + * Gets all the available bgp service communities. * * @param {object} [options] Optional Parameters. * @@ -24314,7 +23834,7 @@ export interface Subnets { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {BgpServiceCommunityListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -24322,54 +23842,46 @@ export interface Subnets { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {BgpServiceCommunityListResult} [result] - The deserialized result object if an error did not occur. + * See {@link BgpServiceCommunityListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, virtualNetworkName: string, subnetName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(callback: ServiceCallback): void; + list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified subnet by virtual network and resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkName The name of the virtual network. + * Gets all the available bgp service communities. * - * @param {string} subnetName The name of the subnet. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.expand] Expands referenced resources. - * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified subnet by virtual network and resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkName The name of the virtual network. + * Gets all the available bgp service communities. * - * @param {string} subnetName The name of the subnet. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.expand] Expands referenced resources. - * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -24380,7 +23892,7 @@ export interface Subnets { * * {Promise} A promise is returned. * - * @resolve {Subnet} - The deserialized result object. + * @resolve {BgpServiceCommunityListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -24388,99 +23900,155 @@ export interface Subnets { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {Subnet} [result] - The deserialized result object if an error did not occur. - * See {@link Subnet} for more information. + * {BgpServiceCommunityListResult} [result] - The deserialized result object if an error did not occur. + * See {@link BgpServiceCommunityListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, virtualNetworkName: string, subnetName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * Usages + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface Usages { /** - * Creates or updates a subnet in the specified virtual network. - * - * @param {string} resourceGroupName The name of the resource group. + * List network usages for a subscription. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} location The location where resource usage is queried. * - * @param {string} subnetName The name of the subnet. + * @param {object} [options] Optional Parameters. * - * @param {object} subnetParameters Parameters supplied to the create or update - * subnet operation. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [subnetParameters.addressPrefix] The address prefix for the - * subnet. + * @returns {Promise} A promise is returned * - * @param {object} [subnetParameters.networkSecurityGroup] The reference of the - * NetworkSecurityGroup resource. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {array} [subnetParameters.networkSecurityGroup.securityRules] A - * collection of security rules of the network security group. + * @reject {Error|ServiceError} - The error object. + */ + listWithHttpOperationResponse(location: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * List network usages for a subscription. * - * @param {array} [subnetParameters.networkSecurityGroup.defaultSecurityRules] - * The default security rules of network security group. + * @param {string} location The location where resource usage is queried. * - * @param {string} [subnetParameters.networkSecurityGroup.resourceGuid] The - * resource GUID property of the network security group resource. + * @param {object} [options] Optional Parameters. * - * @param {string} [subnetParameters.networkSecurityGroup.provisioningState] - * The provisioning state of the public IP resource. Possible values are: - * 'Updating', 'Deleting', and 'Failed'. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [subnetParameters.networkSecurityGroup.etag] A unique - * read-only string that changes whenever the resource is updated. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} [subnetParameters.networkSecurityGroup.id] Resource ID. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {string} [subnetParameters.networkSecurityGroup.location] Resource - * location. + * {Promise} A promise is returned. * - * @param {object} [subnetParameters.networkSecurityGroup.tags] Resource tags. + * @resolve {UsagesListResult} - The deserialized result object. * - * @param {object} [subnetParameters.routeTable] The reference of the - * RouteTable resource. + * @reject {Error|ServiceError} - The error object. * - * @param {array} [subnetParameters.routeTable.routes] Collection of routes - * contained within a route table. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {boolean} [subnetParameters.routeTable.disableBgpRoutePropagation] - * Gets or sets whether to disable the routes learned by BGP on that route - * table. True means disable. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [subnetParameters.routeTable.provisioningState] The - * provisioning state of the resource. Possible values are: 'Updating', - * 'Deleting', and 'Failed'. + * {UsagesListResult} [result] - The deserialized result object if an error did not occur. + * See {@link UsagesListResult} for more information. * - * @param {string} [subnetParameters.routeTable.etag] Gets a unique read-only - * string that changes whenever the resource is updated. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {string} [subnetParameters.routeTable.id] Resource ID. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + list(location: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(location: string, callback: ServiceCallback): void; + list(location: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * List network usages for a subscription. * - * @param {string} [subnetParameters.routeTable.location] Resource location. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {object} [subnetParameters.routeTable.tags] Resource tags. + * @param {object} [options] Optional Parameters. * - * @param {array} [subnetParameters.serviceEndpoints] An array of service - * endpoints. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {array} [subnetParameters.resourceNavigationLinks] Gets an array of - * references to the external resources using subnet. + * @returns {Promise} A promise is returned * - * @param {string} [subnetParameters.provisioningState] The provisioning state - * of the resource. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [subnetParameters.name] The name of the resource that is - * unique within a resource group. This name can be used to access the - * resource. + * @reject {Error|ServiceError} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * List network usages for a subscription. * - * @param {string} [subnetParameters.etag] A unique read-only string that - * changes whenever the resource is updated. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {string} [subnetParameters.id] Resource ID. + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {UsagesListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {UsagesListResult} [result] - The deserialized result object if an error did not occur. + * See {@link UsagesListResult} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * VirtualNetworks + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface VirtualNetworks { + + + /** + * Deletes the specified virtual network. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. * * @param {object} [options] Optional Parameters. * @@ -24489,93 +24057,5574 @@ export interface Subnets { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, subnetName: string, subnetParameters: models.Subnet, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a subnet in the specified virtual network. + * Deletes the specified virtual network. * * @param {string} resourceGroupName The name of the resource group. * * @param {string} virtualNetworkName The name of the virtual network. * - * @param {string} subnetName The name of the subnet. + * @param {object} [options] Optional Parameters. * - * @param {object} subnetParameters Parameters supplied to the create or update - * subnet operation. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [subnetParameters.addressPrefix] The address prefix for the - * subnet. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {object} [subnetParameters.networkSecurityGroup] The reference of the - * NetworkSecurityGroup resource. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {array} [subnetParameters.networkSecurityGroup.securityRules] A - * collection of security rules of the network security group. + * {Promise} A promise is returned. * - * @param {array} [subnetParameters.networkSecurityGroup.defaultSecurityRules] - * The default security rules of network security group. + * @resolve {null} - The deserialized result object. * - * @param {string} [subnetParameters.networkSecurityGroup.resourceGuid] The - * resource GUID property of the network security group resource. + * @reject {Error|ServiceError} - The error object. * - * @param {string} [subnetParameters.networkSecurityGroup.provisioningState] - * The provisioning state of the public IP resource. Possible values are: - * 'Updating', 'Deleting', and 'Failed'. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} [subnetParameters.networkSecurityGroup.etag] A unique - * read-only string that changes whenever the resource is updated. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [subnetParameters.networkSecurityGroup.id] Resource ID. + * {null} [result] - The deserialized result object if an error did not occur. * - * @param {string} [subnetParameters.networkSecurityGroup.location] Resource - * location. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {object} [subnetParameters.networkSecurityGroup.tags] Resource tags. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + deleteMethod(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, virtualNetworkName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, virtualNetworkName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets the specified virtual network by resource group. * - * @param {object} [subnetParameters.routeTable] The reference of the - * RouteTable resource. + * @param {string} resourceGroupName The name of the resource group. * - * @param {array} [subnetParameters.routeTable.routes] Collection of routes - * contained within a route table. + * @param {string} virtualNetworkName The name of the virtual network. * - * @param {boolean} [subnetParameters.routeTable.disableBgpRoutePropagation] - * Gets or sets whether to disable the routes learned by BGP on that route - * table. True means disable. + * @param {object} [options] Optional Parameters. * - * @param {string} [subnetParameters.routeTable.provisioningState] The - * provisioning state of the resource. Possible values are: 'Updating', - * 'Deleting', and 'Failed'. + * @param {string} [options.expand] Expands referenced resources. * - * @param {string} [subnetParameters.routeTable.etag] Gets a unique read-only - * string that changes whenever the resource is updated. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [subnetParameters.routeTable.id] Resource ID. + * @returns {Promise} A promise is returned * - * @param {string} [subnetParameters.routeTable.location] Resource location. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {object} [subnetParameters.routeTable.tags] Resource tags. + * @reject {Error|ServiceError} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets the specified virtual network by resource group. * - * @param {array} [subnetParameters.serviceEndpoints] An array of service - * endpoints. + * @param {string} resourceGroupName The name of the resource group. * - * @param {array} [subnetParameters.resourceNavigationLinks] Gets an array of - * references to the external resources using subnet. + * @param {string} virtualNetworkName The name of the virtual network. * - * @param {string} [subnetParameters.provisioningState] The provisioning state - * of the resource. + * @param {object} [options] Optional Parameters. + * + * @param {string} [options.expand] Expands referenced resources. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetwork} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetwork} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetwork} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName: string, virtualNetworkName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, virtualNetworkName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, virtualNetworkName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Creates or updates a virtual network in the specified resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} parameters Parameters supplied to the create or update + * virtual network operation + * + * @param {object} [parameters.addressSpace] The AddressSpace that contains an + * array of IP address ranges that can be used by subnets. + * + * @param {array} [parameters.addressSpace.addressPrefixes] A list of address + * blocks reserved for this virtual network in CIDR notation. + * + * @param {object} [parameters.dhcpOptions] The dhcpOptions that contains an + * array of DNS servers available to VMs deployed in the virtual network. + * + * @param {array} [parameters.dhcpOptions.dnsServers] The list of DNS servers + * IP addresses. + * + * @param {array} [parameters.subnets] A list of subnets in a Virtual Network. + * + * @param {array} [parameters.virtualNetworkPeerings] A list of peerings in a + * Virtual Network. + * + * @param {string} [parameters.resourceGuid] The resourceGuid property of the + * Virtual Network resource. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * PublicIP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. + * + * @param {boolean} [parameters.enableDdosProtection] Indicates if DDoS + * protection is enabled for all the protected resources in the virtual + * network. It requires a DDoS protection plan associated with the resource. + * + * @param {boolean} [parameters.enableVmProtection] Indicates if VM protection + * is enabled for all the subnets in the virtual network. + * + * @param {object} [parameters.ddosProtectionPlan] The DDoS protection plan + * associated with the virtual network. + * + * @param {string} [parameters.ddosProtectionPlan.id] Resource ID. + * + * @param {string} [parameters.etag] Gets a unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, parameters: models.VirtualNetwork, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a virtual network in the specified resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} parameters Parameters supplied to the create or update + * virtual network operation + * + * @param {object} [parameters.addressSpace] The AddressSpace that contains an + * array of IP address ranges that can be used by subnets. + * + * @param {array} [parameters.addressSpace.addressPrefixes] A list of address + * blocks reserved for this virtual network in CIDR notation. + * + * @param {object} [parameters.dhcpOptions] The dhcpOptions that contains an + * array of DNS servers available to VMs deployed in the virtual network. + * + * @param {array} [parameters.dhcpOptions.dnsServers] The list of DNS servers + * IP addresses. + * + * @param {array} [parameters.subnets] A list of subnets in a Virtual Network. + * + * @param {array} [parameters.virtualNetworkPeerings] A list of peerings in a + * Virtual Network. + * + * @param {string} [parameters.resourceGuid] The resourceGuid property of the + * Virtual Network resource. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * PublicIP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. + * + * @param {boolean} [parameters.enableDdosProtection] Indicates if DDoS + * protection is enabled for all the protected resources in the virtual + * network. It requires a DDoS protection plan associated with the resource. + * + * @param {boolean} [parameters.enableVmProtection] Indicates if VM protection + * is enabled for all the subnets in the virtual network. + * + * @param {object} [parameters.ddosProtectionPlan] The DDoS protection plan + * associated with the virtual network. + * + * @param {string} [parameters.ddosProtectionPlan.id] Resource ID. + * + * @param {string} [parameters.etag] Gets a unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetwork} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetwork} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetwork} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName: string, virtualNetworkName: string, parameters: models.VirtualNetwork, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, virtualNetworkName: string, parameters: models.VirtualNetwork, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, virtualNetworkName: string, parameters: models.VirtualNetwork, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Updates a virtual network tags. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} parameters Parameters supplied to update virtual network + * tags. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + updateTagsWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Updates a virtual network tags. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} parameters Parameters supplied to update virtual network + * tags. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetwork} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetwork} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetwork} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + updateTags(resourceGroupName: string, virtualNetworkName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, virtualNetworkName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, virtualNetworkName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all virtual networks in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listAllWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all virtual networks in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkListResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listAll(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAll(callback: ServiceCallback): void; + listAll(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all virtual networks in a resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all virtual networks in a resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkListResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Checks whether a private IP address is available for use. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} [options] Optional Parameters. + * + * @param {string} [options.ipAddress] The private IP address to be verified. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + checkIPAddressAvailabilityWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, options?: { ipAddress? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Checks whether a private IP address is available for use. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} [options] Optional Parameters. + * + * @param {string} [options.ipAddress] The private IP address to be verified. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {IPAddressAvailabilityResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {IPAddressAvailabilityResult} [result] - The deserialized result object if an error did not occur. + * See {@link IPAddressAvailabilityResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + checkIPAddressAvailability(resourceGroupName: string, virtualNetworkName: string, options?: { ipAddress? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + checkIPAddressAvailability(resourceGroupName: string, virtualNetworkName: string, callback: ServiceCallback): void; + checkIPAddressAvailability(resourceGroupName: string, virtualNetworkName: string, options: { ipAddress? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists usage stats. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listUsageWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists usage stats. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkListUsageResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkListUsageResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkListUsageResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listUsage(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listUsage(resourceGroupName: string, virtualNetworkName: string, callback: ServiceCallback): void; + listUsage(resourceGroupName: string, virtualNetworkName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes the specified virtual network. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes the specified virtual network. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Creates or updates a virtual network in the specified resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} parameters Parameters supplied to the create or update + * virtual network operation + * + * @param {object} [parameters.addressSpace] The AddressSpace that contains an + * array of IP address ranges that can be used by subnets. + * + * @param {array} [parameters.addressSpace.addressPrefixes] A list of address + * blocks reserved for this virtual network in CIDR notation. + * + * @param {object} [parameters.dhcpOptions] The dhcpOptions that contains an + * array of DNS servers available to VMs deployed in the virtual network. + * + * @param {array} [parameters.dhcpOptions.dnsServers] The list of DNS servers + * IP addresses. + * + * @param {array} [parameters.subnets] A list of subnets in a Virtual Network. + * + * @param {array} [parameters.virtualNetworkPeerings] A list of peerings in a + * Virtual Network. + * + * @param {string} [parameters.resourceGuid] The resourceGuid property of the + * Virtual Network resource. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * PublicIP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. + * + * @param {boolean} [parameters.enableDdosProtection] Indicates if DDoS + * protection is enabled for all the protected resources in the virtual + * network. It requires a DDoS protection plan associated with the resource. + * + * @param {boolean} [parameters.enableVmProtection] Indicates if VM protection + * is enabled for all the subnets in the virtual network. + * + * @param {object} [parameters.ddosProtectionPlan] The DDoS protection plan + * associated with the virtual network. + * + * @param {string} [parameters.ddosProtectionPlan.id] Resource ID. + * + * @param {string} [parameters.etag] Gets a unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, parameters: models.VirtualNetwork, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a virtual network in the specified resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} parameters Parameters supplied to the create or update + * virtual network operation + * + * @param {object} [parameters.addressSpace] The AddressSpace that contains an + * array of IP address ranges that can be used by subnets. + * + * @param {array} [parameters.addressSpace.addressPrefixes] A list of address + * blocks reserved for this virtual network in CIDR notation. + * + * @param {object} [parameters.dhcpOptions] The dhcpOptions that contains an + * array of DNS servers available to VMs deployed in the virtual network. + * + * @param {array} [parameters.dhcpOptions.dnsServers] The list of DNS servers + * IP addresses. + * + * @param {array} [parameters.subnets] A list of subnets in a Virtual Network. + * + * @param {array} [parameters.virtualNetworkPeerings] A list of peerings in a + * Virtual Network. + * + * @param {string} [parameters.resourceGuid] The resourceGuid property of the + * Virtual Network resource. + * + * @param {string} [parameters.provisioningState] The provisioning state of the + * PublicIP resource. Possible values are: 'Updating', 'Deleting', and + * 'Failed'. + * + * @param {boolean} [parameters.enableDdosProtection] Indicates if DDoS + * protection is enabled for all the protected resources in the virtual + * network. It requires a DDoS protection plan associated with the resource. + * + * @param {boolean} [parameters.enableVmProtection] Indicates if VM protection + * is enabled for all the subnets in the virtual network. + * + * @param {object} [parameters.ddosProtectionPlan] The DDoS protection plan + * associated with the virtual network. + * + * @param {string} [parameters.ddosProtectionPlan.id] Resource ID. + * + * @param {string} [parameters.etag] Gets a unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetwork} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetwork} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetwork} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, parameters: models.VirtualNetwork, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, parameters: models.VirtualNetwork, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, parameters: models.VirtualNetwork, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Updates a virtual network tags. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} parameters Parameters supplied to update virtual network + * tags. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Updates a virtual network tags. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} parameters Parameters supplied to update virtual network + * tags. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetwork} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetwork} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetwork} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginUpdateTags(resourceGroupName: string, virtualNetworkName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdateTags(resourceGroupName: string, virtualNetworkName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, virtualNetworkName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all virtual networks in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listAllNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all virtual networks in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkListResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listAllNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listAllNext(nextPageLink: string, callback: ServiceCallback): void; + listAllNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all virtual networks in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all virtual networks in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkListResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists usage stats. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listUsageNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists usage stats. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkListUsageResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkListUsageResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkListUsageResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listUsageNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listUsageNext(nextPageLink: string, callback: ServiceCallback): void; + listUsageNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * Subnets + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface Subnets { + + + /** + * Deletes the specified subnet. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} subnetName The name of the subnet. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + deleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes the specified subnet. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} subnetName The name of the subnet. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + deleteMethod(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, virtualNetworkName: string, subnetName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets the specified subnet by virtual network and resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} subnetName The name of the subnet. + * + * @param {object} [options] Optional Parameters. + * + * @param {string} [options.expand] Expands referenced resources. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets the specified subnet by virtual network and resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} subnetName The name of the subnet. + * + * @param {object} [options] Optional Parameters. + * + * @param {string} [options.expand] Expands referenced resources. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {Subnet} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {Subnet} [result] - The deserialized result object if an error did not occur. + * See {@link Subnet} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options?: { expand? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, virtualNetworkName: string, subnetName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options: { expand? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Creates or updates a subnet in the specified virtual network. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} subnetName The name of the subnet. + * + * @param {object} subnetParameters Parameters supplied to the create or update + * subnet operation. + * + * @param {string} [subnetParameters.addressPrefix] The address prefix for the + * subnet. + * + * @param {object} [subnetParameters.networkSecurityGroup] The reference of the + * NetworkSecurityGroup resource. + * + * @param {array} [subnetParameters.networkSecurityGroup.securityRules] A + * collection of security rules of the network security group. + * + * @param {array} [subnetParameters.networkSecurityGroup.defaultSecurityRules] + * The default security rules of network security group. + * + * @param {string} [subnetParameters.networkSecurityGroup.resourceGuid] The + * resource GUID property of the network security group resource. + * + * @param {string} [subnetParameters.networkSecurityGroup.provisioningState] + * The provisioning state of the public IP resource. Possible values are: + * 'Updating', 'Deleting', and 'Failed'. + * + * @param {string} [subnetParameters.networkSecurityGroup.etag] A unique + * read-only string that changes whenever the resource is updated. + * + * @param {string} [subnetParameters.networkSecurityGroup.id] Resource ID. + * + * @param {string} [subnetParameters.networkSecurityGroup.location] Resource + * location. + * + * @param {object} [subnetParameters.networkSecurityGroup.tags] Resource tags. + * + * @param {object} [subnetParameters.routeTable] The reference of the + * RouteTable resource. + * + * @param {array} [subnetParameters.routeTable.routes] Collection of routes + * contained within a route table. + * + * @param {boolean} [subnetParameters.routeTable.disableBgpRoutePropagation] + * Gets or sets whether to disable the routes learned by BGP on that route + * table. True means disable. + * + * @param {string} [subnetParameters.routeTable.provisioningState] The + * provisioning state of the resource. Possible values are: 'Updating', + * 'Deleting', and 'Failed'. + * + * @param {string} [subnetParameters.routeTable.etag] Gets a unique read-only + * string that changes whenever the resource is updated. + * + * @param {string} [subnetParameters.routeTable.id] Resource ID. + * + * @param {string} [subnetParameters.routeTable.location] Resource location. + * + * @param {object} [subnetParameters.routeTable.tags] Resource tags. + * + * @param {array} [subnetParameters.serviceEndpoints] An array of service + * endpoints. + * + * @param {array} [subnetParameters.resourceNavigationLinks] Gets an array of + * references to the external resources using subnet. + * + * @param {string} [subnetParameters.provisioningState] The provisioning state + * of the resource. + * + * @param {string} [subnetParameters.name] The name of the resource that is + * unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [subnetParameters.etag] A unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [subnetParameters.id] Resource ID. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, subnetName: string, subnetParameters: models.Subnet, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a subnet in the specified virtual network. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} subnetName The name of the subnet. + * + * @param {object} subnetParameters Parameters supplied to the create or update + * subnet operation. + * + * @param {string} [subnetParameters.addressPrefix] The address prefix for the + * subnet. + * + * @param {object} [subnetParameters.networkSecurityGroup] The reference of the + * NetworkSecurityGroup resource. + * + * @param {array} [subnetParameters.networkSecurityGroup.securityRules] A + * collection of security rules of the network security group. + * + * @param {array} [subnetParameters.networkSecurityGroup.defaultSecurityRules] + * The default security rules of network security group. + * + * @param {string} [subnetParameters.networkSecurityGroup.resourceGuid] The + * resource GUID property of the network security group resource. + * + * @param {string} [subnetParameters.networkSecurityGroup.provisioningState] + * The provisioning state of the public IP resource. Possible values are: + * 'Updating', 'Deleting', and 'Failed'. + * + * @param {string} [subnetParameters.networkSecurityGroup.etag] A unique + * read-only string that changes whenever the resource is updated. + * + * @param {string} [subnetParameters.networkSecurityGroup.id] Resource ID. + * + * @param {string} [subnetParameters.networkSecurityGroup.location] Resource + * location. + * + * @param {object} [subnetParameters.networkSecurityGroup.tags] Resource tags. + * + * @param {object} [subnetParameters.routeTable] The reference of the + * RouteTable resource. + * + * @param {array} [subnetParameters.routeTable.routes] Collection of routes + * contained within a route table. + * + * @param {boolean} [subnetParameters.routeTable.disableBgpRoutePropagation] + * Gets or sets whether to disable the routes learned by BGP on that route + * table. True means disable. + * + * @param {string} [subnetParameters.routeTable.provisioningState] The + * provisioning state of the resource. Possible values are: 'Updating', + * 'Deleting', and 'Failed'. + * + * @param {string} [subnetParameters.routeTable.etag] Gets a unique read-only + * string that changes whenever the resource is updated. + * + * @param {string} [subnetParameters.routeTable.id] Resource ID. + * + * @param {string} [subnetParameters.routeTable.location] Resource location. + * + * @param {object} [subnetParameters.routeTable.tags] Resource tags. + * + * @param {array} [subnetParameters.serviceEndpoints] An array of service + * endpoints. + * + * @param {array} [subnetParameters.resourceNavigationLinks] Gets an array of + * references to the external resources using subnet. + * + * @param {string} [subnetParameters.provisioningState] The provisioning state + * of the resource. + * + * @param {string} [subnetParameters.name] The name of the resource that is + * unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [subnetParameters.etag] A unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [subnetParameters.id] Resource ID. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {Subnet} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {Subnet} [result] - The deserialized result object if an error did not occur. + * See {@link Subnet} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName: string, virtualNetworkName: string, subnetName: string, subnetParameters: models.Subnet, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, virtualNetworkName: string, subnetName: string, subnetParameters: models.Subnet, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, virtualNetworkName: string, subnetName: string, subnetParameters: models.Subnet, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all subnets in a virtual network. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all subnets in a virtual network. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SubnetListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SubnetListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SubnetListResult} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + list(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, virtualNetworkName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, virtualNetworkName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes the specified subnet. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} subnetName The name of the subnet. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes the specified subnet. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} subnetName The name of the subnet. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, subnetName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Creates or updates a subnet in the specified virtual network. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} subnetName The name of the subnet. + * + * @param {object} subnetParameters Parameters supplied to the create or update + * subnet operation. + * + * @param {string} [subnetParameters.addressPrefix] The address prefix for the + * subnet. + * + * @param {object} [subnetParameters.networkSecurityGroup] The reference of the + * NetworkSecurityGroup resource. + * + * @param {array} [subnetParameters.networkSecurityGroup.securityRules] A + * collection of security rules of the network security group. + * + * @param {array} [subnetParameters.networkSecurityGroup.defaultSecurityRules] + * The default security rules of network security group. + * + * @param {string} [subnetParameters.networkSecurityGroup.resourceGuid] The + * resource GUID property of the network security group resource. + * + * @param {string} [subnetParameters.networkSecurityGroup.provisioningState] + * The provisioning state of the public IP resource. Possible values are: + * 'Updating', 'Deleting', and 'Failed'. + * + * @param {string} [subnetParameters.networkSecurityGroup.etag] A unique + * read-only string that changes whenever the resource is updated. + * + * @param {string} [subnetParameters.networkSecurityGroup.id] Resource ID. + * + * @param {string} [subnetParameters.networkSecurityGroup.location] Resource + * location. + * + * @param {object} [subnetParameters.networkSecurityGroup.tags] Resource tags. + * + * @param {object} [subnetParameters.routeTable] The reference of the + * RouteTable resource. + * + * @param {array} [subnetParameters.routeTable.routes] Collection of routes + * contained within a route table. + * + * @param {boolean} [subnetParameters.routeTable.disableBgpRoutePropagation] + * Gets or sets whether to disable the routes learned by BGP on that route + * table. True means disable. + * + * @param {string} [subnetParameters.routeTable.provisioningState] The + * provisioning state of the resource. Possible values are: 'Updating', + * 'Deleting', and 'Failed'. + * + * @param {string} [subnetParameters.routeTable.etag] Gets a unique read-only + * string that changes whenever the resource is updated. + * + * @param {string} [subnetParameters.routeTable.id] Resource ID. + * + * @param {string} [subnetParameters.routeTable.location] Resource location. + * + * @param {object} [subnetParameters.routeTable.tags] Resource tags. + * + * @param {array} [subnetParameters.serviceEndpoints] An array of service + * endpoints. + * + * @param {array} [subnetParameters.resourceNavigationLinks] Gets an array of + * references to the external resources using subnet. + * + * @param {string} [subnetParameters.provisioningState] The provisioning state + * of the resource. + * + * @param {string} [subnetParameters.name] The name of the resource that is + * unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [subnetParameters.etag] A unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [subnetParameters.id] Resource ID. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, subnetName: string, subnetParameters: models.Subnet, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a subnet in the specified virtual network. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} subnetName The name of the subnet. + * + * @param {object} subnetParameters Parameters supplied to the create or update + * subnet operation. + * + * @param {string} [subnetParameters.addressPrefix] The address prefix for the + * subnet. + * + * @param {object} [subnetParameters.networkSecurityGroup] The reference of the + * NetworkSecurityGroup resource. + * + * @param {array} [subnetParameters.networkSecurityGroup.securityRules] A + * collection of security rules of the network security group. + * + * @param {array} [subnetParameters.networkSecurityGroup.defaultSecurityRules] + * The default security rules of network security group. + * + * @param {string} [subnetParameters.networkSecurityGroup.resourceGuid] The + * resource GUID property of the network security group resource. + * + * @param {string} [subnetParameters.networkSecurityGroup.provisioningState] + * The provisioning state of the public IP resource. Possible values are: + * 'Updating', 'Deleting', and 'Failed'. + * + * @param {string} [subnetParameters.networkSecurityGroup.etag] A unique + * read-only string that changes whenever the resource is updated. + * + * @param {string} [subnetParameters.networkSecurityGroup.id] Resource ID. + * + * @param {string} [subnetParameters.networkSecurityGroup.location] Resource + * location. + * + * @param {object} [subnetParameters.networkSecurityGroup.tags] Resource tags. + * + * @param {object} [subnetParameters.routeTable] The reference of the + * RouteTable resource. + * + * @param {array} [subnetParameters.routeTable.routes] Collection of routes + * contained within a route table. + * + * @param {boolean} [subnetParameters.routeTable.disableBgpRoutePropagation] + * Gets or sets whether to disable the routes learned by BGP on that route + * table. True means disable. + * + * @param {string} [subnetParameters.routeTable.provisioningState] The + * provisioning state of the resource. Possible values are: 'Updating', + * 'Deleting', and 'Failed'. + * + * @param {string} [subnetParameters.routeTable.etag] Gets a unique read-only + * string that changes whenever the resource is updated. + * + * @param {string} [subnetParameters.routeTable.id] Resource ID. + * + * @param {string} [subnetParameters.routeTable.location] Resource location. + * + * @param {object} [subnetParameters.routeTable.tags] Resource tags. + * + * @param {array} [subnetParameters.serviceEndpoints] An array of service + * endpoints. + * + * @param {array} [subnetParameters.resourceNavigationLinks] Gets an array of + * references to the external resources using subnet. + * + * @param {string} [subnetParameters.provisioningState] The provisioning state + * of the resource. + * + * @param {string} [subnetParameters.name] The name of the resource that is + * unique within a resource group. This name can be used to access the + * resource. + * + * @param {string} [subnetParameters.etag] A unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [subnetParameters.id] Resource ID. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {Subnet} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {Subnet} [result] - The deserialized result object if an error did not occur. + * See {@link Subnet} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, subnetName: string, subnetParameters: models.Subnet, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, subnetName: string, subnetParameters: models.Subnet, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, subnetName: string, subnetParameters: models.Subnet, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all subnets in a virtual network. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all subnets in a virtual network. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SubnetListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SubnetListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SubnetListResult} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * VirtualNetworkPeerings + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface VirtualNetworkPeerings { + + + /** + * Deletes the specified virtual network peering. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} virtualNetworkPeeringName The name of the virtual network + * peering. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + deleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes the specified virtual network peering. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} virtualNetworkPeeringName The name of the virtual network + * peering. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + deleteMethod(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets the specified virtual network peering. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} virtualNetworkPeeringName The name of the virtual network + * peering. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets the specified virtual network peering. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} virtualNetworkPeeringName The name of the virtual network + * peering. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkPeering} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkPeering} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkPeering} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Creates or updates a peering in the specified virtual network. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} virtualNetworkPeeringName The name of the peering. + * + * @param {object} virtualNetworkPeeringParameters Parameters supplied to the + * create or update virtual network peering operation. + * + * @param {boolean} [virtualNetworkPeeringParameters.allowVirtualNetworkAccess] + * Whether the VMs in the linked virtual network space would be able to access + * all the VMs in local Virtual network space. + * + * @param {boolean} [virtualNetworkPeeringParameters.allowForwardedTraffic] + * Whether the forwarded traffic from the VMs in the remote virtual network + * will be allowed/disallowed. + * + * @param {boolean} [virtualNetworkPeeringParameters.allowGatewayTransit] If + * gateway links can be used in remote virtual networking to link to this + * virtual network. + * + * @param {boolean} [virtualNetworkPeeringParameters.useRemoteGateways] If + * remote gateways can be used on this virtual network. If the flag is set to + * true, and allowGatewayTransit on remote peering is also true, virtual + * network will use gateways of remote virtual network for transit. Only one + * peering can have this flag set to true. This flag cannot be set if virtual + * network already has a gateway. + * + * @param {object} [virtualNetworkPeeringParameters.remoteVirtualNetwork] The + * reference of the remote virtual network. The remote virtual network can be + * in the same or different region (preview). See here to register for the + * preview and learn more + * (https://docs.microsoft.com/en-us/azure/virtual-network/virtual-network-create-peering). + * + * @param {string} [virtualNetworkPeeringParameters.remoteVirtualNetwork.id] + * Resource ID. + * + * @param {object} [virtualNetworkPeeringParameters.remoteAddressSpace] The + * reference of the remote virtual network address space. + * + * @param {array} + * [virtualNetworkPeeringParameters.remoteAddressSpace.addressPrefixes] A list + * of address blocks reserved for this virtual network in CIDR notation. + * + * @param {string} [virtualNetworkPeeringParameters.peeringState] The status of + * the virtual network peering. Possible values are 'Initiated', 'Connected', + * and 'Disconnected'. Possible values include: 'Initiated', 'Connected', + * 'Disconnected' + * + * @param {string} [virtualNetworkPeeringParameters.provisioningState] The + * provisioning state of the resource. + * + * @param {string} [virtualNetworkPeeringParameters.name] The name of the + * resource that is unique within a resource group. This name can be used to + * access the resource. + * + * @param {string} [virtualNetworkPeeringParameters.etag] A unique read-only + * string that changes whenever the resource is updated. + * + * @param {string} [virtualNetworkPeeringParameters.id] Resource ID. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, virtualNetworkPeeringParameters: models.VirtualNetworkPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a peering in the specified virtual network. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} virtualNetworkPeeringName The name of the peering. + * + * @param {object} virtualNetworkPeeringParameters Parameters supplied to the + * create or update virtual network peering operation. + * + * @param {boolean} [virtualNetworkPeeringParameters.allowVirtualNetworkAccess] + * Whether the VMs in the linked virtual network space would be able to access + * all the VMs in local Virtual network space. + * + * @param {boolean} [virtualNetworkPeeringParameters.allowForwardedTraffic] + * Whether the forwarded traffic from the VMs in the remote virtual network + * will be allowed/disallowed. + * + * @param {boolean} [virtualNetworkPeeringParameters.allowGatewayTransit] If + * gateway links can be used in remote virtual networking to link to this + * virtual network. + * + * @param {boolean} [virtualNetworkPeeringParameters.useRemoteGateways] If + * remote gateways can be used on this virtual network. If the flag is set to + * true, and allowGatewayTransit on remote peering is also true, virtual + * network will use gateways of remote virtual network for transit. Only one + * peering can have this flag set to true. This flag cannot be set if virtual + * network already has a gateway. + * + * @param {object} [virtualNetworkPeeringParameters.remoteVirtualNetwork] The + * reference of the remote virtual network. The remote virtual network can be + * in the same or different region (preview). See here to register for the + * preview and learn more + * (https://docs.microsoft.com/en-us/azure/virtual-network/virtual-network-create-peering). + * + * @param {string} [virtualNetworkPeeringParameters.remoteVirtualNetwork.id] + * Resource ID. + * + * @param {object} [virtualNetworkPeeringParameters.remoteAddressSpace] The + * reference of the remote virtual network address space. + * + * @param {array} + * [virtualNetworkPeeringParameters.remoteAddressSpace.addressPrefixes] A list + * of address blocks reserved for this virtual network in CIDR notation. + * + * @param {string} [virtualNetworkPeeringParameters.peeringState] The status of + * the virtual network peering. Possible values are 'Initiated', 'Connected', + * and 'Disconnected'. Possible values include: 'Initiated', 'Connected', + * 'Disconnected' + * + * @param {string} [virtualNetworkPeeringParameters.provisioningState] The + * provisioning state of the resource. + * + * @param {string} [virtualNetworkPeeringParameters.name] The name of the + * resource that is unique within a resource group. This name can be used to + * access the resource. + * + * @param {string} [virtualNetworkPeeringParameters.etag] A unique read-only + * string that changes whenever the resource is updated. + * + * @param {string} [virtualNetworkPeeringParameters.id] Resource ID. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkPeering} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkPeering} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkPeering} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, virtualNetworkPeeringParameters: models.VirtualNetworkPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, virtualNetworkPeeringParameters: models.VirtualNetworkPeering, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, virtualNetworkPeeringParameters: models.VirtualNetworkPeering, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all virtual network peerings in a virtual network. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all virtual network peerings in a virtual network. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkPeeringListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkPeeringListResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkPeeringListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + list(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, virtualNetworkName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, virtualNetworkName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes the specified virtual network peering. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} virtualNetworkPeeringName The name of the virtual network + * peering. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes the specified virtual network peering. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} virtualNetworkPeeringName The name of the virtual network + * peering. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Creates or updates a peering in the specified virtual network. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} virtualNetworkPeeringName The name of the peering. + * + * @param {object} virtualNetworkPeeringParameters Parameters supplied to the + * create or update virtual network peering operation. + * + * @param {boolean} [virtualNetworkPeeringParameters.allowVirtualNetworkAccess] + * Whether the VMs in the linked virtual network space would be able to access + * all the VMs in local Virtual network space. + * + * @param {boolean} [virtualNetworkPeeringParameters.allowForwardedTraffic] + * Whether the forwarded traffic from the VMs in the remote virtual network + * will be allowed/disallowed. + * + * @param {boolean} [virtualNetworkPeeringParameters.allowGatewayTransit] If + * gateway links can be used in remote virtual networking to link to this + * virtual network. + * + * @param {boolean} [virtualNetworkPeeringParameters.useRemoteGateways] If + * remote gateways can be used on this virtual network. If the flag is set to + * true, and allowGatewayTransit on remote peering is also true, virtual + * network will use gateways of remote virtual network for transit. Only one + * peering can have this flag set to true. This flag cannot be set if virtual + * network already has a gateway. + * + * @param {object} [virtualNetworkPeeringParameters.remoteVirtualNetwork] The + * reference of the remote virtual network. The remote virtual network can be + * in the same or different region (preview). See here to register for the + * preview and learn more + * (https://docs.microsoft.com/en-us/azure/virtual-network/virtual-network-create-peering). + * + * @param {string} [virtualNetworkPeeringParameters.remoteVirtualNetwork.id] + * Resource ID. + * + * @param {object} [virtualNetworkPeeringParameters.remoteAddressSpace] The + * reference of the remote virtual network address space. + * + * @param {array} + * [virtualNetworkPeeringParameters.remoteAddressSpace.addressPrefixes] A list + * of address blocks reserved for this virtual network in CIDR notation. + * + * @param {string} [virtualNetworkPeeringParameters.peeringState] The status of + * the virtual network peering. Possible values are 'Initiated', 'Connected', + * and 'Disconnected'. Possible values include: 'Initiated', 'Connected', + * 'Disconnected' + * + * @param {string} [virtualNetworkPeeringParameters.provisioningState] The + * provisioning state of the resource. + * + * @param {string} [virtualNetworkPeeringParameters.name] The name of the + * resource that is unique within a resource group. This name can be used to + * access the resource. + * + * @param {string} [virtualNetworkPeeringParameters.etag] A unique read-only + * string that changes whenever the resource is updated. + * + * @param {string} [virtualNetworkPeeringParameters.id] Resource ID. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, virtualNetworkPeeringParameters: models.VirtualNetworkPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a peering in the specified virtual network. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkName The name of the virtual network. + * + * @param {string} virtualNetworkPeeringName The name of the peering. + * + * @param {object} virtualNetworkPeeringParameters Parameters supplied to the + * create or update virtual network peering operation. + * + * @param {boolean} [virtualNetworkPeeringParameters.allowVirtualNetworkAccess] + * Whether the VMs in the linked virtual network space would be able to access + * all the VMs in local Virtual network space. + * + * @param {boolean} [virtualNetworkPeeringParameters.allowForwardedTraffic] + * Whether the forwarded traffic from the VMs in the remote virtual network + * will be allowed/disallowed. + * + * @param {boolean} [virtualNetworkPeeringParameters.allowGatewayTransit] If + * gateway links can be used in remote virtual networking to link to this + * virtual network. + * + * @param {boolean} [virtualNetworkPeeringParameters.useRemoteGateways] If + * remote gateways can be used on this virtual network. If the flag is set to + * true, and allowGatewayTransit on remote peering is also true, virtual + * network will use gateways of remote virtual network for transit. Only one + * peering can have this flag set to true. This flag cannot be set if virtual + * network already has a gateway. + * + * @param {object} [virtualNetworkPeeringParameters.remoteVirtualNetwork] The + * reference of the remote virtual network. The remote virtual network can be + * in the same or different region (preview). See here to register for the + * preview and learn more + * (https://docs.microsoft.com/en-us/azure/virtual-network/virtual-network-create-peering). + * + * @param {string} [virtualNetworkPeeringParameters.remoteVirtualNetwork.id] + * Resource ID. + * + * @param {object} [virtualNetworkPeeringParameters.remoteAddressSpace] The + * reference of the remote virtual network address space. + * + * @param {array} + * [virtualNetworkPeeringParameters.remoteAddressSpace.addressPrefixes] A list + * of address blocks reserved for this virtual network in CIDR notation. + * + * @param {string} [virtualNetworkPeeringParameters.peeringState] The status of + * the virtual network peering. Possible values are 'Initiated', 'Connected', + * and 'Disconnected'. Possible values include: 'Initiated', 'Connected', + * 'Disconnected' + * + * @param {string} [virtualNetworkPeeringParameters.provisioningState] The + * provisioning state of the resource. + * + * @param {string} [virtualNetworkPeeringParameters.name] The name of the + * resource that is unique within a resource group. This name can be used to + * access the resource. + * + * @param {string} [virtualNetworkPeeringParameters.etag] A unique read-only + * string that changes whenever the resource is updated. + * + * @param {string} [virtualNetworkPeeringParameters.id] Resource ID. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkPeering} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkPeering} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkPeering} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, virtualNetworkPeeringParameters: models.VirtualNetworkPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, virtualNetworkPeeringParameters: models.VirtualNetworkPeering, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, virtualNetworkPeeringParameters: models.VirtualNetworkPeering, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all virtual network peerings in a virtual network. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all virtual network peerings in a virtual network. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkPeeringListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkPeeringListResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkPeeringListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * VirtualNetworkGateways + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface VirtualNetworkGateways { + + + /** + * Creates or updates a virtual network gateway in the specified resource + * group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} parameters Parameters supplied to create or update virtual + * network gateway operation. + * + * @param {array} [parameters.ipConfigurations] IP configurations for virtual + * network gateway. + * + * @param {string} [parameters.gatewayType] The type of this virtual network + * gateway. Possible values are: 'Vpn' and 'ExpressRoute'. Possible values + * include: 'Vpn', 'ExpressRoute' + * + * @param {string} [parameters.vpnType] The type of this virtual network + * gateway. Possible values are: 'PolicyBased' and 'RouteBased'. Possible + * values include: 'PolicyBased', 'RouteBased' + * + * @param {boolean} [parameters.enableBgp] Whether BGP is enabled for this + * virtual network gateway or not. + * + * @param {boolean} [parameters.activeActive] ActiveActive flag + * + * @param {object} [parameters.gatewayDefaultSite] The reference of the + * LocalNetworkGateway resource which represents local network site having + * default routes. Assign Null value in case of removing existing default site + * setting. + * + * @param {string} [parameters.gatewayDefaultSite.id] Resource ID. + * + * @param {object} [parameters.sku] The reference of the + * VirtualNetworkGatewaySku resource which represents the SKU selected for + * Virtual network gateway. + * + * @param {string} [parameters.sku.name] Gateway SKU name. Possible values + * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' + * + * @param {string} [parameters.sku.tier] Gateway SKU tier. Possible values + * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' + * + * @param {number} [parameters.sku.capacity] The capacity. + * + * @param {object} [parameters.vpnClientConfiguration] The reference of the + * VpnClientConfiguration resource which represents the P2S VpnClient + * configurations. + * + * @param {object} [parameters.vpnClientConfiguration.vpnClientAddressPool] The + * reference of the address space resource which represents Address space for + * P2S VpnClient. + * + * @param {array} + * [parameters.vpnClientConfiguration.vpnClientAddressPool.addressPrefixes] A + * list of address blocks reserved for this virtual network in CIDR notation. + * + * @param {array} [parameters.vpnClientConfiguration.vpnClientRootCertificates] + * VpnClientRootCertificate for virtual network gateway. + * + * @param {array} + * [parameters.vpnClientConfiguration.vpnClientRevokedCertificates] + * VpnClientRevokedCertificate for Virtual network gateway. + * + * @param {array} [parameters.vpnClientConfiguration.vpnClientProtocols] + * VpnClientProtocols for Virtual network gateway. + * + * @param {array} [parameters.vpnClientConfiguration.vpnClientIpsecPolicies] + * VpnClientIpsecPolicies for virtual network gateway P2S client. + * + * @param {string} [parameters.vpnClientConfiguration.radiusServerAddress] The + * radius server address property of the VirtualNetworkGateway resource for vpn + * client connection. + * + * @param {string} [parameters.vpnClientConfiguration.radiusServerSecret] The + * radius secret property of the VirtualNetworkGateway resource for vpn client + * connection. + * + * @param {object} [parameters.bgpSettings] Virtual network gateway's BGP + * speaker settings. + * + * @param {number} [parameters.bgpSettings.asn] The BGP speaker's ASN. + * + * @param {string} [parameters.bgpSettings.bgpPeeringAddress] The BGP peering + * address and BGP identifier of this BGP speaker. + * + * @param {number} [parameters.bgpSettings.peerWeight] The weight added to + * routes learned from this BGP speaker. + * + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * VirtualNetworkGateway resource. + * + * @param {string} [parameters.etag] Gets a unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VirtualNetworkGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a virtual network gateway in the specified resource + * group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} parameters Parameters supplied to create or update virtual + * network gateway operation. + * + * @param {array} [parameters.ipConfigurations] IP configurations for virtual + * network gateway. + * + * @param {string} [parameters.gatewayType] The type of this virtual network + * gateway. Possible values are: 'Vpn' and 'ExpressRoute'. Possible values + * include: 'Vpn', 'ExpressRoute' + * + * @param {string} [parameters.vpnType] The type of this virtual network + * gateway. Possible values are: 'PolicyBased' and 'RouteBased'. Possible + * values include: 'PolicyBased', 'RouteBased' + * + * @param {boolean} [parameters.enableBgp] Whether BGP is enabled for this + * virtual network gateway or not. + * + * @param {boolean} [parameters.activeActive] ActiveActive flag + * + * @param {object} [parameters.gatewayDefaultSite] The reference of the + * LocalNetworkGateway resource which represents local network site having + * default routes. Assign Null value in case of removing existing default site + * setting. + * + * @param {string} [parameters.gatewayDefaultSite.id] Resource ID. + * + * @param {object} [parameters.sku] The reference of the + * VirtualNetworkGatewaySku resource which represents the SKU selected for + * Virtual network gateway. + * + * @param {string} [parameters.sku.name] Gateway SKU name. Possible values + * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' + * + * @param {string} [parameters.sku.tier] Gateway SKU tier. Possible values + * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' + * + * @param {number} [parameters.sku.capacity] The capacity. + * + * @param {object} [parameters.vpnClientConfiguration] The reference of the + * VpnClientConfiguration resource which represents the P2S VpnClient + * configurations. + * + * @param {object} [parameters.vpnClientConfiguration.vpnClientAddressPool] The + * reference of the address space resource which represents Address space for + * P2S VpnClient. + * + * @param {array} + * [parameters.vpnClientConfiguration.vpnClientAddressPool.addressPrefixes] A + * list of address blocks reserved for this virtual network in CIDR notation. + * + * @param {array} [parameters.vpnClientConfiguration.vpnClientRootCertificates] + * VpnClientRootCertificate for virtual network gateway. + * + * @param {array} + * [parameters.vpnClientConfiguration.vpnClientRevokedCertificates] + * VpnClientRevokedCertificate for Virtual network gateway. + * + * @param {array} [parameters.vpnClientConfiguration.vpnClientProtocols] + * VpnClientProtocols for Virtual network gateway. + * + * @param {array} [parameters.vpnClientConfiguration.vpnClientIpsecPolicies] + * VpnClientIpsecPolicies for virtual network gateway P2S client. + * + * @param {string} [parameters.vpnClientConfiguration.radiusServerAddress] The + * radius server address property of the VirtualNetworkGateway resource for vpn + * client connection. + * + * @param {string} [parameters.vpnClientConfiguration.radiusServerSecret] The + * radius secret property of the VirtualNetworkGateway resource for vpn client + * connection. + * + * @param {object} [parameters.bgpSettings] Virtual network gateway's BGP + * speaker settings. + * + * @param {number} [parameters.bgpSettings.asn] The BGP speaker's ASN. + * + * @param {string} [parameters.bgpSettings.bgpPeeringAddress] The BGP peering + * address and BGP identifier of this BGP speaker. + * + * @param {number} [parameters.bgpSettings.peerWeight] The weight added to + * routes learned from this BGP speaker. + * + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * VirtualNetworkGateway resource. + * + * @param {string} [parameters.etag] Gets a unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkGateway} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkGateway} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGateway} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VirtualNetworkGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VirtualNetworkGateway, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VirtualNetworkGateway, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets the specified virtual network gateway by resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets the specified virtual network gateway by resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkGateway} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkGateway} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGateway} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes the specified virtual network gateway. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + deleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes the specified virtual network gateway. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + deleteMethod(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Updates a virtual network gateway tags. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} parameters Parameters supplied to update virtual network + * gateway tags. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + updateTagsWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Updates a virtual network gateway tags. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} parameters Parameters supplied to update virtual network + * gateway tags. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkGateway} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkGateway} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGateway} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + updateTags(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all virtual network gateways by resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all virtual network gateways by resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkGatewayListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkGatewayListResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGatewayListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all the connections in a virtual network gateway. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listConnectionsWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all the connections in a virtual network gateway. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkGatewayListConnectionsResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkGatewayListConnectionsResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGatewayListConnectionsResult} + * for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listConnections(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listConnections(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; + listConnections(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Resets the primary of the virtual network gateway in the specified resource + * group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {string} [options.gatewayVip] Virtual network gateway vip address + * supplied to the begin reset of the active-active feature enabled gateway. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + resetWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { gatewayVip? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Resets the primary of the virtual network gateway in the specified resource + * group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {string} [options.gatewayVip] Virtual network gateway vip address + * supplied to the begin reset of the active-active feature enabled gateway. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkGateway} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkGateway} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGateway} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + reset(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { gatewayVip? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + reset(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; + reset(resourceGroupName: string, virtualNetworkGatewayName: string, options: { gatewayVip? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Generates VPN client package for P2S client of the virtual network gateway + * in the specified resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} parameters Parameters supplied to the generate virtual + * network gateway VPN client package operation. + * + * @param {string} [parameters.processorArchitecture] VPN client Processor + * Architecture. Possible values are: 'AMD64' and 'X86'. Possible values + * include: 'Amd64', 'X86' + * + * @param {string} [parameters.authenticationMethod] VPN client Authentication + * Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values + * include: 'EAPTLS', 'EAPMSCHAPv2' + * + * @param {string} [parameters.radiusServerAuthCertificate] The public + * certificate data for the radius server authentication certificate as a + * Base-64 encoded string. Required only if external radius authentication has + * been configured with EAPTLS authentication. + * + * @param {array} [parameters.clientRootCertificates] A list of client root + * certificates public certificate data encoded as Base-64 strings. Optional + * parameter for external radius based authentication with EAPTLS. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + generatevpnclientpackageWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Generates VPN client package for P2S client of the virtual network gateway + * in the specified resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} parameters Parameters supplied to the generate virtual + * network gateway VPN client package operation. + * + * @param {string} [parameters.processorArchitecture] VPN client Processor + * Architecture. Possible values are: 'AMD64' and 'X86'. Possible values + * include: 'Amd64', 'X86' + * + * @param {string} [parameters.authenticationMethod] VPN client Authentication + * Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values + * include: 'EAPTLS', 'EAPMSCHAPv2' + * + * @param {string} [parameters.radiusServerAuthCertificate] The public + * certificate data for the radius server authentication certificate as a + * Base-64 encoded string. Required only if external radius authentication has + * been configured with EAPTLS authentication. + * + * @param {array} [parameters.clientRootCertificates] A list of client root + * certificates public certificate data encoded as Base-64 strings. Optional + * parameter for external radius based authentication with EAPTLS. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {String} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {String} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + generatevpnclientpackage(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + generatevpnclientpackage(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, callback: ServiceCallback): void; + generatevpnclientpackage(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Generates VPN profile for P2S client of the virtual network gateway in the + * specified resource group. Used for IKEV2 and radius based authentication. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} parameters Parameters supplied to the generate virtual + * network gateway VPN client package operation. + * + * @param {string} [parameters.processorArchitecture] VPN client Processor + * Architecture. Possible values are: 'AMD64' and 'X86'. Possible values + * include: 'Amd64', 'X86' + * + * @param {string} [parameters.authenticationMethod] VPN client Authentication + * Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values + * include: 'EAPTLS', 'EAPMSCHAPv2' + * + * @param {string} [parameters.radiusServerAuthCertificate] The public + * certificate data for the radius server authentication certificate as a + * Base-64 encoded string. Required only if external radius authentication has + * been configured with EAPTLS authentication. + * + * @param {array} [parameters.clientRootCertificates] A list of client root + * certificates public certificate data encoded as Base-64 strings. Optional + * parameter for external radius based authentication with EAPTLS. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + generateVpnProfileWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Generates VPN profile for P2S client of the virtual network gateway in the + * specified resource group. Used for IKEV2 and radius based authentication. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} parameters Parameters supplied to the generate virtual + * network gateway VPN client package operation. + * + * @param {string} [parameters.processorArchitecture] VPN client Processor + * Architecture. Possible values are: 'AMD64' and 'X86'. Possible values + * include: 'Amd64', 'X86' + * + * @param {string} [parameters.authenticationMethod] VPN client Authentication + * Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values + * include: 'EAPTLS', 'EAPMSCHAPv2' + * + * @param {string} [parameters.radiusServerAuthCertificate] The public + * certificate data for the radius server authentication certificate as a + * Base-64 encoded string. Required only if external radius authentication has + * been configured with EAPTLS authentication. + * + * @param {array} [parameters.clientRootCertificates] A list of client root + * certificates public certificate data encoded as Base-64 strings. Optional + * parameter for external radius based authentication with EAPTLS. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {String} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {String} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + generateVpnProfile(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + generateVpnProfile(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, callback: ServiceCallback): void; + generateVpnProfile(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets pre-generated VPN profile for P2S client of the virtual network gateway + * in the specified resource group. The profile needs to be generated first + * using generateVpnProfile. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + getVpnProfilePackageUrlWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets pre-generated VPN profile for P2S client of the virtual network gateway + * in the specified resource group. The profile needs to be generated first + * using generateVpnProfile. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {String} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {String} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + getVpnProfilePackageUrl(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getVpnProfilePackageUrl(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; + getVpnProfilePackageUrl(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * The GetBgpPeerStatus operation retrieves the status of all BGP peers. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {string} [options.peer] The IP address of the peer to retrieve the + * status of. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + getBgpPeerStatusWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { peer? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * The GetBgpPeerStatus operation retrieves the status of all BGP peers. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {string} [options.peer] The IP address of the peer to retrieve the + * status of. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {BgpPeerStatusListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {BgpPeerStatusListResult} [result] - The deserialized result object if an error did not occur. + * See {@link BgpPeerStatusListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + getBgpPeerStatus(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { peer? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + getBgpPeerStatus(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; + getBgpPeerStatus(resourceGroupName: string, virtualNetworkGatewayName: string, options: { peer? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets a xml format representation for supported vpn devices. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + supportedVpnDevicesWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a xml format representation for supported vpn devices. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {String} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {String} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + supportedVpnDevices(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + supportedVpnDevices(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; + supportedVpnDevices(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * This operation retrieves a list of routes the virtual network gateway has + * learned, including routes learned from BGP peers. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + getLearnedRoutesWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * This operation retrieves a list of routes the virtual network gateway has + * learned, including routes learned from BGP peers. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {GatewayRouteListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {GatewayRouteListResult} [result] - The deserialized result object if an error did not occur. + * See {@link GatewayRouteListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + getLearnedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getLearnedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; + getLearnedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * This operation retrieves a list of routes the virtual network gateway is + * advertising to the specified peer. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {string} peer The IP address of the peer + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + getAdvertisedRoutesWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, peer: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * This operation retrieves a list of routes the virtual network gateway is + * advertising to the specified peer. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {string} peer The IP address of the peer + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {GatewayRouteListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {GatewayRouteListResult} [result] - The deserialized result object if an error did not occur. + * See {@link GatewayRouteListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + getAdvertisedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, peer: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getAdvertisedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, peer: string, callback: ServiceCallback): void; + getAdvertisedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, peer: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * The Set VpnclientIpsecParameters operation sets the vpnclient ipsec policy + * for P2S client of virtual network gateway in the specified resource group + * through Network resource provider. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} vpnclientIpsecParams Parameters supplied to the Begin Set + * vpnclient ipsec parameters of Virtual Network Gateway P2S client operation + * through Network resource provider. + * + * @param {number} vpnclientIpsecParams.saLifeTimeSeconds The IPSec Security + * Association (also called Quick Mode or Phase 2 SA) lifetime in seconds for + * P2S client. + * + * @param {number} vpnclientIpsecParams.saDataSizeKilobytes The IPSec Security + * Association (also called Quick Mode or Phase 2 SA) payload size in KB for + * P2S client.. + * + * @param {string} vpnclientIpsecParams.ipsecEncryption The IPSec encryption + * algorithm (IKE phase 1). Possible values include: 'None', 'DES', 'DES3', + * 'AES128', 'AES192', 'AES256', 'GCMAES128', 'GCMAES192', 'GCMAES256' + * + * @param {string} vpnclientIpsecParams.ipsecIntegrity The IPSec integrity + * algorithm (IKE phase 1). Possible values include: 'MD5', 'SHA1', 'SHA256', + * 'GCMAES128', 'GCMAES192', 'GCMAES256' + * + * @param {string} vpnclientIpsecParams.ikeEncryption The IKE encryption + * algorithm (IKE phase 2). Possible values include: 'DES', 'DES3', 'AES128', + * 'AES192', 'AES256', 'GCMAES256', 'GCMAES128' + * + * @param {string} vpnclientIpsecParams.ikeIntegrity The IKE integrity + * algorithm (IKE phase 2). Possible values include: 'MD5', 'SHA1', 'SHA256', + * 'SHA384', 'GCMAES256', 'GCMAES128' + * + * @param {string} vpnclientIpsecParams.dhGroup The DH Groups used in IKE Phase + * 1 for initial SA. Possible values include: 'None', 'DHGroup1', 'DHGroup2', + * 'DHGroup14', 'DHGroup2048', 'ECP256', 'ECP384', 'DHGroup24' + * + * @param {string} vpnclientIpsecParams.pfsGroup The Pfs Groups used in IKE + * Phase 2 for new child SA. Possible values include: 'None', 'PFS1', 'PFS2', + * 'PFS2048', 'ECP256', 'ECP384', 'PFS24', 'PFS14', 'PFSMM' + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + setVpnclientIpsecParametersWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, vpnclientIpsecParams: models.VpnClientIPsecParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * The Set VpnclientIpsecParameters operation sets the vpnclient ipsec policy + * for P2S client of virtual network gateway in the specified resource group + * through Network resource provider. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} vpnclientIpsecParams Parameters supplied to the Begin Set + * vpnclient ipsec parameters of Virtual Network Gateway P2S client operation + * through Network resource provider. + * + * @param {number} vpnclientIpsecParams.saLifeTimeSeconds The IPSec Security + * Association (also called Quick Mode or Phase 2 SA) lifetime in seconds for + * P2S client. + * + * @param {number} vpnclientIpsecParams.saDataSizeKilobytes The IPSec Security + * Association (also called Quick Mode or Phase 2 SA) payload size in KB for + * P2S client.. + * + * @param {string} vpnclientIpsecParams.ipsecEncryption The IPSec encryption + * algorithm (IKE phase 1). Possible values include: 'None', 'DES', 'DES3', + * 'AES128', 'AES192', 'AES256', 'GCMAES128', 'GCMAES192', 'GCMAES256' + * + * @param {string} vpnclientIpsecParams.ipsecIntegrity The IPSec integrity + * algorithm (IKE phase 1). Possible values include: 'MD5', 'SHA1', 'SHA256', + * 'GCMAES128', 'GCMAES192', 'GCMAES256' + * + * @param {string} vpnclientIpsecParams.ikeEncryption The IKE encryption + * algorithm (IKE phase 2). Possible values include: 'DES', 'DES3', 'AES128', + * 'AES192', 'AES256', 'GCMAES256', 'GCMAES128' + * + * @param {string} vpnclientIpsecParams.ikeIntegrity The IKE integrity + * algorithm (IKE phase 2). Possible values include: 'MD5', 'SHA1', 'SHA256', + * 'SHA384', 'GCMAES256', 'GCMAES128' + * + * @param {string} vpnclientIpsecParams.dhGroup The DH Groups used in IKE Phase + * 1 for initial SA. Possible values include: 'None', 'DHGroup1', 'DHGroup2', + * 'DHGroup14', 'DHGroup2048', 'ECP256', 'ECP384', 'DHGroup24' + * + * @param {string} vpnclientIpsecParams.pfsGroup The Pfs Groups used in IKE + * Phase 2 for new child SA. Possible values include: 'None', 'PFS1', 'PFS2', + * 'PFS2048', 'ECP256', 'ECP384', 'PFS24', 'PFS14', 'PFSMM' + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VpnClientIPsecParameters} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VpnClientIPsecParameters} [result] - The deserialized result object if an error did not occur. + * See {@link VpnClientIPsecParameters} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + setVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, vpnclientIpsecParams: models.VpnClientIPsecParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + setVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, vpnclientIpsecParams: models.VpnClientIPsecParameters, callback: ServiceCallback): void; + setVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, vpnclientIpsecParams: models.VpnClientIPsecParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * The Get VpnclientIpsecParameters operation retrieves information about the + * vpnclient ipsec policy for P2S client of virtual network gateway in the + * specified resource group through Network resource provider. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The virtual network gateway name. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + getVpnclientIpsecParametersWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * The Get VpnclientIpsecParameters operation retrieves information about the + * vpnclient ipsec policy for P2S client of virtual network gateway in the + * specified resource group through Network resource provider. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The virtual network gateway name. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VpnClientIPsecParameters} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VpnClientIPsecParameters} [result] - The deserialized result object if an error did not occur. + * See {@link VpnClientIPsecParameters} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + getVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; + getVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets a xml format representation for vpn device configuration script. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayConnectionName The name of the virtual + * network gateway connection for which the configuration script is generated. + * + * @param {object} parameters Parameters supplied to the generate vpn device + * script operation. + * + * @param {string} [parameters.vendor] The vendor for the vpn device. + * + * @param {string} [parameters.deviceFamily] The device family for the vpn + * device. + * + * @param {string} [parameters.firmwareVersion] The firmware version for the + * vpn device. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + vpnDeviceConfigurationScriptWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VpnDeviceScriptParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a xml format representation for vpn device configuration script. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayConnectionName The name of the virtual + * network gateway connection for which the configuration script is generated. + * + * @param {object} parameters Parameters supplied to the generate vpn device + * script operation. + * + * @param {string} [parameters.vendor] The vendor for the vpn device. + * + * @param {string} [parameters.deviceFamily] The device family for the vpn + * device. + * + * @param {string} [parameters.firmwareVersion] The firmware version for the + * vpn device. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {String} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {String} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + vpnDeviceConfigurationScript(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VpnDeviceScriptParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + vpnDeviceConfigurationScript(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VpnDeviceScriptParameters, callback: ServiceCallback): void; + vpnDeviceConfigurationScript(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VpnDeviceScriptParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Creates or updates a virtual network gateway in the specified resource + * group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} parameters Parameters supplied to create or update virtual + * network gateway operation. + * + * @param {array} [parameters.ipConfigurations] IP configurations for virtual + * network gateway. + * + * @param {string} [parameters.gatewayType] The type of this virtual network + * gateway. Possible values are: 'Vpn' and 'ExpressRoute'. Possible values + * include: 'Vpn', 'ExpressRoute' + * + * @param {string} [parameters.vpnType] The type of this virtual network + * gateway. Possible values are: 'PolicyBased' and 'RouteBased'. Possible + * values include: 'PolicyBased', 'RouteBased' + * + * @param {boolean} [parameters.enableBgp] Whether BGP is enabled for this + * virtual network gateway or not. + * + * @param {boolean} [parameters.activeActive] ActiveActive flag + * + * @param {object} [parameters.gatewayDefaultSite] The reference of the + * LocalNetworkGateway resource which represents local network site having + * default routes. Assign Null value in case of removing existing default site + * setting. + * + * @param {string} [parameters.gatewayDefaultSite.id] Resource ID. + * + * @param {object} [parameters.sku] The reference of the + * VirtualNetworkGatewaySku resource which represents the SKU selected for + * Virtual network gateway. + * + * @param {string} [parameters.sku.name] Gateway SKU name. Possible values + * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' + * + * @param {string} [parameters.sku.tier] Gateway SKU tier. Possible values + * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' + * + * @param {number} [parameters.sku.capacity] The capacity. + * + * @param {object} [parameters.vpnClientConfiguration] The reference of the + * VpnClientConfiguration resource which represents the P2S VpnClient + * configurations. + * + * @param {object} [parameters.vpnClientConfiguration.vpnClientAddressPool] The + * reference of the address space resource which represents Address space for + * P2S VpnClient. + * + * @param {array} + * [parameters.vpnClientConfiguration.vpnClientAddressPool.addressPrefixes] A + * list of address blocks reserved for this virtual network in CIDR notation. + * + * @param {array} [parameters.vpnClientConfiguration.vpnClientRootCertificates] + * VpnClientRootCertificate for virtual network gateway. + * + * @param {array} + * [parameters.vpnClientConfiguration.vpnClientRevokedCertificates] + * VpnClientRevokedCertificate for Virtual network gateway. + * + * @param {array} [parameters.vpnClientConfiguration.vpnClientProtocols] + * VpnClientProtocols for Virtual network gateway. + * + * @param {array} [parameters.vpnClientConfiguration.vpnClientIpsecPolicies] + * VpnClientIpsecPolicies for virtual network gateway P2S client. + * + * @param {string} [parameters.vpnClientConfiguration.radiusServerAddress] The + * radius server address property of the VirtualNetworkGateway resource for vpn + * client connection. + * + * @param {string} [parameters.vpnClientConfiguration.radiusServerSecret] The + * radius secret property of the VirtualNetworkGateway resource for vpn client + * connection. + * + * @param {object} [parameters.bgpSettings] Virtual network gateway's BGP + * speaker settings. + * + * @param {number} [parameters.bgpSettings.asn] The BGP speaker's ASN. + * + * @param {string} [parameters.bgpSettings.bgpPeeringAddress] The BGP peering + * address and BGP identifier of this BGP speaker. + * + * @param {number} [parameters.bgpSettings.peerWeight] The weight added to + * routes learned from this BGP speaker. + * + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * VirtualNetworkGateway resource. + * + * @param {string} [parameters.etag] Gets a unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VirtualNetworkGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a virtual network gateway in the specified resource + * group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} parameters Parameters supplied to create or update virtual + * network gateway operation. + * + * @param {array} [parameters.ipConfigurations] IP configurations for virtual + * network gateway. + * + * @param {string} [parameters.gatewayType] The type of this virtual network + * gateway. Possible values are: 'Vpn' and 'ExpressRoute'. Possible values + * include: 'Vpn', 'ExpressRoute' + * + * @param {string} [parameters.vpnType] The type of this virtual network + * gateway. Possible values are: 'PolicyBased' and 'RouteBased'. Possible + * values include: 'PolicyBased', 'RouteBased' + * + * @param {boolean} [parameters.enableBgp] Whether BGP is enabled for this + * virtual network gateway or not. + * + * @param {boolean} [parameters.activeActive] ActiveActive flag + * + * @param {object} [parameters.gatewayDefaultSite] The reference of the + * LocalNetworkGateway resource which represents local network site having + * default routes. Assign Null value in case of removing existing default site + * setting. + * + * @param {string} [parameters.gatewayDefaultSite.id] Resource ID. + * + * @param {object} [parameters.sku] The reference of the + * VirtualNetworkGatewaySku resource which represents the SKU selected for + * Virtual network gateway. + * + * @param {string} [parameters.sku.name] Gateway SKU name. Possible values + * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' + * + * @param {string} [parameters.sku.tier] Gateway SKU tier. Possible values + * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' + * + * @param {number} [parameters.sku.capacity] The capacity. + * + * @param {object} [parameters.vpnClientConfiguration] The reference of the + * VpnClientConfiguration resource which represents the P2S VpnClient + * configurations. + * + * @param {object} [parameters.vpnClientConfiguration.vpnClientAddressPool] The + * reference of the address space resource which represents Address space for + * P2S VpnClient. + * + * @param {array} + * [parameters.vpnClientConfiguration.vpnClientAddressPool.addressPrefixes] A + * list of address blocks reserved for this virtual network in CIDR notation. + * + * @param {array} [parameters.vpnClientConfiguration.vpnClientRootCertificates] + * VpnClientRootCertificate for virtual network gateway. + * + * @param {array} + * [parameters.vpnClientConfiguration.vpnClientRevokedCertificates] + * VpnClientRevokedCertificate for Virtual network gateway. + * + * @param {array} [parameters.vpnClientConfiguration.vpnClientProtocols] + * VpnClientProtocols for Virtual network gateway. + * + * @param {array} [parameters.vpnClientConfiguration.vpnClientIpsecPolicies] + * VpnClientIpsecPolicies for virtual network gateway P2S client. + * + * @param {string} [parameters.vpnClientConfiguration.radiusServerAddress] The + * radius server address property of the VirtualNetworkGateway resource for vpn + * client connection. + * + * @param {string} [parameters.vpnClientConfiguration.radiusServerSecret] The + * radius secret property of the VirtualNetworkGateway resource for vpn client + * connection. + * + * @param {object} [parameters.bgpSettings] Virtual network gateway's BGP + * speaker settings. + * + * @param {number} [parameters.bgpSettings.asn] The BGP speaker's ASN. + * + * @param {string} [parameters.bgpSettings.bgpPeeringAddress] The BGP peering + * address and BGP identifier of this BGP speaker. + * + * @param {number} [parameters.bgpSettings.peerWeight] The weight added to + * routes learned from this BGP speaker. + * + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * VirtualNetworkGateway resource. + * + * @param {string} [parameters.etag] Gets a unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkGateway} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkGateway} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGateway} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginCreateOrUpdate(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VirtualNetworkGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VirtualNetworkGateway, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VirtualNetworkGateway, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes the specified virtual network gateway. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes the specified virtual network gateway. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Updates a virtual network gateway tags. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} parameters Parameters supplied to update virtual network + * gateway tags. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Updates a virtual network gateway tags. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} parameters Parameters supplied to update virtual network + * gateway tags. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkGateway} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkGateway} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGateway} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginUpdateTags(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdateTags(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Resets the primary of the virtual network gateway in the specified resource + * group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {string} [options.gatewayVip] Virtual network gateway vip address + * supplied to the begin reset of the active-active feature enabled gateway. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginResetWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { gatewayVip? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Resets the primary of the virtual network gateway in the specified resource + * group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {string} [options.gatewayVip] Virtual network gateway vip address + * supplied to the begin reset of the active-active feature enabled gateway. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkGateway} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkGateway} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGateway} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginReset(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { gatewayVip? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + beginReset(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; + beginReset(resourceGroupName: string, virtualNetworkGatewayName: string, options: { gatewayVip? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Generates VPN client package for P2S client of the virtual network gateway + * in the specified resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} parameters Parameters supplied to the generate virtual + * network gateway VPN client package operation. + * + * @param {string} [parameters.processorArchitecture] VPN client Processor + * Architecture. Possible values are: 'AMD64' and 'X86'. Possible values + * include: 'Amd64', 'X86' + * + * @param {string} [parameters.authenticationMethod] VPN client Authentication + * Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values + * include: 'EAPTLS', 'EAPMSCHAPv2' + * + * @param {string} [parameters.radiusServerAuthCertificate] The public + * certificate data for the radius server authentication certificate as a + * Base-64 encoded string. Required only if external radius authentication has + * been configured with EAPTLS authentication. + * + * @param {array} [parameters.clientRootCertificates] A list of client root + * certificates public certificate data encoded as Base-64 strings. Optional + * parameter for external radius based authentication with EAPTLS. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginGeneratevpnclientpackageWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Generates VPN client package for P2S client of the virtual network gateway + * in the specified resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} parameters Parameters supplied to the generate virtual + * network gateway VPN client package operation. + * + * @param {string} [parameters.processorArchitecture] VPN client Processor + * Architecture. Possible values are: 'AMD64' and 'X86'. Possible values + * include: 'Amd64', 'X86' + * + * @param {string} [parameters.authenticationMethod] VPN client Authentication + * Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values + * include: 'EAPTLS', 'EAPMSCHAPv2' + * + * @param {string} [parameters.radiusServerAuthCertificate] The public + * certificate data for the radius server authentication certificate as a + * Base-64 encoded string. Required only if external radius authentication has + * been configured with EAPTLS authentication. + * + * @param {array} [parameters.clientRootCertificates] A list of client root + * certificates public certificate data encoded as Base-64 strings. Optional + * parameter for external radius based authentication with EAPTLS. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {String} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {String} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginGeneratevpnclientpackage(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginGeneratevpnclientpackage(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, callback: ServiceCallback): void; + beginGeneratevpnclientpackage(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Generates VPN profile for P2S client of the virtual network gateway in the + * specified resource group. Used for IKEV2 and radius based authentication. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} parameters Parameters supplied to the generate virtual + * network gateway VPN client package operation. + * + * @param {string} [parameters.processorArchitecture] VPN client Processor + * Architecture. Possible values are: 'AMD64' and 'X86'. Possible values + * include: 'Amd64', 'X86' + * + * @param {string} [parameters.authenticationMethod] VPN client Authentication + * Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values + * include: 'EAPTLS', 'EAPMSCHAPv2' + * + * @param {string} [parameters.radiusServerAuthCertificate] The public + * certificate data for the radius server authentication certificate as a + * Base-64 encoded string. Required only if external radius authentication has + * been configured with EAPTLS authentication. + * + * @param {array} [parameters.clientRootCertificates] A list of client root + * certificates public certificate data encoded as Base-64 strings. Optional + * parameter for external radius based authentication with EAPTLS. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginGenerateVpnProfileWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Generates VPN profile for P2S client of the virtual network gateway in the + * specified resource group. Used for IKEV2 and radius based authentication. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} parameters Parameters supplied to the generate virtual + * network gateway VPN client package operation. + * + * @param {string} [parameters.processorArchitecture] VPN client Processor + * Architecture. Possible values are: 'AMD64' and 'X86'. Possible values + * include: 'Amd64', 'X86' + * + * @param {string} [parameters.authenticationMethod] VPN client Authentication + * Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values + * include: 'EAPTLS', 'EAPMSCHAPv2' + * + * @param {string} [parameters.radiusServerAuthCertificate] The public + * certificate data for the radius server authentication certificate as a + * Base-64 encoded string. Required only if external radius authentication has + * been configured with EAPTLS authentication. + * + * @param {array} [parameters.clientRootCertificates] A list of client root + * certificates public certificate data encoded as Base-64 strings. Optional + * parameter for external radius based authentication with EAPTLS. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {String} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {String} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginGenerateVpnProfile(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginGenerateVpnProfile(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, callback: ServiceCallback): void; + beginGenerateVpnProfile(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets pre-generated VPN profile for P2S client of the virtual network gateway + * in the specified resource group. The profile needs to be generated first + * using generateVpnProfile. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginGetVpnProfilePackageUrlWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets pre-generated VPN profile for P2S client of the virtual network gateway + * in the specified resource group. The profile needs to be generated first + * using generateVpnProfile. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {String} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {String} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginGetVpnProfilePackageUrl(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginGetVpnProfilePackageUrl(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; + beginGetVpnProfilePackageUrl(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * The GetBgpPeerStatus operation retrieves the status of all BGP peers. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {string} [options.peer] The IP address of the peer to retrieve the + * status of. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginGetBgpPeerStatusWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { peer? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * The GetBgpPeerStatus operation retrieves the status of all BGP peers. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {string} [options.peer] The IP address of the peer to retrieve the + * status of. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {BgpPeerStatusListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {BgpPeerStatusListResult} [result] - The deserialized result object if an error did not occur. + * See {@link BgpPeerStatusListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginGetBgpPeerStatus(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { peer? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + beginGetBgpPeerStatus(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; + beginGetBgpPeerStatus(resourceGroupName: string, virtualNetworkGatewayName: string, options: { peer? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * This operation retrieves a list of routes the virtual network gateway has + * learned, including routes learned from BGP peers. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginGetLearnedRoutesWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * This operation retrieves a list of routes the virtual network gateway has + * learned, including routes learned from BGP peers. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {GatewayRouteListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {GatewayRouteListResult} [result] - The deserialized result object if an error did not occur. + * See {@link GatewayRouteListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginGetLearnedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginGetLearnedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; + beginGetLearnedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * This operation retrieves a list of routes the virtual network gateway is + * advertising to the specified peer. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {string} peer The IP address of the peer + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginGetAdvertisedRoutesWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, peer: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * This operation retrieves a list of routes the virtual network gateway is + * advertising to the specified peer. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {string} peer The IP address of the peer + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {GatewayRouteListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {GatewayRouteListResult} [result] - The deserialized result object if an error did not occur. + * See {@link GatewayRouteListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginGetAdvertisedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, peer: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginGetAdvertisedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, peer: string, callback: ServiceCallback): void; + beginGetAdvertisedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, peer: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * The Set VpnclientIpsecParameters operation sets the vpnclient ipsec policy + * for P2S client of virtual network gateway in the specified resource group + * through Network resource provider. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} vpnclientIpsecParams Parameters supplied to the Begin Set + * vpnclient ipsec parameters of Virtual Network Gateway P2S client operation + * through Network resource provider. + * + * @param {number} vpnclientIpsecParams.saLifeTimeSeconds The IPSec Security + * Association (also called Quick Mode or Phase 2 SA) lifetime in seconds for + * P2S client. + * + * @param {number} vpnclientIpsecParams.saDataSizeKilobytes The IPSec Security + * Association (also called Quick Mode or Phase 2 SA) payload size in KB for + * P2S client.. + * + * @param {string} vpnclientIpsecParams.ipsecEncryption The IPSec encryption + * algorithm (IKE phase 1). Possible values include: 'None', 'DES', 'DES3', + * 'AES128', 'AES192', 'AES256', 'GCMAES128', 'GCMAES192', 'GCMAES256' + * + * @param {string} vpnclientIpsecParams.ipsecIntegrity The IPSec integrity + * algorithm (IKE phase 1). Possible values include: 'MD5', 'SHA1', 'SHA256', + * 'GCMAES128', 'GCMAES192', 'GCMAES256' + * + * @param {string} vpnclientIpsecParams.ikeEncryption The IKE encryption + * algorithm (IKE phase 2). Possible values include: 'DES', 'DES3', 'AES128', + * 'AES192', 'AES256', 'GCMAES256', 'GCMAES128' + * + * @param {string} vpnclientIpsecParams.ikeIntegrity The IKE integrity + * algorithm (IKE phase 2). Possible values include: 'MD5', 'SHA1', 'SHA256', + * 'SHA384', 'GCMAES256', 'GCMAES128' + * + * @param {string} vpnclientIpsecParams.dhGroup The DH Groups used in IKE Phase + * 1 for initial SA. Possible values include: 'None', 'DHGroup1', 'DHGroup2', + * 'DHGroup14', 'DHGroup2048', 'ECP256', 'ECP384', 'DHGroup24' + * + * @param {string} vpnclientIpsecParams.pfsGroup The Pfs Groups used in IKE + * Phase 2 for new child SA. Possible values include: 'None', 'PFS1', 'PFS2', + * 'PFS2048', 'ECP256', 'ECP384', 'PFS24', 'PFS14', 'PFSMM' + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginSetVpnclientIpsecParametersWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, vpnclientIpsecParams: models.VpnClientIPsecParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * The Set VpnclientIpsecParameters operation sets the vpnclient ipsec policy + * for P2S client of virtual network gateway in the specified resource group + * through Network resource provider. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The name of the virtual network + * gateway. + * + * @param {object} vpnclientIpsecParams Parameters supplied to the Begin Set + * vpnclient ipsec parameters of Virtual Network Gateway P2S client operation + * through Network resource provider. + * + * @param {number} vpnclientIpsecParams.saLifeTimeSeconds The IPSec Security + * Association (also called Quick Mode or Phase 2 SA) lifetime in seconds for + * P2S client. + * + * @param {number} vpnclientIpsecParams.saDataSizeKilobytes The IPSec Security + * Association (also called Quick Mode or Phase 2 SA) payload size in KB for + * P2S client.. + * + * @param {string} vpnclientIpsecParams.ipsecEncryption The IPSec encryption + * algorithm (IKE phase 1). Possible values include: 'None', 'DES', 'DES3', + * 'AES128', 'AES192', 'AES256', 'GCMAES128', 'GCMAES192', 'GCMAES256' + * + * @param {string} vpnclientIpsecParams.ipsecIntegrity The IPSec integrity + * algorithm (IKE phase 1). Possible values include: 'MD5', 'SHA1', 'SHA256', + * 'GCMAES128', 'GCMAES192', 'GCMAES256' + * + * @param {string} vpnclientIpsecParams.ikeEncryption The IKE encryption + * algorithm (IKE phase 2). Possible values include: 'DES', 'DES3', 'AES128', + * 'AES192', 'AES256', 'GCMAES256', 'GCMAES128' + * + * @param {string} vpnclientIpsecParams.ikeIntegrity The IKE integrity + * algorithm (IKE phase 2). Possible values include: 'MD5', 'SHA1', 'SHA256', + * 'SHA384', 'GCMAES256', 'GCMAES128' + * + * @param {string} vpnclientIpsecParams.dhGroup The DH Groups used in IKE Phase + * 1 for initial SA. Possible values include: 'None', 'DHGroup1', 'DHGroup2', + * 'DHGroup14', 'DHGroup2048', 'ECP256', 'ECP384', 'DHGroup24' + * + * @param {string} vpnclientIpsecParams.pfsGroup The Pfs Groups used in IKE + * Phase 2 for new child SA. Possible values include: 'None', 'PFS1', 'PFS2', + * 'PFS2048', 'ECP256', 'ECP384', 'PFS24', 'PFS14', 'PFSMM' + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VpnClientIPsecParameters} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VpnClientIPsecParameters} [result] - The deserialized result object if an error did not occur. + * See {@link VpnClientIPsecParameters} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginSetVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, vpnclientIpsecParams: models.VpnClientIPsecParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginSetVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, vpnclientIpsecParams: models.VpnClientIPsecParameters, callback: ServiceCallback): void; + beginSetVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, vpnclientIpsecParams: models.VpnClientIPsecParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * The Get VpnclientIpsecParameters operation retrieves information about the + * vpnclient ipsec policy for P2S client of virtual network gateway in the + * specified resource group through Network resource provider. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The virtual network gateway name. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginGetVpnclientIpsecParametersWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * The Get VpnclientIpsecParameters operation retrieves information about the + * vpnclient ipsec policy for P2S client of virtual network gateway in the + * specified resource group through Network resource provider. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayName The virtual network gateway name. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VpnClientIPsecParameters} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VpnClientIPsecParameters} [result] - The deserialized result object if an error did not occur. + * See {@link VpnClientIPsecParameters} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginGetVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginGetVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; + beginGetVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all virtual network gateways by resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all virtual network gateways by resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkGatewayListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkGatewayListResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGatewayListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all the connections in a virtual network gateway. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listConnectionsNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all the connections in a virtual network gateway. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkGatewayListConnectionsResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkGatewayListConnectionsResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGatewayListConnectionsResult} + * for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listConnectionsNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listConnectionsNext(nextPageLink: string, callback: ServiceCallback): void; + listConnectionsNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * VirtualNetworkGatewayConnections + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface VirtualNetworkGatewayConnections { + + + /** + * Creates or updates a virtual network gateway connection in the specified + * resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayConnectionName The name of the virtual + * network gateway connection. + * + * @param {object} parameters Parameters supplied to the create or update + * virtual network gateway connection operation. + * + * @param {string} [parameters.authorizationKey] The authorizationKey. + * + * @param {object} parameters.virtualNetworkGateway1 The reference to virtual + * network gateway resource. + * + * @param {object} [parameters.virtualNetworkGateway2] The reference to virtual + * network gateway resource. + * + * @param {array} [parameters.virtualNetworkGateway2.ipConfigurations] IP + * configurations for virtual network gateway. + * + * @param {string} [parameters.virtualNetworkGateway2.gatewayType] The type of + * this virtual network gateway. Possible values are: 'Vpn' and 'ExpressRoute'. + * Possible values include: 'Vpn', 'ExpressRoute' + * + * @param {string} [parameters.virtualNetworkGateway2.vpnType] The type of this + * virtual network gateway. Possible values are: 'PolicyBased' and + * 'RouteBased'. Possible values include: 'PolicyBased', 'RouteBased' + * + * @param {boolean} [parameters.virtualNetworkGateway2.enableBgp] Whether BGP + * is enabled for this virtual network gateway or not. + * + * @param {boolean} [parameters.virtualNetworkGateway2.activeActive] + * ActiveActive flag + * + * @param {object} [parameters.virtualNetworkGateway2.gatewayDefaultSite] The + * reference of the LocalNetworkGateway resource which represents local network + * site having default routes. Assign Null value in case of removing existing + * default site setting. + * + * @param {object} [parameters.virtualNetworkGateway2.sku] The reference of the + * VirtualNetworkGatewaySku resource which represents the SKU selected for + * Virtual network gateway. + * + * @param {string} [parameters.virtualNetworkGateway2.sku.name] Gateway SKU + * name. Possible values include: 'Basic', 'HighPerformance', 'Standard', + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' + * + * @param {string} [parameters.virtualNetworkGateway2.sku.tier] Gateway SKU + * tier. Possible values include: 'Basic', 'HighPerformance', 'Standard', + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' + * + * @param {number} [parameters.virtualNetworkGateway2.sku.capacity] The + * capacity. + * + * @param {object} [parameters.virtualNetworkGateway2.vpnClientConfiguration] + * The reference of the VpnClientConfiguration resource which represents the + * P2S VpnClient configurations. + * + * @param {object} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientAddressPool] + * The reference of the address space resource which represents Address space + * for P2S VpnClient. + * + * @param {array} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientRootCertificates] + * VpnClientRootCertificate for virtual network gateway. + * + * @param {array} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientRevokedCertificates] + * VpnClientRevokedCertificate for Virtual network gateway. + * + * @param {array} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientProtocols] + * VpnClientProtocols for Virtual network gateway. + * + * @param {array} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientIpsecPolicies] + * VpnClientIpsecPolicies for virtual network gateway P2S client. + * + * @param {string} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.radiusServerAddress] + * The radius server address property of the VirtualNetworkGateway resource for + * vpn client connection. + * + * @param {string} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.radiusServerSecret] + * The radius secret property of the VirtualNetworkGateway resource for vpn + * client connection. + * + * @param {object} [parameters.virtualNetworkGateway2.bgpSettings] Virtual + * network gateway's BGP speaker settings. + * + * @param {string} [parameters.virtualNetworkGateway2.resourceGuid] The + * resource GUID property of the VirtualNetworkGateway resource. + * + * @param {string} [parameters.virtualNetworkGateway2.etag] Gets a unique + * read-only string that changes whenever the resource is updated. + * + * @param {string} [parameters.virtualNetworkGateway2.id] Resource ID. + * + * @param {string} [parameters.virtualNetworkGateway2.location] Resource + * location. + * + * @param {object} [parameters.virtualNetworkGateway2.tags] Resource tags. + * + * @param {object} [parameters.localNetworkGateway2] The reference to local + * network gateway resource. + * + * @param {object} [parameters.localNetworkGateway2.localNetworkAddressSpace] + * Local network site address space. + * + * @param {array} + * [parameters.localNetworkGateway2.localNetworkAddressSpace.addressPrefixes] A + * list of address blocks reserved for this virtual network in CIDR notation. + * + * @param {string} [parameters.localNetworkGateway2.gatewayIpAddress] IP + * address of local network gateway. + * + * @param {object} [parameters.localNetworkGateway2.bgpSettings] Local network + * gateway's BGP speaker settings. + * + * @param {number} [parameters.localNetworkGateway2.bgpSettings.asn] The BGP + * speaker's ASN. + * + * @param {string} + * [parameters.localNetworkGateway2.bgpSettings.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [parameters.localNetworkGateway2.bgpSettings.peerWeight] The + * weight added to routes learned from this BGP speaker. + * + * @param {string} [parameters.localNetworkGateway2.resourceGuid] The resource + * GUID property of the LocalNetworkGateway resource. + * + * @param {string} [parameters.localNetworkGateway2.etag] A unique read-only + * string that changes whenever the resource is updated. + * + * @param {string} [parameters.localNetworkGateway2.id] Resource ID. + * + * @param {string} [parameters.localNetworkGateway2.location] Resource + * location. + * + * @param {object} [parameters.localNetworkGateway2.tags] Resource tags. + * + * @param {string} parameters.connectionType Gateway connection type. Possible + * values are: 'Ipsec','Vnet2Vnet','ExpressRoute', and 'VPNClient. Possible + * values include: 'IPsec', 'Vnet2Vnet', 'ExpressRoute', 'VPNClient' + * + * @param {number} [parameters.routingWeight] The routing weight. + * + * @param {string} [parameters.sharedKey] The IPSec shared key. + * + * @param {object} [parameters.peer] The reference to peerings resource. + * + * @param {string} [parameters.peer.id] Resource ID. + * + * @param {boolean} [parameters.enableBgp] EnableBgp flag + * + * @param {boolean} [parameters.usePolicyBasedTrafficSelectors] Enable + * policy-based traffic selectors. + * + * @param {array} [parameters.ipsecPolicies] The IPSec Policies to be + * considered by this connection. + * + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * VirtualNetworkGatewayConnection resource. + * + * @param {string} [parameters.etag] Gets a unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VirtualNetworkGatewayConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a virtual network gateway connection in the specified + * resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayConnectionName The name of the virtual + * network gateway connection. + * + * @param {object} parameters Parameters supplied to the create or update + * virtual network gateway connection operation. + * + * @param {string} [parameters.authorizationKey] The authorizationKey. + * + * @param {object} parameters.virtualNetworkGateway1 The reference to virtual + * network gateway resource. + * + * @param {object} [parameters.virtualNetworkGateway2] The reference to virtual + * network gateway resource. + * + * @param {array} [parameters.virtualNetworkGateway2.ipConfigurations] IP + * configurations for virtual network gateway. + * + * @param {string} [parameters.virtualNetworkGateway2.gatewayType] The type of + * this virtual network gateway. Possible values are: 'Vpn' and 'ExpressRoute'. + * Possible values include: 'Vpn', 'ExpressRoute' + * + * @param {string} [parameters.virtualNetworkGateway2.vpnType] The type of this + * virtual network gateway. Possible values are: 'PolicyBased' and + * 'RouteBased'. Possible values include: 'PolicyBased', 'RouteBased' + * + * @param {boolean} [parameters.virtualNetworkGateway2.enableBgp] Whether BGP + * is enabled for this virtual network gateway or not. + * + * @param {boolean} [parameters.virtualNetworkGateway2.activeActive] + * ActiveActive flag + * + * @param {object} [parameters.virtualNetworkGateway2.gatewayDefaultSite] The + * reference of the LocalNetworkGateway resource which represents local network + * site having default routes. Assign Null value in case of removing existing + * default site setting. + * + * @param {object} [parameters.virtualNetworkGateway2.sku] The reference of the + * VirtualNetworkGatewaySku resource which represents the SKU selected for + * Virtual network gateway. + * + * @param {string} [parameters.virtualNetworkGateway2.sku.name] Gateway SKU + * name. Possible values include: 'Basic', 'HighPerformance', 'Standard', + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' + * + * @param {string} [parameters.virtualNetworkGateway2.sku.tier] Gateway SKU + * tier. Possible values include: 'Basic', 'HighPerformance', 'Standard', + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' + * + * @param {number} [parameters.virtualNetworkGateway2.sku.capacity] The + * capacity. + * + * @param {object} [parameters.virtualNetworkGateway2.vpnClientConfiguration] + * The reference of the VpnClientConfiguration resource which represents the + * P2S VpnClient configurations. + * + * @param {object} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientAddressPool] + * The reference of the address space resource which represents Address space + * for P2S VpnClient. + * + * @param {array} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientRootCertificates] + * VpnClientRootCertificate for virtual network gateway. + * + * @param {array} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientRevokedCertificates] + * VpnClientRevokedCertificate for Virtual network gateway. + * + * @param {array} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientProtocols] + * VpnClientProtocols for Virtual network gateway. + * + * @param {array} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientIpsecPolicies] + * VpnClientIpsecPolicies for virtual network gateway P2S client. + * + * @param {string} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.radiusServerAddress] + * The radius server address property of the VirtualNetworkGateway resource for + * vpn client connection. + * + * @param {string} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.radiusServerSecret] + * The radius secret property of the VirtualNetworkGateway resource for vpn + * client connection. + * + * @param {object} [parameters.virtualNetworkGateway2.bgpSettings] Virtual + * network gateway's BGP speaker settings. + * + * @param {string} [parameters.virtualNetworkGateway2.resourceGuid] The + * resource GUID property of the VirtualNetworkGateway resource. + * + * @param {string} [parameters.virtualNetworkGateway2.etag] Gets a unique + * read-only string that changes whenever the resource is updated. + * + * @param {string} [parameters.virtualNetworkGateway2.id] Resource ID. + * + * @param {string} [parameters.virtualNetworkGateway2.location] Resource + * location. + * + * @param {object} [parameters.virtualNetworkGateway2.tags] Resource tags. + * + * @param {object} [parameters.localNetworkGateway2] The reference to local + * network gateway resource. + * + * @param {object} [parameters.localNetworkGateway2.localNetworkAddressSpace] + * Local network site address space. + * + * @param {array} + * [parameters.localNetworkGateway2.localNetworkAddressSpace.addressPrefixes] A + * list of address blocks reserved for this virtual network in CIDR notation. + * + * @param {string} [parameters.localNetworkGateway2.gatewayIpAddress] IP + * address of local network gateway. + * + * @param {object} [parameters.localNetworkGateway2.bgpSettings] Local network + * gateway's BGP speaker settings. + * + * @param {number} [parameters.localNetworkGateway2.bgpSettings.asn] The BGP + * speaker's ASN. + * + * @param {string} + * [parameters.localNetworkGateway2.bgpSettings.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [parameters.localNetworkGateway2.bgpSettings.peerWeight] The + * weight added to routes learned from this BGP speaker. + * + * @param {string} [parameters.localNetworkGateway2.resourceGuid] The resource + * GUID property of the LocalNetworkGateway resource. + * + * @param {string} [parameters.localNetworkGateway2.etag] A unique read-only + * string that changes whenever the resource is updated. + * + * @param {string} [parameters.localNetworkGateway2.id] Resource ID. + * + * @param {string} [parameters.localNetworkGateway2.location] Resource + * location. + * + * @param {object} [parameters.localNetworkGateway2.tags] Resource tags. + * + * @param {string} parameters.connectionType Gateway connection type. Possible + * values are: 'Ipsec','Vnet2Vnet','ExpressRoute', and 'VPNClient. Possible + * values include: 'IPsec', 'Vnet2Vnet', 'ExpressRoute', 'VPNClient' + * + * @param {number} [parameters.routingWeight] The routing weight. + * + * @param {string} [parameters.sharedKey] The IPSec shared key. + * + * @param {object} [parameters.peer] The reference to peerings resource. + * + * @param {string} [parameters.peer.id] Resource ID. + * + * @param {boolean} [parameters.enableBgp] EnableBgp flag + * + * @param {boolean} [parameters.usePolicyBasedTrafficSelectors] Enable + * policy-based traffic selectors. + * + * @param {array} [parameters.ipsecPolicies] The IPSec Policies to be + * considered by this connection. + * + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * VirtualNetworkGatewayConnection resource. + * + * @param {string} [parameters.etag] Gets a unique read-only string that + * changes whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkGatewayConnection} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkGatewayConnection} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGatewayConnection} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VirtualNetworkGatewayConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VirtualNetworkGatewayConnection, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VirtualNetworkGatewayConnection, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets the specified virtual network gateway connection by resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayConnectionName The name of the virtual + * network gateway connection. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [subnetParameters.name] The name of the resource that is - * unique within a resource group. This name can be used to access the - * resource. + * @reject {Error|ServiceError} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets the specified virtual network gateway connection by resource group. * - * @param {string} [subnetParameters.etag] A unique read-only string that - * changes whenever the resource is updated. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [subnetParameters.id] Resource ID. + * @param {string} virtualNetworkGatewayConnectionName The name of the virtual + * network gateway connection. * * @param {object} [options] Optional Parameters. * @@ -24589,7 +29638,7 @@ export interface Subnets { * * {Promise} A promise is returned. * - * @resolve {Subnet} - The deserialized result object. + * @resolve {VirtualNetworkGatewayConnection} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -24597,24 +29646,26 @@ export interface Subnets { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {Subnet} [result] - The deserialized result object if an error did not occur. - * See {@link Subnet} for more information. + * {VirtualNetworkGatewayConnection} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGatewayConnection} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, virtualNetworkName: string, subnetName: string, subnetParameters: models.Subnet, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, virtualNetworkName: string, subnetName: string, subnetParameters: models.Subnet, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, virtualNetworkName: string, subnetName: string, subnetParameters: models.Subnet, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all subnets in a virtual network. + * Deletes the specified virtual network Gateway connection. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} virtualNetworkGatewayConnectionName The name of the virtual + * network gateway connection. * * @param {object} [options] Optional Parameters. * @@ -24623,18 +29674,19 @@ export interface Subnets { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all subnets in a virtual network. + * Deletes the specified virtual network Gateway connection. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} virtualNetworkGatewayConnectionName The name of the virtual + * network gateway connection. * * @param {object} [options] Optional Parameters. * @@ -24648,7 +29700,7 @@ export interface Subnets { * * {Promise} A promise is returned. * - * @resolve {SubnetListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -24656,26 +29708,29 @@ export interface Subnets { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SubnetListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SubnetListResult} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, virtualNetworkName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, virtualNetworkName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified subnet. + * Updates a virtual network gateway connection tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} virtualNetworkGatewayConnectionName The name of the virtual + * network gateway connection. * - * @param {string} subnetName The name of the subnet. + * @param {object} parameters Parameters supplied to update virtual network + * gateway connection tags. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -24684,20 +29739,24 @@ export interface Subnets { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateTagsWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified subnet. + * Updates a virtual network gateway connection tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} virtualNetworkGatewayConnectionName The name of the virtual + * network gateway connection. * - * @param {string} subnetName The name of the subnet. + * @param {object} parameters Parameters supplied to update virtual network + * gateway connection tags. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -24711,7 +29770,7 @@ export interface Subnets { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {VirtualNetworkGatewayConnection} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -24719,98 +29778,113 @@ export interface Subnets { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {VirtualNetworkGatewayConnection} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGatewayConnection} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, subnetName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, subnetName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a subnet in the specified virtual network. + * The Put VirtualNetworkGatewayConnectionSharedKey operation sets the virtual + * network gateway connection shared key for passed virtual network gateway + * connection in the specified resource group through Network resource + * provider. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} virtualNetworkGatewayConnectionName The virtual network + * gateway connection name. * - * @param {string} subnetName The name of the subnet. + * @param {object} parameters Parameters supplied to the Begin Set Virtual + * Network Gateway connection Shared key operation throughNetwork resource + * provider. * - * @param {object} subnetParameters Parameters supplied to the create or update - * subnet operation. + * @param {string} parameters.value The virtual network connection shared key + * value. * - * @param {string} [subnetParameters.addressPrefix] The address prefix for the - * subnet. + * @param {string} [parameters.id] Resource ID. * - * @param {object} [subnetParameters.networkSecurityGroup] The reference of the - * NetworkSecurityGroup resource. + * @param {object} [options] Optional Parameters. * - * @param {array} [subnetParameters.networkSecurityGroup.securityRules] A - * collection of security rules of the network security group. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {array} [subnetParameters.networkSecurityGroup.defaultSecurityRules] - * The default security rules of network security group. + * @returns {Promise} A promise is returned * - * @param {string} [subnetParameters.networkSecurityGroup.resourceGuid] The - * resource GUID property of the network security group resource. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [subnetParameters.networkSecurityGroup.provisioningState] - * The provisioning state of the public IP resource. Possible values are: - * 'Updating', 'Deleting', and 'Failed'. + * @reject {Error|ServiceError} - The error object. + */ + setSharedKeyWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionSharedKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * The Put VirtualNetworkGatewayConnectionSharedKey operation sets the virtual + * network gateway connection shared key for passed virtual network gateway + * connection in the specified resource group through Network resource + * provider. * - * @param {string} [subnetParameters.networkSecurityGroup.etag] A unique - * read-only string that changes whenever the resource is updated. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [subnetParameters.networkSecurityGroup.id] Resource ID. + * @param {string} virtualNetworkGatewayConnectionName The virtual network + * gateway connection name. * - * @param {string} [subnetParameters.networkSecurityGroup.location] Resource - * location. + * @param {object} parameters Parameters supplied to the Begin Set Virtual + * Network Gateway connection Shared key operation throughNetwork resource + * provider. * - * @param {object} [subnetParameters.networkSecurityGroup.tags] Resource tags. + * @param {string} parameters.value The virtual network connection shared key + * value. * - * @param {object} [subnetParameters.routeTable] The reference of the - * RouteTable resource. + * @param {string} [parameters.id] Resource ID. * - * @param {array} [subnetParameters.routeTable.routes] Collection of routes - * contained within a route table. + * @param {object} [options] Optional Parameters. * - * @param {boolean} [subnetParameters.routeTable.disableBgpRoutePropagation] - * Gets or sets whether to disable the routes learned by BGP on that route - * table. True means disable. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [subnetParameters.routeTable.provisioningState] The - * provisioning state of the resource. Possible values are: 'Updating', - * 'Deleting', and 'Failed'. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} [subnetParameters.routeTable.etag] Gets a unique read-only - * string that changes whenever the resource is updated. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {string} [subnetParameters.routeTable.id] Resource ID. + * {Promise} A promise is returned. * - * @param {string} [subnetParameters.routeTable.location] Resource location. + * @resolve {ConnectionSharedKey} - The deserialized result object. * - * @param {object} [subnetParameters.routeTable.tags] Resource tags. + * @reject {Error|ServiceError} - The error object. * - * @param {array} [subnetParameters.serviceEndpoints] An array of service - * endpoints. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {array} [subnetParameters.resourceNavigationLinks] Gets an array of - * references to the external resources using subnet. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [subnetParameters.provisioningState] The provisioning state - * of the resource. + * {ConnectionSharedKey} [result] - The deserialized result object if an error did not occur. + * See {@link ConnectionSharedKey} for more information. * - * @param {string} [subnetParameters.name] The name of the resource that is - * unique within a resource group. This name can be used to access the - * resource. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {string} [subnetParameters.etag] A unique read-only string that - * changes whenever the resource is updated. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + setSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionSharedKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + setSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionSharedKey, callback: ServiceCallback): void; + setSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionSharedKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * The Get VirtualNetworkGatewayConnectionSharedKey operation retrieves + * information about the specified virtual network gateway connection shared + * key through Network resource provider. * - * @param {string} [subnetParameters.id] Resource ID. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayConnectionName The virtual network + * gateway connection shared key name. * * @param {object} [options] Optional Parameters. * @@ -24819,93 +29893,78 @@ export interface Subnets { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, subnetName: string, subnetParameters: models.Subnet, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getSharedKeyWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a subnet in the specified virtual network. + * The Get VirtualNetworkGatewayConnectionSharedKey operation retrieves + * information about the specified virtual network gateway connection shared + * key through Network resource provider. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. - * - * @param {string} subnetName The name of the subnet. - * - * @param {object} subnetParameters Parameters supplied to the create or update - * subnet operation. - * - * @param {string} [subnetParameters.addressPrefix] The address prefix for the - * subnet. - * - * @param {object} [subnetParameters.networkSecurityGroup] The reference of the - * NetworkSecurityGroup resource. - * - * @param {array} [subnetParameters.networkSecurityGroup.securityRules] A - * collection of security rules of the network security group. - * - * @param {array} [subnetParameters.networkSecurityGroup.defaultSecurityRules] - * The default security rules of network security group. - * - * @param {string} [subnetParameters.networkSecurityGroup.resourceGuid] The - * resource GUID property of the network security group resource. - * - * @param {string} [subnetParameters.networkSecurityGroup.provisioningState] - * The provisioning state of the public IP resource. Possible values are: - * 'Updating', 'Deleting', and 'Failed'. + * @param {string} virtualNetworkGatewayConnectionName The virtual network + * gateway connection shared key name. * - * @param {string} [subnetParameters.networkSecurityGroup.etag] A unique - * read-only string that changes whenever the resource is updated. + * @param {object} [options] Optional Parameters. * - * @param {string} [subnetParameters.networkSecurityGroup.id] Resource ID. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [subnetParameters.networkSecurityGroup.location] Resource - * location. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {object} [subnetParameters.networkSecurityGroup.tags] Resource tags. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {object} [subnetParameters.routeTable] The reference of the - * RouteTable resource. + * {Promise} A promise is returned. * - * @param {array} [subnetParameters.routeTable.routes] Collection of routes - * contained within a route table. + * @resolve {ConnectionSharedKey} - The deserialized result object. * - * @param {boolean} [subnetParameters.routeTable.disableBgpRoutePropagation] - * Gets or sets whether to disable the routes learned by BGP on that route - * table. True means disable. + * @reject {Error|ServiceError} - The error object. * - * @param {string} [subnetParameters.routeTable.provisioningState] The - * provisioning state of the resource. Possible values are: 'Updating', - * 'Deleting', and 'Failed'. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} [subnetParameters.routeTable.etag] Gets a unique read-only - * string that changes whenever the resource is updated. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [subnetParameters.routeTable.id] Resource ID. + * {ConnectionSharedKey} [result] - The deserialized result object if an error did not occur. + * See {@link ConnectionSharedKey} for more information. * - * @param {string} [subnetParameters.routeTable.location] Resource location. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {object} [subnetParameters.routeTable.tags] Resource tags. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + getSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + getSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, callback: ServiceCallback): void; + getSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * The List VirtualNetworkGatewayConnections operation retrieves all the + * virtual network gateways connections created. * - * @param {array} [subnetParameters.serviceEndpoints] An array of service - * endpoints. + * @param {string} resourceGroupName The name of the resource group. * - * @param {array} [subnetParameters.resourceNavigationLinks] Gets an array of - * references to the external resources using subnet. + * @param {object} [options] Optional Parameters. * - * @param {string} [subnetParameters.provisioningState] The provisioning state - * of the resource. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [subnetParameters.name] The name of the resource that is - * unique within a resource group. This name can be used to access the - * resource. + * @returns {Promise} A promise is returned * - * @param {string} [subnetParameters.etag] A unique read-only string that - * changes whenever the resource is updated. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [subnetParameters.id] Resource ID. + * @reject {Error|ServiceError} - The error object. + */ + listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * The List VirtualNetworkGatewayConnections operation retrieves all the + * virtual network gateways connections created. + * + * @param {string} resourceGroupName The name of the resource group. * * @param {object} [options] Optional Parameters. * @@ -24919,7 +29978,7 @@ export interface Subnets { * * {Promise} A promise is returned. * - * @resolve {Subnet} - The deserialized result object. + * @resolve {VirtualNetworkGatewayConnectionListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -24927,23 +29986,36 @@ export interface Subnets { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {Subnet} [result] - The deserialized result object if an error did not occur. - * See {@link Subnet} for more information. + * {VirtualNetworkGatewayConnectionListResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGatewayConnectionListResult} + * for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, subnetName: string, subnetParameters: models.Subnet, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, subnetName: string, subnetParameters: models.Subnet, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, subnetName: string, subnetParameters: models.Subnet, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all subnets in a virtual network. + * The VirtualNetworkGatewayConnectionResetSharedKey operation resets the + * virtual network gateway connection shared key for passed virtual network + * gateway connection in the specified resource group through Network resource + * provider. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayConnectionName The virtual network + * gateway connection reset shared key Name. + * + * @param {object} parameters Parameters supplied to the begin reset virtual + * network gateway connection shared key operation through network resource + * provider. + * + * @param {number} parameters.keyLength The virtual network connection reset + * shared key length, should between 1 and 128. * * @param {object} [options] Optional Parameters. * @@ -24952,17 +30024,29 @@ export interface Subnets { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + resetSharedKeyWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionResetSharedKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all subnets in a virtual network. + * The VirtualNetworkGatewayConnectionResetSharedKey operation resets the + * virtual network gateway connection shared key for passed virtual network + * gateway connection in the specified resource group through Network resource + * provider. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} virtualNetworkGatewayConnectionName The virtual network + * gateway connection reset shared key Name. + * + * @param {object} parameters Parameters supplied to the begin reset virtual + * network gateway connection shared key operation through network resource + * provider. + * + * @param {number} parameters.keyLength The virtual network connection reset + * shared key length, should between 1 and 128. * * @param {object} [options] Optional Parameters. * @@ -24976,7 +30060,7 @@ export interface Subnets { * * {Promise} A promise is returned. * - * @resolve {SubnetListResult} - The deserialized result object. + * @resolve {ConnectionResetSharedKey} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -24984,100 +30068,199 @@ export interface Subnets { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SubnetListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SubnetListResult} for more information. + * {ConnectionResetSharedKey} [result] - The deserialized result object if an error did not occur. + * See {@link ConnectionResetSharedKey} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * VirtualNetworkPeerings - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface VirtualNetworkPeerings { + resetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionResetSharedKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + resetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionResetSharedKey, callback: ServiceCallback): void; + resetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionResetSharedKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified virtual network peering. + * Creates or updates a virtual network gateway connection in the specified + * resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} virtualNetworkGatewayConnectionName The name of the virtual + * network gateway connection. * - * @param {string} virtualNetworkPeeringName The name of the virtual network - * peering. + * @param {object} parameters Parameters supplied to the create or update + * virtual network gateway connection operation. * - * @param {object} [options] Optional Parameters. + * @param {string} [parameters.authorizationKey] The authorizationKey. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {object} parameters.virtualNetworkGateway1 The reference to virtual + * network gateway resource. * - * @returns {Promise} A promise is returned + * @param {object} [parameters.virtualNetworkGateway2] The reference to virtual + * network gateway resource. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {array} [parameters.virtualNetworkGateway2.ipConfigurations] IP + * configurations for virtual network gateway. * - * @reject {Error|ServiceError} - The error object. - */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Deletes the specified virtual network peering. + * @param {string} [parameters.virtualNetworkGateway2.gatewayType] The type of + * this virtual network gateway. Possible values are: 'Vpn' and 'ExpressRoute'. + * Possible values include: 'Vpn', 'ExpressRoute' + * + * @param {string} [parameters.virtualNetworkGateway2.vpnType] The type of this + * virtual network gateway. Possible values are: 'PolicyBased' and + * 'RouteBased'. Possible values include: 'PolicyBased', 'RouteBased' + * + * @param {boolean} [parameters.virtualNetworkGateway2.enableBgp] Whether BGP + * is enabled for this virtual network gateway or not. + * + * @param {boolean} [parameters.virtualNetworkGateway2.activeActive] + * ActiveActive flag + * + * @param {object} [parameters.virtualNetworkGateway2.gatewayDefaultSite] The + * reference of the LocalNetworkGateway resource which represents local network + * site having default routes. Assign Null value in case of removing existing + * default site setting. + * + * @param {object} [parameters.virtualNetworkGateway2.sku] The reference of the + * VirtualNetworkGatewaySku resource which represents the SKU selected for + * Virtual network gateway. + * + * @param {string} [parameters.virtualNetworkGateway2.sku.name] Gateway SKU + * name. Possible values include: 'Basic', 'HighPerformance', 'Standard', + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' + * + * @param {string} [parameters.virtualNetworkGateway2.sku.tier] Gateway SKU + * tier. Possible values include: 'Basic', 'HighPerformance', 'Standard', + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' + * + * @param {number} [parameters.virtualNetworkGateway2.sku.capacity] The + * capacity. + * + * @param {object} [parameters.virtualNetworkGateway2.vpnClientConfiguration] + * The reference of the VpnClientConfiguration resource which represents the + * P2S VpnClient configurations. + * + * @param {object} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientAddressPool] + * The reference of the address space resource which represents Address space + * for P2S VpnClient. + * + * @param {array} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientRootCertificates] + * VpnClientRootCertificate for virtual network gateway. + * + * @param {array} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientRevokedCertificates] + * VpnClientRevokedCertificate for Virtual network gateway. + * + * @param {array} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientProtocols] + * VpnClientProtocols for Virtual network gateway. + * + * @param {array} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientIpsecPolicies] + * VpnClientIpsecPolicies for virtual network gateway P2S client. + * + * @param {string} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.radiusServerAddress] + * The radius server address property of the VirtualNetworkGateway resource for + * vpn client connection. + * + * @param {string} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.radiusServerSecret] + * The radius secret property of the VirtualNetworkGateway resource for vpn + * client connection. + * + * @param {object} [parameters.virtualNetworkGateway2.bgpSettings] Virtual + * network gateway's BGP speaker settings. + * + * @param {string} [parameters.virtualNetworkGateway2.resourceGuid] The + * resource GUID property of the VirtualNetworkGateway resource. + * + * @param {string} [parameters.virtualNetworkGateway2.etag] Gets a unique + * read-only string that changes whenever the resource is updated. + * + * @param {string} [parameters.virtualNetworkGateway2.id] Resource ID. + * + * @param {string} [parameters.virtualNetworkGateway2.location] Resource + * location. + * + * @param {object} [parameters.virtualNetworkGateway2.tags] Resource tags. + * + * @param {object} [parameters.localNetworkGateway2] The reference to local + * network gateway resource. + * + * @param {object} [parameters.localNetworkGateway2.localNetworkAddressSpace] + * Local network site address space. + * + * @param {array} + * [parameters.localNetworkGateway2.localNetworkAddressSpace.addressPrefixes] A + * list of address blocks reserved for this virtual network in CIDR notation. + * + * @param {string} [parameters.localNetworkGateway2.gatewayIpAddress] IP + * address of local network gateway. + * + * @param {object} [parameters.localNetworkGateway2.bgpSettings] Local network + * gateway's BGP speaker settings. + * + * @param {number} [parameters.localNetworkGateway2.bgpSettings.asn] The BGP + * speaker's ASN. + * + * @param {string} + * [parameters.localNetworkGateway2.bgpSettings.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. * - * @param {string} resourceGroupName The name of the resource group. + * @param {number} [parameters.localNetworkGateway2.bgpSettings.peerWeight] The + * weight added to routes learned from this BGP speaker. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} [parameters.localNetworkGateway2.resourceGuid] The resource + * GUID property of the LocalNetworkGateway resource. * - * @param {string} virtualNetworkPeeringName The name of the virtual network - * peering. + * @param {string} [parameters.localNetworkGateway2.etag] A unique read-only + * string that changes whenever the resource is updated. * - * @param {object} [options] Optional Parameters. + * @param {string} [parameters.localNetworkGateway2.id] Resource ID. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [parameters.localNetworkGateway2.location] Resource + * location. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {object} [parameters.localNetworkGateway2.tags] Resource tags. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {string} parameters.connectionType Gateway connection type. Possible + * values are: 'Ipsec','Vnet2Vnet','ExpressRoute', and 'VPNClient. Possible + * values include: 'IPsec', 'Vnet2Vnet', 'ExpressRoute', 'VPNClient' * - * {Promise} A promise is returned. + * @param {number} [parameters.routingWeight] The routing weight. * - * @resolve {null} - The deserialized result object. + * @param {string} [parameters.sharedKey] The IPSec shared key. * - * @reject {Error|ServiceError} - The error object. + * @param {object} [parameters.peer] The reference to peerings resource. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {string} [parameters.peer.id] Resource ID. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {boolean} [parameters.enableBgp] EnableBgp flag * - * {null} [result] - The deserialized result object if an error did not occur. + * @param {boolean} [parameters.usePolicyBasedTrafficSelectors] Enable + * policy-based traffic selectors. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {array} [parameters.ipsecPolicies] The IPSec Policies to be + * considered by this connection. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - deleteMethod(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets the specified virtual network peering. + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * VirtualNetworkGatewayConnection resource. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [parameters.etag] Gets a unique read-only string that + * changes whenever the resource is updated. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} [parameters.id] Resource ID. * - * @param {string} virtualNetworkPeeringName The name of the virtual network - * peering. + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -25086,194 +30269,192 @@ export interface VirtualNetworkPeerings { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VirtualNetworkGatewayConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified virtual network peering. + * Creates or updates a virtual network gateway connection in the specified + * resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} virtualNetworkGatewayConnectionName The name of the virtual + * network gateway connection. * - * @param {string} virtualNetworkPeeringName The name of the virtual network - * peering. + * @param {object} parameters Parameters supplied to the create or update + * virtual network gateway connection operation. * - * @param {object} [options] Optional Parameters. + * @param {string} [parameters.authorizationKey] The authorizationKey. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {object} parameters.virtualNetworkGateway1 The reference to virtual + * network gateway resource. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {object} [parameters.virtualNetworkGateway2] The reference to virtual + * network gateway resource. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {array} [parameters.virtualNetworkGateway2.ipConfigurations] IP + * configurations for virtual network gateway. * - * {Promise} A promise is returned. + * @param {string} [parameters.virtualNetworkGateway2.gatewayType] The type of + * this virtual network gateway. Possible values are: 'Vpn' and 'ExpressRoute'. + * Possible values include: 'Vpn', 'ExpressRoute' * - * @resolve {VirtualNetworkPeering} - The deserialized result object. + * @param {string} [parameters.virtualNetworkGateway2.vpnType] The type of this + * virtual network gateway. Possible values are: 'PolicyBased' and + * 'RouteBased'. Possible values include: 'PolicyBased', 'RouteBased' * - * @reject {Error|ServiceError} - The error object. + * @param {boolean} [parameters.virtualNetworkGateway2.enableBgp] Whether BGP + * is enabled for this virtual network gateway or not. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {boolean} [parameters.virtualNetworkGateway2.activeActive] + * ActiveActive flag * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {object} [parameters.virtualNetworkGateway2.gatewayDefaultSite] The + * reference of the LocalNetworkGateway resource which represents local network + * site having default routes. Assign Null value in case of removing existing + * default site setting. * - * {VirtualNetworkPeering} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkPeering} for more information. + * @param {object} [parameters.virtualNetworkGateway2.sku] The reference of the + * VirtualNetworkGatewaySku resource which represents the SKU selected for + * Virtual network gateway. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {string} [parameters.virtualNetworkGateway2.sku.name] Gateway SKU + * name. Possible values include: 'Basic', 'HighPerformance', 'Standard', + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - get(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Creates or updates a peering in the specified virtual network. + * @param {string} [parameters.virtualNetworkGateway2.sku.tier] Gateway SKU + * tier. Possible values include: 'Basic', 'HighPerformance', 'Standard', + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * - * @param {string} resourceGroupName The name of the resource group. + * @param {number} [parameters.virtualNetworkGateway2.sku.capacity] The + * capacity. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {object} [parameters.virtualNetworkGateway2.vpnClientConfiguration] + * The reference of the VpnClientConfiguration resource which represents the + * P2S VpnClient configurations. * - * @param {string} virtualNetworkPeeringName The name of the peering. + * @param {object} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientAddressPool] + * The reference of the address space resource which represents Address space + * for P2S VpnClient. * - * @param {object} virtualNetworkPeeringParameters Parameters supplied to the - * create or update virtual network peering operation. + * @param {array} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientRootCertificates] + * VpnClientRootCertificate for virtual network gateway. * - * @param {boolean} [virtualNetworkPeeringParameters.allowVirtualNetworkAccess] - * Whether the VMs in the linked virtual network space would be able to access - * all the VMs in local Virtual network space. + * @param {array} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientRevokedCertificates] + * VpnClientRevokedCertificate for Virtual network gateway. * - * @param {boolean} [virtualNetworkPeeringParameters.allowForwardedTraffic] - * Whether the forwarded traffic from the VMs in the remote virtual network - * will be allowed/disallowed. + * @param {array} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientProtocols] + * VpnClientProtocols for Virtual network gateway. * - * @param {boolean} [virtualNetworkPeeringParameters.allowGatewayTransit] If - * gateway links can be used in remote virtual networking to link to this - * virtual network. + * @param {array} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientIpsecPolicies] + * VpnClientIpsecPolicies for virtual network gateway P2S client. * - * @param {boolean} [virtualNetworkPeeringParameters.useRemoteGateways] If - * remote gateways can be used on this virtual network. If the flag is set to - * true, and allowGatewayTransit on remote peering is also true, virtual - * network will use gateways of remote virtual network for transit. Only one - * peering can have this flag set to true. This flag cannot be set if virtual - * network already has a gateway. + * @param {string} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.radiusServerAddress] + * The radius server address property of the VirtualNetworkGateway resource for + * vpn client connection. * - * @param {object} [virtualNetworkPeeringParameters.remoteVirtualNetwork] The - * reference of the remote virtual network. The remote virtual network can be - * in the same or different region (preview). See here to register for the - * preview and learn more - * (https://docs.microsoft.com/en-us/azure/virtual-network/virtual-network-create-peering). + * @param {string} + * [parameters.virtualNetworkGateway2.vpnClientConfiguration.radiusServerSecret] + * The radius secret property of the VirtualNetworkGateway resource for vpn + * client connection. * - * @param {string} [virtualNetworkPeeringParameters.remoteVirtualNetwork.id] - * Resource ID. + * @param {object} [parameters.virtualNetworkGateway2.bgpSettings] Virtual + * network gateway's BGP speaker settings. * - * @param {object} [virtualNetworkPeeringParameters.remoteAddressSpace] The - * reference of the remote virtual network address space. + * @param {string} [parameters.virtualNetworkGateway2.resourceGuid] The + * resource GUID property of the VirtualNetworkGateway resource. * - * @param {array} - * [virtualNetworkPeeringParameters.remoteAddressSpace.addressPrefixes] A list - * of address blocks reserved for this virtual network in CIDR notation. + * @param {string} [parameters.virtualNetworkGateway2.etag] Gets a unique + * read-only string that changes whenever the resource is updated. * - * @param {string} [virtualNetworkPeeringParameters.peeringState] The status of - * the virtual network peering. Possible values are 'Initiated', 'Connected', - * and 'Disconnected'. Possible values include: 'Initiated', 'Connected', - * 'Disconnected' + * @param {string} [parameters.virtualNetworkGateway2.id] Resource ID. * - * @param {string} [virtualNetworkPeeringParameters.provisioningState] The - * provisioning state of the resource. + * @param {string} [parameters.virtualNetworkGateway2.location] Resource + * location. * - * @param {string} [virtualNetworkPeeringParameters.name] The name of the - * resource that is unique within a resource group. This name can be used to - * access the resource. + * @param {object} [parameters.virtualNetworkGateway2.tags] Resource tags. * - * @param {string} [virtualNetworkPeeringParameters.etag] A unique read-only - * string that changes whenever the resource is updated. + * @param {object} [parameters.localNetworkGateway2] The reference to local + * network gateway resource. * - * @param {string} [virtualNetworkPeeringParameters.id] Resource ID. + * @param {object} [parameters.localNetworkGateway2.localNetworkAddressSpace] + * Local network site address space. * - * @param {object} [options] Optional Parameters. + * @param {array} + * [parameters.localNetworkGateway2.localNetworkAddressSpace.addressPrefixes] A + * list of address blocks reserved for this virtual network in CIDR notation. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [parameters.localNetworkGateway2.gatewayIpAddress] IP + * address of local network gateway. * - * @returns {Promise} A promise is returned + * @param {object} [parameters.localNetworkGateway2.bgpSettings] Local network + * gateway's BGP speaker settings. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {number} [parameters.localNetworkGateway2.bgpSettings.asn] The BGP + * speaker's ASN. * - * @reject {Error|ServiceError} - The error object. - */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, virtualNetworkPeeringParameters: models.VirtualNetworkPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Creates or updates a peering in the specified virtual network. + * @param {string} + * [parameters.localNetworkGateway2.bgpSettings.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. * - * @param {string} resourceGroupName The name of the resource group. + * @param {number} [parameters.localNetworkGateway2.bgpSettings.peerWeight] The + * weight added to routes learned from this BGP speaker. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} [parameters.localNetworkGateway2.resourceGuid] The resource + * GUID property of the LocalNetworkGateway resource. * - * @param {string} virtualNetworkPeeringName The name of the peering. + * @param {string} [parameters.localNetworkGateway2.etag] A unique read-only + * string that changes whenever the resource is updated. * - * @param {object} virtualNetworkPeeringParameters Parameters supplied to the - * create or update virtual network peering operation. + * @param {string} [parameters.localNetworkGateway2.id] Resource ID. * - * @param {boolean} [virtualNetworkPeeringParameters.allowVirtualNetworkAccess] - * Whether the VMs in the linked virtual network space would be able to access - * all the VMs in local Virtual network space. + * @param {string} [parameters.localNetworkGateway2.location] Resource + * location. + * + * @param {object} [parameters.localNetworkGateway2.tags] Resource tags. * - * @param {boolean} [virtualNetworkPeeringParameters.allowForwardedTraffic] - * Whether the forwarded traffic from the VMs in the remote virtual network - * will be allowed/disallowed. + * @param {string} parameters.connectionType Gateway connection type. Possible + * values are: 'Ipsec','Vnet2Vnet','ExpressRoute', and 'VPNClient. Possible + * values include: 'IPsec', 'Vnet2Vnet', 'ExpressRoute', 'VPNClient' * - * @param {boolean} [virtualNetworkPeeringParameters.allowGatewayTransit] If - * gateway links can be used in remote virtual networking to link to this - * virtual network. + * @param {number} [parameters.routingWeight] The routing weight. * - * @param {boolean} [virtualNetworkPeeringParameters.useRemoteGateways] If - * remote gateways can be used on this virtual network. If the flag is set to - * true, and allowGatewayTransit on remote peering is also true, virtual - * network will use gateways of remote virtual network for transit. Only one - * peering can have this flag set to true. This flag cannot be set if virtual - * network already has a gateway. + * @param {string} [parameters.sharedKey] The IPSec shared key. * - * @param {object} [virtualNetworkPeeringParameters.remoteVirtualNetwork] The - * reference of the remote virtual network. The remote virtual network can be - * in the same or different region (preview). See here to register for the - * preview and learn more - * (https://docs.microsoft.com/en-us/azure/virtual-network/virtual-network-create-peering). + * @param {object} [parameters.peer] The reference to peerings resource. * - * @param {string} [virtualNetworkPeeringParameters.remoteVirtualNetwork.id] - * Resource ID. + * @param {string} [parameters.peer.id] Resource ID. * - * @param {object} [virtualNetworkPeeringParameters.remoteAddressSpace] The - * reference of the remote virtual network address space. + * @param {boolean} [parameters.enableBgp] EnableBgp flag * - * @param {array} - * [virtualNetworkPeeringParameters.remoteAddressSpace.addressPrefixes] A list - * of address blocks reserved for this virtual network in CIDR notation. + * @param {boolean} [parameters.usePolicyBasedTrafficSelectors] Enable + * policy-based traffic selectors. * - * @param {string} [virtualNetworkPeeringParameters.peeringState] The status of - * the virtual network peering. Possible values are 'Initiated', 'Connected', - * and 'Disconnected'. Possible values include: 'Initiated', 'Connected', - * 'Disconnected' + * @param {array} [parameters.ipsecPolicies] The IPSec Policies to be + * considered by this connection. * - * @param {string} [virtualNetworkPeeringParameters.provisioningState] The - * provisioning state of the resource. + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * VirtualNetworkGatewayConnection resource. * - * @param {string} [virtualNetworkPeeringParameters.name] The name of the - * resource that is unique within a resource group. This name can be used to - * access the resource. + * @param {string} [parameters.etag] Gets a unique read-only string that + * changes whenever the resource is updated. * - * @param {string} [virtualNetworkPeeringParameters.etag] A unique read-only - * string that changes whenever the resource is updated. + * @param {string} [parameters.id] Resource ID. * - * @param {string} [virtualNetworkPeeringParameters.id] Resource ID. + * @param {string} [parameters.location] Resource location. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -25287,7 +30468,7 @@ export interface VirtualNetworkPeerings { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkPeering} - The deserialized result object. + * @resolve {VirtualNetworkGatewayConnection} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -25295,24 +30476,26 @@ export interface VirtualNetworkPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkPeering} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkPeering} for more information. + * {VirtualNetworkGatewayConnection} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGatewayConnection} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, virtualNetworkPeeringParameters: models.VirtualNetworkPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, virtualNetworkPeeringParameters: models.VirtualNetworkPeering, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, virtualNetworkPeeringParameters: models.VirtualNetworkPeering, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VirtualNetworkGatewayConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VirtualNetworkGatewayConnection, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VirtualNetworkGatewayConnection, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all virtual network peerings in a virtual network. + * Deletes the specified virtual network Gateway connection. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} virtualNetworkGatewayConnectionName The name of the virtual + * network gateway connection. * * @param {object} [options] Optional Parameters. * @@ -25321,18 +30504,19 @@ export interface VirtualNetworkPeerings { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all virtual network peerings in a virtual network. + * Deletes the specified virtual network Gateway connection. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} virtualNetworkGatewayConnectionName The name of the virtual + * network gateway connection. * * @param {object} [options] Optional Parameters. * @@ -25346,7 +30530,7 @@ export interface VirtualNetworkPeerings { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkPeeringListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -25354,28 +30538,29 @@ export interface VirtualNetworkPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkPeeringListResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkPeeringListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, virtualNetworkName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, virtualNetworkName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, virtualNetworkName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified virtual network peering. + * Updates a virtual network gateway connection tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} virtualNetworkGatewayConnectionName The name of the virtual + * network gateway connection. * - * @param {string} virtualNetworkPeeringName The name of the virtual network - * peering. + * @param {object} parameters Parameters supplied to update virtual network + * gateway connection tags. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -25384,21 +30569,24 @@ export interface VirtualNetworkPeerings { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified virtual network peering. + * Updates a virtual network gateway connection tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. + * @param {string} virtualNetworkGatewayConnectionName The name of the virtual + * network gateway connection. * - * @param {string} virtualNetworkPeeringName The name of the virtual network - * peering. + * @param {object} parameters Parameters supplied to update virtual network + * gateway connection tags. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -25412,7 +30600,7 @@ export interface VirtualNetworkPeerings { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {VirtualNetworkGatewayConnection} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -25420,157 +30608,152 @@ export interface VirtualNetworkPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {VirtualNetworkGatewayConnection} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGatewayConnection} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdateTags(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a peering in the specified virtual network. + * The Put VirtualNetworkGatewayConnectionSharedKey operation sets the virtual + * network gateway connection shared key for passed virtual network gateway + * connection in the specified resource group through Network resource + * provider. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkName The name of the virtual network. - * - * @param {string} virtualNetworkPeeringName The name of the peering. - * - * @param {object} virtualNetworkPeeringParameters Parameters supplied to the - * create or update virtual network peering operation. + * @param {string} virtualNetworkGatewayConnectionName The virtual network + * gateway connection name. * - * @param {boolean} [virtualNetworkPeeringParameters.allowVirtualNetworkAccess] - * Whether the VMs in the linked virtual network space would be able to access - * all the VMs in local Virtual network space. + * @param {object} parameters Parameters supplied to the Begin Set Virtual + * Network Gateway connection Shared key operation throughNetwork resource + * provider. * - * @param {boolean} [virtualNetworkPeeringParameters.allowForwardedTraffic] - * Whether the forwarded traffic from the VMs in the remote virtual network - * will be allowed/disallowed. + * @param {string} parameters.value The virtual network connection shared key + * value. * - * @param {boolean} [virtualNetworkPeeringParameters.allowGatewayTransit] If - * gateway links can be used in remote virtual networking to link to this - * virtual network. + * @param {string} [parameters.id] Resource ID. * - * @param {boolean} [virtualNetworkPeeringParameters.useRemoteGateways] If - * remote gateways can be used on this virtual network. If the flag is set to - * true, and allowGatewayTransit on remote peering is also true, virtual - * network will use gateways of remote virtual network for transit. Only one - * peering can have this flag set to true. This flag cannot be set if virtual - * network already has a gateway. + * @param {object} [options] Optional Parameters. * - * @param {object} [virtualNetworkPeeringParameters.remoteVirtualNetwork] The - * reference of the remote virtual network. The remote virtual network can be - * in the same or different region (preview). See here to register for the - * preview and learn more - * (https://docs.microsoft.com/en-us/azure/virtual-network/virtual-network-create-peering). + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [virtualNetworkPeeringParameters.remoteVirtualNetwork.id] - * Resource ID. + * @returns {Promise} A promise is returned * - * @param {object} [virtualNetworkPeeringParameters.remoteAddressSpace] The - * reference of the remote virtual network address space. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {array} - * [virtualNetworkPeeringParameters.remoteAddressSpace.addressPrefixes] A list - * of address blocks reserved for this virtual network in CIDR notation. + * @reject {Error|ServiceError} - The error object. + */ + beginSetSharedKeyWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionSharedKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * The Put VirtualNetworkGatewayConnectionSharedKey operation sets the virtual + * network gateway connection shared key for passed virtual network gateway + * connection in the specified resource group through Network resource + * provider. * - * @param {string} [virtualNetworkPeeringParameters.peeringState] The status of - * the virtual network peering. Possible values are 'Initiated', 'Connected', - * and 'Disconnected'. Possible values include: 'Initiated', 'Connected', - * 'Disconnected' + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [virtualNetworkPeeringParameters.provisioningState] The - * provisioning state of the resource. + * @param {string} virtualNetworkGatewayConnectionName The virtual network + * gateway connection name. * - * @param {string} [virtualNetworkPeeringParameters.name] The name of the - * resource that is unique within a resource group. This name can be used to - * access the resource. + * @param {object} parameters Parameters supplied to the Begin Set Virtual + * Network Gateway connection Shared key operation throughNetwork resource + * provider. * - * @param {string} [virtualNetworkPeeringParameters.etag] A unique read-only - * string that changes whenever the resource is updated. + * @param {string} parameters.value The virtual network connection shared key + * value. * - * @param {string} [virtualNetworkPeeringParameters.id] Resource ID. + * @param {string} [parameters.id] Resource ID. * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * - * @returns {Promise} A promise is returned + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @reject {Error|ServiceError} - The error object. - */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, virtualNetworkPeeringParameters: models.VirtualNetworkPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Creates or updates a peering in the specified virtual network. + * {Promise} A promise is returned. * - * @param {string} resourceGroupName The name of the resource group. + * @resolve {ConnectionSharedKey} - The deserialized result object. * - * @param {string} virtualNetworkName The name of the virtual network. + * @reject {Error|ServiceError} - The error object. * - * @param {string} virtualNetworkPeeringName The name of the peering. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {object} virtualNetworkPeeringParameters Parameters supplied to the - * create or update virtual network peering operation. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {boolean} [virtualNetworkPeeringParameters.allowVirtualNetworkAccess] - * Whether the VMs in the linked virtual network space would be able to access - * all the VMs in local Virtual network space. + * {ConnectionSharedKey} [result] - The deserialized result object if an error did not occur. + * See {@link ConnectionSharedKey} for more information. * - * @param {boolean} [virtualNetworkPeeringParameters.allowForwardedTraffic] - * Whether the forwarded traffic from the VMs in the remote virtual network - * will be allowed/disallowed. + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginSetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionSharedKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginSetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionSharedKey, callback: ServiceCallback): void; + beginSetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionSharedKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * The VirtualNetworkGatewayConnectionResetSharedKey operation resets the + * virtual network gateway connection shared key for passed virtual network + * gateway connection in the specified resource group through Network resource + * provider. + * + * @param {string} resourceGroupName The name of the resource group. * - * @param {boolean} [virtualNetworkPeeringParameters.allowGatewayTransit] If - * gateway links can be used in remote virtual networking to link to this - * virtual network. + * @param {string} virtualNetworkGatewayConnectionName The virtual network + * gateway connection reset shared key Name. * - * @param {boolean} [virtualNetworkPeeringParameters.useRemoteGateways] If - * remote gateways can be used on this virtual network. If the flag is set to - * true, and allowGatewayTransit on remote peering is also true, virtual - * network will use gateways of remote virtual network for transit. Only one - * peering can have this flag set to true. This flag cannot be set if virtual - * network already has a gateway. + * @param {object} parameters Parameters supplied to the begin reset virtual + * network gateway connection shared key operation through network resource + * provider. * - * @param {object} [virtualNetworkPeeringParameters.remoteVirtualNetwork] The - * reference of the remote virtual network. The remote virtual network can be - * in the same or different region (preview). See here to register for the - * preview and learn more - * (https://docs.microsoft.com/en-us/azure/virtual-network/virtual-network-create-peering). + * @param {number} parameters.keyLength The virtual network connection reset + * shared key length, should between 1 and 128. * - * @param {string} [virtualNetworkPeeringParameters.remoteVirtualNetwork.id] - * Resource ID. + * @param {object} [options] Optional Parameters. * - * @param {object} [virtualNetworkPeeringParameters.remoteAddressSpace] The - * reference of the remote virtual network address space. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {array} - * [virtualNetworkPeeringParameters.remoteAddressSpace.addressPrefixes] A list - * of address blocks reserved for this virtual network in CIDR notation. + * @returns {Promise} A promise is returned * - * @param {string} [virtualNetworkPeeringParameters.peeringState] The status of - * the virtual network peering. Possible values are 'Initiated', 'Connected', - * and 'Disconnected'. Possible values include: 'Initiated', 'Connected', - * 'Disconnected' + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [virtualNetworkPeeringParameters.provisioningState] The - * provisioning state of the resource. + * @reject {Error|ServiceError} - The error object. + */ + beginResetSharedKeyWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionResetSharedKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * The VirtualNetworkGatewayConnectionResetSharedKey operation resets the + * virtual network gateway connection shared key for passed virtual network + * gateway connection in the specified resource group through Network resource + * provider. * - * @param {string} [virtualNetworkPeeringParameters.name] The name of the - * resource that is unique within a resource group. This name can be used to - * access the resource. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [virtualNetworkPeeringParameters.etag] A unique read-only - * string that changes whenever the resource is updated. + * @param {string} virtualNetworkGatewayConnectionName The virtual network + * gateway connection reset shared key Name. * - * @param {string} [virtualNetworkPeeringParameters.id] Resource ID. + * @param {object} parameters Parameters supplied to the begin reset virtual + * network gateway connection shared key operation through network resource + * provider. + * + * @param {number} parameters.keyLength The virtual network connection reset + * shared key length, should between 1 and 128. * * @param {object} [options] Optional Parameters. * @@ -25584,7 +30767,7 @@ export interface VirtualNetworkPeerings { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkPeering} - The deserialized result object. + * @resolve {ConnectionResetSharedKey} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -25592,20 +30775,22 @@ export interface VirtualNetworkPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkPeering} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkPeering} for more information. + * {ConnectionResetSharedKey} [result] - The deserialized result object if an error did not occur. + * See {@link ConnectionResetSharedKey} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, virtualNetworkPeeringParameters: models.VirtualNetworkPeering, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, virtualNetworkPeeringParameters: models.VirtualNetworkPeering, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, virtualNetworkName: string, virtualNetworkPeeringName: string, virtualNetworkPeeringParameters: models.VirtualNetworkPeering, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginResetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionResetSharedKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginResetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionResetSharedKey, callback: ServiceCallback): void; + beginResetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionResetSharedKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all virtual network peerings in a virtual network. + * The List VirtualNetworkGatewayConnections operation retrieves all the + * virtual network gateways connections created. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -25617,14 +30802,15 @@ export interface VirtualNetworkPeerings { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all virtual network peerings in a virtual network. + * The List VirtualNetworkGatewayConnections operation retrieves all the + * virtual network gateways connections created. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -25641,7 +30827,7 @@ export interface VirtualNetworkPeerings { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkPeeringListResult} - The deserialized result object. + * @resolve {VirtualNetworkGatewayConnectionListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -25649,112 +30835,106 @@ export interface VirtualNetworkPeerings { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkPeeringListResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkPeeringListResult} for more - * information. + * {VirtualNetworkGatewayConnectionListResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkGatewayConnectionListResult} + * for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } /** * @class - * VirtualNetworkGateways + * LocalNetworkGateways * __NOTE__: An instance of this class is automatically created for an * instance of the NetworkManagementClient. */ -export interface VirtualNetworkGateways { +export interface LocalNetworkGateways { /** - * Creates or updates a virtual network gateway in the specified resource - * group. + * Creates or updates a local network gateway in the specified resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkGatewayName The name of the virtual network + * @param {string} localNetworkGatewayName The name of the local network * gateway. * - * @param {object} parameters Parameters supplied to create or update virtual + * @param {object} parameters Parameters supplied to the create or update local * network gateway operation. * - * @param {array} [parameters.ipConfigurations] IP configurations for virtual - * network gateway. + * @param {object} [parameters.localNetworkAddressSpace] Local network site + * address space. * - * @param {string} [parameters.gatewayType] The type of this virtual network - * gateway. Possible values are: 'Vpn' and 'ExpressRoute'. Possible values - * include: 'Vpn', 'ExpressRoute' + * @param {array} [parameters.localNetworkAddressSpace.addressPrefixes] A list + * of address blocks reserved for this virtual network in CIDR notation. * - * @param {string} [parameters.vpnType] The type of this virtual network - * gateway. Possible values are: 'PolicyBased' and 'RouteBased'. Possible - * values include: 'PolicyBased', 'RouteBased' + * @param {string} [parameters.gatewayIpAddress] IP address of local network + * gateway. * - * @param {boolean} [parameters.enableBgp] Whether BGP is enabled for this - * virtual network gateway or not. + * @param {object} [parameters.bgpSettings] Local network gateway's BGP speaker + * settings. * - * @param {boolean} [parameters.activeActive] ActiveActive flag + * @param {number} [parameters.bgpSettings.asn] The BGP speaker's ASN. * - * @param {object} [parameters.gatewayDefaultSite] The reference of the - * LocalNetworkGateway resource which represents local network site having - * default routes. Assign Null value in case of removing existing default site - * setting. + * @param {string} [parameters.bgpSettings.bgpPeeringAddress] The BGP peering + * address and BGP identifier of this BGP speaker. * - * @param {string} [parameters.gatewayDefaultSite.id] Resource ID. + * @param {number} [parameters.bgpSettings.peerWeight] The weight added to + * routes learned from this BGP speaker. * - * @param {object} [parameters.sku] The reference of the - * VirtualNetworkGatewaySku resource which represents the SKU selected for - * Virtual network gateway. + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * LocalNetworkGateway resource. * - * @param {string} [parameters.sku.name] Gateway SKU name. Possible values - * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. * - * @param {string} [parameters.sku.tier] Gateway SKU tier. Possible values - * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * @param {string} [parameters.id] Resource ID. * - * @param {number} [parameters.sku.capacity] The capacity. + * @param {string} [parameters.location] Resource location. * - * @param {object} [parameters.vpnClientConfiguration] The reference of the - * VpnClientConfiguration resource which represents the P2S VpnClient - * configurations. + * @param {object} [parameters.tags] Resource tags. * - * @param {object} [parameters.vpnClientConfiguration.vpnClientAddressPool] The - * reference of the address space resource which represents Address space for - * P2S VpnClient. + * @param {object} [options] Optional Parameters. * - * @param {array} - * [parameters.vpnClientConfiguration.vpnClientAddressPool.addressPrefixes] A - * list of address blocks reserved for this virtual network in CIDR notation. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {array} [parameters.vpnClientConfiguration.vpnClientRootCertificates] - * VpnClientRootCertificate for virtual network gateway. + * @returns {Promise} A promise is returned * - * @param {array} - * [parameters.vpnClientConfiguration.vpnClientRevokedCertificates] - * VpnClientRevokedCertificate for Virtual network gateway. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {array} [parameters.vpnClientConfiguration.vpnClientProtocols] - * VpnClientProtocols for Virtual network gateway. + * @reject {Error|ServiceError} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.LocalNetworkGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a local network gateway in the specified resource group. * - * @param {array} [parameters.vpnClientConfiguration.vpnClientIpsecPolicies] - * VpnClientIpsecPolicies for virtual network gateway P2S client. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [parameters.vpnClientConfiguration.radiusServerAddress] The - * radius server address property of the VirtualNetworkGateway resource for vpn - * client connection. + * @param {string} localNetworkGatewayName The name of the local network + * gateway. * - * @param {string} [parameters.vpnClientConfiguration.radiusServerSecret] The - * radius secret property of the VirtualNetworkGateway resource for vpn client - * connection. + * @param {object} parameters Parameters supplied to the create or update local + * network gateway operation. * - * @param {object} [parameters.bgpSettings] Virtual network gateway's BGP - * speaker settings. + * @param {object} [parameters.localNetworkAddressSpace] Local network site + * address space. + * + * @param {array} [parameters.localNetworkAddressSpace.addressPrefixes] A list + * of address blocks reserved for this virtual network in CIDR notation. + * + * @param {string} [parameters.gatewayIpAddress] IP address of local network + * gateway. + * + * @param {object} [parameters.bgpSettings] Local network gateway's BGP speaker + * settings. * * @param {number} [parameters.bgpSettings.asn] The BGP speaker's ASN. * @@ -25765,10 +30945,10 @@ export interface VirtualNetworkGateways { * routes learned from this BGP speaker. * * @param {string} [parameters.resourceGuid] The resource GUID property of the - * VirtualNetworkGateway resource. + * LocalNetworkGateway resource. * - * @param {string} [parameters.etag] Gets a unique read-only string that - * changes whenever the resource is updated. + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. * * @param {string} [parameters.id] Resource ID. * @@ -25781,118 +30961,122 @@ export interface VirtualNetworkGateways { * @param {object} [options.customHeaders] Headers that will be added to the * request * - * @returns {Promise} A promise is returned + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @reject {Error|ServiceError} - The error object. + * {Promise} A promise is returned. + * + * @resolve {LocalNetworkGateway} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {LocalNetworkGateway} [result] - The deserialized result object if an error did not occur. + * See {@link LocalNetworkGateway} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VirtualNetworkGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdate(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.LocalNetworkGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.LocalNetworkGateway, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.LocalNetworkGateway, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + /** - * Creates or updates a virtual network gateway in the specified resource - * group. + * Gets the specified local network gateway in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkGatewayName The name of the virtual network + * @param {string} localNetworkGatewayName The name of the local network * gateway. * - * @param {object} parameters Parameters supplied to create or update virtual - * network gateway operation. - * - * @param {array} [parameters.ipConfigurations] IP configurations for virtual - * network gateway. - * - * @param {string} [parameters.gatewayType] The type of this virtual network - * gateway. Possible values are: 'Vpn' and 'ExpressRoute'. Possible values - * include: 'Vpn', 'ExpressRoute' - * - * @param {string} [parameters.vpnType] The type of this virtual network - * gateway. Possible values are: 'PolicyBased' and 'RouteBased'. Possible - * values include: 'PolicyBased', 'RouteBased' + * @param {object} [options] Optional Parameters. * - * @param {boolean} [parameters.enableBgp] Whether BGP is enabled for this - * virtual network gateway or not. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {boolean} [parameters.activeActive] ActiveActive flag + * @returns {Promise} A promise is returned * - * @param {object} [parameters.gatewayDefaultSite] The reference of the - * LocalNetworkGateway resource which represents local network site having - * default routes. Assign Null value in case of removing existing default site - * setting. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [parameters.gatewayDefaultSite.id] Resource ID. + * @reject {Error|ServiceError} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName: string, localNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets the specified local network gateway in a resource group. * - * @param {object} [parameters.sku] The reference of the - * VirtualNetworkGatewaySku resource which represents the SKU selected for - * Virtual network gateway. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [parameters.sku.name] Gateway SKU name. Possible values - * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * @param {string} localNetworkGatewayName The name of the local network + * gateway. * - * @param {string} [parameters.sku.tier] Gateway SKU tier. Possible values - * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * @param {object} [options] Optional Parameters. * - * @param {number} [parameters.sku.capacity] The capacity. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} [parameters.vpnClientConfiguration] The reference of the - * VpnClientConfiguration resource which represents the P2S VpnClient - * configurations. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {object} [parameters.vpnClientConfiguration.vpnClientAddressPool] The - * reference of the address space resource which represents Address space for - * P2S VpnClient. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {array} - * [parameters.vpnClientConfiguration.vpnClientAddressPool.addressPrefixes] A - * list of address blocks reserved for this virtual network in CIDR notation. + * {Promise} A promise is returned. * - * @param {array} [parameters.vpnClientConfiguration.vpnClientRootCertificates] - * VpnClientRootCertificate for virtual network gateway. + * @resolve {LocalNetworkGateway} - The deserialized result object. * - * @param {array} - * [parameters.vpnClientConfiguration.vpnClientRevokedCertificates] - * VpnClientRevokedCertificate for Virtual network gateway. + * @reject {Error|ServiceError} - The error object. * - * @param {array} [parameters.vpnClientConfiguration.vpnClientProtocols] - * VpnClientProtocols for Virtual network gateway. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {array} [parameters.vpnClientConfiguration.vpnClientIpsecPolicies] - * VpnClientIpsecPolicies for virtual network gateway P2S client. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [parameters.vpnClientConfiguration.radiusServerAddress] The - * radius server address property of the VirtualNetworkGateway resource for vpn - * client connection. + * {LocalNetworkGateway} [result] - The deserialized result object if an error did not occur. + * See {@link LocalNetworkGateway} for more information. * - * @param {string} [parameters.vpnClientConfiguration.radiusServerSecret] The - * radius secret property of the VirtualNetworkGateway resource for vpn client - * connection. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {object} [parameters.bgpSettings] Virtual network gateway's BGP - * speaker settings. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName: string, localNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, localNetworkGatewayName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, localNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes the specified local network gateway. * - * @param {number} [parameters.bgpSettings.asn] The BGP speaker's ASN. + * @param {string} resourceGroupName The name of the resource group. * - * @param {string} [parameters.bgpSettings.bgpPeeringAddress] The BGP peering - * address and BGP identifier of this BGP speaker. + * @param {string} localNetworkGatewayName The name of the local network + * gateway. * - * @param {number} [parameters.bgpSettings.peerWeight] The weight added to - * routes learned from this BGP speaker. + * @param {object} [options] Optional Parameters. * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * VirtualNetworkGateway resource. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.etag] Gets a unique read-only string that - * changes whenever the resource is updated. + * @returns {Promise} A promise is returned * - * @param {string} [parameters.id] Resource ID. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [parameters.location] Resource location. + * @reject {Error|ServiceError} - The error object. + */ + deleteMethodWithHttpOperationResponse(resourceGroupName: string, localNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes the specified local network gateway. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} localNetworkGatewayName The name of the local network + * gateway. * * @param {object} [options] Optional Parameters. * @@ -25906,7 +31090,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGateway} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -25914,26 +31098,30 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGateway} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGateway} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VirtualNetworkGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VirtualNetworkGateway, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VirtualNetworkGateway, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, localNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, localNetworkGatewayName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, localNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified virtual network gateway by resource group. + * Updates a local network gateway tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkGatewayName The name of the virtual network + * @param {string} localNetworkGatewayName The name of the local network * gateway. * + * @param {object} parameters Parameters supplied to update local network + * gateway tags. + * + * @param {object} [parameters.tags] Resource tags. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -25941,20 +31129,25 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateTagsWithHttpOperationResponse(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified virtual network gateway by resource group. + * Updates a local network gateway tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkGatewayName The name of the virtual network + * @param {string} localNetworkGatewayName The name of the local network * gateway. * + * @param {object} parameters Parameters supplied to update local network + * gateway tags. + * + * @param {object} [parameters.tags] Resource tags. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -25967,7 +31160,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGateway} - The deserialized result object. + * @resolve {LocalNetworkGateway} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -25975,26 +31168,23 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGateway} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGateway} for more information. + * {LocalNetworkGateway} [result] - The deserialized result object if an error did not occur. + * See {@link LocalNetworkGateway} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified virtual network gateway. + * Gets all the local network gateways in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -26002,20 +31192,17 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified virtual network gateway. + * Gets all the local network gateways in a resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -26028,7 +31215,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {LocalNetworkGatewayListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -26036,27 +31223,59 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {LocalNetworkGatewayListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LocalNetworkGatewayListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a virtual network gateway tags. + * Creates or updates a local network gateway in the specified resource group. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkGatewayName The name of the virtual network + * @param {string} localNetworkGatewayName The name of the local network * gateway. * - * @param {object} parameters Parameters supplied to update virtual network - * gateway tags. + * @param {object} parameters Parameters supplied to the create or update local + * network gateway operation. + * + * @param {object} [parameters.localNetworkAddressSpace] Local network site + * address space. + * + * @param {array} [parameters.localNetworkAddressSpace.addressPrefixes] A list + * of address blocks reserved for this virtual network in CIDR notation. + * + * @param {string} [parameters.gatewayIpAddress] IP address of local network + * gateway. + * + * @param {object} [parameters.bgpSettings] Local network gateway's BGP speaker + * settings. + * + * @param {number} [parameters.bgpSettings.asn] The BGP speaker's ASN. + * + * @param {string} [parameters.bgpSettings.bgpPeeringAddress] The BGP peering + * address and BGP identifier of this BGP speaker. + * + * @param {number} [parameters.bgpSettings.peerWeight] The weight added to + * routes learned from this BGP speaker. + * + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * LocalNetworkGateway resource. + * + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. + * + * @param {string} [parameters.id] Resource ID. + * + * @param {string} [parameters.location] Resource location. * * @param {object} [parameters.tags] Resource tags. * @@ -26067,22 +31286,52 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.LocalNetworkGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a local network gateway in the specified resource group. + * + * @param {string} resourceGroupName The name of the resource group. + * + * @param {string} localNetworkGatewayName The name of the local network + * gateway. + * + * @param {object} parameters Parameters supplied to the create or update local + * network gateway operation. + * + * @param {object} [parameters.localNetworkAddressSpace] Local network site + * address space. + * + * @param {array} [parameters.localNetworkAddressSpace.addressPrefixes] A list + * of address blocks reserved for this virtual network in CIDR notation. + * + * @param {string} [parameters.gatewayIpAddress] IP address of local network + * gateway. + * + * @param {object} [parameters.bgpSettings] Local network gateway's BGP speaker + * settings. + * + * @param {number} [parameters.bgpSettings.asn] The BGP speaker's ASN. + * + * @param {string} [parameters.bgpSettings.bgpPeeringAddress] The BGP peering + * address and BGP identifier of this BGP speaker. + * + * @param {number} [parameters.bgpSettings.peerWeight] The weight added to + * routes learned from this BGP speaker. * - * @reject {Error|ServiceError} - The error object. - */ - updateTagsWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Updates a virtual network gateway tags. + * @param {string} [parameters.resourceGuid] The resource GUID property of the + * LocalNetworkGateway resource. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [parameters.etag] A unique read-only string that changes + * whenever the resource is updated. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} [parameters.id] Resource ID. * - * @param {object} parameters Parameters supplied to update virtual network - * gateway tags. + * @param {string} [parameters.location] Resource location. * * @param {object} [parameters.tags] Resource tags. * @@ -26098,7 +31347,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGateway} - The deserialized result object. + * @resolve {LocalNetworkGateway} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -26106,23 +31355,26 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGateway} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGateway} for more information. + * {LocalNetworkGateway} [result] - The deserialized result object if an error did not occur. + * See {@link LocalNetworkGateway} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - updateTags(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - updateTags(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - updateTags(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.LocalNetworkGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.LocalNetworkGateway, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.LocalNetworkGateway, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all virtual network gateways by resource group. + * Deletes the specified local network gateway. * * @param {string} resourceGroupName The name of the resource group. * + * @param {string} localNetworkGatewayName The name of the local network + * gateway. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -26130,17 +31382,20 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, localNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all virtual network gateways by resource group. + * Deletes the specified local network gateway. * * @param {string} resourceGroupName The name of the resource group. * + * @param {string} localNetworkGatewayName The name of the local network + * gateway. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -26153,7 +31408,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGatewayListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -26161,27 +31416,30 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGatewayListResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGatewayListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, localNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, localNetworkGatewayName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, localNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the connections in a virtual network gateway. + * Updates a local network gateway tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkGatewayName The name of the virtual network + * @param {string} localNetworkGatewayName The name of the local network * gateway. * + * @param {object} parameters Parameters supplied to update local network + * gateway tags. + * + * @param {object} [parameters.tags] Resource tags. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -26189,20 +31447,25 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listConnectionsWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the connections in a virtual network gateway. + * Updates a local network gateway tags. * * @param {string} resourceGroupName The name of the resource group. * - * @param {string} virtualNetworkGatewayName The name of the virtual network + * @param {string} localNetworkGatewayName The name of the local network * gateway. * + * @param {object} parameters Parameters supplied to update local network + * gateway tags. + * + * @param {object} [parameters.tags] Resource tags. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -26215,7 +31478,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGatewayListConnectionsResult} - The deserialized result object. + * @resolve {LocalNetworkGateway} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -26223,58 +31486,45 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGatewayListConnectionsResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGatewayListConnectionsResult} - * for more information. + * {LocalNetworkGateway} [result] - The deserialized result object if an error did not occur. + * See {@link LocalNetworkGateway} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listConnections(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listConnections(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; - listConnections(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdateTags(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.TagsObject, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Resets the primary of the virtual network gateway in the specified resource - * group. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets all the local network gateways in a resource group. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.gatewayVip] Virtual network gateway vip address - * supplied to the begin reset of the active-active feature enabled gateway. - * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - resetWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { gatewayVip? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Resets the primary of the virtual network gateway in the specified resource - * group. - * - * @param {string} resourceGroupName The name of the resource group. + * Gets all the local network gateways in a resource group. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.gatewayVip] Virtual network gateway vip address - * supplied to the begin reset of the active-active feature enabled gateway. - * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -26285,7 +31535,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGateway} - The deserialized result object. + * @resolve {LocalNetworkGatewayListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -26293,46 +31543,34 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGateway} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGateway} for more information. + * {LocalNetworkGatewayListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LocalNetworkGatewayListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - reset(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { gatewayVip? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - reset(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; - reset(resourceGroupName: string, virtualNetworkGatewayName: string, options: { gatewayVip? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * VirtualWANs + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface VirtualWANs { /** - * Generates VPN client package for P2S client of the virtual network gateway - * in the specified resource group. - * - * @param {string} resourceGroupName The name of the resource group. + * Retrieves the details of a VirtualWAN. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. - * - * @param {object} parameters Parameters supplied to the generate virtual - * network gateway VPN client package operation. - * - * @param {string} [parameters.processorArchitecture] VPN client Processor - * Architecture. Possible values are: 'AMD64' and 'X86'. Possible values - * include: 'Amd64', 'X86' - * - * @param {string} [parameters.authenticationMethod] VPN client Authentication - * Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values - * include: 'EAPTLS', 'EAPMSCHAPv2' - * - * @param {string} [parameters.radiusServerAuthCertificate] The public - * certificate data for the radius server authentication certificate as a - * Base-64 encoded string. Required only if external radius authentication has - * been configured with EAPTLS authentication. + * @param {string} resourceGroupName The resource group name of the VirtualWan. * - * @param {array} [parameters.clientRootCertificates] A list of client root - * certificates public certificate data encoded as Base-64 strings. Optional - * parameter for external radius based authentication with EAPTLS. + * @param {string} virtualWANName The name of the VirtualWAN being retrieved. * * @param {object} [options] Optional Parameters. * @@ -26341,40 +31579,18 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - generatevpnclientpackageWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, virtualWANName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Generates VPN client package for P2S client of the virtual network gateway - * in the specified resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. - * - * @param {object} parameters Parameters supplied to the generate virtual - * network gateway VPN client package operation. - * - * @param {string} [parameters.processorArchitecture] VPN client Processor - * Architecture. Possible values are: 'AMD64' and 'X86'. Possible values - * include: 'Amd64', 'X86' - * - * @param {string} [parameters.authenticationMethod] VPN client Authentication - * Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values - * include: 'EAPTLS', 'EAPMSCHAPv2' + * Retrieves the details of a VirtualWAN. * - * @param {string} [parameters.radiusServerAuthCertificate] The public - * certificate data for the radius server authentication certificate as a - * Base-64 encoded string. Required only if external radius authentication has - * been configured with EAPTLS authentication. + * @param {string} resourceGroupName The resource group name of the VirtualWan. * - * @param {array} [parameters.clientRootCertificates] A list of client root - * certificates public certificate data encoded as Base-64 strings. Optional - * parameter for external radius based authentication with EAPTLS. + * @param {string} virtualWANName The name of the VirtualWAN being retrieved. * * @param {object} [options] Optional Parameters. * @@ -26388,7 +31604,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {String} - The deserialized result object. + * @resolve {VirtualWAN} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -26396,45 +31612,42 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {String} [result] - The deserialized result object if an error did not occur. + * {VirtualWAN} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualWAN} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - generatevpnclientpackage(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - generatevpnclientpackage(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, callback: ServiceCallback): void; - generatevpnclientpackage(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, virtualWANName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, virtualWANName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, virtualWANName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Generates VPN profile for P2S client of the virtual network gateway in the - * specified resource group. Used for IKEV2 and radius based authentication. + * Creates a VirtualWAN resource if it doesn't exist else updates the existing + * VirtualWAN. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualWan. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} virtualWANName The name of the VirtualWAN being created or + * updated. * - * @param {object} parameters Parameters supplied to the generate virtual - * network gateway VPN client package operation. + * @param {object} wANParameters Parameters supplied to create or update + * VirtualWAN. * - * @param {string} [parameters.processorArchitecture] VPN client Processor - * Architecture. Possible values are: 'AMD64' and 'X86'. Possible values - * include: 'Amd64', 'X86' + * @param {boolean} [wANParameters.disableVpnEncryption] Vpn encryption to be + * disabled or not. * - * @param {string} [parameters.authenticationMethod] VPN client Authentication - * Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values - * include: 'EAPTLS', 'EAPMSCHAPv2' + * @param {string} [wANParameters.provisioningState] The provisioning state of + * the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' * - * @param {string} [parameters.radiusServerAuthCertificate] The public - * certificate data for the radius server authentication certificate as a - * Base-64 encoded string. Required only if external radius authentication has - * been configured with EAPTLS authentication. + * @param {string} [wANParameters.id] Resource ID. * - * @param {array} [parameters.clientRootCertificates] A list of client root - * certificates public certificate data encoded as Base-64 strings. Optional - * parameter for external radius based authentication with EAPTLS. + * @param {string} [wANParameters.location] Resource location. + * + * @param {object} [wANParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -26443,40 +31656,36 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - generateVpnProfileWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualWANName: string, wANParameters: models.VirtualWAN, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Generates VPN profile for P2S client of the virtual network gateway in the - * specified resource group. Used for IKEV2 and radius based authentication. + * Creates a VirtualWAN resource if it doesn't exist else updates the existing + * VirtualWAN. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualWan. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} virtualWANName The name of the VirtualWAN being created or + * updated. * - * @param {object} parameters Parameters supplied to the generate virtual - * network gateway VPN client package operation. + * @param {object} wANParameters Parameters supplied to create or update + * VirtualWAN. * - * @param {string} [parameters.processorArchitecture] VPN client Processor - * Architecture. Possible values are: 'AMD64' and 'X86'. Possible values - * include: 'Amd64', 'X86' + * @param {boolean} [wANParameters.disableVpnEncryption] Vpn encryption to be + * disabled or not. * - * @param {string} [parameters.authenticationMethod] VPN client Authentication - * Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values - * include: 'EAPTLS', 'EAPMSCHAPv2' + * @param {string} [wANParameters.provisioningState] The provisioning state of + * the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' * - * @param {string} [parameters.radiusServerAuthCertificate] The public - * certificate data for the radius server authentication certificate as a - * Base-64 encoded string. Required only if external radius authentication has - * been configured with EAPTLS authentication. + * @param {string} [wANParameters.id] Resource ID. * - * @param {array} [parameters.clientRootCertificates] A list of client root - * certificates public certificate data encoded as Base-64 strings. Optional - * parameter for external radius based authentication with EAPTLS. + * @param {string} [wANParameters.location] Resource location. + * + * @param {object} [wANParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -26490,7 +31699,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {String} - The deserialized result object. + * @resolve {VirtualWAN} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -26498,26 +31707,28 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {String} [result] - The deserialized result object if an error did not occur. + * {VirtualWAN} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualWAN} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - generateVpnProfile(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - generateVpnProfile(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, callback: ServiceCallback): void; - generateVpnProfile(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, virtualWANName: string, wANParameters: models.VirtualWAN, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, virtualWANName: string, wANParameters: models.VirtualWAN, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, virtualWANName: string, wANParameters: models.VirtualWAN, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets pre-generated VPN profile for P2S client of the virtual network gateway - * in the specified resource group. The profile needs to be generated first - * using generateVpnProfile. + * Updates a VirtualWAN tags. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualWan. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} virtualWANName The name of the VirtualWAN being updated. + * + * @param {object} wANParameters Parameters supplied to Update VirtualWAN tags. + * + * @param {object} [wANParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -26526,21 +31737,22 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getVpnProfilePackageUrlWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateTagsWithHttpOperationResponse(resourceGroupName: string, virtualWANName: string, wANParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets pre-generated VPN profile for P2S client of the virtual network gateway - * in the specified resource group. The profile needs to be generated first - * using generateVpnProfile. + * Updates a VirtualWAN tags. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualWan. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} virtualWANName The name of the VirtualWAN being updated. + * + * @param {object} wANParameters Parameters supplied to Update VirtualWAN tags. + * + * @param {object} [wANParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -26554,7 +31766,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {String} - The deserialized result object. + * @resolve {VirtualWAN} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -26562,54 +31774,47 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {String} [result] - The deserialized result object if an error did not occur. + * {VirtualWAN} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualWAN} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getVpnProfilePackageUrl(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getVpnProfilePackageUrl(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; - getVpnProfilePackageUrl(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, virtualWANName: string, wANParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, virtualWANName: string, wANParameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, virtualWANName: string, wANParameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * The GetBgpPeerStatus operation retrieves the status of all BGP peers. + * Deletes a VirtualWAN. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualWan. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} virtualWANName The name of the VirtualWAN being deleted. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.peer] The IP address of the peer to retrieve the - * status of. - * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getBgpPeerStatusWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { peer? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualWANName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * The GetBgpPeerStatus operation retrieves the status of all BGP peers. + * Deletes a VirtualWAN. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualWan. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} virtualWANName The name of the VirtualWAN being deleted. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.peer] The IP address of the peer to retrieve the - * status of. - * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -26620,7 +31825,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {BgpPeerStatusListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -26628,26 +31833,21 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {BgpPeerStatusListResult} [result] - The deserialized result object if an error did not occur. - * See {@link BgpPeerStatusListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getBgpPeerStatus(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { peer? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - getBgpPeerStatus(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; - getBgpPeerStatus(resourceGroupName: string, virtualNetworkGatewayName: string, options: { peer? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, virtualWANName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, virtualWANName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, virtualWANName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a xml format representation for supported vpn devices. + * Lists all the VirtualWANs in a resource group. * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} resourceGroupName The resource group name of the VirtualWan. * * @param {object} [options] Optional Parameters. * @@ -26656,19 +31856,16 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - supportedVpnDevicesWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByResourceGroupWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a xml format representation for supported vpn devices. - * - * @param {string} resourceGroupName The name of the resource group. + * Lists all the VirtualWANs in a resource group. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} resourceGroupName The resource group name of the VirtualWan. * * @param {object} [options] Optional Parameters. * @@ -26682,7 +31879,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {String} - The deserialized result object. + * @resolve {ListVirtualWANsResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -26690,25 +31887,20 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {String} [result] - The deserialized result object if an error did not occur. + * {ListVirtualWANsResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualWANsResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - supportedVpnDevices(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - supportedVpnDevices(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; - supportedVpnDevices(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByResourceGroup(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroup(resourceGroupName: string, callback: ServiceCallback): void; + listByResourceGroup(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * This operation retrieves a list of routes the virtual network gateway has - * learned, including routes learned from BGP peers. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * Lists all the VirtualWANs in a subscription. * * @param {object} [options] Optional Parameters. * @@ -26717,20 +31909,14 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getLearnedRoutesWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * This operation retrieves a list of routes the virtual network gateway has - * learned, including routes learned from BGP peers. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * Lists all the VirtualWANs in a subscription. * * @param {object} [options] Optional Parameters. * @@ -26744,7 +31930,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {GatewayRouteListResult} - The deserialized result object. + * @resolve {ListVirtualWANsResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -26752,29 +31938,42 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {GatewayRouteListResult} [result] - The deserialized result object if an error did not occur. - * See {@link GatewayRouteListResult} for more - * information. + * {ListVirtualWANsResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualWANsResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getLearnedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getLearnedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; - getLearnedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(callback: ServiceCallback): void; + list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * This operation retrieves a list of routes the virtual network gateway is - * advertising to the specified peer. + * Creates a VirtualWAN resource if it doesn't exist else updates the existing + * VirtualWAN. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualWan. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} virtualWANName The name of the VirtualWAN being created or + * updated. * - * @param {string} peer The IP address of the peer + * @param {object} wANParameters Parameters supplied to create or update + * VirtualWAN. + * + * @param {boolean} [wANParameters.disableVpnEncryption] Vpn encryption to be + * disabled or not. + * + * @param {string} [wANParameters.provisioningState] The provisioning state of + * the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * + * @param {string} [wANParameters.id] Resource ID. + * + * @param {string} [wANParameters.location] Resource location. + * + * @param {object} [wANParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -26783,22 +31982,36 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getAdvertisedRoutesWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, peer: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualWANName: string, wANParameters: models.VirtualWAN, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * This operation retrieves a list of routes the virtual network gateway is - * advertising to the specified peer. + * Creates a VirtualWAN resource if it doesn't exist else updates the existing + * VirtualWAN. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualWan. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} virtualWANName The name of the VirtualWAN being created or + * updated. * - * @param {string} peer The IP address of the peer + * @param {object} wANParameters Parameters supplied to create or update + * VirtualWAN. + * + * @param {boolean} [wANParameters.disableVpnEncryption] Vpn encryption to be + * disabled or not. + * + * @param {string} [wANParameters.provisioningState] The provisioning state of + * the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * + * @param {string} [wANParameters.id] Resource ID. + * + * @param {string} [wANParameters.location] Resource location. + * + * @param {object} [wANParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -26812,7 +32025,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {GatewayRouteListResult} - The deserialized result object. + * @resolve {VirtualWAN} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -26820,64 +32033,28 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {GatewayRouteListResult} [result] - The deserialized result object if an error did not occur. - * See {@link GatewayRouteListResult} for more - * information. + * {VirtualWAN} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualWAN} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getAdvertisedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, peer: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getAdvertisedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, peer: string, callback: ServiceCallback): void; - getAdvertisedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, peer: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, virtualWANName: string, wANParameters: models.VirtualWAN, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, virtualWANName: string, wANParameters: models.VirtualWAN, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, virtualWANName: string, wANParameters: models.VirtualWAN, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * The Set VpnclientIpsecParameters operation sets the vpnclient ipsec policy - * for P2S client of virtual network gateway in the specified resource group - * through Network resource provider. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. - * - * @param {object} vpnclientIpsecParams Parameters supplied to the Begin Set - * vpnclient ipsec parameters of Virtual Network Gateway P2S client operation - * through Network resource provider. - * - * @param {number} vpnclientIpsecParams.saLifeTimeSeconds The IPSec Security - * Association (also called Quick Mode or Phase 2 SA) lifetime in seconds for - * P2S client. - * - * @param {number} vpnclientIpsecParams.saDataSizeKilobytes The IPSec Security - * Association (also called Quick Mode or Phase 2 SA) payload size in KB for - * P2S client.. - * - * @param {string} vpnclientIpsecParams.ipsecEncryption The IPSec encryption - * algorithm (IKE phase 1). Possible values include: 'None', 'DES', 'DES3', - * 'AES128', 'AES192', 'AES256', 'GCMAES128', 'GCMAES192', 'GCMAES256' - * - * @param {string} vpnclientIpsecParams.ipsecIntegrity The IPSec integrity - * algorithm (IKE phase 1). Possible values include: 'MD5', 'SHA1', 'SHA256', - * 'GCMAES128', 'GCMAES192', 'GCMAES256' + * Updates a VirtualWAN tags. * - * @param {string} vpnclientIpsecParams.ikeEncryption The IKE encryption - * algorithm (IKE phase 2). Possible values include: 'DES', 'DES3', 'AES128', - * 'AES192', 'AES256', 'GCMAES256', 'GCMAES128' + * @param {string} resourceGroupName The resource group name of the VirtualWan. * - * @param {string} vpnclientIpsecParams.ikeIntegrity The IKE integrity - * algorithm (IKE phase 2). Possible values include: 'MD5', 'SHA1', 'SHA256', - * 'SHA384', 'GCMAES256', 'GCMAES128' + * @param {string} virtualWANName The name of the VirtualWAN being updated. * - * @param {string} vpnclientIpsecParams.dhGroup The DH Groups used in IKE Phase - * 1 for initial SA. Possible values include: 'None', 'DHGroup1', 'DHGroup2', - * 'DHGroup14', 'DHGroup2048', 'ECP256', 'ECP384', 'DHGroup24' + * @param {object} wANParameters Parameters supplied to Update VirtualWAN tags. * - * @param {string} vpnclientIpsecParams.pfsGroup The Pfs Groups used in IKE - * Phase 2 for new child SA. Possible values include: 'None', 'PFS1', 'PFS2', - * 'PFS2048', 'ECP256', 'ECP384', 'PFS24', 'PFS14', 'PFSMM' + * @param {object} [wANParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -26886,57 +32063,22 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - setVpnclientIpsecParametersWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, vpnclientIpsecParams: models.VpnClientIPsecParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, virtualWANName: string, wANParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * The Set VpnclientIpsecParameters operation sets the vpnclient ipsec policy - * for P2S client of virtual network gateway in the specified resource group - * through Network resource provider. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * Updates a VirtualWAN tags. * - * @param {object} vpnclientIpsecParams Parameters supplied to the Begin Set - * vpnclient ipsec parameters of Virtual Network Gateway P2S client operation - * through Network resource provider. - * - * @param {number} vpnclientIpsecParams.saLifeTimeSeconds The IPSec Security - * Association (also called Quick Mode or Phase 2 SA) lifetime in seconds for - * P2S client. - * - * @param {number} vpnclientIpsecParams.saDataSizeKilobytes The IPSec Security - * Association (also called Quick Mode or Phase 2 SA) payload size in KB for - * P2S client.. - * - * @param {string} vpnclientIpsecParams.ipsecEncryption The IPSec encryption - * algorithm (IKE phase 1). Possible values include: 'None', 'DES', 'DES3', - * 'AES128', 'AES192', 'AES256', 'GCMAES128', 'GCMAES192', 'GCMAES256' - * - * @param {string} vpnclientIpsecParams.ipsecIntegrity The IPSec integrity - * algorithm (IKE phase 1). Possible values include: 'MD5', 'SHA1', 'SHA256', - * 'GCMAES128', 'GCMAES192', 'GCMAES256' - * - * @param {string} vpnclientIpsecParams.ikeEncryption The IKE encryption - * algorithm (IKE phase 2). Possible values include: 'DES', 'DES3', 'AES128', - * 'AES192', 'AES256', 'GCMAES256', 'GCMAES128' + * @param {string} resourceGroupName The resource group name of the VirtualWan. * - * @param {string} vpnclientIpsecParams.ikeIntegrity The IKE integrity - * algorithm (IKE phase 2). Possible values include: 'MD5', 'SHA1', 'SHA256', - * 'SHA384', 'GCMAES256', 'GCMAES128' + * @param {string} virtualWANName The name of the VirtualWAN being updated. * - * @param {string} vpnclientIpsecParams.dhGroup The DH Groups used in IKE Phase - * 1 for initial SA. Possible values include: 'None', 'DHGroup1', 'DHGroup2', - * 'DHGroup14', 'DHGroup2048', 'ECP256', 'ECP384', 'DHGroup24' + * @param {object} wANParameters Parameters supplied to Update VirtualWAN tags. * - * @param {string} vpnclientIpsecParams.pfsGroup The Pfs Groups used in IKE - * Phase 2 for new child SA. Possible values include: 'None', 'PFS1', 'PFS2', - * 'PFS2048', 'ECP256', 'ECP384', 'PFS24', 'PFS14', 'PFSMM' + * @param {object} [wANParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -26950,7 +32092,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {VpnClientIPsecParameters} - The deserialized result object. + * @resolve {VirtualWAN} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -26958,27 +32100,24 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VpnClientIPsecParameters} [result] - The deserialized result object if an error did not occur. - * See {@link VpnClientIPsecParameters} for more - * information. + * {VirtualWAN} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualWAN} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - setVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, vpnclientIpsecParams: models.VpnClientIPsecParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - setVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, vpnclientIpsecParams: models.VpnClientIPsecParameters, callback: ServiceCallback): void; - setVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, vpnclientIpsecParams: models.VpnClientIPsecParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, virtualWANName: string, wANParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdateTags(resourceGroupName: string, virtualWANName: string, wANParameters: models.TagsObject, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, virtualWANName: string, wANParameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * The Get VpnclientIpsecParameters operation retrieves information about the - * vpnclient ipsec policy for P2S client of virtual network gateway in the - * specified resource group through Network resource provider. + * Deletes a VirtualWAN. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualWan. * - * @param {string} virtualNetworkGatewayName The virtual network gateway name. + * @param {string} virtualWANName The name of the VirtualWAN being deleted. * * @param {object} [options] Optional Parameters. * @@ -26987,20 +32126,18 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getVpnclientIpsecParametersWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualWANName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * The Get VpnclientIpsecParameters operation retrieves information about the - * vpnclient ipsec policy for P2S client of virtual network gateway in the - * specified resource group through Network resource provider. + * Deletes a VirtualWAN. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualWan. * - * @param {string} virtualNetworkGatewayName The virtual network gateway name. + * @param {string} virtualWANName The name of the VirtualWAN being deleted. * * @param {object} [options] Optional Parameters. * @@ -27014,7 +32151,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {VpnClientIPsecParameters} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -27022,37 +32159,22 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VpnClientIPsecParameters} [result] - The deserialized result object if an error did not occur. - * See {@link VpnClientIPsecParameters} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; - getVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, virtualWANName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, virtualWANName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, virtualWANName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a xml format representation for vpn device configuration script. - * - * @param {string} resourceGroupName The name of the resource group. + * Lists all the VirtualWANs in a resource group. * - * @param {string} virtualNetworkGatewayConnectionName The name of the virtual - * network gateway connection for which the configuration script is generated. - * - * @param {object} parameters Parameters supplied to the generate vpn device - * script operation. - * - * @param {string} [parameters.vendor] The vendor for the vpn device. - * - * @param {string} [parameters.deviceFamily] The device family for the vpn - * device. - * - * @param {string} [parameters.firmwareVersion] The firmware version for the - * vpn device. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -27061,30 +32183,17 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - vpnDeviceConfigurationScriptWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VpnDeviceScriptParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a xml format representation for vpn device configuration script. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayConnectionName The name of the virtual - * network gateway connection for which the configuration script is generated. - * - * @param {object} parameters Parameters supplied to the generate vpn device - * script operation. - * - * @param {string} [parameters.vendor] The vendor for the vpn device. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [parameters.deviceFamily] The device family for the vpn - * device. + * @reject {Error|ServiceError} - The error object. + */ + listByResourceGroupNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists all the VirtualWANs in a resource group. * - * @param {string} [parameters.firmwareVersion] The firmware version for the - * vpn device. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -27098,7 +32207,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {String} - The deserialized result object. + * @resolve {ListVirtualWANsResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -27106,121 +32215,90 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {String} [result] - The deserialized result object if an error did not occur. + * {ListVirtualWANsResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualWANsResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - vpnDeviceConfigurationScript(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VpnDeviceScriptParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - vpnDeviceConfigurationScript(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VpnDeviceScriptParameters, callback: ServiceCallback): void; - vpnDeviceConfigurationScript(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VpnDeviceScriptParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByResourceGroupNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroupNext(nextPageLink: string, callback: ServiceCallback): void; + listByResourceGroupNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a virtual network gateway in the specified resource - * group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. - * - * @param {object} parameters Parameters supplied to create or update virtual - * network gateway operation. - * - * @param {array} [parameters.ipConfigurations] IP configurations for virtual - * network gateway. - * - * @param {string} [parameters.gatewayType] The type of this virtual network - * gateway. Possible values are: 'Vpn' and 'ExpressRoute'. Possible values - * include: 'Vpn', 'ExpressRoute' - * - * @param {string} [parameters.vpnType] The type of this virtual network - * gateway. Possible values are: 'PolicyBased' and 'RouteBased'. Possible - * values include: 'PolicyBased', 'RouteBased' - * - * @param {boolean} [parameters.enableBgp] Whether BGP is enabled for this - * virtual network gateway or not. - * - * @param {boolean} [parameters.activeActive] ActiveActive flag - * - * @param {object} [parameters.gatewayDefaultSite] The reference of the - * LocalNetworkGateway resource which represents local network site having - * default routes. Assign Null value in case of removing existing default site - * setting. - * - * @param {string} [parameters.gatewayDefaultSite.id] Resource ID. - * - * @param {object} [parameters.sku] The reference of the - * VirtualNetworkGatewaySku resource which represents the SKU selected for - * Virtual network gateway. + * Lists all the VirtualWANs in a subscription. * - * @param {string} [parameters.sku.name] Gateway SKU name. Possible values - * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {string} [parameters.sku.tier] Gateway SKU tier. Possible values - * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * @param {object} [options] Optional Parameters. * - * @param {number} [parameters.sku.capacity] The capacity. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} [parameters.vpnClientConfiguration] The reference of the - * VpnClientConfiguration resource which represents the P2S VpnClient - * configurations. + * @returns {Promise} A promise is returned * - * @param {object} [parameters.vpnClientConfiguration.vpnClientAddressPool] The - * reference of the address space resource which represents Address space for - * P2S VpnClient. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {array} - * [parameters.vpnClientConfiguration.vpnClientAddressPool.addressPrefixes] A - * list of address blocks reserved for this virtual network in CIDR notation. + * @reject {Error|ServiceError} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists all the VirtualWANs in a subscription. * - * @param {array} [parameters.vpnClientConfiguration.vpnClientRootCertificates] - * VpnClientRootCertificate for virtual network gateway. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {array} - * [parameters.vpnClientConfiguration.vpnClientRevokedCertificates] - * VpnClientRevokedCertificate for Virtual network gateway. + * @param {object} [options] Optional Parameters. * - * @param {array} [parameters.vpnClientConfiguration.vpnClientProtocols] - * VpnClientProtocols for Virtual network gateway. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {array} [parameters.vpnClientConfiguration.vpnClientIpsecPolicies] - * VpnClientIpsecPolicies for virtual network gateway P2S client. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} [parameters.vpnClientConfiguration.radiusServerAddress] The - * radius server address property of the VirtualNetworkGateway resource for vpn - * client connection. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {string} [parameters.vpnClientConfiguration.radiusServerSecret] The - * radius secret property of the VirtualNetworkGateway resource for vpn client - * connection. + * {Promise} A promise is returned. * - * @param {object} [parameters.bgpSettings] Virtual network gateway's BGP - * speaker settings. + * @resolve {ListVirtualWANsResult} - The deserialized result object. * - * @param {number} [parameters.bgpSettings.asn] The BGP speaker's ASN. + * @reject {Error|ServiceError} - The error object. * - * @param {string} [parameters.bgpSettings.bgpPeeringAddress] The BGP peering - * address and BGP identifier of this BGP speaker. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {number} [parameters.bgpSettings.peerWeight] The weight added to - * routes learned from this BGP speaker. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * VirtualNetworkGateway resource. + * {ListVirtualWANsResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualWANsResult} for more information. * - * @param {string} [parameters.etag] Gets a unique read-only string that - * changes whenever the resource is updated. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {string} [parameters.id] Resource ID. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * VpnSites + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface VpnSites { + + + /** + * Retrieves the details of a VPNsite. * - * @param {string} [parameters.location] Resource location. + * @param {string} resourceGroupName The resource group name of the VpnSite. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} vpnSiteName The name of the VpnSite being retrieved. * * @param {object} [options] Optional Parameters. * @@ -27229,177 +32307,183 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VirtualNetworkGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, vpnSiteName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a virtual network gateway in the specified resource - * group. + * Retrieves the details of a VPNsite. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnSite. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} vpnSiteName The name of the VpnSite being retrieved. * - * @param {object} parameters Parameters supplied to create or update virtual - * network gateway operation. + * @param {object} [options] Optional Parameters. * - * @param {array} [parameters.ipConfigurations] IP configurations for virtual - * network gateway. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.gatewayType] The type of this virtual network - * gateway. Possible values are: 'Vpn' and 'ExpressRoute'. Possible values - * include: 'Vpn', 'ExpressRoute' + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} [parameters.vpnType] The type of this virtual network - * gateway. Possible values are: 'PolicyBased' and 'RouteBased'. Possible - * values include: 'PolicyBased', 'RouteBased' + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {boolean} [parameters.enableBgp] Whether BGP is enabled for this - * virtual network gateway or not. + * {Promise} A promise is returned. * - * @param {boolean} [parameters.activeActive] ActiveActive flag + * @resolve {VpnSite} - The deserialized result object. * - * @param {object} [parameters.gatewayDefaultSite] The reference of the - * LocalNetworkGateway resource which represents local network site having - * default routes. Assign Null value in case of removing existing default site - * setting. + * @reject {Error|ServiceError} - The error object. * - * @param {string} [parameters.gatewayDefaultSite.id] Resource ID. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {object} [parameters.sku] The reference of the - * VirtualNetworkGatewaySku resource which represents the SKU selected for - * Virtual network gateway. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [parameters.sku.name] Gateway SKU name. Possible values - * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * {VpnSite} [result] - The deserialized result object if an error did not occur. + * See {@link VpnSite} for more information. * - * @param {string} [parameters.sku.tier] Gateway SKU tier. Possible values - * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {number} [parameters.sku.capacity] The capacity. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName: string, vpnSiteName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, vpnSiteName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, vpnSiteName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Creates a VpnSite resource if it doesn't exist else updates the existing + * VpnSite. * - * @param {object} [parameters.vpnClientConfiguration] The reference of the - * VpnClientConfiguration resource which represents the P2S VpnClient - * configurations. + * @param {string} resourceGroupName The resource group name of the VpnSite. * - * @param {object} [parameters.vpnClientConfiguration.vpnClientAddressPool] The - * reference of the address space resource which represents Address space for - * P2S VpnClient. + * @param {string} vpnSiteName The name of the VpnSite being created or + * updated. * - * @param {array} - * [parameters.vpnClientConfiguration.vpnClientAddressPool.addressPrefixes] A - * list of address blocks reserved for this virtual network in CIDR notation. + * @param {object} vpnSiteParameters Parameters supplied to create or update + * VpnSite. * - * @param {array} [parameters.vpnClientConfiguration.vpnClientRootCertificates] - * VpnClientRootCertificate for virtual network gateway. + * @param {object} [vpnSiteParameters.virtualWAN] The VirtualWAN to which the + * vpnSite belongs * - * @param {array} - * [parameters.vpnClientConfiguration.vpnClientRevokedCertificates] - * VpnClientRevokedCertificate for Virtual network gateway. + * @param {string} [vpnSiteParameters.virtualWAN.id] Resource ID. * - * @param {array} [parameters.vpnClientConfiguration.vpnClientProtocols] - * VpnClientProtocols for Virtual network gateway. + * @param {object} [vpnSiteParameters.deviceProperties] The device properties * - * @param {array} [parameters.vpnClientConfiguration.vpnClientIpsecPolicies] - * VpnClientIpsecPolicies for virtual network gateway P2S client. + * @param {string} [vpnSiteParameters.deviceProperties.deviceVendor] Name of + * the device Vendor. * - * @param {string} [parameters.vpnClientConfiguration.radiusServerAddress] The - * radius server address property of the VirtualNetworkGateway resource for vpn - * client connection. + * @param {string} [vpnSiteParameters.deviceProperties.deviceModel] Model of + * the device. * - * @param {string} [parameters.vpnClientConfiguration.radiusServerSecret] The - * radius secret property of the VirtualNetworkGateway resource for vpn client - * connection. + * @param {number} [vpnSiteParameters.deviceProperties.linkSpeedInMbps] Link + * speed. * - * @param {object} [parameters.bgpSettings] Virtual network gateway's BGP - * speaker settings. + * @param {string} [vpnSiteParameters.ipAddress] The ip-address for the + * vpn-site. * - * @param {number} [parameters.bgpSettings.asn] The BGP speaker's ASN. + * @param {string} [vpnSiteParameters.siteKey] The key for vpn-site that can be + * used for connections. * - * @param {string} [parameters.bgpSettings.bgpPeeringAddress] The BGP peering - * address and BGP identifier of this BGP speaker. + * @param {object} [vpnSiteParameters.addressSpace] The AddressSpace that + * contains an array of IP address ranges. * - * @param {number} [parameters.bgpSettings.peerWeight] The weight added to - * routes learned from this BGP speaker. + * @param {array} [vpnSiteParameters.addressSpace.addressPrefixes] A list of + * address blocks reserved for this virtual network in CIDR notation. * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * VirtualNetworkGateway resource. + * @param {object} [vpnSiteParameters.bgpProperties] The set of bgp properties. * - * @param {string} [parameters.etag] Gets a unique read-only string that - * changes whenever the resource is updated. + * @param {number} [vpnSiteParameters.bgpProperties.asn] The BGP speaker's ASN. * - * @param {string} [parameters.id] Resource ID. + * @param {string} [vpnSiteParameters.bgpProperties.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. * - * @param {string} [parameters.location] Resource location. + * @param {number} [vpnSiteParameters.bgpProperties.peerWeight] The weight + * added to routes learned from this BGP speaker. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} [vpnSiteParameters.provisioningState] The provisioning state + * of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [vpnSiteParameters.id] Resource ID. + * + * @param {string} [vpnSiteParameters.location] Resource location. + * + * @param {object} [vpnSiteParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @returns {Promise} A promise is returned * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * {Promise} A promise is returned. + * @reject {Error|ServiceError} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, vpnSiteName: string, vpnSiteParameters: models.VpnSite, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates a VpnSite resource if it doesn't exist else updates the existing + * VpnSite. * - * @resolve {VirtualNetworkGateway} - The deserialized result object. + * @param {string} resourceGroupName The resource group name of the VpnSite. * - * @reject {Error|ServiceError} - The error object. + * @param {string} vpnSiteName The name of the VpnSite being created or + * updated. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {object} vpnSiteParameters Parameters supplied to create or update + * VpnSite. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {object} [vpnSiteParameters.virtualWAN] The VirtualWAN to which the + * vpnSite belongs * - * {VirtualNetworkGateway} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGateway} for more information. + * @param {string} [vpnSiteParameters.virtualWAN.id] Resource ID. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {object} [vpnSiteParameters.deviceProperties] The device properties * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginCreateOrUpdate(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VirtualNetworkGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VirtualNetworkGateway, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VirtualNetworkGateway, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Deletes the specified virtual network gateway. + * @param {string} [vpnSiteParameters.deviceProperties.deviceVendor] Name of + * the device Vendor. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [vpnSiteParameters.deviceProperties.deviceModel] Model of + * the device. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {number} [vpnSiteParameters.deviceProperties.linkSpeedInMbps] Link + * speed. * - * @param {object} [options] Optional Parameters. + * @param {string} [vpnSiteParameters.ipAddress] The ip-address for the + * vpn-site. + * + * @param {string} [vpnSiteParameters.siteKey] The key for vpn-site that can be + * used for connections. + * + * @param {object} [vpnSiteParameters.addressSpace] The AddressSpace that + * contains an array of IP address ranges. + * + * @param {array} [vpnSiteParameters.addressSpace.addressPrefixes] A list of + * address blocks reserved for this virtual network in CIDR notation. + * + * @param {object} [vpnSiteParameters.bgpProperties] The set of bgp properties. + * + * @param {number} [vpnSiteParameters.bgpProperties.asn] The BGP speaker's ASN. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [vpnSiteParameters.bgpProperties.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. * - * @returns {Promise} A promise is returned + * @param {number} [vpnSiteParameters.bgpProperties.peerWeight] The weight + * added to routes learned from this BGP speaker. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} [vpnSiteParameters.provisioningState] The provisioning state + * of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' * - * @reject {Error|ServiceError} - The error object. - */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Deletes the specified virtual network gateway. + * @param {string} [vpnSiteParameters.id] Resource ID. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [vpnSiteParameters.location] Resource location. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {object} [vpnSiteParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -27413,7 +32497,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {VpnSite} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -27421,29 +32505,29 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {VpnSite} [result] - The deserialized result object if an error did not occur. + * See {@link VpnSite} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, vpnSiteName: string, vpnSiteParameters: models.VpnSite, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, vpnSiteName: string, vpnSiteParameters: models.VpnSite, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, vpnSiteName: string, vpnSiteParameters: models.VpnSite, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a virtual network gateway tags. + * Updates VpnSite tags. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnSite. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} vpnSiteName The name of the VpnSite being updated. * - * @param {object} parameters Parameters supplied to update virtual network - * gateway tags. + * @param {object} vpnSiteParameters Parameters supplied to update VpnSite + * tags. * - * @param {object} [parameters.tags] Resource tags. + * @param {object} [vpnSiteParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -27452,24 +32536,23 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateTagsWithHttpOperationResponse(resourceGroupName: string, vpnSiteName: string, vpnSiteParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a virtual network gateway tags. + * Updates VpnSite tags. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnSite. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} vpnSiteName The name of the VpnSite being updated. * - * @param {object} parameters Parameters supplied to update virtual network - * gateway tags. + * @param {object} vpnSiteParameters Parameters supplied to update VpnSite + * tags. * - * @param {object} [parameters.tags] Resource tags. + * @param {object} [vpnSiteParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -27483,7 +32566,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGateway} - The deserialized result object. + * @resolve {VpnSite} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -27491,57 +32574,47 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGateway} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGateway} for more information. + * {VpnSite} [result] - The deserialized result object if an error did not occur. + * See {@link VpnSite} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdateTags(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdateTags(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - beginUpdateTags(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, vpnSiteName: string, vpnSiteParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, vpnSiteName: string, vpnSiteParameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, vpnSiteName: string, vpnSiteParameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Resets the primary of the virtual network gateway in the specified resource - * group. + * Deletes a VpnSite. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnSite. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} vpnSiteName The name of the VpnSite being deleted. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.gatewayVip] Virtual network gateway vip address - * supplied to the begin reset of the active-active feature enabled gateway. - * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginResetWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { gatewayVip? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, vpnSiteName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Resets the primary of the virtual network gateway in the specified resource - * group. + * Deletes a VpnSite. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnSite. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} vpnSiteName The name of the VpnSite being deleted. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.gatewayVip] Virtual network gateway vip address - * supplied to the begin reset of the active-active feature enabled gateway. - * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -27552,7 +32625,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGateway} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -27560,46 +32633,21 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGateway} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGateway} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginReset(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { gatewayVip? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - beginReset(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; - beginReset(resourceGroupName: string, virtualNetworkGatewayName: string, options: { gatewayVip? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, vpnSiteName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, vpnSiteName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, vpnSiteName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Generates VPN client package for P2S client of the virtual network gateway - * in the specified resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. - * - * @param {object} parameters Parameters supplied to the generate virtual - * network gateway VPN client package operation. + * Lists all the vpnSites in a resource group. * - * @param {string} [parameters.processorArchitecture] VPN client Processor - * Architecture. Possible values are: 'AMD64' and 'X86'. Possible values - * include: 'Amd64', 'X86' - * - * @param {string} [parameters.authenticationMethod] VPN client Authentication - * Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values - * include: 'EAPTLS', 'EAPMSCHAPv2' - * - * @param {string} [parameters.radiusServerAuthCertificate] The public - * certificate data for the radius server authentication certificate as a - * Base-64 encoded string. Required only if external radius authentication has - * been configured with EAPTLS authentication. - * - * @param {array} [parameters.clientRootCertificates] A list of client root - * certificates public certificate data encoded as Base-64 strings. Optional - * parameter for external radius based authentication with EAPTLS. + * @param {string} resourceGroupName The resource group name of the VpnSite. * * @param {object} [options] Optional Parameters. * @@ -27608,40 +32656,16 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginGeneratevpnclientpackageWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByResourceGroupWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Generates VPN client package for P2S client of the virtual network gateway - * in the specified resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. - * - * @param {object} parameters Parameters supplied to the generate virtual - * network gateway VPN client package operation. - * - * @param {string} [parameters.processorArchitecture] VPN client Processor - * Architecture. Possible values are: 'AMD64' and 'X86'. Possible values - * include: 'Amd64', 'X86' + * Lists all the vpnSites in a resource group. * - * @param {string} [parameters.authenticationMethod] VPN client Authentication - * Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values - * include: 'EAPTLS', 'EAPMSCHAPv2' - * - * @param {string} [parameters.radiusServerAuthCertificate] The public - * certificate data for the radius server authentication certificate as a - * Base-64 encoded string. Required only if external radius authentication has - * been configured with EAPTLS authentication. - * - * @param {array} [parameters.clientRootCertificates] A list of client root - * certificates public certificate data encoded as Base-64 strings. Optional - * parameter for external radius based authentication with EAPTLS. + * @param {string} resourceGroupName The resource group name of the VpnSite. * * @param {object} [options] Optional Parameters. * @@ -27655,7 +32679,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {String} - The deserialized result object. + * @resolve {ListVpnSitesResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -27663,45 +32687,20 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {String} [result] - The deserialized result object if an error did not occur. + * {ListVpnSitesResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnSitesResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginGeneratevpnclientpackage(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginGeneratevpnclientpackage(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, callback: ServiceCallback): void; - beginGeneratevpnclientpackage(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByResourceGroup(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroup(resourceGroupName: string, callback: ServiceCallback): void; + listByResourceGroup(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Generates VPN profile for P2S client of the virtual network gateway in the - * specified resource group. Used for IKEV2 and radius based authentication. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. - * - * @param {object} parameters Parameters supplied to the generate virtual - * network gateway VPN client package operation. - * - * @param {string} [parameters.processorArchitecture] VPN client Processor - * Architecture. Possible values are: 'AMD64' and 'X86'. Possible values - * include: 'Amd64', 'X86' - * - * @param {string} [parameters.authenticationMethod] VPN client Authentication - * Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values - * include: 'EAPTLS', 'EAPMSCHAPv2' - * - * @param {string} [parameters.radiusServerAuthCertificate] The public - * certificate data for the radius server authentication certificate as a - * Base-64 encoded string. Required only if external radius authentication has - * been configured with EAPTLS authentication. - * - * @param {array} [parameters.clientRootCertificates] A list of client root - * certificates public certificate data encoded as Base-64 strings. Optional - * parameter for external radius based authentication with EAPTLS. + * Lists all the VpnSites in a subscription. * * @param {object} [options] Optional Parameters. * @@ -27710,40 +32709,14 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginGenerateVpnProfileWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Generates VPN profile for P2S client of the virtual network gateway in the - * specified resource group. Used for IKEV2 and radius based authentication. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. - * - * @param {object} parameters Parameters supplied to the generate virtual - * network gateway VPN client package operation. - * - * @param {string} [parameters.processorArchitecture] VPN client Processor - * Architecture. Possible values are: 'AMD64' and 'X86'. Possible values - * include: 'Amd64', 'X86' - * - * @param {string} [parameters.authenticationMethod] VPN client Authentication - * Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values - * include: 'EAPTLS', 'EAPMSCHAPv2' - * - * @param {string} [parameters.radiusServerAuthCertificate] The public - * certificate data for the radius server authentication certificate as a - * Base-64 encoded string. Required only if external radius authentication has - * been configured with EAPTLS authentication. - * - * @param {array} [parameters.clientRootCertificates] A list of client root - * certificates public certificate data encoded as Base-64 strings. Optional - * parameter for external radius based authentication with EAPTLS. + * Lists all the VpnSites in a subscription. * * @param {object} [options] Optional Parameters. * @@ -27757,7 +32730,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {String} - The deserialized result object. + * @resolve {ListVpnSitesResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -27765,26 +32738,77 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {String} [result] - The deserialized result object if an error did not occur. + * {ListVpnSitesResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnSitesResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginGenerateVpnProfile(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginGenerateVpnProfile(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, callback: ServiceCallback): void; - beginGenerateVpnProfile(resourceGroupName: string, virtualNetworkGatewayName: string, parameters: models.VpnClientParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(callback: ServiceCallback): void; + list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets pre-generated VPN profile for P2S client of the virtual network gateway - * in the specified resource group. The profile needs to be generated first - * using generateVpnProfile. + * Creates a VpnSite resource if it doesn't exist else updates the existing + * VpnSite. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnSite. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} vpnSiteName The name of the VpnSite being created or + * updated. + * + * @param {object} vpnSiteParameters Parameters supplied to create or update + * VpnSite. + * + * @param {object} [vpnSiteParameters.virtualWAN] The VirtualWAN to which the + * vpnSite belongs + * + * @param {string} [vpnSiteParameters.virtualWAN.id] Resource ID. + * + * @param {object} [vpnSiteParameters.deviceProperties] The device properties + * + * @param {string} [vpnSiteParameters.deviceProperties.deviceVendor] Name of + * the device Vendor. + * + * @param {string} [vpnSiteParameters.deviceProperties.deviceModel] Model of + * the device. + * + * @param {number} [vpnSiteParameters.deviceProperties.linkSpeedInMbps] Link + * speed. + * + * @param {string} [vpnSiteParameters.ipAddress] The ip-address for the + * vpn-site. + * + * @param {string} [vpnSiteParameters.siteKey] The key for vpn-site that can be + * used for connections. + * + * @param {object} [vpnSiteParameters.addressSpace] The AddressSpace that + * contains an array of IP address ranges. + * + * @param {array} [vpnSiteParameters.addressSpace.addressPrefixes] A list of + * address blocks reserved for this virtual network in CIDR notation. + * + * @param {object} [vpnSiteParameters.bgpProperties] The set of bgp properties. + * + * @param {number} [vpnSiteParameters.bgpProperties.asn] The BGP speaker's ASN. + * + * @param {string} [vpnSiteParameters.bgpProperties.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [vpnSiteParameters.bgpProperties.peerWeight] The weight + * added to routes learned from this BGP speaker. + * + * @param {string} [vpnSiteParameters.provisioningState] The provisioning state + * of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [vpnSiteParameters.id] Resource ID. + * + * @param {string} [vpnSiteParameters.location] Resource location. + * + * @param {object} [vpnSiteParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -27793,89 +32817,73 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginGetVpnProfilePackageUrlWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, vpnSiteName: string, vpnSiteParameters: models.VpnSite, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets pre-generated VPN profile for P2S client of the virtual network gateway - * in the specified resource group. The profile needs to be generated first - * using generateVpnProfile. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. - * - * @param {object} [options] Optional Parameters. + * Creates a VpnSite resource if it doesn't exist else updates the existing + * VpnSite. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {string} resourceGroupName The resource group name of the VpnSite. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {string} vpnSiteName The name of the VpnSite being created or + * updated. * - * {Promise} A promise is returned. + * @param {object} vpnSiteParameters Parameters supplied to create or update + * VpnSite. * - * @resolve {String} - The deserialized result object. + * @param {object} [vpnSiteParameters.virtualWAN] The VirtualWAN to which the + * vpnSite belongs * - * @reject {Error|ServiceError} - The error object. + * @param {string} [vpnSiteParameters.virtualWAN.id] Resource ID. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {object} [vpnSiteParameters.deviceProperties] The device properties * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {string} [vpnSiteParameters.deviceProperties.deviceVendor] Name of + * the device Vendor. * - * {String} [result] - The deserialized result object if an error did not occur. + * @param {string} [vpnSiteParameters.deviceProperties.deviceModel] Model of + * the device. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {number} [vpnSiteParameters.deviceProperties.linkSpeedInMbps] Link + * speed. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginGetVpnProfilePackageUrl(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginGetVpnProfilePackageUrl(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; - beginGetVpnProfilePackageUrl(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * The GetBgpPeerStatus operation retrieves the status of all BGP peers. + * @param {string} [vpnSiteParameters.ipAddress] The ip-address for the + * vpn-site. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [vpnSiteParameters.siteKey] The key for vpn-site that can be + * used for connections. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {object} [vpnSiteParameters.addressSpace] The AddressSpace that + * contains an array of IP address ranges. * - * @param {object} [options] Optional Parameters. + * @param {array} [vpnSiteParameters.addressSpace.addressPrefixes] A list of + * address blocks reserved for this virtual network in CIDR notation. * - * @param {string} [options.peer] The IP address of the peer to retrieve the - * status of. + * @param {object} [vpnSiteParameters.bgpProperties] The set of bgp properties. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {number} [vpnSiteParameters.bgpProperties.asn] The BGP speaker's ASN. * - * @returns {Promise} A promise is returned + * @param {string} [vpnSiteParameters.bgpProperties.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {number} [vpnSiteParameters.bgpProperties.peerWeight] The weight + * added to routes learned from this BGP speaker. * - * @reject {Error|ServiceError} - The error object. - */ - beginGetBgpPeerStatusWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { peer? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * The GetBgpPeerStatus operation retrieves the status of all BGP peers. + * @param {string} [vpnSiteParameters.provisioningState] The provisioning state + * of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} [vpnSiteParameters.id] Resource ID. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} [vpnSiteParameters.location] Resource location. * - * @param {object} [options] Optional Parameters. + * @param {object} [vpnSiteParameters.tags] Resource tags. * - * @param {string} [options.peer] The IP address of the peer to retrieve the - * status of. + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request @@ -27887,7 +32895,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {BgpPeerStatusListResult} - The deserialized result object. + * @resolve {VpnSite} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -27895,27 +32903,29 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {BgpPeerStatusListResult} [result] - The deserialized result object if an error did not occur. - * See {@link BgpPeerStatusListResult} for more - * information. + * {VpnSite} [result] - The deserialized result object if an error did not occur. + * See {@link VpnSite} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginGetBgpPeerStatus(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { peer? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - beginGetBgpPeerStatus(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; - beginGetBgpPeerStatus(resourceGroupName: string, virtualNetworkGatewayName: string, options: { peer? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, vpnSiteName: string, vpnSiteParameters: models.VpnSite, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, vpnSiteName: string, vpnSiteParameters: models.VpnSite, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, vpnSiteName: string, vpnSiteParameters: models.VpnSite, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * This operation retrieves a list of routes the virtual network gateway has - * learned, including routes learned from BGP peers. + * Updates VpnSite tags. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnSite. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} vpnSiteName The name of the VpnSite being updated. + * + * @param {object} vpnSiteParameters Parameters supplied to update VpnSite + * tags. + * + * @param {object} [vpnSiteParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -27924,20 +32934,23 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginGetLearnedRoutesWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, vpnSiteName: string, vpnSiteParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * This operation retrieves a list of routes the virtual network gateway has - * learned, including routes learned from BGP peers. + * Updates VpnSite tags. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnSite. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} vpnSiteName The name of the VpnSite being updated. + * + * @param {object} vpnSiteParameters Parameters supplied to update VpnSite + * tags. + * + * @param {object} [vpnSiteParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -27951,7 +32964,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {GatewayRouteListResult} - The deserialized result object. + * @resolve {VpnSite} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -27959,29 +32972,24 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {GatewayRouteListResult} [result] - The deserialized result object if an error did not occur. - * See {@link GatewayRouteListResult} for more - * information. + * {VpnSite} [result] - The deserialized result object if an error did not occur. + * See {@link VpnSite} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginGetLearnedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginGetLearnedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; - beginGetLearnedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, vpnSiteName: string, vpnSiteParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdateTags(resourceGroupName: string, vpnSiteName: string, vpnSiteParameters: models.TagsObject, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, vpnSiteName: string, vpnSiteParameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * This operation retrieves a list of routes the virtual network gateway is - * advertising to the specified peer. + * Deletes a VpnSite. * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} resourceGroupName The resource group name of the VpnSite. * - * @param {string} peer The IP address of the peer + * @param {string} vpnSiteName The name of the VpnSite being deleted. * * @param {object} [options] Optional Parameters. * @@ -27990,22 +32998,18 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginGetAdvertisedRoutesWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, peer: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, vpnSiteName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * This operation retrieves a list of routes the virtual network gateway is - * advertising to the specified peer. - * - * @param {string} resourceGroupName The name of the resource group. + * Deletes a VpnSite. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. + * @param {string} resourceGroupName The resource group name of the VpnSite. * - * @param {string} peer The IP address of the peer + * @param {string} vpnSiteName The name of the VpnSite being deleted. * * @param {object} [options] Optional Parameters. * @@ -28019,7 +33023,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {GatewayRouteListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -28027,64 +33031,22 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {GatewayRouteListResult} [result] - The deserialized result object if an error did not occur. - * See {@link GatewayRouteListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginGetAdvertisedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, peer: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginGetAdvertisedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, peer: string, callback: ServiceCallback): void; - beginGetAdvertisedRoutes(resourceGroupName: string, virtualNetworkGatewayName: string, peer: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, vpnSiteName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, vpnSiteName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, vpnSiteName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * The Set VpnclientIpsecParameters operation sets the vpnclient ipsec policy - * for P2S client of virtual network gateway in the specified resource group - * through Network resource provider. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. - * - * @param {object} vpnclientIpsecParams Parameters supplied to the Begin Set - * vpnclient ipsec parameters of Virtual Network Gateway P2S client operation - * through Network resource provider. - * - * @param {number} vpnclientIpsecParams.saLifeTimeSeconds The IPSec Security - * Association (also called Quick Mode or Phase 2 SA) lifetime in seconds for - * P2S client. - * - * @param {number} vpnclientIpsecParams.saDataSizeKilobytes The IPSec Security - * Association (also called Quick Mode or Phase 2 SA) payload size in KB for - * P2S client.. + * Lists all the vpnSites in a resource group. * - * @param {string} vpnclientIpsecParams.ipsecEncryption The IPSec encryption - * algorithm (IKE phase 1). Possible values include: 'None', 'DES', 'DES3', - * 'AES128', 'AES192', 'AES256', 'GCMAES128', 'GCMAES192', 'GCMAES256' - * - * @param {string} vpnclientIpsecParams.ipsecIntegrity The IPSec integrity - * algorithm (IKE phase 1). Possible values include: 'MD5', 'SHA1', 'SHA256', - * 'GCMAES128', 'GCMAES192', 'GCMAES256' - * - * @param {string} vpnclientIpsecParams.ikeEncryption The IKE encryption - * algorithm (IKE phase 2). Possible values include: 'DES', 'DES3', 'AES128', - * 'AES192', 'AES256', 'GCMAES256', 'GCMAES128' - * - * @param {string} vpnclientIpsecParams.ikeIntegrity The IKE integrity - * algorithm (IKE phase 2). Possible values include: 'MD5', 'SHA1', 'SHA256', - * 'SHA384', 'GCMAES256', 'GCMAES128' - * - * @param {string} vpnclientIpsecParams.dhGroup The DH Groups used in IKE Phase - * 1 for initial SA. Possible values include: 'None', 'DHGroup1', 'DHGroup2', - * 'DHGroup14', 'DHGroup2048', 'ECP256', 'ECP384', 'DHGroup24' - * - * @param {string} vpnclientIpsecParams.pfsGroup The Pfs Groups used in IKE - * Phase 2 for new child SA. Possible values include: 'None', 'PFS1', 'PFS2', - * 'PFS2048', 'ECP256', 'ECP384', 'PFS24', 'PFS14', 'PFSMM' + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -28093,57 +33055,17 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginSetVpnclientIpsecParametersWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, vpnclientIpsecParams: models.VpnClientIPsecParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByResourceGroupNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * The Set VpnclientIpsecParameters operation sets the vpnclient ipsec policy - * for P2S client of virtual network gateway in the specified resource group - * through Network resource provider. - * - * @param {string} resourceGroupName The name of the resource group. + * Lists all the vpnSites in a resource group. * - * @param {string} virtualNetworkGatewayName The name of the virtual network - * gateway. - * - * @param {object} vpnclientIpsecParams Parameters supplied to the Begin Set - * vpnclient ipsec parameters of Virtual Network Gateway P2S client operation - * through Network resource provider. - * - * @param {number} vpnclientIpsecParams.saLifeTimeSeconds The IPSec Security - * Association (also called Quick Mode or Phase 2 SA) lifetime in seconds for - * P2S client. - * - * @param {number} vpnclientIpsecParams.saDataSizeKilobytes The IPSec Security - * Association (also called Quick Mode or Phase 2 SA) payload size in KB for - * P2S client.. - * - * @param {string} vpnclientIpsecParams.ipsecEncryption The IPSec encryption - * algorithm (IKE phase 1). Possible values include: 'None', 'DES', 'DES3', - * 'AES128', 'AES192', 'AES256', 'GCMAES128', 'GCMAES192', 'GCMAES256' - * - * @param {string} vpnclientIpsecParams.ipsecIntegrity The IPSec integrity - * algorithm (IKE phase 1). Possible values include: 'MD5', 'SHA1', 'SHA256', - * 'GCMAES128', 'GCMAES192', 'GCMAES256' - * - * @param {string} vpnclientIpsecParams.ikeEncryption The IKE encryption - * algorithm (IKE phase 2). Possible values include: 'DES', 'DES3', 'AES128', - * 'AES192', 'AES256', 'GCMAES256', 'GCMAES128' - * - * @param {string} vpnclientIpsecParams.ikeIntegrity The IKE integrity - * algorithm (IKE phase 2). Possible values include: 'MD5', 'SHA1', 'SHA256', - * 'SHA384', 'GCMAES256', 'GCMAES128' - * - * @param {string} vpnclientIpsecParams.dhGroup The DH Groups used in IKE Phase - * 1 for initial SA. Possible values include: 'None', 'DHGroup1', 'DHGroup2', - * 'DHGroup14', 'DHGroup2048', 'ECP256', 'ECP384', 'DHGroup24' - * - * @param {string} vpnclientIpsecParams.pfsGroup The Pfs Groups used in IKE - * Phase 2 for new child SA. Possible values include: 'None', 'PFS1', 'PFS2', - * 'PFS2048', 'ECP256', 'ECP384', 'PFS24', 'PFS14', 'PFSMM' + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -28157,7 +33079,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {VpnClientIPsecParameters} - The deserialized result object. + * @resolve {ListVpnSitesResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -28165,27 +33087,23 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VpnClientIPsecParameters} [result] - The deserialized result object if an error did not occur. - * See {@link VpnClientIPsecParameters} for more - * information. + * {ListVpnSitesResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnSitesResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginSetVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, vpnclientIpsecParams: models.VpnClientIPsecParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginSetVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, vpnclientIpsecParams: models.VpnClientIPsecParameters, callback: ServiceCallback): void; - beginSetVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, vpnclientIpsecParams: models.VpnClientIPsecParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByResourceGroupNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroupNext(nextPageLink: string, callback: ServiceCallback): void; + listByResourceGroupNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * The Get VpnclientIpsecParameters operation retrieves information about the - * vpnclient ipsec policy for P2S client of virtual network gateway in the - * specified resource group through Network resource provider. - * - * @param {string} resourceGroupName The name of the resource group. + * Lists all the VpnSites in a subscription. * - * @param {string} virtualNetworkGatewayName The virtual network gateway name. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -28194,20 +33112,17 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginGetVpnclientIpsecParametersWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * The Get VpnclientIpsecParameters operation retrieves information about the - * vpnclient ipsec policy for P2S client of virtual network gateway in the - * specified resource group through Network resource provider. + * Lists all the VpnSites in a subscription. * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayName The virtual network gateway name. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -28221,7 +33136,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {VpnClientIPsecParameters} - The deserialized result object. + * @resolve {ListVpnSitesResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -28229,24 +33144,44 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VpnClientIPsecParameters} [result] - The deserialized result object if an error did not occur. - * See {@link VpnClientIPsecParameters} for more - * information. + * {ListVpnSitesResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnSitesResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginGetVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginGetVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, callback: ServiceCallback): void; - beginGetVpnclientIpsecParameters(resourceGroupName: string, virtualNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * VpnSitesConfiguration + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface VpnSitesConfiguration { /** - * Gets all virtual network gateways by resource group. + * Gives the sas-url to download the configurations for vpn-sites in a resource + * group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The resource group name. + * + * @param {string} virtualWANName The name of the VirtualWAN for which + * configuration of all vpn-sites is needed. + * + * @param {object} request Parameters supplied to download vpn-sites + * configuration. + * + * @param {array} [request.vpnSites] List of resource-ids of the vpn-sites for + * which config is to be downloaded. + * + * @param {string} [request.outputBlobSasUrl] The sas-url to download the + * configurations for vpn-sites * * @param {object} [options] Optional Parameters. * @@ -28255,17 +33190,29 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + downloadWithHttpOperationResponse(resourceGroupName: string, virtualWANName: string, request: models.GetVpnSitesConfigurationRequest, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all virtual network gateways by resource group. + * Gives the sas-url to download the configurations for vpn-sites in a resource + * group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The resource group name. + * + * @param {string} virtualWANName The name of the VirtualWAN for which + * configuration of all vpn-sites is needed. + * + * @param {object} request Parameters supplied to download vpn-sites + * configuration. + * + * @param {array} [request.vpnSites] List of resource-ids of the vpn-sites for + * which config is to be downloaded. + * + * @param {string} [request.outputBlobSasUrl] The sas-url to download the + * configurations for vpn-sites * * @param {object} [options] Optional Parameters. * @@ -28279,7 +33226,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGatewayListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -28287,24 +33234,34 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGatewayListResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGatewayListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + download(resourceGroupName: string, virtualWANName: string, request: models.GetVpnSitesConfigurationRequest, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + download(resourceGroupName: string, virtualWANName: string, request: models.GetVpnSitesConfigurationRequest, callback: ServiceCallback): void; + download(resourceGroupName: string, virtualWANName: string, request: models.GetVpnSitesConfigurationRequest, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the connections in a virtual network gateway. + * Gives the sas-url to download the configurations for vpn-sites in a resource + * group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The resource group name. + * + * @param {string} virtualWANName The name of the VirtualWAN for which + * configuration of all vpn-sites is needed. + * + * @param {object} request Parameters supplied to download vpn-sites + * configuration. + * + * @param {array} [request.vpnSites] List of resource-ids of the vpn-sites for + * which config is to be downloaded. + * + * @param {string} [request.outputBlobSasUrl] The sas-url to download the + * configurations for vpn-sites * * @param {object} [options] Optional Parameters. * @@ -28313,17 +33270,29 @@ export interface VirtualNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listConnectionsNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDownloadWithHttpOperationResponse(resourceGroupName: string, virtualWANName: string, request: models.GetVpnSitesConfigurationRequest, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the connections in a virtual network gateway. + * Gives the sas-url to download the configurations for vpn-sites in a resource + * group. + * + * @param {string} resourceGroupName The resource group name. + * + * @param {string} virtualWANName The name of the VirtualWAN for which + * configuration of all vpn-sites is needed. + * + * @param {object} request Parameters supplied to download vpn-sites + * configuration. + * + * @param {array} [request.vpnSites] List of resource-ids of the vpn-sites for + * which config is to be downloaded. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} [request.outputBlobSasUrl] The sas-url to download the + * configurations for vpn-sites * * @param {object} [options] Optional Parameters. * @@ -28337,7 +33306,7 @@ export interface VirtualNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGatewayListConnectionsResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -28345,398 +33314,343 @@ export interface VirtualNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGatewayListConnectionsResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGatewayListConnectionsResult} - * for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listConnectionsNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listConnectionsNext(nextPageLink: string, callback: ServiceCallback): void; - listConnectionsNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDownload(resourceGroupName: string, virtualWANName: string, request: models.GetVpnSitesConfigurationRequest, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDownload(resourceGroupName: string, virtualWANName: string, request: models.GetVpnSitesConfigurationRequest, callback: ServiceCallback): void; + beginDownload(resourceGroupName: string, virtualWANName: string, request: models.GetVpnSitesConfigurationRequest, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } /** * @class - * VirtualNetworkGatewayConnections + * VirtualHubs * __NOTE__: An instance of this class is automatically created for an * instance of the NetworkManagementClient. */ -export interface VirtualNetworkGatewayConnections { +export interface VirtualHubs { /** - * Creates or updates a virtual network gateway connection in the specified - * resource group. - * - * @param {string} resourceGroupName The name of the resource group. + * Retrieves the details of a VirtualHub. * - * @param {string} virtualNetworkGatewayConnectionName The name of the virtual - * network gateway connection. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {object} parameters Parameters supplied to the create or update - * virtual network gateway connection operation. + * @param {string} virtualHubName The name of the VirtualHub. * - * @param {string} [parameters.authorizationKey] The authorizationKey. + * @param {object} [options] Optional Parameters. * - * @param {object} parameters.virtualNetworkGateway1 The reference to virtual - * network gateway resource. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} [parameters.virtualNetworkGateway2] The reference to virtual - * network gateway resource. + * @returns {Promise} A promise is returned * - * @param {array} [parameters.virtualNetworkGateway2.ipConfigurations] IP - * configurations for virtual network gateway. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [parameters.virtualNetworkGateway2.gatewayType] The type of - * this virtual network gateway. Possible values are: 'Vpn' and 'ExpressRoute'. - * Possible values include: 'Vpn', 'ExpressRoute' + * @reject {Error|ServiceError} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName: string, virtualHubName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Retrieves the details of a VirtualHub. * - * @param {string} [parameters.virtualNetworkGateway2.vpnType] The type of this - * virtual network gateway. Possible values are: 'PolicyBased' and - * 'RouteBased'. Possible values include: 'PolicyBased', 'RouteBased' + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {boolean} [parameters.virtualNetworkGateway2.enableBgp] Whether BGP - * is enabled for this virtual network gateway or not. + * @param {string} virtualHubName The name of the VirtualHub. * - * @param {boolean} [parameters.virtualNetworkGateway2.activeActive] - * ActiveActive flag + * @param {object} [options] Optional Parameters. * - * @param {object} [parameters.virtualNetworkGateway2.gatewayDefaultSite] The - * reference of the LocalNetworkGateway resource which represents local network - * site having default routes. Assign Null value in case of removing existing - * default site setting. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} [parameters.virtualNetworkGateway2.sku] The reference of the - * VirtualNetworkGatewaySku resource which represents the SKU selected for - * Virtual network gateway. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} [parameters.virtualNetworkGateway2.sku.name] Gateway SKU - * name. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {string} [parameters.virtualNetworkGateway2.sku.tier] Gateway SKU - * tier. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * {Promise} A promise is returned. * - * @param {number} [parameters.virtualNetworkGateway2.sku.capacity] The - * capacity. + * @resolve {VirtualHub} - The deserialized result object. * - * @param {object} [parameters.virtualNetworkGateway2.vpnClientConfiguration] - * The reference of the VpnClientConfiguration resource which represents the - * P2S VpnClient configurations. + * @reject {Error|ServiceError} - The error object. * - * @param {object} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientAddressPool] - * The reference of the address space resource which represents Address space - * for P2S VpnClient. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {array} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientRootCertificates] - * VpnClientRootCertificate for virtual network gateway. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {array} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientRevokedCertificates] - * VpnClientRevokedCertificate for Virtual network gateway. + * {VirtualHub} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualHub} for more information. * - * @param {array} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientProtocols] - * VpnClientProtocols for Virtual network gateway. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {array} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientIpsecPolicies] - * VpnClientIpsecPolicies for virtual network gateway P2S client. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName: string, virtualHubName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, virtualHubName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, virtualHubName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Creates a VirtualHub resource if it doesn't exist else updates the existing + * VirtualHub. * - * @param {string} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.radiusServerAddress] - * The radius server address property of the VirtualNetworkGateway resource for - * vpn client connection. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {string} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.radiusServerSecret] - * The radius secret property of the VirtualNetworkGateway resource for vpn - * client connection. + * @param {string} virtualHubName The name of the VirtualHub. * - * @param {object} [parameters.virtualNetworkGateway2.bgpSettings] Virtual - * network gateway's BGP speaker settings. + * @param {object} virtualHubParameters Parameters supplied to create or update + * VirtualHub. * - * @param {string} [parameters.virtualNetworkGateway2.resourceGuid] The - * resource GUID property of the VirtualNetworkGateway resource. + * @param {object} [virtualHubParameters.virtualWan] The VirtualWAN to which + * the VirtualHub belongs * - * @param {string} [parameters.virtualNetworkGateway2.etag] Gets a unique - * read-only string that changes whenever the resource is updated. + * @param {string} [virtualHubParameters.virtualWan.id] Resource ID. * - * @param {string} [parameters.virtualNetworkGateway2.id] Resource ID. + * @param {array} [virtualHubParameters.hubVirtualNetworkConnections] list of + * all vnet connections with this VirtualHub. * - * @param {string} [parameters.virtualNetworkGateway2.location] Resource - * location. + * @param {string} [virtualHubParameters.addressPrefix] Address-prefix for this + * VirtualHub. * - * @param {object} [parameters.virtualNetworkGateway2.tags] Resource tags. + * @param {string} [virtualHubParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' * - * @param {object} [parameters.localNetworkGateway2] The reference to local - * network gateway resource. + * @param {string} [virtualHubParameters.id] Resource ID. * - * @param {object} [parameters.localNetworkGateway2.localNetworkAddressSpace] - * Local network site address space. + * @param {string} [virtualHubParameters.location] Resource location. * - * @param {array} - * [parameters.localNetworkGateway2.localNetworkAddressSpace.addressPrefixes] A - * list of address blocks reserved for this virtual network in CIDR notation. + * @param {object} [virtualHubParameters.tags] Resource tags. * - * @param {string} [parameters.localNetworkGateway2.gatewayIpAddress] IP - * address of local network gateway. + * @param {object} [options] Optional Parameters. * - * @param {object} [parameters.localNetworkGateway2.bgpSettings] Local network - * gateway's BGP speaker settings. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {number} [parameters.localNetworkGateway2.bgpSettings.asn] The BGP - * speaker's ASN. + * @returns {Promise} A promise is returned * - * @param {string} - * [parameters.localNetworkGateway2.bgpSettings.bgpPeeringAddress] The BGP - * peering address and BGP identifier of this BGP speaker. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {number} [parameters.localNetworkGateway2.bgpSettings.peerWeight] The - * weight added to routes learned from this BGP speaker. + * @reject {Error|ServiceError} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualHubName: string, virtualHubParameters: models.VirtualHub, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates a VirtualHub resource if it doesn't exist else updates the existing + * VirtualHub. * - * @param {string} [parameters.localNetworkGateway2.resourceGuid] The resource - * GUID property of the LocalNetworkGateway resource. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {string} [parameters.localNetworkGateway2.etag] A unique read-only - * string that changes whenever the resource is updated. + * @param {string} virtualHubName The name of the VirtualHub. * - * @param {string} [parameters.localNetworkGateway2.id] Resource ID. + * @param {object} virtualHubParameters Parameters supplied to create or update + * VirtualHub. * - * @param {string} [parameters.localNetworkGateway2.location] Resource - * location. + * @param {object} [virtualHubParameters.virtualWan] The VirtualWAN to which + * the VirtualHub belongs * - * @param {object} [parameters.localNetworkGateway2.tags] Resource tags. + * @param {string} [virtualHubParameters.virtualWan.id] Resource ID. * - * @param {string} parameters.connectionType Gateway connection type. Possible - * values are: 'Ipsec','Vnet2Vnet','ExpressRoute', and 'VPNClient. Possible - * values include: 'IPsec', 'Vnet2Vnet', 'ExpressRoute', 'VPNClient' + * @param {array} [virtualHubParameters.hubVirtualNetworkConnections] list of + * all vnet connections with this VirtualHub. * - * @param {number} [parameters.routingWeight] The routing weight. + * @param {string} [virtualHubParameters.addressPrefix] Address-prefix for this + * VirtualHub. * - * @param {string} [parameters.sharedKey] The IPSec shared key. + * @param {string} [virtualHubParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' * - * @param {object} [parameters.peer] The reference to peerings resource. + * @param {string} [virtualHubParameters.id] Resource ID. * - * @param {string} [parameters.peer.id] Resource ID. + * @param {string} [virtualHubParameters.location] Resource location. * - * @param {boolean} [parameters.enableBgp] EnableBgp flag + * @param {object} [virtualHubParameters.tags] Resource tags. * - * @param {boolean} [parameters.usePolicyBasedTrafficSelectors] Enable - * policy-based traffic selectors. + * @param {object} [options] Optional Parameters. * - * @param {array} [parameters.ipsecPolicies] The IPSec Policies to be - * considered by this connection. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * VirtualNetworkGatewayConnection resource. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} [parameters.etag] Gets a unique read-only string that - * changes whenever the resource is updated. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {string} [parameters.id] Resource ID. + * {Promise} A promise is returned. * - * @param {string} [parameters.location] Resource location. + * @resolve {VirtualHub} - The deserialized result object. * - * @param {object} [parameters.tags] Resource tags. + * @reject {Error|ServiceError} - The error object. * - * @param {object} [options] Optional Parameters. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @returns {Promise} A promise is returned + * {VirtualHub} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualHub} for more information. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @reject {Error|ServiceError} - The error object. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VirtualNetworkGatewayConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdate(resourceGroupName: string, virtualHubName: string, virtualHubParameters: models.VirtualHub, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, virtualHubName: string, virtualHubParameters: models.VirtualHub, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, virtualHubName: string, virtualHubParameters: models.VirtualHub, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + /** - * Creates or updates a virtual network gateway connection in the specified - * resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayConnectionName The name of the virtual - * network gateway connection. + * Updates VirtualHub tags. * - * @param {object} parameters Parameters supplied to the create or update - * virtual network gateway connection operation. - * - * @param {string} [parameters.authorizationKey] The authorizationKey. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {object} parameters.virtualNetworkGateway1 The reference to virtual - * network gateway resource. + * @param {string} virtualHubName The name of the VirtualHub. * - * @param {object} [parameters.virtualNetworkGateway2] The reference to virtual - * network gateway resource. + * @param {object} virtualHubParameters Parameters supplied to update + * VirtualHub tags. * - * @param {array} [parameters.virtualNetworkGateway2.ipConfigurations] IP - * configurations for virtual network gateway. + * @param {object} [virtualHubParameters.tags] Resource tags. * - * @param {string} [parameters.virtualNetworkGateway2.gatewayType] The type of - * this virtual network gateway. Possible values are: 'Vpn' and 'ExpressRoute'. - * Possible values include: 'Vpn', 'ExpressRoute' + * @param {object} [options] Optional Parameters. * - * @param {string} [parameters.virtualNetworkGateway2.vpnType] The type of this - * virtual network gateway. Possible values are: 'PolicyBased' and - * 'RouteBased'. Possible values include: 'PolicyBased', 'RouteBased' + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {boolean} [parameters.virtualNetworkGateway2.enableBgp] Whether BGP - * is enabled for this virtual network gateway or not. + * @returns {Promise} A promise is returned * - * @param {boolean} [parameters.virtualNetworkGateway2.activeActive] - * ActiveActive flag + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {object} [parameters.virtualNetworkGateway2.gatewayDefaultSite] The - * reference of the LocalNetworkGateway resource which represents local network - * site having default routes. Assign Null value in case of removing existing - * default site setting. + * @reject {Error|ServiceError} - The error object. + */ + updateTagsWithHttpOperationResponse(resourceGroupName: string, virtualHubName: string, virtualHubParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Updates VirtualHub tags. * - * @param {object} [parameters.virtualNetworkGateway2.sku] The reference of the - * VirtualNetworkGatewaySku resource which represents the SKU selected for - * Virtual network gateway. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {string} [parameters.virtualNetworkGateway2.sku.name] Gateway SKU - * name. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * @param {string} virtualHubName The name of the VirtualHub. * - * @param {string} [parameters.virtualNetworkGateway2.sku.tier] Gateway SKU - * tier. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * @param {object} virtualHubParameters Parameters supplied to update + * VirtualHub tags. * - * @param {number} [parameters.virtualNetworkGateway2.sku.capacity] The - * capacity. + * @param {object} [virtualHubParameters.tags] Resource tags. * - * @param {object} [parameters.virtualNetworkGateway2.vpnClientConfiguration] - * The reference of the VpnClientConfiguration resource which represents the - * P2S VpnClient configurations. + * @param {object} [options] Optional Parameters. * - * @param {object} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientAddressPool] - * The reference of the address space resource which represents Address space - * for P2S VpnClient. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {array} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientRootCertificates] - * VpnClientRootCertificate for virtual network gateway. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {array} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientRevokedCertificates] - * VpnClientRevokedCertificate for Virtual network gateway. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {array} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientProtocols] - * VpnClientProtocols for Virtual network gateway. + * {Promise} A promise is returned. * - * @param {array} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientIpsecPolicies] - * VpnClientIpsecPolicies for virtual network gateway P2S client. + * @resolve {VirtualHub} - The deserialized result object. * - * @param {string} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.radiusServerAddress] - * The radius server address property of the VirtualNetworkGateway resource for - * vpn client connection. + * @reject {Error|ServiceError} - The error object. * - * @param {string} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.radiusServerSecret] - * The radius secret property of the VirtualNetworkGateway resource for vpn - * client connection. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {object} [parameters.virtualNetworkGateway2.bgpSettings] Virtual - * network gateway's BGP speaker settings. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [parameters.virtualNetworkGateway2.resourceGuid] The - * resource GUID property of the VirtualNetworkGateway resource. + * {VirtualHub} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualHub} for more information. * - * @param {string} [parameters.virtualNetworkGateway2.etag] Gets a unique - * read-only string that changes whenever the resource is updated. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {string} [parameters.virtualNetworkGateway2.id] Resource ID. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + updateTags(resourceGroupName: string, virtualHubName: string, virtualHubParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, virtualHubName: string, virtualHubParameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, virtualHubName: string, virtualHubParameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes a VirtualHub. * - * @param {string} [parameters.virtualNetworkGateway2.location] Resource - * location. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {object} [parameters.virtualNetworkGateway2.tags] Resource tags. + * @param {string} virtualHubName The name of the VirtualHub. * - * @param {object} [parameters.localNetworkGateway2] The reference to local - * network gateway resource. + * @param {object} [options] Optional Parameters. * - * @param {object} [parameters.localNetworkGateway2.localNetworkAddressSpace] - * Local network site address space. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {array} - * [parameters.localNetworkGateway2.localNetworkAddressSpace.addressPrefixes] A - * list of address blocks reserved for this virtual network in CIDR notation. + * @returns {Promise} A promise is returned * - * @param {string} [parameters.localNetworkGateway2.gatewayIpAddress] IP - * address of local network gateway. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {object} [parameters.localNetworkGateway2.bgpSettings] Local network - * gateway's BGP speaker settings. + * @reject {Error|ServiceError} - The error object. + */ + deleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualHubName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes a VirtualHub. * - * @param {number} [parameters.localNetworkGateway2.bgpSettings.asn] The BGP - * speaker's ASN. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {string} - * [parameters.localNetworkGateway2.bgpSettings.bgpPeeringAddress] The BGP - * peering address and BGP identifier of this BGP speaker. + * @param {string} virtualHubName The name of the VirtualHub. * - * @param {number} [parameters.localNetworkGateway2.bgpSettings.peerWeight] The - * weight added to routes learned from this BGP speaker. + * @param {object} [options] Optional Parameters. * - * @param {string} [parameters.localNetworkGateway2.resourceGuid] The resource - * GUID property of the LocalNetworkGateway resource. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.localNetworkGateway2.etag] A unique read-only - * string that changes whenever the resource is updated. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} [parameters.localNetworkGateway2.id] Resource ID. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {string} [parameters.localNetworkGateway2.location] Resource - * location. + * {Promise} A promise is returned. * - * @param {object} [parameters.localNetworkGateway2.tags] Resource tags. + * @resolve {null} - The deserialized result object. * - * @param {string} parameters.connectionType Gateway connection type. Possible - * values are: 'Ipsec','Vnet2Vnet','ExpressRoute', and 'VPNClient. Possible - * values include: 'IPsec', 'Vnet2Vnet', 'ExpressRoute', 'VPNClient' + * @reject {Error|ServiceError} - The error object. * - * @param {number} [parameters.routingWeight] The routing weight. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} [parameters.sharedKey] The IPSec shared key. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {object} [parameters.peer] The reference to peerings resource. + * {null} [result] - The deserialized result object if an error did not occur. * - * @param {string} [parameters.peer.id] Resource ID. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {boolean} [parameters.enableBgp] EnableBgp flag + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + deleteMethod(resourceGroupName: string, virtualHubName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, virtualHubName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, virtualHubName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists all the VirtualHubs in a resource group. * - * @param {boolean} [parameters.usePolicyBasedTrafficSelectors] Enable - * policy-based traffic selectors. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {array} [parameters.ipsecPolicies] The IPSec Policies to be - * considered by this connection. + * @param {object} [options] Optional Parameters. * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * VirtualNetworkGatewayConnection resource. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.etag] Gets a unique read-only string that - * changes whenever the resource is updated. + * @returns {Promise} A promise is returned * - * @param {string} [parameters.id] Resource ID. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [parameters.location] Resource location. + * @reject {Error|ServiceError} - The error object. + */ + listByResourceGroupWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists all the VirtualHubs in a resource group. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * * @param {object} [options] Optional Parameters. * @@ -28750,7 +33664,7 @@ export interface VirtualNetworkGatewayConnections { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGatewayConnection} - The deserialized result object. + * @resolve {ListVirtualHubsResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -28758,26 +33672,20 @@ export interface VirtualNetworkGatewayConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGatewayConnection} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGatewayConnection} for more - * information. + * {ListVirtualHubsResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualHubsResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VirtualNetworkGatewayConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VirtualNetworkGatewayConnection, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VirtualNetworkGatewayConnection, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByResourceGroup(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroup(resourceGroupName: string, callback: ServiceCallback): void; + listByResourceGroup(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the specified virtual network gateway connection by resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayConnectionName The name of the virtual - * network gateway connection. + * Lists all the VirtualHubs in a subscription. * * @param {object} [options] Optional Parameters. * @@ -28786,19 +33694,14 @@ export interface VirtualNetworkGatewayConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified virtual network gateway connection by resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayConnectionName The name of the virtual - * network gateway connection. + * Lists all the VirtualHubs in a subscription. * * @param {object} [options] Optional Parameters. * @@ -28812,7 +33715,7 @@ export interface VirtualNetworkGatewayConnections { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGatewayConnection} - The deserialized result object. + * @resolve {ListVirtualHubsResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -28820,26 +33723,49 @@ export interface VirtualNetworkGatewayConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGatewayConnection} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGatewayConnection} for more - * information. + * {ListVirtualHubsResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualHubsResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(callback: ServiceCallback): void; + list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified virtual network Gateway connection. + * Creates a VirtualHub resource if it doesn't exist else updates the existing + * VirtualHub. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {string} virtualNetworkGatewayConnectionName The name of the virtual - * network gateway connection. + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} virtualHubParameters Parameters supplied to create or update + * VirtualHub. + * + * @param {object} [virtualHubParameters.virtualWan] The VirtualWAN to which + * the VirtualHub belongs + * + * @param {string} [virtualHubParameters.virtualWan.id] Resource ID. + * + * @param {array} [virtualHubParameters.hubVirtualNetworkConnections] list of + * all vnet connections with this VirtualHub. + * + * @param {string} [virtualHubParameters.addressPrefix] Address-prefix for this + * VirtualHub. + * + * @param {string} [virtualHubParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [virtualHubParameters.id] Resource ID. + * + * @param {string} [virtualHubParameters.location] Resource location. + * + * @param {object} [virtualHubParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -28848,19 +33774,43 @@ export interface VirtualNetworkGatewayConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualHubName: string, virtualHubParameters: models.VirtualHub, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified virtual network Gateway connection. + * Creates a VirtualHub resource if it doesn't exist else updates the existing + * VirtualHub. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {string} virtualNetworkGatewayConnectionName The name of the virtual - * network gateway connection. + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} virtualHubParameters Parameters supplied to create or update + * VirtualHub. + * + * @param {object} [virtualHubParameters.virtualWan] The VirtualWAN to which + * the VirtualHub belongs + * + * @param {string} [virtualHubParameters.virtualWan.id] Resource ID. + * + * @param {array} [virtualHubParameters.hubVirtualNetworkConnections] list of + * all vnet connections with this VirtualHub. + * + * @param {string} [virtualHubParameters.addressPrefix] Address-prefix for this + * VirtualHub. + * + * @param {string} [virtualHubParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [virtualHubParameters.id] Resource ID. + * + * @param {string} [virtualHubParameters.location] Resource location. + * + * @param {object} [virtualHubParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -28874,7 +33824,7 @@ export interface VirtualNetworkGatewayConnections { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {VirtualHub} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -28882,29 +33832,29 @@ export interface VirtualNetworkGatewayConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {VirtualHub} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualHub} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, virtualHubName: string, virtualHubParameters: models.VirtualHub, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, virtualHubName: string, virtualHubParameters: models.VirtualHub, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, virtualHubName: string, virtualHubParameters: models.VirtualHub, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a virtual network gateway connection tags. + * Updates VirtualHub tags. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {string} virtualNetworkGatewayConnectionName The name of the virtual - * network gateway connection. + * @param {string} virtualHubName The name of the VirtualHub. * - * @param {object} parameters Parameters supplied to update virtual network - * gateway connection tags. + * @param {object} virtualHubParameters Parameters supplied to update + * VirtualHub tags. * - * @param {object} [parameters.tags] Resource tags. + * @param {object} [virtualHubParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -28913,24 +33863,23 @@ export interface VirtualNetworkGatewayConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateTagsWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, virtualHubName: string, virtualHubParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a virtual network gateway connection tags. + * Updates VirtualHub tags. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {string} virtualNetworkGatewayConnectionName The name of the virtual - * network gateway connection. + * @param {string} virtualHubName The name of the VirtualHub. * - * @param {object} parameters Parameters supplied to update virtual network - * gateway connection tags. + * @param {object} virtualHubParameters Parameters supplied to update + * VirtualHub tags. * - * @param {object} [parameters.tags] Resource tags. + * @param {object} [virtualHubParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -28944,7 +33893,7 @@ export interface VirtualNetworkGatewayConnections { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGatewayConnectionListEntity} - The deserialized result object. + * @resolve {VirtualHub} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -28952,36 +33901,24 @@ export interface VirtualNetworkGatewayConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGatewayConnectionListEntity} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGatewayConnectionListEntity} - * for more information. + * {VirtualHub} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualHub} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - updateTags(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - updateTags(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - updateTags(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, virtualHubName: string, virtualHubParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdateTags(resourceGroupName: string, virtualHubName: string, virtualHubParameters: models.TagsObject, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, virtualHubName: string, virtualHubParameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * The Put VirtualNetworkGatewayConnectionSharedKey operation sets the virtual - * network gateway connection shared key for passed virtual network gateway - * connection in the specified resource group through Network resource - * provider. - * - * @param {string} resourceGroupName The name of the resource group. + * Deletes a VirtualHub. * - * @param {string} virtualNetworkGatewayConnectionName The virtual network - * gateway connection name. - * - * @param {object} parameters Parameters supplied to the Begin Set Virtual - * Network Gateway connection Shared key operation throughNetwork resource - * provider. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {string} parameters.value The virtual network connection shared key - * value. + * @param {string} virtualHubName The name of the VirtualHub. * * @param {object} [options] Optional Parameters. * @@ -28990,29 +33927,74 @@ export interface VirtualNetworkGatewayConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - setSharedKeyWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionSharedKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualHubName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * The Put VirtualNetworkGatewayConnectionSharedKey operation sets the virtual - * network gateway connection shared key for passed virtual network gateway - * connection in the specified resource group through Network resource - * provider. + * Deletes a VirtualHub. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {string} virtualNetworkGatewayConnectionName The virtual network - * gateway connection name. + * @param {string} virtualHubName The name of the VirtualHub. * - * @param {object} parameters Parameters supplied to the Begin Set Virtual - * Network Gateway connection Shared key operation throughNetwork resource - * provider. + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(resourceGroupName: string, virtualHubName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, virtualHubName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, virtualHubName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists all the VirtualHubs in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listByResourceGroupNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists all the VirtualHubs in a resource group. * - * @param {string} parameters.value The virtual network connection shared key - * value. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -29026,7 +34008,7 @@ export interface VirtualNetworkGatewayConnections { * * {Promise} A promise is returned. * - * @resolve {ConnectionSharedKey} - The deserialized result object. + * @resolve {ListVirtualHubsResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -29034,27 +34016,23 @@ export interface VirtualNetworkGatewayConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ConnectionSharedKey} [result] - The deserialized result object if an error did not occur. - * See {@link ConnectionSharedKey} for more information. + * {ListVirtualHubsResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualHubsResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - setSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionSharedKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - setSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionSharedKey, callback: ServiceCallback): void; - setSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionSharedKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByResourceGroupNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroupNext(nextPageLink: string, callback: ServiceCallback): void; + listByResourceGroupNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * The Get VirtualNetworkGatewayConnectionSharedKey operation retrieves - * information about the specified virtual network gateway connection shared - * key through Network resource provider. - * - * @param {string} resourceGroupName The name of the resource group. + * Lists all the VirtualHubs in a subscription. * - * @param {string} virtualNetworkGatewayConnectionName The virtual network - * gateway connection shared key name. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -29063,21 +34041,17 @@ export interface VirtualNetworkGatewayConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getSharedKeyWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * The Get VirtualNetworkGatewayConnectionSharedKey operation retrieves - * information about the specified virtual network gateway connection shared - * key through Network resource provider. - * - * @param {string} resourceGroupName The name of the resource group. + * Lists all the VirtualHubs in a subscription. * - * @param {string} virtualNetworkGatewayConnectionName The virtual network - * gateway connection shared key name. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -29091,7 +34065,7 @@ export interface VirtualNetworkGatewayConnections { * * {Promise} A promise is returned. * - * @resolve {ConnectionSharedKey} - The deserialized result object. + * @resolve {ListVirtualHubsResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -29099,23 +34073,35 @@ export interface VirtualNetworkGatewayConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ConnectionSharedKey} [result] - The deserialized result object if an error did not occur. - * See {@link ConnectionSharedKey} for more information. + * {ListVirtualHubsResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualHubsResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - getSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - getSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, callback: ServiceCallback): void; - getSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * HubVirtualNetworkConnections + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface HubVirtualNetworkConnections { /** - * The List VirtualNetworkGatewayConnections operation retrieves all the - * virtual network gateways connections created. + * Retrieves the details of a HubVirtualNetworkConnection. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {string} connectionName The name of the vpn connection. * * @param {object} [options] Optional Parameters. * @@ -29124,17 +34110,20 @@ export interface VirtualNetworkGatewayConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, virtualHubName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * The List VirtualNetworkGatewayConnections operation retrieves all the - * virtual network gateways connections created. + * Retrieves the details of a HubVirtualNetworkConnection. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {string} connectionName The name of the vpn connection. * * @param {object} [options] Optional Parameters. * @@ -29148,7 +34137,7 @@ export interface VirtualNetworkGatewayConnections { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGatewayConnectionListResult} - The deserialized result object. + * @resolve {HubVirtualNetworkConnection} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -29156,36 +34145,25 @@ export interface VirtualNetworkGatewayConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGatewayConnectionListResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGatewayConnectionListResult} - * for more information. + * {HubVirtualNetworkConnection} [result] - The deserialized result object if an error did not occur. + * See {@link HubVirtualNetworkConnection} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, virtualHubName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, virtualHubName: string, connectionName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, virtualHubName: string, connectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * The VirtualNetworkGatewayConnectionResetSharedKey operation resets the - * virtual network gateway connection shared key for passed virtual network - * gateway connection in the specified resource group through Network resource - * provider. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayConnectionName The virtual network - * gateway connection reset shared key Name. + * Retrieves the details of all HubVirtualNetworkConnections. * - * @param {object} parameters Parameters supplied to the begin reset virtual - * network gateway connection shared key operation through network resource - * provider. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {number} parameters.keyLength The virtual network connection reset - * shared key length, should between 1 and 128. + * @param {string} virtualHubName The name of the VirtualHub. * * @param {object} [options] Optional Parameters. * @@ -29194,29 +34172,18 @@ export interface VirtualNetworkGatewayConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - resetSharedKeyWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionResetSharedKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(resourceGroupName: string, virtualHubName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * The VirtualNetworkGatewayConnectionResetSharedKey operation resets the - * virtual network gateway connection shared key for passed virtual network - * gateway connection in the specified resource group through Network resource - * provider. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayConnectionName The virtual network - * gateway connection reset shared key Name. + * Retrieves the details of all HubVirtualNetworkConnections. * - * @param {object} parameters Parameters supplied to the begin reset virtual - * network gateway connection shared key operation through network resource - * provider. + * @param {string} resourceGroupName The resource group name of the VirtualHub. * - * @param {number} parameters.keyLength The virtual network connection reset - * shared key length, should between 1 and 128. + * @param {string} virtualHubName The name of the VirtualHub. * * @param {object} [options] Optional Parameters. * @@ -29230,7 +34197,7 @@ export interface VirtualNetworkGatewayConnections { * * {Promise} A promise is returned. * - * @resolve {ConnectionResetSharedKey} - The deserialized result object. + * @resolve {ListHubVirtualNetworkConnectionsResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -29238,197 +34205,194 @@ export interface VirtualNetworkGatewayConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ConnectionResetSharedKey} [result] - The deserialized result object if an error did not occur. - * See {@link ConnectionResetSharedKey} for more - * information. + * {ListHubVirtualNetworkConnectionsResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListHubVirtualNetworkConnectionsResult} for + * more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - resetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionResetSharedKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - resetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionResetSharedKey, callback: ServiceCallback): void; - resetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionResetSharedKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(resourceGroupName: string, virtualHubName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(resourceGroupName: string, virtualHubName: string, callback: ServiceCallback): void; + list(resourceGroupName: string, virtualHubName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a virtual network gateway connection in the specified - * resource group. + * Retrieves the details of all HubVirtualNetworkConnections. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {string} virtualNetworkGatewayConnectionName The name of the virtual - * network gateway connection. + * @param {object} [options] Optional Parameters. * - * @param {object} parameters Parameters supplied to the create or update - * virtual network gateway connection operation. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.authorizationKey] The authorizationKey. + * @returns {Promise} A promise is returned * - * @param {object} parameters.virtualNetworkGateway1 The reference to virtual - * network gateway resource. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {object} [parameters.virtualNetworkGateway2] The reference to virtual - * network gateway resource. + * @reject {Error|ServiceError} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Retrieves the details of all HubVirtualNetworkConnections. * - * @param {array} [parameters.virtualNetworkGateway2.ipConfigurations] IP - * configurations for virtual network gateway. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {string} [parameters.virtualNetworkGateway2.gatewayType] The type of - * this virtual network gateway. Possible values are: 'Vpn' and 'ExpressRoute'. - * Possible values include: 'Vpn', 'ExpressRoute' + * @param {object} [options] Optional Parameters. * - * @param {string} [parameters.virtualNetworkGateway2.vpnType] The type of this - * virtual network gateway. Possible values are: 'PolicyBased' and - * 'RouteBased'. Possible values include: 'PolicyBased', 'RouteBased' + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {boolean} [parameters.virtualNetworkGateway2.enableBgp] Whether BGP - * is enabled for this virtual network gateway or not. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {boolean} [parameters.virtualNetworkGateway2.activeActive] - * ActiveActive flag + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {object} [parameters.virtualNetworkGateway2.gatewayDefaultSite] The - * reference of the LocalNetworkGateway resource which represents local network - * site having default routes. Assign Null value in case of removing existing - * default site setting. + * {Promise} A promise is returned. * - * @param {object} [parameters.virtualNetworkGateway2.sku] The reference of the - * VirtualNetworkGatewaySku resource which represents the SKU selected for - * Virtual network gateway. + * @resolve {ListHubVirtualNetworkConnectionsResult} - The deserialized result object. * - * @param {string} [parameters.virtualNetworkGateway2.sku.name] Gateway SKU - * name. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * @reject {Error|ServiceError} - The error object. * - * @param {string} [parameters.virtualNetworkGateway2.sku.tier] Gateway SKU - * tier. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {number} [parameters.virtualNetworkGateway2.sku.capacity] The - * capacity. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {object} [parameters.virtualNetworkGateway2.vpnClientConfiguration] - * The reference of the VpnClientConfiguration resource which represents the - * P2S VpnClient configurations. + * {ListHubVirtualNetworkConnectionsResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListHubVirtualNetworkConnectionsResult} for + * more information. * - * @param {object} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientAddressPool] - * The reference of the address space resource which represents Address space - * for P2S VpnClient. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {array} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientRootCertificates] - * VpnClientRootCertificate for virtual network gateway. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * VpnGateways + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface VpnGateways { + + + /** + * Retrieves the details of a virtual wan vpn gateway. * - * @param {array} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientRevokedCertificates] - * VpnClientRevokedCertificate for Virtual network gateway. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {array} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientProtocols] - * VpnClientProtocols for Virtual network gateway. + * @param {string} gatewayName The name of the gateway. * - * @param {array} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientIpsecPolicies] - * VpnClientIpsecPolicies for virtual network gateway P2S client. + * @param {object} [options] Optional Parameters. * - * @param {string} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.radiusServerAddress] - * The radius server address property of the VirtualNetworkGateway resource for - * vpn client connection. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.radiusServerSecret] - * The radius secret property of the VirtualNetworkGateway resource for vpn - * client connection. + * @returns {Promise} A promise is returned * - * @param {object} [parameters.virtualNetworkGateway2.bgpSettings] Virtual - * network gateway's BGP speaker settings. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [parameters.virtualNetworkGateway2.resourceGuid] The - * resource GUID property of the VirtualNetworkGateway resource. + * @reject {Error|ServiceError} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName: string, gatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Retrieves the details of a virtual wan vpn gateway. * - * @param {string} [parameters.virtualNetworkGateway2.etag] Gets a unique - * read-only string that changes whenever the resource is updated. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {string} [parameters.virtualNetworkGateway2.id] Resource ID. + * @param {string} gatewayName The name of the gateway. * - * @param {string} [parameters.virtualNetworkGateway2.location] Resource - * location. + * @param {object} [options] Optional Parameters. * - * @param {object} [parameters.virtualNetworkGateway2.tags] Resource tags. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} [parameters.localNetworkGateway2] The reference to local - * network gateway resource. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {object} [parameters.localNetworkGateway2.localNetworkAddressSpace] - * Local network site address space. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {array} - * [parameters.localNetworkGateway2.localNetworkAddressSpace.addressPrefixes] A - * list of address blocks reserved for this virtual network in CIDR notation. + * {Promise} A promise is returned. * - * @param {string} [parameters.localNetworkGateway2.gatewayIpAddress] IP - * address of local network gateway. + * @resolve {VpnGateway} - The deserialized result object. * - * @param {object} [parameters.localNetworkGateway2.bgpSettings] Local network - * gateway's BGP speaker settings. + * @reject {Error|ServiceError} - The error object. * - * @param {number} [parameters.localNetworkGateway2.bgpSettings.asn] The BGP - * speaker's ASN. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} - * [parameters.localNetworkGateway2.bgpSettings.bgpPeeringAddress] The BGP - * peering address and BGP identifier of this BGP speaker. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {number} [parameters.localNetworkGateway2.bgpSettings.peerWeight] The - * weight added to routes learned from this BGP speaker. + * {VpnGateway} [result] - The deserialized result object if an error did not occur. + * See {@link VpnGateway} for more information. * - * @param {string} [parameters.localNetworkGateway2.resourceGuid] The resource - * GUID property of the LocalNetworkGateway resource. + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName: string, gatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, gatewayName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, gatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Creates a virtual wan vpn gateway if it doesn't exist else updates the + * existing gateway. * - * @param {string} [parameters.localNetworkGateway2.etag] A unique read-only - * string that changes whenever the resource is updated. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {string} [parameters.localNetworkGateway2.id] Resource ID. + * @param {string} gatewayName The name of the gateway. * - * @param {string} [parameters.localNetworkGateway2.location] Resource - * location. + * @param {object} vpnGatewayParameters Parameters supplied to create or Update + * a virtual wan vpn gateway. * - * @param {object} [parameters.localNetworkGateway2.tags] Resource tags. + * @param {object} [vpnGatewayParameters.virtualHub] The VirtualHub to which + * the gateway belongs * - * @param {string} parameters.connectionType Gateway connection type. Possible - * values are: 'Ipsec','Vnet2Vnet','ExpressRoute', and 'VPNClient. Possible - * values include: 'IPsec', 'Vnet2Vnet', 'ExpressRoute', 'VPNClient' + * @param {string} [vpnGatewayParameters.virtualHub.id] Resource ID. * - * @param {number} [parameters.routingWeight] The routing weight. + * @param {array} [vpnGatewayParameters.connections] list of all vpn + * connections to the gateway. * - * @param {string} [parameters.sharedKey] The IPSec shared key. + * @param {object} [vpnGatewayParameters.bgpSettings] Local network gateway's + * BGP speaker settings. * - * @param {object} [parameters.peer] The reference to peerings resource. + * @param {number} [vpnGatewayParameters.bgpSettings.asn] The BGP speaker's + * ASN. * - * @param {string} [parameters.peer.id] Resource ID. + * @param {string} [vpnGatewayParameters.bgpSettings.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. * - * @param {boolean} [parameters.enableBgp] EnableBgp flag + * @param {number} [vpnGatewayParameters.bgpSettings.peerWeight] The weight + * added to routes learned from this BGP speaker. * - * @param {boolean} [parameters.usePolicyBasedTrafficSelectors] Enable - * policy-based traffic selectors. + * @param {string} [vpnGatewayParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' * - * @param {array} [parameters.ipsecPolicies] The IPSec Policies to be - * considered by this connection. + * @param {object} [vpnGatewayParameters.policies] The policies applied to this + * vpn gateway. * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * VirtualNetworkGatewayConnection resource. + * @param {boolean} [vpnGatewayParameters.policies.allowBranchToBranchTraffic] + * True if branch to branch traffic is allowed. * - * @param {string} [parameters.etag] Gets a unique read-only string that - * changes whenever the resource is updated. + * @param {boolean} [vpnGatewayParameters.policies.allowVnetToVnetTraffic] True + * if Vnet to Vnet traffic is allowed. * - * @param {string} [parameters.id] Resource ID. + * @param {string} [vpnGatewayParameters.id] Resource ID. * - * @param {string} [parameters.location] Resource location. + * @param {string} [vpnGatewayParameters.location] Resource location. * - * @param {object} [parameters.tags] Resource tags. + * @param {object} [vpnGatewayParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -29437,190 +34401,189 @@ export interface VirtualNetworkGatewayConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VirtualNetworkGatewayConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, gatewayName: string, vpnGatewayParameters: models.VpnGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a virtual network gateway connection in the specified - * resource group. + * Creates a virtual wan vpn gateway if it doesn't exist else updates the + * existing gateway. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {string} virtualNetworkGatewayConnectionName The name of the virtual - * network gateway connection. + * @param {string} gatewayName The name of the gateway. * - * @param {object} parameters Parameters supplied to the create or update - * virtual network gateway connection operation. + * @param {object} vpnGatewayParameters Parameters supplied to create or Update + * a virtual wan vpn gateway. * - * @param {string} [parameters.authorizationKey] The authorizationKey. + * @param {object} [vpnGatewayParameters.virtualHub] The VirtualHub to which + * the gateway belongs * - * @param {object} parameters.virtualNetworkGateway1 The reference to virtual - * network gateway resource. + * @param {string} [vpnGatewayParameters.virtualHub.id] Resource ID. * - * @param {object} [parameters.virtualNetworkGateway2] The reference to virtual - * network gateway resource. + * @param {array} [vpnGatewayParameters.connections] list of all vpn + * connections to the gateway. * - * @param {array} [parameters.virtualNetworkGateway2.ipConfigurations] IP - * configurations for virtual network gateway. + * @param {object} [vpnGatewayParameters.bgpSettings] Local network gateway's + * BGP speaker settings. * - * @param {string} [parameters.virtualNetworkGateway2.gatewayType] The type of - * this virtual network gateway. Possible values are: 'Vpn' and 'ExpressRoute'. - * Possible values include: 'Vpn', 'ExpressRoute' + * @param {number} [vpnGatewayParameters.bgpSettings.asn] The BGP speaker's + * ASN. * - * @param {string} [parameters.virtualNetworkGateway2.vpnType] The type of this - * virtual network gateway. Possible values are: 'PolicyBased' and - * 'RouteBased'. Possible values include: 'PolicyBased', 'RouteBased' + * @param {string} [vpnGatewayParameters.bgpSettings.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. * - * @param {boolean} [parameters.virtualNetworkGateway2.enableBgp] Whether BGP - * is enabled for this virtual network gateway or not. + * @param {number} [vpnGatewayParameters.bgpSettings.peerWeight] The weight + * added to routes learned from this BGP speaker. * - * @param {boolean} [parameters.virtualNetworkGateway2.activeActive] - * ActiveActive flag + * @param {string} [vpnGatewayParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' * - * @param {object} [parameters.virtualNetworkGateway2.gatewayDefaultSite] The - * reference of the LocalNetworkGateway resource which represents local network - * site having default routes. Assign Null value in case of removing existing - * default site setting. + * @param {object} [vpnGatewayParameters.policies] The policies applied to this + * vpn gateway. * - * @param {object} [parameters.virtualNetworkGateway2.sku] The reference of the - * VirtualNetworkGatewaySku resource which represents the SKU selected for - * Virtual network gateway. + * @param {boolean} [vpnGatewayParameters.policies.allowBranchToBranchTraffic] + * True if branch to branch traffic is allowed. * - * @param {string} [parameters.virtualNetworkGateway2.sku.name] Gateway SKU - * name. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * @param {boolean} [vpnGatewayParameters.policies.allowVnetToVnetTraffic] True + * if Vnet to Vnet traffic is allowed. * - * @param {string} [parameters.virtualNetworkGateway2.sku.tier] Gateway SKU - * tier. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * @param {string} [vpnGatewayParameters.id] Resource ID. * - * @param {number} [parameters.virtualNetworkGateway2.sku.capacity] The - * capacity. + * @param {string} [vpnGatewayParameters.location] Resource location. * - * @param {object} [parameters.virtualNetworkGateway2.vpnClientConfiguration] - * The reference of the VpnClientConfiguration resource which represents the - * P2S VpnClient configurations. + * @param {object} [vpnGatewayParameters.tags] Resource tags. * - * @param {object} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientAddressPool] - * The reference of the address space resource which represents Address space - * for P2S VpnClient. + * @param {object} [options] Optional Parameters. * - * @param {array} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientRootCertificates] - * VpnClientRootCertificate for virtual network gateway. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {array} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientRevokedCertificates] - * VpnClientRevokedCertificate for Virtual network gateway. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {array} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientProtocols] - * VpnClientProtocols for Virtual network gateway. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {array} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.vpnClientIpsecPolicies] - * VpnClientIpsecPolicies for virtual network gateway P2S client. + * {Promise} A promise is returned. * - * @param {string} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.radiusServerAddress] - * The radius server address property of the VirtualNetworkGateway resource for - * vpn client connection. + * @resolve {VpnGateway} - The deserialized result object. * - * @param {string} - * [parameters.virtualNetworkGateway2.vpnClientConfiguration.radiusServerSecret] - * The radius secret property of the VirtualNetworkGateway resource for vpn - * client connection. + * @reject {Error|ServiceError} - The error object. * - * @param {object} [parameters.virtualNetworkGateway2.bgpSettings] Virtual - * network gateway's BGP speaker settings. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {string} [parameters.virtualNetworkGateway2.resourceGuid] The - * resource GUID property of the VirtualNetworkGateway resource. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [parameters.virtualNetworkGateway2.etag] Gets a unique - * read-only string that changes whenever the resource is updated. + * {VpnGateway} [result] - The deserialized result object if an error did not occur. + * See {@link VpnGateway} for more information. * - * @param {string} [parameters.virtualNetworkGateway2.id] Resource ID. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {string} [parameters.virtualNetworkGateway2.location] Resource - * location. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName: string, gatewayName: string, vpnGatewayParameters: models.VpnGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, gatewayName: string, vpnGatewayParameters: models.VpnGateway, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, gatewayName: string, vpnGatewayParameters: models.VpnGateway, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Updates virtual wan vpn gateway tags. * - * @param {object} [parameters.virtualNetworkGateway2.tags] Resource tags. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {object} [parameters.localNetworkGateway2] The reference to local - * network gateway resource. + * @param {string} gatewayName The name of the gateway. * - * @param {object} [parameters.localNetworkGateway2.localNetworkAddressSpace] - * Local network site address space. + * @param {object} vpnGatewayParameters Parameters supplied to update a virtual + * wan vpn gateway tags. * - * @param {array} - * [parameters.localNetworkGateway2.localNetworkAddressSpace.addressPrefixes] A - * list of address blocks reserved for this virtual network in CIDR notation. + * @param {object} [vpnGatewayParameters.tags] Resource tags. * - * @param {string} [parameters.localNetworkGateway2.gatewayIpAddress] IP - * address of local network gateway. + * @param {object} [options] Optional Parameters. * - * @param {object} [parameters.localNetworkGateway2.bgpSettings] Local network - * gateway's BGP speaker settings. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {number} [parameters.localNetworkGateway2.bgpSettings.asn] The BGP - * speaker's ASN. + * @returns {Promise} A promise is returned * - * @param {string} - * [parameters.localNetworkGateway2.bgpSettings.bgpPeeringAddress] The BGP - * peering address and BGP identifier of this BGP speaker. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {number} [parameters.localNetworkGateway2.bgpSettings.peerWeight] The - * weight added to routes learned from this BGP speaker. + * @reject {Error|ServiceError} - The error object. + */ + updateTagsWithHttpOperationResponse(resourceGroupName: string, gatewayName: string, vpnGatewayParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Updates virtual wan vpn gateway tags. * - * @param {string} [parameters.localNetworkGateway2.resourceGuid] The resource - * GUID property of the LocalNetworkGateway resource. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {string} [parameters.localNetworkGateway2.etag] A unique read-only - * string that changes whenever the resource is updated. + * @param {string} gatewayName The name of the gateway. * - * @param {string} [parameters.localNetworkGateway2.id] Resource ID. + * @param {object} vpnGatewayParameters Parameters supplied to update a virtual + * wan vpn gateway tags. * - * @param {string} [parameters.localNetworkGateway2.location] Resource - * location. + * @param {object} [vpnGatewayParameters.tags] Resource tags. * - * @param {object} [parameters.localNetworkGateway2.tags] Resource tags. + * @param {object} [options] Optional Parameters. * - * @param {string} parameters.connectionType Gateway connection type. Possible - * values are: 'Ipsec','Vnet2Vnet','ExpressRoute', and 'VPNClient. Possible - * values include: 'IPsec', 'Vnet2Vnet', 'ExpressRoute', 'VPNClient' + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {number} [parameters.routingWeight] The routing weight. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} [parameters.sharedKey] The IPSec shared key. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {object} [parameters.peer] The reference to peerings resource. + * {Promise} A promise is returned. * - * @param {string} [parameters.peer.id] Resource ID. + * @resolve {VpnGateway} - The deserialized result object. * - * @param {boolean} [parameters.enableBgp] EnableBgp flag + * @reject {Error|ServiceError} - The error object. * - * @param {boolean} [parameters.usePolicyBasedTrafficSelectors] Enable - * policy-based traffic selectors. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {array} [parameters.ipsecPolicies] The IPSec Policies to be - * considered by this connection. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * VirtualNetworkGatewayConnection resource. + * {VpnGateway} [result] - The deserialized result object if an error did not occur. + * See {@link VpnGateway} for more information. * - * @param {string} [parameters.etag] Gets a unique read-only string that - * changes whenever the resource is updated. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {string} [parameters.id] Resource ID. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + updateTags(resourceGroupName: string, gatewayName: string, vpnGatewayParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + updateTags(resourceGroupName: string, gatewayName: string, vpnGatewayParameters: models.TagsObject, callback: ServiceCallback): void; + updateTags(resourceGroupName: string, gatewayName: string, vpnGatewayParameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes a virtual wan vpn gateway. * - * @param {string} [parameters.location] Resource location. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} gatewayName The name of the gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + deleteMethodWithHttpOperationResponse(resourceGroupName: string, gatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes a virtual wan vpn gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. * * @param {object} [options] Optional Parameters. * @@ -29634,7 +34597,7 @@ export interface VirtualNetworkGatewayConnections { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGatewayConnection} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -29642,26 +34605,74 @@ export interface VirtualNetworkGatewayConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGatewayConnection} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGatewayConnection} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VirtualNetworkGatewayConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VirtualNetworkGatewayConnection, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.VirtualNetworkGatewayConnection, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, gatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, gatewayName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, gatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified virtual network Gateway connection. + * Lists all the VpnGateways in a resource group. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {string} virtualNetworkGatewayConnectionName The name of the virtual - * network gateway connection. + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listByResourceGroupWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists all the VpnGateways in a resource group. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {ListVpnGatewaysResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {ListVpnGatewaysResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnGatewaysResult} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listByResourceGroup(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroup(resourceGroupName: string, callback: ServiceCallback): void; + listByResourceGroup(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists all the VpnGateways in a subscription. * * @param {object} [options] Optional Parameters. * @@ -29670,19 +34681,14 @@ export interface VirtualNetworkGatewayConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified virtual network Gateway connection. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayConnectionName The name of the virtual - * network gateway connection. + * Lists all the VpnGateways in a subscription. * * @param {object} [options] Optional Parameters. * @@ -29696,7 +34702,7 @@ export interface VirtualNetworkGatewayConnections { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ListVpnGatewaysResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -29704,29 +34710,67 @@ export interface VirtualNetworkGatewayConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ListVpnGatewaysResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnGatewaysResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(callback: ServiceCallback): void; + list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a virtual network gateway connection tags. + * Creates a virtual wan vpn gateway if it doesn't exist else updates the + * existing gateway. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {string} virtualNetworkGatewayConnectionName The name of the virtual - * network gateway connection. + * @param {string} gatewayName The name of the gateway. * - * @param {object} parameters Parameters supplied to update virtual network - * gateway connection tags. + * @param {object} vpnGatewayParameters Parameters supplied to create or Update + * a virtual wan vpn gateway. * - * @param {object} [parameters.tags] Resource tags. + * @param {object} [vpnGatewayParameters.virtualHub] The VirtualHub to which + * the gateway belongs + * + * @param {string} [vpnGatewayParameters.virtualHub.id] Resource ID. + * + * @param {array} [vpnGatewayParameters.connections] list of all vpn + * connections to the gateway. + * + * @param {object} [vpnGatewayParameters.bgpSettings] Local network gateway's + * BGP speaker settings. + * + * @param {number} [vpnGatewayParameters.bgpSettings.asn] The BGP speaker's + * ASN. + * + * @param {string} [vpnGatewayParameters.bgpSettings.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [vpnGatewayParameters.bgpSettings.peerWeight] The weight + * added to routes learned from this BGP speaker. + * + * @param {string} [vpnGatewayParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {object} [vpnGatewayParameters.policies] The policies applied to this + * vpn gateway. + * + * @param {boolean} [vpnGatewayParameters.policies.allowBranchToBranchTraffic] + * True if branch to branch traffic is allowed. + * + * @param {boolean} [vpnGatewayParameters.policies.allowVnetToVnetTraffic] True + * if Vnet to Vnet traffic is allowed. + * + * @param {string} [vpnGatewayParameters.id] Resource ID. + * + * @param {string} [vpnGatewayParameters.location] Resource location. + * + * @param {object} [vpnGatewayParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -29735,24 +34779,61 @@ export interface VirtualNetworkGatewayConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, gatewayName: string, vpnGatewayParameters: models.VpnGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a virtual network gateway connection tags. + * Creates a virtual wan vpn gateway if it doesn't exist else updates the + * existing gateway. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {string} virtualNetworkGatewayConnectionName The name of the virtual - * network gateway connection. + * @param {string} gatewayName The name of the gateway. * - * @param {object} parameters Parameters supplied to update virtual network - * gateway connection tags. + * @param {object} vpnGatewayParameters Parameters supplied to create or Update + * a virtual wan vpn gateway. * - * @param {object} [parameters.tags] Resource tags. + * @param {object} [vpnGatewayParameters.virtualHub] The VirtualHub to which + * the gateway belongs + * + * @param {string} [vpnGatewayParameters.virtualHub.id] Resource ID. + * + * @param {array} [vpnGatewayParameters.connections] list of all vpn + * connections to the gateway. + * + * @param {object} [vpnGatewayParameters.bgpSettings] Local network gateway's + * BGP speaker settings. + * + * @param {number} [vpnGatewayParameters.bgpSettings.asn] The BGP speaker's + * ASN. + * + * @param {string} [vpnGatewayParameters.bgpSettings.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [vpnGatewayParameters.bgpSettings.peerWeight] The weight + * added to routes learned from this BGP speaker. + * + * @param {string} [vpnGatewayParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {object} [vpnGatewayParameters.policies] The policies applied to this + * vpn gateway. + * + * @param {boolean} [vpnGatewayParameters.policies.allowBranchToBranchTraffic] + * True if branch to branch traffic is allowed. + * + * @param {boolean} [vpnGatewayParameters.policies.allowVnetToVnetTraffic] True + * if Vnet to Vnet traffic is allowed. + * + * @param {string} [vpnGatewayParameters.id] Resource ID. + * + * @param {string} [vpnGatewayParameters.location] Resource location. + * + * @param {object} [vpnGatewayParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -29766,7 +34847,7 @@ export interface VirtualNetworkGatewayConnections { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGatewayConnectionListEntity} - The deserialized result object. + * @resolve {VpnGateway} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -29774,36 +34855,29 @@ export interface VirtualNetworkGatewayConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGatewayConnectionListEntity} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGatewayConnectionListEntity} - * for more information. + * {VpnGateway} [result] - The deserialized result object if an error did not occur. + * See {@link VpnGateway} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdateTags(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdateTags(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - beginUpdateTags(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, gatewayName: string, vpnGatewayParameters: models.VpnGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, gatewayName: string, vpnGatewayParameters: models.VpnGateway, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, gatewayName: string, vpnGatewayParameters: models.VpnGateway, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * The Put VirtualNetworkGatewayConnectionSharedKey operation sets the virtual - * network gateway connection shared key for passed virtual network gateway - * connection in the specified resource group through Network resource - * provider. + * Updates virtual wan vpn gateway tags. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {string} virtualNetworkGatewayConnectionName The virtual network - * gateway connection name. + * @param {string} gatewayName The name of the gateway. * - * @param {object} parameters Parameters supplied to the Begin Set Virtual - * Network Gateway connection Shared key operation throughNetwork resource - * provider. + * @param {object} vpnGatewayParameters Parameters supplied to update a virtual + * wan vpn gateway tags. * - * @param {string} parameters.value The virtual network connection shared key - * value. + * @param {object} [vpnGatewayParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -29812,29 +34886,23 @@ export interface VirtualNetworkGatewayConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginSetSharedKeyWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionSharedKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, gatewayName: string, vpnGatewayParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * The Put VirtualNetworkGatewayConnectionSharedKey operation sets the virtual - * network gateway connection shared key for passed virtual network gateway - * connection in the specified resource group through Network resource - * provider. + * Updates virtual wan vpn gateway tags. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {string} virtualNetworkGatewayConnectionName The virtual network - * gateway connection name. + * @param {string} gatewayName The name of the gateway. * - * @param {object} parameters Parameters supplied to the Begin Set Virtual - * Network Gateway connection Shared key operation throughNetwork resource - * provider. + * @param {object} vpnGatewayParameters Parameters supplied to update a virtual + * wan vpn gateway tags. * - * @param {string} parameters.value The virtual network connection shared key - * value. + * @param {object} [vpnGatewayParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -29848,7 +34916,7 @@ export interface VirtualNetworkGatewayConnections { * * {Promise} A promise is returned. * - * @resolve {ConnectionSharedKey} - The deserialized result object. + * @resolve {VpnGateway} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -29856,35 +34924,24 @@ export interface VirtualNetworkGatewayConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ConnectionSharedKey} [result] - The deserialized result object if an error did not occur. - * See {@link ConnectionSharedKey} for more information. + * {VpnGateway} [result] - The deserialized result object if an error did not occur. + * See {@link VpnGateway} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginSetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionSharedKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginSetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionSharedKey, callback: ServiceCallback): void; - beginSetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionSharedKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, gatewayName: string, vpnGatewayParameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdateTags(resourceGroupName: string, gatewayName: string, vpnGatewayParameters: models.TagsObject, callback: ServiceCallback): void; + beginUpdateTags(resourceGroupName: string, gatewayName: string, vpnGatewayParameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * The VirtualNetworkGatewayConnectionResetSharedKey operation resets the - * virtual network gateway connection shared key for passed virtual network - * gateway connection in the specified resource group through Network resource - * provider. + * Deletes a virtual wan vpn gateway. * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayConnectionName The virtual network - * gateway connection reset shared key Name. - * - * @param {object} parameters Parameters supplied to the begin reset virtual - * network gateway connection shared key operation through network resource - * provider. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {number} parameters.keyLength The virtual network connection reset - * shared key length, should between 1 and 128. + * @param {string} gatewayName The name of the gateway. * * @param {object} [options] Optional Parameters. * @@ -29893,29 +34950,18 @@ export interface VirtualNetworkGatewayConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginResetSharedKeyWithHttpOperationResponse(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionResetSharedKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, gatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * The VirtualNetworkGatewayConnectionResetSharedKey operation resets the - * virtual network gateway connection shared key for passed virtual network - * gateway connection in the specified resource group through Network resource - * provider. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} virtualNetworkGatewayConnectionName The virtual network - * gateway connection reset shared key Name. + * Deletes a virtual wan vpn gateway. * - * @param {object} parameters Parameters supplied to the begin reset virtual - * network gateway connection shared key operation through network resource - * provider. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {number} parameters.keyLength The virtual network connection reset - * shared key length, should between 1 and 128. + * @param {string} gatewayName The name of the gateway. * * @param {object} [options] Optional Parameters. * @@ -29929,7 +34975,7 @@ export interface VirtualNetworkGatewayConnections { * * {Promise} A promise is returned. * - * @resolve {ConnectionResetSharedKey} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -29937,22 +34983,19 @@ export interface VirtualNetworkGatewayConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ConnectionResetSharedKey} [result] - The deserialized result object if an error did not occur. - * See {@link ConnectionResetSharedKey} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginResetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionResetSharedKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginResetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionResetSharedKey, callback: ServiceCallback): void; - beginResetSharedKey(resourceGroupName: string, virtualNetworkGatewayConnectionName: string, parameters: models.ConnectionResetSharedKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, gatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, gatewayName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, gatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * The List VirtualNetworkGatewayConnections operation retrieves all the - * virtual network gateways connections created. + * Lists all the VpnGateways in a resource group. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -29964,15 +35007,14 @@ export interface VirtualNetworkGatewayConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByResourceGroupNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * The List VirtualNetworkGatewayConnections operation retrieves all the - * virtual network gateways connections created. + * Lists all the VpnGateways in a resource group. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -29989,7 +35031,7 @@ export interface VirtualNetworkGatewayConnections { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkGatewayConnectionListResult} - The deserialized result object. + * @resolve {ListVpnGatewaysResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -29997,70 +35039,23 @@ export interface VirtualNetworkGatewayConnections { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkGatewayConnectionListResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGatewayConnectionListResult} - * for more information. + * {ListVpnGatewaysResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnGatewaysResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * LocalNetworkGateways - * __NOTE__: An instance of this class is automatically created for an - * instance of the NetworkManagementClient. - */ -export interface LocalNetworkGateways { + listByResourceGroupNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroupNext(nextPageLink: string, callback: ServiceCallback): void; + listByResourceGroupNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a local network gateway in the specified resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} localNetworkGatewayName The name of the local network - * gateway. - * - * @param {object} parameters Parameters supplied to the create or update local - * network gateway operation. - * - * @param {object} [parameters.localNetworkAddressSpace] Local network site - * address space. - * - * @param {array} [parameters.localNetworkAddressSpace.addressPrefixes] A list - * of address blocks reserved for this virtual network in CIDR notation. - * - * @param {string} [parameters.gatewayIpAddress] IP address of local network - * gateway. - * - * @param {object} [parameters.bgpSettings] Local network gateway's BGP speaker - * settings. - * - * @param {number} [parameters.bgpSettings.asn] The BGP speaker's ASN. - * - * @param {string} [parameters.bgpSettings.bgpPeeringAddress] The BGP peering - * address and BGP identifier of this BGP speaker. - * - * @param {number} [parameters.bgpSettings.peerWeight] The weight added to - * routes learned from this BGP speaker. - * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * LocalNetworkGateway resource. - * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. - * - * @param {string} [parameters.id] Resource ID. - * - * @param {string} [parameters.location] Resource location. + * Lists all the VpnGateways in a subscription. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -30069,54 +35064,17 @@ export interface LocalNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.LocalNetworkGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a local network gateway in the specified resource group. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} localNetworkGatewayName The name of the local network - * gateway. - * - * @param {object} parameters Parameters supplied to the create or update local - * network gateway operation. - * - * @param {object} [parameters.localNetworkAddressSpace] Local network site - * address space. - * - * @param {array} [parameters.localNetworkAddressSpace.addressPrefixes] A list - * of address blocks reserved for this virtual network in CIDR notation. - * - * @param {string} [parameters.gatewayIpAddress] IP address of local network - * gateway. - * - * @param {object} [parameters.bgpSettings] Local network gateway's BGP speaker - * settings. - * - * @param {number} [parameters.bgpSettings.asn] The BGP speaker's ASN. - * - * @param {string} [parameters.bgpSettings.bgpPeeringAddress] The BGP peering - * address and BGP identifier of this BGP speaker. + * Lists all the VpnGateways in a subscription. * - * @param {number} [parameters.bgpSettings.peerWeight] The weight added to - * routes learned from this BGP speaker. - * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * LocalNetworkGateway resource. - * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. - * - * @param {string} [parameters.id] Resource ID. - * - * @param {string} [parameters.location] Resource location. - * - * @param {object} [parameters.tags] Resource tags. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -30130,7 +35088,7 @@ export interface LocalNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {LocalNetworkGateway} - The deserialized result object. + * @resolve {ListVpnGatewaysResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -30138,25 +35096,35 @@ export interface LocalNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LocalNetworkGateway} [result] - The deserialized result object if an error did not occur. - * See {@link LocalNetworkGateway} for more information. + * {ListVpnGatewaysResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnGatewaysResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.LocalNetworkGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.LocalNetworkGateway, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.LocalNetworkGateway, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * VpnConnections + * __NOTE__: An instance of this class is automatically created for an + * instance of the NetworkManagementClient. + */ +export interface VpnConnections { /** - * Gets the specified local network gateway in a resource group. + * Retrieves the details of a vpn connection. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. * - * @param {string} localNetworkGatewayName The name of the local network - * gateway. + * @param {string} connectionName The name of the vpn connection. * * @param {object} [options] Optional Parameters. * @@ -30165,19 +35133,20 @@ export interface LocalNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, localNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, gatewayName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the specified local network gateway in a resource group. + * Retrieves the details of a vpn connection. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {string} localNetworkGatewayName The name of the local network - * gateway. + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the vpn connection. * * @param {object} [options] Optional Parameters. * @@ -30191,7 +35160,7 @@ export interface LocalNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {LocalNetworkGateway} - The deserialized result object. + * @resolve {VpnConnection} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -30199,25 +35168,60 @@ export interface LocalNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LocalNetworkGateway} [result] - The deserialized result object if an error did not occur. - * See {@link LocalNetworkGateway} for more information. + * {VpnConnection} [result] - The deserialized result object if an error did not occur. + * See {@link VpnConnection} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, localNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, localNetworkGatewayName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, localNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, gatewayName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, gatewayName: string, connectionName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, gatewayName: string, connectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified local network gateway. + * Creates a vpn connection to a scalable vpn gateway if it doesn't exist else + * updates the existing connection. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {string} localNetworkGatewayName The name of the local network - * gateway. + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the connection. + * + * @param {object} vpnConnectionParameters Parameters supplied to create or + * Update a VPN Connection. + * + * @param {object} [vpnConnectionParameters.remoteVpnSite] Id of the connected + * vpn site. + * + * @param {string} [vpnConnectionParameters.remoteVpnSite.id] Resource ID. + * + * @param {number} [vpnConnectionParameters.routingWeight] routing weight for + * vpn connection. + * + * @param {string} [vpnConnectionParameters.connectionStatus] The connection + * status. Possible values include: 'Unknown', 'Connecting', 'Connected', + * 'NotConnected' + * + * @param {string} [vpnConnectionParameters.sharedKey] SharedKey for the vpn + * connection. + * + * @param {boolean} [vpnConnectionParameters.enableBgp] EnableBgp flag + * + * @param {array} [vpnConnectionParameters.ipsecPolicies] The IPSec Policies to + * be considered by this connection. + * + * @param {string} [vpnConnectionParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [vpnConnectionParameters.id] Resource ID. + * + * @param {string} [vpnConnectionParameters.location] Resource location. + * + * @param {object} [vpnConnectionParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -30226,19 +35230,54 @@ export interface LocalNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, localNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, gatewayName: string, connectionName: string, vpnConnectionParameters: models.VpnConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified local network gateway. + * Creates a vpn connection to a scalable vpn gateway if it doesn't exist else + * updates the existing connection. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {string} localNetworkGatewayName The name of the local network - * gateway. + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the connection. + * + * @param {object} vpnConnectionParameters Parameters supplied to create or + * Update a VPN Connection. + * + * @param {object} [vpnConnectionParameters.remoteVpnSite] Id of the connected + * vpn site. + * + * @param {string} [vpnConnectionParameters.remoteVpnSite.id] Resource ID. + * + * @param {number} [vpnConnectionParameters.routingWeight] routing weight for + * vpn connection. + * + * @param {string} [vpnConnectionParameters.connectionStatus] The connection + * status. Possible values include: 'Unknown', 'Connecting', 'Connected', + * 'NotConnected' + * + * @param {string} [vpnConnectionParameters.sharedKey] SharedKey for the vpn + * connection. + * + * @param {boolean} [vpnConnectionParameters.enableBgp] EnableBgp flag + * + * @param {array} [vpnConnectionParameters.ipsecPolicies] The IPSec Policies to + * be considered by this connection. + * + * @param {string} [vpnConnectionParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [vpnConnectionParameters.id] Resource ID. + * + * @param {string} [vpnConnectionParameters.location] Resource location. + * + * @param {object} [vpnConnectionParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -30252,7 +35291,7 @@ export interface LocalNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {VpnConnection} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -30260,29 +35299,26 @@ export interface LocalNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {VpnConnection} [result] - The deserialized result object if an error did not occur. + * See {@link VpnConnection} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, localNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, localNetworkGatewayName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, localNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, gatewayName: string, connectionName: string, vpnConnectionParameters: models.VpnConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, gatewayName: string, connectionName: string, vpnConnectionParameters: models.VpnConnection, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, gatewayName: string, connectionName: string, vpnConnectionParameters: models.VpnConnection, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a local network gateway tags. - * - * @param {string} resourceGroupName The name of the resource group. + * Deletes a vpn connection. * - * @param {string} localNetworkGatewayName The name of the local network - * gateway. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {object} parameters Parameters supplied to update local network - * gateway tags. + * @param {string} gatewayName The name of the gateway. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} connectionName The name of the connection. * * @param {object} [options] Optional Parameters. * @@ -30291,24 +35327,20 @@ export interface LocalNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateTagsWithHttpOperationResponse(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, gatewayName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a local network gateway tags. - * - * @param {string} resourceGroupName The name of the resource group. + * Deletes a vpn connection. * - * @param {string} localNetworkGatewayName The name of the local network - * gateway. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {object} parameters Parameters supplied to update local network - * gateway tags. + * @param {string} gatewayName The name of the gateway. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} connectionName The name of the connection. * * @param {object} [options] Optional Parameters. * @@ -30322,7 +35354,7 @@ export interface LocalNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {LocalNetworkGateway} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -30330,22 +35362,23 @@ export interface LocalNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LocalNetworkGateway} [result] - The deserialized result object if an error did not occur. - * See {@link LocalNetworkGateway} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - updateTags(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - updateTags(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - updateTags(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, gatewayName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, gatewayName: string, connectionName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, gatewayName: string, connectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the local network gateways in a resource group. + * Retrieves all vpn connections for a particular virtual wan vpn gateway. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. * * @param {object} [options] Optional Parameters. * @@ -30354,16 +35387,18 @@ export interface LocalNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByVpnGatewayWithHttpOperationResponse(resourceGroupName: string, gatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the local network gateways in a resource group. + * Retrieves all vpn connections for a particular virtual wan vpn gateway. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. * * @param {object} [options] Optional Parameters. * @@ -30377,7 +35412,7 @@ export interface LocalNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {LocalNetworkGatewayListResult} - The deserialized result object. + * @resolve {ListVpnConnectionsResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -30385,61 +35420,61 @@ export interface LocalNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LocalNetworkGatewayListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LocalNetworkGatewayListResult} for more + * {ListVpnConnectionsResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnConnectionsResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(resourceGroupName: string, callback: ServiceCallback): void; - list(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByVpnGateway(resourceGroupName: string, gatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByVpnGateway(resourceGroupName: string, gatewayName: string, callback: ServiceCallback): void; + listByVpnGateway(resourceGroupName: string, gatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a local network gateway in the specified resource group. + * Creates a vpn connection to a scalable vpn gateway if it doesn't exist else + * updates the existing connection. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {string} localNetworkGatewayName The name of the local network - * gateway. + * @param {string} gatewayName The name of the gateway. * - * @param {object} parameters Parameters supplied to the create or update local - * network gateway operation. + * @param {string} connectionName The name of the connection. * - * @param {object} [parameters.localNetworkAddressSpace] Local network site - * address space. + * @param {object} vpnConnectionParameters Parameters supplied to create or + * Update a VPN Connection. * - * @param {array} [parameters.localNetworkAddressSpace.addressPrefixes] A list - * of address blocks reserved for this virtual network in CIDR notation. + * @param {object} [vpnConnectionParameters.remoteVpnSite] Id of the connected + * vpn site. * - * @param {string} [parameters.gatewayIpAddress] IP address of local network - * gateway. + * @param {string} [vpnConnectionParameters.remoteVpnSite.id] Resource ID. * - * @param {object} [parameters.bgpSettings] Local network gateway's BGP speaker - * settings. + * @param {number} [vpnConnectionParameters.routingWeight] routing weight for + * vpn connection. * - * @param {number} [parameters.bgpSettings.asn] The BGP speaker's ASN. + * @param {string} [vpnConnectionParameters.connectionStatus] The connection + * status. Possible values include: 'Unknown', 'Connecting', 'Connected', + * 'NotConnected' * - * @param {string} [parameters.bgpSettings.bgpPeeringAddress] The BGP peering - * address and BGP identifier of this BGP speaker. + * @param {string} [vpnConnectionParameters.sharedKey] SharedKey for the vpn + * connection. * - * @param {number} [parameters.bgpSettings.peerWeight] The weight added to - * routes learned from this BGP speaker. + * @param {boolean} [vpnConnectionParameters.enableBgp] EnableBgp flag * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * LocalNetworkGateway resource. + * @param {array} [vpnConnectionParameters.ipsecPolicies] The IPSec Policies to + * be considered by this connection. * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. + * @param {string} [vpnConnectionParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' * - * @param {string} [parameters.id] Resource ID. + * @param {string} [vpnConnectionParameters.id] Resource ID. * - * @param {string} [parameters.location] Resource location. + * @param {string} [vpnConnectionParameters.location] Resource location. * - * @param {object} [parameters.tags] Resource tags. + * @param {object} [vpnConnectionParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -30448,54 +35483,54 @@ export interface LocalNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.LocalNetworkGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, gatewayName: string, connectionName: string, vpnConnectionParameters: models.VpnConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a local network gateway in the specified resource group. + * Creates a vpn connection to a scalable vpn gateway if it doesn't exist else + * updates the existing connection. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {string} localNetworkGatewayName The name of the local network - * gateway. + * @param {string} gatewayName The name of the gateway. * - * @param {object} parameters Parameters supplied to the create or update local - * network gateway operation. + * @param {string} connectionName The name of the connection. * - * @param {object} [parameters.localNetworkAddressSpace] Local network site - * address space. + * @param {object} vpnConnectionParameters Parameters supplied to create or + * Update a VPN Connection. * - * @param {array} [parameters.localNetworkAddressSpace.addressPrefixes] A list - * of address blocks reserved for this virtual network in CIDR notation. + * @param {object} [vpnConnectionParameters.remoteVpnSite] Id of the connected + * vpn site. * - * @param {string} [parameters.gatewayIpAddress] IP address of local network - * gateway. + * @param {string} [vpnConnectionParameters.remoteVpnSite.id] Resource ID. * - * @param {object} [parameters.bgpSettings] Local network gateway's BGP speaker - * settings. + * @param {number} [vpnConnectionParameters.routingWeight] routing weight for + * vpn connection. * - * @param {number} [parameters.bgpSettings.asn] The BGP speaker's ASN. + * @param {string} [vpnConnectionParameters.connectionStatus] The connection + * status. Possible values include: 'Unknown', 'Connecting', 'Connected', + * 'NotConnected' * - * @param {string} [parameters.bgpSettings.bgpPeeringAddress] The BGP peering - * address and BGP identifier of this BGP speaker. + * @param {string} [vpnConnectionParameters.sharedKey] SharedKey for the vpn + * connection. * - * @param {number} [parameters.bgpSettings.peerWeight] The weight added to - * routes learned from this BGP speaker. + * @param {boolean} [vpnConnectionParameters.enableBgp] EnableBgp flag * - * @param {string} [parameters.resourceGuid] The resource GUID property of the - * LocalNetworkGateway resource. + * @param {array} [vpnConnectionParameters.ipsecPolicies] The IPSec Policies to + * be considered by this connection. * - * @param {string} [parameters.etag] A unique read-only string that changes - * whenever the resource is updated. + * @param {string} [vpnConnectionParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' * - * @param {string} [parameters.id] Resource ID. + * @param {string} [vpnConnectionParameters.id] Resource ID. * - * @param {string} [parameters.location] Resource location. + * @param {string} [vpnConnectionParameters.location] Resource location. * - * @param {object} [parameters.tags] Resource tags. + * @param {object} [vpnConnectionParameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -30509,7 +35544,7 @@ export interface LocalNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {LocalNetworkGateway} - The deserialized result object. + * @resolve {VpnConnection} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -30517,25 +35552,26 @@ export interface LocalNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LocalNetworkGateway} [result] - The deserialized result object if an error did not occur. - * See {@link LocalNetworkGateway} for more information. + * {VpnConnection} [result] - The deserialized result object if an error did not occur. + * See {@link VpnConnection} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.LocalNetworkGateway, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.LocalNetworkGateway, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.LocalNetworkGateway, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, gatewayName: string, connectionName: string, vpnConnectionParameters: models.VpnConnection, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, gatewayName: string, connectionName: string, vpnConnectionParameters: models.VpnConnection, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, gatewayName: string, connectionName: string, vpnConnectionParameters: models.VpnConnection, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the specified local network gateway. + * Deletes a vpn connection. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {string} localNetworkGatewayName The name of the local network - * gateway. + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the connection. * * @param {object} [options] Optional Parameters. * @@ -30548,15 +35584,16 @@ export interface LocalNetworkGateways { * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, localNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, gatewayName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the specified local network gateway. + * Deletes a vpn connection. * - * @param {string} resourceGroupName The name of the resource group. + * @param {string} resourceGroupName The resource group name of the VpnGateway. * - * @param {string} localNetworkGatewayName The name of the local network - * gateway. + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the connection. * * @param {object} [options] Optional Parameters. * @@ -30584,84 +35621,13 @@ export interface LocalNetworkGateways { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, localNetworkGatewayName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, localNetworkGatewayName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, localNetworkGatewayName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Updates a local network gateway tags. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} localNetworkGatewayName The name of the local network - * gateway. - * - * @param {object} parameters Parameters supplied to update local network - * gateway tags. - * - * @param {object} [parameters.tags] Resource tags. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - beginUpdateTagsWithHttpOperationResponse(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Updates a local network gateway tags. - * - * @param {string} resourceGroupName The name of the resource group. - * - * @param {string} localNetworkGatewayName The name of the local network - * gateway. - * - * @param {object} parameters Parameters supplied to update local network - * gateway tags. - * - * @param {object} [parameters.tags] Resource tags. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {LocalNetworkGateway} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {LocalNetworkGateway} [result] - The deserialized result object if an error did not occur. - * See {@link LocalNetworkGateway} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginUpdateTags(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.TagsObject, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdateTags(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.TagsObject, callback: ServiceCallback): void; - beginUpdateTags(resourceGroupName: string, localNetworkGatewayName: string, parameters: models.TagsObject, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, gatewayName: string, connectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, gatewayName: string, connectionName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, gatewayName: string, connectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all the local network gateways in a resource group. + * Retrieves all vpn connections for a particular virtual wan vpn gateway. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -30673,14 +35639,14 @@ export interface LocalNetworkGateways { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByVpnGatewayNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all the local network gateways in a resource group. + * Retrieves all vpn connections for a particular virtual wan vpn gateway. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -30697,7 +35663,7 @@ export interface LocalNetworkGateways { * * {Promise} A promise is returned. * - * @resolve {LocalNetworkGatewayListResult} - The deserialized result object. + * @resolve {ListVpnConnectionsResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -30705,15 +35671,15 @@ export interface LocalNetworkGateways { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LocalNetworkGatewayListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LocalNetworkGatewayListResult} for more + * {ListVpnConnectionsResult} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnConnectionsResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByVpnGatewayNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByVpnGatewayNext(nextPageLink: string, callback: ServiceCallback): void; + listByVpnGatewayNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } diff --git a/lib/services/networkManagement2/lib/operations/index.js b/lib/services/networkManagement2/lib/operations/index.js index b71044c90d..65816959b8 100644 --- a/lib/services/networkManagement2/lib/operations/index.js +++ b/lib/services/networkManagement2/lib/operations/index.js @@ -14,6 +14,7 @@ 'use strict'; +exports.AzureFirewalls = require('./azureFirewalls'); exports.ApplicationGateways = require('./applicationGateways'); exports.ApplicationSecurityGroups = require('./applicationSecurityGroups'); exports.DdosProtectionPlans = require('./ddosProtectionPlans'); @@ -55,3 +56,10 @@ exports.VirtualNetworkPeerings = require('./virtualNetworkPeerings'); exports.VirtualNetworkGateways = require('./virtualNetworkGateways'); exports.VirtualNetworkGatewayConnections = require('./virtualNetworkGatewayConnections'); exports.LocalNetworkGateways = require('./localNetworkGateways'); +exports.VirtualWANs = require('./virtualWANs'); +exports.VpnSites = require('./vpnSites'); +exports.VpnSitesConfiguration = require('./vpnSitesConfiguration'); +exports.VirtualHubs = require('./virtualHubs'); +exports.HubVirtualNetworkConnections = require('./hubVirtualNetworkConnections'); +exports.VpnGateways = require('./vpnGateways'); +exports.VpnConnections = require('./vpnConnections'); diff --git a/lib/services/networkManagement2/lib/operations/loadBalancerBackendAddressPools.js b/lib/services/networkManagement2/lib/operations/loadBalancerBackendAddressPools.js index 48c39799aa..119685121e 100644 --- a/lib/services/networkManagement2/lib/operations/loadBalancerBackendAddressPools.js +++ b/lib/services/networkManagement2/lib/operations/loadBalancerBackendAddressPools.js @@ -50,6 +50,7 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -58,9 +59,6 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { if (loadBalancerName === null || loadBalancerName === undefined || typeof loadBalancerName.valueOf() !== 'string') { throw new Error('loadBalancerName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -78,7 +76,7 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { requestUrl = requestUrl.replace('{loadBalancerName}', encodeURIComponent(loadBalancerName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -197,6 +195,7 @@ function _get(resourceGroupName, loadBalancerName, backendAddressPoolName, optio if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -208,9 +207,6 @@ function _get(resourceGroupName, loadBalancerName, backendAddressPoolName, optio if (backendAddressPoolName === null || backendAddressPoolName === undefined || typeof backendAddressPoolName.valueOf() !== 'string') { throw new Error('backendAddressPoolName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -229,7 +225,7 @@ function _get(resourceGroupName, loadBalancerName, backendAddressPoolName, optio requestUrl = requestUrl.replace('{backendAddressPoolName}', encodeURIComponent(backendAddressPoolName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/loadBalancerFrontendIPConfigurations.js b/lib/services/networkManagement2/lib/operations/loadBalancerFrontendIPConfigurations.js index fd396ac90b..c514809cdc 100644 --- a/lib/services/networkManagement2/lib/operations/loadBalancerFrontendIPConfigurations.js +++ b/lib/services/networkManagement2/lib/operations/loadBalancerFrontendIPConfigurations.js @@ -51,6 +51,7 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -59,9 +60,6 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { if (loadBalancerName === null || loadBalancerName === undefined || typeof loadBalancerName.valueOf() !== 'string') { throw new Error('loadBalancerName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -79,7 +77,7 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { requestUrl = requestUrl.replace('{loadBalancerName}', encodeURIComponent(loadBalancerName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -200,6 +198,7 @@ function _get(resourceGroupName, loadBalancerName, frontendIPConfigurationName, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -211,9 +210,6 @@ function _get(resourceGroupName, loadBalancerName, frontendIPConfigurationName, if (frontendIPConfigurationName === null || frontendIPConfigurationName === undefined || typeof frontendIPConfigurationName.valueOf() !== 'string') { throw new Error('frontendIPConfigurationName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -232,7 +228,7 @@ function _get(resourceGroupName, loadBalancerName, frontendIPConfigurationName, requestUrl = requestUrl.replace('{frontendIPConfigurationName}', encodeURIComponent(frontendIPConfigurationName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/loadBalancerLoadBalancingRules.js b/lib/services/networkManagement2/lib/operations/loadBalancerLoadBalancingRules.js index 40590cf2c2..6610a194bd 100644 --- a/lib/services/networkManagement2/lib/operations/loadBalancerLoadBalancingRules.js +++ b/lib/services/networkManagement2/lib/operations/loadBalancerLoadBalancingRules.js @@ -50,6 +50,7 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -58,9 +59,6 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { if (loadBalancerName === null || loadBalancerName === undefined || typeof loadBalancerName.valueOf() !== 'string') { throw new Error('loadBalancerName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -78,7 +76,7 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { requestUrl = requestUrl.replace('{loadBalancerName}', encodeURIComponent(loadBalancerName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -197,6 +195,7 @@ function _get(resourceGroupName, loadBalancerName, loadBalancingRuleName, option if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -208,9 +207,6 @@ function _get(resourceGroupName, loadBalancerName, loadBalancingRuleName, option if (loadBalancingRuleName === null || loadBalancingRuleName === undefined || typeof loadBalancingRuleName.valueOf() !== 'string') { throw new Error('loadBalancingRuleName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -229,7 +225,7 @@ function _get(resourceGroupName, loadBalancerName, loadBalancingRuleName, option requestUrl = requestUrl.replace('{loadBalancingRuleName}', encodeURIComponent(loadBalancingRuleName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/loadBalancerNetworkInterfaces.js b/lib/services/networkManagement2/lib/operations/loadBalancerNetworkInterfaces.js index 543a490d40..75d413b24d 100644 --- a/lib/services/networkManagement2/lib/operations/loadBalancerNetworkInterfaces.js +++ b/lib/services/networkManagement2/lib/operations/loadBalancerNetworkInterfaces.js @@ -50,6 +50,7 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -58,9 +59,6 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { if (loadBalancerName === null || loadBalancerName === undefined || typeof loadBalancerName.valueOf() !== 'string') { throw new Error('loadBalancerName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -78,7 +76,7 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { requestUrl = requestUrl.replace('{loadBalancerName}', encodeURIComponent(loadBalancerName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/loadBalancerProbes.js b/lib/services/networkManagement2/lib/operations/loadBalancerProbes.js index 4f03ac9afc..1791978c67 100644 --- a/lib/services/networkManagement2/lib/operations/loadBalancerProbes.js +++ b/lib/services/networkManagement2/lib/operations/loadBalancerProbes.js @@ -50,6 +50,7 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -58,9 +59,6 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { if (loadBalancerName === null || loadBalancerName === undefined || typeof loadBalancerName.valueOf() !== 'string') { throw new Error('loadBalancerName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -78,7 +76,7 @@ function _list(resourceGroupName, loadBalancerName, options, callback) { requestUrl = requestUrl.replace('{loadBalancerName}', encodeURIComponent(loadBalancerName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -197,6 +195,7 @@ function _get(resourceGroupName, loadBalancerName, probeName, options, callback) if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -208,9 +207,6 @@ function _get(resourceGroupName, loadBalancerName, probeName, options, callback) if (probeName === null || probeName === undefined || typeof probeName.valueOf() !== 'string') { throw new Error('probeName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -229,7 +225,7 @@ function _get(resourceGroupName, loadBalancerName, probeName, options, callback) requestUrl = requestUrl.replace('{probeName}', encodeURIComponent(probeName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/loadBalancers.js b/lib/services/networkManagement2/lib/operations/loadBalancers.js index 8bd21d2254..93a55f2af0 100644 --- a/lib/services/networkManagement2/lib/operations/loadBalancers.js +++ b/lib/services/networkManagement2/lib/operations/loadBalancers.js @@ -115,6 +115,7 @@ function _get(resourceGroupName, loadBalancerName, options, callback) { throw new Error('callback cannot be null.'); } let expand = (options && options.expand !== undefined) ? options.expand : undefined; + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -123,9 +124,6 @@ function _get(resourceGroupName, loadBalancerName, options, callback) { if (loadBalancerName === null || loadBalancerName === undefined || typeof loadBalancerName.valueOf() !== 'string') { throw new Error('loadBalancerName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -146,7 +144,7 @@ function _get(resourceGroupName, loadBalancerName, options, callback) { requestUrl = requestUrl.replace('{loadBalancerName}', encodeURIComponent(loadBalancerName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (expand !== null && expand !== undefined) { queryParameters.push('$expand=' + encodeURIComponent(expand)); } @@ -478,11 +476,9 @@ function _listAll(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -498,7 +494,7 @@ function _listAll(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/loadBalancers'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -614,14 +610,12 @@ function _list(resourceGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -638,7 +632,7 @@ function _list(resourceGroupName, options, callback) { requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -754,6 +748,7 @@ function _beginDeleteMethod(resourceGroupName, loadBalancerName, options, callba if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -762,9 +757,6 @@ function _beginDeleteMethod(resourceGroupName, loadBalancerName, options, callba if (loadBalancerName === null || loadBalancerName === undefined || typeof loadBalancerName.valueOf() !== 'string') { throw new Error('loadBalancerName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -782,7 +774,7 @@ function _beginDeleteMethod(resourceGroupName, loadBalancerName, options, callba requestUrl = requestUrl.replace('{loadBalancerName}', encodeURIComponent(loadBalancerName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -937,6 +929,7 @@ function _beginCreateOrUpdate(resourceGroupName, loadBalancerName, parameters, o if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -948,9 +941,6 @@ function _beginCreateOrUpdate(resourceGroupName, loadBalancerName, parameters, o if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -968,7 +958,7 @@ function _beginCreateOrUpdate(resourceGroupName, loadBalancerName, parameters, o requestUrl = requestUrl.replace('{loadBalancerName}', encodeURIComponent(loadBalancerName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1120,6 +1110,7 @@ function _beginUpdateTags(resourceGroupName, loadBalancerName, parameters, optio if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1131,9 +1122,6 @@ function _beginUpdateTags(resourceGroupName, loadBalancerName, parameters, optio if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1151,7 +1139,7 @@ function _beginUpdateTags(resourceGroupName, loadBalancerName, parameters, optio requestUrl = requestUrl.replace('{loadBalancerName}', encodeURIComponent(loadBalancerName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/localNetworkGateways.js b/lib/services/networkManagement2/lib/operations/localNetworkGateways.js index 9d43427a97..f4d9a8536e 100644 --- a/lib/services/networkManagement2/lib/operations/localNetworkGateways.js +++ b/lib/services/networkManagement2/lib/operations/localNetworkGateways.js @@ -164,6 +164,7 @@ function _get(resourceGroupName, localNetworkGatewayName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -178,9 +179,6 @@ function _get(resourceGroupName, localNetworkGatewayName, options, callback) { throw new Error('"localNetworkGatewayName" should satisfy the constraint - "MinLength": 1'); } } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -198,7 +196,7 @@ function _get(resourceGroupName, localNetworkGatewayName, options, callback) { requestUrl = requestUrl.replace('{localNetworkGatewayName}', encodeURIComponent(localNetworkGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -462,14 +460,12 @@ function _list(resourceGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -486,7 +482,7 @@ function _list(resourceGroupName, options, callback) { requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -639,6 +635,7 @@ function _beginCreateOrUpdate(resourceGroupName, localNetworkGatewayName, parame if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -656,9 +653,6 @@ function _beginCreateOrUpdate(resourceGroupName, localNetworkGatewayName, parame if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -676,7 +670,7 @@ function _beginCreateOrUpdate(resourceGroupName, localNetworkGatewayName, parame requestUrl = requestUrl.replace('{localNetworkGatewayName}', encodeURIComponent(localNetworkGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -824,6 +818,7 @@ function _beginDeleteMethod(resourceGroupName, localNetworkGatewayName, options, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -838,9 +833,6 @@ function _beginDeleteMethod(resourceGroupName, localNetworkGatewayName, options, throw new Error('"localNetworkGatewayName" should satisfy the constraint - "MinLength": 1'); } } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -858,7 +850,7 @@ function _beginDeleteMethod(resourceGroupName, localNetworkGatewayName, options, requestUrl = requestUrl.replace('{localNetworkGatewayName}', encodeURIComponent(localNetworkGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -964,6 +956,7 @@ function _beginUpdateTags(resourceGroupName, localNetworkGatewayName, parameters if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -981,9 +974,6 @@ function _beginUpdateTags(resourceGroupName, localNetworkGatewayName, parameters if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1001,7 +991,7 @@ function _beginUpdateTags(resourceGroupName, localNetworkGatewayName, parameters requestUrl = requestUrl.replace('{localNetworkGatewayName}', encodeURIComponent(localNetworkGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/networkInterfaceIPConfigurations.js b/lib/services/networkManagement2/lib/operations/networkInterfaceIPConfigurations.js index db53f4db14..1750d4d95c 100644 --- a/lib/services/networkManagement2/lib/operations/networkInterfaceIPConfigurations.js +++ b/lib/services/networkManagement2/lib/operations/networkInterfaceIPConfigurations.js @@ -50,6 +50,7 @@ function _list(resourceGroupName, networkInterfaceName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -58,9 +59,6 @@ function _list(resourceGroupName, networkInterfaceName, options, callback) { if (networkInterfaceName === null || networkInterfaceName === undefined || typeof networkInterfaceName.valueOf() !== 'string') { throw new Error('networkInterfaceName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -78,7 +76,7 @@ function _list(resourceGroupName, networkInterfaceName, options, callback) { requestUrl = requestUrl.replace('{networkInterfaceName}', encodeURIComponent(networkInterfaceName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -198,6 +196,7 @@ function _get(resourceGroupName, networkInterfaceName, ipConfigurationName, opti if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -209,9 +208,6 @@ function _get(resourceGroupName, networkInterfaceName, ipConfigurationName, opti if (ipConfigurationName === null || ipConfigurationName === undefined || typeof ipConfigurationName.valueOf() !== 'string') { throw new Error('ipConfigurationName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -230,7 +226,7 @@ function _get(resourceGroupName, networkInterfaceName, ipConfigurationName, opti requestUrl = requestUrl.replace('{ipConfigurationName}', encodeURIComponent(ipConfigurationName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/networkInterfaceLoadBalancers.js b/lib/services/networkManagement2/lib/operations/networkInterfaceLoadBalancers.js index db1e16ac06..040fabb791 100644 --- a/lib/services/networkManagement2/lib/operations/networkInterfaceLoadBalancers.js +++ b/lib/services/networkManagement2/lib/operations/networkInterfaceLoadBalancers.js @@ -50,6 +50,7 @@ function _list(resourceGroupName, networkInterfaceName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -58,9 +59,6 @@ function _list(resourceGroupName, networkInterfaceName, options, callback) { if (networkInterfaceName === null || networkInterfaceName === undefined || typeof networkInterfaceName.valueOf() !== 'string') { throw new Error('networkInterfaceName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -78,7 +76,7 @@ function _list(resourceGroupName, networkInterfaceName, options, callback) { requestUrl = requestUrl.replace('{networkInterfaceName}', encodeURIComponent(networkInterfaceName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/networkInterfaces.js b/lib/services/networkManagement2/lib/operations/networkInterfaces.js index c24fdf2233..a298f16e6f 100644 --- a/lib/services/networkManagement2/lib/operations/networkInterfaces.js +++ b/lib/services/networkManagement2/lib/operations/networkInterfaces.js @@ -115,6 +115,7 @@ function _get(resourceGroupName, networkInterfaceName, options, callback) { throw new Error('callback cannot be null.'); } let expand = (options && options.expand !== undefined) ? options.expand : undefined; + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -123,9 +124,6 @@ function _get(resourceGroupName, networkInterfaceName, options, callback) { if (networkInterfaceName === null || networkInterfaceName === undefined || typeof networkInterfaceName.valueOf() !== 'string') { throw new Error('networkInterfaceName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -146,7 +144,7 @@ function _get(resourceGroupName, networkInterfaceName, options, callback) { requestUrl = requestUrl.replace('{networkInterfaceName}', encodeURIComponent(networkInterfaceName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (expand !== null && expand !== undefined) { queryParameters.push('$expand=' + encodeURIComponent(expand)); } @@ -515,11 +513,9 @@ function _listAll(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -535,7 +531,7 @@ function _listAll(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/networkInterfaces'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -651,14 +647,12 @@ function _list(resourceGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -675,7 +669,7 @@ function _list(resourceGroupName, options, callback) { requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -955,7 +949,7 @@ function _listVirtualMachineScaleSetVMNetworkInterfaces(resourceGroupName, virtu if (!callback) { throw new Error('callback cannot be null.'); } - let apiVersion = '2018-02-01'; + let apiVersion = '2017-03-30'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1104,7 +1098,7 @@ function _listVirtualMachineScaleSetNetworkInterfaces(resourceGroupName, virtual if (!callback) { throw new Error('callback cannot be null.'); } - let apiVersion = '2018-02-01'; + let apiVersion = '2017-03-30'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1255,7 +1249,7 @@ function _getVirtualMachineScaleSetNetworkInterface(resourceGroupName, virtualMa throw new Error('callback cannot be null.'); } let expand = (options && options.expand !== undefined) ? options.expand : undefined; - let apiVersion = '2018-02-01'; + let apiVersion = '2017-03-30'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1422,7 +1416,7 @@ function _listVirtualMachineScaleSetIpConfigurations(resourceGroupName, virtualM throw new Error('callback cannot be null.'); } let expand = (options && options.expand !== undefined) ? options.expand : undefined; - let apiVersion = '2018-02-01'; + let apiVersion = '2017-03-30'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1591,7 +1585,7 @@ function _getVirtualMachineScaleSetIpConfiguration(resourceGroupName, virtualMac throw new Error('callback cannot be null.'); } let expand = (options && options.expand !== undefined) ? options.expand : undefined; - let apiVersion = '2018-02-01'; + let apiVersion = '2017-03-30'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1751,6 +1745,7 @@ function _beginDeleteMethod(resourceGroupName, networkInterfaceName, options, ca if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1759,9 +1754,6 @@ function _beginDeleteMethod(resourceGroupName, networkInterfaceName, options, ca if (networkInterfaceName === null || networkInterfaceName === undefined || typeof networkInterfaceName.valueOf() !== 'string') { throw new Error('networkInterfaceName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1779,7 +1771,7 @@ function _beginDeleteMethod(resourceGroupName, networkInterfaceName, options, ca requestUrl = requestUrl.replace('{networkInterfaceName}', encodeURIComponent(networkInterfaceName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1970,6 +1962,7 @@ function _beginCreateOrUpdate(resourceGroupName, networkInterfaceName, parameter if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1981,9 +1974,6 @@ function _beginCreateOrUpdate(resourceGroupName, networkInterfaceName, parameter if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2001,7 +1991,7 @@ function _beginCreateOrUpdate(resourceGroupName, networkInterfaceName, parameter requestUrl = requestUrl.replace('{networkInterfaceName}', encodeURIComponent(networkInterfaceName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2154,6 +2144,7 @@ function _beginUpdateTags(resourceGroupName, networkInterfaceName, parameters, o if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2165,9 +2156,6 @@ function _beginUpdateTags(resourceGroupName, networkInterfaceName, parameters, o if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2185,7 +2173,7 @@ function _beginUpdateTags(resourceGroupName, networkInterfaceName, parameters, o requestUrl = requestUrl.replace('{networkInterfaceName}', encodeURIComponent(networkInterfaceName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2317,6 +2305,7 @@ function _beginGetEffectiveRouteTable(resourceGroupName, networkInterfaceName, o if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2325,9 +2314,6 @@ function _beginGetEffectiveRouteTable(resourceGroupName, networkInterfaceName, o if (networkInterfaceName === null || networkInterfaceName === undefined || typeof networkInterfaceName.valueOf() !== 'string') { throw new Error('networkInterfaceName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2345,7 +2331,7 @@ function _beginGetEffectiveRouteTable(resourceGroupName, networkInterfaceName, o requestUrl = requestUrl.replace('{networkInterfaceName}', encodeURIComponent(networkInterfaceName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2463,6 +2449,7 @@ function _beginListEffectiveNetworkSecurityGroups(resourceGroupName, networkInte if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2471,9 +2458,6 @@ function _beginListEffectiveNetworkSecurityGroups(resourceGroupName, networkInte if (networkInterfaceName === null || networkInterfaceName === undefined || typeof networkInterfaceName.valueOf() !== 'string') { throw new Error('networkInterfaceName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2491,7 +2475,7 @@ function _beginListEffectiveNetworkSecurityGroups(resourceGroupName, networkInte requestUrl = requestUrl.replace('{networkInterfaceName}', encodeURIComponent(networkInterfaceName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/networkSecurityGroups.js b/lib/services/networkManagement2/lib/operations/networkSecurityGroups.js index 60dd20b7a6..c2bb3bf542 100644 --- a/lib/services/networkManagement2/lib/operations/networkSecurityGroups.js +++ b/lib/services/networkManagement2/lib/operations/networkSecurityGroups.js @@ -117,6 +117,7 @@ function _get(resourceGroupName, networkSecurityGroupName, options, callback) { throw new Error('callback cannot be null.'); } let expand = (options && options.expand !== undefined) ? options.expand : undefined; + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -125,9 +126,6 @@ function _get(resourceGroupName, networkSecurityGroupName, options, callback) { if (networkSecurityGroupName === null || networkSecurityGroupName === undefined || typeof networkSecurityGroupName.valueOf() !== 'string') { throw new Error('networkSecurityGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -148,7 +146,7 @@ function _get(resourceGroupName, networkSecurityGroupName, options, callback) { requestUrl = requestUrl.replace('{networkSecurityGroupName}', encodeURIComponent(networkSecurityGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (expand !== null && expand !== undefined) { queryParameters.push('$expand=' + encodeURIComponent(expand)); } @@ -453,11 +451,9 @@ function _listAll(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -473,7 +469,7 @@ function _listAll(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/networkSecurityGroups'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -589,14 +585,12 @@ function _list(resourceGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -613,7 +607,7 @@ function _list(resourceGroupName, options, callback) { requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -730,6 +724,7 @@ function _beginDeleteMethod(resourceGroupName, networkSecurityGroupName, options if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -738,9 +733,6 @@ function _beginDeleteMethod(resourceGroupName, networkSecurityGroupName, options if (networkSecurityGroupName === null || networkSecurityGroupName === undefined || typeof networkSecurityGroupName.valueOf() !== 'string') { throw new Error('networkSecurityGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -758,7 +750,7 @@ function _beginDeleteMethod(resourceGroupName, networkSecurityGroupName, options requestUrl = requestUrl.replace('{networkSecurityGroupName}', encodeURIComponent(networkSecurityGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -884,6 +876,7 @@ function _beginCreateOrUpdate(resourceGroupName, networkSecurityGroupName, param if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -895,9 +888,6 @@ function _beginCreateOrUpdate(resourceGroupName, networkSecurityGroupName, param if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -915,7 +905,7 @@ function _beginCreateOrUpdate(resourceGroupName, networkSecurityGroupName, param requestUrl = requestUrl.replace('{networkSecurityGroupName}', encodeURIComponent(networkSecurityGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1069,6 +1059,7 @@ function _beginUpdateTags(resourceGroupName, networkSecurityGroupName, parameter if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1080,9 +1071,6 @@ function _beginUpdateTags(resourceGroupName, networkSecurityGroupName, parameter if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1100,7 +1088,7 @@ function _beginUpdateTags(resourceGroupName, networkSecurityGroupName, parameter requestUrl = requestUrl.replace('{networkSecurityGroupName}', encodeURIComponent(networkSecurityGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/networkWatchers.js b/lib/services/networkManagement2/lib/operations/networkWatchers.js index ba75241a11..c744d25aae 100644 --- a/lib/services/networkManagement2/lib/operations/networkWatchers.js +++ b/lib/services/networkManagement2/lib/operations/networkWatchers.js @@ -61,6 +61,7 @@ function _createOrUpdate(resourceGroupName, networkWatcherName, parameters, opti if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -72,9 +73,6 @@ function _createOrUpdate(resourceGroupName, networkWatcherName, parameters, opti if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -92,7 +90,7 @@ function _createOrUpdate(resourceGroupName, networkWatcherName, parameters, opti requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -240,6 +238,7 @@ function _get(resourceGroupName, networkWatcherName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -248,9 +247,6 @@ function _get(resourceGroupName, networkWatcherName, options, callback) { if (networkWatcherName === null || networkWatcherName === undefined || typeof networkWatcherName.valueOf() !== 'string') { throw new Error('networkWatcherName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -268,7 +264,7 @@ function _get(resourceGroupName, networkWatcherName, options, callback) { requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -453,6 +449,7 @@ function _updateTags(resourceGroupName, networkWatcherName, parameters, options, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -464,9 +461,6 @@ function _updateTags(resourceGroupName, networkWatcherName, parameters, options, if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -484,7 +478,7 @@ function _updateTags(resourceGroupName, networkWatcherName, parameters, options, requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -614,14 +608,12 @@ function _list(resourceGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -638,7 +630,7 @@ function _list(resourceGroupName, options, callback) { requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -752,11 +744,9 @@ function _listAll(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -772,7 +762,7 @@ function _listAll(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/networkWatchers'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -903,6 +893,7 @@ function _getTopology(resourceGroupName, networkWatcherName, parameters, options if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -914,9 +905,6 @@ function _getTopology(resourceGroupName, networkWatcherName, parameters, options if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -934,7 +922,7 @@ function _getTopology(resourceGroupName, networkWatcherName, parameters, options requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1492,7 +1480,8 @@ function _getTroubleshootingResult(resourceGroupName, networkWatcherName, parame /** - * Configures flow log on a specified resource. + * Configures flow log and traffic analytics (optional) on a specified + * resource. * * @param {string} resourceGroupName The name of the network watcher resource * group. @@ -1503,7 +1492,7 @@ function _getTroubleshootingResult(resourceGroupName, networkWatcherName, parame * log. * * @param {string} parameters.targetResourceId The ID of the resource to - * configure for flow logging. + * configure for flow log and traffic analytics (optional) . * * @param {string} parameters.storageId ID of the storage account which is used * to store the flow log. @@ -1518,6 +1507,27 @@ function _getTroubleshootingResult(resourceGroupName, networkWatcherName, parame * @param {boolean} [parameters.retentionPolicy.enabled] Flag to enable/disable * retention. * + * @param {object} [parameters.flowAnalyticsConfiguration] + * + * @param {object} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration + * + * @param {boolean} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.enabled + * Flag to enable/disable traffic analytics. + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceId + * The resource guid of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceRegion + * The location of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceResourceId + * Resource Id of the attached workspace + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -1590,7 +1600,8 @@ function _setFlowLogConfiguration(resourceGroupName, networkWatcherName, paramet /** - * Queries status of flow log on a specified resource. + * Queries status of flow log and traffic analytics (optional) on a specified + * resource. * * @param {string} resourceGroupName The name of the network watcher resource * group. @@ -1598,10 +1609,10 @@ function _setFlowLogConfiguration(resourceGroupName, networkWatcherName, paramet * @param {string} networkWatcherName The name of the network watcher resource. * * @param {object} parameters Parameters that define a resource to query flow - * log status. + * log and traffic analytics (optional) status. * * @param {string} parameters.targetResourceId The target resource where - * getting the flow logging status. + * getting the flow log and traffic analytics (optional) status. * * @param {object} [options] Optional Parameters. * @@ -2025,6 +2036,7 @@ function _beginDeleteMethod(resourceGroupName, networkWatcherName, options, call if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2033,9 +2045,6 @@ function _beginDeleteMethod(resourceGroupName, networkWatcherName, options, call if (networkWatcherName === null || networkWatcherName === undefined || typeof networkWatcherName.valueOf() !== 'string') { throw new Error('networkWatcherName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2053,7 +2062,7 @@ function _beginDeleteMethod(resourceGroupName, networkWatcherName, options, call requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2185,6 +2194,7 @@ function _beginVerifyIPFlow(resourceGroupName, networkWatcherName, parameters, o if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2196,9 +2206,6 @@ function _beginVerifyIPFlow(resourceGroupName, networkWatcherName, parameters, o if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2216,7 +2223,7 @@ function _beginVerifyIPFlow(resourceGroupName, networkWatcherName, parameters, o requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2378,6 +2385,7 @@ function _beginGetNextHop(resourceGroupName, networkWatcherName, parameters, opt if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2389,9 +2397,6 @@ function _beginGetNextHop(resourceGroupName, networkWatcherName, parameters, opt if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2409,7 +2414,7 @@ function _beginGetNextHop(resourceGroupName, networkWatcherName, parameters, opt requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2563,6 +2568,7 @@ function _beginGetVMSecurityRules(resourceGroupName, networkWatcherName, paramet if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2574,9 +2580,6 @@ function _beginGetVMSecurityRules(resourceGroupName, networkWatcherName, paramet if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2594,7 +2597,7 @@ function _beginGetVMSecurityRules(resourceGroupName, networkWatcherName, paramet requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2754,6 +2757,7 @@ function _beginGetTroubleshooting(resourceGroupName, networkWatcherName, paramet if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2765,9 +2769,6 @@ function _beginGetTroubleshooting(resourceGroupName, networkWatcherName, paramet if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2785,7 +2786,7 @@ function _beginGetTroubleshooting(resourceGroupName, networkWatcherName, paramet requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2939,6 +2940,7 @@ function _beginGetTroubleshootingResult(resourceGroupName, networkWatcherName, p if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2950,9 +2952,6 @@ function _beginGetTroubleshootingResult(resourceGroupName, networkWatcherName, p if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2970,7 +2969,7 @@ function _beginGetTroubleshootingResult(resourceGroupName, networkWatcherName, p requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -3084,7 +3083,8 @@ function _beginGetTroubleshootingResult(resourceGroupName, networkWatcherName, p } /** - * Configures flow log on a specified resource. + * Configures flow log and traffic analytics (optional) on a specified + * resource. * * @param {string} resourceGroupName The name of the network watcher resource * group. @@ -3095,7 +3095,7 @@ function _beginGetTroubleshootingResult(resourceGroupName, networkWatcherName, p * log. * * @param {string} parameters.targetResourceId The ID of the resource to - * configure for flow logging. + * configure for flow log and traffic analytics (optional) . * * @param {string} parameters.storageId ID of the storage account which is used * to store the flow log. @@ -3110,6 +3110,27 @@ function _beginGetTroubleshootingResult(resourceGroupName, networkWatcherName, p * @param {boolean} [parameters.retentionPolicy.enabled] Flag to enable/disable * retention. * + * @param {object} [parameters.flowAnalyticsConfiguration] + * + * @param {object} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration + * + * @param {boolean} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.enabled + * Flag to enable/disable traffic analytics. + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceId + * The resource guid of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceRegion + * The location of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceResourceId + * Resource Id of the attached workspace + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -3138,6 +3159,7 @@ function _beginSetFlowLogConfiguration(resourceGroupName, networkWatcherName, pa if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -3149,9 +3171,6 @@ function _beginSetFlowLogConfiguration(resourceGroupName, networkWatcherName, pa if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -3169,7 +3188,7 @@ function _beginSetFlowLogConfiguration(resourceGroupName, networkWatcherName, pa requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -3283,7 +3302,8 @@ function _beginSetFlowLogConfiguration(resourceGroupName, networkWatcherName, pa } /** - * Queries status of flow log on a specified resource. + * Queries status of flow log and traffic analytics (optional) on a specified + * resource. * * @param {string} resourceGroupName The name of the network watcher resource * group. @@ -3291,10 +3311,10 @@ function _beginSetFlowLogConfiguration(resourceGroupName, networkWatcherName, pa * @param {string} networkWatcherName The name of the network watcher resource. * * @param {object} parameters Parameters that define a resource to query flow - * log status. + * log and traffic analytics (optional) status. * * @param {string} parameters.targetResourceId The target resource where - * getting the flow logging status. + * getting the flow log and traffic analytics (optional) status. * * @param {object} [options] Optional Parameters. * @@ -3324,6 +3344,7 @@ function _beginGetFlowLogStatus(resourceGroupName, networkWatcherName, parameter if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -3335,9 +3356,6 @@ function _beginGetFlowLogStatus(resourceGroupName, networkWatcherName, parameter if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -3355,7 +3373,7 @@ function _beginGetFlowLogStatus(resourceGroupName, networkWatcherName, parameter requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -3546,6 +3564,7 @@ function _beginCheckConnectivity(resourceGroupName, networkWatcherName, paramete if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -3557,9 +3576,6 @@ function _beginCheckConnectivity(resourceGroupName, networkWatcherName, paramete if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -3577,7 +3593,7 @@ function _beginCheckConnectivity(resourceGroupName, networkWatcherName, paramete requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -3751,6 +3767,7 @@ function _beginGetAzureReachabilityReport(resourceGroupName, networkWatcherName, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -3762,9 +3779,6 @@ function _beginGetAzureReachabilityReport(resourceGroupName, networkWatcherName, if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -3782,7 +3796,7 @@ function _beginGetAzureReachabilityReport(resourceGroupName, networkWatcherName, requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -3945,6 +3959,7 @@ function _beginListAvailableProviders(resourceGroupName, networkWatcherName, par if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -3956,9 +3971,6 @@ function _beginListAvailableProviders(resourceGroupName, networkWatcherName, par if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -3976,7 +3988,7 @@ function _beginListAvailableProviders(resourceGroupName, networkWatcherName, par requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -5349,7 +5361,8 @@ class NetworkWatchers { } /** - * Configures flow log on a specified resource. + * Configures flow log and traffic analytics (optional) on a specified + * resource. * * @param {string} resourceGroupName The name of the network watcher resource * group. @@ -5360,7 +5373,7 @@ class NetworkWatchers { * log. * * @param {string} parameters.targetResourceId The ID of the resource to - * configure for flow logging. + * configure for flow log and traffic analytics (optional) . * * @param {string} parameters.storageId ID of the storage account which is used * to store the flow log. @@ -5375,6 +5388,27 @@ class NetworkWatchers { * @param {boolean} [parameters.retentionPolicy.enabled] Flag to enable/disable * retention. * + * @param {object} [parameters.flowAnalyticsConfiguration] + * + * @param {object} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration + * + * @param {boolean} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.enabled + * Flag to enable/disable traffic analytics. + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceId + * The resource guid of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceRegion + * The location of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceResourceId + * Resource Id of the attached workspace + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -5401,7 +5435,8 @@ class NetworkWatchers { } /** - * Configures flow log on a specified resource. + * Configures flow log and traffic analytics (optional) on a specified + * resource. * * @param {string} resourceGroupName The name of the network watcher resource * group. @@ -5412,7 +5447,7 @@ class NetworkWatchers { * log. * * @param {string} parameters.targetResourceId The ID of the resource to - * configure for flow logging. + * configure for flow log and traffic analytics (optional) . * * @param {string} parameters.storageId ID of the storage account which is used * to store the flow log. @@ -5427,6 +5462,27 @@ class NetworkWatchers { * @param {boolean} [parameters.retentionPolicy.enabled] Flag to enable/disable * retention. * + * @param {object} [parameters.flowAnalyticsConfiguration] + * + * @param {object} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration + * + * @param {boolean} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.enabled + * Flag to enable/disable traffic analytics. + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceId + * The resource guid of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceRegion + * The location of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceResourceId + * Resource Id of the attached workspace + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -5475,7 +5531,8 @@ class NetworkWatchers { } /** - * Queries status of flow log on a specified resource. + * Queries status of flow log and traffic analytics (optional) on a specified + * resource. * * @param {string} resourceGroupName The name of the network watcher resource * group. @@ -5483,10 +5540,10 @@ class NetworkWatchers { * @param {string} networkWatcherName The name of the network watcher resource. * * @param {object} parameters Parameters that define a resource to query flow - * log status. + * log and traffic analytics (optional) status. * * @param {string} parameters.targetResourceId The target resource where - * getting the flow logging status. + * getting the flow log and traffic analytics (optional) status. * * @param {object} [options] Optional Parameters. * @@ -5514,7 +5571,8 @@ class NetworkWatchers { } /** - * Queries status of flow log on a specified resource. + * Queries status of flow log and traffic analytics (optional) on a specified + * resource. * * @param {string} resourceGroupName The name of the network watcher resource * group. @@ -5522,10 +5580,10 @@ class NetworkWatchers { * @param {string} networkWatcherName The name of the network watcher resource. * * @param {object} parameters Parameters that define a resource to query flow - * log status. + * log and traffic analytics (optional) status. * * @param {string} parameters.targetResourceId The target resource where - * getting the flow logging status. + * getting the flow log and traffic analytics (optional) status. * * @param {object} [options] Optional Parameters. * @@ -6651,7 +6709,8 @@ class NetworkWatchers { } /** - * Configures flow log on a specified resource. + * Configures flow log and traffic analytics (optional) on a specified + * resource. * * @param {string} resourceGroupName The name of the network watcher resource * group. @@ -6662,7 +6721,7 @@ class NetworkWatchers { * log. * * @param {string} parameters.targetResourceId The ID of the resource to - * configure for flow logging. + * configure for flow log and traffic analytics (optional) . * * @param {string} parameters.storageId ID of the storage account which is used * to store the flow log. @@ -6677,6 +6736,27 @@ class NetworkWatchers { * @param {boolean} [parameters.retentionPolicy.enabled] Flag to enable/disable * retention. * + * @param {object} [parameters.flowAnalyticsConfiguration] + * + * @param {object} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration + * + * @param {boolean} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.enabled + * Flag to enable/disable traffic analytics. + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceId + * The resource guid of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceRegion + * The location of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceResourceId + * Resource Id of the attached workspace + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -6703,7 +6783,8 @@ class NetworkWatchers { } /** - * Configures flow log on a specified resource. + * Configures flow log and traffic analytics (optional) on a specified + * resource. * * @param {string} resourceGroupName The name of the network watcher resource * group. @@ -6714,7 +6795,7 @@ class NetworkWatchers { * log. * * @param {string} parameters.targetResourceId The ID of the resource to - * configure for flow logging. + * configure for flow log and traffic analytics (optional) . * * @param {string} parameters.storageId ID of the storage account which is used * to store the flow log. @@ -6729,6 +6810,27 @@ class NetworkWatchers { * @param {boolean} [parameters.retentionPolicy.enabled] Flag to enable/disable * retention. * + * @param {object} [parameters.flowAnalyticsConfiguration] + * + * @param {object} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration + * + * @param {boolean} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.enabled + * Flag to enable/disable traffic analytics. + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceId + * The resource guid of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceRegion + * The location of the attached workspace + * + * @param {string} + * parameters.flowAnalyticsConfiguration.networkWatcherFlowAnalyticsConfiguration.workspaceResourceId + * Resource Id of the attached workspace + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -6777,7 +6879,8 @@ class NetworkWatchers { } /** - * Queries status of flow log on a specified resource. + * Queries status of flow log and traffic analytics (optional) on a specified + * resource. * * @param {string} resourceGroupName The name of the network watcher resource * group. @@ -6785,10 +6888,10 @@ class NetworkWatchers { * @param {string} networkWatcherName The name of the network watcher resource. * * @param {object} parameters Parameters that define a resource to query flow - * log status. + * log and traffic analytics (optional) status. * * @param {string} parameters.targetResourceId The target resource where - * getting the flow logging status. + * getting the flow log and traffic analytics (optional) status. * * @param {object} [options] Optional Parameters. * @@ -6816,7 +6919,8 @@ class NetworkWatchers { } /** - * Queries status of flow log on a specified resource. + * Queries status of flow log and traffic analytics (optional) on a specified + * resource. * * @param {string} resourceGroupName The name of the network watcher resource * group. @@ -6824,10 +6928,10 @@ class NetworkWatchers { * @param {string} networkWatcherName The name of the network watcher resource. * * @param {object} parameters Parameters that define a resource to query flow - * log status. + * log and traffic analytics (optional) status. * * @param {string} parameters.targetResourceId The target resource where - * getting the flow logging status. + * getting the flow log and traffic analytics (optional) status. * * @param {object} [options] Optional Parameters. * diff --git a/lib/services/networkManagement2/lib/operations/operations.js b/lib/services/networkManagement2/lib/operations/operations.js index fb99365869..2cd6898159 100644 --- a/lib/services/networkManagement2/lib/operations/operations.js +++ b/lib/services/networkManagement2/lib/operations/operations.js @@ -45,11 +45,9 @@ function _list(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { throw new Error('this.client.acceptLanguage must be of type string.'); } @@ -61,7 +59,7 @@ function _list(options, callback) { let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'providers/Microsoft.Network/operations'; let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/packetCaptures.js b/lib/services/networkManagement2/lib/operations/packetCaptures.js index 0e78bd995f..089c5b1985 100644 --- a/lib/services/networkManagement2/lib/operations/packetCaptures.js +++ b/lib/services/networkManagement2/lib/operations/packetCaptures.js @@ -163,6 +163,7 @@ function _get(resourceGroupName, networkWatcherName, packetCaptureName, options, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -174,9 +175,6 @@ function _get(resourceGroupName, networkWatcherName, packetCaptureName, options, if (packetCaptureName === null || packetCaptureName === undefined || typeof packetCaptureName.valueOf() !== 'string') { throw new Error('packetCaptureName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -195,7 +193,7 @@ function _get(resourceGroupName, networkWatcherName, packetCaptureName, options, requestUrl = requestUrl.replace('{packetCaptureName}', encodeURIComponent(packetCaptureName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -525,6 +523,7 @@ function _list(resourceGroupName, networkWatcherName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -533,9 +532,6 @@ function _list(resourceGroupName, networkWatcherName, options, callback) { if (networkWatcherName === null || networkWatcherName === undefined || typeof networkWatcherName.valueOf() !== 'string') { throw new Error('networkWatcherName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -553,7 +549,7 @@ function _list(resourceGroupName, networkWatcherName, options, callback) { requestUrl = requestUrl.replace('{networkWatcherName}', encodeURIComponent(networkWatcherName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -704,6 +700,7 @@ function _beginCreate(resourceGroupName, networkWatcherName, packetCaptureName, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -718,9 +715,6 @@ function _beginCreate(resourceGroupName, networkWatcherName, packetCaptureName, if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -739,7 +733,7 @@ function _beginCreate(resourceGroupName, networkWatcherName, packetCaptureName, requestUrl = requestUrl.replace('{packetCaptureName}', encodeURIComponent(packetCaptureName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -871,6 +865,7 @@ function _beginDeleteMethod(resourceGroupName, networkWatcherName, packetCapture if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -882,9 +877,6 @@ function _beginDeleteMethod(resourceGroupName, networkWatcherName, packetCapture if (packetCaptureName === null || packetCaptureName === undefined || typeof packetCaptureName.valueOf() !== 'string') { throw new Error('packetCaptureName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -903,7 +895,7 @@ function _beginDeleteMethod(resourceGroupName, networkWatcherName, packetCapture requestUrl = requestUrl.replace('{packetCaptureName}', encodeURIComponent(packetCaptureName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1004,6 +996,7 @@ function _beginStop(resourceGroupName, networkWatcherName, packetCaptureName, op if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1015,9 +1008,6 @@ function _beginStop(resourceGroupName, networkWatcherName, packetCaptureName, op if (packetCaptureName === null || packetCaptureName === undefined || typeof packetCaptureName.valueOf() !== 'string') { throw new Error('packetCaptureName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1036,7 +1026,7 @@ function _beginStop(resourceGroupName, networkWatcherName, packetCaptureName, op requestUrl = requestUrl.replace('{packetCaptureName}', encodeURIComponent(packetCaptureName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1140,6 +1130,7 @@ function _beginGetStatus(resourceGroupName, networkWatcherName, packetCaptureNam if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1151,9 +1142,6 @@ function _beginGetStatus(resourceGroupName, networkWatcherName, packetCaptureNam if (packetCaptureName === null || packetCaptureName === undefined || typeof packetCaptureName.valueOf() !== 'string') { throw new Error('packetCaptureName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1172,7 +1160,7 @@ function _beginGetStatus(resourceGroupName, networkWatcherName, packetCaptureNam requestUrl = requestUrl.replace('{packetCaptureName}', encodeURIComponent(packetCaptureName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/publicIPAddresses.js b/lib/services/networkManagement2/lib/operations/publicIPAddresses.js index d571cbb250..22e4718f80 100644 --- a/lib/services/networkManagement2/lib/operations/publicIPAddresses.js +++ b/lib/services/networkManagement2/lib/operations/publicIPAddresses.js @@ -115,6 +115,7 @@ function _get(resourceGroupName, publicIpAddressName, options, callback) { throw new Error('callback cannot be null.'); } let expand = (options && options.expand !== undefined) ? options.expand : undefined; + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -123,9 +124,6 @@ function _get(resourceGroupName, publicIpAddressName, options, callback) { if (publicIpAddressName === null || publicIpAddressName === undefined || typeof publicIpAddressName.valueOf() !== 'string') { throw new Error('publicIpAddressName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -146,7 +144,7 @@ function _get(resourceGroupName, publicIpAddressName, options, callback) { requestUrl = requestUrl.replace('{publicIpAddressName}', encodeURIComponent(publicIpAddressName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (expand !== null && expand !== undefined) { queryParameters.push('$expand=' + encodeURIComponent(expand)); } @@ -487,11 +485,9 @@ function _listAll(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -507,7 +503,7 @@ function _listAll(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/publicIPAddresses'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -623,14 +619,12 @@ function _list(resourceGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -647,7 +641,7 @@ function _list(resourceGroupName, options, callback) { requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -767,7 +761,7 @@ function _listVirtualMachineScaleSetPublicIPAddresses(resourceGroupName, virtual if (!callback) { throw new Error('callback cannot be null.'); } - let apiVersion = '2018-02-01'; + let apiVersion = '2017-03-30'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -919,7 +913,7 @@ function _listVirtualMachineScaleSetVMPublicIPAddresses(resourceGroupName, virtu if (!callback) { throw new Error('callback cannot be null.'); } - let apiVersion = '2018-02-01'; + let apiVersion = '2017-03-30'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1086,7 +1080,7 @@ function _getVirtualMachineScaleSetPublicIPAddress(resourceGroupName, virtualMac throw new Error('callback cannot be null.'); } let expand = (options && options.expand !== undefined) ? options.expand : undefined; - let apiVersion = '2018-02-01'; + let apiVersion = '2017-03-30'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1250,6 +1244,7 @@ function _beginDeleteMethod(resourceGroupName, publicIpAddressName, options, cal if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1258,9 +1253,6 @@ function _beginDeleteMethod(resourceGroupName, publicIpAddressName, options, cal if (publicIpAddressName === null || publicIpAddressName === undefined || typeof publicIpAddressName.valueOf() !== 'string') { throw new Error('publicIpAddressName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1278,7 +1270,7 @@ function _beginDeleteMethod(resourceGroupName, publicIpAddressName, options, cal requestUrl = requestUrl.replace('{publicIpAddressName}', encodeURIComponent(publicIpAddressName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1441,6 +1433,7 @@ function _beginCreateOrUpdate(resourceGroupName, publicIpAddressName, parameters if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1452,9 +1445,6 @@ function _beginCreateOrUpdate(resourceGroupName, publicIpAddressName, parameters if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1472,7 +1462,7 @@ function _beginCreateOrUpdate(resourceGroupName, publicIpAddressName, parameters requestUrl = requestUrl.replace('{publicIpAddressName}', encodeURIComponent(publicIpAddressName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1625,6 +1615,7 @@ function _beginUpdateTags(resourceGroupName, publicIpAddressName, parameters, op if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1636,9 +1627,6 @@ function _beginUpdateTags(resourceGroupName, publicIpAddressName, parameters, op if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1656,7 +1644,7 @@ function _beginUpdateTags(resourceGroupName, publicIpAddressName, parameters, op requestUrl = requestUrl.replace('{publicIpAddressName}', encodeURIComponent(publicIpAddressName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/routeFilterRules.js b/lib/services/networkManagement2/lib/operations/routeFilterRules.js index f75f1724e6..f3528b9f62 100644 --- a/lib/services/networkManagement2/lib/operations/routeFilterRules.js +++ b/lib/services/networkManagement2/lib/operations/routeFilterRules.js @@ -116,6 +116,7 @@ function _get(resourceGroupName, routeFilterName, ruleName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -127,9 +128,6 @@ function _get(resourceGroupName, routeFilterName, ruleName, options, callback) { if (ruleName === null || ruleName === undefined || typeof ruleName.valueOf() !== 'string') { throw new Error('ruleName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -148,7 +146,7 @@ function _get(resourceGroupName, routeFilterName, ruleName, options, callback) { requestUrl = requestUrl.replace('{ruleName}', encodeURIComponent(ruleName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -456,6 +454,7 @@ function _listByRouteFilter(resourceGroupName, routeFilterName, options, callbac if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -464,9 +463,6 @@ function _listByRouteFilter(resourceGroupName, routeFilterName, options, callbac if (routeFilterName === null || routeFilterName === undefined || typeof routeFilterName.valueOf() !== 'string') { throw new Error('routeFilterName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -484,7 +480,7 @@ function _listByRouteFilter(resourceGroupName, routeFilterName, options, callbac requestUrl = requestUrl.replace('{routeFilterName}', encodeURIComponent(routeFilterName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -602,6 +598,7 @@ function _beginDeleteMethod(resourceGroupName, routeFilterName, ruleName, option if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -613,9 +610,6 @@ function _beginDeleteMethod(resourceGroupName, routeFilterName, ruleName, option if (ruleName === null || ruleName === undefined || typeof ruleName.valueOf() !== 'string') { throw new Error('ruleName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -634,7 +628,7 @@ function _beginDeleteMethod(resourceGroupName, routeFilterName, ruleName, option requestUrl = requestUrl.replace('{ruleName}', encodeURIComponent(ruleName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -758,6 +752,7 @@ function _beginCreateOrUpdate(resourceGroupName, routeFilterName, ruleName, rout { routeFilterRuleParameters = {}; } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -772,9 +767,6 @@ function _beginCreateOrUpdate(resourceGroupName, routeFilterName, ruleName, rout if (routeFilterRuleParameters === null || routeFilterRuleParameters === undefined) { throw new Error('routeFilterRuleParameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -793,7 +785,7 @@ function _beginCreateOrUpdate(resourceGroupName, routeFilterName, ruleName, rout requestUrl = requestUrl.replace('{ruleName}', encodeURIComponent(ruleName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -959,6 +951,7 @@ function _beginUpdate(resourceGroupName, routeFilterName, ruleName, routeFilterR { routeFilterRuleParameters = {}; } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -973,9 +966,6 @@ function _beginUpdate(resourceGroupName, routeFilterName, ruleName, routeFilterR if (routeFilterRuleParameters === null || routeFilterRuleParameters === undefined) { throw new Error('routeFilterRuleParameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -994,7 +984,7 @@ function _beginUpdate(resourceGroupName, routeFilterName, ruleName, routeFilterR requestUrl = requestUrl.replace('{ruleName}', encodeURIComponent(ruleName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/routeFilters.js b/lib/services/networkManagement2/lib/operations/routeFilters.js index 3dc57d7eb0..504bcb10c1 100644 --- a/lib/services/networkManagement2/lib/operations/routeFilters.js +++ b/lib/services/networkManagement2/lib/operations/routeFilters.js @@ -116,6 +116,7 @@ function _get(resourceGroupName, routeFilterName, options, callback) { throw new Error('callback cannot be null.'); } let expand = (options && options.expand !== undefined) ? options.expand : undefined; + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -124,9 +125,6 @@ function _get(resourceGroupName, routeFilterName, options, callback) { if (routeFilterName === null || routeFilterName === undefined || typeof routeFilterName.valueOf() !== 'string') { throw new Error('routeFilterName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -147,7 +145,7 @@ function _get(resourceGroupName, routeFilterName, options, callback) { requestUrl = requestUrl.replace('{routeFilterName}', encodeURIComponent(routeFilterName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (expand !== null && expand !== undefined) { queryParameters.push('$expand=' + encodeURIComponent(expand)); } @@ -449,14 +447,12 @@ function _listByResourceGroup(resourceGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -473,7 +469,7 @@ function _listByResourceGroup(resourceGroupName, options, callback) { requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -586,11 +582,9 @@ function _list(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -606,7 +600,7 @@ function _list(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/routeFilters'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -722,6 +716,7 @@ function _beginDeleteMethod(resourceGroupName, routeFilterName, options, callbac if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -730,9 +725,6 @@ function _beginDeleteMethod(resourceGroupName, routeFilterName, options, callbac if (routeFilterName === null || routeFilterName === undefined || typeof routeFilterName.valueOf() !== 'string') { throw new Error('routeFilterName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -750,7 +742,7 @@ function _beginDeleteMethod(resourceGroupName, routeFilterName, options, callbac requestUrl = requestUrl.replace('{routeFilterName}', encodeURIComponent(routeFilterName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -865,6 +857,7 @@ function _beginCreateOrUpdate(resourceGroupName, routeFilterName, routeFilterPar if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -876,9 +869,6 @@ function _beginCreateOrUpdate(resourceGroupName, routeFilterName, routeFilterPar if (routeFilterParameters === null || routeFilterParameters === undefined) { throw new Error('routeFilterParameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -896,7 +886,7 @@ function _beginCreateOrUpdate(resourceGroupName, routeFilterName, routeFilterPar requestUrl = requestUrl.replace('{routeFilterName}', encodeURIComponent(routeFilterName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1057,6 +1047,7 @@ function _beginUpdate(resourceGroupName, routeFilterName, routeFilterParameters, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1068,9 +1059,6 @@ function _beginUpdate(resourceGroupName, routeFilterName, routeFilterParameters, if (routeFilterParameters === null || routeFilterParameters === undefined) { throw new Error('routeFilterParameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1088,7 +1076,7 @@ function _beginUpdate(resourceGroupName, routeFilterName, routeFilterParameters, requestUrl = requestUrl.replace('{routeFilterName}', encodeURIComponent(routeFilterName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/routeTables.js b/lib/services/networkManagement2/lib/operations/routeTables.js index 4a5ee2f20a..517f17c260 100644 --- a/lib/services/networkManagement2/lib/operations/routeTables.js +++ b/lib/services/networkManagement2/lib/operations/routeTables.js @@ -115,6 +115,7 @@ function _get(resourceGroupName, routeTableName, options, callback) { throw new Error('callback cannot be null.'); } let expand = (options && options.expand !== undefined) ? options.expand : undefined; + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -123,9 +124,6 @@ function _get(resourceGroupName, routeTableName, options, callback) { if (routeTableName === null || routeTableName === undefined || typeof routeTableName.valueOf() !== 'string') { throw new Error('routeTableName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -146,7 +144,7 @@ function _get(resourceGroupName, routeTableName, options, callback) { requestUrl = requestUrl.replace('{routeTableName}', encodeURIComponent(routeTableName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (expand !== null && expand !== undefined) { queryParameters.push('$expand=' + encodeURIComponent(expand)); } @@ -446,14 +444,12 @@ function _list(resourceGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -470,7 +466,7 @@ function _list(resourceGroupName, options, callback) { requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -583,11 +579,9 @@ function _listAll(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -603,7 +597,7 @@ function _listAll(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/routeTables'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -719,6 +713,7 @@ function _beginDeleteMethod(resourceGroupName, routeTableName, options, callback if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -727,9 +722,6 @@ function _beginDeleteMethod(resourceGroupName, routeTableName, options, callback if (routeTableName === null || routeTableName === undefined || typeof routeTableName.valueOf() !== 'string') { throw new Error('routeTableName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -747,7 +739,7 @@ function _beginDeleteMethod(resourceGroupName, routeTableName, options, callback requestUrl = requestUrl.replace('{routeTableName}', encodeURIComponent(routeTableName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -869,6 +861,7 @@ function _beginCreateOrUpdate(resourceGroupName, routeTableName, parameters, opt if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -880,9 +873,6 @@ function _beginCreateOrUpdate(resourceGroupName, routeTableName, parameters, opt if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -900,7 +890,7 @@ function _beginCreateOrUpdate(resourceGroupName, routeTableName, parameters, opt requestUrl = requestUrl.replace('{routeTableName}', encodeURIComponent(routeTableName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1052,6 +1042,7 @@ function _beginUpdateTags(resourceGroupName, routeTableName, parameters, options if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1063,9 +1054,6 @@ function _beginUpdateTags(resourceGroupName, routeTableName, parameters, options if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1083,7 +1071,7 @@ function _beginUpdateTags(resourceGroupName, routeTableName, parameters, options requestUrl = requestUrl.replace('{routeTableName}', encodeURIComponent(routeTableName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/routes.js b/lib/services/networkManagement2/lib/operations/routes.js index cdb3db5d01..4b6ef8a695 100644 --- a/lib/services/networkManagement2/lib/operations/routes.js +++ b/lib/services/networkManagement2/lib/operations/routes.js @@ -116,6 +116,7 @@ function _get(resourceGroupName, routeTableName, routeName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -127,9 +128,6 @@ function _get(resourceGroupName, routeTableName, routeName, options, callback) { if (routeName === null || routeName === undefined || typeof routeName.valueOf() !== 'string') { throw new Error('routeName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -148,7 +146,7 @@ function _get(resourceGroupName, routeTableName, routeName, options, callback) { requestUrl = requestUrl.replace('{routeName}', encodeURIComponent(routeName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -373,6 +371,7 @@ function _list(resourceGroupName, routeTableName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -381,9 +380,6 @@ function _list(resourceGroupName, routeTableName, options, callback) { if (routeTableName === null || routeTableName === undefined || typeof routeTableName.valueOf() !== 'string') { throw new Error('routeTableName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -401,7 +397,7 @@ function _list(resourceGroupName, routeTableName, options, callback) { requestUrl = requestUrl.replace('{routeTableName}', encodeURIComponent(routeTableName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -519,6 +515,7 @@ function _beginDeleteMethod(resourceGroupName, routeTableName, routeName, option if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -530,9 +527,6 @@ function _beginDeleteMethod(resourceGroupName, routeTableName, routeName, option if (routeName === null || routeName === undefined || typeof routeName.valueOf() !== 'string') { throw new Error('routeName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -551,7 +545,7 @@ function _beginDeleteMethod(resourceGroupName, routeTableName, routeName, option requestUrl = requestUrl.replace('{routeName}', encodeURIComponent(routeName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -681,6 +675,7 @@ function _beginCreateOrUpdate(resourceGroupName, routeTableName, routeName, rout if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -695,9 +690,6 @@ function _beginCreateOrUpdate(resourceGroupName, routeTableName, routeName, rout if (routeParameters === null || routeParameters === undefined) { throw new Error('routeParameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -716,7 +708,7 @@ function _beginCreateOrUpdate(resourceGroupName, routeTableName, routeName, rout requestUrl = requestUrl.replace('{routeName}', encodeURIComponent(routeName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/securityRules.js b/lib/services/networkManagement2/lib/operations/securityRules.js index a1ed0bc9bc..7fd121a9bf 100644 --- a/lib/services/networkManagement2/lib/operations/securityRules.js +++ b/lib/services/networkManagement2/lib/operations/securityRules.js @@ -118,6 +118,7 @@ function _get(resourceGroupName, networkSecurityGroupName, securityRuleName, opt if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -129,9 +130,6 @@ function _get(resourceGroupName, networkSecurityGroupName, securityRuleName, opt if (securityRuleName === null || securityRuleName === undefined || typeof securityRuleName.valueOf() !== 'string') { throw new Error('securityRuleName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -150,7 +148,7 @@ function _get(resourceGroupName, networkSecurityGroupName, securityRuleName, opt requestUrl = requestUrl.replace('{securityRuleName}', encodeURIComponent(securityRuleName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -424,6 +422,7 @@ function _list(resourceGroupName, networkSecurityGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -432,9 +431,6 @@ function _list(resourceGroupName, networkSecurityGroupName, options, callback) { if (networkSecurityGroupName === null || networkSecurityGroupName === undefined || typeof networkSecurityGroupName.valueOf() !== 'string') { throw new Error('networkSecurityGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -452,7 +448,7 @@ function _list(resourceGroupName, networkSecurityGroupName, options, callback) { requestUrl = requestUrl.replace('{networkSecurityGroupName}', encodeURIComponent(networkSecurityGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -571,6 +567,7 @@ function _beginDeleteMethod(resourceGroupName, networkSecurityGroupName, securit if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -582,9 +579,6 @@ function _beginDeleteMethod(resourceGroupName, networkSecurityGroupName, securit if (securityRuleName === null || securityRuleName === undefined || typeof securityRuleName.valueOf() !== 'string') { throw new Error('securityRuleName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -603,7 +597,7 @@ function _beginDeleteMethod(resourceGroupName, networkSecurityGroupName, securit requestUrl = requestUrl.replace('{securityRuleName}', encodeURIComponent(securityRuleName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -780,6 +774,7 @@ function _beginCreateOrUpdate(resourceGroupName, networkSecurityGroupName, secur if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -794,9 +789,6 @@ function _beginCreateOrUpdate(resourceGroupName, networkSecurityGroupName, secur if (securityRuleParameters === null || securityRuleParameters === undefined) { throw new Error('securityRuleParameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -815,7 +807,7 @@ function _beginCreateOrUpdate(resourceGroupName, networkSecurityGroupName, secur requestUrl = requestUrl.replace('{securityRuleName}', encodeURIComponent(securityRuleName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/subnets.js b/lib/services/networkManagement2/lib/operations/subnets.js index d0ba19ebaa..624a0eeae2 100644 --- a/lib/services/networkManagement2/lib/operations/subnets.js +++ b/lib/services/networkManagement2/lib/operations/subnets.js @@ -119,6 +119,7 @@ function _get(resourceGroupName, virtualNetworkName, subnetName, options, callba throw new Error('callback cannot be null.'); } let expand = (options && options.expand !== undefined) ? options.expand : undefined; + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -130,9 +131,6 @@ function _get(resourceGroupName, virtualNetworkName, subnetName, options, callba if (subnetName === null || subnetName === undefined || typeof subnetName.valueOf() !== 'string') { throw new Error('subnetName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -154,7 +152,7 @@ function _get(resourceGroupName, virtualNetworkName, subnetName, options, callba requestUrl = requestUrl.replace('{subnetName}', encodeURIComponent(subnetName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (expand !== null && expand !== undefined) { queryParameters.push('$expand=' + encodeURIComponent(expand)); } @@ -427,6 +425,7 @@ function _list(resourceGroupName, virtualNetworkName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -435,9 +434,6 @@ function _list(resourceGroupName, virtualNetworkName, options, callback) { if (virtualNetworkName === null || virtualNetworkName === undefined || typeof virtualNetworkName.valueOf() !== 'string') { throw new Error('virtualNetworkName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -455,7 +451,7 @@ function _list(resourceGroupName, virtualNetworkName, options, callback) { requestUrl = requestUrl.replace('{virtualNetworkName}', encodeURIComponent(virtualNetworkName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -573,6 +569,7 @@ function _beginDeleteMethod(resourceGroupName, virtualNetworkName, subnetName, o if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -584,9 +581,6 @@ function _beginDeleteMethod(resourceGroupName, virtualNetworkName, subnetName, o if (subnetName === null || subnetName === undefined || typeof subnetName.valueOf() !== 'string') { throw new Error('subnetName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -605,7 +599,7 @@ function _beginDeleteMethod(resourceGroupName, virtualNetworkName, subnetName, o requestUrl = requestUrl.replace('{subnetName}', encodeURIComponent(subnetName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -780,6 +774,7 @@ function _beginCreateOrUpdate(resourceGroupName, virtualNetworkName, subnetName, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -794,9 +789,6 @@ function _beginCreateOrUpdate(resourceGroupName, virtualNetworkName, subnetName, if (subnetParameters === null || subnetParameters === undefined) { throw new Error('subnetParameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -815,7 +807,7 @@ function _beginCreateOrUpdate(resourceGroupName, virtualNetworkName, subnetName, requestUrl = requestUrl.replace('{subnetName}', encodeURIComponent(subnetName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/usages.js b/lib/services/networkManagement2/lib/operations/usages.js index e3a083f0ba..fddfb0b8e2 100644 --- a/lib/services/networkManagement2/lib/operations/usages.js +++ b/lib/services/networkManagement2/lib/operations/usages.js @@ -47,6 +47,7 @@ function _list(location, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (location === null || location === undefined || typeof location.valueOf() !== 'string') { @@ -58,9 +59,6 @@ function _list(location, options, callback) { throw new Error('"location" should satisfy the constraint - "Pattern": /^[-\w\._]+$/'); } } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -77,7 +75,7 @@ function _list(location, options, callback) { requestUrl = requestUrl.replace('{location}', encodeURIComponent(location)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/virtualHubs.js b/lib/services/networkManagement2/lib/operations/virtualHubs.js new file mode 100644 index 0000000000..b4e5b81077 --- /dev/null +++ b/lib/services/networkManagement2/lib/operations/virtualHubs.js @@ -0,0 +1,2519 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const msRest = require('ms-rest'); +const msRestAzure = require('ms-rest-azure'); +const WebResource = msRest.WebResource; + +/** + * Retrieves the details of a VirtualHub. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualHub} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _get(resourceGroupName, virtualHubName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (virtualHubName === null || virtualHubName === undefined || typeof virtualHubName.valueOf() !== 'string') { + throw new Error('virtualHubName cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualHubs/{virtualHubName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{virtualHubName}', encodeURIComponent(virtualHubName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VirtualHub']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + + +/** + * Creates a VirtualHub resource if it doesn't exist else updates the existing + * VirtualHub. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} virtualHubParameters Parameters supplied to create or update + * VirtualHub. + * + * @param {object} [virtualHubParameters.virtualWan] The VirtualWAN to which + * the VirtualHub belongs + * + * @param {string} [virtualHubParameters.virtualWan.id] Resource ID. + * + * @param {array} [virtualHubParameters.hubVirtualNetworkConnections] list of + * all vnet connections with this VirtualHub. + * + * @param {string} [virtualHubParameters.addressPrefix] Address-prefix for this + * VirtualHub. + * + * @param {string} [virtualHubParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [virtualHubParameters.id] Resource ID. + * + * @param {string} [virtualHubParameters.location] Resource location. + * + * @param {object} [virtualHubParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualHub} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _createOrUpdate(resourceGroupName, virtualHubName, virtualHubParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginCreateOrUpdate(resourceGroupName, virtualHubName, virtualHubParameters, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VirtualHub']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + + return callback(null, result, httpRequest, response); + }); + }); +} + + +/** + * Updates VirtualHub tags. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} virtualHubParameters Parameters supplied to update + * VirtualHub tags. + * + * @param {object} [virtualHubParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualHub} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _updateTags(resourceGroupName, virtualHubName, virtualHubParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginUpdateTags(resourceGroupName, virtualHubName, virtualHubParameters, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VirtualHub']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + + return callback(null, result, httpRequest, response); + }); + }); +} + + +/** + * Deletes a VirtualHub. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _deleteMethod(resourceGroupName, virtualHubName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginDeleteMethod(resourceGroupName, virtualHubName, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + + return callback(null, result, httpRequest, response); + }); + }); +} + +/** + * Lists all the VirtualHubs in a resource group. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualHubsResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listByResourceGroup(resourceGroupName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualHubs'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVirtualHubsResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Lists all the VirtualHubs in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualHubsResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _list(options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/virtualHubs'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVirtualHubsResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Creates a VirtualHub resource if it doesn't exist else updates the existing + * VirtualHub. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} virtualHubParameters Parameters supplied to create or update + * VirtualHub. + * + * @param {object} [virtualHubParameters.virtualWan] The VirtualWAN to which + * the VirtualHub belongs + * + * @param {string} [virtualHubParameters.virtualWan.id] Resource ID. + * + * @param {array} [virtualHubParameters.hubVirtualNetworkConnections] list of + * all vnet connections with this VirtualHub. + * + * @param {string} [virtualHubParameters.addressPrefix] Address-prefix for this + * VirtualHub. + * + * @param {string} [virtualHubParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [virtualHubParameters.id] Resource ID. + * + * @param {string} [virtualHubParameters.location] Resource location. + * + * @param {object} [virtualHubParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualHub} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginCreateOrUpdate(resourceGroupName, virtualHubName, virtualHubParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (virtualHubName === null || virtualHubName === undefined || typeof virtualHubName.valueOf() !== 'string') { + throw new Error('virtualHubName cannot be null or undefined and it must be of type string.'); + } + if (virtualHubParameters === null || virtualHubParameters === undefined) { + throw new Error('virtualHubParameters cannot be null or undefined.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualHubs/{virtualHubName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{virtualHubName}', encodeURIComponent(virtualHubName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'PUT'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + // Serialize Request + let requestContent = null; + let requestModel = null; + try { + if (virtualHubParameters !== null && virtualHubParameters !== undefined) { + let requestModelMapper = new client.models['VirtualHub']().mapper(); + requestModel = client.serialize(requestModelMapper, virtualHubParameters, 'virtualHubParameters'); + requestContent = JSON.stringify(requestModel); + } + } catch (error) { + let serializationError = new Error(`Error "${error.message}" occurred in serializing the ` + + `payload - ${JSON.stringify(virtualHubParameters, null, 2)}.`); + return callback(serializationError); + } + httpRequest.body = requestContent; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 201) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VirtualHub']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + // Deserialize Response + if (statusCode === 201) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VirtualHub']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError1 = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError1.request = msRest.stripRequest(httpRequest); + deserializationError1.response = msRest.stripResponse(response); + return callback(deserializationError1); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Updates VirtualHub tags. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} virtualHubParameters Parameters supplied to update + * VirtualHub tags. + * + * @param {object} [virtualHubParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualHub} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginUpdateTags(resourceGroupName, virtualHubName, virtualHubParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (virtualHubName === null || virtualHubName === undefined || typeof virtualHubName.valueOf() !== 'string') { + throw new Error('virtualHubName cannot be null or undefined and it must be of type string.'); + } + if (virtualHubParameters === null || virtualHubParameters === undefined) { + throw new Error('virtualHubParameters cannot be null or undefined.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualHubs/{virtualHubName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{virtualHubName}', encodeURIComponent(virtualHubName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'PATCH'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + // Serialize Request + let requestContent = null; + let requestModel = null; + try { + if (virtualHubParameters !== null && virtualHubParameters !== undefined) { + let requestModelMapper = new client.models['TagsObject']().mapper(); + requestModel = client.serialize(requestModelMapper, virtualHubParameters, 'virtualHubParameters'); + requestContent = JSON.stringify(requestModel); + } + } catch (error) { + let serializationError = new Error(`Error "${error.message}" occurred in serializing the ` + + `payload - ${JSON.stringify(virtualHubParameters, null, 2)}.`); + return callback(serializationError); + } + httpRequest.body = requestContent; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 201) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VirtualHub']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + // Deserialize Response + if (statusCode === 201) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VirtualHub']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError1 = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError1.request = msRest.stripRequest(httpRequest); + deserializationError1.response = msRest.stripResponse(response); + return callback(deserializationError1); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Deletes a VirtualHub. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginDeleteMethod(resourceGroupName, virtualHubName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (virtualHubName === null || virtualHubName === undefined || typeof virtualHubName.valueOf() !== 'string') { + throw new Error('virtualHubName cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualHubs/{virtualHubName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{virtualHubName}', encodeURIComponent(virtualHubName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'DELETE'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 202 && statusCode !== 204) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Lists all the VirtualHubs in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualHubsResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listByResourceGroupNext(nextPageLink, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + // Validate + try { + if (nextPageLink === null || nextPageLink === undefined || typeof nextPageLink.valueOf() !== 'string') { + throw new Error('nextPageLink cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let requestUrl = '{nextLink}'; + requestUrl = requestUrl.replace('{nextLink}', nextPageLink); + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVirtualHubsResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Lists all the VirtualHubs in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualHubsResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listNext(nextPageLink, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + // Validate + try { + if (nextPageLink === null || nextPageLink === undefined || typeof nextPageLink.valueOf() !== 'string') { + throw new Error('nextPageLink cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let requestUrl = '{nextLink}'; + requestUrl = requestUrl.replace('{nextLink}', nextPageLink); + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVirtualHubsResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** Class representing a VirtualHubs. */ +class VirtualHubs { + /** + * Create a VirtualHubs. + * @param {NetworkManagementClient} client Reference to the service client. + */ + constructor(client) { + this.client = client; + this._get = _get; + this._createOrUpdate = _createOrUpdate; + this._updateTags = _updateTags; + this._deleteMethod = _deleteMethod; + this._listByResourceGroup = _listByResourceGroup; + this._list = _list; + this._beginCreateOrUpdate = _beginCreateOrUpdate; + this._beginUpdateTags = _beginUpdateTags; + this._beginDeleteMethod = _beginDeleteMethod; + this._listByResourceGroupNext = _listByResourceGroupNext; + this._listNext = _listNext; + } + + /** + * Retrieves the details of a VirtualHub. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName, virtualHubName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._get(resourceGroupName, virtualHubName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Retrieves the details of a VirtualHub. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VirtualHub} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualHub} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName, virtualHubName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._get(resourceGroupName, virtualHubName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._get(resourceGroupName, virtualHubName, options, optionalCallback); + } + } + + /** + * Creates a VirtualHub resource if it doesn't exist else updates the existing + * VirtualHub. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} virtualHubParameters Parameters supplied to create or update + * VirtualHub. + * + * @param {object} [virtualHubParameters.virtualWan] The VirtualWAN to which + * the VirtualHub belongs + * + * @param {string} [virtualHubParameters.virtualWan.id] Resource ID. + * + * @param {array} [virtualHubParameters.hubVirtualNetworkConnections] list of + * all vnet connections with this VirtualHub. + * + * @param {string} [virtualHubParameters.addressPrefix] Address-prefix for this + * VirtualHub. + * + * @param {string} [virtualHubParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [virtualHubParameters.id] Resource ID. + * + * @param {string} [virtualHubParameters.location] Resource location. + * + * @param {object} [virtualHubParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName, virtualHubName, virtualHubParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._createOrUpdate(resourceGroupName, virtualHubName, virtualHubParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Creates a VirtualHub resource if it doesn't exist else updates the existing + * VirtualHub. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} virtualHubParameters Parameters supplied to create or update + * VirtualHub. + * + * @param {object} [virtualHubParameters.virtualWan] The VirtualWAN to which + * the VirtualHub belongs + * + * @param {string} [virtualHubParameters.virtualWan.id] Resource ID. + * + * @param {array} [virtualHubParameters.hubVirtualNetworkConnections] list of + * all vnet connections with this VirtualHub. + * + * @param {string} [virtualHubParameters.addressPrefix] Address-prefix for this + * VirtualHub. + * + * @param {string} [virtualHubParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [virtualHubParameters.id] Resource ID. + * + * @param {string} [virtualHubParameters.location] Resource location. + * + * @param {object} [virtualHubParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VirtualHub} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualHub} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName, virtualHubName, virtualHubParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._createOrUpdate(resourceGroupName, virtualHubName, virtualHubParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._createOrUpdate(resourceGroupName, virtualHubName, virtualHubParameters, options, optionalCallback); + } + } + + /** + * Updates VirtualHub tags. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} virtualHubParameters Parameters supplied to update + * VirtualHub tags. + * + * @param {object} [virtualHubParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + updateTagsWithHttpOperationResponse(resourceGroupName, virtualHubName, virtualHubParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._updateTags(resourceGroupName, virtualHubName, virtualHubParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Updates VirtualHub tags. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} virtualHubParameters Parameters supplied to update + * VirtualHub tags. + * + * @param {object} [virtualHubParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VirtualHub} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualHub} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + updateTags(resourceGroupName, virtualHubName, virtualHubParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._updateTags(resourceGroupName, virtualHubName, virtualHubParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._updateTags(resourceGroupName, virtualHubName, virtualHubParameters, options, optionalCallback); + } + } + + /** + * Deletes a VirtualHub. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + deleteMethodWithHttpOperationResponse(resourceGroupName, virtualHubName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._deleteMethod(resourceGroupName, virtualHubName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Deletes a VirtualHub. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + deleteMethod(resourceGroupName, virtualHubName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._deleteMethod(resourceGroupName, virtualHubName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._deleteMethod(resourceGroupName, virtualHubName, options, optionalCallback); + } + } + + /** + * Lists all the VirtualHubs in a resource group. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listByResourceGroupWithHttpOperationResponse(resourceGroupName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listByResourceGroup(resourceGroupName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all the VirtualHubs in a resource group. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVirtualHubsResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualHubsResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listByResourceGroup(resourceGroupName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listByResourceGroup(resourceGroupName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listByResourceGroup(resourceGroupName, options, optionalCallback); + } + } + + /** + * Lists all the VirtualHubs in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listWithHttpOperationResponse(options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._list(options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all the VirtualHubs in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVirtualHubsResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualHubsResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + list(options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._list(options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._list(options, optionalCallback); + } + } + + /** + * Creates a VirtualHub resource if it doesn't exist else updates the existing + * VirtualHub. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} virtualHubParameters Parameters supplied to create or update + * VirtualHub. + * + * @param {object} [virtualHubParameters.virtualWan] The VirtualWAN to which + * the VirtualHub belongs + * + * @param {string} [virtualHubParameters.virtualWan.id] Resource ID. + * + * @param {array} [virtualHubParameters.hubVirtualNetworkConnections] list of + * all vnet connections with this VirtualHub. + * + * @param {string} [virtualHubParameters.addressPrefix] Address-prefix for this + * VirtualHub. + * + * @param {string} [virtualHubParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [virtualHubParameters.id] Resource ID. + * + * @param {string} [virtualHubParameters.location] Resource location. + * + * @param {object} [virtualHubParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName, virtualHubName, virtualHubParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginCreateOrUpdate(resourceGroupName, virtualHubName, virtualHubParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Creates a VirtualHub resource if it doesn't exist else updates the existing + * VirtualHub. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} virtualHubParameters Parameters supplied to create or update + * VirtualHub. + * + * @param {object} [virtualHubParameters.virtualWan] The VirtualWAN to which + * the VirtualHub belongs + * + * @param {string} [virtualHubParameters.virtualWan.id] Resource ID. + * + * @param {array} [virtualHubParameters.hubVirtualNetworkConnections] list of + * all vnet connections with this VirtualHub. + * + * @param {string} [virtualHubParameters.addressPrefix] Address-prefix for this + * VirtualHub. + * + * @param {string} [virtualHubParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [virtualHubParameters.id] Resource ID. + * + * @param {string} [virtualHubParameters.location] Resource location. + * + * @param {object} [virtualHubParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VirtualHub} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualHub} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginCreateOrUpdate(resourceGroupName, virtualHubName, virtualHubParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginCreateOrUpdate(resourceGroupName, virtualHubName, virtualHubParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginCreateOrUpdate(resourceGroupName, virtualHubName, virtualHubParameters, options, optionalCallback); + } + } + + /** + * Updates VirtualHub tags. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} virtualHubParameters Parameters supplied to update + * VirtualHub tags. + * + * @param {object} [virtualHubParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginUpdateTagsWithHttpOperationResponse(resourceGroupName, virtualHubName, virtualHubParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginUpdateTags(resourceGroupName, virtualHubName, virtualHubParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Updates VirtualHub tags. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} virtualHubParameters Parameters supplied to update + * VirtualHub tags. + * + * @param {object} [virtualHubParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VirtualHub} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualHub} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginUpdateTags(resourceGroupName, virtualHubName, virtualHubParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginUpdateTags(resourceGroupName, virtualHubName, virtualHubParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginUpdateTags(resourceGroupName, virtualHubName, virtualHubParameters, options, optionalCallback); + } + } + + /** + * Deletes a VirtualHub. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginDeleteMethodWithHttpOperationResponse(resourceGroupName, virtualHubName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginDeleteMethod(resourceGroupName, virtualHubName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Deletes a VirtualHub. + * + * @param {string} resourceGroupName The resource group name of the VirtualHub. + * + * @param {string} virtualHubName The name of the VirtualHub. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(resourceGroupName, virtualHubName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginDeleteMethod(resourceGroupName, virtualHubName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginDeleteMethod(resourceGroupName, virtualHubName, options, optionalCallback); + } + } + + /** + * Lists all the VirtualHubs in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listByResourceGroupNextWithHttpOperationResponse(nextPageLink, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listByResourceGroupNext(nextPageLink, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all the VirtualHubs in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVirtualHubsResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualHubsResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listByResourceGroupNext(nextPageLink, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listByResourceGroupNext(nextPageLink, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listByResourceGroupNext(nextPageLink, options, optionalCallback); + } + } + + /** + * Lists all the VirtualHubs in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listNext(nextPageLink, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all the VirtualHubs in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVirtualHubsResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualHubsResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listNext(nextPageLink, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listNext(nextPageLink, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listNext(nextPageLink, options, optionalCallback); + } + } + +} + +module.exports = VirtualHubs; diff --git a/lib/services/networkManagement2/lib/operations/virtualNetworkGatewayConnections.js b/lib/services/networkManagement2/lib/operations/virtualNetworkGatewayConnections.js index e40db35d68..44e00197cb 100644 --- a/lib/services/networkManagement2/lib/operations/virtualNetworkGatewayConnections.js +++ b/lib/services/networkManagement2/lib/operations/virtualNetworkGatewayConnections.js @@ -63,11 +63,13 @@ const WebResource = msRest.WebResource; * * @param {string} [parameters.virtualNetworkGateway2.sku.name] Gateway SKU * name. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * * @param {string} [parameters.virtualNetworkGateway2.sku.tier] Gateway SKU * tier. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * * @param {number} [parameters.virtualNetworkGateway2.sku.capacity] The * capacity. @@ -302,6 +304,7 @@ function _get(resourceGroupName, virtualNetworkGatewayConnectionName, options, c if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -310,9 +313,6 @@ function _get(resourceGroupName, virtualNetworkGatewayConnectionName, options, c if (virtualNetworkGatewayConnectionName === null || virtualNetworkGatewayConnectionName === undefined || typeof virtualNetworkGatewayConnectionName.valueOf() !== 'string') { throw new Error('virtualNetworkGatewayConnectionName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -330,7 +330,7 @@ function _get(resourceGroupName, virtualNetworkGatewayConnectionName, options, c requestUrl = requestUrl.replace('{virtualNetworkGatewayConnectionName}', encodeURIComponent(virtualNetworkGatewayConnectionName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -502,8 +502,8 @@ function _deleteMethod(resourceGroupName, virtualNetworkGatewayConnectionName, o * {Error} err - The Error object if an error occurred, null otherwise. * * {object} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGatewayConnectionListEntity} - * for more information. + * See {@link VirtualNetworkGatewayConnection} for more + * information. * * {object} [request] - The HTTP Request object if an error did not occur. * @@ -546,7 +546,7 @@ function _updateTags(resourceGroupName, virtualNetworkGatewayConnectionName, par parsedResponse = JSON.parse(responseBody); result = JSON.parse(responseBody); if (parsedResponse !== null && parsedResponse !== undefined) { - let resultMapper = new client.models['VirtualNetworkGatewayConnectionListEntity']().mapper(); + let resultMapper = new client.models['VirtualNetworkGatewayConnection']().mapper(); result = client.deserialize(resultMapper, parsedResponse, 'result'); } } catch (error) { @@ -580,6 +580,8 @@ function _updateTags(resourceGroupName, virtualNetworkGatewayConnectionName, par * @param {string} parameters.value The virtual network connection shared key * value. * + * @param {string} [parameters.id] Resource ID. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -688,6 +690,7 @@ function _getSharedKey(resourceGroupName, virtualNetworkGatewayConnectionName, o if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -696,9 +699,6 @@ function _getSharedKey(resourceGroupName, virtualNetworkGatewayConnectionName, o if (virtualNetworkGatewayConnectionName === null || virtualNetworkGatewayConnectionName === undefined || typeof virtualNetworkGatewayConnectionName.valueOf() !== 'string') { throw new Error('virtualNetworkGatewayConnectionName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -716,7 +716,7 @@ function _getSharedKey(resourceGroupName, virtualNetworkGatewayConnectionName, o requestUrl = requestUrl.replace('{virtualNetworkGatewayConnectionName}', encodeURIComponent(virtualNetworkGatewayConnectionName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -833,14 +833,12 @@ function _list(resourceGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -857,7 +855,7 @@ function _list(resourceGroupName, options, callback) { requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1077,11 +1075,13 @@ function _resetSharedKey(resourceGroupName, virtualNetworkGatewayConnectionName, * * @param {string} [parameters.virtualNetworkGateway2.sku.name] Gateway SKU * name. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * * @param {string} [parameters.virtualNetworkGateway2.sku.tier] Gateway SKU * tier. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * * @param {number} [parameters.virtualNetworkGateway2.sku.capacity] The * capacity. @@ -1237,6 +1237,7 @@ function _beginCreateOrUpdate(resourceGroupName, virtualNetworkGatewayConnection if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1248,9 +1249,6 @@ function _beginCreateOrUpdate(resourceGroupName, virtualNetworkGatewayConnection if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1268,7 +1266,7 @@ function _beginCreateOrUpdate(resourceGroupName, virtualNetworkGatewayConnection requestUrl = requestUrl.replace('{virtualNetworkGatewayConnectionName}', encodeURIComponent(virtualNetworkGatewayConnectionName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1416,6 +1414,7 @@ function _beginDeleteMethod(resourceGroupName, virtualNetworkGatewayConnectionNa if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1424,9 +1423,6 @@ function _beginDeleteMethod(resourceGroupName, virtualNetworkGatewayConnectionNa if (virtualNetworkGatewayConnectionName === null || virtualNetworkGatewayConnectionName === undefined || typeof virtualNetworkGatewayConnectionName.valueOf() !== 'string') { throw new Error('virtualNetworkGatewayConnectionName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1444,7 +1440,7 @@ function _beginDeleteMethod(resourceGroupName, virtualNetworkGatewayConnectionNa requestUrl = requestUrl.replace('{virtualNetworkGatewayConnectionName}', encodeURIComponent(virtualNetworkGatewayConnectionName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1534,8 +1530,8 @@ function _beginDeleteMethod(resourceGroupName, virtualNetworkGatewayConnectionNa * {Error} err - The Error object if an error occurred, null otherwise. * * {object} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGatewayConnectionListEntity} - * for more information. + * See {@link VirtualNetworkGatewayConnection} for more + * information. * * {object} [request] - The HTTP Request object if an error did not occur. * @@ -1551,6 +1547,7 @@ function _beginUpdateTags(resourceGroupName, virtualNetworkGatewayConnectionName if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1562,9 +1559,6 @@ function _beginUpdateTags(resourceGroupName, virtualNetworkGatewayConnectionName if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1582,7 +1576,7 @@ function _beginUpdateTags(resourceGroupName, virtualNetworkGatewayConnectionName requestUrl = requestUrl.replace('{virtualNetworkGatewayConnectionName}', encodeURIComponent(virtualNetworkGatewayConnectionName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1663,7 +1657,7 @@ function _beginUpdateTags(resourceGroupName, virtualNetworkGatewayConnectionName parsedResponse = JSON.parse(responseBody); result = JSON.parse(responseBody); if (parsedResponse !== null && parsedResponse !== undefined) { - let resultMapper = new client.models['VirtualNetworkGatewayConnectionListEntity']().mapper(); + let resultMapper = new client.models['VirtualNetworkGatewayConnection']().mapper(); result = client.deserialize(resultMapper, parsedResponse, 'result'); } } catch (error) { @@ -1696,6 +1690,8 @@ function _beginUpdateTags(resourceGroupName, virtualNetworkGatewayConnectionName * @param {string} parameters.value The virtual network connection shared key * value. * + * @param {string} [parameters.id] Resource ID. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -1724,6 +1720,7 @@ function _beginSetSharedKey(resourceGroupName, virtualNetworkGatewayConnectionNa if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1735,9 +1732,6 @@ function _beginSetSharedKey(resourceGroupName, virtualNetworkGatewayConnectionNa if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1755,7 +1749,7 @@ function _beginSetSharedKey(resourceGroupName, virtualNetworkGatewayConnectionNa requestUrl = requestUrl.replace('{virtualNetworkGatewayConnectionName}', encodeURIComponent(virtualNetworkGatewayConnectionName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1915,6 +1909,7 @@ function _beginResetSharedKey(resourceGroupName, virtualNetworkGatewayConnection if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1926,9 +1921,6 @@ function _beginResetSharedKey(resourceGroupName, virtualNetworkGatewayConnection if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1946,7 +1938,7 @@ function _beginResetSharedKey(resourceGroupName, virtualNetworkGatewayConnection requestUrl = requestUrl.replace('{virtualNetworkGatewayConnectionName}', encodeURIComponent(virtualNetworkGatewayConnectionName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2243,11 +2235,13 @@ class VirtualNetworkGatewayConnections { * * @param {string} [parameters.virtualNetworkGateway2.sku.name] Gateway SKU * name. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * * @param {string} [parameters.virtualNetworkGateway2.sku.tier] Gateway SKU * tier. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * * @param {number} [parameters.virtualNetworkGateway2.sku.capacity] The * capacity. @@ -2447,11 +2441,13 @@ class VirtualNetworkGatewayConnections { * * @param {string} [parameters.virtualNetworkGateway2.sku.name] Gateway SKU * name. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * * @param {string} [parameters.virtualNetworkGateway2.sku.tier] Gateway SKU * tier. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * * @param {number} [parameters.virtualNetworkGateway2.sku.capacity] The * capacity. @@ -2822,7 +2818,7 @@ class VirtualNetworkGatewayConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error} - The error object. */ @@ -2865,7 +2861,7 @@ class VirtualNetworkGatewayConnections { * * {Promise} A promise is returned * - * @resolve {VirtualNetworkGatewayConnectionListEntity} - The deserialized result object. + * @resolve {VirtualNetworkGatewayConnection} - The deserialized result object. * * @reject {Error} - The error object. * @@ -2874,8 +2870,8 @@ class VirtualNetworkGatewayConnections { * {Error} err - The Error object if an error occurred, null otherwise. * * {object} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGatewayConnectionListEntity} - * for more information. + * See {@link VirtualNetworkGatewayConnection} for more + * information. * * {object} [request] - The HTTP Request object if an error did not occur. * @@ -2919,6 +2915,8 @@ class VirtualNetworkGatewayConnections { * @param {string} parameters.value The virtual network connection shared key * value. * + * @param {string} [parameters.id] Resource ID. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -2962,6 +2960,8 @@ class VirtualNetworkGatewayConnections { * @param {string} parameters.value The virtual network connection shared key * value. * + * @param {string} [parameters.id] Resource ID. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -3343,11 +3343,13 @@ class VirtualNetworkGatewayConnections { * * @param {string} [parameters.virtualNetworkGateway2.sku.name] Gateway SKU * name. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * * @param {string} [parameters.virtualNetworkGateway2.sku.tier] Gateway SKU * tier. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * * @param {number} [parameters.virtualNetworkGateway2.sku.capacity] The * capacity. @@ -3547,11 +3549,13 @@ class VirtualNetworkGatewayConnections { * * @param {string} [parameters.virtualNetworkGateway2.sku.name] Gateway SKU * name. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * * @param {string} [parameters.virtualNetworkGateway2.sku.tier] Gateway SKU * tier. Possible values include: 'Basic', 'HighPerformance', 'Standard', - * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'UltraPerformance', 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', + * 'VpnGw3AZ', 'ErGw1AZ', 'ErGw2AZ', 'ErGw3AZ' * * @param {number} [parameters.virtualNetworkGateway2.sku.capacity] The * capacity. @@ -3833,7 +3837,7 @@ class VirtualNetworkGatewayConnections { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error} - The error object. */ @@ -3876,7 +3880,7 @@ class VirtualNetworkGatewayConnections { * * {Promise} A promise is returned * - * @resolve {VirtualNetworkGatewayConnectionListEntity} - The deserialized result object. + * @resolve {VirtualNetworkGatewayConnection} - The deserialized result object. * * @reject {Error} - The error object. * @@ -3885,8 +3889,8 @@ class VirtualNetworkGatewayConnections { * {Error} err - The Error object if an error occurred, null otherwise. * * {object} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkGatewayConnectionListEntity} - * for more information. + * See {@link VirtualNetworkGatewayConnection} for more + * information. * * {object} [request] - The HTTP Request object if an error did not occur. * @@ -3930,6 +3934,8 @@ class VirtualNetworkGatewayConnections { * @param {string} parameters.value The virtual network connection shared key * value. * + * @param {string} [parameters.id] Resource ID. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -3973,6 +3979,8 @@ class VirtualNetworkGatewayConnections { * @param {string} parameters.value The virtual network connection shared key * value. * + * @param {string} [parameters.id] Resource ID. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the diff --git a/lib/services/networkManagement2/lib/operations/virtualNetworkGateways.js b/lib/services/networkManagement2/lib/operations/virtualNetworkGateways.js index c649890237..f75d16fb1c 100644 --- a/lib/services/networkManagement2/lib/operations/virtualNetworkGateways.js +++ b/lib/services/networkManagement2/lib/operations/virtualNetworkGateways.js @@ -56,11 +56,13 @@ const WebResource = msRest.WebResource; * * @param {string} [parameters.sku.name] Gateway SKU name. Possible values * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * * @param {string} [parameters.sku.tier] Gateway SKU tier. Possible values * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * * @param {number} [parameters.sku.capacity] The capacity. * @@ -226,6 +228,7 @@ function _get(resourceGroupName, virtualNetworkGatewayName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -234,9 +237,6 @@ function _get(resourceGroupName, virtualNetworkGatewayName, options, callback) { if (virtualNetworkGatewayName === null || virtualNetworkGatewayName === undefined || typeof virtualNetworkGatewayName.valueOf() !== 'string') { throw new Error('virtualNetworkGatewayName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -254,7 +254,7 @@ function _get(resourceGroupName, virtualNetworkGatewayName, options, callback) { requestUrl = requestUrl.replace('{virtualNetworkGatewayName}', encodeURIComponent(virtualNetworkGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -518,14 +518,12 @@ function _list(resourceGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -542,7 +540,7 @@ function _list(resourceGroupName, options, callback) { requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -661,6 +659,7 @@ function _listConnections(resourceGroupName, virtualNetworkGatewayName, options, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -669,9 +668,6 @@ function _listConnections(resourceGroupName, virtualNetworkGatewayName, options, if (virtualNetworkGatewayName === null || virtualNetworkGatewayName === undefined || typeof virtualNetworkGatewayName.valueOf() !== 'string') { throw new Error('virtualNetworkGatewayName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -689,7 +685,7 @@ function _listConnections(resourceGroupName, virtualNetworkGatewayName, options, requestUrl = requestUrl.replace('{virtualNetworkGatewayName}', encodeURIComponent(virtualNetworkGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1268,6 +1264,7 @@ function _supportedVpnDevices(resourceGroupName, virtualNetworkGatewayName, opti if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1276,9 +1273,6 @@ function _supportedVpnDevices(resourceGroupName, virtualNetworkGatewayName, opti if (virtualNetworkGatewayName === null || virtualNetworkGatewayName === undefined || typeof virtualNetworkGatewayName.valueOf() !== 'string') { throw new Error('virtualNetworkGatewayName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1296,7 +1290,7 @@ function _supportedVpnDevices(resourceGroupName, virtualNetworkGatewayName, opti requestUrl = requestUrl.replace('{virtualNetworkGatewayName}', encodeURIComponent(virtualNetworkGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1793,6 +1787,7 @@ function _vpnDeviceConfigurationScript(resourceGroupName, virtualNetworkGatewayC if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1804,9 +1799,6 @@ function _vpnDeviceConfigurationScript(resourceGroupName, virtualNetworkGatewayC if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1824,7 +1816,7 @@ function _vpnDeviceConfigurationScript(resourceGroupName, virtualNetworkGatewayC requestUrl = requestUrl.replace('{virtualNetworkGatewayConnectionName}', encodeURIComponent(virtualNetworkGatewayConnectionName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1967,11 +1959,13 @@ function _vpnDeviceConfigurationScript(resourceGroupName, virtualNetworkGatewayC * * @param {string} [parameters.sku.name] Gateway SKU name. Possible values * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * * @param {string} [parameters.sku.tier] Gateway SKU tier. Possible values * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * * @param {number} [parameters.sku.capacity] The capacity. * @@ -2059,6 +2053,7 @@ function _beginCreateOrUpdate(resourceGroupName, virtualNetworkGatewayName, para if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2070,9 +2065,6 @@ function _beginCreateOrUpdate(resourceGroupName, virtualNetworkGatewayName, para if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2090,7 +2082,7 @@ function _beginCreateOrUpdate(resourceGroupName, virtualNetworkGatewayName, para requestUrl = requestUrl.replace('{virtualNetworkGatewayName}', encodeURIComponent(virtualNetworkGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2238,6 +2230,7 @@ function _beginDeleteMethod(resourceGroupName, virtualNetworkGatewayName, option if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2246,9 +2239,6 @@ function _beginDeleteMethod(resourceGroupName, virtualNetworkGatewayName, option if (virtualNetworkGatewayName === null || virtualNetworkGatewayName === undefined || typeof virtualNetworkGatewayName.valueOf() !== 'string') { throw new Error('virtualNetworkGatewayName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2266,7 +2256,7 @@ function _beginDeleteMethod(resourceGroupName, virtualNetworkGatewayName, option requestUrl = requestUrl.replace('{virtualNetworkGatewayName}', encodeURIComponent(virtualNetworkGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2372,6 +2362,7 @@ function _beginUpdateTags(resourceGroupName, virtualNetworkGatewayName, paramete if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2383,9 +2374,6 @@ function _beginUpdateTags(resourceGroupName, virtualNetworkGatewayName, paramete if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2403,7 +2391,7 @@ function _beginUpdateTags(resourceGroupName, virtualNetworkGatewayName, paramete requestUrl = requestUrl.replace('{virtualNetworkGatewayName}', encodeURIComponent(virtualNetworkGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2540,6 +2528,7 @@ function _beginReset(resourceGroupName, virtualNetworkGatewayName, options, call throw new Error('callback cannot be null.'); } let gatewayVip = (options && options.gatewayVip !== undefined) ? options.gatewayVip : undefined; + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2551,9 +2540,6 @@ function _beginReset(resourceGroupName, virtualNetworkGatewayName, options, call if (gatewayVip !== null && gatewayVip !== undefined && typeof gatewayVip.valueOf() !== 'string') { throw new Error('gatewayVip must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2574,7 +2560,7 @@ function _beginReset(resourceGroupName, virtualNetworkGatewayName, options, call if (gatewayVip !== null && gatewayVip !== undefined) { queryParameters.push('gatewayVip=' + encodeURIComponent(gatewayVip)); } - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2712,6 +2698,7 @@ function _beginGeneratevpnclientpackage(resourceGroupName, virtualNetworkGateway if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2723,9 +2710,6 @@ function _beginGeneratevpnclientpackage(resourceGroupName, virtualNetworkGateway if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2743,7 +2727,7 @@ function _beginGeneratevpnclientpackage(resourceGroupName, virtualNetworkGateway requestUrl = requestUrl.replace('{virtualNetworkGatewayName}', encodeURIComponent(virtualNetworkGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2901,6 +2885,7 @@ function _beginGenerateVpnProfile(resourceGroupName, virtualNetworkGatewayName, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -2912,9 +2897,6 @@ function _beginGenerateVpnProfile(resourceGroupName, virtualNetworkGatewayName, if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -2932,7 +2914,7 @@ function _beginGenerateVpnProfile(resourceGroupName, virtualNetworkGatewayName, requestUrl = requestUrl.replace('{virtualNetworkGatewayName}', encodeURIComponent(virtualNetworkGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -3071,6 +3053,7 @@ function _beginGetVpnProfilePackageUrl(resourceGroupName, virtualNetworkGatewayN if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -3079,9 +3062,6 @@ function _beginGetVpnProfilePackageUrl(resourceGroupName, virtualNetworkGatewayN if (virtualNetworkGatewayName === null || virtualNetworkGatewayName === undefined || typeof virtualNetworkGatewayName.valueOf() !== 'string') { throw new Error('virtualNetworkGatewayName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -3099,7 +3079,7 @@ function _beginGetVpnProfilePackageUrl(resourceGroupName, virtualNetworkGatewayN requestUrl = requestUrl.replace('{virtualNetworkGatewayName}', encodeURIComponent(virtualNetworkGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -3228,6 +3208,7 @@ function _beginGetBgpPeerStatus(resourceGroupName, virtualNetworkGatewayName, op throw new Error('callback cannot be null.'); } let peer = (options && options.peer !== undefined) ? options.peer : undefined; + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -3239,9 +3220,6 @@ function _beginGetBgpPeerStatus(resourceGroupName, virtualNetworkGatewayName, op if (peer !== null && peer !== undefined && typeof peer.valueOf() !== 'string') { throw new Error('peer must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -3262,7 +3240,7 @@ function _beginGetBgpPeerStatus(resourceGroupName, virtualNetworkGatewayName, op if (peer !== null && peer !== undefined) { queryParameters.push('peer=' + encodeURIComponent(peer)); } - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -3382,6 +3360,7 @@ function _beginGetLearnedRoutes(resourceGroupName, virtualNetworkGatewayName, op if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -3390,9 +3369,6 @@ function _beginGetLearnedRoutes(resourceGroupName, virtualNetworkGatewayName, op if (virtualNetworkGatewayName === null || virtualNetworkGatewayName === undefined || typeof virtualNetworkGatewayName.valueOf() !== 'string') { throw new Error('virtualNetworkGatewayName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -3410,7 +3386,7 @@ function _beginGetLearnedRoutes(resourceGroupName, virtualNetworkGatewayName, op requestUrl = requestUrl.replace('{virtualNetworkGatewayName}', encodeURIComponent(virtualNetworkGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -3532,6 +3508,7 @@ function _beginGetAdvertisedRoutes(resourceGroupName, virtualNetworkGatewayName, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -3543,9 +3520,6 @@ function _beginGetAdvertisedRoutes(resourceGroupName, virtualNetworkGatewayName, if (peer === null || peer === undefined || typeof peer.valueOf() !== 'string') { throw new Error('peer cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -3564,7 +3538,7 @@ function _beginGetAdvertisedRoutes(resourceGroupName, virtualNetworkGatewayName, requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; queryParameters.push('peer=' + encodeURIComponent(peer)); - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -3721,6 +3695,7 @@ function _beginSetVpnclientIpsecParameters(resourceGroupName, virtualNetworkGate if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -3732,9 +3707,6 @@ function _beginSetVpnclientIpsecParameters(resourceGroupName, virtualNetworkGate if (vpnclientIpsecParams === null || vpnclientIpsecParams === undefined) { throw new Error('vpnclientIpsecParams cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -3752,7 +3724,7 @@ function _beginSetVpnclientIpsecParameters(resourceGroupName, virtualNetworkGate requestUrl = requestUrl.replace('{virtualNetworkGatewayName}', encodeURIComponent(virtualNetworkGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -3886,6 +3858,7 @@ function _beginGetVpnclientIpsecParameters(resourceGroupName, virtualNetworkGate if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -3894,9 +3867,6 @@ function _beginGetVpnclientIpsecParameters(resourceGroupName, virtualNetworkGate if (virtualNetworkGatewayName === null || virtualNetworkGatewayName === undefined || typeof virtualNetworkGatewayName.valueOf() !== 'string') { throw new Error('virtualNetworkGatewayName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -3914,7 +3884,7 @@ function _beginGetVpnclientIpsecParameters(resourceGroupName, virtualNetworkGate requestUrl = requestUrl.replace('{virtualNetworkGatewayName}', encodeURIComponent(virtualNetworkGatewayName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -4334,11 +4304,13 @@ class VirtualNetworkGateways { * * @param {string} [parameters.sku.name] Gateway SKU name. Possible values * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * * @param {string} [parameters.sku.tier] Gateway SKU tier. Possible values * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * * @param {number} [parameters.sku.capacity] The capacity. * @@ -4464,11 +4436,13 @@ class VirtualNetworkGateways { * * @param {string} [parameters.sku.name] Gateway SKU name. Possible values * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * * @param {string} [parameters.sku.tier] Gateway SKU tier. Possible values * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * * @param {number} [parameters.sku.capacity] The capacity. * @@ -6239,11 +6213,13 @@ class VirtualNetworkGateways { * * @param {string} [parameters.sku.name] Gateway SKU name. Possible values * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * * @param {string} [parameters.sku.tier] Gateway SKU tier. Possible values * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * * @param {number} [parameters.sku.capacity] The capacity. * @@ -6369,11 +6345,13 @@ class VirtualNetworkGateways { * * @param {string} [parameters.sku.name] Gateway SKU name. Possible values * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * * @param {string} [parameters.sku.tier] Gateway SKU tier. Possible values * include: 'Basic', 'HighPerformance', 'Standard', 'UltraPerformance', - * 'VpnGw1', 'VpnGw2', 'VpnGw3' + * 'VpnGw1', 'VpnGw2', 'VpnGw3', 'VpnGw1AZ', 'VpnGw2AZ', 'VpnGw3AZ', 'ErGw1AZ', + * 'ErGw2AZ', 'ErGw3AZ' * * @param {number} [parameters.sku.capacity] The capacity. * diff --git a/lib/services/networkManagement2/lib/operations/virtualNetworkPeerings.js b/lib/services/networkManagement2/lib/operations/virtualNetworkPeerings.js index 2bf0999f6b..5e2bfeb81f 100644 --- a/lib/services/networkManagement2/lib/operations/virtualNetworkPeerings.js +++ b/lib/services/networkManagement2/lib/operations/virtualNetworkPeerings.js @@ -118,6 +118,7 @@ function _get(resourceGroupName, virtualNetworkName, virtualNetworkPeeringName, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -129,9 +130,6 @@ function _get(resourceGroupName, virtualNetworkName, virtualNetworkPeeringName, if (virtualNetworkPeeringName === null || virtualNetworkPeeringName === undefined || typeof virtualNetworkPeeringName.valueOf() !== 'string') { throw new Error('virtualNetworkPeeringName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -150,7 +148,7 @@ function _get(resourceGroupName, virtualNetworkName, virtualNetworkPeeringName, requestUrl = requestUrl.replace('{virtualNetworkPeeringName}', encodeURIComponent(virtualNetworkPeeringName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -403,6 +401,7 @@ function _list(resourceGroupName, virtualNetworkName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -411,9 +410,6 @@ function _list(resourceGroupName, virtualNetworkName, options, callback) { if (virtualNetworkName === null || virtualNetworkName === undefined || typeof virtualNetworkName.valueOf() !== 'string') { throw new Error('virtualNetworkName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -431,7 +427,7 @@ function _list(resourceGroupName, virtualNetworkName, options, callback) { requestUrl = requestUrl.replace('{virtualNetworkName}', encodeURIComponent(virtualNetworkName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -550,6 +546,7 @@ function _beginDeleteMethod(resourceGroupName, virtualNetworkName, virtualNetwor if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -561,9 +558,6 @@ function _beginDeleteMethod(resourceGroupName, virtualNetworkName, virtualNetwor if (virtualNetworkPeeringName === null || virtualNetworkPeeringName === undefined || typeof virtualNetworkPeeringName.valueOf() !== 'string') { throw new Error('virtualNetworkPeeringName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -582,7 +576,7 @@ function _beginDeleteMethod(resourceGroupName, virtualNetworkName, virtualNetwor requestUrl = requestUrl.replace('{virtualNetworkPeeringName}', encodeURIComponent(virtualNetworkPeeringName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -739,6 +733,7 @@ function _beginCreateOrUpdate(resourceGroupName, virtualNetworkName, virtualNetw if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -753,9 +748,6 @@ function _beginCreateOrUpdate(resourceGroupName, virtualNetworkName, virtualNetw if (virtualNetworkPeeringParameters === null || virtualNetworkPeeringParameters === undefined) { throw new Error('virtualNetworkPeeringParameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -774,7 +766,7 @@ function _beginCreateOrUpdate(resourceGroupName, virtualNetworkName, virtualNetw requestUrl = requestUrl.replace('{virtualNetworkPeeringName}', encodeURIComponent(virtualNetworkPeeringName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/virtualNetworks.js b/lib/services/networkManagement2/lib/operations/virtualNetworks.js index 412ea8f563..e2c13908cc 100644 --- a/lib/services/networkManagement2/lib/operations/virtualNetworks.js +++ b/lib/services/networkManagement2/lib/operations/virtualNetworks.js @@ -115,6 +115,7 @@ function _get(resourceGroupName, virtualNetworkName, options, callback) { throw new Error('callback cannot be null.'); } let expand = (options && options.expand !== undefined) ? options.expand : undefined; + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -123,9 +124,6 @@ function _get(resourceGroupName, virtualNetworkName, options, callback) { if (virtualNetworkName === null || virtualNetworkName === undefined || typeof virtualNetworkName.valueOf() !== 'string') { throw new Error('virtualNetworkName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -146,7 +144,7 @@ function _get(resourceGroupName, virtualNetworkName, options, callback) { requestUrl = requestUrl.replace('{virtualNetworkName}', encodeURIComponent(virtualNetworkName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (expand !== null && expand !== undefined) { queryParameters.push('$expand=' + encodeURIComponent(expand)); } @@ -472,11 +470,9 @@ function _listAll(options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -492,7 +488,7 @@ function _listAll(options, callback) { let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/virtualNetworks'; requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -608,14 +604,12 @@ function _list(resourceGroupName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -632,7 +626,7 @@ function _list(resourceGroupName, options, callback) { requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -753,6 +747,7 @@ function _checkIPAddressAvailability(resourceGroupName, virtualNetworkName, opti throw new Error('callback cannot be null.'); } let ipAddress = (options && options.ipAddress !== undefined) ? options.ipAddress : undefined; + let apiVersion = '2018-06-01'; // Validate try { if (ipAddress !== null && ipAddress !== undefined && typeof ipAddress.valueOf() !== 'string') { @@ -764,9 +759,6 @@ function _checkIPAddressAvailability(resourceGroupName, virtualNetworkName, opti if (virtualNetworkName === null || virtualNetworkName === undefined || typeof virtualNetworkName.valueOf() !== 'string') { throw new Error('virtualNetworkName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -787,7 +779,7 @@ function _checkIPAddressAvailability(resourceGroupName, virtualNetworkName, opti if (ipAddress !== null && ipAddress !== undefined) { queryParameters.push('ipAddress=' + encodeURIComponent(ipAddress)); } - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -905,6 +897,7 @@ function _listUsage(resourceGroupName, virtualNetworkName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -913,9 +906,6 @@ function _listUsage(resourceGroupName, virtualNetworkName, options, callback) { if (virtualNetworkName === null || virtualNetworkName === undefined || typeof virtualNetworkName.valueOf() !== 'string') { throw new Error('virtualNetworkName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -933,7 +923,7 @@ function _listUsage(resourceGroupName, virtualNetworkName, options, callback) { requestUrl = requestUrl.replace('{virtualNetworkName}', encodeURIComponent(virtualNetworkName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1049,6 +1039,7 @@ function _beginDeleteMethod(resourceGroupName, virtualNetworkName, options, call if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1057,9 +1048,6 @@ function _beginDeleteMethod(resourceGroupName, virtualNetworkName, options, call if (virtualNetworkName === null || virtualNetworkName === undefined || typeof virtualNetworkName.valueOf() !== 'string') { throw new Error('virtualNetworkName cannot be null or undefined and it must be of type string.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1077,7 +1065,7 @@ function _beginDeleteMethod(resourceGroupName, virtualNetworkName, options, call requestUrl = requestUrl.replace('{virtualNetworkName}', encodeURIComponent(virtualNetworkName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1225,6 +1213,7 @@ function _beginCreateOrUpdate(resourceGroupName, virtualNetworkName, parameters, if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1236,9 +1225,6 @@ function _beginCreateOrUpdate(resourceGroupName, virtualNetworkName, parameters, if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1256,7 +1242,7 @@ function _beginCreateOrUpdate(resourceGroupName, virtualNetworkName, parameters, requestUrl = requestUrl.replace('{virtualNetworkName}', encodeURIComponent(virtualNetworkName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1409,6 +1395,7 @@ function _beginUpdateTags(resourceGroupName, virtualNetworkName, parameters, opt if (!callback) { throw new Error('callback cannot be null.'); } + let apiVersion = '2018-06-01'; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -1420,9 +1407,6 @@ function _beginUpdateTags(resourceGroupName, virtualNetworkName, parameters, opt if (parameters === null || parameters === undefined) { throw new Error('parameters cannot be null or undefined.'); } - if (this.client.apiVersion === null || this.client.apiVersion === undefined || typeof this.client.apiVersion.valueOf() !== 'string') { - throw new Error('this.client.apiVersion cannot be null or undefined and it must be of type string.'); - } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } @@ -1440,7 +1424,7 @@ function _beginUpdateTags(resourceGroupName, virtualNetworkName, parameters, opt requestUrl = requestUrl.replace('{virtualNetworkName}', encodeURIComponent(virtualNetworkName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; - queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } diff --git a/lib/services/networkManagement2/lib/operations/virtualWANs.js b/lib/services/networkManagement2/lib/operations/virtualWANs.js new file mode 100644 index 0000000000..27a5a3b901 --- /dev/null +++ b/lib/services/networkManagement2/lib/operations/virtualWANs.js @@ -0,0 +1,2471 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const msRest = require('ms-rest'); +const msRestAzure = require('ms-rest-azure'); +const WebResource = msRest.WebResource; + +/** + * Retrieves the details of a VirtualWAN. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being retrieved. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualWAN} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _get(resourceGroupName, virtualWANName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (virtualWANName === null || virtualWANName === undefined || typeof virtualWANName.valueOf() !== 'string') { + throw new Error('virtualWANName cannot be null or undefined and it must be of type string.'); + } + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualWans/{VirtualWANName}'; + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{VirtualWANName}', encodeURIComponent(virtualWANName)); + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VirtualWAN']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + + +/** + * Creates a VirtualWAN resource if it doesn't exist else updates the existing + * VirtualWAN. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being created or + * updated. + * + * @param {object} wANParameters Parameters supplied to create or update + * VirtualWAN. + * + * @param {boolean} [wANParameters.disableVpnEncryption] Vpn encryption to be + * disabled or not. + * + * @param {string} [wANParameters.provisioningState] The provisioning state of + * the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * + * @param {string} [wANParameters.id] Resource ID. + * + * @param {string} [wANParameters.location] Resource location. + * + * @param {object} [wANParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualWAN} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _createOrUpdate(resourceGroupName, virtualWANName, wANParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginCreateOrUpdate(resourceGroupName, virtualWANName, wANParameters, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VirtualWAN']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + + return callback(null, result, httpRequest, response); + }); + }); +} + + +/** + * Updates a VirtualWAN tags. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being updated. + * + * @param {object} wANParameters Parameters supplied to Update VirtualWAN tags. + * + * @param {object} [wANParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualWAN} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _updateTags(resourceGroupName, virtualWANName, wANParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginUpdateTags(resourceGroupName, virtualWANName, wANParameters, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VirtualWAN']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + + return callback(null, result, httpRequest, response); + }); + }); +} + + +/** + * Deletes a VirtualWAN. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being deleted. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _deleteMethod(resourceGroupName, virtualWANName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginDeleteMethod(resourceGroupName, virtualWANName, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + + return callback(null, result, httpRequest, response); + }); + }); +} + +/** + * Lists all the VirtualWANs in a resource group. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualWANsResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listByResourceGroup(resourceGroupName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualWans'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVirtualWANsResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Lists all the VirtualWANs in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualWANsResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _list(options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/virtualWans'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVirtualWANsResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Creates a VirtualWAN resource if it doesn't exist else updates the existing + * VirtualWAN. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being created or + * updated. + * + * @param {object} wANParameters Parameters supplied to create or update + * VirtualWAN. + * + * @param {boolean} [wANParameters.disableVpnEncryption] Vpn encryption to be + * disabled or not. + * + * @param {string} [wANParameters.provisioningState] The provisioning state of + * the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * + * @param {string} [wANParameters.id] Resource ID. + * + * @param {string} [wANParameters.location] Resource location. + * + * @param {object} [wANParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualWAN} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginCreateOrUpdate(resourceGroupName, virtualWANName, wANParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (virtualWANName === null || virtualWANName === undefined || typeof virtualWANName.valueOf() !== 'string') { + throw new Error('virtualWANName cannot be null or undefined and it must be of type string.'); + } + if (wANParameters === null || wANParameters === undefined) { + throw new Error('wANParameters cannot be null or undefined.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualWans/{VirtualWANName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{VirtualWANName}', encodeURIComponent(virtualWANName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'PUT'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + // Serialize Request + let requestContent = null; + let requestModel = null; + try { + if (wANParameters !== null && wANParameters !== undefined) { + let requestModelMapper = new client.models['VirtualWAN']().mapper(); + requestModel = client.serialize(requestModelMapper, wANParameters, 'wANParameters'); + requestContent = JSON.stringify(requestModel); + } + } catch (error) { + let serializationError = new Error(`Error "${error.message}" occurred in serializing the ` + + `payload - ${JSON.stringify(wANParameters, null, 2)}.`); + return callback(serializationError); + } + httpRequest.body = requestContent; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 201) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VirtualWAN']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + // Deserialize Response + if (statusCode === 201) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VirtualWAN']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError1 = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError1.request = msRest.stripRequest(httpRequest); + deserializationError1.response = msRest.stripResponse(response); + return callback(deserializationError1); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Updates a VirtualWAN tags. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being updated. + * + * @param {object} wANParameters Parameters supplied to Update VirtualWAN tags. + * + * @param {object} [wANParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualWAN} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginUpdateTags(resourceGroupName, virtualWANName, wANParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (virtualWANName === null || virtualWANName === undefined || typeof virtualWANName.valueOf() !== 'string') { + throw new Error('virtualWANName cannot be null or undefined and it must be of type string.'); + } + if (wANParameters === null || wANParameters === undefined) { + throw new Error('wANParameters cannot be null or undefined.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualWans/{VirtualWANName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{VirtualWANName}', encodeURIComponent(virtualWANName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'PATCH'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + // Serialize Request + let requestContent = null; + let requestModel = null; + try { + if (wANParameters !== null && wANParameters !== undefined) { + let requestModelMapper = new client.models['TagsObject']().mapper(); + requestModel = client.serialize(requestModelMapper, wANParameters, 'wANParameters'); + requestContent = JSON.stringify(requestModel); + } + } catch (error) { + let serializationError = new Error(`Error "${error.message}" occurred in serializing the ` + + `payload - ${JSON.stringify(wANParameters, null, 2)}.`); + return callback(serializationError); + } + httpRequest.body = requestContent; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 201) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VirtualWAN']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + // Deserialize Response + if (statusCode === 201) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VirtualWAN']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError1 = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError1.request = msRest.stripRequest(httpRequest); + deserializationError1.response = msRest.stripResponse(response); + return callback(deserializationError1); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Deletes a VirtualWAN. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being deleted. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginDeleteMethod(resourceGroupName, virtualWANName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (virtualWANName === null || virtualWANName === undefined || typeof virtualWANName.valueOf() !== 'string') { + throw new Error('virtualWANName cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualWans/{VirtualWANName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{VirtualWANName}', encodeURIComponent(virtualWANName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'DELETE'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 202 && statusCode !== 204) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Lists all the VirtualWANs in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualWANsResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listByResourceGroupNext(nextPageLink, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + // Validate + try { + if (nextPageLink === null || nextPageLink === undefined || typeof nextPageLink.valueOf() !== 'string') { + throw new Error('nextPageLink cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let requestUrl = '{nextLink}'; + requestUrl = requestUrl.replace('{nextLink}', nextPageLink); + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVirtualWANsResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Lists all the VirtualWANs in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualWANsResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listNext(nextPageLink, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + // Validate + try { + if (nextPageLink === null || nextPageLink === undefined || typeof nextPageLink.valueOf() !== 'string') { + throw new Error('nextPageLink cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let requestUrl = '{nextLink}'; + requestUrl = requestUrl.replace('{nextLink}', nextPageLink); + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVirtualWANsResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** Class representing a VirtualWANs. */ +class VirtualWANs { + /** + * Create a VirtualWANs. + * @param {NetworkManagementClient} client Reference to the service client. + */ + constructor(client) { + this.client = client; + this._get = _get; + this._createOrUpdate = _createOrUpdate; + this._updateTags = _updateTags; + this._deleteMethod = _deleteMethod; + this._listByResourceGroup = _listByResourceGroup; + this._list = _list; + this._beginCreateOrUpdate = _beginCreateOrUpdate; + this._beginUpdateTags = _beginUpdateTags; + this._beginDeleteMethod = _beginDeleteMethod; + this._listByResourceGroupNext = _listByResourceGroupNext; + this._listNext = _listNext; + } + + /** + * Retrieves the details of a VirtualWAN. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being retrieved. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName, virtualWANName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._get(resourceGroupName, virtualWANName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Retrieves the details of a VirtualWAN. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being retrieved. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VirtualWAN} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualWAN} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName, virtualWANName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._get(resourceGroupName, virtualWANName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._get(resourceGroupName, virtualWANName, options, optionalCallback); + } + } + + /** + * Creates a VirtualWAN resource if it doesn't exist else updates the existing + * VirtualWAN. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being created or + * updated. + * + * @param {object} wANParameters Parameters supplied to create or update + * VirtualWAN. + * + * @param {boolean} [wANParameters.disableVpnEncryption] Vpn encryption to be + * disabled or not. + * + * @param {string} [wANParameters.provisioningState] The provisioning state of + * the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * + * @param {string} [wANParameters.id] Resource ID. + * + * @param {string} [wANParameters.location] Resource location. + * + * @param {object} [wANParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName, virtualWANName, wANParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._createOrUpdate(resourceGroupName, virtualWANName, wANParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Creates a VirtualWAN resource if it doesn't exist else updates the existing + * VirtualWAN. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being created or + * updated. + * + * @param {object} wANParameters Parameters supplied to create or update + * VirtualWAN. + * + * @param {boolean} [wANParameters.disableVpnEncryption] Vpn encryption to be + * disabled or not. + * + * @param {string} [wANParameters.provisioningState] The provisioning state of + * the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * + * @param {string} [wANParameters.id] Resource ID. + * + * @param {string} [wANParameters.location] Resource location. + * + * @param {object} [wANParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VirtualWAN} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualWAN} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName, virtualWANName, wANParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._createOrUpdate(resourceGroupName, virtualWANName, wANParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._createOrUpdate(resourceGroupName, virtualWANName, wANParameters, options, optionalCallback); + } + } + + /** + * Updates a VirtualWAN tags. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being updated. + * + * @param {object} wANParameters Parameters supplied to Update VirtualWAN tags. + * + * @param {object} [wANParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + updateTagsWithHttpOperationResponse(resourceGroupName, virtualWANName, wANParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._updateTags(resourceGroupName, virtualWANName, wANParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Updates a VirtualWAN tags. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being updated. + * + * @param {object} wANParameters Parameters supplied to Update VirtualWAN tags. + * + * @param {object} [wANParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VirtualWAN} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualWAN} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + updateTags(resourceGroupName, virtualWANName, wANParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._updateTags(resourceGroupName, virtualWANName, wANParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._updateTags(resourceGroupName, virtualWANName, wANParameters, options, optionalCallback); + } + } + + /** + * Deletes a VirtualWAN. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being deleted. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + deleteMethodWithHttpOperationResponse(resourceGroupName, virtualWANName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._deleteMethod(resourceGroupName, virtualWANName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Deletes a VirtualWAN. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being deleted. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + deleteMethod(resourceGroupName, virtualWANName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._deleteMethod(resourceGroupName, virtualWANName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._deleteMethod(resourceGroupName, virtualWANName, options, optionalCallback); + } + } + + /** + * Lists all the VirtualWANs in a resource group. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listByResourceGroupWithHttpOperationResponse(resourceGroupName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listByResourceGroup(resourceGroupName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all the VirtualWANs in a resource group. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVirtualWANsResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualWANsResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listByResourceGroup(resourceGroupName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listByResourceGroup(resourceGroupName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listByResourceGroup(resourceGroupName, options, optionalCallback); + } + } + + /** + * Lists all the VirtualWANs in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listWithHttpOperationResponse(options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._list(options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all the VirtualWANs in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVirtualWANsResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualWANsResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + list(options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._list(options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._list(options, optionalCallback); + } + } + + /** + * Creates a VirtualWAN resource if it doesn't exist else updates the existing + * VirtualWAN. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being created or + * updated. + * + * @param {object} wANParameters Parameters supplied to create or update + * VirtualWAN. + * + * @param {boolean} [wANParameters.disableVpnEncryption] Vpn encryption to be + * disabled or not. + * + * @param {string} [wANParameters.provisioningState] The provisioning state of + * the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * + * @param {string} [wANParameters.id] Resource ID. + * + * @param {string} [wANParameters.location] Resource location. + * + * @param {object} [wANParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName, virtualWANName, wANParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginCreateOrUpdate(resourceGroupName, virtualWANName, wANParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Creates a VirtualWAN resource if it doesn't exist else updates the existing + * VirtualWAN. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being created or + * updated. + * + * @param {object} wANParameters Parameters supplied to create or update + * VirtualWAN. + * + * @param {boolean} [wANParameters.disableVpnEncryption] Vpn encryption to be + * disabled or not. + * + * @param {string} [wANParameters.provisioningState] The provisioning state of + * the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', + * 'Failed' + * + * @param {string} [wANParameters.id] Resource ID. + * + * @param {string} [wANParameters.location] Resource location. + * + * @param {object} [wANParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VirtualWAN} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualWAN} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginCreateOrUpdate(resourceGroupName, virtualWANName, wANParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginCreateOrUpdate(resourceGroupName, virtualWANName, wANParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginCreateOrUpdate(resourceGroupName, virtualWANName, wANParameters, options, optionalCallback); + } + } + + /** + * Updates a VirtualWAN tags. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being updated. + * + * @param {object} wANParameters Parameters supplied to Update VirtualWAN tags. + * + * @param {object} [wANParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginUpdateTagsWithHttpOperationResponse(resourceGroupName, virtualWANName, wANParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginUpdateTags(resourceGroupName, virtualWANName, wANParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Updates a VirtualWAN tags. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being updated. + * + * @param {object} wANParameters Parameters supplied to Update VirtualWAN tags. + * + * @param {object} [wANParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VirtualWAN} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualWAN} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginUpdateTags(resourceGroupName, virtualWANName, wANParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginUpdateTags(resourceGroupName, virtualWANName, wANParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginUpdateTags(resourceGroupName, virtualWANName, wANParameters, options, optionalCallback); + } + } + + /** + * Deletes a VirtualWAN. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being deleted. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginDeleteMethodWithHttpOperationResponse(resourceGroupName, virtualWANName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginDeleteMethod(resourceGroupName, virtualWANName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Deletes a VirtualWAN. + * + * @param {string} resourceGroupName The resource group name of the VirtualWan. + * + * @param {string} virtualWANName The name of the VirtualWAN being deleted. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(resourceGroupName, virtualWANName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginDeleteMethod(resourceGroupName, virtualWANName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginDeleteMethod(resourceGroupName, virtualWANName, options, optionalCallback); + } + } + + /** + * Lists all the VirtualWANs in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listByResourceGroupNextWithHttpOperationResponse(nextPageLink, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listByResourceGroupNext(nextPageLink, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all the VirtualWANs in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVirtualWANsResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualWANsResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listByResourceGroupNext(nextPageLink, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listByResourceGroupNext(nextPageLink, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listByResourceGroupNext(nextPageLink, options, optionalCallback); + } + } + + /** + * Lists all the VirtualWANs in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listNext(nextPageLink, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all the VirtualWANs in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVirtualWANsResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVirtualWANsResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listNext(nextPageLink, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listNext(nextPageLink, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listNext(nextPageLink, options, optionalCallback); + } + } + +} + +module.exports = VirtualWANs; diff --git a/lib/services/networkManagement2/lib/operations/vpnConnections.js b/lib/services/networkManagement2/lib/operations/vpnConnections.js new file mode 100644 index 0000000000..a355bcbce9 --- /dev/null +++ b/lib/services/networkManagement2/lib/operations/vpnConnections.js @@ -0,0 +1,1745 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const msRest = require('ms-rest'); +const msRestAzure = require('ms-rest-azure'); +const WebResource = msRest.WebResource; + +/** + * Retrieves the details of a vpn connection. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the vpn connection. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnConnection} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _get(resourceGroupName, gatewayName, connectionName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (gatewayName === null || gatewayName === undefined || typeof gatewayName.valueOf() !== 'string') { + throw new Error('gatewayName cannot be null or undefined and it must be of type string.'); + } + if (connectionName === null || connectionName === undefined || typeof connectionName.valueOf() !== 'string') { + throw new Error('connectionName cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/vpnGateways/{gatewayName}/vpnConnections/{connectionName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{gatewayName}', encodeURIComponent(gatewayName)); + requestUrl = requestUrl.replace('{connectionName}', encodeURIComponent(connectionName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnConnection']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + + +/** + * Creates a vpn connection to a scalable vpn gateway if it doesn't exist else + * updates the existing connection. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the connection. + * + * @param {object} vpnConnectionParameters Parameters supplied to create or + * Update a VPN Connection. + * + * @param {object} [vpnConnectionParameters.remoteVpnSite] Id of the connected + * vpn site. + * + * @param {string} [vpnConnectionParameters.remoteVpnSite.id] Resource ID. + * + * @param {number} [vpnConnectionParameters.routingWeight] routing weight for + * vpn connection. + * + * @param {string} [vpnConnectionParameters.connectionStatus] The connection + * status. Possible values include: 'Unknown', 'Connecting', 'Connected', + * 'NotConnected' + * + * @param {string} [vpnConnectionParameters.sharedKey] SharedKey for the vpn + * connection. + * + * @param {boolean} [vpnConnectionParameters.enableBgp] EnableBgp flag + * + * @param {array} [vpnConnectionParameters.ipsecPolicies] The IPSec Policies to + * be considered by this connection. + * + * @param {string} [vpnConnectionParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [vpnConnectionParameters.id] Resource ID. + * + * @param {string} [vpnConnectionParameters.location] Resource location. + * + * @param {object} [vpnConnectionParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnConnection} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _createOrUpdate(resourceGroupName, gatewayName, connectionName, vpnConnectionParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginCreateOrUpdate(resourceGroupName, gatewayName, connectionName, vpnConnectionParameters, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnConnection']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + + return callback(null, result, httpRequest, response); + }); + }); +} + + +/** + * Deletes a vpn connection. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the connection. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _deleteMethod(resourceGroupName, gatewayName, connectionName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginDeleteMethod(resourceGroupName, gatewayName, connectionName, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + + return callback(null, result, httpRequest, response); + }); + }); +} + +/** + * Retrieves all vpn connections for a particular virtual wan vpn gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnConnectionsResult} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listByVpnGateway(resourceGroupName, gatewayName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (gatewayName === null || gatewayName === undefined || typeof gatewayName.valueOf() !== 'string') { + throw new Error('gatewayName cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/vpnGateways/{gatewayName}/vpnConnections'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{gatewayName}', encodeURIComponent(gatewayName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVpnConnectionsResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Creates a vpn connection to a scalable vpn gateway if it doesn't exist else + * updates the existing connection. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the connection. + * + * @param {object} vpnConnectionParameters Parameters supplied to create or + * Update a VPN Connection. + * + * @param {object} [vpnConnectionParameters.remoteVpnSite] Id of the connected + * vpn site. + * + * @param {string} [vpnConnectionParameters.remoteVpnSite.id] Resource ID. + * + * @param {number} [vpnConnectionParameters.routingWeight] routing weight for + * vpn connection. + * + * @param {string} [vpnConnectionParameters.connectionStatus] The connection + * status. Possible values include: 'Unknown', 'Connecting', 'Connected', + * 'NotConnected' + * + * @param {string} [vpnConnectionParameters.sharedKey] SharedKey for the vpn + * connection. + * + * @param {boolean} [vpnConnectionParameters.enableBgp] EnableBgp flag + * + * @param {array} [vpnConnectionParameters.ipsecPolicies] The IPSec Policies to + * be considered by this connection. + * + * @param {string} [vpnConnectionParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [vpnConnectionParameters.id] Resource ID. + * + * @param {string} [vpnConnectionParameters.location] Resource location. + * + * @param {object} [vpnConnectionParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnConnection} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginCreateOrUpdate(resourceGroupName, gatewayName, connectionName, vpnConnectionParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (gatewayName === null || gatewayName === undefined || typeof gatewayName.valueOf() !== 'string') { + throw new Error('gatewayName cannot be null or undefined and it must be of type string.'); + } + if (connectionName === null || connectionName === undefined || typeof connectionName.valueOf() !== 'string') { + throw new Error('connectionName cannot be null or undefined and it must be of type string.'); + } + if (vpnConnectionParameters === null || vpnConnectionParameters === undefined) { + throw new Error('vpnConnectionParameters cannot be null or undefined.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/vpnGateways/{gatewayName}/vpnConnections/{connectionName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{gatewayName}', encodeURIComponent(gatewayName)); + requestUrl = requestUrl.replace('{connectionName}', encodeURIComponent(connectionName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'PUT'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + // Serialize Request + let requestContent = null; + let requestModel = null; + try { + if (vpnConnectionParameters !== null && vpnConnectionParameters !== undefined) { + let requestModelMapper = new client.models['VpnConnection']().mapper(); + requestModel = client.serialize(requestModelMapper, vpnConnectionParameters, 'vpnConnectionParameters'); + requestContent = JSON.stringify(requestModel); + } + } catch (error) { + let serializationError = new Error(`Error "${error.message}" occurred in serializing the ` + + `payload - ${JSON.stringify(vpnConnectionParameters, null, 2)}.`); + return callback(serializationError); + } + httpRequest.body = requestContent; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 201) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnConnection']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + // Deserialize Response + if (statusCode === 201) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnConnection']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError1 = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError1.request = msRest.stripRequest(httpRequest); + deserializationError1.response = msRest.stripResponse(response); + return callback(deserializationError1); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Deletes a vpn connection. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the connection. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginDeleteMethod(resourceGroupName, gatewayName, connectionName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (gatewayName === null || gatewayName === undefined || typeof gatewayName.valueOf() !== 'string') { + throw new Error('gatewayName cannot be null or undefined and it must be of type string.'); + } + if (connectionName === null || connectionName === undefined || typeof connectionName.valueOf() !== 'string') { + throw new Error('connectionName cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/vpnGateways/{gatewayName}/vpnConnections/{connectionName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{gatewayName}', encodeURIComponent(gatewayName)); + requestUrl = requestUrl.replace('{connectionName}', encodeURIComponent(connectionName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'DELETE'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 202 && statusCode !== 204) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Retrieves all vpn connections for a particular virtual wan vpn gateway. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnConnectionsResult} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listByVpnGatewayNext(nextPageLink, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + // Validate + try { + if (nextPageLink === null || nextPageLink === undefined || typeof nextPageLink.valueOf() !== 'string') { + throw new Error('nextPageLink cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let requestUrl = '{nextLink}'; + requestUrl = requestUrl.replace('{nextLink}', nextPageLink); + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVpnConnectionsResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** Class representing a VpnConnections. */ +class VpnConnections { + /** + * Create a VpnConnections. + * @param {NetworkManagementClient} client Reference to the service client. + */ + constructor(client) { + this.client = client; + this._get = _get; + this._createOrUpdate = _createOrUpdate; + this._deleteMethod = _deleteMethod; + this._listByVpnGateway = _listByVpnGateway; + this._beginCreateOrUpdate = _beginCreateOrUpdate; + this._beginDeleteMethod = _beginDeleteMethod; + this._listByVpnGatewayNext = _listByVpnGatewayNext; + } + + /** + * Retrieves the details of a vpn connection. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the vpn connection. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName, gatewayName, connectionName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._get(resourceGroupName, gatewayName, connectionName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Retrieves the details of a vpn connection. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the vpn connection. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VpnConnection} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnConnection} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName, gatewayName, connectionName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._get(resourceGroupName, gatewayName, connectionName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._get(resourceGroupName, gatewayName, connectionName, options, optionalCallback); + } + } + + /** + * Creates a vpn connection to a scalable vpn gateway if it doesn't exist else + * updates the existing connection. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the connection. + * + * @param {object} vpnConnectionParameters Parameters supplied to create or + * Update a VPN Connection. + * + * @param {object} [vpnConnectionParameters.remoteVpnSite] Id of the connected + * vpn site. + * + * @param {string} [vpnConnectionParameters.remoteVpnSite.id] Resource ID. + * + * @param {number} [vpnConnectionParameters.routingWeight] routing weight for + * vpn connection. + * + * @param {string} [vpnConnectionParameters.connectionStatus] The connection + * status. Possible values include: 'Unknown', 'Connecting', 'Connected', + * 'NotConnected' + * + * @param {string} [vpnConnectionParameters.sharedKey] SharedKey for the vpn + * connection. + * + * @param {boolean} [vpnConnectionParameters.enableBgp] EnableBgp flag + * + * @param {array} [vpnConnectionParameters.ipsecPolicies] The IPSec Policies to + * be considered by this connection. + * + * @param {string} [vpnConnectionParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [vpnConnectionParameters.id] Resource ID. + * + * @param {string} [vpnConnectionParameters.location] Resource location. + * + * @param {object} [vpnConnectionParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName, gatewayName, connectionName, vpnConnectionParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._createOrUpdate(resourceGroupName, gatewayName, connectionName, vpnConnectionParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Creates a vpn connection to a scalable vpn gateway if it doesn't exist else + * updates the existing connection. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the connection. + * + * @param {object} vpnConnectionParameters Parameters supplied to create or + * Update a VPN Connection. + * + * @param {object} [vpnConnectionParameters.remoteVpnSite] Id of the connected + * vpn site. + * + * @param {string} [vpnConnectionParameters.remoteVpnSite.id] Resource ID. + * + * @param {number} [vpnConnectionParameters.routingWeight] routing weight for + * vpn connection. + * + * @param {string} [vpnConnectionParameters.connectionStatus] The connection + * status. Possible values include: 'Unknown', 'Connecting', 'Connected', + * 'NotConnected' + * + * @param {string} [vpnConnectionParameters.sharedKey] SharedKey for the vpn + * connection. + * + * @param {boolean} [vpnConnectionParameters.enableBgp] EnableBgp flag + * + * @param {array} [vpnConnectionParameters.ipsecPolicies] The IPSec Policies to + * be considered by this connection. + * + * @param {string} [vpnConnectionParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [vpnConnectionParameters.id] Resource ID. + * + * @param {string} [vpnConnectionParameters.location] Resource location. + * + * @param {object} [vpnConnectionParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VpnConnection} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnConnection} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName, gatewayName, connectionName, vpnConnectionParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._createOrUpdate(resourceGroupName, gatewayName, connectionName, vpnConnectionParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._createOrUpdate(resourceGroupName, gatewayName, connectionName, vpnConnectionParameters, options, optionalCallback); + } + } + + /** + * Deletes a vpn connection. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the connection. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + deleteMethodWithHttpOperationResponse(resourceGroupName, gatewayName, connectionName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._deleteMethod(resourceGroupName, gatewayName, connectionName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Deletes a vpn connection. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the connection. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + deleteMethod(resourceGroupName, gatewayName, connectionName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._deleteMethod(resourceGroupName, gatewayName, connectionName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._deleteMethod(resourceGroupName, gatewayName, connectionName, options, optionalCallback); + } + } + + /** + * Retrieves all vpn connections for a particular virtual wan vpn gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listByVpnGatewayWithHttpOperationResponse(resourceGroupName, gatewayName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listByVpnGateway(resourceGroupName, gatewayName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Retrieves all vpn connections for a particular virtual wan vpn gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVpnConnectionsResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnConnectionsResult} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listByVpnGateway(resourceGroupName, gatewayName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listByVpnGateway(resourceGroupName, gatewayName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listByVpnGateway(resourceGroupName, gatewayName, options, optionalCallback); + } + } + + /** + * Creates a vpn connection to a scalable vpn gateway if it doesn't exist else + * updates the existing connection. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the connection. + * + * @param {object} vpnConnectionParameters Parameters supplied to create or + * Update a VPN Connection. + * + * @param {object} [vpnConnectionParameters.remoteVpnSite] Id of the connected + * vpn site. + * + * @param {string} [vpnConnectionParameters.remoteVpnSite.id] Resource ID. + * + * @param {number} [vpnConnectionParameters.routingWeight] routing weight for + * vpn connection. + * + * @param {string} [vpnConnectionParameters.connectionStatus] The connection + * status. Possible values include: 'Unknown', 'Connecting', 'Connected', + * 'NotConnected' + * + * @param {string} [vpnConnectionParameters.sharedKey] SharedKey for the vpn + * connection. + * + * @param {boolean} [vpnConnectionParameters.enableBgp] EnableBgp flag + * + * @param {array} [vpnConnectionParameters.ipsecPolicies] The IPSec Policies to + * be considered by this connection. + * + * @param {string} [vpnConnectionParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [vpnConnectionParameters.id] Resource ID. + * + * @param {string} [vpnConnectionParameters.location] Resource location. + * + * @param {object} [vpnConnectionParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName, gatewayName, connectionName, vpnConnectionParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginCreateOrUpdate(resourceGroupName, gatewayName, connectionName, vpnConnectionParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Creates a vpn connection to a scalable vpn gateway if it doesn't exist else + * updates the existing connection. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the connection. + * + * @param {object} vpnConnectionParameters Parameters supplied to create or + * Update a VPN Connection. + * + * @param {object} [vpnConnectionParameters.remoteVpnSite] Id of the connected + * vpn site. + * + * @param {string} [vpnConnectionParameters.remoteVpnSite.id] Resource ID. + * + * @param {number} [vpnConnectionParameters.routingWeight] routing weight for + * vpn connection. + * + * @param {string} [vpnConnectionParameters.connectionStatus] The connection + * status. Possible values include: 'Unknown', 'Connecting', 'Connected', + * 'NotConnected' + * + * @param {string} [vpnConnectionParameters.sharedKey] SharedKey for the vpn + * connection. + * + * @param {boolean} [vpnConnectionParameters.enableBgp] EnableBgp flag + * + * @param {array} [vpnConnectionParameters.ipsecPolicies] The IPSec Policies to + * be considered by this connection. + * + * @param {string} [vpnConnectionParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [vpnConnectionParameters.id] Resource ID. + * + * @param {string} [vpnConnectionParameters.location] Resource location. + * + * @param {object} [vpnConnectionParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VpnConnection} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnConnection} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginCreateOrUpdate(resourceGroupName, gatewayName, connectionName, vpnConnectionParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginCreateOrUpdate(resourceGroupName, gatewayName, connectionName, vpnConnectionParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginCreateOrUpdate(resourceGroupName, gatewayName, connectionName, vpnConnectionParameters, options, optionalCallback); + } + } + + /** + * Deletes a vpn connection. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the connection. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginDeleteMethodWithHttpOperationResponse(resourceGroupName, gatewayName, connectionName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginDeleteMethod(resourceGroupName, gatewayName, connectionName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Deletes a vpn connection. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {string} connectionName The name of the connection. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(resourceGroupName, gatewayName, connectionName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginDeleteMethod(resourceGroupName, gatewayName, connectionName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginDeleteMethod(resourceGroupName, gatewayName, connectionName, options, optionalCallback); + } + } + + /** + * Retrieves all vpn connections for a particular virtual wan vpn gateway. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listByVpnGatewayNextWithHttpOperationResponse(nextPageLink, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listByVpnGatewayNext(nextPageLink, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Retrieves all vpn connections for a particular virtual wan vpn gateway. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVpnConnectionsResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnConnectionsResult} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listByVpnGatewayNext(nextPageLink, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listByVpnGatewayNext(nextPageLink, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listByVpnGatewayNext(nextPageLink, options, optionalCallback); + } + } + +} + +module.exports = VpnConnections; diff --git a/lib/services/networkManagement2/lib/operations/vpnGateways.js b/lib/services/networkManagement2/lib/operations/vpnGateways.js new file mode 100644 index 0000000000..238e248b70 --- /dev/null +++ b/lib/services/networkManagement2/lib/operations/vpnGateways.js @@ -0,0 +1,2627 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const msRest = require('ms-rest'); +const msRestAzure = require('ms-rest-azure'); +const WebResource = msRest.WebResource; + +/** + * Retrieves the details of a virtual wan vpn gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnGateway} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _get(resourceGroupName, gatewayName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (gatewayName === null || gatewayName === undefined || typeof gatewayName.valueOf() !== 'string') { + throw new Error('gatewayName cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/vpnGateways/{gatewayName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{gatewayName}', encodeURIComponent(gatewayName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnGateway']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + + +/** + * Creates a virtual wan vpn gateway if it doesn't exist else updates the + * existing gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} vpnGatewayParameters Parameters supplied to create or Update + * a virtual wan vpn gateway. + * + * @param {object} [vpnGatewayParameters.virtualHub] The VirtualHub to which + * the gateway belongs + * + * @param {string} [vpnGatewayParameters.virtualHub.id] Resource ID. + * + * @param {array} [vpnGatewayParameters.connections] list of all vpn + * connections to the gateway. + * + * @param {object} [vpnGatewayParameters.bgpSettings] Local network gateway's + * BGP speaker settings. + * + * @param {number} [vpnGatewayParameters.bgpSettings.asn] The BGP speaker's + * ASN. + * + * @param {string} [vpnGatewayParameters.bgpSettings.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [vpnGatewayParameters.bgpSettings.peerWeight] The weight + * added to routes learned from this BGP speaker. + * + * @param {string} [vpnGatewayParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {object} [vpnGatewayParameters.policies] The policies applied to this + * vpn gateway. + * + * @param {boolean} [vpnGatewayParameters.policies.allowBranchToBranchTraffic] + * True if branch to branch traffic is allowed. + * + * @param {boolean} [vpnGatewayParameters.policies.allowVnetToVnetTraffic] True + * if Vnet to Vnet traffic is allowed. + * + * @param {string} [vpnGatewayParameters.id] Resource ID. + * + * @param {string} [vpnGatewayParameters.location] Resource location. + * + * @param {object} [vpnGatewayParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnGateway} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _createOrUpdate(resourceGroupName, gatewayName, vpnGatewayParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginCreateOrUpdate(resourceGroupName, gatewayName, vpnGatewayParameters, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnGateway']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + + return callback(null, result, httpRequest, response); + }); + }); +} + + +/** + * Updates virtual wan vpn gateway tags. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} vpnGatewayParameters Parameters supplied to update a virtual + * wan vpn gateway tags. + * + * @param {object} [vpnGatewayParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnGateway} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _updateTags(resourceGroupName, gatewayName, vpnGatewayParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginUpdateTags(resourceGroupName, gatewayName, vpnGatewayParameters, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnGateway']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + + return callback(null, result, httpRequest, response); + }); + }); +} + + +/** + * Deletes a virtual wan vpn gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _deleteMethod(resourceGroupName, gatewayName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginDeleteMethod(resourceGroupName, gatewayName, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + + return callback(null, result, httpRequest, response); + }); + }); +} + +/** + * Lists all the VpnGateways in a resource group. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnGatewaysResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listByResourceGroup(resourceGroupName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/vpnGateways'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVpnGatewaysResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Lists all the VpnGateways in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnGatewaysResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _list(options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/vpnGateways'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVpnGatewaysResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Creates a virtual wan vpn gateway if it doesn't exist else updates the + * existing gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} vpnGatewayParameters Parameters supplied to create or Update + * a virtual wan vpn gateway. + * + * @param {object} [vpnGatewayParameters.virtualHub] The VirtualHub to which + * the gateway belongs + * + * @param {string} [vpnGatewayParameters.virtualHub.id] Resource ID. + * + * @param {array} [vpnGatewayParameters.connections] list of all vpn + * connections to the gateway. + * + * @param {object} [vpnGatewayParameters.bgpSettings] Local network gateway's + * BGP speaker settings. + * + * @param {number} [vpnGatewayParameters.bgpSettings.asn] The BGP speaker's + * ASN. + * + * @param {string} [vpnGatewayParameters.bgpSettings.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [vpnGatewayParameters.bgpSettings.peerWeight] The weight + * added to routes learned from this BGP speaker. + * + * @param {string} [vpnGatewayParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {object} [vpnGatewayParameters.policies] The policies applied to this + * vpn gateway. + * + * @param {boolean} [vpnGatewayParameters.policies.allowBranchToBranchTraffic] + * True if branch to branch traffic is allowed. + * + * @param {boolean} [vpnGatewayParameters.policies.allowVnetToVnetTraffic] True + * if Vnet to Vnet traffic is allowed. + * + * @param {string} [vpnGatewayParameters.id] Resource ID. + * + * @param {string} [vpnGatewayParameters.location] Resource location. + * + * @param {object} [vpnGatewayParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnGateway} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginCreateOrUpdate(resourceGroupName, gatewayName, vpnGatewayParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (gatewayName === null || gatewayName === undefined || typeof gatewayName.valueOf() !== 'string') { + throw new Error('gatewayName cannot be null or undefined and it must be of type string.'); + } + if (vpnGatewayParameters === null || vpnGatewayParameters === undefined) { + throw new Error('vpnGatewayParameters cannot be null or undefined.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/vpnGateways/{gatewayName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{gatewayName}', encodeURIComponent(gatewayName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'PUT'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + // Serialize Request + let requestContent = null; + let requestModel = null; + try { + if (vpnGatewayParameters !== null && vpnGatewayParameters !== undefined) { + let requestModelMapper = new client.models['VpnGateway']().mapper(); + requestModel = client.serialize(requestModelMapper, vpnGatewayParameters, 'vpnGatewayParameters'); + requestContent = JSON.stringify(requestModel); + } + } catch (error) { + let serializationError = new Error(`Error "${error.message}" occurred in serializing the ` + + `payload - ${JSON.stringify(vpnGatewayParameters, null, 2)}.`); + return callback(serializationError); + } + httpRequest.body = requestContent; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 201) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnGateway']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + // Deserialize Response + if (statusCode === 201) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnGateway']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError1 = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError1.request = msRest.stripRequest(httpRequest); + deserializationError1.response = msRest.stripResponse(response); + return callback(deserializationError1); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Updates virtual wan vpn gateway tags. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} vpnGatewayParameters Parameters supplied to update a virtual + * wan vpn gateway tags. + * + * @param {object} [vpnGatewayParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnGateway} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginUpdateTags(resourceGroupName, gatewayName, vpnGatewayParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (gatewayName === null || gatewayName === undefined || typeof gatewayName.valueOf() !== 'string') { + throw new Error('gatewayName cannot be null or undefined and it must be of type string.'); + } + if (vpnGatewayParameters === null || vpnGatewayParameters === undefined) { + throw new Error('vpnGatewayParameters cannot be null or undefined.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/vpnGateways/{gatewayName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{gatewayName}', encodeURIComponent(gatewayName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'PATCH'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + // Serialize Request + let requestContent = null; + let requestModel = null; + try { + if (vpnGatewayParameters !== null && vpnGatewayParameters !== undefined) { + let requestModelMapper = new client.models['TagsObject']().mapper(); + requestModel = client.serialize(requestModelMapper, vpnGatewayParameters, 'vpnGatewayParameters'); + requestContent = JSON.stringify(requestModel); + } + } catch (error) { + let serializationError = new Error(`Error "${error.message}" occurred in serializing the ` + + `payload - ${JSON.stringify(vpnGatewayParameters, null, 2)}.`); + return callback(serializationError); + } + httpRequest.body = requestContent; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 201) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnGateway']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + // Deserialize Response + if (statusCode === 201) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnGateway']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError1 = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError1.request = msRest.stripRequest(httpRequest); + deserializationError1.response = msRest.stripResponse(response); + return callback(deserializationError1); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Deletes a virtual wan vpn gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginDeleteMethod(resourceGroupName, gatewayName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (gatewayName === null || gatewayName === undefined || typeof gatewayName.valueOf() !== 'string') { + throw new Error('gatewayName cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/vpnGateways/{gatewayName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{gatewayName}', encodeURIComponent(gatewayName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'DELETE'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 202 && statusCode !== 204) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Lists all the VpnGateways in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnGatewaysResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listByResourceGroupNext(nextPageLink, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + // Validate + try { + if (nextPageLink === null || nextPageLink === undefined || typeof nextPageLink.valueOf() !== 'string') { + throw new Error('nextPageLink cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let requestUrl = '{nextLink}'; + requestUrl = requestUrl.replace('{nextLink}', nextPageLink); + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVpnGatewaysResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Lists all the VpnGateways in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnGatewaysResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listNext(nextPageLink, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + // Validate + try { + if (nextPageLink === null || nextPageLink === undefined || typeof nextPageLink.valueOf() !== 'string') { + throw new Error('nextPageLink cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let requestUrl = '{nextLink}'; + requestUrl = requestUrl.replace('{nextLink}', nextPageLink); + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVpnGatewaysResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** Class representing a VpnGateways. */ +class VpnGateways { + /** + * Create a VpnGateways. + * @param {NetworkManagementClient} client Reference to the service client. + */ + constructor(client) { + this.client = client; + this._get = _get; + this._createOrUpdate = _createOrUpdate; + this._updateTags = _updateTags; + this._deleteMethod = _deleteMethod; + this._listByResourceGroup = _listByResourceGroup; + this._list = _list; + this._beginCreateOrUpdate = _beginCreateOrUpdate; + this._beginUpdateTags = _beginUpdateTags; + this._beginDeleteMethod = _beginDeleteMethod; + this._listByResourceGroupNext = _listByResourceGroupNext; + this._listNext = _listNext; + } + + /** + * Retrieves the details of a virtual wan vpn gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName, gatewayName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._get(resourceGroupName, gatewayName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Retrieves the details of a virtual wan vpn gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VpnGateway} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnGateway} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName, gatewayName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._get(resourceGroupName, gatewayName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._get(resourceGroupName, gatewayName, options, optionalCallback); + } + } + + /** + * Creates a virtual wan vpn gateway if it doesn't exist else updates the + * existing gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} vpnGatewayParameters Parameters supplied to create or Update + * a virtual wan vpn gateway. + * + * @param {object} [vpnGatewayParameters.virtualHub] The VirtualHub to which + * the gateway belongs + * + * @param {string} [vpnGatewayParameters.virtualHub.id] Resource ID. + * + * @param {array} [vpnGatewayParameters.connections] list of all vpn + * connections to the gateway. + * + * @param {object} [vpnGatewayParameters.bgpSettings] Local network gateway's + * BGP speaker settings. + * + * @param {number} [vpnGatewayParameters.bgpSettings.asn] The BGP speaker's + * ASN. + * + * @param {string} [vpnGatewayParameters.bgpSettings.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [vpnGatewayParameters.bgpSettings.peerWeight] The weight + * added to routes learned from this BGP speaker. + * + * @param {string} [vpnGatewayParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {object} [vpnGatewayParameters.policies] The policies applied to this + * vpn gateway. + * + * @param {boolean} [vpnGatewayParameters.policies.allowBranchToBranchTraffic] + * True if branch to branch traffic is allowed. + * + * @param {boolean} [vpnGatewayParameters.policies.allowVnetToVnetTraffic] True + * if Vnet to Vnet traffic is allowed. + * + * @param {string} [vpnGatewayParameters.id] Resource ID. + * + * @param {string} [vpnGatewayParameters.location] Resource location. + * + * @param {object} [vpnGatewayParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName, gatewayName, vpnGatewayParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._createOrUpdate(resourceGroupName, gatewayName, vpnGatewayParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Creates a virtual wan vpn gateway if it doesn't exist else updates the + * existing gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} vpnGatewayParameters Parameters supplied to create or Update + * a virtual wan vpn gateway. + * + * @param {object} [vpnGatewayParameters.virtualHub] The VirtualHub to which + * the gateway belongs + * + * @param {string} [vpnGatewayParameters.virtualHub.id] Resource ID. + * + * @param {array} [vpnGatewayParameters.connections] list of all vpn + * connections to the gateway. + * + * @param {object} [vpnGatewayParameters.bgpSettings] Local network gateway's + * BGP speaker settings. + * + * @param {number} [vpnGatewayParameters.bgpSettings.asn] The BGP speaker's + * ASN. + * + * @param {string} [vpnGatewayParameters.bgpSettings.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [vpnGatewayParameters.bgpSettings.peerWeight] The weight + * added to routes learned from this BGP speaker. + * + * @param {string} [vpnGatewayParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {object} [vpnGatewayParameters.policies] The policies applied to this + * vpn gateway. + * + * @param {boolean} [vpnGatewayParameters.policies.allowBranchToBranchTraffic] + * True if branch to branch traffic is allowed. + * + * @param {boolean} [vpnGatewayParameters.policies.allowVnetToVnetTraffic] True + * if Vnet to Vnet traffic is allowed. + * + * @param {string} [vpnGatewayParameters.id] Resource ID. + * + * @param {string} [vpnGatewayParameters.location] Resource location. + * + * @param {object} [vpnGatewayParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VpnGateway} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnGateway} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName, gatewayName, vpnGatewayParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._createOrUpdate(resourceGroupName, gatewayName, vpnGatewayParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._createOrUpdate(resourceGroupName, gatewayName, vpnGatewayParameters, options, optionalCallback); + } + } + + /** + * Updates virtual wan vpn gateway tags. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} vpnGatewayParameters Parameters supplied to update a virtual + * wan vpn gateway tags. + * + * @param {object} [vpnGatewayParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + updateTagsWithHttpOperationResponse(resourceGroupName, gatewayName, vpnGatewayParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._updateTags(resourceGroupName, gatewayName, vpnGatewayParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Updates virtual wan vpn gateway tags. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} vpnGatewayParameters Parameters supplied to update a virtual + * wan vpn gateway tags. + * + * @param {object} [vpnGatewayParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VpnGateway} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnGateway} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + updateTags(resourceGroupName, gatewayName, vpnGatewayParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._updateTags(resourceGroupName, gatewayName, vpnGatewayParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._updateTags(resourceGroupName, gatewayName, vpnGatewayParameters, options, optionalCallback); + } + } + + /** + * Deletes a virtual wan vpn gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + deleteMethodWithHttpOperationResponse(resourceGroupName, gatewayName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._deleteMethod(resourceGroupName, gatewayName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Deletes a virtual wan vpn gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + deleteMethod(resourceGroupName, gatewayName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._deleteMethod(resourceGroupName, gatewayName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._deleteMethod(resourceGroupName, gatewayName, options, optionalCallback); + } + } + + /** + * Lists all the VpnGateways in a resource group. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listByResourceGroupWithHttpOperationResponse(resourceGroupName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listByResourceGroup(resourceGroupName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all the VpnGateways in a resource group. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVpnGatewaysResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnGatewaysResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listByResourceGroup(resourceGroupName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listByResourceGroup(resourceGroupName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listByResourceGroup(resourceGroupName, options, optionalCallback); + } + } + + /** + * Lists all the VpnGateways in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listWithHttpOperationResponse(options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._list(options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all the VpnGateways in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVpnGatewaysResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnGatewaysResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + list(options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._list(options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._list(options, optionalCallback); + } + } + + /** + * Creates a virtual wan vpn gateway if it doesn't exist else updates the + * existing gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} vpnGatewayParameters Parameters supplied to create or Update + * a virtual wan vpn gateway. + * + * @param {object} [vpnGatewayParameters.virtualHub] The VirtualHub to which + * the gateway belongs + * + * @param {string} [vpnGatewayParameters.virtualHub.id] Resource ID. + * + * @param {array} [vpnGatewayParameters.connections] list of all vpn + * connections to the gateway. + * + * @param {object} [vpnGatewayParameters.bgpSettings] Local network gateway's + * BGP speaker settings. + * + * @param {number} [vpnGatewayParameters.bgpSettings.asn] The BGP speaker's + * ASN. + * + * @param {string} [vpnGatewayParameters.bgpSettings.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [vpnGatewayParameters.bgpSettings.peerWeight] The weight + * added to routes learned from this BGP speaker. + * + * @param {string} [vpnGatewayParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {object} [vpnGatewayParameters.policies] The policies applied to this + * vpn gateway. + * + * @param {boolean} [vpnGatewayParameters.policies.allowBranchToBranchTraffic] + * True if branch to branch traffic is allowed. + * + * @param {boolean} [vpnGatewayParameters.policies.allowVnetToVnetTraffic] True + * if Vnet to Vnet traffic is allowed. + * + * @param {string} [vpnGatewayParameters.id] Resource ID. + * + * @param {string} [vpnGatewayParameters.location] Resource location. + * + * @param {object} [vpnGatewayParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName, gatewayName, vpnGatewayParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginCreateOrUpdate(resourceGroupName, gatewayName, vpnGatewayParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Creates a virtual wan vpn gateway if it doesn't exist else updates the + * existing gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} vpnGatewayParameters Parameters supplied to create or Update + * a virtual wan vpn gateway. + * + * @param {object} [vpnGatewayParameters.virtualHub] The VirtualHub to which + * the gateway belongs + * + * @param {string} [vpnGatewayParameters.virtualHub.id] Resource ID. + * + * @param {array} [vpnGatewayParameters.connections] list of all vpn + * connections to the gateway. + * + * @param {object} [vpnGatewayParameters.bgpSettings] Local network gateway's + * BGP speaker settings. + * + * @param {number} [vpnGatewayParameters.bgpSettings.asn] The BGP speaker's + * ASN. + * + * @param {string} [vpnGatewayParameters.bgpSettings.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [vpnGatewayParameters.bgpSettings.peerWeight] The weight + * added to routes learned from this BGP speaker. + * + * @param {string} [vpnGatewayParameters.provisioningState] The provisioning + * state of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {object} [vpnGatewayParameters.policies] The policies applied to this + * vpn gateway. + * + * @param {boolean} [vpnGatewayParameters.policies.allowBranchToBranchTraffic] + * True if branch to branch traffic is allowed. + * + * @param {boolean} [vpnGatewayParameters.policies.allowVnetToVnetTraffic] True + * if Vnet to Vnet traffic is allowed. + * + * @param {string} [vpnGatewayParameters.id] Resource ID. + * + * @param {string} [vpnGatewayParameters.location] Resource location. + * + * @param {object} [vpnGatewayParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VpnGateway} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnGateway} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginCreateOrUpdate(resourceGroupName, gatewayName, vpnGatewayParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginCreateOrUpdate(resourceGroupName, gatewayName, vpnGatewayParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginCreateOrUpdate(resourceGroupName, gatewayName, vpnGatewayParameters, options, optionalCallback); + } + } + + /** + * Updates virtual wan vpn gateway tags. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} vpnGatewayParameters Parameters supplied to update a virtual + * wan vpn gateway tags. + * + * @param {object} [vpnGatewayParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginUpdateTagsWithHttpOperationResponse(resourceGroupName, gatewayName, vpnGatewayParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginUpdateTags(resourceGroupName, gatewayName, vpnGatewayParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Updates virtual wan vpn gateway tags. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} vpnGatewayParameters Parameters supplied to update a virtual + * wan vpn gateway tags. + * + * @param {object} [vpnGatewayParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VpnGateway} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnGateway} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginUpdateTags(resourceGroupName, gatewayName, vpnGatewayParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginUpdateTags(resourceGroupName, gatewayName, vpnGatewayParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginUpdateTags(resourceGroupName, gatewayName, vpnGatewayParameters, options, optionalCallback); + } + } + + /** + * Deletes a virtual wan vpn gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginDeleteMethodWithHttpOperationResponse(resourceGroupName, gatewayName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginDeleteMethod(resourceGroupName, gatewayName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Deletes a virtual wan vpn gateway. + * + * @param {string} resourceGroupName The resource group name of the VpnGateway. + * + * @param {string} gatewayName The name of the gateway. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(resourceGroupName, gatewayName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginDeleteMethod(resourceGroupName, gatewayName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginDeleteMethod(resourceGroupName, gatewayName, options, optionalCallback); + } + } + + /** + * Lists all the VpnGateways in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listByResourceGroupNextWithHttpOperationResponse(nextPageLink, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listByResourceGroupNext(nextPageLink, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all the VpnGateways in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVpnGatewaysResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnGatewaysResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listByResourceGroupNext(nextPageLink, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listByResourceGroupNext(nextPageLink, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listByResourceGroupNext(nextPageLink, options, optionalCallback); + } + } + + /** + * Lists all the VpnGateways in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listNext(nextPageLink, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all the VpnGateways in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVpnGatewaysResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnGatewaysResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listNext(nextPageLink, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listNext(nextPageLink, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listNext(nextPageLink, options, optionalCallback); + } + } + +} + +module.exports = VpnGateways; diff --git a/lib/services/networkManagement2/lib/operations/vpnSites.js b/lib/services/networkManagement2/lib/operations/vpnSites.js new file mode 100644 index 0000000000..a9023614cd --- /dev/null +++ b/lib/services/networkManagement2/lib/operations/vpnSites.js @@ -0,0 +1,2687 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const msRest = require('ms-rest'); +const msRestAzure = require('ms-rest-azure'); +const WebResource = msRest.WebResource; + +/** + * Retrieves the details of a VPNsite. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being retrieved. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnSite} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _get(resourceGroupName, vpnSiteName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (vpnSiteName === null || vpnSiteName === undefined || typeof vpnSiteName.valueOf() !== 'string') { + throw new Error('vpnSiteName cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/vpnSites/{vpnSiteName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{vpnSiteName}', encodeURIComponent(vpnSiteName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnSite']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + + +/** + * Creates a VpnSite resource if it doesn't exist else updates the existing + * VpnSite. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being created or + * updated. + * + * @param {object} vpnSiteParameters Parameters supplied to create or update + * VpnSite. + * + * @param {object} [vpnSiteParameters.virtualWAN] The VirtualWAN to which the + * vpnSite belongs + * + * @param {string} [vpnSiteParameters.virtualWAN.id] Resource ID. + * + * @param {object} [vpnSiteParameters.deviceProperties] The device properties + * + * @param {string} [vpnSiteParameters.deviceProperties.deviceVendor] Name of + * the device Vendor. + * + * @param {string} [vpnSiteParameters.deviceProperties.deviceModel] Model of + * the device. + * + * @param {number} [vpnSiteParameters.deviceProperties.linkSpeedInMbps] Link + * speed. + * + * @param {string} [vpnSiteParameters.ipAddress] The ip-address for the + * vpn-site. + * + * @param {string} [vpnSiteParameters.siteKey] The key for vpn-site that can be + * used for connections. + * + * @param {object} [vpnSiteParameters.addressSpace] The AddressSpace that + * contains an array of IP address ranges. + * + * @param {array} [vpnSiteParameters.addressSpace.addressPrefixes] A list of + * address blocks reserved for this virtual network in CIDR notation. + * + * @param {object} [vpnSiteParameters.bgpProperties] The set of bgp properties. + * + * @param {number} [vpnSiteParameters.bgpProperties.asn] The BGP speaker's ASN. + * + * @param {string} [vpnSiteParameters.bgpProperties.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [vpnSiteParameters.bgpProperties.peerWeight] The weight + * added to routes learned from this BGP speaker. + * + * @param {string} [vpnSiteParameters.provisioningState] The provisioning state + * of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [vpnSiteParameters.id] Resource ID. + * + * @param {string} [vpnSiteParameters.location] Resource location. + * + * @param {object} [vpnSiteParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnSite} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _createOrUpdate(resourceGroupName, vpnSiteName, vpnSiteParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginCreateOrUpdate(resourceGroupName, vpnSiteName, vpnSiteParameters, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnSite']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + + return callback(null, result, httpRequest, response); + }); + }); +} + + +/** + * Updates VpnSite tags. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being updated. + * + * @param {object} vpnSiteParameters Parameters supplied to update VpnSite + * tags. + * + * @param {object} [vpnSiteParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnSite} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _updateTags(resourceGroupName, vpnSiteName, vpnSiteParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginUpdateTags(resourceGroupName, vpnSiteName, vpnSiteParameters, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnSite']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + + return callback(null, result, httpRequest, response); + }); + }); +} + + +/** + * Deletes a VpnSite. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being deleted. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _deleteMethod(resourceGroupName, vpnSiteName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginDeleteMethod(resourceGroupName, vpnSiteName, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + + return callback(null, result, httpRequest, response); + }); + }); +} + +/** + * Lists all the vpnSites in a resource group. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnSitesResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listByResourceGroup(resourceGroupName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/vpnSites'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVpnSitesResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Lists all the VpnSites in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnSitesResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _list(options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/providers/Microsoft.Network/vpnSites'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVpnSitesResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Creates a VpnSite resource if it doesn't exist else updates the existing + * VpnSite. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being created or + * updated. + * + * @param {object} vpnSiteParameters Parameters supplied to create or update + * VpnSite. + * + * @param {object} [vpnSiteParameters.virtualWAN] The VirtualWAN to which the + * vpnSite belongs + * + * @param {string} [vpnSiteParameters.virtualWAN.id] Resource ID. + * + * @param {object} [vpnSiteParameters.deviceProperties] The device properties + * + * @param {string} [vpnSiteParameters.deviceProperties.deviceVendor] Name of + * the device Vendor. + * + * @param {string} [vpnSiteParameters.deviceProperties.deviceModel] Model of + * the device. + * + * @param {number} [vpnSiteParameters.deviceProperties.linkSpeedInMbps] Link + * speed. + * + * @param {string} [vpnSiteParameters.ipAddress] The ip-address for the + * vpn-site. + * + * @param {string} [vpnSiteParameters.siteKey] The key for vpn-site that can be + * used for connections. + * + * @param {object} [vpnSiteParameters.addressSpace] The AddressSpace that + * contains an array of IP address ranges. + * + * @param {array} [vpnSiteParameters.addressSpace.addressPrefixes] A list of + * address blocks reserved for this virtual network in CIDR notation. + * + * @param {object} [vpnSiteParameters.bgpProperties] The set of bgp properties. + * + * @param {number} [vpnSiteParameters.bgpProperties.asn] The BGP speaker's ASN. + * + * @param {string} [vpnSiteParameters.bgpProperties.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [vpnSiteParameters.bgpProperties.peerWeight] The weight + * added to routes learned from this BGP speaker. + * + * @param {string} [vpnSiteParameters.provisioningState] The provisioning state + * of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [vpnSiteParameters.id] Resource ID. + * + * @param {string} [vpnSiteParameters.location] Resource location. + * + * @param {object} [vpnSiteParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnSite} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginCreateOrUpdate(resourceGroupName, vpnSiteName, vpnSiteParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (vpnSiteName === null || vpnSiteName === undefined || typeof vpnSiteName.valueOf() !== 'string') { + throw new Error('vpnSiteName cannot be null or undefined and it must be of type string.'); + } + if (vpnSiteParameters === null || vpnSiteParameters === undefined) { + throw new Error('vpnSiteParameters cannot be null or undefined.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/vpnSites/{vpnSiteName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{vpnSiteName}', encodeURIComponent(vpnSiteName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'PUT'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + // Serialize Request + let requestContent = null; + let requestModel = null; + try { + if (vpnSiteParameters !== null && vpnSiteParameters !== undefined) { + let requestModelMapper = new client.models['VpnSite']().mapper(); + requestModel = client.serialize(requestModelMapper, vpnSiteParameters, 'vpnSiteParameters'); + requestContent = JSON.stringify(requestModel); + } + } catch (error) { + let serializationError = new Error(`Error "${error.message}" occurred in serializing the ` + + `payload - ${JSON.stringify(vpnSiteParameters, null, 2)}.`); + return callback(serializationError); + } + httpRequest.body = requestContent; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 201) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnSite']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + // Deserialize Response + if (statusCode === 201) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnSite']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError1 = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError1.request = msRest.stripRequest(httpRequest); + deserializationError1.response = msRest.stripResponse(response); + return callback(deserializationError1); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Updates VpnSite tags. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being updated. + * + * @param {object} vpnSiteParameters Parameters supplied to update VpnSite + * tags. + * + * @param {object} [vpnSiteParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnSite} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginUpdateTags(resourceGroupName, vpnSiteName, vpnSiteParameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (vpnSiteName === null || vpnSiteName === undefined || typeof vpnSiteName.valueOf() !== 'string') { + throw new Error('vpnSiteName cannot be null or undefined and it must be of type string.'); + } + if (vpnSiteParameters === null || vpnSiteParameters === undefined) { + throw new Error('vpnSiteParameters cannot be null or undefined.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/vpnSites/{vpnSiteName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{vpnSiteName}', encodeURIComponent(vpnSiteName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'PATCH'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + // Serialize Request + let requestContent = null; + let requestModel = null; + try { + if (vpnSiteParameters !== null && vpnSiteParameters !== undefined) { + let requestModelMapper = new client.models['TagsObject']().mapper(); + requestModel = client.serialize(requestModelMapper, vpnSiteParameters, 'vpnSiteParameters'); + requestContent = JSON.stringify(requestModel); + } + } catch (error) { + let serializationError = new Error(`Error "${error.message}" occurred in serializing the ` + + `payload - ${JSON.stringify(vpnSiteParameters, null, 2)}.`); + return callback(serializationError); + } + httpRequest.body = requestContent; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 201) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnSite']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + // Deserialize Response + if (statusCode === 201) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['VpnSite']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError1 = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError1.request = msRest.stripRequest(httpRequest); + deserializationError1.response = msRest.stripResponse(response); + return callback(deserializationError1); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Deletes a VpnSite. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being deleted. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginDeleteMethod(resourceGroupName, vpnSiteName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (vpnSiteName === null || vpnSiteName === undefined || typeof vpnSiteName.valueOf() !== 'string') { + throw new Error('vpnSiteName cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/vpnSites/{vpnSiteName}'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{vpnSiteName}', encodeURIComponent(vpnSiteName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'DELETE'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 202 && statusCode !== 204) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Lists all the vpnSites in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnSitesResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listByResourceGroupNext(nextPageLink, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + // Validate + try { + if (nextPageLink === null || nextPageLink === undefined || typeof nextPageLink.valueOf() !== 'string') { + throw new Error('nextPageLink cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let requestUrl = '{nextLink}'; + requestUrl = requestUrl.replace('{nextLink}', nextPageLink); + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVpnSitesResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Lists all the VpnSites in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnSitesResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _listNext(nextPageLink, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + // Validate + try { + if (nextPageLink === null || nextPageLink === undefined || typeof nextPageLink.valueOf() !== 'string') { + throw new Error('nextPageLink cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let requestUrl = '{nextLink}'; + requestUrl = requestUrl.replace('{nextLink}', nextPageLink); + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ListVpnSitesResult']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** Class representing a VpnSites. */ +class VpnSites { + /** + * Create a VpnSites. + * @param {NetworkManagementClient} client Reference to the service client. + */ + constructor(client) { + this.client = client; + this._get = _get; + this._createOrUpdate = _createOrUpdate; + this._updateTags = _updateTags; + this._deleteMethod = _deleteMethod; + this._listByResourceGroup = _listByResourceGroup; + this._list = _list; + this._beginCreateOrUpdate = _beginCreateOrUpdate; + this._beginUpdateTags = _beginUpdateTags; + this._beginDeleteMethod = _beginDeleteMethod; + this._listByResourceGroupNext = _listByResourceGroupNext; + this._listNext = _listNext; + } + + /** + * Retrieves the details of a VPNsite. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being retrieved. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName, vpnSiteName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._get(resourceGroupName, vpnSiteName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Retrieves the details of a VPNsite. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being retrieved. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VpnSite} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnSite} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName, vpnSiteName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._get(resourceGroupName, vpnSiteName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._get(resourceGroupName, vpnSiteName, options, optionalCallback); + } + } + + /** + * Creates a VpnSite resource if it doesn't exist else updates the existing + * VpnSite. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being created or + * updated. + * + * @param {object} vpnSiteParameters Parameters supplied to create or update + * VpnSite. + * + * @param {object} [vpnSiteParameters.virtualWAN] The VirtualWAN to which the + * vpnSite belongs + * + * @param {string} [vpnSiteParameters.virtualWAN.id] Resource ID. + * + * @param {object} [vpnSiteParameters.deviceProperties] The device properties + * + * @param {string} [vpnSiteParameters.deviceProperties.deviceVendor] Name of + * the device Vendor. + * + * @param {string} [vpnSiteParameters.deviceProperties.deviceModel] Model of + * the device. + * + * @param {number} [vpnSiteParameters.deviceProperties.linkSpeedInMbps] Link + * speed. + * + * @param {string} [vpnSiteParameters.ipAddress] The ip-address for the + * vpn-site. + * + * @param {string} [vpnSiteParameters.siteKey] The key for vpn-site that can be + * used for connections. + * + * @param {object} [vpnSiteParameters.addressSpace] The AddressSpace that + * contains an array of IP address ranges. + * + * @param {array} [vpnSiteParameters.addressSpace.addressPrefixes] A list of + * address blocks reserved for this virtual network in CIDR notation. + * + * @param {object} [vpnSiteParameters.bgpProperties] The set of bgp properties. + * + * @param {number} [vpnSiteParameters.bgpProperties.asn] The BGP speaker's ASN. + * + * @param {string} [vpnSiteParameters.bgpProperties.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [vpnSiteParameters.bgpProperties.peerWeight] The weight + * added to routes learned from this BGP speaker. + * + * @param {string} [vpnSiteParameters.provisioningState] The provisioning state + * of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [vpnSiteParameters.id] Resource ID. + * + * @param {string} [vpnSiteParameters.location] Resource location. + * + * @param {object} [vpnSiteParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName, vpnSiteName, vpnSiteParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._createOrUpdate(resourceGroupName, vpnSiteName, vpnSiteParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Creates a VpnSite resource if it doesn't exist else updates the existing + * VpnSite. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being created or + * updated. + * + * @param {object} vpnSiteParameters Parameters supplied to create or update + * VpnSite. + * + * @param {object} [vpnSiteParameters.virtualWAN] The VirtualWAN to which the + * vpnSite belongs + * + * @param {string} [vpnSiteParameters.virtualWAN.id] Resource ID. + * + * @param {object} [vpnSiteParameters.deviceProperties] The device properties + * + * @param {string} [vpnSiteParameters.deviceProperties.deviceVendor] Name of + * the device Vendor. + * + * @param {string} [vpnSiteParameters.deviceProperties.deviceModel] Model of + * the device. + * + * @param {number} [vpnSiteParameters.deviceProperties.linkSpeedInMbps] Link + * speed. + * + * @param {string} [vpnSiteParameters.ipAddress] The ip-address for the + * vpn-site. + * + * @param {string} [vpnSiteParameters.siteKey] The key for vpn-site that can be + * used for connections. + * + * @param {object} [vpnSiteParameters.addressSpace] The AddressSpace that + * contains an array of IP address ranges. + * + * @param {array} [vpnSiteParameters.addressSpace.addressPrefixes] A list of + * address blocks reserved for this virtual network in CIDR notation. + * + * @param {object} [vpnSiteParameters.bgpProperties] The set of bgp properties. + * + * @param {number} [vpnSiteParameters.bgpProperties.asn] The BGP speaker's ASN. + * + * @param {string} [vpnSiteParameters.bgpProperties.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [vpnSiteParameters.bgpProperties.peerWeight] The weight + * added to routes learned from this BGP speaker. + * + * @param {string} [vpnSiteParameters.provisioningState] The provisioning state + * of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [vpnSiteParameters.id] Resource ID. + * + * @param {string} [vpnSiteParameters.location] Resource location. + * + * @param {object} [vpnSiteParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VpnSite} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnSite} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName, vpnSiteName, vpnSiteParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._createOrUpdate(resourceGroupName, vpnSiteName, vpnSiteParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._createOrUpdate(resourceGroupName, vpnSiteName, vpnSiteParameters, options, optionalCallback); + } + } + + /** + * Updates VpnSite tags. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being updated. + * + * @param {object} vpnSiteParameters Parameters supplied to update VpnSite + * tags. + * + * @param {object} [vpnSiteParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + updateTagsWithHttpOperationResponse(resourceGroupName, vpnSiteName, vpnSiteParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._updateTags(resourceGroupName, vpnSiteName, vpnSiteParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Updates VpnSite tags. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being updated. + * + * @param {object} vpnSiteParameters Parameters supplied to update VpnSite + * tags. + * + * @param {object} [vpnSiteParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VpnSite} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnSite} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + updateTags(resourceGroupName, vpnSiteName, vpnSiteParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._updateTags(resourceGroupName, vpnSiteName, vpnSiteParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._updateTags(resourceGroupName, vpnSiteName, vpnSiteParameters, options, optionalCallback); + } + } + + /** + * Deletes a VpnSite. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being deleted. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + deleteMethodWithHttpOperationResponse(resourceGroupName, vpnSiteName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._deleteMethod(resourceGroupName, vpnSiteName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Deletes a VpnSite. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being deleted. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + deleteMethod(resourceGroupName, vpnSiteName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._deleteMethod(resourceGroupName, vpnSiteName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._deleteMethod(resourceGroupName, vpnSiteName, options, optionalCallback); + } + } + + /** + * Lists all the vpnSites in a resource group. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listByResourceGroupWithHttpOperationResponse(resourceGroupName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listByResourceGroup(resourceGroupName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all the vpnSites in a resource group. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVpnSitesResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnSitesResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listByResourceGroup(resourceGroupName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listByResourceGroup(resourceGroupName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listByResourceGroup(resourceGroupName, options, optionalCallback); + } + } + + /** + * Lists all the VpnSites in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listWithHttpOperationResponse(options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._list(options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all the VpnSites in a subscription. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVpnSitesResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnSitesResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + list(options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._list(options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._list(options, optionalCallback); + } + } + + /** + * Creates a VpnSite resource if it doesn't exist else updates the existing + * VpnSite. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being created or + * updated. + * + * @param {object} vpnSiteParameters Parameters supplied to create or update + * VpnSite. + * + * @param {object} [vpnSiteParameters.virtualWAN] The VirtualWAN to which the + * vpnSite belongs + * + * @param {string} [vpnSiteParameters.virtualWAN.id] Resource ID. + * + * @param {object} [vpnSiteParameters.deviceProperties] The device properties + * + * @param {string} [vpnSiteParameters.deviceProperties.deviceVendor] Name of + * the device Vendor. + * + * @param {string} [vpnSiteParameters.deviceProperties.deviceModel] Model of + * the device. + * + * @param {number} [vpnSiteParameters.deviceProperties.linkSpeedInMbps] Link + * speed. + * + * @param {string} [vpnSiteParameters.ipAddress] The ip-address for the + * vpn-site. + * + * @param {string} [vpnSiteParameters.siteKey] The key for vpn-site that can be + * used for connections. + * + * @param {object} [vpnSiteParameters.addressSpace] The AddressSpace that + * contains an array of IP address ranges. + * + * @param {array} [vpnSiteParameters.addressSpace.addressPrefixes] A list of + * address blocks reserved for this virtual network in CIDR notation. + * + * @param {object} [vpnSiteParameters.bgpProperties] The set of bgp properties. + * + * @param {number} [vpnSiteParameters.bgpProperties.asn] The BGP speaker's ASN. + * + * @param {string} [vpnSiteParameters.bgpProperties.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [vpnSiteParameters.bgpProperties.peerWeight] The weight + * added to routes learned from this BGP speaker. + * + * @param {string} [vpnSiteParameters.provisioningState] The provisioning state + * of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [vpnSiteParameters.id] Resource ID. + * + * @param {string} [vpnSiteParameters.location] Resource location. + * + * @param {object} [vpnSiteParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName, vpnSiteName, vpnSiteParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginCreateOrUpdate(resourceGroupName, vpnSiteName, vpnSiteParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Creates a VpnSite resource if it doesn't exist else updates the existing + * VpnSite. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being created or + * updated. + * + * @param {object} vpnSiteParameters Parameters supplied to create or update + * VpnSite. + * + * @param {object} [vpnSiteParameters.virtualWAN] The VirtualWAN to which the + * vpnSite belongs + * + * @param {string} [vpnSiteParameters.virtualWAN.id] Resource ID. + * + * @param {object} [vpnSiteParameters.deviceProperties] The device properties + * + * @param {string} [vpnSiteParameters.deviceProperties.deviceVendor] Name of + * the device Vendor. + * + * @param {string} [vpnSiteParameters.deviceProperties.deviceModel] Model of + * the device. + * + * @param {number} [vpnSiteParameters.deviceProperties.linkSpeedInMbps] Link + * speed. + * + * @param {string} [vpnSiteParameters.ipAddress] The ip-address for the + * vpn-site. + * + * @param {string} [vpnSiteParameters.siteKey] The key for vpn-site that can be + * used for connections. + * + * @param {object} [vpnSiteParameters.addressSpace] The AddressSpace that + * contains an array of IP address ranges. + * + * @param {array} [vpnSiteParameters.addressSpace.addressPrefixes] A list of + * address blocks reserved for this virtual network in CIDR notation. + * + * @param {object} [vpnSiteParameters.bgpProperties] The set of bgp properties. + * + * @param {number} [vpnSiteParameters.bgpProperties.asn] The BGP speaker's ASN. + * + * @param {string} [vpnSiteParameters.bgpProperties.bgpPeeringAddress] The BGP + * peering address and BGP identifier of this BGP speaker. + * + * @param {number} [vpnSiteParameters.bgpProperties.peerWeight] The weight + * added to routes learned from this BGP speaker. + * + * @param {string} [vpnSiteParameters.provisioningState] The provisioning state + * of the resource. Possible values include: 'Succeeded', 'Updating', + * 'Deleting', 'Failed' + * + * @param {string} [vpnSiteParameters.id] Resource ID. + * + * @param {string} [vpnSiteParameters.location] Resource location. + * + * @param {object} [vpnSiteParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VpnSite} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnSite} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginCreateOrUpdate(resourceGroupName, vpnSiteName, vpnSiteParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginCreateOrUpdate(resourceGroupName, vpnSiteName, vpnSiteParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginCreateOrUpdate(resourceGroupName, vpnSiteName, vpnSiteParameters, options, optionalCallback); + } + } + + /** + * Updates VpnSite tags. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being updated. + * + * @param {object} vpnSiteParameters Parameters supplied to update VpnSite + * tags. + * + * @param {object} [vpnSiteParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginUpdateTagsWithHttpOperationResponse(resourceGroupName, vpnSiteName, vpnSiteParameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginUpdateTags(resourceGroupName, vpnSiteName, vpnSiteParameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Updates VpnSite tags. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being updated. + * + * @param {object} vpnSiteParameters Parameters supplied to update VpnSite + * tags. + * + * @param {object} [vpnSiteParameters.tags] Resource tags. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {VpnSite} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link VpnSite} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginUpdateTags(resourceGroupName, vpnSiteName, vpnSiteParameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginUpdateTags(resourceGroupName, vpnSiteName, vpnSiteParameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginUpdateTags(resourceGroupName, vpnSiteName, vpnSiteParameters, options, optionalCallback); + } + } + + /** + * Deletes a VpnSite. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being deleted. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginDeleteMethodWithHttpOperationResponse(resourceGroupName, vpnSiteName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginDeleteMethod(resourceGroupName, vpnSiteName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Deletes a VpnSite. + * + * @param {string} resourceGroupName The resource group name of the VpnSite. + * + * @param {string} vpnSiteName The name of the VpnSite being deleted. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(resourceGroupName, vpnSiteName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginDeleteMethod(resourceGroupName, vpnSiteName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginDeleteMethod(resourceGroupName, vpnSiteName, options, optionalCallback); + } + } + + /** + * Lists all the vpnSites in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listByResourceGroupNextWithHttpOperationResponse(nextPageLink, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listByResourceGroupNext(nextPageLink, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all the vpnSites in a resource group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVpnSitesResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnSitesResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listByResourceGroupNext(nextPageLink, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listByResourceGroupNext(nextPageLink, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listByResourceGroupNext(nextPageLink, options, optionalCallback); + } + } + + /** + * Lists all the VpnSites in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + listNextWithHttpOperationResponse(nextPageLink, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._listNext(nextPageLink, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Lists all the VpnSites in a subscription. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ListVpnSitesResult} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ListVpnSitesResult} for more information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + listNext(nextPageLink, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._listNext(nextPageLink, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._listNext(nextPageLink, options, optionalCallback); + } + } + +} + +module.exports = VpnSites; diff --git a/lib/services/networkManagement2/lib/operations/vpnSitesConfiguration.js b/lib/services/networkManagement2/lib/operations/vpnSitesConfiguration.js new file mode 100644 index 0000000000..a008dbf71b --- /dev/null +++ b/lib/services/networkManagement2/lib/operations/vpnSitesConfiguration.js @@ -0,0 +1,473 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +'use strict'; + +const msRest = require('ms-rest'); +const msRestAzure = require('ms-rest-azure'); +const WebResource = msRest.WebResource; + + +/** + * Gives the sas-url to download the configurations for vpn-sites in a resource + * group. + * + * @param {string} resourceGroupName The resource group name. + * + * @param {string} virtualWANName The name of the VirtualWAN for which + * configuration of all vpn-sites is needed. + * + * @param {object} request Parameters supplied to download vpn-sites + * configuration. + * + * @param {array} [request.vpnSites] List of resource-ids of the vpn-sites for + * which config is to be downloaded. + * + * @param {string} [request.outputBlobSasUrl] The sas-url to download the + * configurations for vpn-sites + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _download(resourceGroupName, virtualWANName, request, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginDownload(resourceGroupName, virtualWANName, request, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + + return callback(null, result, httpRequest, response); + }); + }); +} + +/** + * Gives the sas-url to download the configurations for vpn-sites in a resource + * group. + * + * @param {string} resourceGroupName The resource group name. + * + * @param {string} virtualWANName The name of the VirtualWAN for which + * configuration of all vpn-sites is needed. + * + * @param {object} request Parameters supplied to download vpn-sites + * configuration. + * + * @param {array} [request.vpnSites] List of resource-ids of the vpn-sites for + * which config is to be downloaded. + * + * @param {string} [request.outputBlobSasUrl] The sas-url to download the + * configurations for vpn-sites + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginDownload(resourceGroupName, virtualWANName, request, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let apiVersion = '2018-06-01'; + // Validate + try { + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (virtualWANName === null || virtualWANName === undefined || typeof virtualWANName.valueOf() !== 'string') { + throw new Error('virtualWANName cannot be null or undefined and it must be of type string.'); + } + if (request === null || request === undefined) { + throw new Error('request cannot be null or undefined.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualWans/{virtualWANName}/vpnConfiguration'; + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{virtualWANName}', encodeURIComponent(virtualWANName)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'POST'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + // Serialize Request + let requestContent = null; + let requestModel = null; + try { + if (request !== null && request !== undefined) { + let requestModelMapper = new client.models['GetVpnSitesConfigurationRequest']().mapper(); + requestModel = client.serialize(requestModelMapper, request, 'request'); + requestContent = JSON.stringify(requestModel); + } + } catch (error) { + let serializationError = new Error(`Error "${error.message}" occurred in serializing the ` + + `payload - ${JSON.stringify(request, null, 2)}.`); + return callback(serializationError); + } + httpRequest.body = requestContent; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 202) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + let internalError = null; + if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; + error.code = internalError ? internalError.code : parsedErrorResponse.code; + error.message = internalError ? internalError.message : parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['ErrorModel']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + + return callback(null, result, httpRequest, response); + }); +} + +/** Class representing a VpnSitesConfiguration. */ +class VpnSitesConfiguration { + /** + * Create a VpnSitesConfiguration. + * @param {NetworkManagementClient} client Reference to the service client. + */ + constructor(client) { + this.client = client; + this._download = _download; + this._beginDownload = _beginDownload; + } + + /** + * Gives the sas-url to download the configurations for vpn-sites in a resource + * group. + * + * @param {string} resourceGroupName The resource group name. + * + * @param {string} virtualWANName The name of the VirtualWAN for which + * configuration of all vpn-sites is needed. + * + * @param {object} request Parameters supplied to download vpn-sites + * configuration. + * + * @param {array} [request.vpnSites] List of resource-ids of the vpn-sites for + * which config is to be downloaded. + * + * @param {string} [request.outputBlobSasUrl] The sas-url to download the + * configurations for vpn-sites + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + downloadWithHttpOperationResponse(resourceGroupName, virtualWANName, request, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._download(resourceGroupName, virtualWANName, request, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Gives the sas-url to download the configurations for vpn-sites in a resource + * group. + * + * @param {string} resourceGroupName The resource group name. + * + * @param {string} virtualWANName The name of the VirtualWAN for which + * configuration of all vpn-sites is needed. + * + * @param {object} request Parameters supplied to download vpn-sites + * configuration. + * + * @param {array} [request.vpnSites] List of resource-ids of the vpn-sites for + * which config is to be downloaded. + * + * @param {string} [request.outputBlobSasUrl] The sas-url to download the + * configurations for vpn-sites + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + download(resourceGroupName, virtualWANName, request, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._download(resourceGroupName, virtualWANName, request, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._download(resourceGroupName, virtualWANName, request, options, optionalCallback); + } + } + + /** + * Gives the sas-url to download the configurations for vpn-sites in a resource + * group. + * + * @param {string} resourceGroupName The resource group name. + * + * @param {string} virtualWANName The name of the VirtualWAN for which + * configuration of all vpn-sites is needed. + * + * @param {object} request Parameters supplied to download vpn-sites + * configuration. + * + * @param {array} [request.vpnSites] List of resource-ids of the vpn-sites for + * which config is to be downloaded. + * + * @param {string} [request.outputBlobSasUrl] The sas-url to download the + * configurations for vpn-sites + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginDownloadWithHttpOperationResponse(resourceGroupName, virtualWANName, request, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginDownload(resourceGroupName, virtualWANName, request, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Gives the sas-url to download the configurations for vpn-sites in a resource + * group. + * + * @param {string} resourceGroupName The resource group name. + * + * @param {string} virtualWANName The name of the VirtualWAN for which + * configuration of all vpn-sites is needed. + * + * @param {object} request Parameters supplied to download vpn-sites + * configuration. + * + * @param {array} [request.vpnSites] List of resource-ids of the vpn-sites for + * which config is to be downloaded. + * + * @param {string} [request.outputBlobSasUrl] The sas-url to download the + * configurations for vpn-sites + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginDownload(resourceGroupName, virtualWANName, request, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginDownload(resourceGroupName, virtualWANName, request, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginDownload(resourceGroupName, virtualWANName, request, options, optionalCallback); + } + } + +} + +module.exports = VpnSitesConfiguration; diff --git a/lib/services/networkManagement2/package.json b/lib/services/networkManagement2/package.json index ee0013bb1d..2a04b48253 100644 --- a/lib/services/networkManagement2/package.json +++ b/lib/services/networkManagement2/package.json @@ -2,12 +2,15 @@ "name": "azure-arm-network", "author": "Microsoft Corporation", "description": "NetworkManagementClient Library with typescript type definitions for node", - "version": "5.3.0", + "version": "6.0.0", "dependencies": { - "ms-rest": "^2.3.2", + "ms-rest": "^2.3.3", "ms-rest-azure": "^2.5.5" }, - "keywords": [ "node", "azure" ], + "keywords": [ + "node", + "azure" + ], "license": "MIT", "main": "./lib/networkManagementClient.js", "types": "./lib/networkManagementClient.d.ts",