1package network
2
3// Copyright (c) Microsoft and contributors.  All rights reserved.
4//
5// Licensed under the Apache License, Version 2.0 (the "License");
6// you may not use this file except in compliance with the License.
7// You may obtain a copy of the License at
8// http://www.apache.org/licenses/LICENSE-2.0
9//
10// Unless required by applicable law or agreed to in writing, software
11// distributed under the License is distributed on an "AS IS" BASIS,
12// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13//
14// See the License for the specific language governing permissions and
15// limitations under the License.
16//
17// Code generated by Microsoft (R) AutoRest Code Generator.
18// Changes may cause incorrect behavior and will be lost if the code is regenerated.
19
20import (
21	"encoding/json"
22	"github.com/Azure/go-autorest/autorest"
23	"github.com/Azure/go-autorest/autorest/azure"
24	"github.com/Azure/go-autorest/autorest/date"
25	"github.com/Azure/go-autorest/autorest/to"
26	"net/http"
27)
28
29// Access enumerates the values for access.
30type Access string
31
32const (
33	// Allow ...
34	Allow Access = "Allow"
35	// Deny ...
36	Deny Access = "Deny"
37)
38
39// PossibleAccessValues returns an array of possible values for the Access const type.
40func PossibleAccessValues() []Access {
41	return []Access{Allow, Deny}
42}
43
44// ApplicationGatewayBackendHealthServerHealth enumerates the values for application gateway backend health
45// server health.
46type ApplicationGatewayBackendHealthServerHealth string
47
48const (
49	// Down ...
50	Down ApplicationGatewayBackendHealthServerHealth = "Down"
51	// Draining ...
52	Draining ApplicationGatewayBackendHealthServerHealth = "Draining"
53	// Partial ...
54	Partial ApplicationGatewayBackendHealthServerHealth = "Partial"
55	// Unknown ...
56	Unknown ApplicationGatewayBackendHealthServerHealth = "Unknown"
57	// Up ...
58	Up ApplicationGatewayBackendHealthServerHealth = "Up"
59)
60
61// PossibleApplicationGatewayBackendHealthServerHealthValues returns an array of possible values for the ApplicationGatewayBackendHealthServerHealth const type.
62func PossibleApplicationGatewayBackendHealthServerHealthValues() []ApplicationGatewayBackendHealthServerHealth {
63	return []ApplicationGatewayBackendHealthServerHealth{Down, Draining, Partial, Unknown, Up}
64}
65
66// ApplicationGatewayCookieBasedAffinity enumerates the values for application gateway cookie based affinity.
67type ApplicationGatewayCookieBasedAffinity string
68
69const (
70	// Disabled ...
71	Disabled ApplicationGatewayCookieBasedAffinity = "Disabled"
72	// Enabled ...
73	Enabled ApplicationGatewayCookieBasedAffinity = "Enabled"
74)
75
76// PossibleApplicationGatewayCookieBasedAffinityValues returns an array of possible values for the ApplicationGatewayCookieBasedAffinity const type.
77func PossibleApplicationGatewayCookieBasedAffinityValues() []ApplicationGatewayCookieBasedAffinity {
78	return []ApplicationGatewayCookieBasedAffinity{Disabled, Enabled}
79}
80
81// ApplicationGatewayFirewallMode enumerates the values for application gateway firewall mode.
82type ApplicationGatewayFirewallMode string
83
84const (
85	// Detection ...
86	Detection ApplicationGatewayFirewallMode = "Detection"
87	// Prevention ...
88	Prevention ApplicationGatewayFirewallMode = "Prevention"
89)
90
91// PossibleApplicationGatewayFirewallModeValues returns an array of possible values for the ApplicationGatewayFirewallMode const type.
92func PossibleApplicationGatewayFirewallModeValues() []ApplicationGatewayFirewallMode {
93	return []ApplicationGatewayFirewallMode{Detection, Prevention}
94}
95
96// ApplicationGatewayOperationalState enumerates the values for application gateway operational state.
97type ApplicationGatewayOperationalState string
98
99const (
100	// Running ...
101	Running ApplicationGatewayOperationalState = "Running"
102	// Starting ...
103	Starting ApplicationGatewayOperationalState = "Starting"
104	// Stopped ...
105	Stopped ApplicationGatewayOperationalState = "Stopped"
106	// Stopping ...
107	Stopping ApplicationGatewayOperationalState = "Stopping"
108)
109
110// PossibleApplicationGatewayOperationalStateValues returns an array of possible values for the ApplicationGatewayOperationalState const type.
111func PossibleApplicationGatewayOperationalStateValues() []ApplicationGatewayOperationalState {
112	return []ApplicationGatewayOperationalState{Running, Starting, Stopped, Stopping}
113}
114
115// ApplicationGatewayProtocol enumerates the values for application gateway protocol.
116type ApplicationGatewayProtocol string
117
118const (
119	// HTTP ...
120	HTTP ApplicationGatewayProtocol = "Http"
121	// HTTPS ...
122	HTTPS ApplicationGatewayProtocol = "Https"
123)
124
125// PossibleApplicationGatewayProtocolValues returns an array of possible values for the ApplicationGatewayProtocol const type.
126func PossibleApplicationGatewayProtocolValues() []ApplicationGatewayProtocol {
127	return []ApplicationGatewayProtocol{HTTP, HTTPS}
128}
129
130// ApplicationGatewayRedirectType enumerates the values for application gateway redirect type.
131type ApplicationGatewayRedirectType string
132
133const (
134	// Found ...
135	Found ApplicationGatewayRedirectType = "Found"
136	// Permanent ...
137	Permanent ApplicationGatewayRedirectType = "Permanent"
138	// SeeOther ...
139	SeeOther ApplicationGatewayRedirectType = "SeeOther"
140	// Temporary ...
141	Temporary ApplicationGatewayRedirectType = "Temporary"
142)
143
144// PossibleApplicationGatewayRedirectTypeValues returns an array of possible values for the ApplicationGatewayRedirectType const type.
145func PossibleApplicationGatewayRedirectTypeValues() []ApplicationGatewayRedirectType {
146	return []ApplicationGatewayRedirectType{Found, Permanent, SeeOther, Temporary}
147}
148
149// ApplicationGatewayRequestRoutingRuleType enumerates the values for application gateway request routing rule
150// type.
151type ApplicationGatewayRequestRoutingRuleType string
152
153const (
154	// Basic ...
155	Basic ApplicationGatewayRequestRoutingRuleType = "Basic"
156	// PathBasedRouting ...
157	PathBasedRouting ApplicationGatewayRequestRoutingRuleType = "PathBasedRouting"
158)
159
160// PossibleApplicationGatewayRequestRoutingRuleTypeValues returns an array of possible values for the ApplicationGatewayRequestRoutingRuleType const type.
161func PossibleApplicationGatewayRequestRoutingRuleTypeValues() []ApplicationGatewayRequestRoutingRuleType {
162	return []ApplicationGatewayRequestRoutingRuleType{Basic, PathBasedRouting}
163}
164
165// ApplicationGatewaySkuName enumerates the values for application gateway sku name.
166type ApplicationGatewaySkuName string
167
168const (
169	// StandardLarge ...
170	StandardLarge ApplicationGatewaySkuName = "Standard_Large"
171	// StandardMedium ...
172	StandardMedium ApplicationGatewaySkuName = "Standard_Medium"
173	// StandardSmall ...
174	StandardSmall ApplicationGatewaySkuName = "Standard_Small"
175	// StandardV2 ...
176	StandardV2 ApplicationGatewaySkuName = "Standard_v2"
177	// WAFLarge ...
178	WAFLarge ApplicationGatewaySkuName = "WAF_Large"
179	// WAFMedium ...
180	WAFMedium ApplicationGatewaySkuName = "WAF_Medium"
181	// WAFV2 ...
182	WAFV2 ApplicationGatewaySkuName = "WAF_v2"
183)
184
185// PossibleApplicationGatewaySkuNameValues returns an array of possible values for the ApplicationGatewaySkuName const type.
186func PossibleApplicationGatewaySkuNameValues() []ApplicationGatewaySkuName {
187	return []ApplicationGatewaySkuName{StandardLarge, StandardMedium, StandardSmall, StandardV2, WAFLarge, WAFMedium, WAFV2}
188}
189
190// ApplicationGatewaySslCipherSuite enumerates the values for application gateway ssl cipher suite.
191type ApplicationGatewaySslCipherSuite string
192
193const (
194	// TLSDHEDSSWITHAES128CBCSHA ...
195	TLSDHEDSSWITHAES128CBCSHA ApplicationGatewaySslCipherSuite = "TLS_DHE_DSS_WITH_AES_128_CBC_SHA"
196	// TLSDHEDSSWITHAES128CBCSHA256 ...
197	TLSDHEDSSWITHAES128CBCSHA256 ApplicationGatewaySslCipherSuite = "TLS_DHE_DSS_WITH_AES_128_CBC_SHA256"
198	// TLSDHEDSSWITHAES256CBCSHA ...
199	TLSDHEDSSWITHAES256CBCSHA ApplicationGatewaySslCipherSuite = "TLS_DHE_DSS_WITH_AES_256_CBC_SHA"
200	// TLSDHEDSSWITHAES256CBCSHA256 ...
201	TLSDHEDSSWITHAES256CBCSHA256 ApplicationGatewaySslCipherSuite = "TLS_DHE_DSS_WITH_AES_256_CBC_SHA256"
202	// TLSDHERSAWITHAES128CBCSHA ...
203	TLSDHERSAWITHAES128CBCSHA ApplicationGatewaySslCipherSuite = "TLS_DHE_RSA_WITH_AES_128_CBC_SHA"
204	// TLSDHERSAWITHAES128GCMSHA256 ...
205	TLSDHERSAWITHAES128GCMSHA256 ApplicationGatewaySslCipherSuite = "TLS_DHE_RSA_WITH_AES_128_GCM_SHA256"
206	// TLSDHERSAWITHAES256CBCSHA ...
207	TLSDHERSAWITHAES256CBCSHA ApplicationGatewaySslCipherSuite = "TLS_DHE_RSA_WITH_AES_256_CBC_SHA"
208	// TLSDHERSAWITHAES256GCMSHA384 ...
209	TLSDHERSAWITHAES256GCMSHA384 ApplicationGatewaySslCipherSuite = "TLS_DHE_RSA_WITH_AES_256_GCM_SHA384"
210	// TLSECDHEECDSAWITHAES128CBCSHA ...
211	TLSECDHEECDSAWITHAES128CBCSHA ApplicationGatewaySslCipherSuite = "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA"
212	// TLSECDHEECDSAWITHAES128CBCSHA256 ...
213	TLSECDHEECDSAWITHAES128CBCSHA256 ApplicationGatewaySslCipherSuite = "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256"
214	// TLSECDHEECDSAWITHAES128GCMSHA256 ...
215	TLSECDHEECDSAWITHAES128GCMSHA256 ApplicationGatewaySslCipherSuite = "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256"
216	// TLSECDHEECDSAWITHAES256CBCSHA ...
217	TLSECDHEECDSAWITHAES256CBCSHA ApplicationGatewaySslCipherSuite = "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA"
218	// TLSECDHEECDSAWITHAES256CBCSHA384 ...
219	TLSECDHEECDSAWITHAES256CBCSHA384 ApplicationGatewaySslCipherSuite = "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384"
220	// TLSECDHEECDSAWITHAES256GCMSHA384 ...
221	TLSECDHEECDSAWITHAES256GCMSHA384 ApplicationGatewaySslCipherSuite = "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384"
222	// TLSECDHERSAWITHAES128CBCSHA ...
223	TLSECDHERSAWITHAES128CBCSHA ApplicationGatewaySslCipherSuite = "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA"
224	// TLSECDHERSAWITHAES128CBCSHA256 ...
225	TLSECDHERSAWITHAES128CBCSHA256 ApplicationGatewaySslCipherSuite = "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256"
226	// TLSECDHERSAWITHAES256CBCSHA ...
227	TLSECDHERSAWITHAES256CBCSHA ApplicationGatewaySslCipherSuite = "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA"
228	// TLSECDHERSAWITHAES256CBCSHA384 ...
229	TLSECDHERSAWITHAES256CBCSHA384 ApplicationGatewaySslCipherSuite = "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384"
230	// TLSRSAWITH3DESEDECBCSHA ...
231	TLSRSAWITH3DESEDECBCSHA ApplicationGatewaySslCipherSuite = "TLS_RSA_WITH_3DES_EDE_CBC_SHA"
232	// TLSRSAWITHAES128CBCSHA ...
233	TLSRSAWITHAES128CBCSHA ApplicationGatewaySslCipherSuite = "TLS_RSA_WITH_AES_128_CBC_SHA"
234	// TLSRSAWITHAES128CBCSHA256 ...
235	TLSRSAWITHAES128CBCSHA256 ApplicationGatewaySslCipherSuite = "TLS_RSA_WITH_AES_128_CBC_SHA256"
236	// TLSRSAWITHAES128GCMSHA256 ...
237	TLSRSAWITHAES128GCMSHA256 ApplicationGatewaySslCipherSuite = "TLS_RSA_WITH_AES_128_GCM_SHA256"
238	// TLSRSAWITHAES256CBCSHA ...
239	TLSRSAWITHAES256CBCSHA ApplicationGatewaySslCipherSuite = "TLS_RSA_WITH_AES_256_CBC_SHA"
240	// TLSRSAWITHAES256CBCSHA256 ...
241	TLSRSAWITHAES256CBCSHA256 ApplicationGatewaySslCipherSuite = "TLS_RSA_WITH_AES_256_CBC_SHA256"
242	// TLSRSAWITHAES256GCMSHA384 ...
243	TLSRSAWITHAES256GCMSHA384 ApplicationGatewaySslCipherSuite = "TLS_RSA_WITH_AES_256_GCM_SHA384"
244)
245
246// PossibleApplicationGatewaySslCipherSuiteValues returns an array of possible values for the ApplicationGatewaySslCipherSuite const type.
247func PossibleApplicationGatewaySslCipherSuiteValues() []ApplicationGatewaySslCipherSuite {
248	return []ApplicationGatewaySslCipherSuite{TLSDHEDSSWITHAES128CBCSHA, TLSDHEDSSWITHAES128CBCSHA256, TLSDHEDSSWITHAES256CBCSHA, TLSDHEDSSWITHAES256CBCSHA256, TLSDHERSAWITHAES128CBCSHA, TLSDHERSAWITHAES128GCMSHA256, TLSDHERSAWITHAES256CBCSHA, TLSDHERSAWITHAES256GCMSHA384, TLSECDHEECDSAWITHAES128CBCSHA, TLSECDHEECDSAWITHAES128CBCSHA256, TLSECDHEECDSAWITHAES128GCMSHA256, TLSECDHEECDSAWITHAES256CBCSHA, TLSECDHEECDSAWITHAES256CBCSHA384, TLSECDHEECDSAWITHAES256GCMSHA384, TLSECDHERSAWITHAES128CBCSHA, TLSECDHERSAWITHAES128CBCSHA256, TLSECDHERSAWITHAES256CBCSHA, TLSECDHERSAWITHAES256CBCSHA384, TLSRSAWITH3DESEDECBCSHA, TLSRSAWITHAES128CBCSHA, TLSRSAWITHAES128CBCSHA256, TLSRSAWITHAES128GCMSHA256, TLSRSAWITHAES256CBCSHA, TLSRSAWITHAES256CBCSHA256, TLSRSAWITHAES256GCMSHA384}
249}
250
251// ApplicationGatewaySslPolicyName enumerates the values for application gateway ssl policy name.
252type ApplicationGatewaySslPolicyName string
253
254const (
255	// AppGwSslPolicy20150501 ...
256	AppGwSslPolicy20150501 ApplicationGatewaySslPolicyName = "AppGwSslPolicy20150501"
257	// AppGwSslPolicy20170401 ...
258	AppGwSslPolicy20170401 ApplicationGatewaySslPolicyName = "AppGwSslPolicy20170401"
259	// AppGwSslPolicy20170401S ...
260	AppGwSslPolicy20170401S ApplicationGatewaySslPolicyName = "AppGwSslPolicy20170401S"
261)
262
263// PossibleApplicationGatewaySslPolicyNameValues returns an array of possible values for the ApplicationGatewaySslPolicyName const type.
264func PossibleApplicationGatewaySslPolicyNameValues() []ApplicationGatewaySslPolicyName {
265	return []ApplicationGatewaySslPolicyName{AppGwSslPolicy20150501, AppGwSslPolicy20170401, AppGwSslPolicy20170401S}
266}
267
268// ApplicationGatewaySslPolicyType enumerates the values for application gateway ssl policy type.
269type ApplicationGatewaySslPolicyType string
270
271const (
272	// Custom ...
273	Custom ApplicationGatewaySslPolicyType = "Custom"
274	// Predefined ...
275	Predefined ApplicationGatewaySslPolicyType = "Predefined"
276)
277
278// PossibleApplicationGatewaySslPolicyTypeValues returns an array of possible values for the ApplicationGatewaySslPolicyType const type.
279func PossibleApplicationGatewaySslPolicyTypeValues() []ApplicationGatewaySslPolicyType {
280	return []ApplicationGatewaySslPolicyType{Custom, Predefined}
281}
282
283// ApplicationGatewaySslProtocol enumerates the values for application gateway ssl protocol.
284type ApplicationGatewaySslProtocol string
285
286const (
287	// TLSv10 ...
288	TLSv10 ApplicationGatewaySslProtocol = "TLSv1_0"
289	// TLSv11 ...
290	TLSv11 ApplicationGatewaySslProtocol = "TLSv1_1"
291	// TLSv12 ...
292	TLSv12 ApplicationGatewaySslProtocol = "TLSv1_2"
293)
294
295// PossibleApplicationGatewaySslProtocolValues returns an array of possible values for the ApplicationGatewaySslProtocol const type.
296func PossibleApplicationGatewaySslProtocolValues() []ApplicationGatewaySslProtocol {
297	return []ApplicationGatewaySslProtocol{TLSv10, TLSv11, TLSv12}
298}
299
300// ApplicationGatewayTier enumerates the values for application gateway tier.
301type ApplicationGatewayTier string
302
303const (
304	// ApplicationGatewayTierStandard ...
305	ApplicationGatewayTierStandard ApplicationGatewayTier = "Standard"
306	// ApplicationGatewayTierStandardV2 ...
307	ApplicationGatewayTierStandardV2 ApplicationGatewayTier = "Standard_v2"
308	// ApplicationGatewayTierWAF ...
309	ApplicationGatewayTierWAF ApplicationGatewayTier = "WAF"
310	// ApplicationGatewayTierWAFV2 ...
311	ApplicationGatewayTierWAFV2 ApplicationGatewayTier = "WAF_v2"
312)
313
314// PossibleApplicationGatewayTierValues returns an array of possible values for the ApplicationGatewayTier const type.
315func PossibleApplicationGatewayTierValues() []ApplicationGatewayTier {
316	return []ApplicationGatewayTier{ApplicationGatewayTierStandard, ApplicationGatewayTierStandardV2, ApplicationGatewayTierWAF, ApplicationGatewayTierWAFV2}
317}
318
319// AssociationType enumerates the values for association type.
320type AssociationType string
321
322const (
323	// Associated ...
324	Associated AssociationType = "Associated"
325	// Contains ...
326	Contains AssociationType = "Contains"
327)
328
329// PossibleAssociationTypeValues returns an array of possible values for the AssociationType const type.
330func PossibleAssociationTypeValues() []AssociationType {
331	return []AssociationType{Associated, Contains}
332}
333
334// AuthenticationMethod enumerates the values for authentication method.
335type AuthenticationMethod string
336
337const (
338	// EAPMSCHAPv2 ...
339	EAPMSCHAPv2 AuthenticationMethod = "EAPMSCHAPv2"
340	// EAPTLS ...
341	EAPTLS AuthenticationMethod = "EAPTLS"
342)
343
344// PossibleAuthenticationMethodValues returns an array of possible values for the AuthenticationMethod const type.
345func PossibleAuthenticationMethodValues() []AuthenticationMethod {
346	return []AuthenticationMethod{EAPMSCHAPv2, EAPTLS}
347}
348
349// AuthorizationUseStatus enumerates the values for authorization use status.
350type AuthorizationUseStatus string
351
352const (
353	// Available ...
354	Available AuthorizationUseStatus = "Available"
355	// InUse ...
356	InUse AuthorizationUseStatus = "InUse"
357)
358
359// PossibleAuthorizationUseStatusValues returns an array of possible values for the AuthorizationUseStatus const type.
360func PossibleAuthorizationUseStatusValues() []AuthorizationUseStatus {
361	return []AuthorizationUseStatus{Available, InUse}
362}
363
364// AzureFirewallApplicationRuleProtocolType enumerates the values for azure firewall application rule protocol
365// type.
366type AzureFirewallApplicationRuleProtocolType string
367
368const (
369	// AzureFirewallApplicationRuleProtocolTypeHTTP ...
370	AzureFirewallApplicationRuleProtocolTypeHTTP AzureFirewallApplicationRuleProtocolType = "Http"
371	// AzureFirewallApplicationRuleProtocolTypeHTTPS ...
372	AzureFirewallApplicationRuleProtocolTypeHTTPS AzureFirewallApplicationRuleProtocolType = "Https"
373)
374
375// PossibleAzureFirewallApplicationRuleProtocolTypeValues returns an array of possible values for the AzureFirewallApplicationRuleProtocolType const type.
376func PossibleAzureFirewallApplicationRuleProtocolTypeValues() []AzureFirewallApplicationRuleProtocolType {
377	return []AzureFirewallApplicationRuleProtocolType{AzureFirewallApplicationRuleProtocolTypeHTTP, AzureFirewallApplicationRuleProtocolTypeHTTPS}
378}
379
380// AzureFirewallNatRCActionType enumerates the values for azure firewall nat rc action type.
381type AzureFirewallNatRCActionType string
382
383const (
384	// Dnat ...
385	Dnat AzureFirewallNatRCActionType = "Dnat"
386	// Snat ...
387	Snat AzureFirewallNatRCActionType = "Snat"
388)
389
390// PossibleAzureFirewallNatRCActionTypeValues returns an array of possible values for the AzureFirewallNatRCActionType const type.
391func PossibleAzureFirewallNatRCActionTypeValues() []AzureFirewallNatRCActionType {
392	return []AzureFirewallNatRCActionType{Dnat, Snat}
393}
394
395// AzureFirewallNetworkRuleProtocol enumerates the values for azure firewall network rule protocol.
396type AzureFirewallNetworkRuleProtocol string
397
398const (
399	// Any ...
400	Any AzureFirewallNetworkRuleProtocol = "Any"
401	// TCP ...
402	TCP AzureFirewallNetworkRuleProtocol = "TCP"
403	// UDP ...
404	UDP AzureFirewallNetworkRuleProtocol = "UDP"
405)
406
407// PossibleAzureFirewallNetworkRuleProtocolValues returns an array of possible values for the AzureFirewallNetworkRuleProtocol const type.
408func PossibleAzureFirewallNetworkRuleProtocolValues() []AzureFirewallNetworkRuleProtocol {
409	return []AzureFirewallNetworkRuleProtocol{Any, TCP, UDP}
410}
411
412// AzureFirewallRCActionType enumerates the values for azure firewall rc action type.
413type AzureFirewallRCActionType string
414
415const (
416	// AzureFirewallRCActionTypeAllow ...
417	AzureFirewallRCActionTypeAllow AzureFirewallRCActionType = "Allow"
418	// AzureFirewallRCActionTypeDeny ...
419	AzureFirewallRCActionTypeDeny AzureFirewallRCActionType = "Deny"
420)
421
422// PossibleAzureFirewallRCActionTypeValues returns an array of possible values for the AzureFirewallRCActionType const type.
423func PossibleAzureFirewallRCActionTypeValues() []AzureFirewallRCActionType {
424	return []AzureFirewallRCActionType{AzureFirewallRCActionTypeAllow, AzureFirewallRCActionTypeDeny}
425}
426
427// BgpPeerState enumerates the values for bgp peer state.
428type BgpPeerState string
429
430const (
431	// BgpPeerStateConnected ...
432	BgpPeerStateConnected BgpPeerState = "Connected"
433	// BgpPeerStateConnecting ...
434	BgpPeerStateConnecting BgpPeerState = "Connecting"
435	// BgpPeerStateIdle ...
436	BgpPeerStateIdle BgpPeerState = "Idle"
437	// BgpPeerStateStopped ...
438	BgpPeerStateStopped BgpPeerState = "Stopped"
439	// BgpPeerStateUnknown ...
440	BgpPeerStateUnknown BgpPeerState = "Unknown"
441)
442
443// PossibleBgpPeerStateValues returns an array of possible values for the BgpPeerState const type.
444func PossibleBgpPeerStateValues() []BgpPeerState {
445	return []BgpPeerState{BgpPeerStateConnected, BgpPeerStateConnecting, BgpPeerStateIdle, BgpPeerStateStopped, BgpPeerStateUnknown}
446}
447
448// CircuitConnectionStatus enumerates the values for circuit connection status.
449type CircuitConnectionStatus string
450
451const (
452	// Connected ...
453	Connected CircuitConnectionStatus = "Connected"
454	// Connecting ...
455	Connecting CircuitConnectionStatus = "Connecting"
456	// Disconnected ...
457	Disconnected CircuitConnectionStatus = "Disconnected"
458)
459
460// PossibleCircuitConnectionStatusValues returns an array of possible values for the CircuitConnectionStatus const type.
461func PossibleCircuitConnectionStatusValues() []CircuitConnectionStatus {
462	return []CircuitConnectionStatus{Connected, Connecting, Disconnected}
463}
464
465// ConnectionMonitorSourceStatus enumerates the values for connection monitor source status.
466type ConnectionMonitorSourceStatus string
467
468const (
469	// Active ...
470	Active ConnectionMonitorSourceStatus = "Active"
471	// Inactive ...
472	Inactive ConnectionMonitorSourceStatus = "Inactive"
473	// Uknown ...
474	Uknown ConnectionMonitorSourceStatus = "Uknown"
475)
476
477// PossibleConnectionMonitorSourceStatusValues returns an array of possible values for the ConnectionMonitorSourceStatus const type.
478func PossibleConnectionMonitorSourceStatusValues() []ConnectionMonitorSourceStatus {
479	return []ConnectionMonitorSourceStatus{Active, Inactive, Uknown}
480}
481
482// ConnectionState enumerates the values for connection state.
483type ConnectionState string
484
485const (
486	// ConnectionStateReachable ...
487	ConnectionStateReachable ConnectionState = "Reachable"
488	// ConnectionStateUnknown ...
489	ConnectionStateUnknown ConnectionState = "Unknown"
490	// ConnectionStateUnreachable ...
491	ConnectionStateUnreachable ConnectionState = "Unreachable"
492)
493
494// PossibleConnectionStateValues returns an array of possible values for the ConnectionState const type.
495func PossibleConnectionStateValues() []ConnectionState {
496	return []ConnectionState{ConnectionStateReachable, ConnectionStateUnknown, ConnectionStateUnreachable}
497}
498
499// ConnectionStatus enumerates the values for connection status.
500type ConnectionStatus string
501
502const (
503	// ConnectionStatusConnected ...
504	ConnectionStatusConnected ConnectionStatus = "Connected"
505	// ConnectionStatusDegraded ...
506	ConnectionStatusDegraded ConnectionStatus = "Degraded"
507	// ConnectionStatusDisconnected ...
508	ConnectionStatusDisconnected ConnectionStatus = "Disconnected"
509	// ConnectionStatusUnknown ...
510	ConnectionStatusUnknown ConnectionStatus = "Unknown"
511)
512
513// PossibleConnectionStatusValues returns an array of possible values for the ConnectionStatus const type.
514func PossibleConnectionStatusValues() []ConnectionStatus {
515	return []ConnectionStatus{ConnectionStatusConnected, ConnectionStatusDegraded, ConnectionStatusDisconnected, ConnectionStatusUnknown}
516}
517
518// DhGroup enumerates the values for dh group.
519type DhGroup string
520
521const (
522	// DHGroup1 ...
523	DHGroup1 DhGroup = "DHGroup1"
524	// DHGroup14 ...
525	DHGroup14 DhGroup = "DHGroup14"
526	// DHGroup2 ...
527	DHGroup2 DhGroup = "DHGroup2"
528	// DHGroup2048 ...
529	DHGroup2048 DhGroup = "DHGroup2048"
530	// DHGroup24 ...
531	DHGroup24 DhGroup = "DHGroup24"
532	// ECP256 ...
533	ECP256 DhGroup = "ECP256"
534	// ECP384 ...
535	ECP384 DhGroup = "ECP384"
536	// None ...
537	None DhGroup = "None"
538)
539
540// PossibleDhGroupValues returns an array of possible values for the DhGroup const type.
541func PossibleDhGroupValues() []DhGroup {
542	return []DhGroup{DHGroup1, DHGroup14, DHGroup2, DHGroup2048, DHGroup24, ECP256, ECP384, None}
543}
544
545// Direction enumerates the values for direction.
546type Direction string
547
548const (
549	// Inbound ...
550	Inbound Direction = "Inbound"
551	// Outbound ...
552	Outbound Direction = "Outbound"
553)
554
555// PossibleDirectionValues returns an array of possible values for the Direction const type.
556func PossibleDirectionValues() []Direction {
557	return []Direction{Inbound, Outbound}
558}
559
560// EffectiveRouteSource enumerates the values for effective route source.
561type EffectiveRouteSource string
562
563const (
564	// EffectiveRouteSourceDefault ...
565	EffectiveRouteSourceDefault EffectiveRouteSource = "Default"
566	// EffectiveRouteSourceUnknown ...
567	EffectiveRouteSourceUnknown EffectiveRouteSource = "Unknown"
568	// EffectiveRouteSourceUser ...
569	EffectiveRouteSourceUser EffectiveRouteSource = "User"
570	// EffectiveRouteSourceVirtualNetworkGateway ...
571	EffectiveRouteSourceVirtualNetworkGateway EffectiveRouteSource = "VirtualNetworkGateway"
572)
573
574// PossibleEffectiveRouteSourceValues returns an array of possible values for the EffectiveRouteSource const type.
575func PossibleEffectiveRouteSourceValues() []EffectiveRouteSource {
576	return []EffectiveRouteSource{EffectiveRouteSourceDefault, EffectiveRouteSourceUnknown, EffectiveRouteSourceUser, EffectiveRouteSourceVirtualNetworkGateway}
577}
578
579// EffectiveRouteState enumerates the values for effective route state.
580type EffectiveRouteState string
581
582const (
583	// EffectiveRouteStateActive ...
584	EffectiveRouteStateActive EffectiveRouteState = "Active"
585	// EffectiveRouteStateInvalid ...
586	EffectiveRouteStateInvalid EffectiveRouteState = "Invalid"
587)
588
589// PossibleEffectiveRouteStateValues returns an array of possible values for the EffectiveRouteState const type.
590func PossibleEffectiveRouteStateValues() []EffectiveRouteState {
591	return []EffectiveRouteState{EffectiveRouteStateActive, EffectiveRouteStateInvalid}
592}
593
594// EffectiveSecurityRuleProtocol enumerates the values for effective security rule protocol.
595type EffectiveSecurityRuleProtocol string
596
597const (
598	// EffectiveSecurityRuleProtocolAll ...
599	EffectiveSecurityRuleProtocolAll EffectiveSecurityRuleProtocol = "All"
600	// EffectiveSecurityRuleProtocolTCP ...
601	EffectiveSecurityRuleProtocolTCP EffectiveSecurityRuleProtocol = "Tcp"
602	// EffectiveSecurityRuleProtocolUDP ...
603	EffectiveSecurityRuleProtocolUDP EffectiveSecurityRuleProtocol = "Udp"
604)
605
606// PossibleEffectiveSecurityRuleProtocolValues returns an array of possible values for the EffectiveSecurityRuleProtocol const type.
607func PossibleEffectiveSecurityRuleProtocolValues() []EffectiveSecurityRuleProtocol {
608	return []EffectiveSecurityRuleProtocol{EffectiveSecurityRuleProtocolAll, EffectiveSecurityRuleProtocolTCP, EffectiveSecurityRuleProtocolUDP}
609}
610
611// EvaluationState enumerates the values for evaluation state.
612type EvaluationState string
613
614const (
615	// Completed ...
616	Completed EvaluationState = "Completed"
617	// InProgress ...
618	InProgress EvaluationState = "InProgress"
619	// NotStarted ...
620	NotStarted EvaluationState = "NotStarted"
621)
622
623// PossibleEvaluationStateValues returns an array of possible values for the EvaluationState const type.
624func PossibleEvaluationStateValues() []EvaluationState {
625	return []EvaluationState{Completed, InProgress, NotStarted}
626}
627
628// ExpressRouteCircuitPeeringAdvertisedPublicPrefixState enumerates the values for express route circuit
629// peering advertised public prefix state.
630type ExpressRouteCircuitPeeringAdvertisedPublicPrefixState string
631
632const (
633	// Configured ...
634	Configured ExpressRouteCircuitPeeringAdvertisedPublicPrefixState = "Configured"
635	// Configuring ...
636	Configuring ExpressRouteCircuitPeeringAdvertisedPublicPrefixState = "Configuring"
637	// NotConfigured ...
638	NotConfigured ExpressRouteCircuitPeeringAdvertisedPublicPrefixState = "NotConfigured"
639	// ValidationNeeded ...
640	ValidationNeeded ExpressRouteCircuitPeeringAdvertisedPublicPrefixState = "ValidationNeeded"
641)
642
643// PossibleExpressRouteCircuitPeeringAdvertisedPublicPrefixStateValues returns an array of possible values for the ExpressRouteCircuitPeeringAdvertisedPublicPrefixState const type.
644func PossibleExpressRouteCircuitPeeringAdvertisedPublicPrefixStateValues() []ExpressRouteCircuitPeeringAdvertisedPublicPrefixState {
645	return []ExpressRouteCircuitPeeringAdvertisedPublicPrefixState{Configured, Configuring, NotConfigured, ValidationNeeded}
646}
647
648// ExpressRouteCircuitPeeringState enumerates the values for express route circuit peering state.
649type ExpressRouteCircuitPeeringState string
650
651const (
652	// ExpressRouteCircuitPeeringStateDisabled ...
653	ExpressRouteCircuitPeeringStateDisabled ExpressRouteCircuitPeeringState = "Disabled"
654	// ExpressRouteCircuitPeeringStateEnabled ...
655	ExpressRouteCircuitPeeringStateEnabled ExpressRouteCircuitPeeringState = "Enabled"
656)
657
658// PossibleExpressRouteCircuitPeeringStateValues returns an array of possible values for the ExpressRouteCircuitPeeringState const type.
659func PossibleExpressRouteCircuitPeeringStateValues() []ExpressRouteCircuitPeeringState {
660	return []ExpressRouteCircuitPeeringState{ExpressRouteCircuitPeeringStateDisabled, ExpressRouteCircuitPeeringStateEnabled}
661}
662
663// ExpressRouteCircuitSkuFamily enumerates the values for express route circuit sku family.
664type ExpressRouteCircuitSkuFamily string
665
666const (
667	// MeteredData ...
668	MeteredData ExpressRouteCircuitSkuFamily = "MeteredData"
669	// UnlimitedData ...
670	UnlimitedData ExpressRouteCircuitSkuFamily = "UnlimitedData"
671)
672
673// PossibleExpressRouteCircuitSkuFamilyValues returns an array of possible values for the ExpressRouteCircuitSkuFamily const type.
674func PossibleExpressRouteCircuitSkuFamilyValues() []ExpressRouteCircuitSkuFamily {
675	return []ExpressRouteCircuitSkuFamily{MeteredData, UnlimitedData}
676}
677
678// ExpressRouteCircuitSkuTier enumerates the values for express route circuit sku tier.
679type ExpressRouteCircuitSkuTier string
680
681const (
682	// Premium ...
683	Premium ExpressRouteCircuitSkuTier = "Premium"
684	// Standard ...
685	Standard ExpressRouteCircuitSkuTier = "Standard"
686)
687
688// PossibleExpressRouteCircuitSkuTierValues returns an array of possible values for the ExpressRouteCircuitSkuTier const type.
689func PossibleExpressRouteCircuitSkuTierValues() []ExpressRouteCircuitSkuTier {
690	return []ExpressRouteCircuitSkuTier{Premium, Standard}
691}
692
693// ExpressRoutePeeringState enumerates the values for express route peering state.
694type ExpressRoutePeeringState string
695
696const (
697	// ExpressRoutePeeringStateDisabled ...
698	ExpressRoutePeeringStateDisabled ExpressRoutePeeringState = "Disabled"
699	// ExpressRoutePeeringStateEnabled ...
700	ExpressRoutePeeringStateEnabled ExpressRoutePeeringState = "Enabled"
701)
702
703// PossibleExpressRoutePeeringStateValues returns an array of possible values for the ExpressRoutePeeringState const type.
704func PossibleExpressRoutePeeringStateValues() []ExpressRoutePeeringState {
705	return []ExpressRoutePeeringState{ExpressRoutePeeringStateDisabled, ExpressRoutePeeringStateEnabled}
706}
707
708// ExpressRoutePeeringType enumerates the values for express route peering type.
709type ExpressRoutePeeringType string
710
711const (
712	// AzurePrivatePeering ...
713	AzurePrivatePeering ExpressRoutePeeringType = "AzurePrivatePeering"
714	// AzurePublicPeering ...
715	AzurePublicPeering ExpressRoutePeeringType = "AzurePublicPeering"
716	// MicrosoftPeering ...
717	MicrosoftPeering ExpressRoutePeeringType = "MicrosoftPeering"
718)
719
720// PossibleExpressRoutePeeringTypeValues returns an array of possible values for the ExpressRoutePeeringType const type.
721func PossibleExpressRoutePeeringTypeValues() []ExpressRoutePeeringType {
722	return []ExpressRoutePeeringType{AzurePrivatePeering, AzurePublicPeering, MicrosoftPeering}
723}
724
725// HTTPMethod enumerates the values for http method.
726type HTTPMethod string
727
728const (
729	// Get ...
730	Get HTTPMethod = "Get"
731)
732
733// PossibleHTTPMethodValues returns an array of possible values for the HTTPMethod const type.
734func PossibleHTTPMethodValues() []HTTPMethod {
735	return []HTTPMethod{Get}
736}
737
738// HubVirtualNetworkConnectionStatus enumerates the values for hub virtual network connection status.
739type HubVirtualNetworkConnectionStatus string
740
741const (
742	// HubVirtualNetworkConnectionStatusConnected ...
743	HubVirtualNetworkConnectionStatusConnected HubVirtualNetworkConnectionStatus = "Connected"
744	// HubVirtualNetworkConnectionStatusConnecting ...
745	HubVirtualNetworkConnectionStatusConnecting HubVirtualNetworkConnectionStatus = "Connecting"
746	// HubVirtualNetworkConnectionStatusNotConnected ...
747	HubVirtualNetworkConnectionStatusNotConnected HubVirtualNetworkConnectionStatus = "NotConnected"
748	// HubVirtualNetworkConnectionStatusUnknown ...
749	HubVirtualNetworkConnectionStatusUnknown HubVirtualNetworkConnectionStatus = "Unknown"
750)
751
752// PossibleHubVirtualNetworkConnectionStatusValues returns an array of possible values for the HubVirtualNetworkConnectionStatus const type.
753func PossibleHubVirtualNetworkConnectionStatusValues() []HubVirtualNetworkConnectionStatus {
754	return []HubVirtualNetworkConnectionStatus{HubVirtualNetworkConnectionStatusConnected, HubVirtualNetworkConnectionStatusConnecting, HubVirtualNetworkConnectionStatusNotConnected, HubVirtualNetworkConnectionStatusUnknown}
755}
756
757// IkeEncryption enumerates the values for ike encryption.
758type IkeEncryption string
759
760const (
761	// AES128 ...
762	AES128 IkeEncryption = "AES128"
763	// AES192 ...
764	AES192 IkeEncryption = "AES192"
765	// AES256 ...
766	AES256 IkeEncryption = "AES256"
767	// DES ...
768	DES IkeEncryption = "DES"
769	// DES3 ...
770	DES3 IkeEncryption = "DES3"
771	// GCMAES128 ...
772	GCMAES128 IkeEncryption = "GCMAES128"
773	// GCMAES256 ...
774	GCMAES256 IkeEncryption = "GCMAES256"
775)
776
777// PossibleIkeEncryptionValues returns an array of possible values for the IkeEncryption const type.
778func PossibleIkeEncryptionValues() []IkeEncryption {
779	return []IkeEncryption{AES128, AES192, AES256, DES, DES3, GCMAES128, GCMAES256}
780}
781
782// IkeIntegrity enumerates the values for ike integrity.
783type IkeIntegrity string
784
785const (
786	// IkeIntegrityGCMAES128 ...
787	IkeIntegrityGCMAES128 IkeIntegrity = "GCMAES128"
788	// IkeIntegrityGCMAES256 ...
789	IkeIntegrityGCMAES256 IkeIntegrity = "GCMAES256"
790	// IkeIntegrityMD5 ...
791	IkeIntegrityMD5 IkeIntegrity = "MD5"
792	// IkeIntegritySHA1 ...
793	IkeIntegritySHA1 IkeIntegrity = "SHA1"
794	// IkeIntegritySHA256 ...
795	IkeIntegritySHA256 IkeIntegrity = "SHA256"
796	// IkeIntegritySHA384 ...
797	IkeIntegritySHA384 IkeIntegrity = "SHA384"
798)
799
800// PossibleIkeIntegrityValues returns an array of possible values for the IkeIntegrity const type.
801func PossibleIkeIntegrityValues() []IkeIntegrity {
802	return []IkeIntegrity{IkeIntegrityGCMAES128, IkeIntegrityGCMAES256, IkeIntegrityMD5, IkeIntegritySHA1, IkeIntegritySHA256, IkeIntegritySHA384}
803}
804
805// IPAllocationMethod enumerates the values for ip allocation method.
806type IPAllocationMethod string
807
808const (
809	// Dynamic ...
810	Dynamic IPAllocationMethod = "Dynamic"
811	// Static ...
812	Static IPAllocationMethod = "Static"
813)
814
815// PossibleIPAllocationMethodValues returns an array of possible values for the IPAllocationMethod const type.
816func PossibleIPAllocationMethodValues() []IPAllocationMethod {
817	return []IPAllocationMethod{Dynamic, Static}
818}
819
820// IPFlowProtocol enumerates the values for ip flow protocol.
821type IPFlowProtocol string
822
823const (
824	// IPFlowProtocolTCP ...
825	IPFlowProtocolTCP IPFlowProtocol = "TCP"
826	// IPFlowProtocolUDP ...
827	IPFlowProtocolUDP IPFlowProtocol = "UDP"
828)
829
830// PossibleIPFlowProtocolValues returns an array of possible values for the IPFlowProtocol const type.
831func PossibleIPFlowProtocolValues() []IPFlowProtocol {
832	return []IPFlowProtocol{IPFlowProtocolTCP, IPFlowProtocolUDP}
833}
834
835// IpsecEncryption enumerates the values for ipsec encryption.
836type IpsecEncryption string
837
838const (
839	// IpsecEncryptionAES128 ...
840	IpsecEncryptionAES128 IpsecEncryption = "AES128"
841	// IpsecEncryptionAES192 ...
842	IpsecEncryptionAES192 IpsecEncryption = "AES192"
843	// IpsecEncryptionAES256 ...
844	IpsecEncryptionAES256 IpsecEncryption = "AES256"
845	// IpsecEncryptionDES ...
846	IpsecEncryptionDES IpsecEncryption = "DES"
847	// IpsecEncryptionDES3 ...
848	IpsecEncryptionDES3 IpsecEncryption = "DES3"
849	// IpsecEncryptionGCMAES128 ...
850	IpsecEncryptionGCMAES128 IpsecEncryption = "GCMAES128"
851	// IpsecEncryptionGCMAES192 ...
852	IpsecEncryptionGCMAES192 IpsecEncryption = "GCMAES192"
853	// IpsecEncryptionGCMAES256 ...
854	IpsecEncryptionGCMAES256 IpsecEncryption = "GCMAES256"
855	// IpsecEncryptionNone ...
856	IpsecEncryptionNone IpsecEncryption = "None"
857)
858
859// PossibleIpsecEncryptionValues returns an array of possible values for the IpsecEncryption const type.
860func PossibleIpsecEncryptionValues() []IpsecEncryption {
861	return []IpsecEncryption{IpsecEncryptionAES128, IpsecEncryptionAES192, IpsecEncryptionAES256, IpsecEncryptionDES, IpsecEncryptionDES3, IpsecEncryptionGCMAES128, IpsecEncryptionGCMAES192, IpsecEncryptionGCMAES256, IpsecEncryptionNone}
862}
863
864// IpsecIntegrity enumerates the values for ipsec integrity.
865type IpsecIntegrity string
866
867const (
868	// IpsecIntegrityGCMAES128 ...
869	IpsecIntegrityGCMAES128 IpsecIntegrity = "GCMAES128"
870	// IpsecIntegrityGCMAES192 ...
871	IpsecIntegrityGCMAES192 IpsecIntegrity = "GCMAES192"
872	// IpsecIntegrityGCMAES256 ...
873	IpsecIntegrityGCMAES256 IpsecIntegrity = "GCMAES256"
874	// IpsecIntegrityMD5 ...
875	IpsecIntegrityMD5 IpsecIntegrity = "MD5"
876	// IpsecIntegritySHA1 ...
877	IpsecIntegritySHA1 IpsecIntegrity = "SHA1"
878	// IpsecIntegritySHA256 ...
879	IpsecIntegritySHA256 IpsecIntegrity = "SHA256"
880)
881
882// PossibleIpsecIntegrityValues returns an array of possible values for the IpsecIntegrity const type.
883func PossibleIpsecIntegrityValues() []IpsecIntegrity {
884	return []IpsecIntegrity{IpsecIntegrityGCMAES128, IpsecIntegrityGCMAES192, IpsecIntegrityGCMAES256, IpsecIntegrityMD5, IpsecIntegritySHA1, IpsecIntegritySHA256}
885}
886
887// IPVersion enumerates the values for ip version.
888type IPVersion string
889
890const (
891	// IPv4 ...
892	IPv4 IPVersion = "IPv4"
893	// IPv6 ...
894	IPv6 IPVersion = "IPv6"
895)
896
897// PossibleIPVersionValues returns an array of possible values for the IPVersion const type.
898func PossibleIPVersionValues() []IPVersion {
899	return []IPVersion{IPv4, IPv6}
900}
901
902// IssueType enumerates the values for issue type.
903type IssueType string
904
905const (
906	// IssueTypeAgentStopped ...
907	IssueTypeAgentStopped IssueType = "AgentStopped"
908	// IssueTypeDNSResolution ...
909	IssueTypeDNSResolution IssueType = "DnsResolution"
910	// IssueTypeGuestFirewall ...
911	IssueTypeGuestFirewall IssueType = "GuestFirewall"
912	// IssueTypeNetworkSecurityRule ...
913	IssueTypeNetworkSecurityRule IssueType = "NetworkSecurityRule"
914	// IssueTypePlatform ...
915	IssueTypePlatform IssueType = "Platform"
916	// IssueTypePortThrottled ...
917	IssueTypePortThrottled IssueType = "PortThrottled"
918	// IssueTypeSocketBind ...
919	IssueTypeSocketBind IssueType = "SocketBind"
920	// IssueTypeUnknown ...
921	IssueTypeUnknown IssueType = "Unknown"
922	// IssueTypeUserDefinedRoute ...
923	IssueTypeUserDefinedRoute IssueType = "UserDefinedRoute"
924)
925
926// PossibleIssueTypeValues returns an array of possible values for the IssueType const type.
927func PossibleIssueTypeValues() []IssueType {
928	return []IssueType{IssueTypeAgentStopped, IssueTypeDNSResolution, IssueTypeGuestFirewall, IssueTypeNetworkSecurityRule, IssueTypePlatform, IssueTypePortThrottled, IssueTypeSocketBind, IssueTypeUnknown, IssueTypeUserDefinedRoute}
929}
930
931// LoadBalancerSkuName enumerates the values for load balancer sku name.
932type LoadBalancerSkuName string
933
934const (
935	// LoadBalancerSkuNameBasic ...
936	LoadBalancerSkuNameBasic LoadBalancerSkuName = "Basic"
937	// LoadBalancerSkuNameStandard ...
938	LoadBalancerSkuNameStandard LoadBalancerSkuName = "Standard"
939)
940
941// PossibleLoadBalancerSkuNameValues returns an array of possible values for the LoadBalancerSkuName const type.
942func PossibleLoadBalancerSkuNameValues() []LoadBalancerSkuName {
943	return []LoadBalancerSkuName{LoadBalancerSkuNameBasic, LoadBalancerSkuNameStandard}
944}
945
946// LoadDistribution enumerates the values for load distribution.
947type LoadDistribution string
948
949const (
950	// Default ...
951	Default LoadDistribution = "Default"
952	// SourceIP ...
953	SourceIP LoadDistribution = "SourceIP"
954	// SourceIPProtocol ...
955	SourceIPProtocol LoadDistribution = "SourceIPProtocol"
956)
957
958// PossibleLoadDistributionValues returns an array of possible values for the LoadDistribution const type.
959func PossibleLoadDistributionValues() []LoadDistribution {
960	return []LoadDistribution{Default, SourceIP, SourceIPProtocol}
961}
962
963// NextHopType enumerates the values for next hop type.
964type NextHopType string
965
966const (
967	// NextHopTypeHyperNetGateway ...
968	NextHopTypeHyperNetGateway NextHopType = "HyperNetGateway"
969	// NextHopTypeInternet ...
970	NextHopTypeInternet NextHopType = "Internet"
971	// NextHopTypeNone ...
972	NextHopTypeNone NextHopType = "None"
973	// NextHopTypeVirtualAppliance ...
974	NextHopTypeVirtualAppliance NextHopType = "VirtualAppliance"
975	// NextHopTypeVirtualNetworkGateway ...
976	NextHopTypeVirtualNetworkGateway NextHopType = "VirtualNetworkGateway"
977	// NextHopTypeVnetLocal ...
978	NextHopTypeVnetLocal NextHopType = "VnetLocal"
979)
980
981// PossibleNextHopTypeValues returns an array of possible values for the NextHopType const type.
982func PossibleNextHopTypeValues() []NextHopType {
983	return []NextHopType{NextHopTypeHyperNetGateway, NextHopTypeInternet, NextHopTypeNone, NextHopTypeVirtualAppliance, NextHopTypeVirtualNetworkGateway, NextHopTypeVnetLocal}
984}
985
986// OfficeTrafficCategory enumerates the values for office traffic category.
987type OfficeTrafficCategory string
988
989const (
990	// OfficeTrafficCategoryAll ...
991	OfficeTrafficCategoryAll OfficeTrafficCategory = "All"
992	// OfficeTrafficCategoryNone ...
993	OfficeTrafficCategoryNone OfficeTrafficCategory = "None"
994	// OfficeTrafficCategoryOptimize ...
995	OfficeTrafficCategoryOptimize OfficeTrafficCategory = "Optimize"
996	// OfficeTrafficCategoryOptimizeAndAllow ...
997	OfficeTrafficCategoryOptimizeAndAllow OfficeTrafficCategory = "OptimizeAndAllow"
998)
999
1000// PossibleOfficeTrafficCategoryValues returns an array of possible values for the OfficeTrafficCategory const type.
1001func PossibleOfficeTrafficCategoryValues() []OfficeTrafficCategory {
1002	return []OfficeTrafficCategory{OfficeTrafficCategoryAll, OfficeTrafficCategoryNone, OfficeTrafficCategoryOptimize, OfficeTrafficCategoryOptimizeAndAllow}
1003}
1004
1005// OperationStatus enumerates the values for operation status.
1006type OperationStatus string
1007
1008const (
1009	// OperationStatusFailed ...
1010	OperationStatusFailed OperationStatus = "Failed"
1011	// OperationStatusInProgress ...
1012	OperationStatusInProgress OperationStatus = "InProgress"
1013	// OperationStatusSucceeded ...
1014	OperationStatusSucceeded OperationStatus = "Succeeded"
1015)
1016
1017// PossibleOperationStatusValues returns an array of possible values for the OperationStatus const type.
1018func PossibleOperationStatusValues() []OperationStatus {
1019	return []OperationStatus{OperationStatusFailed, OperationStatusInProgress, OperationStatusSucceeded}
1020}
1021
1022// Origin enumerates the values for origin.
1023type Origin string
1024
1025const (
1026	// OriginInbound ...
1027	OriginInbound Origin = "Inbound"
1028	// OriginLocal ...
1029	OriginLocal Origin = "Local"
1030	// OriginOutbound ...
1031	OriginOutbound Origin = "Outbound"
1032)
1033
1034// PossibleOriginValues returns an array of possible values for the Origin const type.
1035func PossibleOriginValues() []Origin {
1036	return []Origin{OriginInbound, OriginLocal, OriginOutbound}
1037}
1038
1039// PcError enumerates the values for pc error.
1040type PcError string
1041
1042const (
1043	// AgentStopped ...
1044	AgentStopped PcError = "AgentStopped"
1045	// CaptureFailed ...
1046	CaptureFailed PcError = "CaptureFailed"
1047	// InternalError ...
1048	InternalError PcError = "InternalError"
1049	// LocalFileFailed ...
1050	LocalFileFailed PcError = "LocalFileFailed"
1051	// StorageFailed ...
1052	StorageFailed PcError = "StorageFailed"
1053)
1054
1055// PossiblePcErrorValues returns an array of possible values for the PcError const type.
1056func PossiblePcErrorValues() []PcError {
1057	return []PcError{AgentStopped, CaptureFailed, InternalError, LocalFileFailed, StorageFailed}
1058}
1059
1060// PcProtocol enumerates the values for pc protocol.
1061type PcProtocol string
1062
1063const (
1064	// PcProtocolAny ...
1065	PcProtocolAny PcProtocol = "Any"
1066	// PcProtocolTCP ...
1067	PcProtocolTCP PcProtocol = "TCP"
1068	// PcProtocolUDP ...
1069	PcProtocolUDP PcProtocol = "UDP"
1070)
1071
1072// PossiblePcProtocolValues returns an array of possible values for the PcProtocol const type.
1073func PossiblePcProtocolValues() []PcProtocol {
1074	return []PcProtocol{PcProtocolAny, PcProtocolTCP, PcProtocolUDP}
1075}
1076
1077// PcStatus enumerates the values for pc status.
1078type PcStatus string
1079
1080const (
1081	// PcStatusError ...
1082	PcStatusError PcStatus = "Error"
1083	// PcStatusNotStarted ...
1084	PcStatusNotStarted PcStatus = "NotStarted"
1085	// PcStatusRunning ...
1086	PcStatusRunning PcStatus = "Running"
1087	// PcStatusStopped ...
1088	PcStatusStopped PcStatus = "Stopped"
1089	// PcStatusUnknown ...
1090	PcStatusUnknown PcStatus = "Unknown"
1091)
1092
1093// PossiblePcStatusValues returns an array of possible values for the PcStatus const type.
1094func PossiblePcStatusValues() []PcStatus {
1095	return []PcStatus{PcStatusError, PcStatusNotStarted, PcStatusRunning, PcStatusStopped, PcStatusUnknown}
1096}
1097
1098// PfsGroup enumerates the values for pfs group.
1099type PfsGroup string
1100
1101const (
1102	// PfsGroupECP256 ...
1103	PfsGroupECP256 PfsGroup = "ECP256"
1104	// PfsGroupECP384 ...
1105	PfsGroupECP384 PfsGroup = "ECP384"
1106	// PfsGroupNone ...
1107	PfsGroupNone PfsGroup = "None"
1108	// PfsGroupPFS1 ...
1109	PfsGroupPFS1 PfsGroup = "PFS1"
1110	// PfsGroupPFS14 ...
1111	PfsGroupPFS14 PfsGroup = "PFS14"
1112	// PfsGroupPFS2 ...
1113	PfsGroupPFS2 PfsGroup = "PFS2"
1114	// PfsGroupPFS2048 ...
1115	PfsGroupPFS2048 PfsGroup = "PFS2048"
1116	// PfsGroupPFS24 ...
1117	PfsGroupPFS24 PfsGroup = "PFS24"
1118	// PfsGroupPFSMM ...
1119	PfsGroupPFSMM PfsGroup = "PFSMM"
1120)
1121
1122// PossiblePfsGroupValues returns an array of possible values for the PfsGroup const type.
1123func PossiblePfsGroupValues() []PfsGroup {
1124	return []PfsGroup{PfsGroupECP256, PfsGroupECP384, PfsGroupNone, PfsGroupPFS1, PfsGroupPFS14, PfsGroupPFS2, PfsGroupPFS2048, PfsGroupPFS24, PfsGroupPFSMM}
1125}
1126
1127// ProbeProtocol enumerates the values for probe protocol.
1128type ProbeProtocol string
1129
1130const (
1131	// ProbeProtocolHTTP ...
1132	ProbeProtocolHTTP ProbeProtocol = "Http"
1133	// ProbeProtocolHTTPS ...
1134	ProbeProtocolHTTPS ProbeProtocol = "Https"
1135	// ProbeProtocolTCP ...
1136	ProbeProtocolTCP ProbeProtocol = "Tcp"
1137)
1138
1139// PossibleProbeProtocolValues returns an array of possible values for the ProbeProtocol const type.
1140func PossibleProbeProtocolValues() []ProbeProtocol {
1141	return []ProbeProtocol{ProbeProtocolHTTP, ProbeProtocolHTTPS, ProbeProtocolTCP}
1142}
1143
1144// ProcessorArchitecture enumerates the values for processor architecture.
1145type ProcessorArchitecture string
1146
1147const (
1148	// Amd64 ...
1149	Amd64 ProcessorArchitecture = "Amd64"
1150	// X86 ...
1151	X86 ProcessorArchitecture = "X86"
1152)
1153
1154// PossibleProcessorArchitectureValues returns an array of possible values for the ProcessorArchitecture const type.
1155func PossibleProcessorArchitectureValues() []ProcessorArchitecture {
1156	return []ProcessorArchitecture{Amd64, X86}
1157}
1158
1159// Protocol enumerates the values for protocol.
1160type Protocol string
1161
1162const (
1163	// ProtocolHTTP ...
1164	ProtocolHTTP Protocol = "Http"
1165	// ProtocolHTTPS ...
1166	ProtocolHTTPS Protocol = "Https"
1167	// ProtocolIcmp ...
1168	ProtocolIcmp Protocol = "Icmp"
1169	// ProtocolTCP ...
1170	ProtocolTCP Protocol = "Tcp"
1171)
1172
1173// PossibleProtocolValues returns an array of possible values for the Protocol const type.
1174func PossibleProtocolValues() []Protocol {
1175	return []Protocol{ProtocolHTTP, ProtocolHTTPS, ProtocolIcmp, ProtocolTCP}
1176}
1177
1178// Protocol1 enumerates the values for protocol 1.
1179type Protocol1 string
1180
1181const (
1182	// Protocol1All ...
1183	Protocol1All Protocol1 = "All"
1184	// Protocol1TCP ...
1185	Protocol1TCP Protocol1 = "Tcp"
1186	// Protocol1UDP ...
1187	Protocol1UDP Protocol1 = "Udp"
1188)
1189
1190// PossibleProtocol1Values returns an array of possible values for the Protocol1 const type.
1191func PossibleProtocol1Values() []Protocol1 {
1192	return []Protocol1{Protocol1All, Protocol1TCP, Protocol1UDP}
1193}
1194
1195// ProvisioningState enumerates the values for provisioning state.
1196type ProvisioningState string
1197
1198const (
1199	// Deleting ...
1200	Deleting ProvisioningState = "Deleting"
1201	// Failed ...
1202	Failed ProvisioningState = "Failed"
1203	// Succeeded ...
1204	Succeeded ProvisioningState = "Succeeded"
1205	// Updating ...
1206	Updating ProvisioningState = "Updating"
1207)
1208
1209// PossibleProvisioningStateValues returns an array of possible values for the ProvisioningState const type.
1210func PossibleProvisioningStateValues() []ProvisioningState {
1211	return []ProvisioningState{Deleting, Failed, Succeeded, Updating}
1212}
1213
1214// PublicIPAddressSkuName enumerates the values for public ip address sku name.
1215type PublicIPAddressSkuName string
1216
1217const (
1218	// PublicIPAddressSkuNameBasic ...
1219	PublicIPAddressSkuNameBasic PublicIPAddressSkuName = "Basic"
1220	// PublicIPAddressSkuNameStandard ...
1221	PublicIPAddressSkuNameStandard PublicIPAddressSkuName = "Standard"
1222)
1223
1224// PossiblePublicIPAddressSkuNameValues returns an array of possible values for the PublicIPAddressSkuName const type.
1225func PossiblePublicIPAddressSkuNameValues() []PublicIPAddressSkuName {
1226	return []PublicIPAddressSkuName{PublicIPAddressSkuNameBasic, PublicIPAddressSkuNameStandard}
1227}
1228
1229// PublicIPPrefixSkuName enumerates the values for public ip prefix sku name.
1230type PublicIPPrefixSkuName string
1231
1232const (
1233	// PublicIPPrefixSkuNameStandard ...
1234	PublicIPPrefixSkuNameStandard PublicIPPrefixSkuName = "Standard"
1235)
1236
1237// PossiblePublicIPPrefixSkuNameValues returns an array of possible values for the PublicIPPrefixSkuName const type.
1238func PossiblePublicIPPrefixSkuNameValues() []PublicIPPrefixSkuName {
1239	return []PublicIPPrefixSkuName{PublicIPPrefixSkuNameStandard}
1240}
1241
1242// RouteNextHopType enumerates the values for route next hop type.
1243type RouteNextHopType string
1244
1245const (
1246	// RouteNextHopTypeInternet ...
1247	RouteNextHopTypeInternet RouteNextHopType = "Internet"
1248	// RouteNextHopTypeNone ...
1249	RouteNextHopTypeNone RouteNextHopType = "None"
1250	// RouteNextHopTypeVirtualAppliance ...
1251	RouteNextHopTypeVirtualAppliance RouteNextHopType = "VirtualAppliance"
1252	// RouteNextHopTypeVirtualNetworkGateway ...
1253	RouteNextHopTypeVirtualNetworkGateway RouteNextHopType = "VirtualNetworkGateway"
1254	// RouteNextHopTypeVnetLocal ...
1255	RouteNextHopTypeVnetLocal RouteNextHopType = "VnetLocal"
1256)
1257
1258// PossibleRouteNextHopTypeValues returns an array of possible values for the RouteNextHopType const type.
1259func PossibleRouteNextHopTypeValues() []RouteNextHopType {
1260	return []RouteNextHopType{RouteNextHopTypeInternet, RouteNextHopTypeNone, RouteNextHopTypeVirtualAppliance, RouteNextHopTypeVirtualNetworkGateway, RouteNextHopTypeVnetLocal}
1261}
1262
1263// SecurityRuleAccess enumerates the values for security rule access.
1264type SecurityRuleAccess string
1265
1266const (
1267	// SecurityRuleAccessAllow ...
1268	SecurityRuleAccessAllow SecurityRuleAccess = "Allow"
1269	// SecurityRuleAccessDeny ...
1270	SecurityRuleAccessDeny SecurityRuleAccess = "Deny"
1271)
1272
1273// PossibleSecurityRuleAccessValues returns an array of possible values for the SecurityRuleAccess const type.
1274func PossibleSecurityRuleAccessValues() []SecurityRuleAccess {
1275	return []SecurityRuleAccess{SecurityRuleAccessAllow, SecurityRuleAccessDeny}
1276}
1277
1278// SecurityRuleDirection enumerates the values for security rule direction.
1279type SecurityRuleDirection string
1280
1281const (
1282	// SecurityRuleDirectionInbound ...
1283	SecurityRuleDirectionInbound SecurityRuleDirection = "Inbound"
1284	// SecurityRuleDirectionOutbound ...
1285	SecurityRuleDirectionOutbound SecurityRuleDirection = "Outbound"
1286)
1287
1288// PossibleSecurityRuleDirectionValues returns an array of possible values for the SecurityRuleDirection const type.
1289func PossibleSecurityRuleDirectionValues() []SecurityRuleDirection {
1290	return []SecurityRuleDirection{SecurityRuleDirectionInbound, SecurityRuleDirectionOutbound}
1291}
1292
1293// SecurityRuleProtocol enumerates the values for security rule protocol.
1294type SecurityRuleProtocol string
1295
1296const (
1297	// SecurityRuleProtocolAsterisk ...
1298	SecurityRuleProtocolAsterisk SecurityRuleProtocol = "*"
1299	// SecurityRuleProtocolTCP ...
1300	SecurityRuleProtocolTCP SecurityRuleProtocol = "Tcp"
1301	// SecurityRuleProtocolUDP ...
1302	SecurityRuleProtocolUDP SecurityRuleProtocol = "Udp"
1303)
1304
1305// PossibleSecurityRuleProtocolValues returns an array of possible values for the SecurityRuleProtocol const type.
1306func PossibleSecurityRuleProtocolValues() []SecurityRuleProtocol {
1307	return []SecurityRuleProtocol{SecurityRuleProtocolAsterisk, SecurityRuleProtocolTCP, SecurityRuleProtocolUDP}
1308}
1309
1310// ServiceProviderProvisioningState enumerates the values for service provider provisioning state.
1311type ServiceProviderProvisioningState string
1312
1313const (
1314	// Deprovisioning ...
1315	Deprovisioning ServiceProviderProvisioningState = "Deprovisioning"
1316	// NotProvisioned ...
1317	NotProvisioned ServiceProviderProvisioningState = "NotProvisioned"
1318	// Provisioned ...
1319	Provisioned ServiceProviderProvisioningState = "Provisioned"
1320	// Provisioning ...
1321	Provisioning ServiceProviderProvisioningState = "Provisioning"
1322)
1323
1324// PossibleServiceProviderProvisioningStateValues returns an array of possible values for the ServiceProviderProvisioningState const type.
1325func PossibleServiceProviderProvisioningStateValues() []ServiceProviderProvisioningState {
1326	return []ServiceProviderProvisioningState{Deprovisioning, NotProvisioned, Provisioned, Provisioning}
1327}
1328
1329// Severity enumerates the values for severity.
1330type Severity string
1331
1332const (
1333	// SeverityError ...
1334	SeverityError Severity = "Error"
1335	// SeverityWarning ...
1336	SeverityWarning Severity = "Warning"
1337)
1338
1339// PossibleSeverityValues returns an array of possible values for the Severity const type.
1340func PossibleSeverityValues() []Severity {
1341	return []Severity{SeverityError, SeverityWarning}
1342}
1343
1344// TransportProtocol enumerates the values for transport protocol.
1345type TransportProtocol string
1346
1347const (
1348	// TransportProtocolAll ...
1349	TransportProtocolAll TransportProtocol = "All"
1350	// TransportProtocolTCP ...
1351	TransportProtocolTCP TransportProtocol = "Tcp"
1352	// TransportProtocolUDP ...
1353	TransportProtocolUDP TransportProtocol = "Udp"
1354)
1355
1356// PossibleTransportProtocolValues returns an array of possible values for the TransportProtocol const type.
1357func PossibleTransportProtocolValues() []TransportProtocol {
1358	return []TransportProtocol{TransportProtocolAll, TransportProtocolTCP, TransportProtocolUDP}
1359}
1360
1361// TunnelConnectionStatus enumerates the values for tunnel connection status.
1362type TunnelConnectionStatus string
1363
1364const (
1365	// TunnelConnectionStatusConnected ...
1366	TunnelConnectionStatusConnected TunnelConnectionStatus = "Connected"
1367	// TunnelConnectionStatusConnecting ...
1368	TunnelConnectionStatusConnecting TunnelConnectionStatus = "Connecting"
1369	// TunnelConnectionStatusNotConnected ...
1370	TunnelConnectionStatusNotConnected TunnelConnectionStatus = "NotConnected"
1371	// TunnelConnectionStatusUnknown ...
1372	TunnelConnectionStatusUnknown TunnelConnectionStatus = "Unknown"
1373)
1374
1375// PossibleTunnelConnectionStatusValues returns an array of possible values for the TunnelConnectionStatus const type.
1376func PossibleTunnelConnectionStatusValues() []TunnelConnectionStatus {
1377	return []TunnelConnectionStatus{TunnelConnectionStatusConnected, TunnelConnectionStatusConnecting, TunnelConnectionStatusNotConnected, TunnelConnectionStatusUnknown}
1378}
1379
1380// VirtualNetworkGatewayConnectionProtocol enumerates the values for virtual network gateway connection
1381// protocol.
1382type VirtualNetworkGatewayConnectionProtocol string
1383
1384const (
1385	// IKEv1 ...
1386	IKEv1 VirtualNetworkGatewayConnectionProtocol = "IKEv1"
1387	// IKEv2 ...
1388	IKEv2 VirtualNetworkGatewayConnectionProtocol = "IKEv2"
1389)
1390
1391// PossibleVirtualNetworkGatewayConnectionProtocolValues returns an array of possible values for the VirtualNetworkGatewayConnectionProtocol const type.
1392func PossibleVirtualNetworkGatewayConnectionProtocolValues() []VirtualNetworkGatewayConnectionProtocol {
1393	return []VirtualNetworkGatewayConnectionProtocol{IKEv1, IKEv2}
1394}
1395
1396// VirtualNetworkGatewayConnectionStatus enumerates the values for virtual network gateway connection status.
1397type VirtualNetworkGatewayConnectionStatus string
1398
1399const (
1400	// VirtualNetworkGatewayConnectionStatusConnected ...
1401	VirtualNetworkGatewayConnectionStatusConnected VirtualNetworkGatewayConnectionStatus = "Connected"
1402	// VirtualNetworkGatewayConnectionStatusConnecting ...
1403	VirtualNetworkGatewayConnectionStatusConnecting VirtualNetworkGatewayConnectionStatus = "Connecting"
1404	// VirtualNetworkGatewayConnectionStatusNotConnected ...
1405	VirtualNetworkGatewayConnectionStatusNotConnected VirtualNetworkGatewayConnectionStatus = "NotConnected"
1406	// VirtualNetworkGatewayConnectionStatusUnknown ...
1407	VirtualNetworkGatewayConnectionStatusUnknown VirtualNetworkGatewayConnectionStatus = "Unknown"
1408)
1409
1410// PossibleVirtualNetworkGatewayConnectionStatusValues returns an array of possible values for the VirtualNetworkGatewayConnectionStatus const type.
1411func PossibleVirtualNetworkGatewayConnectionStatusValues() []VirtualNetworkGatewayConnectionStatus {
1412	return []VirtualNetworkGatewayConnectionStatus{VirtualNetworkGatewayConnectionStatusConnected, VirtualNetworkGatewayConnectionStatusConnecting, VirtualNetworkGatewayConnectionStatusNotConnected, VirtualNetworkGatewayConnectionStatusUnknown}
1413}
1414
1415// VirtualNetworkGatewayConnectionType enumerates the values for virtual network gateway connection type.
1416type VirtualNetworkGatewayConnectionType string
1417
1418const (
1419	// ExpressRoute ...
1420	ExpressRoute VirtualNetworkGatewayConnectionType = "ExpressRoute"
1421	// IPsec ...
1422	IPsec VirtualNetworkGatewayConnectionType = "IPsec"
1423	// Vnet2Vnet ...
1424	Vnet2Vnet VirtualNetworkGatewayConnectionType = "Vnet2Vnet"
1425	// VPNClient ...
1426	VPNClient VirtualNetworkGatewayConnectionType = "VPNClient"
1427)
1428
1429// PossibleVirtualNetworkGatewayConnectionTypeValues returns an array of possible values for the VirtualNetworkGatewayConnectionType const type.
1430func PossibleVirtualNetworkGatewayConnectionTypeValues() []VirtualNetworkGatewayConnectionType {
1431	return []VirtualNetworkGatewayConnectionType{ExpressRoute, IPsec, Vnet2Vnet, VPNClient}
1432}
1433
1434// VirtualNetworkGatewaySkuName enumerates the values for virtual network gateway sku name.
1435type VirtualNetworkGatewaySkuName string
1436
1437const (
1438	// VirtualNetworkGatewaySkuNameBasic ...
1439	VirtualNetworkGatewaySkuNameBasic VirtualNetworkGatewaySkuName = "Basic"
1440	// VirtualNetworkGatewaySkuNameErGw1AZ ...
1441	VirtualNetworkGatewaySkuNameErGw1AZ VirtualNetworkGatewaySkuName = "ErGw1AZ"
1442	// VirtualNetworkGatewaySkuNameErGw2AZ ...
1443	VirtualNetworkGatewaySkuNameErGw2AZ VirtualNetworkGatewaySkuName = "ErGw2AZ"
1444	// VirtualNetworkGatewaySkuNameErGw3AZ ...
1445	VirtualNetworkGatewaySkuNameErGw3AZ VirtualNetworkGatewaySkuName = "ErGw3AZ"
1446	// VirtualNetworkGatewaySkuNameHighPerformance ...
1447	VirtualNetworkGatewaySkuNameHighPerformance VirtualNetworkGatewaySkuName = "HighPerformance"
1448	// VirtualNetworkGatewaySkuNameStandard ...
1449	VirtualNetworkGatewaySkuNameStandard VirtualNetworkGatewaySkuName = "Standard"
1450	// VirtualNetworkGatewaySkuNameUltraPerformance ...
1451	VirtualNetworkGatewaySkuNameUltraPerformance VirtualNetworkGatewaySkuName = "UltraPerformance"
1452	// VirtualNetworkGatewaySkuNameVpnGw1 ...
1453	VirtualNetworkGatewaySkuNameVpnGw1 VirtualNetworkGatewaySkuName = "VpnGw1"
1454	// VirtualNetworkGatewaySkuNameVpnGw1AZ ...
1455	VirtualNetworkGatewaySkuNameVpnGw1AZ VirtualNetworkGatewaySkuName = "VpnGw1AZ"
1456	// VirtualNetworkGatewaySkuNameVpnGw2 ...
1457	VirtualNetworkGatewaySkuNameVpnGw2 VirtualNetworkGatewaySkuName = "VpnGw2"
1458	// VirtualNetworkGatewaySkuNameVpnGw2AZ ...
1459	VirtualNetworkGatewaySkuNameVpnGw2AZ VirtualNetworkGatewaySkuName = "VpnGw2AZ"
1460	// VirtualNetworkGatewaySkuNameVpnGw3 ...
1461	VirtualNetworkGatewaySkuNameVpnGw3 VirtualNetworkGatewaySkuName = "VpnGw3"
1462	// VirtualNetworkGatewaySkuNameVpnGw3AZ ...
1463	VirtualNetworkGatewaySkuNameVpnGw3AZ VirtualNetworkGatewaySkuName = "VpnGw3AZ"
1464)
1465
1466// PossibleVirtualNetworkGatewaySkuNameValues returns an array of possible values for the VirtualNetworkGatewaySkuName const type.
1467func PossibleVirtualNetworkGatewaySkuNameValues() []VirtualNetworkGatewaySkuName {
1468	return []VirtualNetworkGatewaySkuName{VirtualNetworkGatewaySkuNameBasic, VirtualNetworkGatewaySkuNameErGw1AZ, VirtualNetworkGatewaySkuNameErGw2AZ, VirtualNetworkGatewaySkuNameErGw3AZ, VirtualNetworkGatewaySkuNameHighPerformance, VirtualNetworkGatewaySkuNameStandard, VirtualNetworkGatewaySkuNameUltraPerformance, VirtualNetworkGatewaySkuNameVpnGw1, VirtualNetworkGatewaySkuNameVpnGw1AZ, VirtualNetworkGatewaySkuNameVpnGw2, VirtualNetworkGatewaySkuNameVpnGw2AZ, VirtualNetworkGatewaySkuNameVpnGw3, VirtualNetworkGatewaySkuNameVpnGw3AZ}
1469}
1470
1471// VirtualNetworkGatewaySkuTier enumerates the values for virtual network gateway sku tier.
1472type VirtualNetworkGatewaySkuTier string
1473
1474const (
1475	// VirtualNetworkGatewaySkuTierBasic ...
1476	VirtualNetworkGatewaySkuTierBasic VirtualNetworkGatewaySkuTier = "Basic"
1477	// VirtualNetworkGatewaySkuTierErGw1AZ ...
1478	VirtualNetworkGatewaySkuTierErGw1AZ VirtualNetworkGatewaySkuTier = "ErGw1AZ"
1479	// VirtualNetworkGatewaySkuTierErGw2AZ ...
1480	VirtualNetworkGatewaySkuTierErGw2AZ VirtualNetworkGatewaySkuTier = "ErGw2AZ"
1481	// VirtualNetworkGatewaySkuTierErGw3AZ ...
1482	VirtualNetworkGatewaySkuTierErGw3AZ VirtualNetworkGatewaySkuTier = "ErGw3AZ"
1483	// VirtualNetworkGatewaySkuTierHighPerformance ...
1484	VirtualNetworkGatewaySkuTierHighPerformance VirtualNetworkGatewaySkuTier = "HighPerformance"
1485	// VirtualNetworkGatewaySkuTierStandard ...
1486	VirtualNetworkGatewaySkuTierStandard VirtualNetworkGatewaySkuTier = "Standard"
1487	// VirtualNetworkGatewaySkuTierUltraPerformance ...
1488	VirtualNetworkGatewaySkuTierUltraPerformance VirtualNetworkGatewaySkuTier = "UltraPerformance"
1489	// VirtualNetworkGatewaySkuTierVpnGw1 ...
1490	VirtualNetworkGatewaySkuTierVpnGw1 VirtualNetworkGatewaySkuTier = "VpnGw1"
1491	// VirtualNetworkGatewaySkuTierVpnGw1AZ ...
1492	VirtualNetworkGatewaySkuTierVpnGw1AZ VirtualNetworkGatewaySkuTier = "VpnGw1AZ"
1493	// VirtualNetworkGatewaySkuTierVpnGw2 ...
1494	VirtualNetworkGatewaySkuTierVpnGw2 VirtualNetworkGatewaySkuTier = "VpnGw2"
1495	// VirtualNetworkGatewaySkuTierVpnGw2AZ ...
1496	VirtualNetworkGatewaySkuTierVpnGw2AZ VirtualNetworkGatewaySkuTier = "VpnGw2AZ"
1497	// VirtualNetworkGatewaySkuTierVpnGw3 ...
1498	VirtualNetworkGatewaySkuTierVpnGw3 VirtualNetworkGatewaySkuTier = "VpnGw3"
1499	// VirtualNetworkGatewaySkuTierVpnGw3AZ ...
1500	VirtualNetworkGatewaySkuTierVpnGw3AZ VirtualNetworkGatewaySkuTier = "VpnGw3AZ"
1501)
1502
1503// PossibleVirtualNetworkGatewaySkuTierValues returns an array of possible values for the VirtualNetworkGatewaySkuTier const type.
1504func PossibleVirtualNetworkGatewaySkuTierValues() []VirtualNetworkGatewaySkuTier {
1505	return []VirtualNetworkGatewaySkuTier{VirtualNetworkGatewaySkuTierBasic, VirtualNetworkGatewaySkuTierErGw1AZ, VirtualNetworkGatewaySkuTierErGw2AZ, VirtualNetworkGatewaySkuTierErGw3AZ, VirtualNetworkGatewaySkuTierHighPerformance, VirtualNetworkGatewaySkuTierStandard, VirtualNetworkGatewaySkuTierUltraPerformance, VirtualNetworkGatewaySkuTierVpnGw1, VirtualNetworkGatewaySkuTierVpnGw1AZ, VirtualNetworkGatewaySkuTierVpnGw2, VirtualNetworkGatewaySkuTierVpnGw2AZ, VirtualNetworkGatewaySkuTierVpnGw3, VirtualNetworkGatewaySkuTierVpnGw3AZ}
1506}
1507
1508// VirtualNetworkGatewayType enumerates the values for virtual network gateway type.
1509type VirtualNetworkGatewayType string
1510
1511const (
1512	// VirtualNetworkGatewayTypeExpressRoute ...
1513	VirtualNetworkGatewayTypeExpressRoute VirtualNetworkGatewayType = "ExpressRoute"
1514	// VirtualNetworkGatewayTypeVpn ...
1515	VirtualNetworkGatewayTypeVpn VirtualNetworkGatewayType = "Vpn"
1516)
1517
1518// PossibleVirtualNetworkGatewayTypeValues returns an array of possible values for the VirtualNetworkGatewayType const type.
1519func PossibleVirtualNetworkGatewayTypeValues() []VirtualNetworkGatewayType {
1520	return []VirtualNetworkGatewayType{VirtualNetworkGatewayTypeExpressRoute, VirtualNetworkGatewayTypeVpn}
1521}
1522
1523// VirtualNetworkPeeringState enumerates the values for virtual network peering state.
1524type VirtualNetworkPeeringState string
1525
1526const (
1527	// VirtualNetworkPeeringStateConnected ...
1528	VirtualNetworkPeeringStateConnected VirtualNetworkPeeringState = "Connected"
1529	// VirtualNetworkPeeringStateDisconnected ...
1530	VirtualNetworkPeeringStateDisconnected VirtualNetworkPeeringState = "Disconnected"
1531	// VirtualNetworkPeeringStateInitiated ...
1532	VirtualNetworkPeeringStateInitiated VirtualNetworkPeeringState = "Initiated"
1533)
1534
1535// PossibleVirtualNetworkPeeringStateValues returns an array of possible values for the VirtualNetworkPeeringState const type.
1536func PossibleVirtualNetworkPeeringStateValues() []VirtualNetworkPeeringState {
1537	return []VirtualNetworkPeeringState{VirtualNetworkPeeringStateConnected, VirtualNetworkPeeringStateDisconnected, VirtualNetworkPeeringStateInitiated}
1538}
1539
1540// VirtualWanSecurityProviderType enumerates the values for virtual wan security provider type.
1541type VirtualWanSecurityProviderType string
1542
1543const (
1544	// External ...
1545	External VirtualWanSecurityProviderType = "External"
1546	// Native ...
1547	Native VirtualWanSecurityProviderType = "Native"
1548)
1549
1550// PossibleVirtualWanSecurityProviderTypeValues returns an array of possible values for the VirtualWanSecurityProviderType const type.
1551func PossibleVirtualWanSecurityProviderTypeValues() []VirtualWanSecurityProviderType {
1552	return []VirtualWanSecurityProviderType{External, Native}
1553}
1554
1555// VpnClientProtocol enumerates the values for vpn client protocol.
1556type VpnClientProtocol string
1557
1558const (
1559	// IkeV2 ...
1560	IkeV2 VpnClientProtocol = "IkeV2"
1561	// OpenVPN ...
1562	OpenVPN VpnClientProtocol = "OpenVPN"
1563	// SSTP ...
1564	SSTP VpnClientProtocol = "SSTP"
1565)
1566
1567// PossibleVpnClientProtocolValues returns an array of possible values for the VpnClientProtocol const type.
1568func PossibleVpnClientProtocolValues() []VpnClientProtocol {
1569	return []VpnClientProtocol{IkeV2, OpenVPN, SSTP}
1570}
1571
1572// VpnConnectionStatus enumerates the values for vpn connection status.
1573type VpnConnectionStatus string
1574
1575const (
1576	// VpnConnectionStatusConnected ...
1577	VpnConnectionStatusConnected VpnConnectionStatus = "Connected"
1578	// VpnConnectionStatusConnecting ...
1579	VpnConnectionStatusConnecting VpnConnectionStatus = "Connecting"
1580	// VpnConnectionStatusNotConnected ...
1581	VpnConnectionStatusNotConnected VpnConnectionStatus = "NotConnected"
1582	// VpnConnectionStatusUnknown ...
1583	VpnConnectionStatusUnknown VpnConnectionStatus = "Unknown"
1584)
1585
1586// PossibleVpnConnectionStatusValues returns an array of possible values for the VpnConnectionStatus const type.
1587func PossibleVpnConnectionStatusValues() []VpnConnectionStatus {
1588	return []VpnConnectionStatus{VpnConnectionStatusConnected, VpnConnectionStatusConnecting, VpnConnectionStatusNotConnected, VpnConnectionStatusUnknown}
1589}
1590
1591// VpnGatewayTunnelingProtocol enumerates the values for vpn gateway tunneling protocol.
1592type VpnGatewayTunnelingProtocol string
1593
1594const (
1595	// VpnGatewayTunnelingProtocolIkeV2 ...
1596	VpnGatewayTunnelingProtocolIkeV2 VpnGatewayTunnelingProtocol = "IkeV2"
1597	// VpnGatewayTunnelingProtocolOpenVPN ...
1598	VpnGatewayTunnelingProtocolOpenVPN VpnGatewayTunnelingProtocol = "OpenVPN"
1599)
1600
1601// PossibleVpnGatewayTunnelingProtocolValues returns an array of possible values for the VpnGatewayTunnelingProtocol const type.
1602func PossibleVpnGatewayTunnelingProtocolValues() []VpnGatewayTunnelingProtocol {
1603	return []VpnGatewayTunnelingProtocol{VpnGatewayTunnelingProtocolIkeV2, VpnGatewayTunnelingProtocolOpenVPN}
1604}
1605
1606// VpnType enumerates the values for vpn type.
1607type VpnType string
1608
1609const (
1610	// PolicyBased ...
1611	PolicyBased VpnType = "PolicyBased"
1612	// RouteBased ...
1613	RouteBased VpnType = "RouteBased"
1614)
1615
1616// PossibleVpnTypeValues returns an array of possible values for the VpnType const type.
1617func PossibleVpnTypeValues() []VpnType {
1618	return []VpnType{PolicyBased, RouteBased}
1619}
1620
1621// AddressSpace addressSpace contains an array of IP address ranges that can be used by subnets of the virtual
1622// network.
1623type AddressSpace struct {
1624	// AddressPrefixes - A list of address blocks reserved for this virtual network in CIDR notation.
1625	AddressPrefixes *[]string `json:"addressPrefixes,omitempty"`
1626}
1627
1628// ApplicationGateway application gateway resource
1629type ApplicationGateway struct {
1630	autorest.Response                   `json:"-"`
1631	*ApplicationGatewayPropertiesFormat `json:"properties,omitempty"`
1632	// Etag - A unique read-only string that changes whenever the resource is updated.
1633	Etag *string `json:"etag,omitempty"`
1634	// Zones - A list of availability zones denoting where the resource needs to come from.
1635	Zones *[]string `json:"zones,omitempty"`
1636	// ID - Resource ID.
1637	ID *string `json:"id,omitempty"`
1638	// Name - Resource name.
1639	Name *string `json:"name,omitempty"`
1640	// Type - Resource type.
1641	Type *string `json:"type,omitempty"`
1642	// Location - Resource location.
1643	Location *string `json:"location,omitempty"`
1644	// Tags - Resource tags.
1645	Tags map[string]*string `json:"tags"`
1646}
1647
1648// MarshalJSON is the custom marshaler for ApplicationGateway.
1649func (ag ApplicationGateway) MarshalJSON() ([]byte, error) {
1650	objectMap := make(map[string]interface{})
1651	if ag.ApplicationGatewayPropertiesFormat != nil {
1652		objectMap["properties"] = ag.ApplicationGatewayPropertiesFormat
1653	}
1654	if ag.Etag != nil {
1655		objectMap["etag"] = ag.Etag
1656	}
1657	if ag.Zones != nil {
1658		objectMap["zones"] = ag.Zones
1659	}
1660	if ag.ID != nil {
1661		objectMap["id"] = ag.ID
1662	}
1663	if ag.Name != nil {
1664		objectMap["name"] = ag.Name
1665	}
1666	if ag.Type != nil {
1667		objectMap["type"] = ag.Type
1668	}
1669	if ag.Location != nil {
1670		objectMap["location"] = ag.Location
1671	}
1672	if ag.Tags != nil {
1673		objectMap["tags"] = ag.Tags
1674	}
1675	return json.Marshal(objectMap)
1676}
1677
1678// UnmarshalJSON is the custom unmarshaler for ApplicationGateway struct.
1679func (ag *ApplicationGateway) UnmarshalJSON(body []byte) error {
1680	var m map[string]*json.RawMessage
1681	err := json.Unmarshal(body, &m)
1682	if err != nil {
1683		return err
1684	}
1685	for k, v := range m {
1686		switch k {
1687		case "properties":
1688			if v != nil {
1689				var applicationGatewayPropertiesFormat ApplicationGatewayPropertiesFormat
1690				err = json.Unmarshal(*v, &applicationGatewayPropertiesFormat)
1691				if err != nil {
1692					return err
1693				}
1694				ag.ApplicationGatewayPropertiesFormat = &applicationGatewayPropertiesFormat
1695			}
1696		case "etag":
1697			if v != nil {
1698				var etag string
1699				err = json.Unmarshal(*v, &etag)
1700				if err != nil {
1701					return err
1702				}
1703				ag.Etag = &etag
1704			}
1705		case "zones":
1706			if v != nil {
1707				var zones []string
1708				err = json.Unmarshal(*v, &zones)
1709				if err != nil {
1710					return err
1711				}
1712				ag.Zones = &zones
1713			}
1714		case "id":
1715			if v != nil {
1716				var ID string
1717				err = json.Unmarshal(*v, &ID)
1718				if err != nil {
1719					return err
1720				}
1721				ag.ID = &ID
1722			}
1723		case "name":
1724			if v != nil {
1725				var name string
1726				err = json.Unmarshal(*v, &name)
1727				if err != nil {
1728					return err
1729				}
1730				ag.Name = &name
1731			}
1732		case "type":
1733			if v != nil {
1734				var typeVar string
1735				err = json.Unmarshal(*v, &typeVar)
1736				if err != nil {
1737					return err
1738				}
1739				ag.Type = &typeVar
1740			}
1741		case "location":
1742			if v != nil {
1743				var location string
1744				err = json.Unmarshal(*v, &location)
1745				if err != nil {
1746					return err
1747				}
1748				ag.Location = &location
1749			}
1750		case "tags":
1751			if v != nil {
1752				var tags map[string]*string
1753				err = json.Unmarshal(*v, &tags)
1754				if err != nil {
1755					return err
1756				}
1757				ag.Tags = tags
1758			}
1759		}
1760	}
1761
1762	return nil
1763}
1764
1765// ApplicationGatewayAuthenticationCertificate authentication certificates of an application gateway.
1766type ApplicationGatewayAuthenticationCertificate struct {
1767	*ApplicationGatewayAuthenticationCertificatePropertiesFormat `json:"properties,omitempty"`
1768	// Name - Name of the authentication certificate that is unique within an Application Gateway.
1769	Name *string `json:"name,omitempty"`
1770	// Etag - A unique read-only string that changes whenever the resource is updated.
1771	Etag *string `json:"etag,omitempty"`
1772	// Type - Type of the resource.
1773	Type *string `json:"type,omitempty"`
1774	// ID - Resource ID.
1775	ID *string `json:"id,omitempty"`
1776}
1777
1778// MarshalJSON is the custom marshaler for ApplicationGatewayAuthenticationCertificate.
1779func (agac ApplicationGatewayAuthenticationCertificate) MarshalJSON() ([]byte, error) {
1780	objectMap := make(map[string]interface{})
1781	if agac.ApplicationGatewayAuthenticationCertificatePropertiesFormat != nil {
1782		objectMap["properties"] = agac.ApplicationGatewayAuthenticationCertificatePropertiesFormat
1783	}
1784	if agac.Name != nil {
1785		objectMap["name"] = agac.Name
1786	}
1787	if agac.Etag != nil {
1788		objectMap["etag"] = agac.Etag
1789	}
1790	if agac.Type != nil {
1791		objectMap["type"] = agac.Type
1792	}
1793	if agac.ID != nil {
1794		objectMap["id"] = agac.ID
1795	}
1796	return json.Marshal(objectMap)
1797}
1798
1799// UnmarshalJSON is the custom unmarshaler for ApplicationGatewayAuthenticationCertificate struct.
1800func (agac *ApplicationGatewayAuthenticationCertificate) UnmarshalJSON(body []byte) error {
1801	var m map[string]*json.RawMessage
1802	err := json.Unmarshal(body, &m)
1803	if err != nil {
1804		return err
1805	}
1806	for k, v := range m {
1807		switch k {
1808		case "properties":
1809			if v != nil {
1810				var applicationGatewayAuthenticationCertificatePropertiesFormat ApplicationGatewayAuthenticationCertificatePropertiesFormat
1811				err = json.Unmarshal(*v, &applicationGatewayAuthenticationCertificatePropertiesFormat)
1812				if err != nil {
1813					return err
1814				}
1815				agac.ApplicationGatewayAuthenticationCertificatePropertiesFormat = &applicationGatewayAuthenticationCertificatePropertiesFormat
1816			}
1817		case "name":
1818			if v != nil {
1819				var name string
1820				err = json.Unmarshal(*v, &name)
1821				if err != nil {
1822					return err
1823				}
1824				agac.Name = &name
1825			}
1826		case "etag":
1827			if v != nil {
1828				var etag string
1829				err = json.Unmarshal(*v, &etag)
1830				if err != nil {
1831					return err
1832				}
1833				agac.Etag = &etag
1834			}
1835		case "type":
1836			if v != nil {
1837				var typeVar string
1838				err = json.Unmarshal(*v, &typeVar)
1839				if err != nil {
1840					return err
1841				}
1842				agac.Type = &typeVar
1843			}
1844		case "id":
1845			if v != nil {
1846				var ID string
1847				err = json.Unmarshal(*v, &ID)
1848				if err != nil {
1849					return err
1850				}
1851				agac.ID = &ID
1852			}
1853		}
1854	}
1855
1856	return nil
1857}
1858
1859// ApplicationGatewayAuthenticationCertificatePropertiesFormat authentication certificates properties of an
1860// application gateway.
1861type ApplicationGatewayAuthenticationCertificatePropertiesFormat struct {
1862	// Data - Certificate public data.
1863	Data *string `json:"data,omitempty"`
1864	// ProvisioningState - Provisioning state of the authentication certificate resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
1865	ProvisioningState *string `json:"provisioningState,omitempty"`
1866}
1867
1868// ApplicationGatewayAutoscaleConfiguration application Gateway autoscale configuration.
1869type ApplicationGatewayAutoscaleConfiguration struct {
1870	// MinCapacity - Lower bound on number of Application Gateway instances
1871	MinCapacity *int32 `json:"minCapacity,omitempty"`
1872}
1873
1874// ApplicationGatewayAvailableSslOptions response for ApplicationGatewayAvailableSslOptions API service call.
1875type ApplicationGatewayAvailableSslOptions struct {
1876	autorest.Response                                      `json:"-"`
1877	*ApplicationGatewayAvailableSslOptionsPropertiesFormat `json:"properties,omitempty"`
1878	// ID - Resource ID.
1879	ID *string `json:"id,omitempty"`
1880	// Name - Resource name.
1881	Name *string `json:"name,omitempty"`
1882	// Type - Resource type.
1883	Type *string `json:"type,omitempty"`
1884	// Location - Resource location.
1885	Location *string `json:"location,omitempty"`
1886	// Tags - Resource tags.
1887	Tags map[string]*string `json:"tags"`
1888}
1889
1890// MarshalJSON is the custom marshaler for ApplicationGatewayAvailableSslOptions.
1891func (agaso ApplicationGatewayAvailableSslOptions) MarshalJSON() ([]byte, error) {
1892	objectMap := make(map[string]interface{})
1893	if agaso.ApplicationGatewayAvailableSslOptionsPropertiesFormat != nil {
1894		objectMap["properties"] = agaso.ApplicationGatewayAvailableSslOptionsPropertiesFormat
1895	}
1896	if agaso.ID != nil {
1897		objectMap["id"] = agaso.ID
1898	}
1899	if agaso.Name != nil {
1900		objectMap["name"] = agaso.Name
1901	}
1902	if agaso.Type != nil {
1903		objectMap["type"] = agaso.Type
1904	}
1905	if agaso.Location != nil {
1906		objectMap["location"] = agaso.Location
1907	}
1908	if agaso.Tags != nil {
1909		objectMap["tags"] = agaso.Tags
1910	}
1911	return json.Marshal(objectMap)
1912}
1913
1914// UnmarshalJSON is the custom unmarshaler for ApplicationGatewayAvailableSslOptions struct.
1915func (agaso *ApplicationGatewayAvailableSslOptions) UnmarshalJSON(body []byte) error {
1916	var m map[string]*json.RawMessage
1917	err := json.Unmarshal(body, &m)
1918	if err != nil {
1919		return err
1920	}
1921	for k, v := range m {
1922		switch k {
1923		case "properties":
1924			if v != nil {
1925				var applicationGatewayAvailableSslOptionsPropertiesFormat ApplicationGatewayAvailableSslOptionsPropertiesFormat
1926				err = json.Unmarshal(*v, &applicationGatewayAvailableSslOptionsPropertiesFormat)
1927				if err != nil {
1928					return err
1929				}
1930				agaso.ApplicationGatewayAvailableSslOptionsPropertiesFormat = &applicationGatewayAvailableSslOptionsPropertiesFormat
1931			}
1932		case "id":
1933			if v != nil {
1934				var ID string
1935				err = json.Unmarshal(*v, &ID)
1936				if err != nil {
1937					return err
1938				}
1939				agaso.ID = &ID
1940			}
1941		case "name":
1942			if v != nil {
1943				var name string
1944				err = json.Unmarshal(*v, &name)
1945				if err != nil {
1946					return err
1947				}
1948				agaso.Name = &name
1949			}
1950		case "type":
1951			if v != nil {
1952				var typeVar string
1953				err = json.Unmarshal(*v, &typeVar)
1954				if err != nil {
1955					return err
1956				}
1957				agaso.Type = &typeVar
1958			}
1959		case "location":
1960			if v != nil {
1961				var location string
1962				err = json.Unmarshal(*v, &location)
1963				if err != nil {
1964					return err
1965				}
1966				agaso.Location = &location
1967			}
1968		case "tags":
1969			if v != nil {
1970				var tags map[string]*string
1971				err = json.Unmarshal(*v, &tags)
1972				if err != nil {
1973					return err
1974				}
1975				agaso.Tags = tags
1976			}
1977		}
1978	}
1979
1980	return nil
1981}
1982
1983// ApplicationGatewayAvailableSslOptionsPropertiesFormat properties of ApplicationGatewayAvailableSslOptions
1984type ApplicationGatewayAvailableSslOptionsPropertiesFormat struct {
1985	// PredefinedPolicies - List of available Ssl predefined policy.
1986	PredefinedPolicies *[]SubResource `json:"predefinedPolicies,omitempty"`
1987	// DefaultPolicy - Name of the Ssl predefined policy applied by default to application gateway. Possible values include: 'AppGwSslPolicy20150501', 'AppGwSslPolicy20170401', 'AppGwSslPolicy20170401S'
1988	DefaultPolicy ApplicationGatewaySslPolicyName `json:"defaultPolicy,omitempty"`
1989	// AvailableCipherSuites - List of available Ssl cipher suites.
1990	AvailableCipherSuites *[]ApplicationGatewaySslCipherSuite `json:"availableCipherSuites,omitempty"`
1991	// AvailableProtocols - List of available Ssl protocols.
1992	AvailableProtocols *[]ApplicationGatewaySslProtocol `json:"availableProtocols,omitempty"`
1993}
1994
1995// ApplicationGatewayAvailableSslPredefinedPolicies response for ApplicationGatewayAvailableSslOptions API service
1996// call.
1997type ApplicationGatewayAvailableSslPredefinedPolicies struct {
1998	autorest.Response `json:"-"`
1999	// Value - List of available Ssl predefined policy.
2000	Value *[]ApplicationGatewaySslPredefinedPolicy `json:"value,omitempty"`
2001	// NextLink - URL to get the next set of results.
2002	NextLink *string `json:"nextLink,omitempty"`
2003}
2004
2005// ApplicationGatewayAvailableSslPredefinedPoliciesIterator provides access to a complete listing of
2006// ApplicationGatewaySslPredefinedPolicy values.
2007type ApplicationGatewayAvailableSslPredefinedPoliciesIterator struct {
2008	i    int
2009	page ApplicationGatewayAvailableSslPredefinedPoliciesPage
2010}
2011
2012// Next advances to the next value.  If there was an error making
2013// the request the iterator does not advance and the error is returned.
2014func (iter *ApplicationGatewayAvailableSslPredefinedPoliciesIterator) Next() error {
2015	iter.i++
2016	if iter.i < len(iter.page.Values()) {
2017		return nil
2018	}
2019	err := iter.page.Next()
2020	if err != nil {
2021		iter.i--
2022		return err
2023	}
2024	iter.i = 0
2025	return nil
2026}
2027
2028// NotDone returns true if the enumeration should be started or is not yet complete.
2029func (iter ApplicationGatewayAvailableSslPredefinedPoliciesIterator) NotDone() bool {
2030	return iter.page.NotDone() && iter.i < len(iter.page.Values())
2031}
2032
2033// Response returns the raw server response from the last page request.
2034func (iter ApplicationGatewayAvailableSslPredefinedPoliciesIterator) Response() ApplicationGatewayAvailableSslPredefinedPolicies {
2035	return iter.page.Response()
2036}
2037
2038// Value returns the current value or a zero-initialized value if the
2039// iterator has advanced beyond the end of the collection.
2040func (iter ApplicationGatewayAvailableSslPredefinedPoliciesIterator) Value() ApplicationGatewaySslPredefinedPolicy {
2041	if !iter.page.NotDone() {
2042		return ApplicationGatewaySslPredefinedPolicy{}
2043	}
2044	return iter.page.Values()[iter.i]
2045}
2046
2047// IsEmpty returns true if the ListResult contains no values.
2048func (agaspp ApplicationGatewayAvailableSslPredefinedPolicies) IsEmpty() bool {
2049	return agaspp.Value == nil || len(*agaspp.Value) == 0
2050}
2051
2052// applicationGatewayAvailableSslPredefinedPoliciesPreparer prepares a request to retrieve the next set of results.
2053// It returns nil if no more results exist.
2054func (agaspp ApplicationGatewayAvailableSslPredefinedPolicies) applicationGatewayAvailableSslPredefinedPoliciesPreparer() (*http.Request, error) {
2055	if agaspp.NextLink == nil || len(to.String(agaspp.NextLink)) < 1 {
2056		return nil, nil
2057	}
2058	return autorest.Prepare(&http.Request{},
2059		autorest.AsJSON(),
2060		autorest.AsGet(),
2061		autorest.WithBaseURL(to.String(agaspp.NextLink)))
2062}
2063
2064// ApplicationGatewayAvailableSslPredefinedPoliciesPage contains a page of ApplicationGatewaySslPredefinedPolicy
2065// values.
2066type ApplicationGatewayAvailableSslPredefinedPoliciesPage struct {
2067	fn     func(ApplicationGatewayAvailableSslPredefinedPolicies) (ApplicationGatewayAvailableSslPredefinedPolicies, error)
2068	agaspp ApplicationGatewayAvailableSslPredefinedPolicies
2069}
2070
2071// Next advances to the next page of values.  If there was an error making
2072// the request the page does not advance and the error is returned.
2073func (page *ApplicationGatewayAvailableSslPredefinedPoliciesPage) Next() error {
2074	next, err := page.fn(page.agaspp)
2075	if err != nil {
2076		return err
2077	}
2078	page.agaspp = next
2079	return nil
2080}
2081
2082// NotDone returns true if the page enumeration should be started or is not yet complete.
2083func (page ApplicationGatewayAvailableSslPredefinedPoliciesPage) NotDone() bool {
2084	return !page.agaspp.IsEmpty()
2085}
2086
2087// Response returns the raw server response from the last page request.
2088func (page ApplicationGatewayAvailableSslPredefinedPoliciesPage) Response() ApplicationGatewayAvailableSslPredefinedPolicies {
2089	return page.agaspp
2090}
2091
2092// Values returns the slice of values for the current page or nil if there are no values.
2093func (page ApplicationGatewayAvailableSslPredefinedPoliciesPage) Values() []ApplicationGatewaySslPredefinedPolicy {
2094	if page.agaspp.IsEmpty() {
2095		return nil
2096	}
2097	return *page.agaspp.Value
2098}
2099
2100// ApplicationGatewayAvailableWafRuleSetsResult response for ApplicationGatewayAvailableWafRuleSets API service
2101// call.
2102type ApplicationGatewayAvailableWafRuleSetsResult struct {
2103	autorest.Response `json:"-"`
2104	// Value - The list of application gateway rule sets.
2105	Value *[]ApplicationGatewayFirewallRuleSet `json:"value,omitempty"`
2106}
2107
2108// ApplicationGatewayBackendAddress backend address of an application gateway.
2109type ApplicationGatewayBackendAddress struct {
2110	// Fqdn - Fully qualified domain name (FQDN).
2111	Fqdn *string `json:"fqdn,omitempty"`
2112	// IPAddress - IP address
2113	IPAddress *string `json:"ipAddress,omitempty"`
2114}
2115
2116// ApplicationGatewayBackendAddressPool backend Address Pool of an application gateway.
2117type ApplicationGatewayBackendAddressPool struct {
2118	*ApplicationGatewayBackendAddressPoolPropertiesFormat `json:"properties,omitempty"`
2119	// Name - Name of the backend address pool that is unique within an Application Gateway.
2120	Name *string `json:"name,omitempty"`
2121	// Etag - A unique read-only string that changes whenever the resource is updated.
2122	Etag *string `json:"etag,omitempty"`
2123	// Type - Type of the resource.
2124	Type *string `json:"type,omitempty"`
2125	// ID - Resource ID.
2126	ID *string `json:"id,omitempty"`
2127}
2128
2129// MarshalJSON is the custom marshaler for ApplicationGatewayBackendAddressPool.
2130func (agbap ApplicationGatewayBackendAddressPool) MarshalJSON() ([]byte, error) {
2131	objectMap := make(map[string]interface{})
2132	if agbap.ApplicationGatewayBackendAddressPoolPropertiesFormat != nil {
2133		objectMap["properties"] = agbap.ApplicationGatewayBackendAddressPoolPropertiesFormat
2134	}
2135	if agbap.Name != nil {
2136		objectMap["name"] = agbap.Name
2137	}
2138	if agbap.Etag != nil {
2139		objectMap["etag"] = agbap.Etag
2140	}
2141	if agbap.Type != nil {
2142		objectMap["type"] = agbap.Type
2143	}
2144	if agbap.ID != nil {
2145		objectMap["id"] = agbap.ID
2146	}
2147	return json.Marshal(objectMap)
2148}
2149
2150// UnmarshalJSON is the custom unmarshaler for ApplicationGatewayBackendAddressPool struct.
2151func (agbap *ApplicationGatewayBackendAddressPool) UnmarshalJSON(body []byte) error {
2152	var m map[string]*json.RawMessage
2153	err := json.Unmarshal(body, &m)
2154	if err != nil {
2155		return err
2156	}
2157	for k, v := range m {
2158		switch k {
2159		case "properties":
2160			if v != nil {
2161				var applicationGatewayBackendAddressPoolPropertiesFormat ApplicationGatewayBackendAddressPoolPropertiesFormat
2162				err = json.Unmarshal(*v, &applicationGatewayBackendAddressPoolPropertiesFormat)
2163				if err != nil {
2164					return err
2165				}
2166				agbap.ApplicationGatewayBackendAddressPoolPropertiesFormat = &applicationGatewayBackendAddressPoolPropertiesFormat
2167			}
2168		case "name":
2169			if v != nil {
2170				var name string
2171				err = json.Unmarshal(*v, &name)
2172				if err != nil {
2173					return err
2174				}
2175				agbap.Name = &name
2176			}
2177		case "etag":
2178			if v != nil {
2179				var etag string
2180				err = json.Unmarshal(*v, &etag)
2181				if err != nil {
2182					return err
2183				}
2184				agbap.Etag = &etag
2185			}
2186		case "type":
2187			if v != nil {
2188				var typeVar string
2189				err = json.Unmarshal(*v, &typeVar)
2190				if err != nil {
2191					return err
2192				}
2193				agbap.Type = &typeVar
2194			}
2195		case "id":
2196			if v != nil {
2197				var ID string
2198				err = json.Unmarshal(*v, &ID)
2199				if err != nil {
2200					return err
2201				}
2202				agbap.ID = &ID
2203			}
2204		}
2205	}
2206
2207	return nil
2208}
2209
2210// ApplicationGatewayBackendAddressPoolPropertiesFormat properties of Backend Address Pool of an application
2211// gateway.
2212type ApplicationGatewayBackendAddressPoolPropertiesFormat struct {
2213	// BackendIPConfigurations - Collection of references to IPs defined in network interfaces.
2214	BackendIPConfigurations *[]InterfaceIPConfiguration `json:"backendIPConfigurations,omitempty"`
2215	// BackendAddresses - Backend addresses
2216	BackendAddresses *[]ApplicationGatewayBackendAddress `json:"backendAddresses,omitempty"`
2217	// ProvisioningState - Provisioning state of the backend address pool resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
2218	ProvisioningState *string `json:"provisioningState,omitempty"`
2219}
2220
2221// ApplicationGatewayBackendHealth list of ApplicationGatewayBackendHealthPool resources.
2222type ApplicationGatewayBackendHealth struct {
2223	autorest.Response   `json:"-"`
2224	BackendAddressPools *[]ApplicationGatewayBackendHealthPool `json:"backendAddressPools,omitempty"`
2225}
2226
2227// ApplicationGatewayBackendHealthHTTPSettings application gateway BackendHealthHttp settings.
2228type ApplicationGatewayBackendHealthHTTPSettings struct {
2229	// BackendHTTPSettings - Reference of an ApplicationGatewayBackendHttpSettings resource.
2230	BackendHTTPSettings *ApplicationGatewayBackendHTTPSettings `json:"backendHttpSettings,omitempty"`
2231	// Servers - List of ApplicationGatewayBackendHealthServer resources.
2232	Servers *[]ApplicationGatewayBackendHealthServer `json:"servers,omitempty"`
2233}
2234
2235// ApplicationGatewayBackendHealthPool application gateway BackendHealth pool.
2236type ApplicationGatewayBackendHealthPool struct {
2237	// BackendAddressPool - Reference of an ApplicationGatewayBackendAddressPool resource.
2238	BackendAddressPool *ApplicationGatewayBackendAddressPool `json:"backendAddressPool,omitempty"`
2239	// BackendHTTPSettingsCollection - List of ApplicationGatewayBackendHealthHttpSettings resources.
2240	BackendHTTPSettingsCollection *[]ApplicationGatewayBackendHealthHTTPSettings `json:"backendHttpSettingsCollection,omitempty"`
2241}
2242
2243// ApplicationGatewayBackendHealthServer application gateway backendhealth http settings.
2244type ApplicationGatewayBackendHealthServer struct {
2245	// Address - IP address or FQDN of backend server.
2246	Address *string `json:"address,omitempty"`
2247	// IPConfiguration - Reference of IP configuration of backend server.
2248	IPConfiguration *InterfaceIPConfiguration `json:"ipConfiguration,omitempty"`
2249	// Health - Health of backend server. Possible values include: 'Unknown', 'Up', 'Down', 'Partial', 'Draining'
2250	Health ApplicationGatewayBackendHealthServerHealth `json:"health,omitempty"`
2251}
2252
2253// ApplicationGatewayBackendHTTPSettings backend address pool settings of an application gateway.
2254type ApplicationGatewayBackendHTTPSettings struct {
2255	*ApplicationGatewayBackendHTTPSettingsPropertiesFormat `json:"properties,omitempty"`
2256	// Name - Name of the backend http settings that is unique within an Application Gateway.
2257	Name *string `json:"name,omitempty"`
2258	// Etag - A unique read-only string that changes whenever the resource is updated.
2259	Etag *string `json:"etag,omitempty"`
2260	// Type - Type of the resource.
2261	Type *string `json:"type,omitempty"`
2262	// ID - Resource ID.
2263	ID *string `json:"id,omitempty"`
2264}
2265
2266// MarshalJSON is the custom marshaler for ApplicationGatewayBackendHTTPSettings.
2267func (agbhs ApplicationGatewayBackendHTTPSettings) MarshalJSON() ([]byte, error) {
2268	objectMap := make(map[string]interface{})
2269	if agbhs.ApplicationGatewayBackendHTTPSettingsPropertiesFormat != nil {
2270		objectMap["properties"] = agbhs.ApplicationGatewayBackendHTTPSettingsPropertiesFormat
2271	}
2272	if agbhs.Name != nil {
2273		objectMap["name"] = agbhs.Name
2274	}
2275	if agbhs.Etag != nil {
2276		objectMap["etag"] = agbhs.Etag
2277	}
2278	if agbhs.Type != nil {
2279		objectMap["type"] = agbhs.Type
2280	}
2281	if agbhs.ID != nil {
2282		objectMap["id"] = agbhs.ID
2283	}
2284	return json.Marshal(objectMap)
2285}
2286
2287// UnmarshalJSON is the custom unmarshaler for ApplicationGatewayBackendHTTPSettings struct.
2288func (agbhs *ApplicationGatewayBackendHTTPSettings) UnmarshalJSON(body []byte) error {
2289	var m map[string]*json.RawMessage
2290	err := json.Unmarshal(body, &m)
2291	if err != nil {
2292		return err
2293	}
2294	for k, v := range m {
2295		switch k {
2296		case "properties":
2297			if v != nil {
2298				var applicationGatewayBackendHTTPSettingsPropertiesFormat ApplicationGatewayBackendHTTPSettingsPropertiesFormat
2299				err = json.Unmarshal(*v, &applicationGatewayBackendHTTPSettingsPropertiesFormat)
2300				if err != nil {
2301					return err
2302				}
2303				agbhs.ApplicationGatewayBackendHTTPSettingsPropertiesFormat = &applicationGatewayBackendHTTPSettingsPropertiesFormat
2304			}
2305		case "name":
2306			if v != nil {
2307				var name string
2308				err = json.Unmarshal(*v, &name)
2309				if err != nil {
2310					return err
2311				}
2312				agbhs.Name = &name
2313			}
2314		case "etag":
2315			if v != nil {
2316				var etag string
2317				err = json.Unmarshal(*v, &etag)
2318				if err != nil {
2319					return err
2320				}
2321				agbhs.Etag = &etag
2322			}
2323		case "type":
2324			if v != nil {
2325				var typeVar string
2326				err = json.Unmarshal(*v, &typeVar)
2327				if err != nil {
2328					return err
2329				}
2330				agbhs.Type = &typeVar
2331			}
2332		case "id":
2333			if v != nil {
2334				var ID string
2335				err = json.Unmarshal(*v, &ID)
2336				if err != nil {
2337					return err
2338				}
2339				agbhs.ID = &ID
2340			}
2341		}
2342	}
2343
2344	return nil
2345}
2346
2347// ApplicationGatewayBackendHTTPSettingsPropertiesFormat properties of Backend address pool settings of an
2348// application gateway.
2349type ApplicationGatewayBackendHTTPSettingsPropertiesFormat struct {
2350	// Port - The destination port on the backend.
2351	Port *int32 `json:"port,omitempty"`
2352	// Protocol - The protocol used to communicate with the backend. Possible values are 'Http' and 'Https'. Possible values include: 'HTTP', 'HTTPS'
2353	Protocol ApplicationGatewayProtocol `json:"protocol,omitempty"`
2354	// CookieBasedAffinity - Cookie based affinity. Possible values include: 'Enabled', 'Disabled'
2355	CookieBasedAffinity ApplicationGatewayCookieBasedAffinity `json:"cookieBasedAffinity,omitempty"`
2356	// RequestTimeout - Request timeout in seconds. Application Gateway will fail the request if response is not received within RequestTimeout. Acceptable values are from 1 second to 86400 seconds.
2357	RequestTimeout *int32 `json:"requestTimeout,omitempty"`
2358	// Probe - Probe resource of an application gateway.
2359	Probe *SubResource `json:"probe,omitempty"`
2360	// AuthenticationCertificates - Array of references to application gateway authentication certificates.
2361	AuthenticationCertificates *[]SubResource `json:"authenticationCertificates,omitempty"`
2362	// TrustedRootCertificates - Array of references to application gateway trusted root certificates.
2363	TrustedRootCertificates *[]SubResource `json:"trustedRootCertificates,omitempty"`
2364	// ConnectionDraining - Connection draining of the backend http settings resource.
2365	ConnectionDraining *ApplicationGatewayConnectionDraining `json:"connectionDraining,omitempty"`
2366	// HostName - Host header to be sent to the backend servers.
2367	HostName *string `json:"hostName,omitempty"`
2368	// PickHostNameFromBackendAddress - Whether to pick host header should be picked from the host name of the backend server. Default value is false.
2369	PickHostNameFromBackendAddress *bool `json:"pickHostNameFromBackendAddress,omitempty"`
2370	// AffinityCookieName - Cookie name to use for the affinity cookie.
2371	AffinityCookieName *string `json:"affinityCookieName,omitempty"`
2372	// ProbeEnabled - Whether the probe is enabled. Default value is false.
2373	ProbeEnabled *bool `json:"probeEnabled,omitempty"`
2374	// Path - Path which should be used as a prefix for all HTTP requests. Null means no path will be prefixed. Default value is null.
2375	Path *string `json:"path,omitempty"`
2376	// ProvisioningState - Provisioning state of the backend http settings resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
2377	ProvisioningState *string `json:"provisioningState,omitempty"`
2378}
2379
2380// ApplicationGatewayConnectionDraining connection draining allows open connections to a backend server to be
2381// active for a specified time after the backend server got removed from the configuration.
2382type ApplicationGatewayConnectionDraining struct {
2383	// Enabled - Whether connection draining is enabled or not.
2384	Enabled *bool `json:"enabled,omitempty"`
2385	// DrainTimeoutInSec - The number of seconds connection draining is active. Acceptable values are from 1 second to 3600 seconds.
2386	DrainTimeoutInSec *int32 `json:"drainTimeoutInSec,omitempty"`
2387}
2388
2389// ApplicationGatewayFirewallDisabledRuleGroup allows to disable rules within a rule group or an entire rule group.
2390type ApplicationGatewayFirewallDisabledRuleGroup struct {
2391	// RuleGroupName - The name of the rule group that will be disabled.
2392	RuleGroupName *string `json:"ruleGroupName,omitempty"`
2393	// Rules - The list of rules that will be disabled. If null, all rules of the rule group will be disabled.
2394	Rules *[]int32 `json:"rules,omitempty"`
2395}
2396
2397// ApplicationGatewayFirewallRule a web application firewall rule.
2398type ApplicationGatewayFirewallRule struct {
2399	// RuleID - The identifier of the web application firewall rule.
2400	RuleID *int32 `json:"ruleId,omitempty"`
2401	// Description - The description of the web application firewall rule.
2402	Description *string `json:"description,omitempty"`
2403}
2404
2405// ApplicationGatewayFirewallRuleGroup a web application firewall rule group.
2406type ApplicationGatewayFirewallRuleGroup struct {
2407	// RuleGroupName - The name of the web application firewall rule group.
2408	RuleGroupName *string `json:"ruleGroupName,omitempty"`
2409	// Description - The description of the web application firewall rule group.
2410	Description *string `json:"description,omitempty"`
2411	// Rules - The rules of the web application firewall rule group.
2412	Rules *[]ApplicationGatewayFirewallRule `json:"rules,omitempty"`
2413}
2414
2415// ApplicationGatewayFirewallRuleSet a web application firewall rule set.
2416type ApplicationGatewayFirewallRuleSet struct {
2417	*ApplicationGatewayFirewallRuleSetPropertiesFormat `json:"properties,omitempty"`
2418	// ID - Resource ID.
2419	ID *string `json:"id,omitempty"`
2420	// Name - Resource name.
2421	Name *string `json:"name,omitempty"`
2422	// Type - Resource type.
2423	Type *string `json:"type,omitempty"`
2424	// Location - Resource location.
2425	Location *string `json:"location,omitempty"`
2426	// Tags - Resource tags.
2427	Tags map[string]*string `json:"tags"`
2428}
2429
2430// MarshalJSON is the custom marshaler for ApplicationGatewayFirewallRuleSet.
2431func (agfrs ApplicationGatewayFirewallRuleSet) MarshalJSON() ([]byte, error) {
2432	objectMap := make(map[string]interface{})
2433	if agfrs.ApplicationGatewayFirewallRuleSetPropertiesFormat != nil {
2434		objectMap["properties"] = agfrs.ApplicationGatewayFirewallRuleSetPropertiesFormat
2435	}
2436	if agfrs.ID != nil {
2437		objectMap["id"] = agfrs.ID
2438	}
2439	if agfrs.Name != nil {
2440		objectMap["name"] = agfrs.Name
2441	}
2442	if agfrs.Type != nil {
2443		objectMap["type"] = agfrs.Type
2444	}
2445	if agfrs.Location != nil {
2446		objectMap["location"] = agfrs.Location
2447	}
2448	if agfrs.Tags != nil {
2449		objectMap["tags"] = agfrs.Tags
2450	}
2451	return json.Marshal(objectMap)
2452}
2453
2454// UnmarshalJSON is the custom unmarshaler for ApplicationGatewayFirewallRuleSet struct.
2455func (agfrs *ApplicationGatewayFirewallRuleSet) UnmarshalJSON(body []byte) error {
2456	var m map[string]*json.RawMessage
2457	err := json.Unmarshal(body, &m)
2458	if err != nil {
2459		return err
2460	}
2461	for k, v := range m {
2462		switch k {
2463		case "properties":
2464			if v != nil {
2465				var applicationGatewayFirewallRuleSetPropertiesFormat ApplicationGatewayFirewallRuleSetPropertiesFormat
2466				err = json.Unmarshal(*v, &applicationGatewayFirewallRuleSetPropertiesFormat)
2467				if err != nil {
2468					return err
2469				}
2470				agfrs.ApplicationGatewayFirewallRuleSetPropertiesFormat = &applicationGatewayFirewallRuleSetPropertiesFormat
2471			}
2472		case "id":
2473			if v != nil {
2474				var ID string
2475				err = json.Unmarshal(*v, &ID)
2476				if err != nil {
2477					return err
2478				}
2479				agfrs.ID = &ID
2480			}
2481		case "name":
2482			if v != nil {
2483				var name string
2484				err = json.Unmarshal(*v, &name)
2485				if err != nil {
2486					return err
2487				}
2488				agfrs.Name = &name
2489			}
2490		case "type":
2491			if v != nil {
2492				var typeVar string
2493				err = json.Unmarshal(*v, &typeVar)
2494				if err != nil {
2495					return err
2496				}
2497				agfrs.Type = &typeVar
2498			}
2499		case "location":
2500			if v != nil {
2501				var location string
2502				err = json.Unmarshal(*v, &location)
2503				if err != nil {
2504					return err
2505				}
2506				agfrs.Location = &location
2507			}
2508		case "tags":
2509			if v != nil {
2510				var tags map[string]*string
2511				err = json.Unmarshal(*v, &tags)
2512				if err != nil {
2513					return err
2514				}
2515				agfrs.Tags = tags
2516			}
2517		}
2518	}
2519
2520	return nil
2521}
2522
2523// ApplicationGatewayFirewallRuleSetPropertiesFormat properties of the web application firewall rule set.
2524type ApplicationGatewayFirewallRuleSetPropertiesFormat struct {
2525	// ProvisioningState - The provisioning state of the web application firewall rule set.
2526	ProvisioningState *string `json:"provisioningState,omitempty"`
2527	// RuleSetType - The type of the web application firewall rule set.
2528	RuleSetType *string `json:"ruleSetType,omitempty"`
2529	// RuleSetVersion - The version of the web application firewall rule set type.
2530	RuleSetVersion *string `json:"ruleSetVersion,omitempty"`
2531	// RuleGroups - The rule groups of the web application firewall rule set.
2532	RuleGroups *[]ApplicationGatewayFirewallRuleGroup `json:"ruleGroups,omitempty"`
2533}
2534
2535// ApplicationGatewayFrontendIPConfiguration frontend IP configuration of an application gateway.
2536type ApplicationGatewayFrontendIPConfiguration struct {
2537	*ApplicationGatewayFrontendIPConfigurationPropertiesFormat `json:"properties,omitempty"`
2538	// Name - Name of the frontend IP configuration that is unique within an Application Gateway.
2539	Name *string `json:"name,omitempty"`
2540	// Etag - A unique read-only string that changes whenever the resource is updated.
2541	Etag *string `json:"etag,omitempty"`
2542	// Type - Type of the resource.
2543	Type *string `json:"type,omitempty"`
2544	// ID - Resource ID.
2545	ID *string `json:"id,omitempty"`
2546}
2547
2548// MarshalJSON is the custom marshaler for ApplicationGatewayFrontendIPConfiguration.
2549func (agfic ApplicationGatewayFrontendIPConfiguration) MarshalJSON() ([]byte, error) {
2550	objectMap := make(map[string]interface{})
2551	if agfic.ApplicationGatewayFrontendIPConfigurationPropertiesFormat != nil {
2552		objectMap["properties"] = agfic.ApplicationGatewayFrontendIPConfigurationPropertiesFormat
2553	}
2554	if agfic.Name != nil {
2555		objectMap["name"] = agfic.Name
2556	}
2557	if agfic.Etag != nil {
2558		objectMap["etag"] = agfic.Etag
2559	}
2560	if agfic.Type != nil {
2561		objectMap["type"] = agfic.Type
2562	}
2563	if agfic.ID != nil {
2564		objectMap["id"] = agfic.ID
2565	}
2566	return json.Marshal(objectMap)
2567}
2568
2569// UnmarshalJSON is the custom unmarshaler for ApplicationGatewayFrontendIPConfiguration struct.
2570func (agfic *ApplicationGatewayFrontendIPConfiguration) UnmarshalJSON(body []byte) error {
2571	var m map[string]*json.RawMessage
2572	err := json.Unmarshal(body, &m)
2573	if err != nil {
2574		return err
2575	}
2576	for k, v := range m {
2577		switch k {
2578		case "properties":
2579			if v != nil {
2580				var applicationGatewayFrontendIPConfigurationPropertiesFormat ApplicationGatewayFrontendIPConfigurationPropertiesFormat
2581				err = json.Unmarshal(*v, &applicationGatewayFrontendIPConfigurationPropertiesFormat)
2582				if err != nil {
2583					return err
2584				}
2585				agfic.ApplicationGatewayFrontendIPConfigurationPropertiesFormat = &applicationGatewayFrontendIPConfigurationPropertiesFormat
2586			}
2587		case "name":
2588			if v != nil {
2589				var name string
2590				err = json.Unmarshal(*v, &name)
2591				if err != nil {
2592					return err
2593				}
2594				agfic.Name = &name
2595			}
2596		case "etag":
2597			if v != nil {
2598				var etag string
2599				err = json.Unmarshal(*v, &etag)
2600				if err != nil {
2601					return err
2602				}
2603				agfic.Etag = &etag
2604			}
2605		case "type":
2606			if v != nil {
2607				var typeVar string
2608				err = json.Unmarshal(*v, &typeVar)
2609				if err != nil {
2610					return err
2611				}
2612				agfic.Type = &typeVar
2613			}
2614		case "id":
2615			if v != nil {
2616				var ID string
2617				err = json.Unmarshal(*v, &ID)
2618				if err != nil {
2619					return err
2620				}
2621				agfic.ID = &ID
2622			}
2623		}
2624	}
2625
2626	return nil
2627}
2628
2629// ApplicationGatewayFrontendIPConfigurationPropertiesFormat properties of Frontend IP configuration of an
2630// application gateway.
2631type ApplicationGatewayFrontendIPConfigurationPropertiesFormat struct {
2632	// PrivateIPAddress - PrivateIPAddress of the network interface IP Configuration.
2633	PrivateIPAddress *string `json:"privateIPAddress,omitempty"`
2634	// PrivateIPAllocationMethod - PrivateIP allocation method. Possible values include: 'Static', 'Dynamic'
2635	PrivateIPAllocationMethod IPAllocationMethod `json:"privateIPAllocationMethod,omitempty"`
2636	// Subnet - Reference of the subnet resource.
2637	Subnet *SubResource `json:"subnet,omitempty"`
2638	// PublicIPAddress - Reference of the PublicIP resource.
2639	PublicIPAddress *SubResource `json:"publicIPAddress,omitempty"`
2640	// ProvisioningState - Provisioning state of the public IP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
2641	ProvisioningState *string `json:"provisioningState,omitempty"`
2642}
2643
2644// ApplicationGatewayFrontendPort frontend port of an application gateway.
2645type ApplicationGatewayFrontendPort struct {
2646	*ApplicationGatewayFrontendPortPropertiesFormat `json:"properties,omitempty"`
2647	// Name - Name of the frontend port that is unique within an Application Gateway
2648	Name *string `json:"name,omitempty"`
2649	// Etag - A unique read-only string that changes whenever the resource is updated.
2650	Etag *string `json:"etag,omitempty"`
2651	// Type - Type of the resource.
2652	Type *string `json:"type,omitempty"`
2653	// ID - Resource ID.
2654	ID *string `json:"id,omitempty"`
2655}
2656
2657// MarshalJSON is the custom marshaler for ApplicationGatewayFrontendPort.
2658func (agfp ApplicationGatewayFrontendPort) MarshalJSON() ([]byte, error) {
2659	objectMap := make(map[string]interface{})
2660	if agfp.ApplicationGatewayFrontendPortPropertiesFormat != nil {
2661		objectMap["properties"] = agfp.ApplicationGatewayFrontendPortPropertiesFormat
2662	}
2663	if agfp.Name != nil {
2664		objectMap["name"] = agfp.Name
2665	}
2666	if agfp.Etag != nil {
2667		objectMap["etag"] = agfp.Etag
2668	}
2669	if agfp.Type != nil {
2670		objectMap["type"] = agfp.Type
2671	}
2672	if agfp.ID != nil {
2673		objectMap["id"] = agfp.ID
2674	}
2675	return json.Marshal(objectMap)
2676}
2677
2678// UnmarshalJSON is the custom unmarshaler for ApplicationGatewayFrontendPort struct.
2679func (agfp *ApplicationGatewayFrontendPort) UnmarshalJSON(body []byte) error {
2680	var m map[string]*json.RawMessage
2681	err := json.Unmarshal(body, &m)
2682	if err != nil {
2683		return err
2684	}
2685	for k, v := range m {
2686		switch k {
2687		case "properties":
2688			if v != nil {
2689				var applicationGatewayFrontendPortPropertiesFormat ApplicationGatewayFrontendPortPropertiesFormat
2690				err = json.Unmarshal(*v, &applicationGatewayFrontendPortPropertiesFormat)
2691				if err != nil {
2692					return err
2693				}
2694				agfp.ApplicationGatewayFrontendPortPropertiesFormat = &applicationGatewayFrontendPortPropertiesFormat
2695			}
2696		case "name":
2697			if v != nil {
2698				var name string
2699				err = json.Unmarshal(*v, &name)
2700				if err != nil {
2701					return err
2702				}
2703				agfp.Name = &name
2704			}
2705		case "etag":
2706			if v != nil {
2707				var etag string
2708				err = json.Unmarshal(*v, &etag)
2709				if err != nil {
2710					return err
2711				}
2712				agfp.Etag = &etag
2713			}
2714		case "type":
2715			if v != nil {
2716				var typeVar string
2717				err = json.Unmarshal(*v, &typeVar)
2718				if err != nil {
2719					return err
2720				}
2721				agfp.Type = &typeVar
2722			}
2723		case "id":
2724			if v != nil {
2725				var ID string
2726				err = json.Unmarshal(*v, &ID)
2727				if err != nil {
2728					return err
2729				}
2730				agfp.ID = &ID
2731			}
2732		}
2733	}
2734
2735	return nil
2736}
2737
2738// ApplicationGatewayFrontendPortPropertiesFormat properties of Frontend port of an application gateway.
2739type ApplicationGatewayFrontendPortPropertiesFormat struct {
2740	// Port - Frontend port
2741	Port *int32 `json:"port,omitempty"`
2742	// ProvisioningState - Provisioning state of the frontend port resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
2743	ProvisioningState *string `json:"provisioningState,omitempty"`
2744}
2745
2746// ApplicationGatewayHTTPListener http listener of an application gateway.
2747type ApplicationGatewayHTTPListener struct {
2748	*ApplicationGatewayHTTPListenerPropertiesFormat `json:"properties,omitempty"`
2749	// Name - Name of the HTTP listener that is unique within an Application Gateway.
2750	Name *string `json:"name,omitempty"`
2751	// Etag - A unique read-only string that changes whenever the resource is updated.
2752	Etag *string `json:"etag,omitempty"`
2753	// Type - Type of the resource.
2754	Type *string `json:"type,omitempty"`
2755	// ID - Resource ID.
2756	ID *string `json:"id,omitempty"`
2757}
2758
2759// MarshalJSON is the custom marshaler for ApplicationGatewayHTTPListener.
2760func (aghl ApplicationGatewayHTTPListener) MarshalJSON() ([]byte, error) {
2761	objectMap := make(map[string]interface{})
2762	if aghl.ApplicationGatewayHTTPListenerPropertiesFormat != nil {
2763		objectMap["properties"] = aghl.ApplicationGatewayHTTPListenerPropertiesFormat
2764	}
2765	if aghl.Name != nil {
2766		objectMap["name"] = aghl.Name
2767	}
2768	if aghl.Etag != nil {
2769		objectMap["etag"] = aghl.Etag
2770	}
2771	if aghl.Type != nil {
2772		objectMap["type"] = aghl.Type
2773	}
2774	if aghl.ID != nil {
2775		objectMap["id"] = aghl.ID
2776	}
2777	return json.Marshal(objectMap)
2778}
2779
2780// UnmarshalJSON is the custom unmarshaler for ApplicationGatewayHTTPListener struct.
2781func (aghl *ApplicationGatewayHTTPListener) UnmarshalJSON(body []byte) error {
2782	var m map[string]*json.RawMessage
2783	err := json.Unmarshal(body, &m)
2784	if err != nil {
2785		return err
2786	}
2787	for k, v := range m {
2788		switch k {
2789		case "properties":
2790			if v != nil {
2791				var applicationGatewayHTTPListenerPropertiesFormat ApplicationGatewayHTTPListenerPropertiesFormat
2792				err = json.Unmarshal(*v, &applicationGatewayHTTPListenerPropertiesFormat)
2793				if err != nil {
2794					return err
2795				}
2796				aghl.ApplicationGatewayHTTPListenerPropertiesFormat = &applicationGatewayHTTPListenerPropertiesFormat
2797			}
2798		case "name":
2799			if v != nil {
2800				var name string
2801				err = json.Unmarshal(*v, &name)
2802				if err != nil {
2803					return err
2804				}
2805				aghl.Name = &name
2806			}
2807		case "etag":
2808			if v != nil {
2809				var etag string
2810				err = json.Unmarshal(*v, &etag)
2811				if err != nil {
2812					return err
2813				}
2814				aghl.Etag = &etag
2815			}
2816		case "type":
2817			if v != nil {
2818				var typeVar string
2819				err = json.Unmarshal(*v, &typeVar)
2820				if err != nil {
2821					return err
2822				}
2823				aghl.Type = &typeVar
2824			}
2825		case "id":
2826			if v != nil {
2827				var ID string
2828				err = json.Unmarshal(*v, &ID)
2829				if err != nil {
2830					return err
2831				}
2832				aghl.ID = &ID
2833			}
2834		}
2835	}
2836
2837	return nil
2838}
2839
2840// ApplicationGatewayHTTPListenerPropertiesFormat properties of HTTP listener of an application gateway.
2841type ApplicationGatewayHTTPListenerPropertiesFormat struct {
2842	// FrontendIPConfiguration - Frontend IP configuration resource of an application gateway.
2843	FrontendIPConfiguration *SubResource `json:"frontendIPConfiguration,omitempty"`
2844	// FrontendPort - Frontend port resource of an application gateway.
2845	FrontendPort *SubResource `json:"frontendPort,omitempty"`
2846	// Protocol - Protocol of the HTTP listener. Possible values are 'Http' and 'Https'. Possible values include: 'HTTP', 'HTTPS'
2847	Protocol ApplicationGatewayProtocol `json:"protocol,omitempty"`
2848	// HostName - Host name of HTTP listener.
2849	HostName *string `json:"hostName,omitempty"`
2850	// SslCertificate - SSL certificate resource of an application gateway.
2851	SslCertificate *SubResource `json:"sslCertificate,omitempty"`
2852	// RequireServerNameIndication - Applicable only if protocol is https. Enables SNI for multi-hosting.
2853	RequireServerNameIndication *bool `json:"requireServerNameIndication,omitempty"`
2854	// ProvisioningState - Provisioning state of the HTTP listener resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
2855	ProvisioningState *string `json:"provisioningState,omitempty"`
2856}
2857
2858// ApplicationGatewayIPConfiguration IP configuration of an application gateway. Currently 1 public and 1 private
2859// IP configuration is allowed.
2860type ApplicationGatewayIPConfiguration struct {
2861	*ApplicationGatewayIPConfigurationPropertiesFormat `json:"properties,omitempty"`
2862	// Name - Name of the IP configuration that is unique within an Application Gateway.
2863	Name *string `json:"name,omitempty"`
2864	// Etag - A unique read-only string that changes whenever the resource is updated.
2865	Etag *string `json:"etag,omitempty"`
2866	// Type - Type of the resource.
2867	Type *string `json:"type,omitempty"`
2868	// ID - Resource ID.
2869	ID *string `json:"id,omitempty"`
2870}
2871
2872// MarshalJSON is the custom marshaler for ApplicationGatewayIPConfiguration.
2873func (agic ApplicationGatewayIPConfiguration) MarshalJSON() ([]byte, error) {
2874	objectMap := make(map[string]interface{})
2875	if agic.ApplicationGatewayIPConfigurationPropertiesFormat != nil {
2876		objectMap["properties"] = agic.ApplicationGatewayIPConfigurationPropertiesFormat
2877	}
2878	if agic.Name != nil {
2879		objectMap["name"] = agic.Name
2880	}
2881	if agic.Etag != nil {
2882		objectMap["etag"] = agic.Etag
2883	}
2884	if agic.Type != nil {
2885		objectMap["type"] = agic.Type
2886	}
2887	if agic.ID != nil {
2888		objectMap["id"] = agic.ID
2889	}
2890	return json.Marshal(objectMap)
2891}
2892
2893// UnmarshalJSON is the custom unmarshaler for ApplicationGatewayIPConfiguration struct.
2894func (agic *ApplicationGatewayIPConfiguration) UnmarshalJSON(body []byte) error {
2895	var m map[string]*json.RawMessage
2896	err := json.Unmarshal(body, &m)
2897	if err != nil {
2898		return err
2899	}
2900	for k, v := range m {
2901		switch k {
2902		case "properties":
2903			if v != nil {
2904				var applicationGatewayIPConfigurationPropertiesFormat ApplicationGatewayIPConfigurationPropertiesFormat
2905				err = json.Unmarshal(*v, &applicationGatewayIPConfigurationPropertiesFormat)
2906				if err != nil {
2907					return err
2908				}
2909				agic.ApplicationGatewayIPConfigurationPropertiesFormat = &applicationGatewayIPConfigurationPropertiesFormat
2910			}
2911		case "name":
2912			if v != nil {
2913				var name string
2914				err = json.Unmarshal(*v, &name)
2915				if err != nil {
2916					return err
2917				}
2918				agic.Name = &name
2919			}
2920		case "etag":
2921			if v != nil {
2922				var etag string
2923				err = json.Unmarshal(*v, &etag)
2924				if err != nil {
2925					return err
2926				}
2927				agic.Etag = &etag
2928			}
2929		case "type":
2930			if v != nil {
2931				var typeVar string
2932				err = json.Unmarshal(*v, &typeVar)
2933				if err != nil {
2934					return err
2935				}
2936				agic.Type = &typeVar
2937			}
2938		case "id":
2939			if v != nil {
2940				var ID string
2941				err = json.Unmarshal(*v, &ID)
2942				if err != nil {
2943					return err
2944				}
2945				agic.ID = &ID
2946			}
2947		}
2948	}
2949
2950	return nil
2951}
2952
2953// ApplicationGatewayIPConfigurationPropertiesFormat properties of IP configuration of an application gateway.
2954type ApplicationGatewayIPConfigurationPropertiesFormat struct {
2955	// Subnet - Reference of the subnet resource. A subnet from where application gateway gets its private address.
2956	Subnet *SubResource `json:"subnet,omitempty"`
2957	// ProvisioningState - Provisioning state of the application gateway subnet resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
2958	ProvisioningState *string `json:"provisioningState,omitempty"`
2959}
2960
2961// ApplicationGatewayListResult response for ListApplicationGateways API service call.
2962type ApplicationGatewayListResult struct {
2963	autorest.Response `json:"-"`
2964	// Value - List of an application gateways in a resource group.
2965	Value *[]ApplicationGateway `json:"value,omitempty"`
2966	// NextLink - URL to get the next set of results.
2967	NextLink *string `json:"nextLink,omitempty"`
2968}
2969
2970// ApplicationGatewayListResultIterator provides access to a complete listing of ApplicationGateway values.
2971type ApplicationGatewayListResultIterator struct {
2972	i    int
2973	page ApplicationGatewayListResultPage
2974}
2975
2976// Next advances to the next value.  If there was an error making
2977// the request the iterator does not advance and the error is returned.
2978func (iter *ApplicationGatewayListResultIterator) Next() error {
2979	iter.i++
2980	if iter.i < len(iter.page.Values()) {
2981		return nil
2982	}
2983	err := iter.page.Next()
2984	if err != nil {
2985		iter.i--
2986		return err
2987	}
2988	iter.i = 0
2989	return nil
2990}
2991
2992// NotDone returns true if the enumeration should be started or is not yet complete.
2993func (iter ApplicationGatewayListResultIterator) NotDone() bool {
2994	return iter.page.NotDone() && iter.i < len(iter.page.Values())
2995}
2996
2997// Response returns the raw server response from the last page request.
2998func (iter ApplicationGatewayListResultIterator) Response() ApplicationGatewayListResult {
2999	return iter.page.Response()
3000}
3001
3002// Value returns the current value or a zero-initialized value if the
3003// iterator has advanced beyond the end of the collection.
3004func (iter ApplicationGatewayListResultIterator) Value() ApplicationGateway {
3005	if !iter.page.NotDone() {
3006		return ApplicationGateway{}
3007	}
3008	return iter.page.Values()[iter.i]
3009}
3010
3011// IsEmpty returns true if the ListResult contains no values.
3012func (aglr ApplicationGatewayListResult) IsEmpty() bool {
3013	return aglr.Value == nil || len(*aglr.Value) == 0
3014}
3015
3016// applicationGatewayListResultPreparer prepares a request to retrieve the next set of results.
3017// It returns nil if no more results exist.
3018func (aglr ApplicationGatewayListResult) applicationGatewayListResultPreparer() (*http.Request, error) {
3019	if aglr.NextLink == nil || len(to.String(aglr.NextLink)) < 1 {
3020		return nil, nil
3021	}
3022	return autorest.Prepare(&http.Request{},
3023		autorest.AsJSON(),
3024		autorest.AsGet(),
3025		autorest.WithBaseURL(to.String(aglr.NextLink)))
3026}
3027
3028// ApplicationGatewayListResultPage contains a page of ApplicationGateway values.
3029type ApplicationGatewayListResultPage struct {
3030	fn   func(ApplicationGatewayListResult) (ApplicationGatewayListResult, error)
3031	aglr ApplicationGatewayListResult
3032}
3033
3034// Next advances to the next page of values.  If there was an error making
3035// the request the page does not advance and the error is returned.
3036func (page *ApplicationGatewayListResultPage) Next() error {
3037	next, err := page.fn(page.aglr)
3038	if err != nil {
3039		return err
3040	}
3041	page.aglr = next
3042	return nil
3043}
3044
3045// NotDone returns true if the page enumeration should be started or is not yet complete.
3046func (page ApplicationGatewayListResultPage) NotDone() bool {
3047	return !page.aglr.IsEmpty()
3048}
3049
3050// Response returns the raw server response from the last page request.
3051func (page ApplicationGatewayListResultPage) Response() ApplicationGatewayListResult {
3052	return page.aglr
3053}
3054
3055// Values returns the slice of values for the current page or nil if there are no values.
3056func (page ApplicationGatewayListResultPage) Values() []ApplicationGateway {
3057	if page.aglr.IsEmpty() {
3058		return nil
3059	}
3060	return *page.aglr.Value
3061}
3062
3063// ApplicationGatewayPathRule path rule of URL path map of an application gateway.
3064type ApplicationGatewayPathRule struct {
3065	*ApplicationGatewayPathRulePropertiesFormat `json:"properties,omitempty"`
3066	// Name - Name of the path rule that is unique within an Application Gateway.
3067	Name *string `json:"name,omitempty"`
3068	// Etag - A unique read-only string that changes whenever the resource is updated.
3069	Etag *string `json:"etag,omitempty"`
3070	// Type - Type of the resource.
3071	Type *string `json:"type,omitempty"`
3072	// ID - Resource ID.
3073	ID *string `json:"id,omitempty"`
3074}
3075
3076// MarshalJSON is the custom marshaler for ApplicationGatewayPathRule.
3077func (agpr ApplicationGatewayPathRule) MarshalJSON() ([]byte, error) {
3078	objectMap := make(map[string]interface{})
3079	if agpr.ApplicationGatewayPathRulePropertiesFormat != nil {
3080		objectMap["properties"] = agpr.ApplicationGatewayPathRulePropertiesFormat
3081	}
3082	if agpr.Name != nil {
3083		objectMap["name"] = agpr.Name
3084	}
3085	if agpr.Etag != nil {
3086		objectMap["etag"] = agpr.Etag
3087	}
3088	if agpr.Type != nil {
3089		objectMap["type"] = agpr.Type
3090	}
3091	if agpr.ID != nil {
3092		objectMap["id"] = agpr.ID
3093	}
3094	return json.Marshal(objectMap)
3095}
3096
3097// UnmarshalJSON is the custom unmarshaler for ApplicationGatewayPathRule struct.
3098func (agpr *ApplicationGatewayPathRule) UnmarshalJSON(body []byte) error {
3099	var m map[string]*json.RawMessage
3100	err := json.Unmarshal(body, &m)
3101	if err != nil {
3102		return err
3103	}
3104	for k, v := range m {
3105		switch k {
3106		case "properties":
3107			if v != nil {
3108				var applicationGatewayPathRulePropertiesFormat ApplicationGatewayPathRulePropertiesFormat
3109				err = json.Unmarshal(*v, &applicationGatewayPathRulePropertiesFormat)
3110				if err != nil {
3111					return err
3112				}
3113				agpr.ApplicationGatewayPathRulePropertiesFormat = &applicationGatewayPathRulePropertiesFormat
3114			}
3115		case "name":
3116			if v != nil {
3117				var name string
3118				err = json.Unmarshal(*v, &name)
3119				if err != nil {
3120					return err
3121				}
3122				agpr.Name = &name
3123			}
3124		case "etag":
3125			if v != nil {
3126				var etag string
3127				err = json.Unmarshal(*v, &etag)
3128				if err != nil {
3129					return err
3130				}
3131				agpr.Etag = &etag
3132			}
3133		case "type":
3134			if v != nil {
3135				var typeVar string
3136				err = json.Unmarshal(*v, &typeVar)
3137				if err != nil {
3138					return err
3139				}
3140				agpr.Type = &typeVar
3141			}
3142		case "id":
3143			if v != nil {
3144				var ID string
3145				err = json.Unmarshal(*v, &ID)
3146				if err != nil {
3147					return err
3148				}
3149				agpr.ID = &ID
3150			}
3151		}
3152	}
3153
3154	return nil
3155}
3156
3157// ApplicationGatewayPathRulePropertiesFormat properties of path rule of an application gateway.
3158type ApplicationGatewayPathRulePropertiesFormat struct {
3159	// Paths - Path rules of URL path map.
3160	Paths *[]string `json:"paths,omitempty"`
3161	// BackendAddressPool - Backend address pool resource of URL path map path rule.
3162	BackendAddressPool *SubResource `json:"backendAddressPool,omitempty"`
3163	// BackendHTTPSettings - Backend http settings resource of URL path map path rule.
3164	BackendHTTPSettings *SubResource `json:"backendHttpSettings,omitempty"`
3165	// RedirectConfiguration - Redirect configuration resource of URL path map path rule.
3166	RedirectConfiguration *SubResource `json:"redirectConfiguration,omitempty"`
3167	// ProvisioningState - Path rule of URL path map resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
3168	ProvisioningState *string `json:"provisioningState,omitempty"`
3169}
3170
3171// ApplicationGatewayProbe probe of the application gateway.
3172type ApplicationGatewayProbe struct {
3173	*ApplicationGatewayProbePropertiesFormat `json:"properties,omitempty"`
3174	// Name - Name of the probe that is unique within an Application Gateway.
3175	Name *string `json:"name,omitempty"`
3176	// Etag - A unique read-only string that changes whenever the resource is updated.
3177	Etag *string `json:"etag,omitempty"`
3178	// Type - Type of the resource.
3179	Type *string `json:"type,omitempty"`
3180	// ID - Resource ID.
3181	ID *string `json:"id,omitempty"`
3182}
3183
3184// MarshalJSON is the custom marshaler for ApplicationGatewayProbe.
3185func (agp ApplicationGatewayProbe) MarshalJSON() ([]byte, error) {
3186	objectMap := make(map[string]interface{})
3187	if agp.ApplicationGatewayProbePropertiesFormat != nil {
3188		objectMap["properties"] = agp.ApplicationGatewayProbePropertiesFormat
3189	}
3190	if agp.Name != nil {
3191		objectMap["name"] = agp.Name
3192	}
3193	if agp.Etag != nil {
3194		objectMap["etag"] = agp.Etag
3195	}
3196	if agp.Type != nil {
3197		objectMap["type"] = agp.Type
3198	}
3199	if agp.ID != nil {
3200		objectMap["id"] = agp.ID
3201	}
3202	return json.Marshal(objectMap)
3203}
3204
3205// UnmarshalJSON is the custom unmarshaler for ApplicationGatewayProbe struct.
3206func (agp *ApplicationGatewayProbe) UnmarshalJSON(body []byte) error {
3207	var m map[string]*json.RawMessage
3208	err := json.Unmarshal(body, &m)
3209	if err != nil {
3210		return err
3211	}
3212	for k, v := range m {
3213		switch k {
3214		case "properties":
3215			if v != nil {
3216				var applicationGatewayProbePropertiesFormat ApplicationGatewayProbePropertiesFormat
3217				err = json.Unmarshal(*v, &applicationGatewayProbePropertiesFormat)
3218				if err != nil {
3219					return err
3220				}
3221				agp.ApplicationGatewayProbePropertiesFormat = &applicationGatewayProbePropertiesFormat
3222			}
3223		case "name":
3224			if v != nil {
3225				var name string
3226				err = json.Unmarshal(*v, &name)
3227				if err != nil {
3228					return err
3229				}
3230				agp.Name = &name
3231			}
3232		case "etag":
3233			if v != nil {
3234				var etag string
3235				err = json.Unmarshal(*v, &etag)
3236				if err != nil {
3237					return err
3238				}
3239				agp.Etag = &etag
3240			}
3241		case "type":
3242			if v != nil {
3243				var typeVar string
3244				err = json.Unmarshal(*v, &typeVar)
3245				if err != nil {
3246					return err
3247				}
3248				agp.Type = &typeVar
3249			}
3250		case "id":
3251			if v != nil {
3252				var ID string
3253				err = json.Unmarshal(*v, &ID)
3254				if err != nil {
3255					return err
3256				}
3257				agp.ID = &ID
3258			}
3259		}
3260	}
3261
3262	return nil
3263}
3264
3265// ApplicationGatewayProbeHealthResponseMatch application gateway probe health response match
3266type ApplicationGatewayProbeHealthResponseMatch struct {
3267	// Body - Body that must be contained in the health response. Default value is empty.
3268	Body *string `json:"body,omitempty"`
3269	// StatusCodes - Allowed ranges of healthy status codes. Default range of healthy status codes is 200-399.
3270	StatusCodes *[]string `json:"statusCodes,omitempty"`
3271}
3272
3273// ApplicationGatewayProbePropertiesFormat properties of probe of an application gateway.
3274type ApplicationGatewayProbePropertiesFormat struct {
3275	// Protocol - The protocol used for the probe. Possible values are 'Http' and 'Https'. Possible values include: 'HTTP', 'HTTPS'
3276	Protocol ApplicationGatewayProtocol `json:"protocol,omitempty"`
3277	// Host - Host name to send the probe to.
3278	Host *string `json:"host,omitempty"`
3279	// Path - Relative path of probe. Valid path starts from '/'. Probe is sent to <Protocol>://<host>:<port><path>
3280	Path *string `json:"path,omitempty"`
3281	// Interval - The probing interval in seconds. This is the time interval between two consecutive probes. Acceptable values are from 1 second to 86400 seconds.
3282	Interval *int32 `json:"interval,omitempty"`
3283	// Timeout - the probe timeout in seconds. Probe marked as failed if valid response is not received with this timeout period. Acceptable values are from 1 second to 86400 seconds.
3284	Timeout *int32 `json:"timeout,omitempty"`
3285	// UnhealthyThreshold - The probe retry count. Backend server is marked down after consecutive probe failure count reaches UnhealthyThreshold. Acceptable values are from 1 second to 20.
3286	UnhealthyThreshold *int32 `json:"unhealthyThreshold,omitempty"`
3287	// PickHostNameFromBackendHTTPSettings - Whether the host header should be picked from the backend http settings. Default value is false.
3288	PickHostNameFromBackendHTTPSettings *bool `json:"pickHostNameFromBackendHttpSettings,omitempty"`
3289	// MinServers - Minimum number of servers that are always marked healthy. Default value is 0.
3290	MinServers *int32 `json:"minServers,omitempty"`
3291	// Match - Criterion for classifying a healthy probe response.
3292	Match *ApplicationGatewayProbeHealthResponseMatch `json:"match,omitempty"`
3293	// ProvisioningState - Provisioning state of the backend http settings resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
3294	ProvisioningState *string `json:"provisioningState,omitempty"`
3295}
3296
3297// ApplicationGatewayPropertiesFormat properties of the application gateway.
3298type ApplicationGatewayPropertiesFormat struct {
3299	// Sku - SKU of the application gateway resource.
3300	Sku *ApplicationGatewaySku `json:"sku,omitempty"`
3301	// SslPolicy - SSL policy of the application gateway resource.
3302	SslPolicy *ApplicationGatewaySslPolicy `json:"sslPolicy,omitempty"`
3303	// OperationalState - Operational state of the application gateway resource. Possible values include: 'Stopped', 'Starting', 'Running', 'Stopping'
3304	OperationalState ApplicationGatewayOperationalState `json:"operationalState,omitempty"`
3305	// GatewayIPConfigurations - Subnets of application the gateway resource.
3306	GatewayIPConfigurations *[]ApplicationGatewayIPConfiguration `json:"gatewayIPConfigurations,omitempty"`
3307	// AuthenticationCertificates - Authentication certificates of the application gateway resource.
3308	AuthenticationCertificates *[]ApplicationGatewayAuthenticationCertificate `json:"authenticationCertificates,omitempty"`
3309	// TrustedRootCertificates - Trusted Root certificates of the application gateway resource.
3310	TrustedRootCertificates *[]ApplicationGatewayTrustedRootCertificate `json:"trustedRootCertificates,omitempty"`
3311	// SslCertificates - SSL certificates of the application gateway resource.
3312	SslCertificates *[]ApplicationGatewaySslCertificate `json:"sslCertificates,omitempty"`
3313	// FrontendIPConfigurations - Frontend IP addresses of the application gateway resource.
3314	FrontendIPConfigurations *[]ApplicationGatewayFrontendIPConfiguration `json:"frontendIPConfigurations,omitempty"`
3315	// FrontendPorts - Frontend ports of the application gateway resource.
3316	FrontendPorts *[]ApplicationGatewayFrontendPort `json:"frontendPorts,omitempty"`
3317	// Probes - Probes of the application gateway resource.
3318	Probes *[]ApplicationGatewayProbe `json:"probes,omitempty"`
3319	// BackendAddressPools - Backend address pool of the application gateway resource.
3320	BackendAddressPools *[]ApplicationGatewayBackendAddressPool `json:"backendAddressPools,omitempty"`
3321	// BackendHTTPSettingsCollection - Backend http settings of the application gateway resource.
3322	BackendHTTPSettingsCollection *[]ApplicationGatewayBackendHTTPSettings `json:"backendHttpSettingsCollection,omitempty"`
3323	// HTTPListeners - Http listeners of the application gateway resource.
3324	HTTPListeners *[]ApplicationGatewayHTTPListener `json:"httpListeners,omitempty"`
3325	// URLPathMaps - URL path map of the application gateway resource.
3326	URLPathMaps *[]ApplicationGatewayURLPathMap `json:"urlPathMaps,omitempty"`
3327	// RequestRoutingRules - Request routing rules of the application gateway resource.
3328	RequestRoutingRules *[]ApplicationGatewayRequestRoutingRule `json:"requestRoutingRules,omitempty"`
3329	// RedirectConfigurations - Redirect configurations of the application gateway resource.
3330	RedirectConfigurations *[]ApplicationGatewayRedirectConfiguration `json:"redirectConfigurations,omitempty"`
3331	// WebApplicationFirewallConfiguration - Web application firewall configuration.
3332	WebApplicationFirewallConfiguration *ApplicationGatewayWebApplicationFirewallConfiguration `json:"webApplicationFirewallConfiguration,omitempty"`
3333	// EnableHTTP2 - Whether HTTP2 is enabled on the application gateway resource.
3334	EnableHTTP2 *bool `json:"enableHttp2,omitempty"`
3335	// EnableFips - Whether FIPS is enabled on the application gateway resource.
3336	EnableFips *bool `json:"enableFips,omitempty"`
3337	// AutoscaleConfiguration - Autoscale Configuration.
3338	AutoscaleConfiguration *ApplicationGatewayAutoscaleConfiguration `json:"autoscaleConfiguration,omitempty"`
3339	// ResourceGUID - Resource GUID property of the application gateway resource.
3340	ResourceGUID *string `json:"resourceGuid,omitempty"`
3341	// ProvisioningState - Provisioning state of the application gateway resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
3342	ProvisioningState *string `json:"provisioningState,omitempty"`
3343}
3344
3345// ApplicationGatewayRedirectConfiguration redirect configuration of an application gateway.
3346type ApplicationGatewayRedirectConfiguration struct {
3347	*ApplicationGatewayRedirectConfigurationPropertiesFormat `json:"properties,omitempty"`
3348	// Name - Name of the redirect configuration that is unique within an Application Gateway.
3349	Name *string `json:"name,omitempty"`
3350	// Etag - A unique read-only string that changes whenever the resource is updated.
3351	Etag *string `json:"etag,omitempty"`
3352	// Type - Type of the resource.
3353	Type *string `json:"type,omitempty"`
3354	// ID - Resource ID.
3355	ID *string `json:"id,omitempty"`
3356}
3357
3358// MarshalJSON is the custom marshaler for ApplicationGatewayRedirectConfiguration.
3359func (agrc ApplicationGatewayRedirectConfiguration) MarshalJSON() ([]byte, error) {
3360	objectMap := make(map[string]interface{})
3361	if agrc.ApplicationGatewayRedirectConfigurationPropertiesFormat != nil {
3362		objectMap["properties"] = agrc.ApplicationGatewayRedirectConfigurationPropertiesFormat
3363	}
3364	if agrc.Name != nil {
3365		objectMap["name"] = agrc.Name
3366	}
3367	if agrc.Etag != nil {
3368		objectMap["etag"] = agrc.Etag
3369	}
3370	if agrc.Type != nil {
3371		objectMap["type"] = agrc.Type
3372	}
3373	if agrc.ID != nil {
3374		objectMap["id"] = agrc.ID
3375	}
3376	return json.Marshal(objectMap)
3377}
3378
3379// UnmarshalJSON is the custom unmarshaler for ApplicationGatewayRedirectConfiguration struct.
3380func (agrc *ApplicationGatewayRedirectConfiguration) UnmarshalJSON(body []byte) error {
3381	var m map[string]*json.RawMessage
3382	err := json.Unmarshal(body, &m)
3383	if err != nil {
3384		return err
3385	}
3386	for k, v := range m {
3387		switch k {
3388		case "properties":
3389			if v != nil {
3390				var applicationGatewayRedirectConfigurationPropertiesFormat ApplicationGatewayRedirectConfigurationPropertiesFormat
3391				err = json.Unmarshal(*v, &applicationGatewayRedirectConfigurationPropertiesFormat)
3392				if err != nil {
3393					return err
3394				}
3395				agrc.ApplicationGatewayRedirectConfigurationPropertiesFormat = &applicationGatewayRedirectConfigurationPropertiesFormat
3396			}
3397		case "name":
3398			if v != nil {
3399				var name string
3400				err = json.Unmarshal(*v, &name)
3401				if err != nil {
3402					return err
3403				}
3404				agrc.Name = &name
3405			}
3406		case "etag":
3407			if v != nil {
3408				var etag string
3409				err = json.Unmarshal(*v, &etag)
3410				if err != nil {
3411					return err
3412				}
3413				agrc.Etag = &etag
3414			}
3415		case "type":
3416			if v != nil {
3417				var typeVar string
3418				err = json.Unmarshal(*v, &typeVar)
3419				if err != nil {
3420					return err
3421				}
3422				agrc.Type = &typeVar
3423			}
3424		case "id":
3425			if v != nil {
3426				var ID string
3427				err = json.Unmarshal(*v, &ID)
3428				if err != nil {
3429					return err
3430				}
3431				agrc.ID = &ID
3432			}
3433		}
3434	}
3435
3436	return nil
3437}
3438
3439// ApplicationGatewayRedirectConfigurationPropertiesFormat properties of redirect configuration of the application
3440// gateway.
3441type ApplicationGatewayRedirectConfigurationPropertiesFormat struct {
3442	// RedirectType - Supported http redirection types - Permanent, Temporary, Found, SeeOther. Possible values include: 'Permanent', 'Found', 'SeeOther', 'Temporary'
3443	RedirectType ApplicationGatewayRedirectType `json:"redirectType,omitempty"`
3444	// TargetListener - Reference to a listener to redirect the request to.
3445	TargetListener *SubResource `json:"targetListener,omitempty"`
3446	// TargetURL - Url to redirect the request to.
3447	TargetURL *string `json:"targetUrl,omitempty"`
3448	// IncludePath - Include path in the redirected url.
3449	IncludePath *bool `json:"includePath,omitempty"`
3450	// IncludeQueryString - Include query string in the redirected url.
3451	IncludeQueryString *bool `json:"includeQueryString,omitempty"`
3452	// RequestRoutingRules - Request routing specifying redirect configuration.
3453	RequestRoutingRules *[]SubResource `json:"requestRoutingRules,omitempty"`
3454	// URLPathMaps - Url path maps specifying default redirect configuration.
3455	URLPathMaps *[]SubResource `json:"urlPathMaps,omitempty"`
3456	// PathRules - Path rules specifying redirect configuration.
3457	PathRules *[]SubResource `json:"pathRules,omitempty"`
3458}
3459
3460// ApplicationGatewayRequestRoutingRule request routing rule of an application gateway.
3461type ApplicationGatewayRequestRoutingRule struct {
3462	*ApplicationGatewayRequestRoutingRulePropertiesFormat `json:"properties,omitempty"`
3463	// Name - Name of the request routing rule that is unique within an Application Gateway.
3464	Name *string `json:"name,omitempty"`
3465	// Etag - A unique read-only string that changes whenever the resource is updated.
3466	Etag *string `json:"etag,omitempty"`
3467	// Type - Type of the resource.
3468	Type *string `json:"type,omitempty"`
3469	// ID - Resource ID.
3470	ID *string `json:"id,omitempty"`
3471}
3472
3473// MarshalJSON is the custom marshaler for ApplicationGatewayRequestRoutingRule.
3474func (agrrr ApplicationGatewayRequestRoutingRule) MarshalJSON() ([]byte, error) {
3475	objectMap := make(map[string]interface{})
3476	if agrrr.ApplicationGatewayRequestRoutingRulePropertiesFormat != nil {
3477		objectMap["properties"] = agrrr.ApplicationGatewayRequestRoutingRulePropertiesFormat
3478	}
3479	if agrrr.Name != nil {
3480		objectMap["name"] = agrrr.Name
3481	}
3482	if agrrr.Etag != nil {
3483		objectMap["etag"] = agrrr.Etag
3484	}
3485	if agrrr.Type != nil {
3486		objectMap["type"] = agrrr.Type
3487	}
3488	if agrrr.ID != nil {
3489		objectMap["id"] = agrrr.ID
3490	}
3491	return json.Marshal(objectMap)
3492}
3493
3494// UnmarshalJSON is the custom unmarshaler for ApplicationGatewayRequestRoutingRule struct.
3495func (agrrr *ApplicationGatewayRequestRoutingRule) UnmarshalJSON(body []byte) error {
3496	var m map[string]*json.RawMessage
3497	err := json.Unmarshal(body, &m)
3498	if err != nil {
3499		return err
3500	}
3501	for k, v := range m {
3502		switch k {
3503		case "properties":
3504			if v != nil {
3505				var applicationGatewayRequestRoutingRulePropertiesFormat ApplicationGatewayRequestRoutingRulePropertiesFormat
3506				err = json.Unmarshal(*v, &applicationGatewayRequestRoutingRulePropertiesFormat)
3507				if err != nil {
3508					return err
3509				}
3510				agrrr.ApplicationGatewayRequestRoutingRulePropertiesFormat = &applicationGatewayRequestRoutingRulePropertiesFormat
3511			}
3512		case "name":
3513			if v != nil {
3514				var name string
3515				err = json.Unmarshal(*v, &name)
3516				if err != nil {
3517					return err
3518				}
3519				agrrr.Name = &name
3520			}
3521		case "etag":
3522			if v != nil {
3523				var etag string
3524				err = json.Unmarshal(*v, &etag)
3525				if err != nil {
3526					return err
3527				}
3528				agrrr.Etag = &etag
3529			}
3530		case "type":
3531			if v != nil {
3532				var typeVar string
3533				err = json.Unmarshal(*v, &typeVar)
3534				if err != nil {
3535					return err
3536				}
3537				agrrr.Type = &typeVar
3538			}
3539		case "id":
3540			if v != nil {
3541				var ID string
3542				err = json.Unmarshal(*v, &ID)
3543				if err != nil {
3544					return err
3545				}
3546				agrrr.ID = &ID
3547			}
3548		}
3549	}
3550
3551	return nil
3552}
3553
3554// ApplicationGatewayRequestRoutingRulePropertiesFormat properties of request routing rule of the application
3555// gateway.
3556type ApplicationGatewayRequestRoutingRulePropertiesFormat struct {
3557	// RuleType - Rule type. Possible values include: 'Basic', 'PathBasedRouting'
3558	RuleType ApplicationGatewayRequestRoutingRuleType `json:"ruleType,omitempty"`
3559	// BackendAddressPool - Backend address pool resource of the application gateway.
3560	BackendAddressPool *SubResource `json:"backendAddressPool,omitempty"`
3561	// BackendHTTPSettings - Backend http settings resource of the application gateway.
3562	BackendHTTPSettings *SubResource `json:"backendHttpSettings,omitempty"`
3563	// HTTPListener - Http listener resource of the application gateway.
3564	HTTPListener *SubResource `json:"httpListener,omitempty"`
3565	// URLPathMap - URL path map resource of the application gateway.
3566	URLPathMap *SubResource `json:"urlPathMap,omitempty"`
3567	// RedirectConfiguration - Redirect configuration resource of the application gateway.
3568	RedirectConfiguration *SubResource `json:"redirectConfiguration,omitempty"`
3569	// ProvisioningState - Provisioning state of the request routing rule resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
3570	ProvisioningState *string `json:"provisioningState,omitempty"`
3571}
3572
3573// ApplicationGatewaysBackendHealthFuture an abstraction for monitoring and retrieving the results of a
3574// long-running operation.
3575type ApplicationGatewaysBackendHealthFuture struct {
3576	azure.Future
3577}
3578
3579// Result returns the result of the asynchronous operation.
3580// If the operation has not completed it will return an error.
3581func (future *ApplicationGatewaysBackendHealthFuture) Result(client ApplicationGatewaysClient) (agbh ApplicationGatewayBackendHealth, err error) {
3582	var done bool
3583	done, err = future.Done(client)
3584	if err != nil {
3585		err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysBackendHealthFuture", "Result", future.Response(), "Polling failure")
3586		return
3587	}
3588	if !done {
3589		err = azure.NewAsyncOpIncompleteError("network.ApplicationGatewaysBackendHealthFuture")
3590		return
3591	}
3592	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
3593	if agbh.Response.Response, err = future.GetResult(sender); err == nil && agbh.Response.Response.StatusCode != http.StatusNoContent {
3594		agbh, err = client.BackendHealthResponder(agbh.Response.Response)
3595		if err != nil {
3596			err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysBackendHealthFuture", "Result", agbh.Response.Response, "Failure responding to request")
3597		}
3598	}
3599	return
3600}
3601
3602// ApplicationGatewaysCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
3603// long-running operation.
3604type ApplicationGatewaysCreateOrUpdateFuture struct {
3605	azure.Future
3606}
3607
3608// Result returns the result of the asynchronous operation.
3609// If the operation has not completed it will return an error.
3610func (future *ApplicationGatewaysCreateOrUpdateFuture) Result(client ApplicationGatewaysClient) (ag ApplicationGateway, err error) {
3611	var done bool
3612	done, err = future.Done(client)
3613	if err != nil {
3614		err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
3615		return
3616	}
3617	if !done {
3618		err = azure.NewAsyncOpIncompleteError("network.ApplicationGatewaysCreateOrUpdateFuture")
3619		return
3620	}
3621	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
3622	if ag.Response.Response, err = future.GetResult(sender); err == nil && ag.Response.Response.StatusCode != http.StatusNoContent {
3623		ag, err = client.CreateOrUpdateResponder(ag.Response.Response)
3624		if err != nil {
3625			err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysCreateOrUpdateFuture", "Result", ag.Response.Response, "Failure responding to request")
3626		}
3627	}
3628	return
3629}
3630
3631// ApplicationGatewaysDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
3632// operation.
3633type ApplicationGatewaysDeleteFuture struct {
3634	azure.Future
3635}
3636
3637// Result returns the result of the asynchronous operation.
3638// If the operation has not completed it will return an error.
3639func (future *ApplicationGatewaysDeleteFuture) Result(client ApplicationGatewaysClient) (ar autorest.Response, err error) {
3640	var done bool
3641	done, err = future.Done(client)
3642	if err != nil {
3643		err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysDeleteFuture", "Result", future.Response(), "Polling failure")
3644		return
3645	}
3646	if !done {
3647		err = azure.NewAsyncOpIncompleteError("network.ApplicationGatewaysDeleteFuture")
3648		return
3649	}
3650	ar.Response = future.Response()
3651	return
3652}
3653
3654// ApplicationGatewaySku SKU of an application gateway
3655type ApplicationGatewaySku struct {
3656	// Name - Name of an application gateway SKU. Possible values include: 'StandardSmall', 'StandardMedium', 'StandardLarge', 'WAFMedium', 'WAFLarge', 'StandardV2', 'WAFV2'
3657	Name ApplicationGatewaySkuName `json:"name,omitempty"`
3658	// Tier - Tier of an application gateway. Possible values include: 'ApplicationGatewayTierStandard', 'ApplicationGatewayTierWAF', 'ApplicationGatewayTierStandardV2', 'ApplicationGatewayTierWAFV2'
3659	Tier ApplicationGatewayTier `json:"tier,omitempty"`
3660	// Capacity - Capacity (instance count) of an application gateway.
3661	Capacity *int32 `json:"capacity,omitempty"`
3662}
3663
3664// ApplicationGatewaySslCertificate SSL certificates of an application gateway.
3665type ApplicationGatewaySslCertificate struct {
3666	*ApplicationGatewaySslCertificatePropertiesFormat `json:"properties,omitempty"`
3667	// Name - Name of the SSL certificate that is unique within an Application Gateway.
3668	Name *string `json:"name,omitempty"`
3669	// Etag - A unique read-only string that changes whenever the resource is updated.
3670	Etag *string `json:"etag,omitempty"`
3671	// Type - Type of the resource.
3672	Type *string `json:"type,omitempty"`
3673	// ID - Resource ID.
3674	ID *string `json:"id,omitempty"`
3675}
3676
3677// MarshalJSON is the custom marshaler for ApplicationGatewaySslCertificate.
3678func (agsc ApplicationGatewaySslCertificate) MarshalJSON() ([]byte, error) {
3679	objectMap := make(map[string]interface{})
3680	if agsc.ApplicationGatewaySslCertificatePropertiesFormat != nil {
3681		objectMap["properties"] = agsc.ApplicationGatewaySslCertificatePropertiesFormat
3682	}
3683	if agsc.Name != nil {
3684		objectMap["name"] = agsc.Name
3685	}
3686	if agsc.Etag != nil {
3687		objectMap["etag"] = agsc.Etag
3688	}
3689	if agsc.Type != nil {
3690		objectMap["type"] = agsc.Type
3691	}
3692	if agsc.ID != nil {
3693		objectMap["id"] = agsc.ID
3694	}
3695	return json.Marshal(objectMap)
3696}
3697
3698// UnmarshalJSON is the custom unmarshaler for ApplicationGatewaySslCertificate struct.
3699func (agsc *ApplicationGatewaySslCertificate) UnmarshalJSON(body []byte) error {
3700	var m map[string]*json.RawMessage
3701	err := json.Unmarshal(body, &m)
3702	if err != nil {
3703		return err
3704	}
3705	for k, v := range m {
3706		switch k {
3707		case "properties":
3708			if v != nil {
3709				var applicationGatewaySslCertificatePropertiesFormat ApplicationGatewaySslCertificatePropertiesFormat
3710				err = json.Unmarshal(*v, &applicationGatewaySslCertificatePropertiesFormat)
3711				if err != nil {
3712					return err
3713				}
3714				agsc.ApplicationGatewaySslCertificatePropertiesFormat = &applicationGatewaySslCertificatePropertiesFormat
3715			}
3716		case "name":
3717			if v != nil {
3718				var name string
3719				err = json.Unmarshal(*v, &name)
3720				if err != nil {
3721					return err
3722				}
3723				agsc.Name = &name
3724			}
3725		case "etag":
3726			if v != nil {
3727				var etag string
3728				err = json.Unmarshal(*v, &etag)
3729				if err != nil {
3730					return err
3731				}
3732				agsc.Etag = &etag
3733			}
3734		case "type":
3735			if v != nil {
3736				var typeVar string
3737				err = json.Unmarshal(*v, &typeVar)
3738				if err != nil {
3739					return err
3740				}
3741				agsc.Type = &typeVar
3742			}
3743		case "id":
3744			if v != nil {
3745				var ID string
3746				err = json.Unmarshal(*v, &ID)
3747				if err != nil {
3748					return err
3749				}
3750				agsc.ID = &ID
3751			}
3752		}
3753	}
3754
3755	return nil
3756}
3757
3758// ApplicationGatewaySslCertificatePropertiesFormat properties of SSL certificates of an application gateway.
3759type ApplicationGatewaySslCertificatePropertiesFormat struct {
3760	// Data - Base-64 encoded pfx certificate. Only applicable in PUT Request.
3761	Data *string `json:"data,omitempty"`
3762	// Password - Password for the pfx file specified in data. Only applicable in PUT request.
3763	Password *string `json:"password,omitempty"`
3764	// PublicCertData - Base-64 encoded Public cert data corresponding to pfx specified in data. Only applicable in GET request.
3765	PublicCertData *string `json:"publicCertData,omitempty"`
3766	// ProvisioningState - Provisioning state of the SSL certificate resource Possible values are: 'Updating', 'Deleting', and 'Failed'.
3767	ProvisioningState *string `json:"provisioningState,omitempty"`
3768}
3769
3770// ApplicationGatewaySslPolicy application Gateway Ssl policy.
3771type ApplicationGatewaySslPolicy struct {
3772	// DisabledSslProtocols - Ssl protocols to be disabled on application gateway.
3773	DisabledSslProtocols *[]ApplicationGatewaySslProtocol `json:"disabledSslProtocols,omitempty"`
3774	// PolicyType - Type of Ssl Policy. Possible values include: 'Predefined', 'Custom'
3775	PolicyType ApplicationGatewaySslPolicyType `json:"policyType,omitempty"`
3776	// PolicyName - Name of Ssl predefined policy. Possible values include: 'AppGwSslPolicy20150501', 'AppGwSslPolicy20170401', 'AppGwSslPolicy20170401S'
3777	PolicyName ApplicationGatewaySslPolicyName `json:"policyName,omitempty"`
3778	// CipherSuites - Ssl cipher suites to be enabled in the specified order to application gateway.
3779	CipherSuites *[]ApplicationGatewaySslCipherSuite `json:"cipherSuites,omitempty"`
3780	// MinProtocolVersion - Minimum version of Ssl protocol to be supported on application gateway. Possible values include: 'TLSv10', 'TLSv11', 'TLSv12'
3781	MinProtocolVersion ApplicationGatewaySslProtocol `json:"minProtocolVersion,omitempty"`
3782}
3783
3784// ApplicationGatewaySslPredefinedPolicy an Ssl predefined policy
3785type ApplicationGatewaySslPredefinedPolicy struct {
3786	autorest.Response `json:"-"`
3787	// Name - Name of the Ssl predefined policy.
3788	Name                                                   *string `json:"name,omitempty"`
3789	*ApplicationGatewaySslPredefinedPolicyPropertiesFormat `json:"properties,omitempty"`
3790	// ID - Resource ID.
3791	ID *string `json:"id,omitempty"`
3792}
3793
3794// MarshalJSON is the custom marshaler for ApplicationGatewaySslPredefinedPolicy.
3795func (agspp ApplicationGatewaySslPredefinedPolicy) MarshalJSON() ([]byte, error) {
3796	objectMap := make(map[string]interface{})
3797	if agspp.Name != nil {
3798		objectMap["name"] = agspp.Name
3799	}
3800	if agspp.ApplicationGatewaySslPredefinedPolicyPropertiesFormat != nil {
3801		objectMap["properties"] = agspp.ApplicationGatewaySslPredefinedPolicyPropertiesFormat
3802	}
3803	if agspp.ID != nil {
3804		objectMap["id"] = agspp.ID
3805	}
3806	return json.Marshal(objectMap)
3807}
3808
3809// UnmarshalJSON is the custom unmarshaler for ApplicationGatewaySslPredefinedPolicy struct.
3810func (agspp *ApplicationGatewaySslPredefinedPolicy) UnmarshalJSON(body []byte) error {
3811	var m map[string]*json.RawMessage
3812	err := json.Unmarshal(body, &m)
3813	if err != nil {
3814		return err
3815	}
3816	for k, v := range m {
3817		switch k {
3818		case "name":
3819			if v != nil {
3820				var name string
3821				err = json.Unmarshal(*v, &name)
3822				if err != nil {
3823					return err
3824				}
3825				agspp.Name = &name
3826			}
3827		case "properties":
3828			if v != nil {
3829				var applicationGatewaySslPredefinedPolicyPropertiesFormat ApplicationGatewaySslPredefinedPolicyPropertiesFormat
3830				err = json.Unmarshal(*v, &applicationGatewaySslPredefinedPolicyPropertiesFormat)
3831				if err != nil {
3832					return err
3833				}
3834				agspp.ApplicationGatewaySslPredefinedPolicyPropertiesFormat = &applicationGatewaySslPredefinedPolicyPropertiesFormat
3835			}
3836		case "id":
3837			if v != nil {
3838				var ID string
3839				err = json.Unmarshal(*v, &ID)
3840				if err != nil {
3841					return err
3842				}
3843				agspp.ID = &ID
3844			}
3845		}
3846	}
3847
3848	return nil
3849}
3850
3851// ApplicationGatewaySslPredefinedPolicyPropertiesFormat properties of ApplicationGatewaySslPredefinedPolicy
3852type ApplicationGatewaySslPredefinedPolicyPropertiesFormat struct {
3853	// CipherSuites - Ssl cipher suites to be enabled in the specified order for application gateway.
3854	CipherSuites *[]ApplicationGatewaySslCipherSuite `json:"cipherSuites,omitempty"`
3855	// MinProtocolVersion - Minimum version of Ssl protocol to be supported on application gateway. Possible values include: 'TLSv10', 'TLSv11', 'TLSv12'
3856	MinProtocolVersion ApplicationGatewaySslProtocol `json:"minProtocolVersion,omitempty"`
3857}
3858
3859// ApplicationGatewaysStartFuture an abstraction for monitoring and retrieving the results of a long-running
3860// operation.
3861type ApplicationGatewaysStartFuture struct {
3862	azure.Future
3863}
3864
3865// Result returns the result of the asynchronous operation.
3866// If the operation has not completed it will return an error.
3867func (future *ApplicationGatewaysStartFuture) Result(client ApplicationGatewaysClient) (ar autorest.Response, err error) {
3868	var done bool
3869	done, err = future.Done(client)
3870	if err != nil {
3871		err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysStartFuture", "Result", future.Response(), "Polling failure")
3872		return
3873	}
3874	if !done {
3875		err = azure.NewAsyncOpIncompleteError("network.ApplicationGatewaysStartFuture")
3876		return
3877	}
3878	ar.Response = future.Response()
3879	return
3880}
3881
3882// ApplicationGatewaysStopFuture an abstraction for monitoring and retrieving the results of a long-running
3883// operation.
3884type ApplicationGatewaysStopFuture struct {
3885	azure.Future
3886}
3887
3888// Result returns the result of the asynchronous operation.
3889// If the operation has not completed it will return an error.
3890func (future *ApplicationGatewaysStopFuture) Result(client ApplicationGatewaysClient) (ar autorest.Response, err error) {
3891	var done bool
3892	done, err = future.Done(client)
3893	if err != nil {
3894		err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysStopFuture", "Result", future.Response(), "Polling failure")
3895		return
3896	}
3897	if !done {
3898		err = azure.NewAsyncOpIncompleteError("network.ApplicationGatewaysStopFuture")
3899		return
3900	}
3901	ar.Response = future.Response()
3902	return
3903}
3904
3905// ApplicationGatewaysUpdateTagsFuture an abstraction for monitoring and retrieving the results of a long-running
3906// operation.
3907type ApplicationGatewaysUpdateTagsFuture struct {
3908	azure.Future
3909}
3910
3911// Result returns the result of the asynchronous operation.
3912// If the operation has not completed it will return an error.
3913func (future *ApplicationGatewaysUpdateTagsFuture) Result(client ApplicationGatewaysClient) (ag ApplicationGateway, err error) {
3914	var done bool
3915	done, err = future.Done(client)
3916	if err != nil {
3917		err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysUpdateTagsFuture", "Result", future.Response(), "Polling failure")
3918		return
3919	}
3920	if !done {
3921		err = azure.NewAsyncOpIncompleteError("network.ApplicationGatewaysUpdateTagsFuture")
3922		return
3923	}
3924	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
3925	if ag.Response.Response, err = future.GetResult(sender); err == nil && ag.Response.Response.StatusCode != http.StatusNoContent {
3926		ag, err = client.UpdateTagsResponder(ag.Response.Response)
3927		if err != nil {
3928			err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysUpdateTagsFuture", "Result", ag.Response.Response, "Failure responding to request")
3929		}
3930	}
3931	return
3932}
3933
3934// ApplicationGatewayTrustedRootCertificate trusted Root certificates of an application gateway.
3935type ApplicationGatewayTrustedRootCertificate struct {
3936	*ApplicationGatewayTrustedRootCertificatePropertiesFormat `json:"properties,omitempty"`
3937	// Name - Name of the trusted root certificate that is unique within an Application Gateway.
3938	Name *string `json:"name,omitempty"`
3939	// Etag - A unique read-only string that changes whenever the resource is updated.
3940	Etag *string `json:"etag,omitempty"`
3941	// Type - Type of the resource.
3942	Type *string `json:"type,omitempty"`
3943	// ID - Resource ID.
3944	ID *string `json:"id,omitempty"`
3945}
3946
3947// MarshalJSON is the custom marshaler for ApplicationGatewayTrustedRootCertificate.
3948func (agtrc ApplicationGatewayTrustedRootCertificate) MarshalJSON() ([]byte, error) {
3949	objectMap := make(map[string]interface{})
3950	if agtrc.ApplicationGatewayTrustedRootCertificatePropertiesFormat != nil {
3951		objectMap["properties"] = agtrc.ApplicationGatewayTrustedRootCertificatePropertiesFormat
3952	}
3953	if agtrc.Name != nil {
3954		objectMap["name"] = agtrc.Name
3955	}
3956	if agtrc.Etag != nil {
3957		objectMap["etag"] = agtrc.Etag
3958	}
3959	if agtrc.Type != nil {
3960		objectMap["type"] = agtrc.Type
3961	}
3962	if agtrc.ID != nil {
3963		objectMap["id"] = agtrc.ID
3964	}
3965	return json.Marshal(objectMap)
3966}
3967
3968// UnmarshalJSON is the custom unmarshaler for ApplicationGatewayTrustedRootCertificate struct.
3969func (agtrc *ApplicationGatewayTrustedRootCertificate) UnmarshalJSON(body []byte) error {
3970	var m map[string]*json.RawMessage
3971	err := json.Unmarshal(body, &m)
3972	if err != nil {
3973		return err
3974	}
3975	for k, v := range m {
3976		switch k {
3977		case "properties":
3978			if v != nil {
3979				var applicationGatewayTrustedRootCertificatePropertiesFormat ApplicationGatewayTrustedRootCertificatePropertiesFormat
3980				err = json.Unmarshal(*v, &applicationGatewayTrustedRootCertificatePropertiesFormat)
3981				if err != nil {
3982					return err
3983				}
3984				agtrc.ApplicationGatewayTrustedRootCertificatePropertiesFormat = &applicationGatewayTrustedRootCertificatePropertiesFormat
3985			}
3986		case "name":
3987			if v != nil {
3988				var name string
3989				err = json.Unmarshal(*v, &name)
3990				if err != nil {
3991					return err
3992				}
3993				agtrc.Name = &name
3994			}
3995		case "etag":
3996			if v != nil {
3997				var etag string
3998				err = json.Unmarshal(*v, &etag)
3999				if err != nil {
4000					return err
4001				}
4002				agtrc.Etag = &etag
4003			}
4004		case "type":
4005			if v != nil {
4006				var typeVar string
4007				err = json.Unmarshal(*v, &typeVar)
4008				if err != nil {
4009					return err
4010				}
4011				agtrc.Type = &typeVar
4012			}
4013		case "id":
4014			if v != nil {
4015				var ID string
4016				err = json.Unmarshal(*v, &ID)
4017				if err != nil {
4018					return err
4019				}
4020				agtrc.ID = &ID
4021			}
4022		}
4023	}
4024
4025	return nil
4026}
4027
4028// ApplicationGatewayTrustedRootCertificatePropertiesFormat trusted Root certificates properties of an application
4029// gateway.
4030type ApplicationGatewayTrustedRootCertificatePropertiesFormat struct {
4031	// Data - Certificate public data.
4032	Data *string `json:"data,omitempty"`
4033	// KeyvaultSecretID - KeyVault Secret Id for certificate.
4034	KeyvaultSecretID *string `json:"keyvaultSecretId,omitempty"`
4035	// ProvisioningState - Provisioning state of the trusted root certificate resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
4036	ProvisioningState *string `json:"provisioningState,omitempty"`
4037}
4038
4039// ApplicationGatewayURLPathMap urlPathMaps give a url path to the backend mapping information for
4040// PathBasedRouting.
4041type ApplicationGatewayURLPathMap struct {
4042	*ApplicationGatewayURLPathMapPropertiesFormat `json:"properties,omitempty"`
4043	// Name - Name of the URL path map that is unique within an Application Gateway.
4044	Name *string `json:"name,omitempty"`
4045	// Etag - A unique read-only string that changes whenever the resource is updated.
4046	Etag *string `json:"etag,omitempty"`
4047	// Type - Type of the resource.
4048	Type *string `json:"type,omitempty"`
4049	// ID - Resource ID.
4050	ID *string `json:"id,omitempty"`
4051}
4052
4053// MarshalJSON is the custom marshaler for ApplicationGatewayURLPathMap.
4054func (agupm ApplicationGatewayURLPathMap) MarshalJSON() ([]byte, error) {
4055	objectMap := make(map[string]interface{})
4056	if agupm.ApplicationGatewayURLPathMapPropertiesFormat != nil {
4057		objectMap["properties"] = agupm.ApplicationGatewayURLPathMapPropertiesFormat
4058	}
4059	if agupm.Name != nil {
4060		objectMap["name"] = agupm.Name
4061	}
4062	if agupm.Etag != nil {
4063		objectMap["etag"] = agupm.Etag
4064	}
4065	if agupm.Type != nil {
4066		objectMap["type"] = agupm.Type
4067	}
4068	if agupm.ID != nil {
4069		objectMap["id"] = agupm.ID
4070	}
4071	return json.Marshal(objectMap)
4072}
4073
4074// UnmarshalJSON is the custom unmarshaler for ApplicationGatewayURLPathMap struct.
4075func (agupm *ApplicationGatewayURLPathMap) UnmarshalJSON(body []byte) error {
4076	var m map[string]*json.RawMessage
4077	err := json.Unmarshal(body, &m)
4078	if err != nil {
4079		return err
4080	}
4081	for k, v := range m {
4082		switch k {
4083		case "properties":
4084			if v != nil {
4085				var applicationGatewayURLPathMapPropertiesFormat ApplicationGatewayURLPathMapPropertiesFormat
4086				err = json.Unmarshal(*v, &applicationGatewayURLPathMapPropertiesFormat)
4087				if err != nil {
4088					return err
4089				}
4090				agupm.ApplicationGatewayURLPathMapPropertiesFormat = &applicationGatewayURLPathMapPropertiesFormat
4091			}
4092		case "name":
4093			if v != nil {
4094				var name string
4095				err = json.Unmarshal(*v, &name)
4096				if err != nil {
4097					return err
4098				}
4099				agupm.Name = &name
4100			}
4101		case "etag":
4102			if v != nil {
4103				var etag string
4104				err = json.Unmarshal(*v, &etag)
4105				if err != nil {
4106					return err
4107				}
4108				agupm.Etag = &etag
4109			}
4110		case "type":
4111			if v != nil {
4112				var typeVar string
4113				err = json.Unmarshal(*v, &typeVar)
4114				if err != nil {
4115					return err
4116				}
4117				agupm.Type = &typeVar
4118			}
4119		case "id":
4120			if v != nil {
4121				var ID string
4122				err = json.Unmarshal(*v, &ID)
4123				if err != nil {
4124					return err
4125				}
4126				agupm.ID = &ID
4127			}
4128		}
4129	}
4130
4131	return nil
4132}
4133
4134// ApplicationGatewayURLPathMapPropertiesFormat properties of UrlPathMap of the application gateway.
4135type ApplicationGatewayURLPathMapPropertiesFormat struct {
4136	// DefaultBackendAddressPool - Default backend address pool resource of URL path map.
4137	DefaultBackendAddressPool *SubResource `json:"defaultBackendAddressPool,omitempty"`
4138	// DefaultBackendHTTPSettings - Default backend http settings resource of URL path map.
4139	DefaultBackendHTTPSettings *SubResource `json:"defaultBackendHttpSettings,omitempty"`
4140	// DefaultRedirectConfiguration - Default redirect configuration resource of URL path map.
4141	DefaultRedirectConfiguration *SubResource `json:"defaultRedirectConfiguration,omitempty"`
4142	// PathRules - Path rule of URL path map resource.
4143	PathRules *[]ApplicationGatewayPathRule `json:"pathRules,omitempty"`
4144	// ProvisioningState - Provisioning state of the backend http settings resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
4145	ProvisioningState *string `json:"provisioningState,omitempty"`
4146}
4147
4148// ApplicationGatewayWebApplicationFirewallConfiguration application gateway web application firewall
4149// configuration.
4150type ApplicationGatewayWebApplicationFirewallConfiguration struct {
4151	// Enabled - Whether the web application firewall is enabled or not.
4152	Enabled *bool `json:"enabled,omitempty"`
4153	// FirewallMode - Web application firewall mode. Possible values include: 'Detection', 'Prevention'
4154	FirewallMode ApplicationGatewayFirewallMode `json:"firewallMode,omitempty"`
4155	// RuleSetType - The type of the web application firewall rule set. Possible values are: 'OWASP'.
4156	RuleSetType *string `json:"ruleSetType,omitempty"`
4157	// RuleSetVersion - The version of the rule set type.
4158	RuleSetVersion *string `json:"ruleSetVersion,omitempty"`
4159	// DisabledRuleGroups - The disabled rule groups.
4160	DisabledRuleGroups *[]ApplicationGatewayFirewallDisabledRuleGroup `json:"disabledRuleGroups,omitempty"`
4161	// RequestBodyCheck - Whether allow WAF to check request Body.
4162	RequestBodyCheck *bool `json:"requestBodyCheck,omitempty"`
4163	// MaxRequestBodySize - Maxium request body size for WAF.
4164	MaxRequestBodySize *int32 `json:"maxRequestBodySize,omitempty"`
4165}
4166
4167// ApplicationSecurityGroup an application security group in a resource group.
4168type ApplicationSecurityGroup struct {
4169	autorest.Response `json:"-"`
4170	// ApplicationSecurityGroupPropertiesFormat - Properties of the application security group.
4171	*ApplicationSecurityGroupPropertiesFormat `json:"properties,omitempty"`
4172	// Etag - A unique read-only string that changes whenever the resource is updated.
4173	Etag *string `json:"etag,omitempty"`
4174	// ID - Resource ID.
4175	ID *string `json:"id,omitempty"`
4176	// Name - Resource name.
4177	Name *string `json:"name,omitempty"`
4178	// Type - Resource type.
4179	Type *string `json:"type,omitempty"`
4180	// Location - Resource location.
4181	Location *string `json:"location,omitempty"`
4182	// Tags - Resource tags.
4183	Tags map[string]*string `json:"tags"`
4184}
4185
4186// MarshalJSON is the custom marshaler for ApplicationSecurityGroup.
4187func (asg ApplicationSecurityGroup) MarshalJSON() ([]byte, error) {
4188	objectMap := make(map[string]interface{})
4189	if asg.ApplicationSecurityGroupPropertiesFormat != nil {
4190		objectMap["properties"] = asg.ApplicationSecurityGroupPropertiesFormat
4191	}
4192	if asg.Etag != nil {
4193		objectMap["etag"] = asg.Etag
4194	}
4195	if asg.ID != nil {
4196		objectMap["id"] = asg.ID
4197	}
4198	if asg.Name != nil {
4199		objectMap["name"] = asg.Name
4200	}
4201	if asg.Type != nil {
4202		objectMap["type"] = asg.Type
4203	}
4204	if asg.Location != nil {
4205		objectMap["location"] = asg.Location
4206	}
4207	if asg.Tags != nil {
4208		objectMap["tags"] = asg.Tags
4209	}
4210	return json.Marshal(objectMap)
4211}
4212
4213// UnmarshalJSON is the custom unmarshaler for ApplicationSecurityGroup struct.
4214func (asg *ApplicationSecurityGroup) UnmarshalJSON(body []byte) error {
4215	var m map[string]*json.RawMessage
4216	err := json.Unmarshal(body, &m)
4217	if err != nil {
4218		return err
4219	}
4220	for k, v := range m {
4221		switch k {
4222		case "properties":
4223			if v != nil {
4224				var applicationSecurityGroupPropertiesFormat ApplicationSecurityGroupPropertiesFormat
4225				err = json.Unmarshal(*v, &applicationSecurityGroupPropertiesFormat)
4226				if err != nil {
4227					return err
4228				}
4229				asg.ApplicationSecurityGroupPropertiesFormat = &applicationSecurityGroupPropertiesFormat
4230			}
4231		case "etag":
4232			if v != nil {
4233				var etag string
4234				err = json.Unmarshal(*v, &etag)
4235				if err != nil {
4236					return err
4237				}
4238				asg.Etag = &etag
4239			}
4240		case "id":
4241			if v != nil {
4242				var ID string
4243				err = json.Unmarshal(*v, &ID)
4244				if err != nil {
4245					return err
4246				}
4247				asg.ID = &ID
4248			}
4249		case "name":
4250			if v != nil {
4251				var name string
4252				err = json.Unmarshal(*v, &name)
4253				if err != nil {
4254					return err
4255				}
4256				asg.Name = &name
4257			}
4258		case "type":
4259			if v != nil {
4260				var typeVar string
4261				err = json.Unmarshal(*v, &typeVar)
4262				if err != nil {
4263					return err
4264				}
4265				asg.Type = &typeVar
4266			}
4267		case "location":
4268			if v != nil {
4269				var location string
4270				err = json.Unmarshal(*v, &location)
4271				if err != nil {
4272					return err
4273				}
4274				asg.Location = &location
4275			}
4276		case "tags":
4277			if v != nil {
4278				var tags map[string]*string
4279				err = json.Unmarshal(*v, &tags)
4280				if err != nil {
4281					return err
4282				}
4283				asg.Tags = tags
4284			}
4285		}
4286	}
4287
4288	return nil
4289}
4290
4291// ApplicationSecurityGroupListResult a list of application security groups.
4292type ApplicationSecurityGroupListResult struct {
4293	autorest.Response `json:"-"`
4294	// Value - A list of application security groups.
4295	Value *[]ApplicationSecurityGroup `json:"value,omitempty"`
4296	// NextLink - The URL to get the next set of results.
4297	NextLink *string `json:"nextLink,omitempty"`
4298}
4299
4300// ApplicationSecurityGroupListResultIterator provides access to a complete listing of ApplicationSecurityGroup
4301// values.
4302type ApplicationSecurityGroupListResultIterator struct {
4303	i    int
4304	page ApplicationSecurityGroupListResultPage
4305}
4306
4307// Next advances to the next value.  If there was an error making
4308// the request the iterator does not advance and the error is returned.
4309func (iter *ApplicationSecurityGroupListResultIterator) Next() error {
4310	iter.i++
4311	if iter.i < len(iter.page.Values()) {
4312		return nil
4313	}
4314	err := iter.page.Next()
4315	if err != nil {
4316		iter.i--
4317		return err
4318	}
4319	iter.i = 0
4320	return nil
4321}
4322
4323// NotDone returns true if the enumeration should be started or is not yet complete.
4324func (iter ApplicationSecurityGroupListResultIterator) NotDone() bool {
4325	return iter.page.NotDone() && iter.i < len(iter.page.Values())
4326}
4327
4328// Response returns the raw server response from the last page request.
4329func (iter ApplicationSecurityGroupListResultIterator) Response() ApplicationSecurityGroupListResult {
4330	return iter.page.Response()
4331}
4332
4333// Value returns the current value or a zero-initialized value if the
4334// iterator has advanced beyond the end of the collection.
4335func (iter ApplicationSecurityGroupListResultIterator) Value() ApplicationSecurityGroup {
4336	if !iter.page.NotDone() {
4337		return ApplicationSecurityGroup{}
4338	}
4339	return iter.page.Values()[iter.i]
4340}
4341
4342// IsEmpty returns true if the ListResult contains no values.
4343func (asglr ApplicationSecurityGroupListResult) IsEmpty() bool {
4344	return asglr.Value == nil || len(*asglr.Value) == 0
4345}
4346
4347// applicationSecurityGroupListResultPreparer prepares a request to retrieve the next set of results.
4348// It returns nil if no more results exist.
4349func (asglr ApplicationSecurityGroupListResult) applicationSecurityGroupListResultPreparer() (*http.Request, error) {
4350	if asglr.NextLink == nil || len(to.String(asglr.NextLink)) < 1 {
4351		return nil, nil
4352	}
4353	return autorest.Prepare(&http.Request{},
4354		autorest.AsJSON(),
4355		autorest.AsGet(),
4356		autorest.WithBaseURL(to.String(asglr.NextLink)))
4357}
4358
4359// ApplicationSecurityGroupListResultPage contains a page of ApplicationSecurityGroup values.
4360type ApplicationSecurityGroupListResultPage struct {
4361	fn    func(ApplicationSecurityGroupListResult) (ApplicationSecurityGroupListResult, error)
4362	asglr ApplicationSecurityGroupListResult
4363}
4364
4365// Next advances to the next page of values.  If there was an error making
4366// the request the page does not advance and the error is returned.
4367func (page *ApplicationSecurityGroupListResultPage) Next() error {
4368	next, err := page.fn(page.asglr)
4369	if err != nil {
4370		return err
4371	}
4372	page.asglr = next
4373	return nil
4374}
4375
4376// NotDone returns true if the page enumeration should be started or is not yet complete.
4377func (page ApplicationSecurityGroupListResultPage) NotDone() bool {
4378	return !page.asglr.IsEmpty()
4379}
4380
4381// Response returns the raw server response from the last page request.
4382func (page ApplicationSecurityGroupListResultPage) Response() ApplicationSecurityGroupListResult {
4383	return page.asglr
4384}
4385
4386// Values returns the slice of values for the current page or nil if there are no values.
4387func (page ApplicationSecurityGroupListResultPage) Values() []ApplicationSecurityGroup {
4388	if page.asglr.IsEmpty() {
4389		return nil
4390	}
4391	return *page.asglr.Value
4392}
4393
4394// ApplicationSecurityGroupPropertiesFormat application security group properties.
4395type ApplicationSecurityGroupPropertiesFormat struct {
4396	// ResourceGUID - The resource GUID property of the application security group resource. It uniquely identifies a resource, even if the user changes its name or migrate the resource across subscriptions or resource groups.
4397	ResourceGUID *string `json:"resourceGuid,omitempty"`
4398	// ProvisioningState - The provisioning state of the application security group resource. Possible values are: 'Succeeded', 'Updating', 'Deleting', and 'Failed'.
4399	ProvisioningState *string `json:"provisioningState,omitempty"`
4400}
4401
4402// ApplicationSecurityGroupsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
4403// long-running operation.
4404type ApplicationSecurityGroupsCreateOrUpdateFuture struct {
4405	azure.Future
4406}
4407
4408// Result returns the result of the asynchronous operation.
4409// If the operation has not completed it will return an error.
4410func (future *ApplicationSecurityGroupsCreateOrUpdateFuture) Result(client ApplicationSecurityGroupsClient) (asg ApplicationSecurityGroup, err error) {
4411	var done bool
4412	done, err = future.Done(client)
4413	if err != nil {
4414		err = autorest.NewErrorWithError(err, "network.ApplicationSecurityGroupsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
4415		return
4416	}
4417	if !done {
4418		err = azure.NewAsyncOpIncompleteError("network.ApplicationSecurityGroupsCreateOrUpdateFuture")
4419		return
4420	}
4421	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
4422	if asg.Response.Response, err = future.GetResult(sender); err == nil && asg.Response.Response.StatusCode != http.StatusNoContent {
4423		asg, err = client.CreateOrUpdateResponder(asg.Response.Response)
4424		if err != nil {
4425			err = autorest.NewErrorWithError(err, "network.ApplicationSecurityGroupsCreateOrUpdateFuture", "Result", asg.Response.Response, "Failure responding to request")
4426		}
4427	}
4428	return
4429}
4430
4431// ApplicationSecurityGroupsDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
4432// operation.
4433type ApplicationSecurityGroupsDeleteFuture struct {
4434	azure.Future
4435}
4436
4437// Result returns the result of the asynchronous operation.
4438// If the operation has not completed it will return an error.
4439func (future *ApplicationSecurityGroupsDeleteFuture) Result(client ApplicationSecurityGroupsClient) (ar autorest.Response, err error) {
4440	var done bool
4441	done, err = future.Done(client)
4442	if err != nil {
4443		err = autorest.NewErrorWithError(err, "network.ApplicationSecurityGroupsDeleteFuture", "Result", future.Response(), "Polling failure")
4444		return
4445	}
4446	if !done {
4447		err = azure.NewAsyncOpIncompleteError("network.ApplicationSecurityGroupsDeleteFuture")
4448		return
4449	}
4450	ar.Response = future.Response()
4451	return
4452}
4453
4454// AuthorizationListResult response for ListAuthorizations API service call retrieves all authorizations that
4455// belongs to an ExpressRouteCircuit.
4456type AuthorizationListResult struct {
4457	autorest.Response `json:"-"`
4458	// Value - The authorizations in an ExpressRoute Circuit.
4459	Value *[]ExpressRouteCircuitAuthorization `json:"value,omitempty"`
4460	// NextLink - The URL to get the next set of results.
4461	NextLink *string `json:"nextLink,omitempty"`
4462}
4463
4464// AuthorizationListResultIterator provides access to a complete listing of ExpressRouteCircuitAuthorization
4465// values.
4466type AuthorizationListResultIterator struct {
4467	i    int
4468	page AuthorizationListResultPage
4469}
4470
4471// Next advances to the next value.  If there was an error making
4472// the request the iterator does not advance and the error is returned.
4473func (iter *AuthorizationListResultIterator) Next() error {
4474	iter.i++
4475	if iter.i < len(iter.page.Values()) {
4476		return nil
4477	}
4478	err := iter.page.Next()
4479	if err != nil {
4480		iter.i--
4481		return err
4482	}
4483	iter.i = 0
4484	return nil
4485}
4486
4487// NotDone returns true if the enumeration should be started or is not yet complete.
4488func (iter AuthorizationListResultIterator) NotDone() bool {
4489	return iter.page.NotDone() && iter.i < len(iter.page.Values())
4490}
4491
4492// Response returns the raw server response from the last page request.
4493func (iter AuthorizationListResultIterator) Response() AuthorizationListResult {
4494	return iter.page.Response()
4495}
4496
4497// Value returns the current value or a zero-initialized value if the
4498// iterator has advanced beyond the end of the collection.
4499func (iter AuthorizationListResultIterator) Value() ExpressRouteCircuitAuthorization {
4500	if !iter.page.NotDone() {
4501		return ExpressRouteCircuitAuthorization{}
4502	}
4503	return iter.page.Values()[iter.i]
4504}
4505
4506// IsEmpty returns true if the ListResult contains no values.
4507func (alr AuthorizationListResult) IsEmpty() bool {
4508	return alr.Value == nil || len(*alr.Value) == 0
4509}
4510
4511// authorizationListResultPreparer prepares a request to retrieve the next set of results.
4512// It returns nil if no more results exist.
4513func (alr AuthorizationListResult) authorizationListResultPreparer() (*http.Request, error) {
4514	if alr.NextLink == nil || len(to.String(alr.NextLink)) < 1 {
4515		return nil, nil
4516	}
4517	return autorest.Prepare(&http.Request{},
4518		autorest.AsJSON(),
4519		autorest.AsGet(),
4520		autorest.WithBaseURL(to.String(alr.NextLink)))
4521}
4522
4523// AuthorizationListResultPage contains a page of ExpressRouteCircuitAuthorization values.
4524type AuthorizationListResultPage struct {
4525	fn  func(AuthorizationListResult) (AuthorizationListResult, error)
4526	alr AuthorizationListResult
4527}
4528
4529// Next advances to the next page of values.  If there was an error making
4530// the request the page does not advance and the error is returned.
4531func (page *AuthorizationListResultPage) Next() error {
4532	next, err := page.fn(page.alr)
4533	if err != nil {
4534		return err
4535	}
4536	page.alr = next
4537	return nil
4538}
4539
4540// NotDone returns true if the page enumeration should be started or is not yet complete.
4541func (page AuthorizationListResultPage) NotDone() bool {
4542	return !page.alr.IsEmpty()
4543}
4544
4545// Response returns the raw server response from the last page request.
4546func (page AuthorizationListResultPage) Response() AuthorizationListResult {
4547	return page.alr
4548}
4549
4550// Values returns the slice of values for the current page or nil if there are no values.
4551func (page AuthorizationListResultPage) Values() []ExpressRouteCircuitAuthorization {
4552	if page.alr.IsEmpty() {
4553		return nil
4554	}
4555	return *page.alr.Value
4556}
4557
4558// AuthorizationPropertiesFormat ...
4559type AuthorizationPropertiesFormat struct {
4560	// AuthorizationKey - The authorization key.
4561	AuthorizationKey *string `json:"authorizationKey,omitempty"`
4562	// AuthorizationUseStatus - AuthorizationUseStatus. Possible values are: 'Available' and 'InUse'. Possible values include: 'Available', 'InUse'
4563	AuthorizationUseStatus AuthorizationUseStatus `json:"authorizationUseStatus,omitempty"`
4564	// ProvisioningState - Gets the provisioning state of the public IP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
4565	ProvisioningState *string `json:"provisioningState,omitempty"`
4566}
4567
4568// Availability availability of the metric.
4569type Availability struct {
4570	// TimeGrain - The time grain of the availability.
4571	TimeGrain *string `json:"timeGrain,omitempty"`
4572	// Retention - The retention of the availability.
4573	Retention *string `json:"retention,omitempty"`
4574	// BlobDuration - Duration of the availability blob.
4575	BlobDuration *string `json:"blobDuration,omitempty"`
4576}
4577
4578// AvailableDelegation the serviceName of an AvailableDelegation indicates a possible delegation for a subnet.
4579type AvailableDelegation struct {
4580	// Name - The name of the AvailableDelegation resource.
4581	Name *string `json:"name,omitempty"`
4582	// ID - A unique identifier of the AvailableDelegation resource.
4583	ID *string `json:"id,omitempty"`
4584	// Type - Resource type.
4585	Type *string `json:"type,omitempty"`
4586	// ServiceName - The name of the service and resource
4587	ServiceName *string `json:"serviceName,omitempty"`
4588	// Actions - Describes the actions permitted to the service upon delegation
4589	Actions *[]string `json:"actions,omitempty"`
4590}
4591
4592// AvailableDelegationsResult an array of available delegations.
4593type AvailableDelegationsResult struct {
4594	autorest.Response `json:"-"`
4595	// Value - An array of available delegations.
4596	Value *[]AvailableDelegation `json:"value,omitempty"`
4597	// NextLink - The URL to get the next set of results.
4598	NextLink *string `json:"nextLink,omitempty"`
4599}
4600
4601// AvailableDelegationsResultIterator provides access to a complete listing of AvailableDelegation values.
4602type AvailableDelegationsResultIterator struct {
4603	i    int
4604	page AvailableDelegationsResultPage
4605}
4606
4607// Next advances to the next value.  If there was an error making
4608// the request the iterator does not advance and the error is returned.
4609func (iter *AvailableDelegationsResultIterator) Next() error {
4610	iter.i++
4611	if iter.i < len(iter.page.Values()) {
4612		return nil
4613	}
4614	err := iter.page.Next()
4615	if err != nil {
4616		iter.i--
4617		return err
4618	}
4619	iter.i = 0
4620	return nil
4621}
4622
4623// NotDone returns true if the enumeration should be started or is not yet complete.
4624func (iter AvailableDelegationsResultIterator) NotDone() bool {
4625	return iter.page.NotDone() && iter.i < len(iter.page.Values())
4626}
4627
4628// Response returns the raw server response from the last page request.
4629func (iter AvailableDelegationsResultIterator) Response() AvailableDelegationsResult {
4630	return iter.page.Response()
4631}
4632
4633// Value returns the current value or a zero-initialized value if the
4634// iterator has advanced beyond the end of the collection.
4635func (iter AvailableDelegationsResultIterator) Value() AvailableDelegation {
4636	if !iter.page.NotDone() {
4637		return AvailableDelegation{}
4638	}
4639	return iter.page.Values()[iter.i]
4640}
4641
4642// IsEmpty returns true if the ListResult contains no values.
4643func (adr AvailableDelegationsResult) IsEmpty() bool {
4644	return adr.Value == nil || len(*adr.Value) == 0
4645}
4646
4647// availableDelegationsResultPreparer prepares a request to retrieve the next set of results.
4648// It returns nil if no more results exist.
4649func (adr AvailableDelegationsResult) availableDelegationsResultPreparer() (*http.Request, error) {
4650	if adr.NextLink == nil || len(to.String(adr.NextLink)) < 1 {
4651		return nil, nil
4652	}
4653	return autorest.Prepare(&http.Request{},
4654		autorest.AsJSON(),
4655		autorest.AsGet(),
4656		autorest.WithBaseURL(to.String(adr.NextLink)))
4657}
4658
4659// AvailableDelegationsResultPage contains a page of AvailableDelegation values.
4660type AvailableDelegationsResultPage struct {
4661	fn  func(AvailableDelegationsResult) (AvailableDelegationsResult, error)
4662	adr AvailableDelegationsResult
4663}
4664
4665// Next advances to the next page of values.  If there was an error making
4666// the request the page does not advance and the error is returned.
4667func (page *AvailableDelegationsResultPage) Next() error {
4668	next, err := page.fn(page.adr)
4669	if err != nil {
4670		return err
4671	}
4672	page.adr = next
4673	return nil
4674}
4675
4676// NotDone returns true if the page enumeration should be started or is not yet complete.
4677func (page AvailableDelegationsResultPage) NotDone() bool {
4678	return !page.adr.IsEmpty()
4679}
4680
4681// Response returns the raw server response from the last page request.
4682func (page AvailableDelegationsResultPage) Response() AvailableDelegationsResult {
4683	return page.adr
4684}
4685
4686// Values returns the slice of values for the current page or nil if there are no values.
4687func (page AvailableDelegationsResultPage) Values() []AvailableDelegation {
4688	if page.adr.IsEmpty() {
4689		return nil
4690	}
4691	return *page.adr.Value
4692}
4693
4694// AvailableProvidersList list of available countries with details.
4695type AvailableProvidersList struct {
4696	autorest.Response `json:"-"`
4697	// Countries - List of available countries.
4698	Countries *[]AvailableProvidersListCountry `json:"countries,omitempty"`
4699}
4700
4701// AvailableProvidersListCity city or town details.
4702type AvailableProvidersListCity struct {
4703	// CityName - The city or town name.
4704	CityName *string `json:"cityName,omitempty"`
4705	// Providers - A list of Internet service providers.
4706	Providers *[]string `json:"providers,omitempty"`
4707}
4708
4709// AvailableProvidersListCountry country details.
4710type AvailableProvidersListCountry struct {
4711	// CountryName - The country name.
4712	CountryName *string `json:"countryName,omitempty"`
4713	// Providers - A list of Internet service providers.
4714	Providers *[]string `json:"providers,omitempty"`
4715	// States - List of available states in the country.
4716	States *[]AvailableProvidersListState `json:"states,omitempty"`
4717}
4718
4719// AvailableProvidersListParameters constraints that determine the list of available Internet service providers.
4720type AvailableProvidersListParameters struct {
4721	// AzureLocations - A list of Azure regions.
4722	AzureLocations *[]string `json:"azureLocations,omitempty"`
4723	// Country - The country for available providers list.
4724	Country *string `json:"country,omitempty"`
4725	// State - The state for available providers list.
4726	State *string `json:"state,omitempty"`
4727	// City - The city or town for available providers list.
4728	City *string `json:"city,omitempty"`
4729}
4730
4731// AvailableProvidersListState state details.
4732type AvailableProvidersListState struct {
4733	// StateName - The state name.
4734	StateName *string `json:"stateName,omitempty"`
4735	// Providers - A list of Internet service providers.
4736	Providers *[]string `json:"providers,omitempty"`
4737	// Cities - List of available cities or towns in the state.
4738	Cities *[]AvailableProvidersListCity `json:"cities,omitempty"`
4739}
4740
4741// AzureAsyncOperationResult the response body contains the status of the specified asynchronous operation,
4742// indicating whether it has succeeded, is in progress, or has failed. Note that this status is distinct from the
4743// HTTP status code returned for the Get Operation Status operation itself. If the asynchronous operation
4744// succeeded, the response body includes the HTTP status code for the successful request. If the asynchronous
4745// operation failed, the response body includes the HTTP status code for the failed request and error information
4746// regarding the failure.
4747type AzureAsyncOperationResult struct {
4748	// Status - Status of the Azure async operation. Possible values are: 'InProgress', 'Succeeded', and 'Failed'. Possible values include: 'OperationStatusInProgress', 'OperationStatusSucceeded', 'OperationStatusFailed'
4749	Status OperationStatus `json:"status,omitempty"`
4750	Error  *Error          `json:"error,omitempty"`
4751}
4752
4753// AzureFirewall azure Firewall resource
4754type AzureFirewall struct {
4755	autorest.Response              `json:"-"`
4756	*AzureFirewallPropertiesFormat `json:"properties,omitempty"`
4757	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
4758	Etag *string `json:"etag,omitempty"`
4759	// ID - Resource ID.
4760	ID *string `json:"id,omitempty"`
4761	// Name - Resource name.
4762	Name *string `json:"name,omitempty"`
4763	// Type - Resource type.
4764	Type *string `json:"type,omitempty"`
4765	// Location - Resource location.
4766	Location *string `json:"location,omitempty"`
4767	// Tags - Resource tags.
4768	Tags map[string]*string `json:"tags"`
4769}
4770
4771// MarshalJSON is the custom marshaler for AzureFirewall.
4772func (af AzureFirewall) MarshalJSON() ([]byte, error) {
4773	objectMap := make(map[string]interface{})
4774	if af.AzureFirewallPropertiesFormat != nil {
4775		objectMap["properties"] = af.AzureFirewallPropertiesFormat
4776	}
4777	if af.Etag != nil {
4778		objectMap["etag"] = af.Etag
4779	}
4780	if af.ID != nil {
4781		objectMap["id"] = af.ID
4782	}
4783	if af.Name != nil {
4784		objectMap["name"] = af.Name
4785	}
4786	if af.Type != nil {
4787		objectMap["type"] = af.Type
4788	}
4789	if af.Location != nil {
4790		objectMap["location"] = af.Location
4791	}
4792	if af.Tags != nil {
4793		objectMap["tags"] = af.Tags
4794	}
4795	return json.Marshal(objectMap)
4796}
4797
4798// UnmarshalJSON is the custom unmarshaler for AzureFirewall struct.
4799func (af *AzureFirewall) UnmarshalJSON(body []byte) error {
4800	var m map[string]*json.RawMessage
4801	err := json.Unmarshal(body, &m)
4802	if err != nil {
4803		return err
4804	}
4805	for k, v := range m {
4806		switch k {
4807		case "properties":
4808			if v != nil {
4809				var azureFirewallPropertiesFormat AzureFirewallPropertiesFormat
4810				err = json.Unmarshal(*v, &azureFirewallPropertiesFormat)
4811				if err != nil {
4812					return err
4813				}
4814				af.AzureFirewallPropertiesFormat = &azureFirewallPropertiesFormat
4815			}
4816		case "etag":
4817			if v != nil {
4818				var etag string
4819				err = json.Unmarshal(*v, &etag)
4820				if err != nil {
4821					return err
4822				}
4823				af.Etag = &etag
4824			}
4825		case "id":
4826			if v != nil {
4827				var ID string
4828				err = json.Unmarshal(*v, &ID)
4829				if err != nil {
4830					return err
4831				}
4832				af.ID = &ID
4833			}
4834		case "name":
4835			if v != nil {
4836				var name string
4837				err = json.Unmarshal(*v, &name)
4838				if err != nil {
4839					return err
4840				}
4841				af.Name = &name
4842			}
4843		case "type":
4844			if v != nil {
4845				var typeVar string
4846				err = json.Unmarshal(*v, &typeVar)
4847				if err != nil {
4848					return err
4849				}
4850				af.Type = &typeVar
4851			}
4852		case "location":
4853			if v != nil {
4854				var location string
4855				err = json.Unmarshal(*v, &location)
4856				if err != nil {
4857					return err
4858				}
4859				af.Location = &location
4860			}
4861		case "tags":
4862			if v != nil {
4863				var tags map[string]*string
4864				err = json.Unmarshal(*v, &tags)
4865				if err != nil {
4866					return err
4867				}
4868				af.Tags = tags
4869			}
4870		}
4871	}
4872
4873	return nil
4874}
4875
4876// AzureFirewallApplicationRule properties of an application rule.
4877type AzureFirewallApplicationRule struct {
4878	// Name - Name of the application rule.
4879	Name *string `json:"name,omitempty"`
4880	// Description - Description of the rule.
4881	Description *string `json:"description,omitempty"`
4882	// SourceAddresses - List of source IP addresses for this rule.
4883	SourceAddresses *[]string `json:"sourceAddresses,omitempty"`
4884	// Protocols - Array of ApplicationRuleProtocols.
4885	Protocols *[]AzureFirewallApplicationRuleProtocol `json:"protocols,omitempty"`
4886	// TargetFqdns - List of FQDNs for this rule.
4887	TargetFqdns *[]string `json:"targetFqdns,omitempty"`
4888	// FqdnTags - List of FQDN Tags for this rule.
4889	FqdnTags *[]string `json:"fqdnTags,omitempty"`
4890}
4891
4892// AzureFirewallApplicationRuleCollection application rule collection resource
4893type AzureFirewallApplicationRuleCollection struct {
4894	*AzureFirewallApplicationRuleCollectionPropertiesFormat `json:"properties,omitempty"`
4895	// Name - Gets name of the resource that is unique within a resource group. This name can be used to access the resource.
4896	Name *string `json:"name,omitempty"`
4897	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
4898	Etag *string `json:"etag,omitempty"`
4899	// ID - Resource ID.
4900	ID *string `json:"id,omitempty"`
4901}
4902
4903// MarshalJSON is the custom marshaler for AzureFirewallApplicationRuleCollection.
4904func (afarc AzureFirewallApplicationRuleCollection) MarshalJSON() ([]byte, error) {
4905	objectMap := make(map[string]interface{})
4906	if afarc.AzureFirewallApplicationRuleCollectionPropertiesFormat != nil {
4907		objectMap["properties"] = afarc.AzureFirewallApplicationRuleCollectionPropertiesFormat
4908	}
4909	if afarc.Name != nil {
4910		objectMap["name"] = afarc.Name
4911	}
4912	if afarc.Etag != nil {
4913		objectMap["etag"] = afarc.Etag
4914	}
4915	if afarc.ID != nil {
4916		objectMap["id"] = afarc.ID
4917	}
4918	return json.Marshal(objectMap)
4919}
4920
4921// UnmarshalJSON is the custom unmarshaler for AzureFirewallApplicationRuleCollection struct.
4922func (afarc *AzureFirewallApplicationRuleCollection) UnmarshalJSON(body []byte) error {
4923	var m map[string]*json.RawMessage
4924	err := json.Unmarshal(body, &m)
4925	if err != nil {
4926		return err
4927	}
4928	for k, v := range m {
4929		switch k {
4930		case "properties":
4931			if v != nil {
4932				var azureFirewallApplicationRuleCollectionPropertiesFormat AzureFirewallApplicationRuleCollectionPropertiesFormat
4933				err = json.Unmarshal(*v, &azureFirewallApplicationRuleCollectionPropertiesFormat)
4934				if err != nil {
4935					return err
4936				}
4937				afarc.AzureFirewallApplicationRuleCollectionPropertiesFormat = &azureFirewallApplicationRuleCollectionPropertiesFormat
4938			}
4939		case "name":
4940			if v != nil {
4941				var name string
4942				err = json.Unmarshal(*v, &name)
4943				if err != nil {
4944					return err
4945				}
4946				afarc.Name = &name
4947			}
4948		case "etag":
4949			if v != nil {
4950				var etag string
4951				err = json.Unmarshal(*v, &etag)
4952				if err != nil {
4953					return err
4954				}
4955				afarc.Etag = &etag
4956			}
4957		case "id":
4958			if v != nil {
4959				var ID string
4960				err = json.Unmarshal(*v, &ID)
4961				if err != nil {
4962					return err
4963				}
4964				afarc.ID = &ID
4965			}
4966		}
4967	}
4968
4969	return nil
4970}
4971
4972// AzureFirewallApplicationRuleCollectionPropertiesFormat properties of the application rule collection.
4973type AzureFirewallApplicationRuleCollectionPropertiesFormat struct {
4974	// Priority - Priority of the application rule collection resource.
4975	Priority *int32 `json:"priority,omitempty"`
4976	// Action - The action type of a rule collection
4977	Action *AzureFirewallRCAction `json:"action,omitempty"`
4978	// Rules - Collection of rules used by a application rule collection.
4979	Rules *[]AzureFirewallApplicationRule `json:"rules,omitempty"`
4980	// ProvisioningState - The provisioning state of the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
4981	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
4982}
4983
4984// AzureFirewallApplicationRuleProtocol properties of the application rule protocol.
4985type AzureFirewallApplicationRuleProtocol struct {
4986	// ProtocolType - Protocol type. Possible values include: 'AzureFirewallApplicationRuleProtocolTypeHTTP', 'AzureFirewallApplicationRuleProtocolTypeHTTPS'
4987	ProtocolType AzureFirewallApplicationRuleProtocolType `json:"protocolType,omitempty"`
4988	// Port - Port number for the protocol, cannot be greater than 64000. This field is optional.
4989	Port *int32 `json:"port,omitempty"`
4990}
4991
4992// AzureFirewallFqdnTag azure Firewall FQDN Tag Resource
4993type AzureFirewallFqdnTag struct {
4994	*AzureFirewallFqdnTagPropertiesFormat `json:"properties,omitempty"`
4995	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
4996	Etag *string `json:"etag,omitempty"`
4997	// ID - Resource ID.
4998	ID *string `json:"id,omitempty"`
4999	// Name - Resource name.
5000	Name *string `json:"name,omitempty"`
5001	// Type - Resource type.
5002	Type *string `json:"type,omitempty"`
5003	// Location - Resource location.
5004	Location *string `json:"location,omitempty"`
5005	// Tags - Resource tags.
5006	Tags map[string]*string `json:"tags"`
5007}
5008
5009// MarshalJSON is the custom marshaler for AzureFirewallFqdnTag.
5010func (afft AzureFirewallFqdnTag) MarshalJSON() ([]byte, error) {
5011	objectMap := make(map[string]interface{})
5012	if afft.AzureFirewallFqdnTagPropertiesFormat != nil {
5013		objectMap["properties"] = afft.AzureFirewallFqdnTagPropertiesFormat
5014	}
5015	if afft.Etag != nil {
5016		objectMap["etag"] = afft.Etag
5017	}
5018	if afft.ID != nil {
5019		objectMap["id"] = afft.ID
5020	}
5021	if afft.Name != nil {
5022		objectMap["name"] = afft.Name
5023	}
5024	if afft.Type != nil {
5025		objectMap["type"] = afft.Type
5026	}
5027	if afft.Location != nil {
5028		objectMap["location"] = afft.Location
5029	}
5030	if afft.Tags != nil {
5031		objectMap["tags"] = afft.Tags
5032	}
5033	return json.Marshal(objectMap)
5034}
5035
5036// UnmarshalJSON is the custom unmarshaler for AzureFirewallFqdnTag struct.
5037func (afft *AzureFirewallFqdnTag) UnmarshalJSON(body []byte) error {
5038	var m map[string]*json.RawMessage
5039	err := json.Unmarshal(body, &m)
5040	if err != nil {
5041		return err
5042	}
5043	for k, v := range m {
5044		switch k {
5045		case "properties":
5046			if v != nil {
5047				var azureFirewallFqdnTagPropertiesFormat AzureFirewallFqdnTagPropertiesFormat
5048				err = json.Unmarshal(*v, &azureFirewallFqdnTagPropertiesFormat)
5049				if err != nil {
5050					return err
5051				}
5052				afft.AzureFirewallFqdnTagPropertiesFormat = &azureFirewallFqdnTagPropertiesFormat
5053			}
5054		case "etag":
5055			if v != nil {
5056				var etag string
5057				err = json.Unmarshal(*v, &etag)
5058				if err != nil {
5059					return err
5060				}
5061				afft.Etag = &etag
5062			}
5063		case "id":
5064			if v != nil {
5065				var ID string
5066				err = json.Unmarshal(*v, &ID)
5067				if err != nil {
5068					return err
5069				}
5070				afft.ID = &ID
5071			}
5072		case "name":
5073			if v != nil {
5074				var name string
5075				err = json.Unmarshal(*v, &name)
5076				if err != nil {
5077					return err
5078				}
5079				afft.Name = &name
5080			}
5081		case "type":
5082			if v != nil {
5083				var typeVar string
5084				err = json.Unmarshal(*v, &typeVar)
5085				if err != nil {
5086					return err
5087				}
5088				afft.Type = &typeVar
5089			}
5090		case "location":
5091			if v != nil {
5092				var location string
5093				err = json.Unmarshal(*v, &location)
5094				if err != nil {
5095					return err
5096				}
5097				afft.Location = &location
5098			}
5099		case "tags":
5100			if v != nil {
5101				var tags map[string]*string
5102				err = json.Unmarshal(*v, &tags)
5103				if err != nil {
5104					return err
5105				}
5106				afft.Tags = tags
5107			}
5108		}
5109	}
5110
5111	return nil
5112}
5113
5114// AzureFirewallFqdnTagListResult response for ListAzureFirewallFqdnTags API service call.
5115type AzureFirewallFqdnTagListResult struct {
5116	autorest.Response `json:"-"`
5117	// Value - List of Azure Firewall FQDN Tags in a resource group.
5118	Value *[]AzureFirewallFqdnTag `json:"value,omitempty"`
5119	// NextLink - URL to get the next set of results.
5120	NextLink *string `json:"nextLink,omitempty"`
5121}
5122
5123// AzureFirewallFqdnTagListResultIterator provides access to a complete listing of AzureFirewallFqdnTag values.
5124type AzureFirewallFqdnTagListResultIterator struct {
5125	i    int
5126	page AzureFirewallFqdnTagListResultPage
5127}
5128
5129// Next advances to the next value.  If there was an error making
5130// the request the iterator does not advance and the error is returned.
5131func (iter *AzureFirewallFqdnTagListResultIterator) Next() error {
5132	iter.i++
5133	if iter.i < len(iter.page.Values()) {
5134		return nil
5135	}
5136	err := iter.page.Next()
5137	if err != nil {
5138		iter.i--
5139		return err
5140	}
5141	iter.i = 0
5142	return nil
5143}
5144
5145// NotDone returns true if the enumeration should be started or is not yet complete.
5146func (iter AzureFirewallFqdnTagListResultIterator) NotDone() bool {
5147	return iter.page.NotDone() && iter.i < len(iter.page.Values())
5148}
5149
5150// Response returns the raw server response from the last page request.
5151func (iter AzureFirewallFqdnTagListResultIterator) Response() AzureFirewallFqdnTagListResult {
5152	return iter.page.Response()
5153}
5154
5155// Value returns the current value or a zero-initialized value if the
5156// iterator has advanced beyond the end of the collection.
5157func (iter AzureFirewallFqdnTagListResultIterator) Value() AzureFirewallFqdnTag {
5158	if !iter.page.NotDone() {
5159		return AzureFirewallFqdnTag{}
5160	}
5161	return iter.page.Values()[iter.i]
5162}
5163
5164// IsEmpty returns true if the ListResult contains no values.
5165func (afftlr AzureFirewallFqdnTagListResult) IsEmpty() bool {
5166	return afftlr.Value == nil || len(*afftlr.Value) == 0
5167}
5168
5169// azureFirewallFqdnTagListResultPreparer prepares a request to retrieve the next set of results.
5170// It returns nil if no more results exist.
5171func (afftlr AzureFirewallFqdnTagListResult) azureFirewallFqdnTagListResultPreparer() (*http.Request, error) {
5172	if afftlr.NextLink == nil || len(to.String(afftlr.NextLink)) < 1 {
5173		return nil, nil
5174	}
5175	return autorest.Prepare(&http.Request{},
5176		autorest.AsJSON(),
5177		autorest.AsGet(),
5178		autorest.WithBaseURL(to.String(afftlr.NextLink)))
5179}
5180
5181// AzureFirewallFqdnTagListResultPage contains a page of AzureFirewallFqdnTag values.
5182type AzureFirewallFqdnTagListResultPage struct {
5183	fn     func(AzureFirewallFqdnTagListResult) (AzureFirewallFqdnTagListResult, error)
5184	afftlr AzureFirewallFqdnTagListResult
5185}
5186
5187// Next advances to the next page of values.  If there was an error making
5188// the request the page does not advance and the error is returned.
5189func (page *AzureFirewallFqdnTagListResultPage) Next() error {
5190	next, err := page.fn(page.afftlr)
5191	if err != nil {
5192		return err
5193	}
5194	page.afftlr = next
5195	return nil
5196}
5197
5198// NotDone returns true if the page enumeration should be started or is not yet complete.
5199func (page AzureFirewallFqdnTagListResultPage) NotDone() bool {
5200	return !page.afftlr.IsEmpty()
5201}
5202
5203// Response returns the raw server response from the last page request.
5204func (page AzureFirewallFqdnTagListResultPage) Response() AzureFirewallFqdnTagListResult {
5205	return page.afftlr
5206}
5207
5208// Values returns the slice of values for the current page or nil if there are no values.
5209func (page AzureFirewallFqdnTagListResultPage) Values() []AzureFirewallFqdnTag {
5210	if page.afftlr.IsEmpty() {
5211		return nil
5212	}
5213	return *page.afftlr.Value
5214}
5215
5216// AzureFirewallFqdnTagPropertiesFormat azure Firewall FQDN Tag Properties
5217type AzureFirewallFqdnTagPropertiesFormat struct {
5218	// ProvisioningState - The provisioning state of the resource.
5219	ProvisioningState *string `json:"provisioningState,omitempty"`
5220	// FqdnTagName - The name of this FQDN Tag.
5221	FqdnTagName *string `json:"fqdnTagName,omitempty"`
5222}
5223
5224// AzureFirewallIPConfiguration IP configuration of an Azure Firewall.
5225type AzureFirewallIPConfiguration struct {
5226	*AzureFirewallIPConfigurationPropertiesFormat `json:"properties,omitempty"`
5227	// Name - Name of the resource that is unique within a resource group. This name can be used to access the resource.
5228	Name *string `json:"name,omitempty"`
5229	// Etag - A unique read-only string that changes whenever the resource is updated.
5230	Etag *string `json:"etag,omitempty"`
5231	// ID - Resource ID.
5232	ID *string `json:"id,omitempty"`
5233}
5234
5235// MarshalJSON is the custom marshaler for AzureFirewallIPConfiguration.
5236func (afic AzureFirewallIPConfiguration) MarshalJSON() ([]byte, error) {
5237	objectMap := make(map[string]interface{})
5238	if afic.AzureFirewallIPConfigurationPropertiesFormat != nil {
5239		objectMap["properties"] = afic.AzureFirewallIPConfigurationPropertiesFormat
5240	}
5241	if afic.Name != nil {
5242		objectMap["name"] = afic.Name
5243	}
5244	if afic.Etag != nil {
5245		objectMap["etag"] = afic.Etag
5246	}
5247	if afic.ID != nil {
5248		objectMap["id"] = afic.ID
5249	}
5250	return json.Marshal(objectMap)
5251}
5252
5253// UnmarshalJSON is the custom unmarshaler for AzureFirewallIPConfiguration struct.
5254func (afic *AzureFirewallIPConfiguration) UnmarshalJSON(body []byte) error {
5255	var m map[string]*json.RawMessage
5256	err := json.Unmarshal(body, &m)
5257	if err != nil {
5258		return err
5259	}
5260	for k, v := range m {
5261		switch k {
5262		case "properties":
5263			if v != nil {
5264				var azureFirewallIPConfigurationPropertiesFormat AzureFirewallIPConfigurationPropertiesFormat
5265				err = json.Unmarshal(*v, &azureFirewallIPConfigurationPropertiesFormat)
5266				if err != nil {
5267					return err
5268				}
5269				afic.AzureFirewallIPConfigurationPropertiesFormat = &azureFirewallIPConfigurationPropertiesFormat
5270			}
5271		case "name":
5272			if v != nil {
5273				var name string
5274				err = json.Unmarshal(*v, &name)
5275				if err != nil {
5276					return err
5277				}
5278				afic.Name = &name
5279			}
5280		case "etag":
5281			if v != nil {
5282				var etag string
5283				err = json.Unmarshal(*v, &etag)
5284				if err != nil {
5285					return err
5286				}
5287				afic.Etag = &etag
5288			}
5289		case "id":
5290			if v != nil {
5291				var ID string
5292				err = json.Unmarshal(*v, &ID)
5293				if err != nil {
5294					return err
5295				}
5296				afic.ID = &ID
5297			}
5298		}
5299	}
5300
5301	return nil
5302}
5303
5304// AzureFirewallIPConfigurationPropertiesFormat properties of IP configuration of an Azure Firewall.
5305type AzureFirewallIPConfigurationPropertiesFormat struct {
5306	// PrivateIPAddress - The Firewall Internal Load Balancer IP to be used as the next hop in User Defined Routes.
5307	PrivateIPAddress *string `json:"privateIPAddress,omitempty"`
5308	// Subnet - Reference of the subnet resource. This resource must be named 'AzureFirewallSubnet'.
5309	Subnet *SubResource `json:"subnet,omitempty"`
5310	// PublicIPAddress - Reference of the PublicIP resource. This field is a mandatory input if subnet is not null.
5311	PublicIPAddress *SubResource `json:"publicIPAddress,omitempty"`
5312	// ProvisioningState - The provisioning state of the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
5313	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
5314}
5315
5316// AzureFirewallListResult response for ListAzureFirewalls API service call.
5317type AzureFirewallListResult struct {
5318	autorest.Response `json:"-"`
5319	// Value - List of Azure Firewalls in a resource group.
5320	Value *[]AzureFirewall `json:"value,omitempty"`
5321	// NextLink - URL to get the next set of results.
5322	NextLink *string `json:"nextLink,omitempty"`
5323}
5324
5325// AzureFirewallListResultIterator provides access to a complete listing of AzureFirewall values.
5326type AzureFirewallListResultIterator struct {
5327	i    int
5328	page AzureFirewallListResultPage
5329}
5330
5331// Next advances to the next value.  If there was an error making
5332// the request the iterator does not advance and the error is returned.
5333func (iter *AzureFirewallListResultIterator) Next() error {
5334	iter.i++
5335	if iter.i < len(iter.page.Values()) {
5336		return nil
5337	}
5338	err := iter.page.Next()
5339	if err != nil {
5340		iter.i--
5341		return err
5342	}
5343	iter.i = 0
5344	return nil
5345}
5346
5347// NotDone returns true if the enumeration should be started or is not yet complete.
5348func (iter AzureFirewallListResultIterator) NotDone() bool {
5349	return iter.page.NotDone() && iter.i < len(iter.page.Values())
5350}
5351
5352// Response returns the raw server response from the last page request.
5353func (iter AzureFirewallListResultIterator) Response() AzureFirewallListResult {
5354	return iter.page.Response()
5355}
5356
5357// Value returns the current value or a zero-initialized value if the
5358// iterator has advanced beyond the end of the collection.
5359func (iter AzureFirewallListResultIterator) Value() AzureFirewall {
5360	if !iter.page.NotDone() {
5361		return AzureFirewall{}
5362	}
5363	return iter.page.Values()[iter.i]
5364}
5365
5366// IsEmpty returns true if the ListResult contains no values.
5367func (aflr AzureFirewallListResult) IsEmpty() bool {
5368	return aflr.Value == nil || len(*aflr.Value) == 0
5369}
5370
5371// azureFirewallListResultPreparer prepares a request to retrieve the next set of results.
5372// It returns nil if no more results exist.
5373func (aflr AzureFirewallListResult) azureFirewallListResultPreparer() (*http.Request, error) {
5374	if aflr.NextLink == nil || len(to.String(aflr.NextLink)) < 1 {
5375		return nil, nil
5376	}
5377	return autorest.Prepare(&http.Request{},
5378		autorest.AsJSON(),
5379		autorest.AsGet(),
5380		autorest.WithBaseURL(to.String(aflr.NextLink)))
5381}
5382
5383// AzureFirewallListResultPage contains a page of AzureFirewall values.
5384type AzureFirewallListResultPage struct {
5385	fn   func(AzureFirewallListResult) (AzureFirewallListResult, error)
5386	aflr AzureFirewallListResult
5387}
5388
5389// Next advances to the next page of values.  If there was an error making
5390// the request the page does not advance and the error is returned.
5391func (page *AzureFirewallListResultPage) Next() error {
5392	next, err := page.fn(page.aflr)
5393	if err != nil {
5394		return err
5395	}
5396	page.aflr = next
5397	return nil
5398}
5399
5400// NotDone returns true if the page enumeration should be started or is not yet complete.
5401func (page AzureFirewallListResultPage) NotDone() bool {
5402	return !page.aflr.IsEmpty()
5403}
5404
5405// Response returns the raw server response from the last page request.
5406func (page AzureFirewallListResultPage) Response() AzureFirewallListResult {
5407	return page.aflr
5408}
5409
5410// Values returns the slice of values for the current page or nil if there are no values.
5411func (page AzureFirewallListResultPage) Values() []AzureFirewall {
5412	if page.aflr.IsEmpty() {
5413		return nil
5414	}
5415	return *page.aflr.Value
5416}
5417
5418// AzureFirewallNatRCAction azureFirewall NAT Rule Collection Action.
5419type AzureFirewallNatRCAction struct {
5420	// Type - The type of action. Possible values include: 'Snat', 'Dnat'
5421	Type AzureFirewallNatRCActionType `json:"type,omitempty"`
5422}
5423
5424// AzureFirewallNatRule properties of a NAT rule.
5425type AzureFirewallNatRule struct {
5426	// Name - Name of the NAT rule.
5427	Name *string `json:"name,omitempty"`
5428	// Description - Description of the rule.
5429	Description *string `json:"description,omitempty"`
5430	// SourceAddresses - List of source IP addresses for this rule.
5431	SourceAddresses *[]string `json:"sourceAddresses,omitempty"`
5432	// DestinationAddresses - List of destination IP addresses for this rule.
5433	DestinationAddresses *[]string `json:"destinationAddresses,omitempty"`
5434	// DestinationPorts - List of destination ports.
5435	DestinationPorts *[]string `json:"destinationPorts,omitempty"`
5436	// Protocols - Array of AzureFirewallNetworkRuleProtocols applicable to this NAT rule.
5437	Protocols *[]AzureFirewallNetworkRuleProtocol `json:"protocols,omitempty"`
5438	// TranslatedAddress - The translated address for this NAT rule.
5439	TranslatedAddress *string `json:"translatedAddress,omitempty"`
5440	// TranslatedPort - The translated port for this NAT rule.
5441	TranslatedPort *string `json:"translatedPort,omitempty"`
5442}
5443
5444// AzureFirewallNatRuleCollection NAT rule collection resource
5445type AzureFirewallNatRuleCollection struct {
5446	*AzureFirewallNatRuleCollectionProperties `json:"properties,omitempty"`
5447	// Name - Gets name of the resource that is unique within a resource group. This name can be used to access the resource.
5448	Name *string `json:"name,omitempty"`
5449	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
5450	Etag *string `json:"etag,omitempty"`
5451	// ID - Resource ID.
5452	ID *string `json:"id,omitempty"`
5453}
5454
5455// MarshalJSON is the custom marshaler for AzureFirewallNatRuleCollection.
5456func (afnrc AzureFirewallNatRuleCollection) MarshalJSON() ([]byte, error) {
5457	objectMap := make(map[string]interface{})
5458	if afnrc.AzureFirewallNatRuleCollectionProperties != nil {
5459		objectMap["properties"] = afnrc.AzureFirewallNatRuleCollectionProperties
5460	}
5461	if afnrc.Name != nil {
5462		objectMap["name"] = afnrc.Name
5463	}
5464	if afnrc.Etag != nil {
5465		objectMap["etag"] = afnrc.Etag
5466	}
5467	if afnrc.ID != nil {
5468		objectMap["id"] = afnrc.ID
5469	}
5470	return json.Marshal(objectMap)
5471}
5472
5473// UnmarshalJSON is the custom unmarshaler for AzureFirewallNatRuleCollection struct.
5474func (afnrc *AzureFirewallNatRuleCollection) UnmarshalJSON(body []byte) error {
5475	var m map[string]*json.RawMessage
5476	err := json.Unmarshal(body, &m)
5477	if err != nil {
5478		return err
5479	}
5480	for k, v := range m {
5481		switch k {
5482		case "properties":
5483			if v != nil {
5484				var azureFirewallNatRuleCollectionProperties AzureFirewallNatRuleCollectionProperties
5485				err = json.Unmarshal(*v, &azureFirewallNatRuleCollectionProperties)
5486				if err != nil {
5487					return err
5488				}
5489				afnrc.AzureFirewallNatRuleCollectionProperties = &azureFirewallNatRuleCollectionProperties
5490			}
5491		case "name":
5492			if v != nil {
5493				var name string
5494				err = json.Unmarshal(*v, &name)
5495				if err != nil {
5496					return err
5497				}
5498				afnrc.Name = &name
5499			}
5500		case "etag":
5501			if v != nil {
5502				var etag string
5503				err = json.Unmarshal(*v, &etag)
5504				if err != nil {
5505					return err
5506				}
5507				afnrc.Etag = &etag
5508			}
5509		case "id":
5510			if v != nil {
5511				var ID string
5512				err = json.Unmarshal(*v, &ID)
5513				if err != nil {
5514					return err
5515				}
5516				afnrc.ID = &ID
5517			}
5518		}
5519	}
5520
5521	return nil
5522}
5523
5524// AzureFirewallNatRuleCollectionProperties properties of the NAT rule collection.
5525type AzureFirewallNatRuleCollectionProperties struct {
5526	// Priority - Priority of the NAT rule collection resource.
5527	Priority *int32 `json:"priority,omitempty"`
5528	// Action - The action type of a NAT rule collection
5529	Action *AzureFirewallNatRCAction `json:"action,omitempty"`
5530	// Rules - Collection of rules used by a NAT rule collection.
5531	Rules *[]AzureFirewallNatRule `json:"rules,omitempty"`
5532	// ProvisioningState - The provisioning state of the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
5533	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
5534}
5535
5536// AzureFirewallNetworkRule properties of the network rule.
5537type AzureFirewallNetworkRule struct {
5538	// Name - Name of the network rule.
5539	Name *string `json:"name,omitempty"`
5540	// Description - Description of the rule.
5541	Description *string `json:"description,omitempty"`
5542	// Protocols - Array of AzureFirewallNetworkRuleProtocols.
5543	Protocols *[]AzureFirewallNetworkRuleProtocol `json:"protocols,omitempty"`
5544	// SourceAddresses - List of source IP addresses for this rule.
5545	SourceAddresses *[]string `json:"sourceAddresses,omitempty"`
5546	// DestinationAddresses - List of destination IP addresses.
5547	DestinationAddresses *[]string `json:"destinationAddresses,omitempty"`
5548	// DestinationPorts - List of destination ports.
5549	DestinationPorts *[]string `json:"destinationPorts,omitempty"`
5550}
5551
5552// AzureFirewallNetworkRuleCollection network rule collection resource
5553type AzureFirewallNetworkRuleCollection struct {
5554	*AzureFirewallNetworkRuleCollectionPropertiesFormat `json:"properties,omitempty"`
5555	// Name - Gets name of the resource that is unique within a resource group. This name can be used to access the resource.
5556	Name *string `json:"name,omitempty"`
5557	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
5558	Etag *string `json:"etag,omitempty"`
5559	// ID - Resource ID.
5560	ID *string `json:"id,omitempty"`
5561}
5562
5563// MarshalJSON is the custom marshaler for AzureFirewallNetworkRuleCollection.
5564func (afnrc AzureFirewallNetworkRuleCollection) MarshalJSON() ([]byte, error) {
5565	objectMap := make(map[string]interface{})
5566	if afnrc.AzureFirewallNetworkRuleCollectionPropertiesFormat != nil {
5567		objectMap["properties"] = afnrc.AzureFirewallNetworkRuleCollectionPropertiesFormat
5568	}
5569	if afnrc.Name != nil {
5570		objectMap["name"] = afnrc.Name
5571	}
5572	if afnrc.Etag != nil {
5573		objectMap["etag"] = afnrc.Etag
5574	}
5575	if afnrc.ID != nil {
5576		objectMap["id"] = afnrc.ID
5577	}
5578	return json.Marshal(objectMap)
5579}
5580
5581// UnmarshalJSON is the custom unmarshaler for AzureFirewallNetworkRuleCollection struct.
5582func (afnrc *AzureFirewallNetworkRuleCollection) UnmarshalJSON(body []byte) error {
5583	var m map[string]*json.RawMessage
5584	err := json.Unmarshal(body, &m)
5585	if err != nil {
5586		return err
5587	}
5588	for k, v := range m {
5589		switch k {
5590		case "properties":
5591			if v != nil {
5592				var azureFirewallNetworkRuleCollectionPropertiesFormat AzureFirewallNetworkRuleCollectionPropertiesFormat
5593				err = json.Unmarshal(*v, &azureFirewallNetworkRuleCollectionPropertiesFormat)
5594				if err != nil {
5595					return err
5596				}
5597				afnrc.AzureFirewallNetworkRuleCollectionPropertiesFormat = &azureFirewallNetworkRuleCollectionPropertiesFormat
5598			}
5599		case "name":
5600			if v != nil {
5601				var name string
5602				err = json.Unmarshal(*v, &name)
5603				if err != nil {
5604					return err
5605				}
5606				afnrc.Name = &name
5607			}
5608		case "etag":
5609			if v != nil {
5610				var etag string
5611				err = json.Unmarshal(*v, &etag)
5612				if err != nil {
5613					return err
5614				}
5615				afnrc.Etag = &etag
5616			}
5617		case "id":
5618			if v != nil {
5619				var ID string
5620				err = json.Unmarshal(*v, &ID)
5621				if err != nil {
5622					return err
5623				}
5624				afnrc.ID = &ID
5625			}
5626		}
5627	}
5628
5629	return nil
5630}
5631
5632// AzureFirewallNetworkRuleCollectionPropertiesFormat properties of the network rule collection.
5633type AzureFirewallNetworkRuleCollectionPropertiesFormat struct {
5634	// Priority - Priority of the network rule collection resource.
5635	Priority *int32 `json:"priority,omitempty"`
5636	// Action - The action type of a rule collection
5637	Action *AzureFirewallRCAction `json:"action,omitempty"`
5638	// Rules - Collection of rules used by a network rule collection.
5639	Rules *[]AzureFirewallNetworkRule `json:"rules,omitempty"`
5640	// ProvisioningState - The provisioning state of the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
5641	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
5642}
5643
5644// AzureFirewallPropertiesFormat properties of the Azure Firewall.
5645type AzureFirewallPropertiesFormat struct {
5646	// ApplicationRuleCollections - Collection of application rule collections used by Azure Firewall.
5647	ApplicationRuleCollections *[]AzureFirewallApplicationRuleCollection `json:"applicationRuleCollections,omitempty"`
5648	// NatRuleCollections - Collection of NAT rule collections used by Azure Firewall.
5649	NatRuleCollections *[]AzureFirewallNatRuleCollection `json:"natRuleCollections,omitempty"`
5650	// NetworkRuleCollections - Collection of network rule collections used by Azure Firewall.
5651	NetworkRuleCollections *[]AzureFirewallNetworkRuleCollection `json:"networkRuleCollections,omitempty"`
5652	// IPConfigurations - IP configuration of the Azure Firewall resource.
5653	IPConfigurations *[]AzureFirewallIPConfiguration `json:"ipConfigurations,omitempty"`
5654	// ProvisioningState - The provisioning state of the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
5655	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
5656}
5657
5658// AzureFirewallRCAction properties of the AzureFirewallRCAction.
5659type AzureFirewallRCAction struct {
5660	// Type - The type of action. Possible values include: 'AzureFirewallRCActionTypeAllow', 'AzureFirewallRCActionTypeDeny'
5661	Type AzureFirewallRCActionType `json:"type,omitempty"`
5662}
5663
5664// AzureFirewallsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
5665// operation.
5666type AzureFirewallsCreateOrUpdateFuture struct {
5667	azure.Future
5668}
5669
5670// Result returns the result of the asynchronous operation.
5671// If the operation has not completed it will return an error.
5672func (future *AzureFirewallsCreateOrUpdateFuture) Result(client AzureFirewallsClient) (af AzureFirewall, err error) {
5673	var done bool
5674	done, err = future.Done(client)
5675	if err != nil {
5676		err = autorest.NewErrorWithError(err, "network.AzureFirewallsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
5677		return
5678	}
5679	if !done {
5680		err = azure.NewAsyncOpIncompleteError("network.AzureFirewallsCreateOrUpdateFuture")
5681		return
5682	}
5683	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
5684	if af.Response.Response, err = future.GetResult(sender); err == nil && af.Response.Response.StatusCode != http.StatusNoContent {
5685		af, err = client.CreateOrUpdateResponder(af.Response.Response)
5686		if err != nil {
5687			err = autorest.NewErrorWithError(err, "network.AzureFirewallsCreateOrUpdateFuture", "Result", af.Response.Response, "Failure responding to request")
5688		}
5689	}
5690	return
5691}
5692
5693// AzureFirewallsDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
5694type AzureFirewallsDeleteFuture struct {
5695	azure.Future
5696}
5697
5698// Result returns the result of the asynchronous operation.
5699// If the operation has not completed it will return an error.
5700func (future *AzureFirewallsDeleteFuture) Result(client AzureFirewallsClient) (ar autorest.Response, err error) {
5701	var done bool
5702	done, err = future.Done(client)
5703	if err != nil {
5704		err = autorest.NewErrorWithError(err, "network.AzureFirewallsDeleteFuture", "Result", future.Response(), "Polling failure")
5705		return
5706	}
5707	if !done {
5708		err = azure.NewAsyncOpIncompleteError("network.AzureFirewallsDeleteFuture")
5709		return
5710	}
5711	ar.Response = future.Response()
5712	return
5713}
5714
5715// AzureReachabilityReport azure reachability report details.
5716type AzureReachabilityReport struct {
5717	autorest.Response `json:"-"`
5718	// AggregationLevel - The aggregation level of Azure reachability report. Can be Country, State or City.
5719	AggregationLevel *string                          `json:"aggregationLevel,omitempty"`
5720	ProviderLocation *AzureReachabilityReportLocation `json:"providerLocation,omitempty"`
5721	// ReachabilityReport - List of Azure reachability report items.
5722	ReachabilityReport *[]AzureReachabilityReportItem `json:"reachabilityReport,omitempty"`
5723}
5724
5725// AzureReachabilityReportItem azure reachability report details for a given provider location.
5726type AzureReachabilityReportItem struct {
5727	// Provider - The Internet service provider.
5728	Provider *string `json:"provider,omitempty"`
5729	// AzureLocation - The Azure region.
5730	AzureLocation *string `json:"azureLocation,omitempty"`
5731	// Latencies - List of latency details for each of the time series.
5732	Latencies *[]AzureReachabilityReportLatencyInfo `json:"latencies,omitempty"`
5733}
5734
5735// AzureReachabilityReportLatencyInfo details on latency for a time series.
5736type AzureReachabilityReportLatencyInfo struct {
5737	// TimeStamp - The time stamp.
5738	TimeStamp *date.Time `json:"timeStamp,omitempty"`
5739	// Score - The relative latency score between 1 and 100, higher values indicating a faster connection.
5740	Score *int32 `json:"score,omitempty"`
5741}
5742
5743// AzureReachabilityReportLocation parameters that define a geographic location.
5744type AzureReachabilityReportLocation struct {
5745	// Country - The name of the country.
5746	Country *string `json:"country,omitempty"`
5747	// State - The name of the state.
5748	State *string `json:"state,omitempty"`
5749	// City - The name of the city or town.
5750	City *string `json:"city,omitempty"`
5751}
5752
5753// AzureReachabilityReportParameters geographic and time constraints for Azure reachability report.
5754type AzureReachabilityReportParameters struct {
5755	ProviderLocation *AzureReachabilityReportLocation `json:"providerLocation,omitempty"`
5756	// Providers - List of Internet service providers.
5757	Providers *[]string `json:"providers,omitempty"`
5758	// AzureLocations - Optional Azure regions to scope the query to.
5759	AzureLocations *[]string `json:"azureLocations,omitempty"`
5760	// StartTime - The start time for the Azure reachability report.
5761	StartTime *date.Time `json:"startTime,omitempty"`
5762	// EndTime - The end time for the Azure reachability report.
5763	EndTime *date.Time `json:"endTime,omitempty"`
5764}
5765
5766// BackendAddressPool pool of backend IP addresses.
5767type BackendAddressPool struct {
5768	autorest.Response `json:"-"`
5769	// BackendAddressPoolPropertiesFormat - Properties of load balancer backend address pool.
5770	*BackendAddressPoolPropertiesFormat `json:"properties,omitempty"`
5771	// Name - Gets name of the resource that is unique within a resource group. This name can be used to access the resource.
5772	Name *string `json:"name,omitempty"`
5773	// Etag - A unique read-only string that changes whenever the resource is updated.
5774	Etag *string `json:"etag,omitempty"`
5775	// ID - Resource ID.
5776	ID *string `json:"id,omitempty"`
5777}
5778
5779// MarshalJSON is the custom marshaler for BackendAddressPool.
5780func (bap BackendAddressPool) MarshalJSON() ([]byte, error) {
5781	objectMap := make(map[string]interface{})
5782	if bap.BackendAddressPoolPropertiesFormat != nil {
5783		objectMap["properties"] = bap.BackendAddressPoolPropertiesFormat
5784	}
5785	if bap.Name != nil {
5786		objectMap["name"] = bap.Name
5787	}
5788	if bap.Etag != nil {
5789		objectMap["etag"] = bap.Etag
5790	}
5791	if bap.ID != nil {
5792		objectMap["id"] = bap.ID
5793	}
5794	return json.Marshal(objectMap)
5795}
5796
5797// UnmarshalJSON is the custom unmarshaler for BackendAddressPool struct.
5798func (bap *BackendAddressPool) UnmarshalJSON(body []byte) error {
5799	var m map[string]*json.RawMessage
5800	err := json.Unmarshal(body, &m)
5801	if err != nil {
5802		return err
5803	}
5804	for k, v := range m {
5805		switch k {
5806		case "properties":
5807			if v != nil {
5808				var backendAddressPoolPropertiesFormat BackendAddressPoolPropertiesFormat
5809				err = json.Unmarshal(*v, &backendAddressPoolPropertiesFormat)
5810				if err != nil {
5811					return err
5812				}
5813				bap.BackendAddressPoolPropertiesFormat = &backendAddressPoolPropertiesFormat
5814			}
5815		case "name":
5816			if v != nil {
5817				var name string
5818				err = json.Unmarshal(*v, &name)
5819				if err != nil {
5820					return err
5821				}
5822				bap.Name = &name
5823			}
5824		case "etag":
5825			if v != nil {
5826				var etag string
5827				err = json.Unmarshal(*v, &etag)
5828				if err != nil {
5829					return err
5830				}
5831				bap.Etag = &etag
5832			}
5833		case "id":
5834			if v != nil {
5835				var ID string
5836				err = json.Unmarshal(*v, &ID)
5837				if err != nil {
5838					return err
5839				}
5840				bap.ID = &ID
5841			}
5842		}
5843	}
5844
5845	return nil
5846}
5847
5848// BackendAddressPoolPropertiesFormat properties of the backend address pool.
5849type BackendAddressPoolPropertiesFormat struct {
5850	// BackendIPConfigurations - Gets collection of references to IP addresses defined in network interfaces.
5851	BackendIPConfigurations *[]InterfaceIPConfiguration `json:"backendIPConfigurations,omitempty"`
5852	// LoadBalancingRules - Gets load balancing rules that use this backend address pool.
5853	LoadBalancingRules *[]SubResource `json:"loadBalancingRules,omitempty"`
5854	// OutboundRule - Gets outbound rules that use this backend address pool.
5855	OutboundRule *SubResource `json:"outboundRule,omitempty"`
5856	// ProvisioningState - Get provisioning state of the public IP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
5857	ProvisioningState *string `json:"provisioningState,omitempty"`
5858}
5859
5860// BGPCommunity contains bgp community information offered in Service Community resources.
5861type BGPCommunity struct {
5862	// ServiceSupportedRegion - The region which the service support. e.g. For O365, region is Global.
5863	ServiceSupportedRegion *string `json:"serviceSupportedRegion,omitempty"`
5864	// CommunityName - The name of the bgp community. e.g. Skype.
5865	CommunityName *string `json:"communityName,omitempty"`
5866	// CommunityValue - The value of the bgp community. For more information: https://docs.microsoft.com/en-us/azure/expressroute/expressroute-routing.
5867	CommunityValue *string `json:"communityValue,omitempty"`
5868	// CommunityPrefixes - The prefixes that the bgp community contains.
5869	CommunityPrefixes *[]string `json:"communityPrefixes,omitempty"`
5870	// IsAuthorizedToUse - Customer is authorized to use bgp community or not.
5871	IsAuthorizedToUse *bool `json:"isAuthorizedToUse,omitempty"`
5872	// ServiceGroup - The service group of the bgp community contains.
5873	ServiceGroup *string `json:"serviceGroup,omitempty"`
5874}
5875
5876// BgpPeerStatus BGP peer status details
5877type BgpPeerStatus struct {
5878	// LocalAddress - The virtual network gateway's local address
5879	LocalAddress *string `json:"localAddress,omitempty"`
5880	// Neighbor - The remote BGP peer
5881	Neighbor *string `json:"neighbor,omitempty"`
5882	// Asn - The autonomous system number of the remote BGP peer
5883	Asn *int32 `json:"asn,omitempty"`
5884	// State - The BGP peer state. Possible values include: 'BgpPeerStateUnknown', 'BgpPeerStateStopped', 'BgpPeerStateIdle', 'BgpPeerStateConnecting', 'BgpPeerStateConnected'
5885	State BgpPeerState `json:"state,omitempty"`
5886	// ConnectedDuration - For how long the peering has been up
5887	ConnectedDuration *string `json:"connectedDuration,omitempty"`
5888	// RoutesReceived - The number of routes learned from this peer
5889	RoutesReceived *int64 `json:"routesReceived,omitempty"`
5890	// MessagesSent - The number of BGP messages sent
5891	MessagesSent *int64 `json:"messagesSent,omitempty"`
5892	// MessagesReceived - The number of BGP messages received
5893	MessagesReceived *int64 `json:"messagesReceived,omitempty"`
5894}
5895
5896// BgpPeerStatusListResult response for list BGP peer status API service call
5897type BgpPeerStatusListResult struct {
5898	autorest.Response `json:"-"`
5899	// Value - List of BGP peers
5900	Value *[]BgpPeerStatus `json:"value,omitempty"`
5901}
5902
5903// BgpServiceCommunity service Community Properties.
5904type BgpServiceCommunity struct {
5905	*BgpServiceCommunityPropertiesFormat `json:"properties,omitempty"`
5906	// ID - Resource ID.
5907	ID *string `json:"id,omitempty"`
5908	// Name - Resource name.
5909	Name *string `json:"name,omitempty"`
5910	// Type - Resource type.
5911	Type *string `json:"type,omitempty"`
5912	// Location - Resource location.
5913	Location *string `json:"location,omitempty"`
5914	// Tags - Resource tags.
5915	Tags map[string]*string `json:"tags"`
5916}
5917
5918// MarshalJSON is the custom marshaler for BgpServiceCommunity.
5919func (bsc BgpServiceCommunity) MarshalJSON() ([]byte, error) {
5920	objectMap := make(map[string]interface{})
5921	if bsc.BgpServiceCommunityPropertiesFormat != nil {
5922		objectMap["properties"] = bsc.BgpServiceCommunityPropertiesFormat
5923	}
5924	if bsc.ID != nil {
5925		objectMap["id"] = bsc.ID
5926	}
5927	if bsc.Name != nil {
5928		objectMap["name"] = bsc.Name
5929	}
5930	if bsc.Type != nil {
5931		objectMap["type"] = bsc.Type
5932	}
5933	if bsc.Location != nil {
5934		objectMap["location"] = bsc.Location
5935	}
5936	if bsc.Tags != nil {
5937		objectMap["tags"] = bsc.Tags
5938	}
5939	return json.Marshal(objectMap)
5940}
5941
5942// UnmarshalJSON is the custom unmarshaler for BgpServiceCommunity struct.
5943func (bsc *BgpServiceCommunity) UnmarshalJSON(body []byte) error {
5944	var m map[string]*json.RawMessage
5945	err := json.Unmarshal(body, &m)
5946	if err != nil {
5947		return err
5948	}
5949	for k, v := range m {
5950		switch k {
5951		case "properties":
5952			if v != nil {
5953				var bgpServiceCommunityPropertiesFormat BgpServiceCommunityPropertiesFormat
5954				err = json.Unmarshal(*v, &bgpServiceCommunityPropertiesFormat)
5955				if err != nil {
5956					return err
5957				}
5958				bsc.BgpServiceCommunityPropertiesFormat = &bgpServiceCommunityPropertiesFormat
5959			}
5960		case "id":
5961			if v != nil {
5962				var ID string
5963				err = json.Unmarshal(*v, &ID)
5964				if err != nil {
5965					return err
5966				}
5967				bsc.ID = &ID
5968			}
5969		case "name":
5970			if v != nil {
5971				var name string
5972				err = json.Unmarshal(*v, &name)
5973				if err != nil {
5974					return err
5975				}
5976				bsc.Name = &name
5977			}
5978		case "type":
5979			if v != nil {
5980				var typeVar string
5981				err = json.Unmarshal(*v, &typeVar)
5982				if err != nil {
5983					return err
5984				}
5985				bsc.Type = &typeVar
5986			}
5987		case "location":
5988			if v != nil {
5989				var location string
5990				err = json.Unmarshal(*v, &location)
5991				if err != nil {
5992					return err
5993				}
5994				bsc.Location = &location
5995			}
5996		case "tags":
5997			if v != nil {
5998				var tags map[string]*string
5999				err = json.Unmarshal(*v, &tags)
6000				if err != nil {
6001					return err
6002				}
6003				bsc.Tags = tags
6004			}
6005		}
6006	}
6007
6008	return nil
6009}
6010
6011// BgpServiceCommunityListResult response for the ListServiceCommunity API service call.
6012type BgpServiceCommunityListResult struct {
6013	autorest.Response `json:"-"`
6014	// Value - A list of service community resources.
6015	Value *[]BgpServiceCommunity `json:"value,omitempty"`
6016	// NextLink - The URL to get the next set of results.
6017	NextLink *string `json:"nextLink,omitempty"`
6018}
6019
6020// BgpServiceCommunityListResultIterator provides access to a complete listing of BgpServiceCommunity values.
6021type BgpServiceCommunityListResultIterator struct {
6022	i    int
6023	page BgpServiceCommunityListResultPage
6024}
6025
6026// Next advances to the next value.  If there was an error making
6027// the request the iterator does not advance and the error is returned.
6028func (iter *BgpServiceCommunityListResultIterator) Next() error {
6029	iter.i++
6030	if iter.i < len(iter.page.Values()) {
6031		return nil
6032	}
6033	err := iter.page.Next()
6034	if err != nil {
6035		iter.i--
6036		return err
6037	}
6038	iter.i = 0
6039	return nil
6040}
6041
6042// NotDone returns true if the enumeration should be started or is not yet complete.
6043func (iter BgpServiceCommunityListResultIterator) NotDone() bool {
6044	return iter.page.NotDone() && iter.i < len(iter.page.Values())
6045}
6046
6047// Response returns the raw server response from the last page request.
6048func (iter BgpServiceCommunityListResultIterator) Response() BgpServiceCommunityListResult {
6049	return iter.page.Response()
6050}
6051
6052// Value returns the current value or a zero-initialized value if the
6053// iterator has advanced beyond the end of the collection.
6054func (iter BgpServiceCommunityListResultIterator) Value() BgpServiceCommunity {
6055	if !iter.page.NotDone() {
6056		return BgpServiceCommunity{}
6057	}
6058	return iter.page.Values()[iter.i]
6059}
6060
6061// IsEmpty returns true if the ListResult contains no values.
6062func (bsclr BgpServiceCommunityListResult) IsEmpty() bool {
6063	return bsclr.Value == nil || len(*bsclr.Value) == 0
6064}
6065
6066// bgpServiceCommunityListResultPreparer prepares a request to retrieve the next set of results.
6067// It returns nil if no more results exist.
6068func (bsclr BgpServiceCommunityListResult) bgpServiceCommunityListResultPreparer() (*http.Request, error) {
6069	if bsclr.NextLink == nil || len(to.String(bsclr.NextLink)) < 1 {
6070		return nil, nil
6071	}
6072	return autorest.Prepare(&http.Request{},
6073		autorest.AsJSON(),
6074		autorest.AsGet(),
6075		autorest.WithBaseURL(to.String(bsclr.NextLink)))
6076}
6077
6078// BgpServiceCommunityListResultPage contains a page of BgpServiceCommunity values.
6079type BgpServiceCommunityListResultPage struct {
6080	fn    func(BgpServiceCommunityListResult) (BgpServiceCommunityListResult, error)
6081	bsclr BgpServiceCommunityListResult
6082}
6083
6084// Next advances to the next page of values.  If there was an error making
6085// the request the page does not advance and the error is returned.
6086func (page *BgpServiceCommunityListResultPage) Next() error {
6087	next, err := page.fn(page.bsclr)
6088	if err != nil {
6089		return err
6090	}
6091	page.bsclr = next
6092	return nil
6093}
6094
6095// NotDone returns true if the page enumeration should be started or is not yet complete.
6096func (page BgpServiceCommunityListResultPage) NotDone() bool {
6097	return !page.bsclr.IsEmpty()
6098}
6099
6100// Response returns the raw server response from the last page request.
6101func (page BgpServiceCommunityListResultPage) Response() BgpServiceCommunityListResult {
6102	return page.bsclr
6103}
6104
6105// Values returns the slice of values for the current page or nil if there are no values.
6106func (page BgpServiceCommunityListResultPage) Values() []BgpServiceCommunity {
6107	if page.bsclr.IsEmpty() {
6108		return nil
6109	}
6110	return *page.bsclr.Value
6111}
6112
6113// BgpServiceCommunityPropertiesFormat properties of Service Community.
6114type BgpServiceCommunityPropertiesFormat struct {
6115	// ServiceName - The name of the bgp community. e.g. Skype.
6116	ServiceName *string `json:"serviceName,omitempty"`
6117	// BgpCommunities - Get a list of bgp communities.
6118	BgpCommunities *[]BGPCommunity `json:"bgpCommunities,omitempty"`
6119}
6120
6121// BgpSettings BGP settings details
6122type BgpSettings struct {
6123	// Asn - The BGP speaker's ASN.
6124	Asn *int64 `json:"asn,omitempty"`
6125	// BgpPeeringAddress - The BGP peering address and BGP identifier of this BGP speaker.
6126	BgpPeeringAddress *string `json:"bgpPeeringAddress,omitempty"`
6127	// PeerWeight - The weight added to routes learned from this BGP speaker.
6128	PeerWeight *int32 `json:"peerWeight,omitempty"`
6129}
6130
6131// ConfigurationDiagnosticParameters parameters to get network configuration diagnostic.
6132type ConfigurationDiagnosticParameters struct {
6133	// TargetResourceID - The ID of the target resource to perform network configuration diagnostic. Valid options are VM, NetworkInterface, VMSS/NetworkInterface and Application Gateway.
6134	TargetResourceID *string `json:"targetResourceId,omitempty"`
6135	// Queries - List of traffic queries.
6136	Queries *[]TrafficQuery `json:"queries,omitempty"`
6137}
6138
6139// ConfigurationDiagnosticResponse results of network configuration diagnostic on the target resource.
6140type ConfigurationDiagnosticResponse struct {
6141	autorest.Response `json:"-"`
6142	// Results - List of network configuration diagnostic results.
6143	Results *[]ConfigurationDiagnosticResult `json:"results,omitempty"`
6144}
6145
6146// ConfigurationDiagnosticResult network configuration diagnostic result corresponded to provided traffic query.
6147type ConfigurationDiagnosticResult struct {
6148	TrafficQuery               *TrafficQuery        `json:"trafficQuery,omitempty"`
6149	NetworkSecurityGroupResult *SecurityGroupResult `json:"networkSecurityGroupResult,omitempty"`
6150}
6151
6152// ConnectionMonitor parameters that define the operation to create a connection monitor.
6153type ConnectionMonitor struct {
6154	// Location - Connection monitor location.
6155	Location *string `json:"location,omitempty"`
6156	// Tags - Connection monitor tags.
6157	Tags                         map[string]*string `json:"tags"`
6158	*ConnectionMonitorParameters `json:"properties,omitempty"`
6159}
6160
6161// MarshalJSON is the custom marshaler for ConnectionMonitor.
6162func (cm ConnectionMonitor) MarshalJSON() ([]byte, error) {
6163	objectMap := make(map[string]interface{})
6164	if cm.Location != nil {
6165		objectMap["location"] = cm.Location
6166	}
6167	if cm.Tags != nil {
6168		objectMap["tags"] = cm.Tags
6169	}
6170	if cm.ConnectionMonitorParameters != nil {
6171		objectMap["properties"] = cm.ConnectionMonitorParameters
6172	}
6173	return json.Marshal(objectMap)
6174}
6175
6176// UnmarshalJSON is the custom unmarshaler for ConnectionMonitor struct.
6177func (cm *ConnectionMonitor) UnmarshalJSON(body []byte) error {
6178	var m map[string]*json.RawMessage
6179	err := json.Unmarshal(body, &m)
6180	if err != nil {
6181		return err
6182	}
6183	for k, v := range m {
6184		switch k {
6185		case "location":
6186			if v != nil {
6187				var location string
6188				err = json.Unmarshal(*v, &location)
6189				if err != nil {
6190					return err
6191				}
6192				cm.Location = &location
6193			}
6194		case "tags":
6195			if v != nil {
6196				var tags map[string]*string
6197				err = json.Unmarshal(*v, &tags)
6198				if err != nil {
6199					return err
6200				}
6201				cm.Tags = tags
6202			}
6203		case "properties":
6204			if v != nil {
6205				var connectionMonitorParameters ConnectionMonitorParameters
6206				err = json.Unmarshal(*v, &connectionMonitorParameters)
6207				if err != nil {
6208					return err
6209				}
6210				cm.ConnectionMonitorParameters = &connectionMonitorParameters
6211			}
6212		}
6213	}
6214
6215	return nil
6216}
6217
6218// ConnectionMonitorDestination describes the destination of connection monitor.
6219type ConnectionMonitorDestination struct {
6220	// ResourceID - The ID of the resource used as the destination by connection monitor.
6221	ResourceID *string `json:"resourceId,omitempty"`
6222	// Address - Address of the connection monitor destination (IP or domain name).
6223	Address *string `json:"address,omitempty"`
6224	// Port - The destination port used by connection monitor.
6225	Port *int32 `json:"port,omitempty"`
6226}
6227
6228// ConnectionMonitorListResult list of connection monitors.
6229type ConnectionMonitorListResult struct {
6230	autorest.Response `json:"-"`
6231	// Value - Information about connection monitors.
6232	Value *[]ConnectionMonitorResult `json:"value,omitempty"`
6233}
6234
6235// ConnectionMonitorParameters parameters that define the operation to create a connection monitor.
6236type ConnectionMonitorParameters struct {
6237	Source      *ConnectionMonitorSource      `json:"source,omitempty"`
6238	Destination *ConnectionMonitorDestination `json:"destination,omitempty"`
6239	// AutoStart - Determines if the connection monitor will start automatically once created.
6240	AutoStart *bool `json:"autoStart,omitempty"`
6241	// MonitoringIntervalInSeconds - Monitoring interval in seconds.
6242	MonitoringIntervalInSeconds *int32 `json:"monitoringIntervalInSeconds,omitempty"`
6243}
6244
6245// ConnectionMonitorQueryResult list of connection states snaphots.
6246type ConnectionMonitorQueryResult struct {
6247	autorest.Response `json:"-"`
6248	// SourceStatus - Status of connection monitor source. Possible values include: 'Uknown', 'Active', 'Inactive'
6249	SourceStatus ConnectionMonitorSourceStatus `json:"sourceStatus,omitempty"`
6250	// States - Information about connection states.
6251	States *[]ConnectionStateSnapshot `json:"states,omitempty"`
6252}
6253
6254// ConnectionMonitorResult information about the connection monitor.
6255type ConnectionMonitorResult struct {
6256	autorest.Response `json:"-"`
6257	// Name - Name of the connection monitor.
6258	Name *string `json:"name,omitempty"`
6259	// ID - ID of the connection monitor.
6260	ID   *string `json:"id,omitempty"`
6261	Etag *string `json:"etag,omitempty"`
6262	// Type - Connection monitor type.
6263	Type *string `json:"type,omitempty"`
6264	// Location - Connection monitor location.
6265	Location *string `json:"location,omitempty"`
6266	// Tags - Connection monitor tags.
6267	Tags                               map[string]*string `json:"tags"`
6268	*ConnectionMonitorResultProperties `json:"properties,omitempty"`
6269}
6270
6271// MarshalJSON is the custom marshaler for ConnectionMonitorResult.
6272func (cmr ConnectionMonitorResult) MarshalJSON() ([]byte, error) {
6273	objectMap := make(map[string]interface{})
6274	if cmr.Name != nil {
6275		objectMap["name"] = cmr.Name
6276	}
6277	if cmr.ID != nil {
6278		objectMap["id"] = cmr.ID
6279	}
6280	if cmr.Etag != nil {
6281		objectMap["etag"] = cmr.Etag
6282	}
6283	if cmr.Type != nil {
6284		objectMap["type"] = cmr.Type
6285	}
6286	if cmr.Location != nil {
6287		objectMap["location"] = cmr.Location
6288	}
6289	if cmr.Tags != nil {
6290		objectMap["tags"] = cmr.Tags
6291	}
6292	if cmr.ConnectionMonitorResultProperties != nil {
6293		objectMap["properties"] = cmr.ConnectionMonitorResultProperties
6294	}
6295	return json.Marshal(objectMap)
6296}
6297
6298// UnmarshalJSON is the custom unmarshaler for ConnectionMonitorResult struct.
6299func (cmr *ConnectionMonitorResult) UnmarshalJSON(body []byte) error {
6300	var m map[string]*json.RawMessage
6301	err := json.Unmarshal(body, &m)
6302	if err != nil {
6303		return err
6304	}
6305	for k, v := range m {
6306		switch k {
6307		case "name":
6308			if v != nil {
6309				var name string
6310				err = json.Unmarshal(*v, &name)
6311				if err != nil {
6312					return err
6313				}
6314				cmr.Name = &name
6315			}
6316		case "id":
6317			if v != nil {
6318				var ID string
6319				err = json.Unmarshal(*v, &ID)
6320				if err != nil {
6321					return err
6322				}
6323				cmr.ID = &ID
6324			}
6325		case "etag":
6326			if v != nil {
6327				var etag string
6328				err = json.Unmarshal(*v, &etag)
6329				if err != nil {
6330					return err
6331				}
6332				cmr.Etag = &etag
6333			}
6334		case "type":
6335			if v != nil {
6336				var typeVar string
6337				err = json.Unmarshal(*v, &typeVar)
6338				if err != nil {
6339					return err
6340				}
6341				cmr.Type = &typeVar
6342			}
6343		case "location":
6344			if v != nil {
6345				var location string
6346				err = json.Unmarshal(*v, &location)
6347				if err != nil {
6348					return err
6349				}
6350				cmr.Location = &location
6351			}
6352		case "tags":
6353			if v != nil {
6354				var tags map[string]*string
6355				err = json.Unmarshal(*v, &tags)
6356				if err != nil {
6357					return err
6358				}
6359				cmr.Tags = tags
6360			}
6361		case "properties":
6362			if v != nil {
6363				var connectionMonitorResultProperties ConnectionMonitorResultProperties
6364				err = json.Unmarshal(*v, &connectionMonitorResultProperties)
6365				if err != nil {
6366					return err
6367				}
6368				cmr.ConnectionMonitorResultProperties = &connectionMonitorResultProperties
6369			}
6370		}
6371	}
6372
6373	return nil
6374}
6375
6376// ConnectionMonitorResultProperties describes the properties of a connection monitor.
6377type ConnectionMonitorResultProperties struct {
6378	// ProvisioningState - The provisioning state of the connection monitor. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
6379	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
6380	// StartTime - The date and time when the connection monitor was started.
6381	StartTime *date.Time `json:"startTime,omitempty"`
6382	// MonitoringStatus - The monitoring status of the connection monitor.
6383	MonitoringStatus *string                       `json:"monitoringStatus,omitempty"`
6384	Source           *ConnectionMonitorSource      `json:"source,omitempty"`
6385	Destination      *ConnectionMonitorDestination `json:"destination,omitempty"`
6386	// AutoStart - Determines if the connection monitor will start automatically once created.
6387	AutoStart *bool `json:"autoStart,omitempty"`
6388	// MonitoringIntervalInSeconds - Monitoring interval in seconds.
6389	MonitoringIntervalInSeconds *int32 `json:"monitoringIntervalInSeconds,omitempty"`
6390}
6391
6392// ConnectionMonitorsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
6393// long-running operation.
6394type ConnectionMonitorsCreateOrUpdateFuture struct {
6395	azure.Future
6396}
6397
6398// Result returns the result of the asynchronous operation.
6399// If the operation has not completed it will return an error.
6400func (future *ConnectionMonitorsCreateOrUpdateFuture) Result(client ConnectionMonitorsClient) (cmr ConnectionMonitorResult, err error) {
6401	var done bool
6402	done, err = future.Done(client)
6403	if err != nil {
6404		err = autorest.NewErrorWithError(err, "network.ConnectionMonitorsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
6405		return
6406	}
6407	if !done {
6408		err = azure.NewAsyncOpIncompleteError("network.ConnectionMonitorsCreateOrUpdateFuture")
6409		return
6410	}
6411	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
6412	if cmr.Response.Response, err = future.GetResult(sender); err == nil && cmr.Response.Response.StatusCode != http.StatusNoContent {
6413		cmr, err = client.CreateOrUpdateResponder(cmr.Response.Response)
6414		if err != nil {
6415			err = autorest.NewErrorWithError(err, "network.ConnectionMonitorsCreateOrUpdateFuture", "Result", cmr.Response.Response, "Failure responding to request")
6416		}
6417	}
6418	return
6419}
6420
6421// ConnectionMonitorsDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
6422// operation.
6423type ConnectionMonitorsDeleteFuture struct {
6424	azure.Future
6425}
6426
6427// Result returns the result of the asynchronous operation.
6428// If the operation has not completed it will return an error.
6429func (future *ConnectionMonitorsDeleteFuture) Result(client ConnectionMonitorsClient) (ar autorest.Response, err error) {
6430	var done bool
6431	done, err = future.Done(client)
6432	if err != nil {
6433		err = autorest.NewErrorWithError(err, "network.ConnectionMonitorsDeleteFuture", "Result", future.Response(), "Polling failure")
6434		return
6435	}
6436	if !done {
6437		err = azure.NewAsyncOpIncompleteError("network.ConnectionMonitorsDeleteFuture")
6438		return
6439	}
6440	ar.Response = future.Response()
6441	return
6442}
6443
6444// ConnectionMonitorSource describes the source of connection monitor.
6445type ConnectionMonitorSource struct {
6446	// ResourceID - The ID of the resource used as the source by connection monitor.
6447	ResourceID *string `json:"resourceId,omitempty"`
6448	// Port - The source port used by connection monitor.
6449	Port *int32 `json:"port,omitempty"`
6450}
6451
6452// ConnectionMonitorsQueryFuture an abstraction for monitoring and retrieving the results of a long-running
6453// operation.
6454type ConnectionMonitorsQueryFuture struct {
6455	azure.Future
6456}
6457
6458// Result returns the result of the asynchronous operation.
6459// If the operation has not completed it will return an error.
6460func (future *ConnectionMonitorsQueryFuture) Result(client ConnectionMonitorsClient) (cmqr ConnectionMonitorQueryResult, err error) {
6461	var done bool
6462	done, err = future.Done(client)
6463	if err != nil {
6464		err = autorest.NewErrorWithError(err, "network.ConnectionMonitorsQueryFuture", "Result", future.Response(), "Polling failure")
6465		return
6466	}
6467	if !done {
6468		err = azure.NewAsyncOpIncompleteError("network.ConnectionMonitorsQueryFuture")
6469		return
6470	}
6471	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
6472	if cmqr.Response.Response, err = future.GetResult(sender); err == nil && cmqr.Response.Response.StatusCode != http.StatusNoContent {
6473		cmqr, err = client.QueryResponder(cmqr.Response.Response)
6474		if err != nil {
6475			err = autorest.NewErrorWithError(err, "network.ConnectionMonitorsQueryFuture", "Result", cmqr.Response.Response, "Failure responding to request")
6476		}
6477	}
6478	return
6479}
6480
6481// ConnectionMonitorsStartFuture an abstraction for monitoring and retrieving the results of a long-running
6482// operation.
6483type ConnectionMonitorsStartFuture struct {
6484	azure.Future
6485}
6486
6487// Result returns the result of the asynchronous operation.
6488// If the operation has not completed it will return an error.
6489func (future *ConnectionMonitorsStartFuture) Result(client ConnectionMonitorsClient) (ar autorest.Response, err error) {
6490	var done bool
6491	done, err = future.Done(client)
6492	if err != nil {
6493		err = autorest.NewErrorWithError(err, "network.ConnectionMonitorsStartFuture", "Result", future.Response(), "Polling failure")
6494		return
6495	}
6496	if !done {
6497		err = azure.NewAsyncOpIncompleteError("network.ConnectionMonitorsStartFuture")
6498		return
6499	}
6500	ar.Response = future.Response()
6501	return
6502}
6503
6504// ConnectionMonitorsStopFuture an abstraction for monitoring and retrieving the results of a long-running
6505// operation.
6506type ConnectionMonitorsStopFuture struct {
6507	azure.Future
6508}
6509
6510// Result returns the result of the asynchronous operation.
6511// If the operation has not completed it will return an error.
6512func (future *ConnectionMonitorsStopFuture) Result(client ConnectionMonitorsClient) (ar autorest.Response, err error) {
6513	var done bool
6514	done, err = future.Done(client)
6515	if err != nil {
6516		err = autorest.NewErrorWithError(err, "network.ConnectionMonitorsStopFuture", "Result", future.Response(), "Polling failure")
6517		return
6518	}
6519	if !done {
6520		err = azure.NewAsyncOpIncompleteError("network.ConnectionMonitorsStopFuture")
6521		return
6522	}
6523	ar.Response = future.Response()
6524	return
6525}
6526
6527// ConnectionResetSharedKey the virtual network connection reset shared key
6528type ConnectionResetSharedKey struct {
6529	autorest.Response `json:"-"`
6530	// KeyLength - The virtual network connection reset shared key length, should between 1 and 128.
6531	KeyLength *int32 `json:"keyLength,omitempty"`
6532}
6533
6534// ConnectionSharedKey response for GetConnectionSharedKey API service call
6535type ConnectionSharedKey struct {
6536	autorest.Response `json:"-"`
6537	// Value - The virtual network connection shared key value.
6538	Value *string `json:"value,omitempty"`
6539	// ID - Resource ID.
6540	ID *string `json:"id,omitempty"`
6541}
6542
6543// ConnectionStateSnapshot connection state snapshot.
6544type ConnectionStateSnapshot struct {
6545	// ConnectionState - The connection state. Possible values include: 'ConnectionStateReachable', 'ConnectionStateUnreachable', 'ConnectionStateUnknown'
6546	ConnectionState ConnectionState `json:"connectionState,omitempty"`
6547	// StartTime - The start time of the connection snapshot.
6548	StartTime *date.Time `json:"startTime,omitempty"`
6549	// EndTime - The end time of the connection snapshot.
6550	EndTime *date.Time `json:"endTime,omitempty"`
6551	// EvaluationState - Connectivity analysis evaluation state. Possible values include: 'NotStarted', 'InProgress', 'Completed'
6552	EvaluationState EvaluationState `json:"evaluationState,omitempty"`
6553	// AvgLatencyInMs - Average latency in ms.
6554	AvgLatencyInMs *int32 `json:"avgLatencyInMs,omitempty"`
6555	// MinLatencyInMs - Minimum latency in ms.
6556	MinLatencyInMs *int32 `json:"minLatencyInMs,omitempty"`
6557	// MaxLatencyInMs - Maximum latency in ms.
6558	MaxLatencyInMs *int32 `json:"maxLatencyInMs,omitempty"`
6559	// ProbesSent - The number of sent probes.
6560	ProbesSent *int32 `json:"probesSent,omitempty"`
6561	// ProbesFailed - The number of failed probes.
6562	ProbesFailed *int32 `json:"probesFailed,omitempty"`
6563	// Hops - List of hops between the source and the destination.
6564	Hops *[]ConnectivityHop `json:"hops,omitempty"`
6565}
6566
6567// ConnectivityDestination parameters that define destination of connection.
6568type ConnectivityDestination struct {
6569	// ResourceID - The ID of the resource to which a connection attempt will be made.
6570	ResourceID *string `json:"resourceId,omitempty"`
6571	// Address - The IP address or URI the resource to which a connection attempt will be made.
6572	Address *string `json:"address,omitempty"`
6573	// Port - Port on which check connectivity will be performed.
6574	Port *int32 `json:"port,omitempty"`
6575}
6576
6577// ConnectivityHop information about a hop between the source and the destination.
6578type ConnectivityHop struct {
6579	// Type - The type of the hop.
6580	Type *string `json:"type,omitempty"`
6581	// ID - The ID of the hop.
6582	ID *string `json:"id,omitempty"`
6583	// Address - The IP address of the hop.
6584	Address *string `json:"address,omitempty"`
6585	// ResourceID - The ID of the resource corresponding to this hop.
6586	ResourceID *string `json:"resourceId,omitempty"`
6587	// NextHopIds - List of next hop identifiers.
6588	NextHopIds *[]string `json:"nextHopIds,omitempty"`
6589	// Issues - List of issues.
6590	Issues *[]ConnectivityIssue `json:"issues,omitempty"`
6591}
6592
6593// ConnectivityInformation information on the connectivity status.
6594type ConnectivityInformation struct {
6595	autorest.Response `json:"-"`
6596	// Hops - List of hops between the source and the destination.
6597	Hops *[]ConnectivityHop `json:"hops,omitempty"`
6598	// ConnectionStatus - The connection status. Possible values include: 'ConnectionStatusUnknown', 'ConnectionStatusConnected', 'ConnectionStatusDisconnected', 'ConnectionStatusDegraded'
6599	ConnectionStatus ConnectionStatus `json:"connectionStatus,omitempty"`
6600	// AvgLatencyInMs - Average latency in milliseconds.
6601	AvgLatencyInMs *int32 `json:"avgLatencyInMs,omitempty"`
6602	// MinLatencyInMs - Minimum latency in milliseconds.
6603	MinLatencyInMs *int32 `json:"minLatencyInMs,omitempty"`
6604	// MaxLatencyInMs - Maximum latency in milliseconds.
6605	MaxLatencyInMs *int32 `json:"maxLatencyInMs,omitempty"`
6606	// ProbesSent - Total number of probes sent.
6607	ProbesSent *int32 `json:"probesSent,omitempty"`
6608	// ProbesFailed - Number of failed probes.
6609	ProbesFailed *int32 `json:"probesFailed,omitempty"`
6610}
6611
6612// ConnectivityIssue information about an issue encountered in the process of checking for connectivity.
6613type ConnectivityIssue struct {
6614	// Origin - The origin of the issue. Possible values include: 'OriginLocal', 'OriginInbound', 'OriginOutbound'
6615	Origin Origin `json:"origin,omitempty"`
6616	// Severity - The severity of the issue. Possible values include: 'SeverityError', 'SeverityWarning'
6617	Severity Severity `json:"severity,omitempty"`
6618	// Type - The type of issue. Possible values include: 'IssueTypeUnknown', 'IssueTypeAgentStopped', 'IssueTypeGuestFirewall', 'IssueTypeDNSResolution', 'IssueTypeSocketBind', 'IssueTypeNetworkSecurityRule', 'IssueTypeUserDefinedRoute', 'IssueTypePortThrottled', 'IssueTypePlatform'
6619	Type IssueType `json:"type,omitempty"`
6620	// Context - Provides additional context on the issue.
6621	Context *[]map[string]*string `json:"context,omitempty"`
6622}
6623
6624// ConnectivityParameters parameters that determine how the connectivity check will be performed.
6625type ConnectivityParameters struct {
6626	Source      *ConnectivitySource      `json:"source,omitempty"`
6627	Destination *ConnectivityDestination `json:"destination,omitempty"`
6628	// Protocol - Network protocol. Possible values include: 'ProtocolTCP', 'ProtocolHTTP', 'ProtocolHTTPS', 'ProtocolIcmp'
6629	Protocol              Protocol               `json:"protocol,omitempty"`
6630	ProtocolConfiguration *ProtocolConfiguration `json:"protocolConfiguration,omitempty"`
6631}
6632
6633// ConnectivitySource parameters that define the source of the connection.
6634type ConnectivitySource struct {
6635	// ResourceID - The ID of the resource from which a connectivity check will be initiated.
6636	ResourceID *string `json:"resourceId,omitempty"`
6637	// Port - The source port from which a connectivity check will be performed.
6638	Port *int32 `json:"port,omitempty"`
6639}
6640
6641// Container reference to container resource in remote resource provider.
6642type Container struct {
6643	// ID - Resource ID.
6644	ID *string `json:"id,omitempty"`
6645}
6646
6647// ContainerNetworkInterface container network interface child resource.
6648type ContainerNetworkInterface struct {
6649	// ContainerNetworkInterfacePropertiesFormat - Container network interface properties.
6650	*ContainerNetworkInterfacePropertiesFormat `json:"properties,omitempty"`
6651	// Name - The name of the resource. This name can be used to access the resource.
6652	Name *string `json:"name,omitempty"`
6653	// Type - Sub Resource type.
6654	Type *string `json:"type,omitempty"`
6655	// Etag - A unique read-only string that changes whenever the resource is updated.
6656	Etag *string `json:"etag,omitempty"`
6657	// ID - Resource ID.
6658	ID *string `json:"id,omitempty"`
6659}
6660
6661// MarshalJSON is the custom marshaler for ContainerNetworkInterface.
6662func (cni ContainerNetworkInterface) MarshalJSON() ([]byte, error) {
6663	objectMap := make(map[string]interface{})
6664	if cni.ContainerNetworkInterfacePropertiesFormat != nil {
6665		objectMap["properties"] = cni.ContainerNetworkInterfacePropertiesFormat
6666	}
6667	if cni.Name != nil {
6668		objectMap["name"] = cni.Name
6669	}
6670	if cni.Type != nil {
6671		objectMap["type"] = cni.Type
6672	}
6673	if cni.Etag != nil {
6674		objectMap["etag"] = cni.Etag
6675	}
6676	if cni.ID != nil {
6677		objectMap["id"] = cni.ID
6678	}
6679	return json.Marshal(objectMap)
6680}
6681
6682// UnmarshalJSON is the custom unmarshaler for ContainerNetworkInterface struct.
6683func (cni *ContainerNetworkInterface) UnmarshalJSON(body []byte) error {
6684	var m map[string]*json.RawMessage
6685	err := json.Unmarshal(body, &m)
6686	if err != nil {
6687		return err
6688	}
6689	for k, v := range m {
6690		switch k {
6691		case "properties":
6692			if v != nil {
6693				var containerNetworkInterfacePropertiesFormat ContainerNetworkInterfacePropertiesFormat
6694				err = json.Unmarshal(*v, &containerNetworkInterfacePropertiesFormat)
6695				if err != nil {
6696					return err
6697				}
6698				cni.ContainerNetworkInterfacePropertiesFormat = &containerNetworkInterfacePropertiesFormat
6699			}
6700		case "name":
6701			if v != nil {
6702				var name string
6703				err = json.Unmarshal(*v, &name)
6704				if err != nil {
6705					return err
6706				}
6707				cni.Name = &name
6708			}
6709		case "type":
6710			if v != nil {
6711				var typeVar string
6712				err = json.Unmarshal(*v, &typeVar)
6713				if err != nil {
6714					return err
6715				}
6716				cni.Type = &typeVar
6717			}
6718		case "etag":
6719			if v != nil {
6720				var etag string
6721				err = json.Unmarshal(*v, &etag)
6722				if err != nil {
6723					return err
6724				}
6725				cni.Etag = &etag
6726			}
6727		case "id":
6728			if v != nil {
6729				var ID string
6730				err = json.Unmarshal(*v, &ID)
6731				if err != nil {
6732					return err
6733				}
6734				cni.ID = &ID
6735			}
6736		}
6737	}
6738
6739	return nil
6740}
6741
6742// ContainerNetworkInterfaceConfiguration container network interface configruation child resource.
6743type ContainerNetworkInterfaceConfiguration struct {
6744	// ContainerNetworkInterfaceConfigurationPropertiesFormat - Container network interface configuration properties.
6745	*ContainerNetworkInterfaceConfigurationPropertiesFormat `json:"properties,omitempty"`
6746	// Name - The name of the resource. This name can be used to access the resource.
6747	Name *string `json:"name,omitempty"`
6748	// Type - Sub Resource type.
6749	Type *string `json:"type,omitempty"`
6750	// Etag - A unique read-only string that changes whenever the resource is updated.
6751	Etag *string `json:"etag,omitempty"`
6752	// ID - Resource ID.
6753	ID *string `json:"id,omitempty"`
6754}
6755
6756// MarshalJSON is the custom marshaler for ContainerNetworkInterfaceConfiguration.
6757func (cnic ContainerNetworkInterfaceConfiguration) MarshalJSON() ([]byte, error) {
6758	objectMap := make(map[string]interface{})
6759	if cnic.ContainerNetworkInterfaceConfigurationPropertiesFormat != nil {
6760		objectMap["properties"] = cnic.ContainerNetworkInterfaceConfigurationPropertiesFormat
6761	}
6762	if cnic.Name != nil {
6763		objectMap["name"] = cnic.Name
6764	}
6765	if cnic.Type != nil {
6766		objectMap["type"] = cnic.Type
6767	}
6768	if cnic.Etag != nil {
6769		objectMap["etag"] = cnic.Etag
6770	}
6771	if cnic.ID != nil {
6772		objectMap["id"] = cnic.ID
6773	}
6774	return json.Marshal(objectMap)
6775}
6776
6777// UnmarshalJSON is the custom unmarshaler for ContainerNetworkInterfaceConfiguration struct.
6778func (cnic *ContainerNetworkInterfaceConfiguration) UnmarshalJSON(body []byte) error {
6779	var m map[string]*json.RawMessage
6780	err := json.Unmarshal(body, &m)
6781	if err != nil {
6782		return err
6783	}
6784	for k, v := range m {
6785		switch k {
6786		case "properties":
6787			if v != nil {
6788				var containerNetworkInterfaceConfigurationPropertiesFormat ContainerNetworkInterfaceConfigurationPropertiesFormat
6789				err = json.Unmarshal(*v, &containerNetworkInterfaceConfigurationPropertiesFormat)
6790				if err != nil {
6791					return err
6792				}
6793				cnic.ContainerNetworkInterfaceConfigurationPropertiesFormat = &containerNetworkInterfaceConfigurationPropertiesFormat
6794			}
6795		case "name":
6796			if v != nil {
6797				var name string
6798				err = json.Unmarshal(*v, &name)
6799				if err != nil {
6800					return err
6801				}
6802				cnic.Name = &name
6803			}
6804		case "type":
6805			if v != nil {
6806				var typeVar string
6807				err = json.Unmarshal(*v, &typeVar)
6808				if err != nil {
6809					return err
6810				}
6811				cnic.Type = &typeVar
6812			}
6813		case "etag":
6814			if v != nil {
6815				var etag string
6816				err = json.Unmarshal(*v, &etag)
6817				if err != nil {
6818					return err
6819				}
6820				cnic.Etag = &etag
6821			}
6822		case "id":
6823			if v != nil {
6824				var ID string
6825				err = json.Unmarshal(*v, &ID)
6826				if err != nil {
6827					return err
6828				}
6829				cnic.ID = &ID
6830			}
6831		}
6832	}
6833
6834	return nil
6835}
6836
6837// ContainerNetworkInterfaceConfigurationPropertiesFormat container network interface configuration properties.
6838type ContainerNetworkInterfaceConfigurationPropertiesFormat struct {
6839	// IPConfigurations - A list of ip configurations of the container network interface configuration.
6840	IPConfigurations *[]IPConfigurationProfile `json:"ipConfigurations,omitempty"`
6841	// ContainerNetworkInterfaces - A list of container network interfaces created from this container network interface configuration.
6842	ContainerNetworkInterfaces *[]ContainerNetworkInterface `json:"containerNetworkInterfaces,omitempty"`
6843	// ProvisioningState - The provisioning state of the resource.
6844	ProvisioningState *string `json:"provisioningState,omitempty"`
6845}
6846
6847// ContainerNetworkInterfaceIPConfiguration the ip configuration for a container network interface.
6848type ContainerNetworkInterfaceIPConfiguration struct {
6849	// ContainerNetworkInterfaceIPConfigurationPropertiesFormat - Properties of the container network interface IP configuration.
6850	*ContainerNetworkInterfaceIPConfigurationPropertiesFormat `json:"properties,omitempty"`
6851	// Name - The name of the resource. This name can be used to access the resource.
6852	Name *string `json:"name,omitempty"`
6853	// Type - Sub Resource type.
6854	Type *string `json:"type,omitempty"`
6855	// Etag - A unique read-only string that changes whenever the resource is updated.
6856	Etag *string `json:"etag,omitempty"`
6857}
6858
6859// MarshalJSON is the custom marshaler for ContainerNetworkInterfaceIPConfiguration.
6860func (cniic ContainerNetworkInterfaceIPConfiguration) MarshalJSON() ([]byte, error) {
6861	objectMap := make(map[string]interface{})
6862	if cniic.ContainerNetworkInterfaceIPConfigurationPropertiesFormat != nil {
6863		objectMap["properties"] = cniic.ContainerNetworkInterfaceIPConfigurationPropertiesFormat
6864	}
6865	if cniic.Name != nil {
6866		objectMap["name"] = cniic.Name
6867	}
6868	if cniic.Type != nil {
6869		objectMap["type"] = cniic.Type
6870	}
6871	if cniic.Etag != nil {
6872		objectMap["etag"] = cniic.Etag
6873	}
6874	return json.Marshal(objectMap)
6875}
6876
6877// UnmarshalJSON is the custom unmarshaler for ContainerNetworkInterfaceIPConfiguration struct.
6878func (cniic *ContainerNetworkInterfaceIPConfiguration) UnmarshalJSON(body []byte) error {
6879	var m map[string]*json.RawMessage
6880	err := json.Unmarshal(body, &m)
6881	if err != nil {
6882		return err
6883	}
6884	for k, v := range m {
6885		switch k {
6886		case "properties":
6887			if v != nil {
6888				var containerNetworkInterfaceIPConfigurationPropertiesFormat ContainerNetworkInterfaceIPConfigurationPropertiesFormat
6889				err = json.Unmarshal(*v, &containerNetworkInterfaceIPConfigurationPropertiesFormat)
6890				if err != nil {
6891					return err
6892				}
6893				cniic.ContainerNetworkInterfaceIPConfigurationPropertiesFormat = &containerNetworkInterfaceIPConfigurationPropertiesFormat
6894			}
6895		case "name":
6896			if v != nil {
6897				var name string
6898				err = json.Unmarshal(*v, &name)
6899				if err != nil {
6900					return err
6901				}
6902				cniic.Name = &name
6903			}
6904		case "type":
6905			if v != nil {
6906				var typeVar string
6907				err = json.Unmarshal(*v, &typeVar)
6908				if err != nil {
6909					return err
6910				}
6911				cniic.Type = &typeVar
6912			}
6913		case "etag":
6914			if v != nil {
6915				var etag string
6916				err = json.Unmarshal(*v, &etag)
6917				if err != nil {
6918					return err
6919				}
6920				cniic.Etag = &etag
6921			}
6922		}
6923	}
6924
6925	return nil
6926}
6927
6928// ContainerNetworkInterfaceIPConfigurationPropertiesFormat properties of the container network interface IP
6929// configuration.
6930type ContainerNetworkInterfaceIPConfigurationPropertiesFormat struct {
6931	// ProvisioningState - The provisioning state of the resource.
6932	ProvisioningState *string `json:"provisioningState,omitempty"`
6933}
6934
6935// ContainerNetworkInterfacePropertiesFormat ...
6936type ContainerNetworkInterfacePropertiesFormat struct {
6937	// ContainerNetworkInterfaceConfiguration - Container network interface configuration from which this container network interface is created.
6938	ContainerNetworkInterfaceConfiguration *ContainerNetworkInterfaceConfiguration `json:"containerNetworkInterfaceConfiguration,omitempty"`
6939	// Container - Reference to the conatinaer to which this container network interface is attached.
6940	Container *Container `json:"container,omitempty"`
6941	// IPConfigurations - Reference to the ip configuration on this container nic.
6942	IPConfigurations *[]ContainerNetworkInterfaceIPConfiguration `json:"ipConfigurations,omitempty"`
6943	// ProvisioningState - The provisioning state of the resource.
6944	ProvisioningState *string `json:"provisioningState,omitempty"`
6945}
6946
6947// DdosProtectionPlan a DDoS protection plan in a resource group.
6948type DdosProtectionPlan struct {
6949	autorest.Response `json:"-"`
6950	// ID - Resource ID.
6951	ID *string `json:"id,omitempty"`
6952	// Name - Resource name.
6953	Name *string `json:"name,omitempty"`
6954	// Type - Resource type.
6955	Type *string `json:"type,omitempty"`
6956	// Location - Resource location.
6957	Location *string `json:"location,omitempty"`
6958	// Tags - Resource tags.
6959	Tags map[string]*string `json:"tags"`
6960	// DdosProtectionPlanPropertiesFormat - Properties of the DDoS protection plan.
6961	*DdosProtectionPlanPropertiesFormat `json:"properties,omitempty"`
6962	// Etag - A unique read-only string that changes whenever the resource is updated.
6963	Etag *string `json:"etag,omitempty"`
6964}
6965
6966// MarshalJSON is the custom marshaler for DdosProtectionPlan.
6967func (dpp DdosProtectionPlan) MarshalJSON() ([]byte, error) {
6968	objectMap := make(map[string]interface{})
6969	if dpp.ID != nil {
6970		objectMap["id"] = dpp.ID
6971	}
6972	if dpp.Name != nil {
6973		objectMap["name"] = dpp.Name
6974	}
6975	if dpp.Type != nil {
6976		objectMap["type"] = dpp.Type
6977	}
6978	if dpp.Location != nil {
6979		objectMap["location"] = dpp.Location
6980	}
6981	if dpp.Tags != nil {
6982		objectMap["tags"] = dpp.Tags
6983	}
6984	if dpp.DdosProtectionPlanPropertiesFormat != nil {
6985		objectMap["properties"] = dpp.DdosProtectionPlanPropertiesFormat
6986	}
6987	if dpp.Etag != nil {
6988		objectMap["etag"] = dpp.Etag
6989	}
6990	return json.Marshal(objectMap)
6991}
6992
6993// UnmarshalJSON is the custom unmarshaler for DdosProtectionPlan struct.
6994func (dpp *DdosProtectionPlan) UnmarshalJSON(body []byte) error {
6995	var m map[string]*json.RawMessage
6996	err := json.Unmarshal(body, &m)
6997	if err != nil {
6998		return err
6999	}
7000	for k, v := range m {
7001		switch k {
7002		case "id":
7003			if v != nil {
7004				var ID string
7005				err = json.Unmarshal(*v, &ID)
7006				if err != nil {
7007					return err
7008				}
7009				dpp.ID = &ID
7010			}
7011		case "name":
7012			if v != nil {
7013				var name string
7014				err = json.Unmarshal(*v, &name)
7015				if err != nil {
7016					return err
7017				}
7018				dpp.Name = &name
7019			}
7020		case "type":
7021			if v != nil {
7022				var typeVar string
7023				err = json.Unmarshal(*v, &typeVar)
7024				if err != nil {
7025					return err
7026				}
7027				dpp.Type = &typeVar
7028			}
7029		case "location":
7030			if v != nil {
7031				var location string
7032				err = json.Unmarshal(*v, &location)
7033				if err != nil {
7034					return err
7035				}
7036				dpp.Location = &location
7037			}
7038		case "tags":
7039			if v != nil {
7040				var tags map[string]*string
7041				err = json.Unmarshal(*v, &tags)
7042				if err != nil {
7043					return err
7044				}
7045				dpp.Tags = tags
7046			}
7047		case "properties":
7048			if v != nil {
7049				var ddosProtectionPlanPropertiesFormat DdosProtectionPlanPropertiesFormat
7050				err = json.Unmarshal(*v, &ddosProtectionPlanPropertiesFormat)
7051				if err != nil {
7052					return err
7053				}
7054				dpp.DdosProtectionPlanPropertiesFormat = &ddosProtectionPlanPropertiesFormat
7055			}
7056		case "etag":
7057			if v != nil {
7058				var etag string
7059				err = json.Unmarshal(*v, &etag)
7060				if err != nil {
7061					return err
7062				}
7063				dpp.Etag = &etag
7064			}
7065		}
7066	}
7067
7068	return nil
7069}
7070
7071// DdosProtectionPlanListResult a list of DDoS protection plans.
7072type DdosProtectionPlanListResult struct {
7073	autorest.Response `json:"-"`
7074	// Value - A list of DDoS protection plans.
7075	Value *[]DdosProtectionPlan `json:"value,omitempty"`
7076	// NextLink - The URL to get the next set of results.
7077	NextLink *string `json:"nextLink,omitempty"`
7078}
7079
7080// DdosProtectionPlanListResultIterator provides access to a complete listing of DdosProtectionPlan values.
7081type DdosProtectionPlanListResultIterator struct {
7082	i    int
7083	page DdosProtectionPlanListResultPage
7084}
7085
7086// Next advances to the next value.  If there was an error making
7087// the request the iterator does not advance and the error is returned.
7088func (iter *DdosProtectionPlanListResultIterator) Next() error {
7089	iter.i++
7090	if iter.i < len(iter.page.Values()) {
7091		return nil
7092	}
7093	err := iter.page.Next()
7094	if err != nil {
7095		iter.i--
7096		return err
7097	}
7098	iter.i = 0
7099	return nil
7100}
7101
7102// NotDone returns true if the enumeration should be started or is not yet complete.
7103func (iter DdosProtectionPlanListResultIterator) NotDone() bool {
7104	return iter.page.NotDone() && iter.i < len(iter.page.Values())
7105}
7106
7107// Response returns the raw server response from the last page request.
7108func (iter DdosProtectionPlanListResultIterator) Response() DdosProtectionPlanListResult {
7109	return iter.page.Response()
7110}
7111
7112// Value returns the current value or a zero-initialized value if the
7113// iterator has advanced beyond the end of the collection.
7114func (iter DdosProtectionPlanListResultIterator) Value() DdosProtectionPlan {
7115	if !iter.page.NotDone() {
7116		return DdosProtectionPlan{}
7117	}
7118	return iter.page.Values()[iter.i]
7119}
7120
7121// IsEmpty returns true if the ListResult contains no values.
7122func (dpplr DdosProtectionPlanListResult) IsEmpty() bool {
7123	return dpplr.Value == nil || len(*dpplr.Value) == 0
7124}
7125
7126// ddosProtectionPlanListResultPreparer prepares a request to retrieve the next set of results.
7127// It returns nil if no more results exist.
7128func (dpplr DdosProtectionPlanListResult) ddosProtectionPlanListResultPreparer() (*http.Request, error) {
7129	if dpplr.NextLink == nil || len(to.String(dpplr.NextLink)) < 1 {
7130		return nil, nil
7131	}
7132	return autorest.Prepare(&http.Request{},
7133		autorest.AsJSON(),
7134		autorest.AsGet(),
7135		autorest.WithBaseURL(to.String(dpplr.NextLink)))
7136}
7137
7138// DdosProtectionPlanListResultPage contains a page of DdosProtectionPlan values.
7139type DdosProtectionPlanListResultPage struct {
7140	fn    func(DdosProtectionPlanListResult) (DdosProtectionPlanListResult, error)
7141	dpplr DdosProtectionPlanListResult
7142}
7143
7144// Next advances to the next page of values.  If there was an error making
7145// the request the page does not advance and the error is returned.
7146func (page *DdosProtectionPlanListResultPage) Next() error {
7147	next, err := page.fn(page.dpplr)
7148	if err != nil {
7149		return err
7150	}
7151	page.dpplr = next
7152	return nil
7153}
7154
7155// NotDone returns true if the page enumeration should be started or is not yet complete.
7156func (page DdosProtectionPlanListResultPage) NotDone() bool {
7157	return !page.dpplr.IsEmpty()
7158}
7159
7160// Response returns the raw server response from the last page request.
7161func (page DdosProtectionPlanListResultPage) Response() DdosProtectionPlanListResult {
7162	return page.dpplr
7163}
7164
7165// Values returns the slice of values for the current page or nil if there are no values.
7166func (page DdosProtectionPlanListResultPage) Values() []DdosProtectionPlan {
7167	if page.dpplr.IsEmpty() {
7168		return nil
7169	}
7170	return *page.dpplr.Value
7171}
7172
7173// DdosProtectionPlanPropertiesFormat dDoS protection plan properties.
7174type DdosProtectionPlanPropertiesFormat struct {
7175	// 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 resource groups.
7176	ResourceGUID *string `json:"resourceGuid,omitempty"`
7177	// ProvisioningState - The provisioning state of the DDoS protection plan resource. Possible values are: 'Succeeded', 'Updating', 'Deleting', and 'Failed'.
7178	ProvisioningState *string `json:"provisioningState,omitempty"`
7179	// VirtualNetworks - The list of virtual networks associated with the DDoS protection plan resource. This list is read-only.
7180	VirtualNetworks *[]SubResource `json:"virtualNetworks,omitempty"`
7181}
7182
7183// DdosProtectionPlansCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
7184// long-running operation.
7185type DdosProtectionPlansCreateOrUpdateFuture struct {
7186	azure.Future
7187}
7188
7189// Result returns the result of the asynchronous operation.
7190// If the operation has not completed it will return an error.
7191func (future *DdosProtectionPlansCreateOrUpdateFuture) Result(client DdosProtectionPlansClient) (dpp DdosProtectionPlan, err error) {
7192	var done bool
7193	done, err = future.Done(client)
7194	if err != nil {
7195		err = autorest.NewErrorWithError(err, "network.DdosProtectionPlansCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
7196		return
7197	}
7198	if !done {
7199		err = azure.NewAsyncOpIncompleteError("network.DdosProtectionPlansCreateOrUpdateFuture")
7200		return
7201	}
7202	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
7203	if dpp.Response.Response, err = future.GetResult(sender); err == nil && dpp.Response.Response.StatusCode != http.StatusNoContent {
7204		dpp, err = client.CreateOrUpdateResponder(dpp.Response.Response)
7205		if err != nil {
7206			err = autorest.NewErrorWithError(err, "network.DdosProtectionPlansCreateOrUpdateFuture", "Result", dpp.Response.Response, "Failure responding to request")
7207		}
7208	}
7209	return
7210}
7211
7212// DdosProtectionPlansDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
7213// operation.
7214type DdosProtectionPlansDeleteFuture struct {
7215	azure.Future
7216}
7217
7218// Result returns the result of the asynchronous operation.
7219// If the operation has not completed it will return an error.
7220func (future *DdosProtectionPlansDeleteFuture) Result(client DdosProtectionPlansClient) (ar autorest.Response, err error) {
7221	var done bool
7222	done, err = future.Done(client)
7223	if err != nil {
7224		err = autorest.NewErrorWithError(err, "network.DdosProtectionPlansDeleteFuture", "Result", future.Response(), "Polling failure")
7225		return
7226	}
7227	if !done {
7228		err = azure.NewAsyncOpIncompleteError("network.DdosProtectionPlansDeleteFuture")
7229		return
7230	}
7231	ar.Response = future.Response()
7232	return
7233}
7234
7235// Delegation details the service to which the subnet is delegated.
7236type Delegation struct {
7237	// ServiceDelegationPropertiesFormat - Properties of the subnet.
7238	*ServiceDelegationPropertiesFormat `json:"properties,omitempty"`
7239	// Name - The name of the resource that is unique within a subnet. This name can be used to access the resource.
7240	Name *string `json:"name,omitempty"`
7241	// Etag - A unique read-only string that changes whenever the resource is updated.
7242	Etag *string `json:"etag,omitempty"`
7243	// ID - Resource ID.
7244	ID *string `json:"id,omitempty"`
7245}
7246
7247// MarshalJSON is the custom marshaler for Delegation.
7248func (d Delegation) MarshalJSON() ([]byte, error) {
7249	objectMap := make(map[string]interface{})
7250	if d.ServiceDelegationPropertiesFormat != nil {
7251		objectMap["properties"] = d.ServiceDelegationPropertiesFormat
7252	}
7253	if d.Name != nil {
7254		objectMap["name"] = d.Name
7255	}
7256	if d.Etag != nil {
7257		objectMap["etag"] = d.Etag
7258	}
7259	if d.ID != nil {
7260		objectMap["id"] = d.ID
7261	}
7262	return json.Marshal(objectMap)
7263}
7264
7265// UnmarshalJSON is the custom unmarshaler for Delegation struct.
7266func (d *Delegation) UnmarshalJSON(body []byte) error {
7267	var m map[string]*json.RawMessage
7268	err := json.Unmarshal(body, &m)
7269	if err != nil {
7270		return err
7271	}
7272	for k, v := range m {
7273		switch k {
7274		case "properties":
7275			if v != nil {
7276				var serviceDelegationPropertiesFormat ServiceDelegationPropertiesFormat
7277				err = json.Unmarshal(*v, &serviceDelegationPropertiesFormat)
7278				if err != nil {
7279					return err
7280				}
7281				d.ServiceDelegationPropertiesFormat = &serviceDelegationPropertiesFormat
7282			}
7283		case "name":
7284			if v != nil {
7285				var name string
7286				err = json.Unmarshal(*v, &name)
7287				if err != nil {
7288					return err
7289				}
7290				d.Name = &name
7291			}
7292		case "etag":
7293			if v != nil {
7294				var etag string
7295				err = json.Unmarshal(*v, &etag)
7296				if err != nil {
7297					return err
7298				}
7299				d.Etag = &etag
7300			}
7301		case "id":
7302			if v != nil {
7303				var ID string
7304				err = json.Unmarshal(*v, &ID)
7305				if err != nil {
7306					return err
7307				}
7308				d.ID = &ID
7309			}
7310		}
7311	}
7312
7313	return nil
7314}
7315
7316// DeviceProperties list of properties of the device.
7317type DeviceProperties struct {
7318	// DeviceVendor - Name of the device Vendor.
7319	DeviceVendor *string `json:"deviceVendor,omitempty"`
7320	// DeviceModel - Model of the device.
7321	DeviceModel *string `json:"deviceModel,omitempty"`
7322	// LinkSpeedInMbps - Link speed.
7323	LinkSpeedInMbps *int32 `json:"linkSpeedInMbps,omitempty"`
7324}
7325
7326// DhcpOptions dhcpOptions contains an array of DNS servers available to VMs deployed in the virtual network.
7327// Standard DHCP option for a subnet overrides VNET DHCP options.
7328type DhcpOptions struct {
7329	// DNSServers - The list of DNS servers IP addresses.
7330	DNSServers *[]string `json:"dnsServers,omitempty"`
7331}
7332
7333// Dimension dimension of the metric.
7334type Dimension struct {
7335	// Name - The name of the dimension.
7336	Name *string `json:"name,omitempty"`
7337	// DisplayName - The display name of the dimension.
7338	DisplayName *string `json:"displayName,omitempty"`
7339	// InternalName - The internal name of the dimension.
7340	InternalName *string `json:"internalName,omitempty"`
7341}
7342
7343// DNSNameAvailabilityResult response for the CheckDnsNameAvailability API service call.
7344type DNSNameAvailabilityResult struct {
7345	autorest.Response `json:"-"`
7346	// Available - Domain availability (True/False).
7347	Available *bool `json:"available,omitempty"`
7348}
7349
7350// EffectiveNetworkSecurityGroup effective network security group.
7351type EffectiveNetworkSecurityGroup struct {
7352	// NetworkSecurityGroup - The ID of network security group that is applied.
7353	NetworkSecurityGroup *SubResource `json:"networkSecurityGroup,omitempty"`
7354	// Association - Associated resources.
7355	Association *EffectiveNetworkSecurityGroupAssociation `json:"association,omitempty"`
7356	// EffectiveSecurityRules - A collection of effective security rules.
7357	EffectiveSecurityRules *[]EffectiveNetworkSecurityRule `json:"effectiveSecurityRules,omitempty"`
7358	// TagMap - Mapping of tags to list of IP Addresses included within the tag.
7359	TagMap map[string][]string `json:"tagMap"`
7360}
7361
7362// MarshalJSON is the custom marshaler for EffectiveNetworkSecurityGroup.
7363func (ensg EffectiveNetworkSecurityGroup) MarshalJSON() ([]byte, error) {
7364	objectMap := make(map[string]interface{})
7365	if ensg.NetworkSecurityGroup != nil {
7366		objectMap["networkSecurityGroup"] = ensg.NetworkSecurityGroup
7367	}
7368	if ensg.Association != nil {
7369		objectMap["association"] = ensg.Association
7370	}
7371	if ensg.EffectiveSecurityRules != nil {
7372		objectMap["effectiveSecurityRules"] = ensg.EffectiveSecurityRules
7373	}
7374	if ensg.TagMap != nil {
7375		objectMap["tagMap"] = ensg.TagMap
7376	}
7377	return json.Marshal(objectMap)
7378}
7379
7380// EffectiveNetworkSecurityGroupAssociation the effective network security group association.
7381type EffectiveNetworkSecurityGroupAssociation struct {
7382	// Subnet - The ID of the subnet if assigned.
7383	Subnet *SubResource `json:"subnet,omitempty"`
7384	// NetworkInterface - The ID of the network interface if assigned.
7385	NetworkInterface *SubResource `json:"networkInterface,omitempty"`
7386}
7387
7388// EffectiveNetworkSecurityGroupListResult response for list effective network security groups API service call.
7389type EffectiveNetworkSecurityGroupListResult struct {
7390	autorest.Response `json:"-"`
7391	// Value - A list of effective network security groups.
7392	Value *[]EffectiveNetworkSecurityGroup `json:"value,omitempty"`
7393	// NextLink - The URL to get the next set of results.
7394	NextLink *string `json:"nextLink,omitempty"`
7395}
7396
7397// EffectiveNetworkSecurityRule effective network security rules.
7398type EffectiveNetworkSecurityRule struct {
7399	// Name - The name of the security rule specified by the user (if created by the user).
7400	Name *string `json:"name,omitempty"`
7401	// Protocol - The network protocol this rule applies to. Possible values are: 'Tcp', 'Udp', and 'All'. Possible values include: 'EffectiveSecurityRuleProtocolTCP', 'EffectiveSecurityRuleProtocolUDP', 'EffectiveSecurityRuleProtocolAll'
7402	Protocol EffectiveSecurityRuleProtocol `json:"protocol,omitempty"`
7403	// SourcePortRange - The source port or range.
7404	SourcePortRange *string `json:"sourcePortRange,omitempty"`
7405	// DestinationPortRange - The destination port or range.
7406	DestinationPortRange *string `json:"destinationPortRange,omitempty"`
7407	// SourcePortRanges - The source port ranges. Expected values include a single integer between 0 and 65535, a range using '-' as seperator (e.g. 100-400), or an asterix (*)
7408	SourcePortRanges *[]string `json:"sourcePortRanges,omitempty"`
7409	// DestinationPortRanges - The destination port ranges. Expected values include a single integer between 0 and 65535, a range using '-' as seperator (e.g. 100-400), or an asterix (*)
7410	DestinationPortRanges *[]string `json:"destinationPortRanges,omitempty"`
7411	// SourceAddressPrefix - The source address prefix.
7412	SourceAddressPrefix *string `json:"sourceAddressPrefix,omitempty"`
7413	// DestinationAddressPrefix - The destination address prefix.
7414	DestinationAddressPrefix *string `json:"destinationAddressPrefix,omitempty"`
7415	// SourceAddressPrefixes - The source address prefixes. Expected values include CIDR IP ranges, Default Tags (VirtualNetwork, AureLoadBalancer, Internet), System Tags, and the asterix (*).
7416	SourceAddressPrefixes *[]string `json:"sourceAddressPrefixes,omitempty"`
7417	// DestinationAddressPrefixes - The destination address prefixes. Expected values include CIDR IP ranges, Default Tags (VirtualNetwork, AureLoadBalancer, Internet), System Tags, and the asterix (*).
7418	DestinationAddressPrefixes *[]string `json:"destinationAddressPrefixes,omitempty"`
7419	// ExpandedSourceAddressPrefix - The expanded source address prefix.
7420	ExpandedSourceAddressPrefix *[]string `json:"expandedSourceAddressPrefix,omitempty"`
7421	// ExpandedDestinationAddressPrefix - Expanded destination address prefix.
7422	ExpandedDestinationAddressPrefix *[]string `json:"expandedDestinationAddressPrefix,omitempty"`
7423	// Access - Whether network traffic is allowed or denied. Possible values are: 'Allow' and 'Deny'. Possible values include: 'SecurityRuleAccessAllow', 'SecurityRuleAccessDeny'
7424	Access SecurityRuleAccess `json:"access,omitempty"`
7425	// Priority - The priority of the rule.
7426	Priority *int32 `json:"priority,omitempty"`
7427	// Direction - The direction of the rule. Possible values are: 'Inbound and Outbound'. Possible values include: 'SecurityRuleDirectionInbound', 'SecurityRuleDirectionOutbound'
7428	Direction SecurityRuleDirection `json:"direction,omitempty"`
7429}
7430
7431// EffectiveRoute effective Route
7432type EffectiveRoute struct {
7433	// Name - The name of the user defined route. This is optional.
7434	Name *string `json:"name,omitempty"`
7435	// Source - Who created the route. Possible values are: 'Unknown', 'User', 'VirtualNetworkGateway', and 'Default'. Possible values include: 'EffectiveRouteSourceUnknown', 'EffectiveRouteSourceUser', 'EffectiveRouteSourceVirtualNetworkGateway', 'EffectiveRouteSourceDefault'
7436	Source EffectiveRouteSource `json:"source,omitempty"`
7437	// State - The value of effective route. Possible values are: 'Active' and 'Invalid'. Possible values include: 'EffectiveRouteStateActive', 'EffectiveRouteStateInvalid'
7438	State EffectiveRouteState `json:"state,omitempty"`
7439	// AddressPrefix - The address prefixes of the effective routes in CIDR notation.
7440	AddressPrefix *[]string `json:"addressPrefix,omitempty"`
7441	// NextHopIPAddress - The IP address of the next hop of the effective route.
7442	NextHopIPAddress *[]string `json:"nextHopIpAddress,omitempty"`
7443	// NextHopType - The type of Azure hop the packet should be sent to. Possible values are: 'VirtualNetworkGateway', 'VnetLocal', 'Internet', 'VirtualAppliance', and 'None'. Possible values include: 'RouteNextHopTypeVirtualNetworkGateway', 'RouteNextHopTypeVnetLocal', 'RouteNextHopTypeInternet', 'RouteNextHopTypeVirtualAppliance', 'RouteNextHopTypeNone'
7444	NextHopType RouteNextHopType `json:"nextHopType,omitempty"`
7445}
7446
7447// EffectiveRouteListResult response for list effective route API service call.
7448type EffectiveRouteListResult struct {
7449	autorest.Response `json:"-"`
7450	// Value - A list of effective routes.
7451	Value *[]EffectiveRoute `json:"value,omitempty"`
7452	// NextLink - The URL to get the next set of results.
7453	NextLink *string `json:"nextLink,omitempty"`
7454}
7455
7456// EndpointService identifies the service being brought into the virtual network.
7457type EndpointService struct {
7458	// ID - A unique identifier of the service being referenced by the interface endpoint.
7459	ID *string `json:"id,omitempty"`
7460}
7461
7462// EndpointServiceResult endpoint service.
7463type EndpointServiceResult struct {
7464	// Name - Name of the endpoint service.
7465	Name *string `json:"name,omitempty"`
7466	// Type - Type of the endpoint service.
7467	Type *string `json:"type,omitempty"`
7468	// ID - Resource ID.
7469	ID *string `json:"id,omitempty"`
7470}
7471
7472// EndpointServicesListResult response for the ListAvailableEndpointServices API service call.
7473type EndpointServicesListResult struct {
7474	autorest.Response `json:"-"`
7475	// Value - List of available endpoint services in a region.
7476	Value *[]EndpointServiceResult `json:"value,omitempty"`
7477	// NextLink - The URL to get the next set of results.
7478	NextLink *string `json:"nextLink,omitempty"`
7479}
7480
7481// EndpointServicesListResultIterator provides access to a complete listing of EndpointServiceResult values.
7482type EndpointServicesListResultIterator struct {
7483	i    int
7484	page EndpointServicesListResultPage
7485}
7486
7487// Next advances to the next value.  If there was an error making
7488// the request the iterator does not advance and the error is returned.
7489func (iter *EndpointServicesListResultIterator) Next() error {
7490	iter.i++
7491	if iter.i < len(iter.page.Values()) {
7492		return nil
7493	}
7494	err := iter.page.Next()
7495	if err != nil {
7496		iter.i--
7497		return err
7498	}
7499	iter.i = 0
7500	return nil
7501}
7502
7503// NotDone returns true if the enumeration should be started or is not yet complete.
7504func (iter EndpointServicesListResultIterator) NotDone() bool {
7505	return iter.page.NotDone() && iter.i < len(iter.page.Values())
7506}
7507
7508// Response returns the raw server response from the last page request.
7509func (iter EndpointServicesListResultIterator) Response() EndpointServicesListResult {
7510	return iter.page.Response()
7511}
7512
7513// Value returns the current value or a zero-initialized value if the
7514// iterator has advanced beyond the end of the collection.
7515func (iter EndpointServicesListResultIterator) Value() EndpointServiceResult {
7516	if !iter.page.NotDone() {
7517		return EndpointServiceResult{}
7518	}
7519	return iter.page.Values()[iter.i]
7520}
7521
7522// IsEmpty returns true if the ListResult contains no values.
7523func (eslr EndpointServicesListResult) IsEmpty() bool {
7524	return eslr.Value == nil || len(*eslr.Value) == 0
7525}
7526
7527// endpointServicesListResultPreparer prepares a request to retrieve the next set of results.
7528// It returns nil if no more results exist.
7529func (eslr EndpointServicesListResult) endpointServicesListResultPreparer() (*http.Request, error) {
7530	if eslr.NextLink == nil || len(to.String(eslr.NextLink)) < 1 {
7531		return nil, nil
7532	}
7533	return autorest.Prepare(&http.Request{},
7534		autorest.AsJSON(),
7535		autorest.AsGet(),
7536		autorest.WithBaseURL(to.String(eslr.NextLink)))
7537}
7538
7539// EndpointServicesListResultPage contains a page of EndpointServiceResult values.
7540type EndpointServicesListResultPage struct {
7541	fn   func(EndpointServicesListResult) (EndpointServicesListResult, error)
7542	eslr EndpointServicesListResult
7543}
7544
7545// Next advances to the next page of values.  If there was an error making
7546// the request the page does not advance and the error is returned.
7547func (page *EndpointServicesListResultPage) Next() error {
7548	next, err := page.fn(page.eslr)
7549	if err != nil {
7550		return err
7551	}
7552	page.eslr = next
7553	return nil
7554}
7555
7556// NotDone returns true if the page enumeration should be started or is not yet complete.
7557func (page EndpointServicesListResultPage) NotDone() bool {
7558	return !page.eslr.IsEmpty()
7559}
7560
7561// Response returns the raw server response from the last page request.
7562func (page EndpointServicesListResultPage) Response() EndpointServicesListResult {
7563	return page.eslr
7564}
7565
7566// Values returns the slice of values for the current page or nil if there are no values.
7567func (page EndpointServicesListResultPage) Values() []EndpointServiceResult {
7568	if page.eslr.IsEmpty() {
7569		return nil
7570	}
7571	return *page.eslr.Value
7572}
7573
7574// Error ...
7575type Error struct {
7576	Code       *string         `json:"code,omitempty"`
7577	Message    *string         `json:"message,omitempty"`
7578	Target     *string         `json:"target,omitempty"`
7579	Details    *[]ErrorDetails `json:"details,omitempty"`
7580	InnerError *string         `json:"innerError,omitempty"`
7581}
7582
7583// ErrorDetails ...
7584type ErrorDetails struct {
7585	Code    *string `json:"code,omitempty"`
7586	Target  *string `json:"target,omitempty"`
7587	Message *string `json:"message,omitempty"`
7588}
7589
7590// ErrorResponse the error object.
7591type ErrorResponse struct {
7592	Error *ErrorDetails `json:"error,omitempty"`
7593}
7594
7595// EvaluatedNetworkSecurityGroup results of network security group evaluation.
7596type EvaluatedNetworkSecurityGroup struct {
7597	// NetworkSecurityGroupID - Network security group ID.
7598	NetworkSecurityGroupID *string      `json:"networkSecurityGroupId,omitempty"`
7599	MatchedRule            *MatchedRule `json:"matchedRule,omitempty"`
7600	// RulesEvaluationResult - List of network security rules evaluation results.
7601	RulesEvaluationResult *[]SecurityRulesEvaluationResult `json:"rulesEvaluationResult,omitempty"`
7602}
7603
7604// ExpressRouteCircuit expressRouteCircuit resource
7605type ExpressRouteCircuit struct {
7606	autorest.Response `json:"-"`
7607	// Sku - The SKU.
7608	Sku                                  *ExpressRouteCircuitSku `json:"sku,omitempty"`
7609	*ExpressRouteCircuitPropertiesFormat `json:"properties,omitempty"`
7610	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
7611	Etag *string `json:"etag,omitempty"`
7612	// ID - Resource ID.
7613	ID *string `json:"id,omitempty"`
7614	// Name - Resource name.
7615	Name *string `json:"name,omitempty"`
7616	// Type - Resource type.
7617	Type *string `json:"type,omitempty"`
7618	// Location - Resource location.
7619	Location *string `json:"location,omitempty"`
7620	// Tags - Resource tags.
7621	Tags map[string]*string `json:"tags"`
7622}
7623
7624// MarshalJSON is the custom marshaler for ExpressRouteCircuit.
7625func (erc ExpressRouteCircuit) MarshalJSON() ([]byte, error) {
7626	objectMap := make(map[string]interface{})
7627	if erc.Sku != nil {
7628		objectMap["sku"] = erc.Sku
7629	}
7630	if erc.ExpressRouteCircuitPropertiesFormat != nil {
7631		objectMap["properties"] = erc.ExpressRouteCircuitPropertiesFormat
7632	}
7633	if erc.Etag != nil {
7634		objectMap["etag"] = erc.Etag
7635	}
7636	if erc.ID != nil {
7637		objectMap["id"] = erc.ID
7638	}
7639	if erc.Name != nil {
7640		objectMap["name"] = erc.Name
7641	}
7642	if erc.Type != nil {
7643		objectMap["type"] = erc.Type
7644	}
7645	if erc.Location != nil {
7646		objectMap["location"] = erc.Location
7647	}
7648	if erc.Tags != nil {
7649		objectMap["tags"] = erc.Tags
7650	}
7651	return json.Marshal(objectMap)
7652}
7653
7654// UnmarshalJSON is the custom unmarshaler for ExpressRouteCircuit struct.
7655func (erc *ExpressRouteCircuit) UnmarshalJSON(body []byte) error {
7656	var m map[string]*json.RawMessage
7657	err := json.Unmarshal(body, &m)
7658	if err != nil {
7659		return err
7660	}
7661	for k, v := range m {
7662		switch k {
7663		case "sku":
7664			if v != nil {
7665				var sku ExpressRouteCircuitSku
7666				err = json.Unmarshal(*v, &sku)
7667				if err != nil {
7668					return err
7669				}
7670				erc.Sku = &sku
7671			}
7672		case "properties":
7673			if v != nil {
7674				var expressRouteCircuitPropertiesFormat ExpressRouteCircuitPropertiesFormat
7675				err = json.Unmarshal(*v, &expressRouteCircuitPropertiesFormat)
7676				if err != nil {
7677					return err
7678				}
7679				erc.ExpressRouteCircuitPropertiesFormat = &expressRouteCircuitPropertiesFormat
7680			}
7681		case "etag":
7682			if v != nil {
7683				var etag string
7684				err = json.Unmarshal(*v, &etag)
7685				if err != nil {
7686					return err
7687				}
7688				erc.Etag = &etag
7689			}
7690		case "id":
7691			if v != nil {
7692				var ID string
7693				err = json.Unmarshal(*v, &ID)
7694				if err != nil {
7695					return err
7696				}
7697				erc.ID = &ID
7698			}
7699		case "name":
7700			if v != nil {
7701				var name string
7702				err = json.Unmarshal(*v, &name)
7703				if err != nil {
7704					return err
7705				}
7706				erc.Name = &name
7707			}
7708		case "type":
7709			if v != nil {
7710				var typeVar string
7711				err = json.Unmarshal(*v, &typeVar)
7712				if err != nil {
7713					return err
7714				}
7715				erc.Type = &typeVar
7716			}
7717		case "location":
7718			if v != nil {
7719				var location string
7720				err = json.Unmarshal(*v, &location)
7721				if err != nil {
7722					return err
7723				}
7724				erc.Location = &location
7725			}
7726		case "tags":
7727			if v != nil {
7728				var tags map[string]*string
7729				err = json.Unmarshal(*v, &tags)
7730				if err != nil {
7731					return err
7732				}
7733				erc.Tags = tags
7734			}
7735		}
7736	}
7737
7738	return nil
7739}
7740
7741// ExpressRouteCircuitArpTable the ARP table associated with the ExpressRouteCircuit.
7742type ExpressRouteCircuitArpTable struct {
7743	// Age - Entry age in minutes
7744	Age *int32 `json:"age,omitempty"`
7745	// Interface - Interface address
7746	Interface *string `json:"interface,omitempty"`
7747	// IPAddress - The IP address.
7748	IPAddress *string `json:"ipAddress,omitempty"`
7749	// MacAddress - The MAC address.
7750	MacAddress *string `json:"macAddress,omitempty"`
7751}
7752
7753// ExpressRouteCircuitAuthorization authorization in an ExpressRouteCircuit resource.
7754type ExpressRouteCircuitAuthorization struct {
7755	autorest.Response              `json:"-"`
7756	*AuthorizationPropertiesFormat `json:"properties,omitempty"`
7757	// Name - Gets name of the resource that is unique within a resource group. This name can be used to access the resource.
7758	Name *string `json:"name,omitempty"`
7759	// Etag - A unique read-only string that changes whenever the resource is updated.
7760	Etag *string `json:"etag,omitempty"`
7761	// ID - Resource ID.
7762	ID *string `json:"id,omitempty"`
7763}
7764
7765// MarshalJSON is the custom marshaler for ExpressRouteCircuitAuthorization.
7766func (erca ExpressRouteCircuitAuthorization) MarshalJSON() ([]byte, error) {
7767	objectMap := make(map[string]interface{})
7768	if erca.AuthorizationPropertiesFormat != nil {
7769		objectMap["properties"] = erca.AuthorizationPropertiesFormat
7770	}
7771	if erca.Name != nil {
7772		objectMap["name"] = erca.Name
7773	}
7774	if erca.Etag != nil {
7775		objectMap["etag"] = erca.Etag
7776	}
7777	if erca.ID != nil {
7778		objectMap["id"] = erca.ID
7779	}
7780	return json.Marshal(objectMap)
7781}
7782
7783// UnmarshalJSON is the custom unmarshaler for ExpressRouteCircuitAuthorization struct.
7784func (erca *ExpressRouteCircuitAuthorization) UnmarshalJSON(body []byte) error {
7785	var m map[string]*json.RawMessage
7786	err := json.Unmarshal(body, &m)
7787	if err != nil {
7788		return err
7789	}
7790	for k, v := range m {
7791		switch k {
7792		case "properties":
7793			if v != nil {
7794				var authorizationPropertiesFormat AuthorizationPropertiesFormat
7795				err = json.Unmarshal(*v, &authorizationPropertiesFormat)
7796				if err != nil {
7797					return err
7798				}
7799				erca.AuthorizationPropertiesFormat = &authorizationPropertiesFormat
7800			}
7801		case "name":
7802			if v != nil {
7803				var name string
7804				err = json.Unmarshal(*v, &name)
7805				if err != nil {
7806					return err
7807				}
7808				erca.Name = &name
7809			}
7810		case "etag":
7811			if v != nil {
7812				var etag string
7813				err = json.Unmarshal(*v, &etag)
7814				if err != nil {
7815					return err
7816				}
7817				erca.Etag = &etag
7818			}
7819		case "id":
7820			if v != nil {
7821				var ID string
7822				err = json.Unmarshal(*v, &ID)
7823				if err != nil {
7824					return err
7825				}
7826				erca.ID = &ID
7827			}
7828		}
7829	}
7830
7831	return nil
7832}
7833
7834// ExpressRouteCircuitAuthorizationsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results
7835// of a long-running operation.
7836type ExpressRouteCircuitAuthorizationsCreateOrUpdateFuture struct {
7837	azure.Future
7838}
7839
7840// Result returns the result of the asynchronous operation.
7841// If the operation has not completed it will return an error.
7842func (future *ExpressRouteCircuitAuthorizationsCreateOrUpdateFuture) Result(client ExpressRouteCircuitAuthorizationsClient) (erca ExpressRouteCircuitAuthorization, err error) {
7843	var done bool
7844	done, err = future.Done(client)
7845	if err != nil {
7846		err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitAuthorizationsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
7847		return
7848	}
7849	if !done {
7850		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitAuthorizationsCreateOrUpdateFuture")
7851		return
7852	}
7853	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
7854	if erca.Response.Response, err = future.GetResult(sender); err == nil && erca.Response.Response.StatusCode != http.StatusNoContent {
7855		erca, err = client.CreateOrUpdateResponder(erca.Response.Response)
7856		if err != nil {
7857			err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitAuthorizationsCreateOrUpdateFuture", "Result", erca.Response.Response, "Failure responding to request")
7858		}
7859	}
7860	return
7861}
7862
7863// ExpressRouteCircuitAuthorizationsDeleteFuture an abstraction for monitoring and retrieving the results of a
7864// long-running operation.
7865type ExpressRouteCircuitAuthorizationsDeleteFuture struct {
7866	azure.Future
7867}
7868
7869// Result returns the result of the asynchronous operation.
7870// If the operation has not completed it will return an error.
7871func (future *ExpressRouteCircuitAuthorizationsDeleteFuture) Result(client ExpressRouteCircuitAuthorizationsClient) (ar autorest.Response, err error) {
7872	var done bool
7873	done, err = future.Done(client)
7874	if err != nil {
7875		err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitAuthorizationsDeleteFuture", "Result", future.Response(), "Polling failure")
7876		return
7877	}
7878	if !done {
7879		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitAuthorizationsDeleteFuture")
7880		return
7881	}
7882	ar.Response = future.Response()
7883	return
7884}
7885
7886// ExpressRouteCircuitConnection express Route Circuit Connection in an ExpressRouteCircuitPeering resource.
7887type ExpressRouteCircuitConnection struct {
7888	autorest.Response                              `json:"-"`
7889	*ExpressRouteCircuitConnectionPropertiesFormat `json:"properties,omitempty"`
7890	// Name - Gets name of the resource that is unique within a resource group. This name can be used to access the resource.
7891	Name *string `json:"name,omitempty"`
7892	// Etag - A unique read-only string that changes whenever the resource is updated.
7893	Etag *string `json:"etag,omitempty"`
7894	// ID - Resource ID.
7895	ID *string `json:"id,omitempty"`
7896}
7897
7898// MarshalJSON is the custom marshaler for ExpressRouteCircuitConnection.
7899func (ercc ExpressRouteCircuitConnection) MarshalJSON() ([]byte, error) {
7900	objectMap := make(map[string]interface{})
7901	if ercc.ExpressRouteCircuitConnectionPropertiesFormat != nil {
7902		objectMap["properties"] = ercc.ExpressRouteCircuitConnectionPropertiesFormat
7903	}
7904	if ercc.Name != nil {
7905		objectMap["name"] = ercc.Name
7906	}
7907	if ercc.Etag != nil {
7908		objectMap["etag"] = ercc.Etag
7909	}
7910	if ercc.ID != nil {
7911		objectMap["id"] = ercc.ID
7912	}
7913	return json.Marshal(objectMap)
7914}
7915
7916// UnmarshalJSON is the custom unmarshaler for ExpressRouteCircuitConnection struct.
7917func (ercc *ExpressRouteCircuitConnection) UnmarshalJSON(body []byte) error {
7918	var m map[string]*json.RawMessage
7919	err := json.Unmarshal(body, &m)
7920	if err != nil {
7921		return err
7922	}
7923	for k, v := range m {
7924		switch k {
7925		case "properties":
7926			if v != nil {
7927				var expressRouteCircuitConnectionPropertiesFormat ExpressRouteCircuitConnectionPropertiesFormat
7928				err = json.Unmarshal(*v, &expressRouteCircuitConnectionPropertiesFormat)
7929				if err != nil {
7930					return err
7931				}
7932				ercc.ExpressRouteCircuitConnectionPropertiesFormat = &expressRouteCircuitConnectionPropertiesFormat
7933			}
7934		case "name":
7935			if v != nil {
7936				var name string
7937				err = json.Unmarshal(*v, &name)
7938				if err != nil {
7939					return err
7940				}
7941				ercc.Name = &name
7942			}
7943		case "etag":
7944			if v != nil {
7945				var etag string
7946				err = json.Unmarshal(*v, &etag)
7947				if err != nil {
7948					return err
7949				}
7950				ercc.Etag = &etag
7951			}
7952		case "id":
7953			if v != nil {
7954				var ID string
7955				err = json.Unmarshal(*v, &ID)
7956				if err != nil {
7957					return err
7958				}
7959				ercc.ID = &ID
7960			}
7961		}
7962	}
7963
7964	return nil
7965}
7966
7967// ExpressRouteCircuitConnectionPropertiesFormat ...
7968type ExpressRouteCircuitConnectionPropertiesFormat struct {
7969	// ExpressRouteCircuitPeering - Reference to Express Route Circuit Private Peering Resource of the circuit initiating connection.
7970	ExpressRouteCircuitPeering *SubResource `json:"expressRouteCircuitPeering,omitempty"`
7971	// PeerExpressRouteCircuitPeering - Reference to Express Route Circuit Private Peering Resource of the peered circuit.
7972	PeerExpressRouteCircuitPeering *SubResource `json:"peerExpressRouteCircuitPeering,omitempty"`
7973	// AddressPrefix - /29 IP address space to carve out Customer addresses for tunnels.
7974	AddressPrefix *string `json:"addressPrefix,omitempty"`
7975	// AuthorizationKey - The authorization key.
7976	AuthorizationKey *string `json:"authorizationKey,omitempty"`
7977	// CircuitConnectionStatus - Express Route Circuit Connection State. Possible values are: 'Connected' and 'Disconnected'. Possible values include: 'Connected', 'Connecting', 'Disconnected'
7978	CircuitConnectionStatus CircuitConnectionStatus `json:"circuitConnectionStatus,omitempty"`
7979	// ProvisioningState - Provisioning state of the circuit connection resource. Possible values are: 'Succeded', 'Updating', 'Deleting', and 'Failed'.
7980	ProvisioningState *string `json:"provisioningState,omitempty"`
7981}
7982
7983// ExpressRouteCircuitConnectionsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
7984// long-running operation.
7985type ExpressRouteCircuitConnectionsCreateOrUpdateFuture struct {
7986	azure.Future
7987}
7988
7989// Result returns the result of the asynchronous operation.
7990// If the operation has not completed it will return an error.
7991func (future *ExpressRouteCircuitConnectionsCreateOrUpdateFuture) Result(client ExpressRouteCircuitConnectionsClient) (ercc ExpressRouteCircuitConnection, err error) {
7992	var done bool
7993	done, err = future.Done(client)
7994	if err != nil {
7995		err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitConnectionsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
7996		return
7997	}
7998	if !done {
7999		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitConnectionsCreateOrUpdateFuture")
8000		return
8001	}
8002	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
8003	if ercc.Response.Response, err = future.GetResult(sender); err == nil && ercc.Response.Response.StatusCode != http.StatusNoContent {
8004		ercc, err = client.CreateOrUpdateResponder(ercc.Response.Response)
8005		if err != nil {
8006			err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitConnectionsCreateOrUpdateFuture", "Result", ercc.Response.Response, "Failure responding to request")
8007		}
8008	}
8009	return
8010}
8011
8012// ExpressRouteCircuitConnectionsDeleteFuture an abstraction for monitoring and retrieving the results of a
8013// long-running operation.
8014type ExpressRouteCircuitConnectionsDeleteFuture struct {
8015	azure.Future
8016}
8017
8018// Result returns the result of the asynchronous operation.
8019// If the operation has not completed it will return an error.
8020func (future *ExpressRouteCircuitConnectionsDeleteFuture) Result(client ExpressRouteCircuitConnectionsClient) (ar autorest.Response, err error) {
8021	var done bool
8022	done, err = future.Done(client)
8023	if err != nil {
8024		err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitConnectionsDeleteFuture", "Result", future.Response(), "Polling failure")
8025		return
8026	}
8027	if !done {
8028		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitConnectionsDeleteFuture")
8029		return
8030	}
8031	ar.Response = future.Response()
8032	return
8033}
8034
8035// ExpressRouteCircuitListResult response for ListExpressRouteCircuit API service call.
8036type ExpressRouteCircuitListResult struct {
8037	autorest.Response `json:"-"`
8038	// Value - A list of ExpressRouteCircuits in a resource group.
8039	Value *[]ExpressRouteCircuit `json:"value,omitempty"`
8040	// NextLink - The URL to get the next set of results.
8041	NextLink *string `json:"nextLink,omitempty"`
8042}
8043
8044// ExpressRouteCircuitListResultIterator provides access to a complete listing of ExpressRouteCircuit values.
8045type ExpressRouteCircuitListResultIterator struct {
8046	i    int
8047	page ExpressRouteCircuitListResultPage
8048}
8049
8050// Next advances to the next value.  If there was an error making
8051// the request the iterator does not advance and the error is returned.
8052func (iter *ExpressRouteCircuitListResultIterator) Next() error {
8053	iter.i++
8054	if iter.i < len(iter.page.Values()) {
8055		return nil
8056	}
8057	err := iter.page.Next()
8058	if err != nil {
8059		iter.i--
8060		return err
8061	}
8062	iter.i = 0
8063	return nil
8064}
8065
8066// NotDone returns true if the enumeration should be started or is not yet complete.
8067func (iter ExpressRouteCircuitListResultIterator) NotDone() bool {
8068	return iter.page.NotDone() && iter.i < len(iter.page.Values())
8069}
8070
8071// Response returns the raw server response from the last page request.
8072func (iter ExpressRouteCircuitListResultIterator) Response() ExpressRouteCircuitListResult {
8073	return iter.page.Response()
8074}
8075
8076// Value returns the current value or a zero-initialized value if the
8077// iterator has advanced beyond the end of the collection.
8078func (iter ExpressRouteCircuitListResultIterator) Value() ExpressRouteCircuit {
8079	if !iter.page.NotDone() {
8080		return ExpressRouteCircuit{}
8081	}
8082	return iter.page.Values()[iter.i]
8083}
8084
8085// IsEmpty returns true if the ListResult contains no values.
8086func (erclr ExpressRouteCircuitListResult) IsEmpty() bool {
8087	return erclr.Value == nil || len(*erclr.Value) == 0
8088}
8089
8090// expressRouteCircuitListResultPreparer prepares a request to retrieve the next set of results.
8091// It returns nil if no more results exist.
8092func (erclr ExpressRouteCircuitListResult) expressRouteCircuitListResultPreparer() (*http.Request, error) {
8093	if erclr.NextLink == nil || len(to.String(erclr.NextLink)) < 1 {
8094		return nil, nil
8095	}
8096	return autorest.Prepare(&http.Request{},
8097		autorest.AsJSON(),
8098		autorest.AsGet(),
8099		autorest.WithBaseURL(to.String(erclr.NextLink)))
8100}
8101
8102// ExpressRouteCircuitListResultPage contains a page of ExpressRouteCircuit values.
8103type ExpressRouteCircuitListResultPage struct {
8104	fn    func(ExpressRouteCircuitListResult) (ExpressRouteCircuitListResult, error)
8105	erclr ExpressRouteCircuitListResult
8106}
8107
8108// Next advances to the next page of values.  If there was an error making
8109// the request the page does not advance and the error is returned.
8110func (page *ExpressRouteCircuitListResultPage) Next() error {
8111	next, err := page.fn(page.erclr)
8112	if err != nil {
8113		return err
8114	}
8115	page.erclr = next
8116	return nil
8117}
8118
8119// NotDone returns true if the page enumeration should be started or is not yet complete.
8120func (page ExpressRouteCircuitListResultPage) NotDone() bool {
8121	return !page.erclr.IsEmpty()
8122}
8123
8124// Response returns the raw server response from the last page request.
8125func (page ExpressRouteCircuitListResultPage) Response() ExpressRouteCircuitListResult {
8126	return page.erclr
8127}
8128
8129// Values returns the slice of values for the current page or nil if there are no values.
8130func (page ExpressRouteCircuitListResultPage) Values() []ExpressRouteCircuit {
8131	if page.erclr.IsEmpty() {
8132		return nil
8133	}
8134	return *page.erclr.Value
8135}
8136
8137// ExpressRouteCircuitPeering peering in an ExpressRouteCircuit resource.
8138type ExpressRouteCircuitPeering struct {
8139	autorest.Response                           `json:"-"`
8140	*ExpressRouteCircuitPeeringPropertiesFormat `json:"properties,omitempty"`
8141	// Name - Gets name of the resource that is unique within a resource group. This name can be used to access the resource.
8142	Name *string `json:"name,omitempty"`
8143	// Etag - A unique read-only string that changes whenever the resource is updated.
8144	Etag *string `json:"etag,omitempty"`
8145	// ID - Resource ID.
8146	ID *string `json:"id,omitempty"`
8147}
8148
8149// MarshalJSON is the custom marshaler for ExpressRouteCircuitPeering.
8150func (ercp ExpressRouteCircuitPeering) MarshalJSON() ([]byte, error) {
8151	objectMap := make(map[string]interface{})
8152	if ercp.ExpressRouteCircuitPeeringPropertiesFormat != nil {
8153		objectMap["properties"] = ercp.ExpressRouteCircuitPeeringPropertiesFormat
8154	}
8155	if ercp.Name != nil {
8156		objectMap["name"] = ercp.Name
8157	}
8158	if ercp.Etag != nil {
8159		objectMap["etag"] = ercp.Etag
8160	}
8161	if ercp.ID != nil {
8162		objectMap["id"] = ercp.ID
8163	}
8164	return json.Marshal(objectMap)
8165}
8166
8167// UnmarshalJSON is the custom unmarshaler for ExpressRouteCircuitPeering struct.
8168func (ercp *ExpressRouteCircuitPeering) UnmarshalJSON(body []byte) error {
8169	var m map[string]*json.RawMessage
8170	err := json.Unmarshal(body, &m)
8171	if err != nil {
8172		return err
8173	}
8174	for k, v := range m {
8175		switch k {
8176		case "properties":
8177			if v != nil {
8178				var expressRouteCircuitPeeringPropertiesFormat ExpressRouteCircuitPeeringPropertiesFormat
8179				err = json.Unmarshal(*v, &expressRouteCircuitPeeringPropertiesFormat)
8180				if err != nil {
8181					return err
8182				}
8183				ercp.ExpressRouteCircuitPeeringPropertiesFormat = &expressRouteCircuitPeeringPropertiesFormat
8184			}
8185		case "name":
8186			if v != nil {
8187				var name string
8188				err = json.Unmarshal(*v, &name)
8189				if err != nil {
8190					return err
8191				}
8192				ercp.Name = &name
8193			}
8194		case "etag":
8195			if v != nil {
8196				var etag string
8197				err = json.Unmarshal(*v, &etag)
8198				if err != nil {
8199					return err
8200				}
8201				ercp.Etag = &etag
8202			}
8203		case "id":
8204			if v != nil {
8205				var ID string
8206				err = json.Unmarshal(*v, &ID)
8207				if err != nil {
8208					return err
8209				}
8210				ercp.ID = &ID
8211			}
8212		}
8213	}
8214
8215	return nil
8216}
8217
8218// ExpressRouteCircuitPeeringConfig specifies the peering configuration.
8219type ExpressRouteCircuitPeeringConfig struct {
8220	// AdvertisedPublicPrefixes - The reference of AdvertisedPublicPrefixes.
8221	AdvertisedPublicPrefixes *[]string `json:"advertisedPublicPrefixes,omitempty"`
8222	// AdvertisedCommunities - The communities of bgp peering. Spepcified for microsoft peering
8223	AdvertisedCommunities *[]string `json:"advertisedCommunities,omitempty"`
8224	// AdvertisedPublicPrefixesState - AdvertisedPublicPrefixState of the Peering resource. Possible values are 'NotConfigured', 'Configuring', 'Configured', and 'ValidationNeeded'. Possible values include: 'NotConfigured', 'Configuring', 'Configured', 'ValidationNeeded'
8225	AdvertisedPublicPrefixesState ExpressRouteCircuitPeeringAdvertisedPublicPrefixState `json:"advertisedPublicPrefixesState,omitempty"`
8226	// LegacyMode - The legacy mode of the peering.
8227	LegacyMode *int32 `json:"legacyMode,omitempty"`
8228	// CustomerASN - The CustomerASN of the peering.
8229	CustomerASN *int32 `json:"customerASN,omitempty"`
8230	// RoutingRegistryName - The RoutingRegistryName of the configuration.
8231	RoutingRegistryName *string `json:"routingRegistryName,omitempty"`
8232}
8233
8234// ExpressRouteCircuitPeeringID expressRoute circuit peering identifier.
8235type ExpressRouteCircuitPeeringID struct {
8236	// ID - The ID of the ExpressRoute circuit peering.
8237	ID *string `json:"id,omitempty"`
8238}
8239
8240// ExpressRouteCircuitPeeringListResult response for ListPeering API service call retrieves all peerings that
8241// belong to an ExpressRouteCircuit.
8242type ExpressRouteCircuitPeeringListResult struct {
8243	autorest.Response `json:"-"`
8244	// Value - The peerings in an express route circuit.
8245	Value *[]ExpressRouteCircuitPeering `json:"value,omitempty"`
8246	// NextLink - The URL to get the next set of results.
8247	NextLink *string `json:"nextLink,omitempty"`
8248}
8249
8250// ExpressRouteCircuitPeeringListResultIterator provides access to a complete listing of ExpressRouteCircuitPeering
8251// values.
8252type ExpressRouteCircuitPeeringListResultIterator struct {
8253	i    int
8254	page ExpressRouteCircuitPeeringListResultPage
8255}
8256
8257// Next advances to the next value.  If there was an error making
8258// the request the iterator does not advance and the error is returned.
8259func (iter *ExpressRouteCircuitPeeringListResultIterator) Next() error {
8260	iter.i++
8261	if iter.i < len(iter.page.Values()) {
8262		return nil
8263	}
8264	err := iter.page.Next()
8265	if err != nil {
8266		iter.i--
8267		return err
8268	}
8269	iter.i = 0
8270	return nil
8271}
8272
8273// NotDone returns true if the enumeration should be started or is not yet complete.
8274func (iter ExpressRouteCircuitPeeringListResultIterator) NotDone() bool {
8275	return iter.page.NotDone() && iter.i < len(iter.page.Values())
8276}
8277
8278// Response returns the raw server response from the last page request.
8279func (iter ExpressRouteCircuitPeeringListResultIterator) Response() ExpressRouteCircuitPeeringListResult {
8280	return iter.page.Response()
8281}
8282
8283// Value returns the current value or a zero-initialized value if the
8284// iterator has advanced beyond the end of the collection.
8285func (iter ExpressRouteCircuitPeeringListResultIterator) Value() ExpressRouteCircuitPeering {
8286	if !iter.page.NotDone() {
8287		return ExpressRouteCircuitPeering{}
8288	}
8289	return iter.page.Values()[iter.i]
8290}
8291
8292// IsEmpty returns true if the ListResult contains no values.
8293func (ercplr ExpressRouteCircuitPeeringListResult) IsEmpty() bool {
8294	return ercplr.Value == nil || len(*ercplr.Value) == 0
8295}
8296
8297// expressRouteCircuitPeeringListResultPreparer prepares a request to retrieve the next set of results.
8298// It returns nil if no more results exist.
8299func (ercplr ExpressRouteCircuitPeeringListResult) expressRouteCircuitPeeringListResultPreparer() (*http.Request, error) {
8300	if ercplr.NextLink == nil || len(to.String(ercplr.NextLink)) < 1 {
8301		return nil, nil
8302	}
8303	return autorest.Prepare(&http.Request{},
8304		autorest.AsJSON(),
8305		autorest.AsGet(),
8306		autorest.WithBaseURL(to.String(ercplr.NextLink)))
8307}
8308
8309// ExpressRouteCircuitPeeringListResultPage contains a page of ExpressRouteCircuitPeering values.
8310type ExpressRouteCircuitPeeringListResultPage struct {
8311	fn     func(ExpressRouteCircuitPeeringListResult) (ExpressRouteCircuitPeeringListResult, error)
8312	ercplr ExpressRouteCircuitPeeringListResult
8313}
8314
8315// Next advances to the next page of values.  If there was an error making
8316// the request the page does not advance and the error is returned.
8317func (page *ExpressRouteCircuitPeeringListResultPage) Next() error {
8318	next, err := page.fn(page.ercplr)
8319	if err != nil {
8320		return err
8321	}
8322	page.ercplr = next
8323	return nil
8324}
8325
8326// NotDone returns true if the page enumeration should be started or is not yet complete.
8327func (page ExpressRouteCircuitPeeringListResultPage) NotDone() bool {
8328	return !page.ercplr.IsEmpty()
8329}
8330
8331// Response returns the raw server response from the last page request.
8332func (page ExpressRouteCircuitPeeringListResultPage) Response() ExpressRouteCircuitPeeringListResult {
8333	return page.ercplr
8334}
8335
8336// Values returns the slice of values for the current page or nil if there are no values.
8337func (page ExpressRouteCircuitPeeringListResultPage) Values() []ExpressRouteCircuitPeering {
8338	if page.ercplr.IsEmpty() {
8339		return nil
8340	}
8341	return *page.ercplr.Value
8342}
8343
8344// ExpressRouteCircuitPeeringPropertiesFormat ...
8345type ExpressRouteCircuitPeeringPropertiesFormat struct {
8346	// PeeringType - The peering type. Possible values include: 'AzurePublicPeering', 'AzurePrivatePeering', 'MicrosoftPeering'
8347	PeeringType ExpressRoutePeeringType `json:"peeringType,omitempty"`
8348	// State - The peering state. Possible values include: 'ExpressRoutePeeringStateDisabled', 'ExpressRoutePeeringStateEnabled'
8349	State ExpressRoutePeeringState `json:"state,omitempty"`
8350	// AzureASN - The Azure ASN.
8351	AzureASN *int32 `json:"azureASN,omitempty"`
8352	// PeerASN - The peer ASN.
8353	PeerASN *int64 `json:"peerASN,omitempty"`
8354	// PrimaryPeerAddressPrefix - The primary address prefix.
8355	PrimaryPeerAddressPrefix *string `json:"primaryPeerAddressPrefix,omitempty"`
8356	// SecondaryPeerAddressPrefix - The secondary address prefix.
8357	SecondaryPeerAddressPrefix *string `json:"secondaryPeerAddressPrefix,omitempty"`
8358	// PrimaryAzurePort - The primary port.
8359	PrimaryAzurePort *string `json:"primaryAzurePort,omitempty"`
8360	// SecondaryAzurePort - The secondary port.
8361	SecondaryAzurePort *string `json:"secondaryAzurePort,omitempty"`
8362	// SharedKey - The shared key.
8363	SharedKey *string `json:"sharedKey,omitempty"`
8364	// VlanID - The VLAN ID.
8365	VlanID *int32 `json:"vlanId,omitempty"`
8366	// MicrosoftPeeringConfig - The Microsoft peering configuration.
8367	MicrosoftPeeringConfig *ExpressRouteCircuitPeeringConfig `json:"microsoftPeeringConfig,omitempty"`
8368	// Stats - Gets peering stats.
8369	Stats *ExpressRouteCircuitStats `json:"stats,omitempty"`
8370	// ProvisioningState - Gets the provisioning state of the public IP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
8371	ProvisioningState *string `json:"provisioningState,omitempty"`
8372	// GatewayManagerEtag - The GatewayManager Etag.
8373	GatewayManagerEtag *string `json:"gatewayManagerEtag,omitempty"`
8374	// LastModifiedBy - Gets whether the provider or the customer last modified the peering.
8375	LastModifiedBy *string `json:"lastModifiedBy,omitempty"`
8376	// RouteFilter - The reference of the RouteFilter resource.
8377	RouteFilter *RouteFilter `json:"routeFilter,omitempty"`
8378	// Ipv6PeeringConfig - The IPv6 peering configuration.
8379	Ipv6PeeringConfig *Ipv6ExpressRouteCircuitPeeringConfig `json:"ipv6PeeringConfig,omitempty"`
8380	// ExpressRouteConnection - The ExpressRoute connection.
8381	ExpressRouteConnection *ExpressRouteConnectionID `json:"expressRouteConnection,omitempty"`
8382	// Connections - The list of circuit connections associated with Azure Private Peering for this circuit.
8383	Connections *[]ExpressRouteCircuitConnection `json:"connections,omitempty"`
8384}
8385
8386// ExpressRouteCircuitPeeringsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
8387// long-running operation.
8388type ExpressRouteCircuitPeeringsCreateOrUpdateFuture struct {
8389	azure.Future
8390}
8391
8392// Result returns the result of the asynchronous operation.
8393// If the operation has not completed it will return an error.
8394func (future *ExpressRouteCircuitPeeringsCreateOrUpdateFuture) Result(client ExpressRouteCircuitPeeringsClient) (ercp ExpressRouteCircuitPeering, err error) {
8395	var done bool
8396	done, err = future.Done(client)
8397	if err != nil {
8398		err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitPeeringsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
8399		return
8400	}
8401	if !done {
8402		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitPeeringsCreateOrUpdateFuture")
8403		return
8404	}
8405	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
8406	if ercp.Response.Response, err = future.GetResult(sender); err == nil && ercp.Response.Response.StatusCode != http.StatusNoContent {
8407		ercp, err = client.CreateOrUpdateResponder(ercp.Response.Response)
8408		if err != nil {
8409			err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitPeeringsCreateOrUpdateFuture", "Result", ercp.Response.Response, "Failure responding to request")
8410		}
8411	}
8412	return
8413}
8414
8415// ExpressRouteCircuitPeeringsDeleteFuture an abstraction for monitoring and retrieving the results of a
8416// long-running operation.
8417type ExpressRouteCircuitPeeringsDeleteFuture struct {
8418	azure.Future
8419}
8420
8421// Result returns the result of the asynchronous operation.
8422// If the operation has not completed it will return an error.
8423func (future *ExpressRouteCircuitPeeringsDeleteFuture) Result(client ExpressRouteCircuitPeeringsClient) (ar autorest.Response, err error) {
8424	var done bool
8425	done, err = future.Done(client)
8426	if err != nil {
8427		err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitPeeringsDeleteFuture", "Result", future.Response(), "Polling failure")
8428		return
8429	}
8430	if !done {
8431		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitPeeringsDeleteFuture")
8432		return
8433	}
8434	ar.Response = future.Response()
8435	return
8436}
8437
8438// ExpressRouteCircuitPropertiesFormat properties of ExpressRouteCircuit.
8439type ExpressRouteCircuitPropertiesFormat struct {
8440	// AllowClassicOperations - Allow classic operations
8441	AllowClassicOperations *bool `json:"allowClassicOperations,omitempty"`
8442	// CircuitProvisioningState - The CircuitProvisioningState state of the resource.
8443	CircuitProvisioningState *string `json:"circuitProvisioningState,omitempty"`
8444	// ServiceProviderProvisioningState - The ServiceProviderProvisioningState state of the resource. Possible values are 'NotProvisioned', 'Provisioning', 'Provisioned', and 'Deprovisioning'. Possible values include: 'NotProvisioned', 'Provisioning', 'Provisioned', 'Deprovisioning'
8445	ServiceProviderProvisioningState ServiceProviderProvisioningState `json:"serviceProviderProvisioningState,omitempty"`
8446	// Authorizations - The list of authorizations.
8447	Authorizations *[]ExpressRouteCircuitAuthorization `json:"authorizations,omitempty"`
8448	// Peerings - The list of peerings.
8449	Peerings *[]ExpressRouteCircuitPeering `json:"peerings,omitempty"`
8450	// ServiceKey - The ServiceKey.
8451	ServiceKey *string `json:"serviceKey,omitempty"`
8452	// ServiceProviderNotes - The ServiceProviderNotes.
8453	ServiceProviderNotes *string `json:"serviceProviderNotes,omitempty"`
8454	// ServiceProviderProperties - The ServiceProviderProperties.
8455	ServiceProviderProperties *ExpressRouteCircuitServiceProviderProperties `json:"serviceProviderProperties,omitempty"`
8456	// ProvisioningState - Gets the provisioning state of the public IP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
8457	ProvisioningState *string `json:"provisioningState,omitempty"`
8458	// GatewayManagerEtag - The GatewayManager Etag.
8459	GatewayManagerEtag *string `json:"gatewayManagerEtag,omitempty"`
8460	// AllowGlobalReach - Flag to enable Global Reach on the circuit.
8461	AllowGlobalReach *bool `json:"allowGlobalReach,omitempty"`
8462}
8463
8464// ExpressRouteCircuitReference ...
8465type ExpressRouteCircuitReference struct {
8466	// ID - Corresponding Express Route Circuit Id.
8467	ID *string `json:"id,omitempty"`
8468}
8469
8470// ExpressRouteCircuitRoutesTable the routes table associated with the ExpressRouteCircuit
8471type ExpressRouteCircuitRoutesTable struct {
8472	// NetworkProperty - IP address of a network entity
8473	NetworkProperty *string `json:"network,omitempty"`
8474	// NextHop - NextHop address
8475	NextHop *string `json:"nextHop,omitempty"`
8476	// LocPrf - Local preference value as set with the set local-preference route-map configuration command
8477	LocPrf *string `json:"locPrf,omitempty"`
8478	// Weight - Route Weight.
8479	Weight *int32 `json:"weight,omitempty"`
8480	// Path - Autonomous system paths to the destination network.
8481	Path *string `json:"path,omitempty"`
8482}
8483
8484// ExpressRouteCircuitRoutesTableSummary the routes table associated with the ExpressRouteCircuit.
8485type ExpressRouteCircuitRoutesTableSummary struct {
8486	// Neighbor - IP address of the neighbor.
8487	Neighbor *string `json:"neighbor,omitempty"`
8488	// V - BGP version number spoken to the neighbor.
8489	V *int32 `json:"v,omitempty"`
8490	// As - Autonomous system number.
8491	As *int32 `json:"as,omitempty"`
8492	// UpDown - The length of time that the BGP session has been in the Established state, or the current status if not in the Established state.
8493	UpDown *string `json:"upDown,omitempty"`
8494	// StatePfxRcd - Current state of the BGP session, and the number of prefixes that have been received from a neighbor or peer group.
8495	StatePfxRcd *string `json:"statePfxRcd,omitempty"`
8496}
8497
8498// ExpressRouteCircuitsArpTableListResult response for ListArpTable associated with the Express Route Circuits API.
8499type ExpressRouteCircuitsArpTableListResult struct {
8500	autorest.Response `json:"-"`
8501	// Value - Gets list of the ARP table.
8502	Value *[]ExpressRouteCircuitArpTable `json:"value,omitempty"`
8503	// NextLink - The URL to get the next set of results.
8504	NextLink *string `json:"nextLink,omitempty"`
8505}
8506
8507// ExpressRouteCircuitsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
8508// long-running operation.
8509type ExpressRouteCircuitsCreateOrUpdateFuture struct {
8510	azure.Future
8511}
8512
8513// Result returns the result of the asynchronous operation.
8514// If the operation has not completed it will return an error.
8515func (future *ExpressRouteCircuitsCreateOrUpdateFuture) Result(client ExpressRouteCircuitsClient) (erc ExpressRouteCircuit, err error) {
8516	var done bool
8517	done, err = future.Done(client)
8518	if err != nil {
8519		err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
8520		return
8521	}
8522	if !done {
8523		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitsCreateOrUpdateFuture")
8524		return
8525	}
8526	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
8527	if erc.Response.Response, err = future.GetResult(sender); err == nil && erc.Response.Response.StatusCode != http.StatusNoContent {
8528		erc, err = client.CreateOrUpdateResponder(erc.Response.Response)
8529		if err != nil {
8530			err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsCreateOrUpdateFuture", "Result", erc.Response.Response, "Failure responding to request")
8531		}
8532	}
8533	return
8534}
8535
8536// ExpressRouteCircuitsDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
8537// operation.
8538type ExpressRouteCircuitsDeleteFuture struct {
8539	azure.Future
8540}
8541
8542// Result returns the result of the asynchronous operation.
8543// If the operation has not completed it will return an error.
8544func (future *ExpressRouteCircuitsDeleteFuture) Result(client ExpressRouteCircuitsClient) (ar autorest.Response, err error) {
8545	var done bool
8546	done, err = future.Done(client)
8547	if err != nil {
8548		err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsDeleteFuture", "Result", future.Response(), "Polling failure")
8549		return
8550	}
8551	if !done {
8552		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitsDeleteFuture")
8553		return
8554	}
8555	ar.Response = future.Response()
8556	return
8557}
8558
8559// ExpressRouteCircuitServiceProviderProperties contains ServiceProviderProperties in an ExpressRouteCircuit.
8560type ExpressRouteCircuitServiceProviderProperties struct {
8561	// ServiceProviderName - The serviceProviderName.
8562	ServiceProviderName *string `json:"serviceProviderName,omitempty"`
8563	// PeeringLocation - The peering location.
8564	PeeringLocation *string `json:"peeringLocation,omitempty"`
8565	// BandwidthInMbps - The BandwidthInMbps.
8566	BandwidthInMbps *int32 `json:"bandwidthInMbps,omitempty"`
8567}
8568
8569// ExpressRouteCircuitSku contains SKU in an ExpressRouteCircuit.
8570type ExpressRouteCircuitSku struct {
8571	// Name - The name of the SKU.
8572	Name *string `json:"name,omitempty"`
8573	// Tier - The tier of the SKU. Possible values are 'Standard' and 'Premium'. Possible values include: 'Standard', 'Premium'
8574	Tier ExpressRouteCircuitSkuTier `json:"tier,omitempty"`
8575	// Family - The family of the SKU. Possible values are: 'UnlimitedData' and 'MeteredData'. Possible values include: 'UnlimitedData', 'MeteredData'
8576	Family ExpressRouteCircuitSkuFamily `json:"family,omitempty"`
8577}
8578
8579// ExpressRouteCircuitsListArpTableFuture an abstraction for monitoring and retrieving the results of a
8580// long-running operation.
8581type ExpressRouteCircuitsListArpTableFuture struct {
8582	azure.Future
8583}
8584
8585// Result returns the result of the asynchronous operation.
8586// If the operation has not completed it will return an error.
8587func (future *ExpressRouteCircuitsListArpTableFuture) Result(client ExpressRouteCircuitsClient) (ercatlr ExpressRouteCircuitsArpTableListResult, err error) {
8588	var done bool
8589	done, err = future.Done(client)
8590	if err != nil {
8591		err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsListArpTableFuture", "Result", future.Response(), "Polling failure")
8592		return
8593	}
8594	if !done {
8595		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitsListArpTableFuture")
8596		return
8597	}
8598	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
8599	if ercatlr.Response.Response, err = future.GetResult(sender); err == nil && ercatlr.Response.Response.StatusCode != http.StatusNoContent {
8600		ercatlr, err = client.ListArpTableResponder(ercatlr.Response.Response)
8601		if err != nil {
8602			err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsListArpTableFuture", "Result", ercatlr.Response.Response, "Failure responding to request")
8603		}
8604	}
8605	return
8606}
8607
8608// ExpressRouteCircuitsListRoutesTableFuture an abstraction for monitoring and retrieving the results of a
8609// long-running operation.
8610type ExpressRouteCircuitsListRoutesTableFuture struct {
8611	azure.Future
8612}
8613
8614// Result returns the result of the asynchronous operation.
8615// If the operation has not completed it will return an error.
8616func (future *ExpressRouteCircuitsListRoutesTableFuture) Result(client ExpressRouteCircuitsClient) (ercrtlr ExpressRouteCircuitsRoutesTableListResult, err error) {
8617	var done bool
8618	done, err = future.Done(client)
8619	if err != nil {
8620		err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsListRoutesTableFuture", "Result", future.Response(), "Polling failure")
8621		return
8622	}
8623	if !done {
8624		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitsListRoutesTableFuture")
8625		return
8626	}
8627	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
8628	if ercrtlr.Response.Response, err = future.GetResult(sender); err == nil && ercrtlr.Response.Response.StatusCode != http.StatusNoContent {
8629		ercrtlr, err = client.ListRoutesTableResponder(ercrtlr.Response.Response)
8630		if err != nil {
8631			err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsListRoutesTableFuture", "Result", ercrtlr.Response.Response, "Failure responding to request")
8632		}
8633	}
8634	return
8635}
8636
8637// ExpressRouteCircuitsListRoutesTableSummaryFuture an abstraction for monitoring and retrieving the results of a
8638// long-running operation.
8639type ExpressRouteCircuitsListRoutesTableSummaryFuture struct {
8640	azure.Future
8641}
8642
8643// Result returns the result of the asynchronous operation.
8644// If the operation has not completed it will return an error.
8645func (future *ExpressRouteCircuitsListRoutesTableSummaryFuture) Result(client ExpressRouteCircuitsClient) (ercrtslr ExpressRouteCircuitsRoutesTableSummaryListResult, err error) {
8646	var done bool
8647	done, err = future.Done(client)
8648	if err != nil {
8649		err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsListRoutesTableSummaryFuture", "Result", future.Response(), "Polling failure")
8650		return
8651	}
8652	if !done {
8653		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitsListRoutesTableSummaryFuture")
8654		return
8655	}
8656	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
8657	if ercrtslr.Response.Response, err = future.GetResult(sender); err == nil && ercrtslr.Response.Response.StatusCode != http.StatusNoContent {
8658		ercrtslr, err = client.ListRoutesTableSummaryResponder(ercrtslr.Response.Response)
8659		if err != nil {
8660			err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsListRoutesTableSummaryFuture", "Result", ercrtslr.Response.Response, "Failure responding to request")
8661		}
8662	}
8663	return
8664}
8665
8666// ExpressRouteCircuitsRoutesTableListResult response for ListRoutesTable associated with the Express Route
8667// Circuits API.
8668type ExpressRouteCircuitsRoutesTableListResult struct {
8669	autorest.Response `json:"-"`
8670	// Value - The list of routes table.
8671	Value *[]ExpressRouteCircuitRoutesTable `json:"value,omitempty"`
8672	// NextLink - The URL to get the next set of results.
8673	NextLink *string `json:"nextLink,omitempty"`
8674}
8675
8676// ExpressRouteCircuitsRoutesTableSummaryListResult response for ListRoutesTable associated with the Express Route
8677// Circuits API.
8678type ExpressRouteCircuitsRoutesTableSummaryListResult struct {
8679	autorest.Response `json:"-"`
8680	// Value - A list of the routes table.
8681	Value *[]ExpressRouteCircuitRoutesTableSummary `json:"value,omitempty"`
8682	// NextLink - The URL to get the next set of results.
8683	NextLink *string `json:"nextLink,omitempty"`
8684}
8685
8686// ExpressRouteCircuitStats contains stats associated with the peering.
8687type ExpressRouteCircuitStats struct {
8688	autorest.Response `json:"-"`
8689	// PrimarybytesIn - Gets BytesIn of the peering.
8690	PrimarybytesIn *int64 `json:"primarybytesIn,omitempty"`
8691	// PrimarybytesOut - Gets BytesOut of the peering.
8692	PrimarybytesOut *int64 `json:"primarybytesOut,omitempty"`
8693	// SecondarybytesIn - Gets BytesIn of the peering.
8694	SecondarybytesIn *int64 `json:"secondarybytesIn,omitempty"`
8695	// SecondarybytesOut - Gets BytesOut of the peering.
8696	SecondarybytesOut *int64 `json:"secondarybytesOut,omitempty"`
8697}
8698
8699// ExpressRouteCircuitsUpdateTagsFuture an abstraction for monitoring and retrieving the results of a long-running
8700// operation.
8701type ExpressRouteCircuitsUpdateTagsFuture struct {
8702	azure.Future
8703}
8704
8705// Result returns the result of the asynchronous operation.
8706// If the operation has not completed it will return an error.
8707func (future *ExpressRouteCircuitsUpdateTagsFuture) Result(client ExpressRouteCircuitsClient) (erc ExpressRouteCircuit, err error) {
8708	var done bool
8709	done, err = future.Done(client)
8710	if err != nil {
8711		err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsUpdateTagsFuture", "Result", future.Response(), "Polling failure")
8712		return
8713	}
8714	if !done {
8715		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitsUpdateTagsFuture")
8716		return
8717	}
8718	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
8719	if erc.Response.Response, err = future.GetResult(sender); err == nil && erc.Response.Response.StatusCode != http.StatusNoContent {
8720		erc, err = client.UpdateTagsResponder(erc.Response.Response)
8721		if err != nil {
8722			err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsUpdateTagsFuture", "Result", erc.Response.Response, "Failure responding to request")
8723		}
8724	}
8725	return
8726}
8727
8728// ExpressRouteConnection expressRouteConnection resource.
8729type ExpressRouteConnection struct {
8730	autorest.Response                 `json:"-"`
8731	*ExpressRouteConnectionProperties `json:"properties,omitempty"`
8732	// Name - The name of the resource.
8733	Name *string `json:"name,omitempty"`
8734	// ID - Resource ID.
8735	ID *string `json:"id,omitempty"`
8736}
8737
8738// MarshalJSON is the custom marshaler for ExpressRouteConnection.
8739func (erc ExpressRouteConnection) MarshalJSON() ([]byte, error) {
8740	objectMap := make(map[string]interface{})
8741	if erc.ExpressRouteConnectionProperties != nil {
8742		objectMap["properties"] = erc.ExpressRouteConnectionProperties
8743	}
8744	if erc.Name != nil {
8745		objectMap["name"] = erc.Name
8746	}
8747	if erc.ID != nil {
8748		objectMap["id"] = erc.ID
8749	}
8750	return json.Marshal(objectMap)
8751}
8752
8753// UnmarshalJSON is the custom unmarshaler for ExpressRouteConnection struct.
8754func (erc *ExpressRouteConnection) UnmarshalJSON(body []byte) error {
8755	var m map[string]*json.RawMessage
8756	err := json.Unmarshal(body, &m)
8757	if err != nil {
8758		return err
8759	}
8760	for k, v := range m {
8761		switch k {
8762		case "properties":
8763			if v != nil {
8764				var expressRouteConnectionProperties ExpressRouteConnectionProperties
8765				err = json.Unmarshal(*v, &expressRouteConnectionProperties)
8766				if err != nil {
8767					return err
8768				}
8769				erc.ExpressRouteConnectionProperties = &expressRouteConnectionProperties
8770			}
8771		case "name":
8772			if v != nil {
8773				var name string
8774				err = json.Unmarshal(*v, &name)
8775				if err != nil {
8776					return err
8777				}
8778				erc.Name = &name
8779			}
8780		case "id":
8781			if v != nil {
8782				var ID string
8783				err = json.Unmarshal(*v, &ID)
8784				if err != nil {
8785					return err
8786				}
8787				erc.ID = &ID
8788			}
8789		}
8790	}
8791
8792	return nil
8793}
8794
8795// ExpressRouteConnectionID the ID of the ExpressRouteConnection.
8796type ExpressRouteConnectionID struct {
8797	// ID - The ID of the ExpressRouteConnection.
8798	ID *string `json:"id,omitempty"`
8799}
8800
8801// ExpressRouteConnectionList expressRouteConnection list
8802type ExpressRouteConnectionList struct {
8803	autorest.Response `json:"-"`
8804	// Value - The list of ExpressRoute connections
8805	Value *[]ExpressRouteConnection `json:"value,omitempty"`
8806}
8807
8808// ExpressRouteConnectionProperties properties of the ExpressRouteConnection subresource.
8809type ExpressRouteConnectionProperties struct {
8810	// ProvisioningState - The provisioning state of the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
8811	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
8812	// ExpressRouteCircuitPeering - The ExpressRoute circuit peering.
8813	ExpressRouteCircuitPeering *ExpressRouteCircuitPeeringID `json:"expressRouteCircuitPeering,omitempty"`
8814	// AuthorizationKey - Authorization key to establish the connection.
8815	AuthorizationKey *string `json:"authorizationKey,omitempty"`
8816	// RoutingWeight - The routing weight associated to the connection.
8817	RoutingWeight *int32 `json:"routingWeight,omitempty"`
8818}
8819
8820// ExpressRouteConnectionsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
8821// long-running operation.
8822type ExpressRouteConnectionsCreateOrUpdateFuture struct {
8823	azure.Future
8824}
8825
8826// Result returns the result of the asynchronous operation.
8827// If the operation has not completed it will return an error.
8828func (future *ExpressRouteConnectionsCreateOrUpdateFuture) Result(client ExpressRouteConnectionsClient) (erc ExpressRouteConnection, err error) {
8829	var done bool
8830	done, err = future.Done(client)
8831	if err != nil {
8832		err = autorest.NewErrorWithError(err, "network.ExpressRouteConnectionsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
8833		return
8834	}
8835	if !done {
8836		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteConnectionsCreateOrUpdateFuture")
8837		return
8838	}
8839	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
8840	if erc.Response.Response, err = future.GetResult(sender); err == nil && erc.Response.Response.StatusCode != http.StatusNoContent {
8841		erc, err = client.CreateOrUpdateResponder(erc.Response.Response)
8842		if err != nil {
8843			err = autorest.NewErrorWithError(err, "network.ExpressRouteConnectionsCreateOrUpdateFuture", "Result", erc.Response.Response, "Failure responding to request")
8844		}
8845	}
8846	return
8847}
8848
8849// ExpressRouteConnectionsDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
8850// operation.
8851type ExpressRouteConnectionsDeleteFuture struct {
8852	azure.Future
8853}
8854
8855// Result returns the result of the asynchronous operation.
8856// If the operation has not completed it will return an error.
8857func (future *ExpressRouteConnectionsDeleteFuture) Result(client ExpressRouteConnectionsClient) (ar autorest.Response, err error) {
8858	var done bool
8859	done, err = future.Done(client)
8860	if err != nil {
8861		err = autorest.NewErrorWithError(err, "network.ExpressRouteConnectionsDeleteFuture", "Result", future.Response(), "Polling failure")
8862		return
8863	}
8864	if !done {
8865		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteConnectionsDeleteFuture")
8866		return
8867	}
8868	ar.Response = future.Response()
8869	return
8870}
8871
8872// ExpressRouteCrossConnection expressRouteCrossConnection resource
8873type ExpressRouteCrossConnection struct {
8874	autorest.Response                      `json:"-"`
8875	*ExpressRouteCrossConnectionProperties `json:"properties,omitempty"`
8876	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
8877	Etag *string `json:"etag,omitempty"`
8878	// ID - Resource ID.
8879	ID *string `json:"id,omitempty"`
8880	// Name - Resource name.
8881	Name *string `json:"name,omitempty"`
8882	// Type - Resource type.
8883	Type *string `json:"type,omitempty"`
8884	// Location - Resource location.
8885	Location *string `json:"location,omitempty"`
8886	// Tags - Resource tags.
8887	Tags map[string]*string `json:"tags"`
8888}
8889
8890// MarshalJSON is the custom marshaler for ExpressRouteCrossConnection.
8891func (ercc ExpressRouteCrossConnection) MarshalJSON() ([]byte, error) {
8892	objectMap := make(map[string]interface{})
8893	if ercc.ExpressRouteCrossConnectionProperties != nil {
8894		objectMap["properties"] = ercc.ExpressRouteCrossConnectionProperties
8895	}
8896	if ercc.Etag != nil {
8897		objectMap["etag"] = ercc.Etag
8898	}
8899	if ercc.ID != nil {
8900		objectMap["id"] = ercc.ID
8901	}
8902	if ercc.Name != nil {
8903		objectMap["name"] = ercc.Name
8904	}
8905	if ercc.Type != nil {
8906		objectMap["type"] = ercc.Type
8907	}
8908	if ercc.Location != nil {
8909		objectMap["location"] = ercc.Location
8910	}
8911	if ercc.Tags != nil {
8912		objectMap["tags"] = ercc.Tags
8913	}
8914	return json.Marshal(objectMap)
8915}
8916
8917// UnmarshalJSON is the custom unmarshaler for ExpressRouteCrossConnection struct.
8918func (ercc *ExpressRouteCrossConnection) UnmarshalJSON(body []byte) error {
8919	var m map[string]*json.RawMessage
8920	err := json.Unmarshal(body, &m)
8921	if err != nil {
8922		return err
8923	}
8924	for k, v := range m {
8925		switch k {
8926		case "properties":
8927			if v != nil {
8928				var expressRouteCrossConnectionProperties ExpressRouteCrossConnectionProperties
8929				err = json.Unmarshal(*v, &expressRouteCrossConnectionProperties)
8930				if err != nil {
8931					return err
8932				}
8933				ercc.ExpressRouteCrossConnectionProperties = &expressRouteCrossConnectionProperties
8934			}
8935		case "etag":
8936			if v != nil {
8937				var etag string
8938				err = json.Unmarshal(*v, &etag)
8939				if err != nil {
8940					return err
8941				}
8942				ercc.Etag = &etag
8943			}
8944		case "id":
8945			if v != nil {
8946				var ID string
8947				err = json.Unmarshal(*v, &ID)
8948				if err != nil {
8949					return err
8950				}
8951				ercc.ID = &ID
8952			}
8953		case "name":
8954			if v != nil {
8955				var name string
8956				err = json.Unmarshal(*v, &name)
8957				if err != nil {
8958					return err
8959				}
8960				ercc.Name = &name
8961			}
8962		case "type":
8963			if v != nil {
8964				var typeVar string
8965				err = json.Unmarshal(*v, &typeVar)
8966				if err != nil {
8967					return err
8968				}
8969				ercc.Type = &typeVar
8970			}
8971		case "location":
8972			if v != nil {
8973				var location string
8974				err = json.Unmarshal(*v, &location)
8975				if err != nil {
8976					return err
8977				}
8978				ercc.Location = &location
8979			}
8980		case "tags":
8981			if v != nil {
8982				var tags map[string]*string
8983				err = json.Unmarshal(*v, &tags)
8984				if err != nil {
8985					return err
8986				}
8987				ercc.Tags = tags
8988			}
8989		}
8990	}
8991
8992	return nil
8993}
8994
8995// ExpressRouteCrossConnectionListResult response for ListExpressRouteCrossConnection API service call.
8996type ExpressRouteCrossConnectionListResult struct {
8997	autorest.Response `json:"-"`
8998	// Value - A list of ExpressRouteCrossConnection resources.
8999	Value *[]ExpressRouteCrossConnection `json:"value,omitempty"`
9000	// NextLink - The URL to get the next set of results.
9001	NextLink *string `json:"nextLink,omitempty"`
9002}
9003
9004// ExpressRouteCrossConnectionListResultIterator provides access to a complete listing of
9005// ExpressRouteCrossConnection values.
9006type ExpressRouteCrossConnectionListResultIterator struct {
9007	i    int
9008	page ExpressRouteCrossConnectionListResultPage
9009}
9010
9011// Next advances to the next value.  If there was an error making
9012// the request the iterator does not advance and the error is returned.
9013func (iter *ExpressRouteCrossConnectionListResultIterator) Next() error {
9014	iter.i++
9015	if iter.i < len(iter.page.Values()) {
9016		return nil
9017	}
9018	err := iter.page.Next()
9019	if err != nil {
9020		iter.i--
9021		return err
9022	}
9023	iter.i = 0
9024	return nil
9025}
9026
9027// NotDone returns true if the enumeration should be started or is not yet complete.
9028func (iter ExpressRouteCrossConnectionListResultIterator) NotDone() bool {
9029	return iter.page.NotDone() && iter.i < len(iter.page.Values())
9030}
9031
9032// Response returns the raw server response from the last page request.
9033func (iter ExpressRouteCrossConnectionListResultIterator) Response() ExpressRouteCrossConnectionListResult {
9034	return iter.page.Response()
9035}
9036
9037// Value returns the current value or a zero-initialized value if the
9038// iterator has advanced beyond the end of the collection.
9039func (iter ExpressRouteCrossConnectionListResultIterator) Value() ExpressRouteCrossConnection {
9040	if !iter.page.NotDone() {
9041		return ExpressRouteCrossConnection{}
9042	}
9043	return iter.page.Values()[iter.i]
9044}
9045
9046// IsEmpty returns true if the ListResult contains no values.
9047func (ercclr ExpressRouteCrossConnectionListResult) IsEmpty() bool {
9048	return ercclr.Value == nil || len(*ercclr.Value) == 0
9049}
9050
9051// expressRouteCrossConnectionListResultPreparer prepares a request to retrieve the next set of results.
9052// It returns nil if no more results exist.
9053func (ercclr ExpressRouteCrossConnectionListResult) expressRouteCrossConnectionListResultPreparer() (*http.Request, error) {
9054	if ercclr.NextLink == nil || len(to.String(ercclr.NextLink)) < 1 {
9055		return nil, nil
9056	}
9057	return autorest.Prepare(&http.Request{},
9058		autorest.AsJSON(),
9059		autorest.AsGet(),
9060		autorest.WithBaseURL(to.String(ercclr.NextLink)))
9061}
9062
9063// ExpressRouteCrossConnectionListResultPage contains a page of ExpressRouteCrossConnection values.
9064type ExpressRouteCrossConnectionListResultPage struct {
9065	fn     func(ExpressRouteCrossConnectionListResult) (ExpressRouteCrossConnectionListResult, error)
9066	ercclr ExpressRouteCrossConnectionListResult
9067}
9068
9069// Next advances to the next page of values.  If there was an error making
9070// the request the page does not advance and the error is returned.
9071func (page *ExpressRouteCrossConnectionListResultPage) Next() error {
9072	next, err := page.fn(page.ercclr)
9073	if err != nil {
9074		return err
9075	}
9076	page.ercclr = next
9077	return nil
9078}
9079
9080// NotDone returns true if the page enumeration should be started or is not yet complete.
9081func (page ExpressRouteCrossConnectionListResultPage) NotDone() bool {
9082	return !page.ercclr.IsEmpty()
9083}
9084
9085// Response returns the raw server response from the last page request.
9086func (page ExpressRouteCrossConnectionListResultPage) Response() ExpressRouteCrossConnectionListResult {
9087	return page.ercclr
9088}
9089
9090// Values returns the slice of values for the current page or nil if there are no values.
9091func (page ExpressRouteCrossConnectionListResultPage) Values() []ExpressRouteCrossConnection {
9092	if page.ercclr.IsEmpty() {
9093		return nil
9094	}
9095	return *page.ercclr.Value
9096}
9097
9098// ExpressRouteCrossConnectionPeering peering in an ExpressRoute Cross Connection resource.
9099type ExpressRouteCrossConnectionPeering struct {
9100	autorest.Response                             `json:"-"`
9101	*ExpressRouteCrossConnectionPeeringProperties `json:"properties,omitempty"`
9102	// Name - Gets name of the resource that is unique within a resource group. This name can be used to access the resource.
9103	Name *string `json:"name,omitempty"`
9104	// Etag - A unique read-only string that changes whenever the resource is updated.
9105	Etag *string `json:"etag,omitempty"`
9106	// ID - Resource ID.
9107	ID *string `json:"id,omitempty"`
9108}
9109
9110// MarshalJSON is the custom marshaler for ExpressRouteCrossConnectionPeering.
9111func (erccp ExpressRouteCrossConnectionPeering) MarshalJSON() ([]byte, error) {
9112	objectMap := make(map[string]interface{})
9113	if erccp.ExpressRouteCrossConnectionPeeringProperties != nil {
9114		objectMap["properties"] = erccp.ExpressRouteCrossConnectionPeeringProperties
9115	}
9116	if erccp.Name != nil {
9117		objectMap["name"] = erccp.Name
9118	}
9119	if erccp.Etag != nil {
9120		objectMap["etag"] = erccp.Etag
9121	}
9122	if erccp.ID != nil {
9123		objectMap["id"] = erccp.ID
9124	}
9125	return json.Marshal(objectMap)
9126}
9127
9128// UnmarshalJSON is the custom unmarshaler for ExpressRouteCrossConnectionPeering struct.
9129func (erccp *ExpressRouteCrossConnectionPeering) UnmarshalJSON(body []byte) error {
9130	var m map[string]*json.RawMessage
9131	err := json.Unmarshal(body, &m)
9132	if err != nil {
9133		return err
9134	}
9135	for k, v := range m {
9136		switch k {
9137		case "properties":
9138			if v != nil {
9139				var expressRouteCrossConnectionPeeringProperties ExpressRouteCrossConnectionPeeringProperties
9140				err = json.Unmarshal(*v, &expressRouteCrossConnectionPeeringProperties)
9141				if err != nil {
9142					return err
9143				}
9144				erccp.ExpressRouteCrossConnectionPeeringProperties = &expressRouteCrossConnectionPeeringProperties
9145			}
9146		case "name":
9147			if v != nil {
9148				var name string
9149				err = json.Unmarshal(*v, &name)
9150				if err != nil {
9151					return err
9152				}
9153				erccp.Name = &name
9154			}
9155		case "etag":
9156			if v != nil {
9157				var etag string
9158				err = json.Unmarshal(*v, &etag)
9159				if err != nil {
9160					return err
9161				}
9162				erccp.Etag = &etag
9163			}
9164		case "id":
9165			if v != nil {
9166				var ID string
9167				err = json.Unmarshal(*v, &ID)
9168				if err != nil {
9169					return err
9170				}
9171				erccp.ID = &ID
9172			}
9173		}
9174	}
9175
9176	return nil
9177}
9178
9179// ExpressRouteCrossConnectionPeeringList response for ListPeering API service call retrieves all peerings that
9180// belong to an ExpressRouteCrossConnection.
9181type ExpressRouteCrossConnectionPeeringList struct {
9182	autorest.Response `json:"-"`
9183	// Value - The peerings in an express route cross connection.
9184	Value *[]ExpressRouteCrossConnectionPeering `json:"value,omitempty"`
9185	// NextLink - The URL to get the next set of results.
9186	NextLink *string `json:"nextLink,omitempty"`
9187}
9188
9189// ExpressRouteCrossConnectionPeeringListIterator provides access to a complete listing of
9190// ExpressRouteCrossConnectionPeering values.
9191type ExpressRouteCrossConnectionPeeringListIterator struct {
9192	i    int
9193	page ExpressRouteCrossConnectionPeeringListPage
9194}
9195
9196// Next advances to the next value.  If there was an error making
9197// the request the iterator does not advance and the error is returned.
9198func (iter *ExpressRouteCrossConnectionPeeringListIterator) Next() error {
9199	iter.i++
9200	if iter.i < len(iter.page.Values()) {
9201		return nil
9202	}
9203	err := iter.page.Next()
9204	if err != nil {
9205		iter.i--
9206		return err
9207	}
9208	iter.i = 0
9209	return nil
9210}
9211
9212// NotDone returns true if the enumeration should be started or is not yet complete.
9213func (iter ExpressRouteCrossConnectionPeeringListIterator) NotDone() bool {
9214	return iter.page.NotDone() && iter.i < len(iter.page.Values())
9215}
9216
9217// Response returns the raw server response from the last page request.
9218func (iter ExpressRouteCrossConnectionPeeringListIterator) Response() ExpressRouteCrossConnectionPeeringList {
9219	return iter.page.Response()
9220}
9221
9222// Value returns the current value or a zero-initialized value if the
9223// iterator has advanced beyond the end of the collection.
9224func (iter ExpressRouteCrossConnectionPeeringListIterator) Value() ExpressRouteCrossConnectionPeering {
9225	if !iter.page.NotDone() {
9226		return ExpressRouteCrossConnectionPeering{}
9227	}
9228	return iter.page.Values()[iter.i]
9229}
9230
9231// IsEmpty returns true if the ListResult contains no values.
9232func (erccpl ExpressRouteCrossConnectionPeeringList) IsEmpty() bool {
9233	return erccpl.Value == nil || len(*erccpl.Value) == 0
9234}
9235
9236// expressRouteCrossConnectionPeeringListPreparer prepares a request to retrieve the next set of results.
9237// It returns nil if no more results exist.
9238func (erccpl ExpressRouteCrossConnectionPeeringList) expressRouteCrossConnectionPeeringListPreparer() (*http.Request, error) {
9239	if erccpl.NextLink == nil || len(to.String(erccpl.NextLink)) < 1 {
9240		return nil, nil
9241	}
9242	return autorest.Prepare(&http.Request{},
9243		autorest.AsJSON(),
9244		autorest.AsGet(),
9245		autorest.WithBaseURL(to.String(erccpl.NextLink)))
9246}
9247
9248// ExpressRouteCrossConnectionPeeringListPage contains a page of ExpressRouteCrossConnectionPeering values.
9249type ExpressRouteCrossConnectionPeeringListPage struct {
9250	fn     func(ExpressRouteCrossConnectionPeeringList) (ExpressRouteCrossConnectionPeeringList, error)
9251	erccpl ExpressRouteCrossConnectionPeeringList
9252}
9253
9254// Next advances to the next page of values.  If there was an error making
9255// the request the page does not advance and the error is returned.
9256func (page *ExpressRouteCrossConnectionPeeringListPage) Next() error {
9257	next, err := page.fn(page.erccpl)
9258	if err != nil {
9259		return err
9260	}
9261	page.erccpl = next
9262	return nil
9263}
9264
9265// NotDone returns true if the page enumeration should be started or is not yet complete.
9266func (page ExpressRouteCrossConnectionPeeringListPage) NotDone() bool {
9267	return !page.erccpl.IsEmpty()
9268}
9269
9270// Response returns the raw server response from the last page request.
9271func (page ExpressRouteCrossConnectionPeeringListPage) Response() ExpressRouteCrossConnectionPeeringList {
9272	return page.erccpl
9273}
9274
9275// Values returns the slice of values for the current page or nil if there are no values.
9276func (page ExpressRouteCrossConnectionPeeringListPage) Values() []ExpressRouteCrossConnectionPeering {
9277	if page.erccpl.IsEmpty() {
9278		return nil
9279	}
9280	return *page.erccpl.Value
9281}
9282
9283// ExpressRouteCrossConnectionPeeringProperties ...
9284type ExpressRouteCrossConnectionPeeringProperties struct {
9285	// PeeringType - The peering type. Possible values include: 'AzurePublicPeering', 'AzurePrivatePeering', 'MicrosoftPeering'
9286	PeeringType ExpressRoutePeeringType `json:"peeringType,omitempty"`
9287	// State - The peering state. Possible values include: 'ExpressRoutePeeringStateDisabled', 'ExpressRoutePeeringStateEnabled'
9288	State ExpressRoutePeeringState `json:"state,omitempty"`
9289	// AzureASN - The Azure ASN.
9290	AzureASN *int32 `json:"azureASN,omitempty"`
9291	// PeerASN - The peer ASN.
9292	PeerASN *int64 `json:"peerASN,omitempty"`
9293	// PrimaryPeerAddressPrefix - The primary address prefix.
9294	PrimaryPeerAddressPrefix *string `json:"primaryPeerAddressPrefix,omitempty"`
9295	// SecondaryPeerAddressPrefix - The secondary address prefix.
9296	SecondaryPeerAddressPrefix *string `json:"secondaryPeerAddressPrefix,omitempty"`
9297	// PrimaryAzurePort - The primary port.
9298	PrimaryAzurePort *string `json:"primaryAzurePort,omitempty"`
9299	// SecondaryAzurePort - The secondary port.
9300	SecondaryAzurePort *string `json:"secondaryAzurePort,omitempty"`
9301	// SharedKey - The shared key.
9302	SharedKey *string `json:"sharedKey,omitempty"`
9303	// VlanID - The VLAN ID.
9304	VlanID *int32 `json:"vlanId,omitempty"`
9305	// MicrosoftPeeringConfig - The Microsoft peering configuration.
9306	MicrosoftPeeringConfig *ExpressRouteCircuitPeeringConfig `json:"microsoftPeeringConfig,omitempty"`
9307	// ProvisioningState - Gets the provisioning state of the public IP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
9308	ProvisioningState *string `json:"provisioningState,omitempty"`
9309	// GatewayManagerEtag - The GatewayManager Etag.
9310	GatewayManagerEtag *string `json:"gatewayManagerEtag,omitempty"`
9311	// LastModifiedBy - Gets whether the provider or the customer last modified the peering.
9312	LastModifiedBy *string `json:"lastModifiedBy,omitempty"`
9313	// Ipv6PeeringConfig - The IPv6 peering configuration.
9314	Ipv6PeeringConfig *Ipv6ExpressRouteCircuitPeeringConfig `json:"ipv6PeeringConfig,omitempty"`
9315}
9316
9317// ExpressRouteCrossConnectionPeeringsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results
9318// of a long-running operation.
9319type ExpressRouteCrossConnectionPeeringsCreateOrUpdateFuture struct {
9320	azure.Future
9321}
9322
9323// Result returns the result of the asynchronous operation.
9324// If the operation has not completed it will return an error.
9325func (future *ExpressRouteCrossConnectionPeeringsCreateOrUpdateFuture) Result(client ExpressRouteCrossConnectionPeeringsClient) (erccp ExpressRouteCrossConnectionPeering, err error) {
9326	var done bool
9327	done, err = future.Done(client)
9328	if err != nil {
9329		err = autorest.NewErrorWithError(err, "network.ExpressRouteCrossConnectionPeeringsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
9330		return
9331	}
9332	if !done {
9333		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCrossConnectionPeeringsCreateOrUpdateFuture")
9334		return
9335	}
9336	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
9337	if erccp.Response.Response, err = future.GetResult(sender); err == nil && erccp.Response.Response.StatusCode != http.StatusNoContent {
9338		erccp, err = client.CreateOrUpdateResponder(erccp.Response.Response)
9339		if err != nil {
9340			err = autorest.NewErrorWithError(err, "network.ExpressRouteCrossConnectionPeeringsCreateOrUpdateFuture", "Result", erccp.Response.Response, "Failure responding to request")
9341		}
9342	}
9343	return
9344}
9345
9346// ExpressRouteCrossConnectionPeeringsDeleteFuture an abstraction for monitoring and retrieving the results of a
9347// long-running operation.
9348type ExpressRouteCrossConnectionPeeringsDeleteFuture struct {
9349	azure.Future
9350}
9351
9352// Result returns the result of the asynchronous operation.
9353// If the operation has not completed it will return an error.
9354func (future *ExpressRouteCrossConnectionPeeringsDeleteFuture) Result(client ExpressRouteCrossConnectionPeeringsClient) (ar autorest.Response, err error) {
9355	var done bool
9356	done, err = future.Done(client)
9357	if err != nil {
9358		err = autorest.NewErrorWithError(err, "network.ExpressRouteCrossConnectionPeeringsDeleteFuture", "Result", future.Response(), "Polling failure")
9359		return
9360	}
9361	if !done {
9362		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCrossConnectionPeeringsDeleteFuture")
9363		return
9364	}
9365	ar.Response = future.Response()
9366	return
9367}
9368
9369// ExpressRouteCrossConnectionProperties properties of ExpressRouteCrossConnection.
9370type ExpressRouteCrossConnectionProperties struct {
9371	// PrimaryAzurePort - The name of the primary  port.
9372	PrimaryAzurePort *string `json:"primaryAzurePort,omitempty"`
9373	// SecondaryAzurePort - The name of the secondary  port.
9374	SecondaryAzurePort *string `json:"secondaryAzurePort,omitempty"`
9375	// STag - The identifier of the circuit traffic.
9376	STag *int32 `json:"sTag,omitempty"`
9377	// PeeringLocation - The peering location of the ExpressRoute circuit.
9378	PeeringLocation *string `json:"peeringLocation,omitempty"`
9379	// BandwidthInMbps - The circuit bandwidth In Mbps.
9380	BandwidthInMbps *int32 `json:"bandwidthInMbps,omitempty"`
9381	// ExpressRouteCircuit - The ExpressRouteCircuit
9382	ExpressRouteCircuit *ExpressRouteCircuitReference `json:"expressRouteCircuit,omitempty"`
9383	// 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'
9384	ServiceProviderProvisioningState ServiceProviderProvisioningState `json:"serviceProviderProvisioningState,omitempty"`
9385	// ServiceProviderNotes - Additional read only notes set by the connectivity provider.
9386	ServiceProviderNotes *string `json:"serviceProviderNotes,omitempty"`
9387	// ProvisioningState - Gets the provisioning state of the public IP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
9388	ProvisioningState *string `json:"provisioningState,omitempty"`
9389	// Peerings - The list of peerings.
9390	Peerings *[]ExpressRouteCrossConnectionPeering `json:"peerings,omitempty"`
9391}
9392
9393// ExpressRouteCrossConnectionRoutesTableSummary the routes table associated with the ExpressRouteCircuit.
9394type ExpressRouteCrossConnectionRoutesTableSummary struct {
9395	// Neighbor - IP address of Neighbor router
9396	Neighbor *string `json:"neighbor,omitempty"`
9397	// Asn - Autonomous system number.
9398	Asn *int32 `json:"asn,omitempty"`
9399	// UpDown - The length of time that the BGP session has been in the Established state, or the current status if not in the Established state.
9400	UpDown *string `json:"upDown,omitempty"`
9401	// StateOrPrefixesReceived - Current state of the BGP session, and the number of prefixes that have been received from a neighbor or peer group.
9402	StateOrPrefixesReceived *string `json:"stateOrPrefixesReceived,omitempty"`
9403}
9404
9405// ExpressRouteCrossConnectionsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
9406// long-running operation.
9407type ExpressRouteCrossConnectionsCreateOrUpdateFuture struct {
9408	azure.Future
9409}
9410
9411// Result returns the result of the asynchronous operation.
9412// If the operation has not completed it will return an error.
9413func (future *ExpressRouteCrossConnectionsCreateOrUpdateFuture) Result(client ExpressRouteCrossConnectionsClient) (ercc ExpressRouteCrossConnection, err error) {
9414	var done bool
9415	done, err = future.Done(client)
9416	if err != nil {
9417		err = autorest.NewErrorWithError(err, "network.ExpressRouteCrossConnectionsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
9418		return
9419	}
9420	if !done {
9421		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCrossConnectionsCreateOrUpdateFuture")
9422		return
9423	}
9424	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
9425	if ercc.Response.Response, err = future.GetResult(sender); err == nil && ercc.Response.Response.StatusCode != http.StatusNoContent {
9426		ercc, err = client.CreateOrUpdateResponder(ercc.Response.Response)
9427		if err != nil {
9428			err = autorest.NewErrorWithError(err, "network.ExpressRouteCrossConnectionsCreateOrUpdateFuture", "Result", ercc.Response.Response, "Failure responding to request")
9429		}
9430	}
9431	return
9432}
9433
9434// ExpressRouteCrossConnectionsListArpTableFuture an abstraction for monitoring and retrieving the results of a
9435// long-running operation.
9436type ExpressRouteCrossConnectionsListArpTableFuture struct {
9437	azure.Future
9438}
9439
9440// Result returns the result of the asynchronous operation.
9441// If the operation has not completed it will return an error.
9442func (future *ExpressRouteCrossConnectionsListArpTableFuture) Result(client ExpressRouteCrossConnectionsClient) (ercatlr ExpressRouteCircuitsArpTableListResult, err error) {
9443	var done bool
9444	done, err = future.Done(client)
9445	if err != nil {
9446		err = autorest.NewErrorWithError(err, "network.ExpressRouteCrossConnectionsListArpTableFuture", "Result", future.Response(), "Polling failure")
9447		return
9448	}
9449	if !done {
9450		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCrossConnectionsListArpTableFuture")
9451		return
9452	}
9453	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
9454	if ercatlr.Response.Response, err = future.GetResult(sender); err == nil && ercatlr.Response.Response.StatusCode != http.StatusNoContent {
9455		ercatlr, err = client.ListArpTableResponder(ercatlr.Response.Response)
9456		if err != nil {
9457			err = autorest.NewErrorWithError(err, "network.ExpressRouteCrossConnectionsListArpTableFuture", "Result", ercatlr.Response.Response, "Failure responding to request")
9458		}
9459	}
9460	return
9461}
9462
9463// ExpressRouteCrossConnectionsListRoutesTableFuture an abstraction for monitoring and retrieving the results of a
9464// long-running operation.
9465type ExpressRouteCrossConnectionsListRoutesTableFuture struct {
9466	azure.Future
9467}
9468
9469// Result returns the result of the asynchronous operation.
9470// If the operation has not completed it will return an error.
9471func (future *ExpressRouteCrossConnectionsListRoutesTableFuture) Result(client ExpressRouteCrossConnectionsClient) (ercrtlr ExpressRouteCircuitsRoutesTableListResult, err error) {
9472	var done bool
9473	done, err = future.Done(client)
9474	if err != nil {
9475		err = autorest.NewErrorWithError(err, "network.ExpressRouteCrossConnectionsListRoutesTableFuture", "Result", future.Response(), "Polling failure")
9476		return
9477	}
9478	if !done {
9479		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCrossConnectionsListRoutesTableFuture")
9480		return
9481	}
9482	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
9483	if ercrtlr.Response.Response, err = future.GetResult(sender); err == nil && ercrtlr.Response.Response.StatusCode != http.StatusNoContent {
9484		ercrtlr, err = client.ListRoutesTableResponder(ercrtlr.Response.Response)
9485		if err != nil {
9486			err = autorest.NewErrorWithError(err, "network.ExpressRouteCrossConnectionsListRoutesTableFuture", "Result", ercrtlr.Response.Response, "Failure responding to request")
9487		}
9488	}
9489	return
9490}
9491
9492// ExpressRouteCrossConnectionsListRoutesTableSummaryFuture an abstraction for monitoring and retrieving the
9493// results of a long-running operation.
9494type ExpressRouteCrossConnectionsListRoutesTableSummaryFuture struct {
9495	azure.Future
9496}
9497
9498// Result returns the result of the asynchronous operation.
9499// If the operation has not completed it will return an error.
9500func (future *ExpressRouteCrossConnectionsListRoutesTableSummaryFuture) Result(client ExpressRouteCrossConnectionsClient) (erccrtslr ExpressRouteCrossConnectionsRoutesTableSummaryListResult, err error) {
9501	var done bool
9502	done, err = future.Done(client)
9503	if err != nil {
9504		err = autorest.NewErrorWithError(err, "network.ExpressRouteCrossConnectionsListRoutesTableSummaryFuture", "Result", future.Response(), "Polling failure")
9505		return
9506	}
9507	if !done {
9508		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCrossConnectionsListRoutesTableSummaryFuture")
9509		return
9510	}
9511	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
9512	if erccrtslr.Response.Response, err = future.GetResult(sender); err == nil && erccrtslr.Response.Response.StatusCode != http.StatusNoContent {
9513		erccrtslr, err = client.ListRoutesTableSummaryResponder(erccrtslr.Response.Response)
9514		if err != nil {
9515			err = autorest.NewErrorWithError(err, "network.ExpressRouteCrossConnectionsListRoutesTableSummaryFuture", "Result", erccrtslr.Response.Response, "Failure responding to request")
9516		}
9517	}
9518	return
9519}
9520
9521// ExpressRouteCrossConnectionsRoutesTableSummaryListResult response for ListRoutesTable associated with the
9522// Express Route Cross Connections.
9523type ExpressRouteCrossConnectionsRoutesTableSummaryListResult struct {
9524	autorest.Response `json:"-"`
9525	// Value - A list of the routes table.
9526	Value *[]ExpressRouteCrossConnectionRoutesTableSummary `json:"value,omitempty"`
9527	// NextLink - The URL to get the next set of results.
9528	NextLink *string `json:"nextLink,omitempty"`
9529}
9530
9531// ExpressRouteCrossConnectionsUpdateTagsFuture an abstraction for monitoring and retrieving the results of a
9532// long-running operation.
9533type ExpressRouteCrossConnectionsUpdateTagsFuture struct {
9534	azure.Future
9535}
9536
9537// Result returns the result of the asynchronous operation.
9538// If the operation has not completed it will return an error.
9539func (future *ExpressRouteCrossConnectionsUpdateTagsFuture) Result(client ExpressRouteCrossConnectionsClient) (ercc ExpressRouteCrossConnection, err error) {
9540	var done bool
9541	done, err = future.Done(client)
9542	if err != nil {
9543		err = autorest.NewErrorWithError(err, "network.ExpressRouteCrossConnectionsUpdateTagsFuture", "Result", future.Response(), "Polling failure")
9544		return
9545	}
9546	if !done {
9547		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCrossConnectionsUpdateTagsFuture")
9548		return
9549	}
9550	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
9551	if ercc.Response.Response, err = future.GetResult(sender); err == nil && ercc.Response.Response.StatusCode != http.StatusNoContent {
9552		ercc, err = client.UpdateTagsResponder(ercc.Response.Response)
9553		if err != nil {
9554			err = autorest.NewErrorWithError(err, "network.ExpressRouteCrossConnectionsUpdateTagsFuture", "Result", ercc.Response.Response, "Failure responding to request")
9555		}
9556	}
9557	return
9558}
9559
9560// ExpressRouteGateway expressRoute gateway resource.
9561type ExpressRouteGateway struct {
9562	autorest.Response              `json:"-"`
9563	*ExpressRouteGatewayProperties `json:"properties,omitempty"`
9564	// Etag - A unique read-only string that changes whenever the resource is updated.
9565	Etag *string `json:"etag,omitempty"`
9566	// ID - Resource ID.
9567	ID *string `json:"id,omitempty"`
9568	// Name - Resource name.
9569	Name *string `json:"name,omitempty"`
9570	// Type - Resource type.
9571	Type *string `json:"type,omitempty"`
9572	// Location - Resource location.
9573	Location *string `json:"location,omitempty"`
9574	// Tags - Resource tags.
9575	Tags map[string]*string `json:"tags"`
9576}
9577
9578// MarshalJSON is the custom marshaler for ExpressRouteGateway.
9579func (erg ExpressRouteGateway) MarshalJSON() ([]byte, error) {
9580	objectMap := make(map[string]interface{})
9581	if erg.ExpressRouteGatewayProperties != nil {
9582		objectMap["properties"] = erg.ExpressRouteGatewayProperties
9583	}
9584	if erg.Etag != nil {
9585		objectMap["etag"] = erg.Etag
9586	}
9587	if erg.ID != nil {
9588		objectMap["id"] = erg.ID
9589	}
9590	if erg.Name != nil {
9591		objectMap["name"] = erg.Name
9592	}
9593	if erg.Type != nil {
9594		objectMap["type"] = erg.Type
9595	}
9596	if erg.Location != nil {
9597		objectMap["location"] = erg.Location
9598	}
9599	if erg.Tags != nil {
9600		objectMap["tags"] = erg.Tags
9601	}
9602	return json.Marshal(objectMap)
9603}
9604
9605// UnmarshalJSON is the custom unmarshaler for ExpressRouteGateway struct.
9606func (erg *ExpressRouteGateway) UnmarshalJSON(body []byte) error {
9607	var m map[string]*json.RawMessage
9608	err := json.Unmarshal(body, &m)
9609	if err != nil {
9610		return err
9611	}
9612	for k, v := range m {
9613		switch k {
9614		case "properties":
9615			if v != nil {
9616				var expressRouteGatewayProperties ExpressRouteGatewayProperties
9617				err = json.Unmarshal(*v, &expressRouteGatewayProperties)
9618				if err != nil {
9619					return err
9620				}
9621				erg.ExpressRouteGatewayProperties = &expressRouteGatewayProperties
9622			}
9623		case "etag":
9624			if v != nil {
9625				var etag string
9626				err = json.Unmarshal(*v, &etag)
9627				if err != nil {
9628					return err
9629				}
9630				erg.Etag = &etag
9631			}
9632		case "id":
9633			if v != nil {
9634				var ID string
9635				err = json.Unmarshal(*v, &ID)
9636				if err != nil {
9637					return err
9638				}
9639				erg.ID = &ID
9640			}
9641		case "name":
9642			if v != nil {
9643				var name string
9644				err = json.Unmarshal(*v, &name)
9645				if err != nil {
9646					return err
9647				}
9648				erg.Name = &name
9649			}
9650		case "type":
9651			if v != nil {
9652				var typeVar string
9653				err = json.Unmarshal(*v, &typeVar)
9654				if err != nil {
9655					return err
9656				}
9657				erg.Type = &typeVar
9658			}
9659		case "location":
9660			if v != nil {
9661				var location string
9662				err = json.Unmarshal(*v, &location)
9663				if err != nil {
9664					return err
9665				}
9666				erg.Location = &location
9667			}
9668		case "tags":
9669			if v != nil {
9670				var tags map[string]*string
9671				err = json.Unmarshal(*v, &tags)
9672				if err != nil {
9673					return err
9674				}
9675				erg.Tags = tags
9676			}
9677		}
9678	}
9679
9680	return nil
9681}
9682
9683// ExpressRouteGatewayList list of ExpressRoute gateways.
9684type ExpressRouteGatewayList struct {
9685	autorest.Response `json:"-"`
9686	// Value - List of ExpressRoute gateways.
9687	Value *[]ExpressRouteGateway `json:"value,omitempty"`
9688}
9689
9690// ExpressRouteGatewayProperties expressRoute gateway resource properties.
9691type ExpressRouteGatewayProperties struct {
9692	// AutoScaleConfiguration - Configuration for auto scaling.
9693	AutoScaleConfiguration *ExpressRouteGatewayPropertiesAutoScaleConfiguration `json:"autoScaleConfiguration,omitempty"`
9694	// ExpressRouteConnections - List of ExpressRoute connections to the ExpressRoute gateway.
9695	ExpressRouteConnections *[]ExpressRouteConnection `json:"expressRouteConnections,omitempty"`
9696	// ProvisioningState - The provisioning state of the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
9697	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
9698	// VirtualHub - The Virtual Hub where the ExpressRoute gateway is or will be deployed.
9699	VirtualHub *VirtualHubID `json:"virtualHub,omitempty"`
9700}
9701
9702// ExpressRouteGatewayPropertiesAutoScaleConfiguration configuration for auto scaling.
9703type ExpressRouteGatewayPropertiesAutoScaleConfiguration struct {
9704	// Bounds - Minimum and maximum number of scale units to deploy.
9705	Bounds *ExpressRouteGatewayPropertiesAutoScaleConfigurationBounds `json:"bounds,omitempty"`
9706}
9707
9708// ExpressRouteGatewayPropertiesAutoScaleConfigurationBounds minimum and maximum number of scale units to deploy.
9709type ExpressRouteGatewayPropertiesAutoScaleConfigurationBounds struct {
9710	// Min - Minimum number of scale units deployed for ExpressRoute gateway.
9711	Min *int32 `json:"min,omitempty"`
9712	// Max - Maximum number of scale units deployed for ExpressRoute gateway.
9713	Max *int32 `json:"max,omitempty"`
9714}
9715
9716// ExpressRouteGatewaysCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
9717// long-running operation.
9718type ExpressRouteGatewaysCreateOrUpdateFuture struct {
9719	azure.Future
9720}
9721
9722// Result returns the result of the asynchronous operation.
9723// If the operation has not completed it will return an error.
9724func (future *ExpressRouteGatewaysCreateOrUpdateFuture) Result(client ExpressRouteGatewaysClient) (erg ExpressRouteGateway, err error) {
9725	var done bool
9726	done, err = future.Done(client)
9727	if err != nil {
9728		err = autorest.NewErrorWithError(err, "network.ExpressRouteGatewaysCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
9729		return
9730	}
9731	if !done {
9732		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteGatewaysCreateOrUpdateFuture")
9733		return
9734	}
9735	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
9736	if erg.Response.Response, err = future.GetResult(sender); err == nil && erg.Response.Response.StatusCode != http.StatusNoContent {
9737		erg, err = client.CreateOrUpdateResponder(erg.Response.Response)
9738		if err != nil {
9739			err = autorest.NewErrorWithError(err, "network.ExpressRouteGatewaysCreateOrUpdateFuture", "Result", erg.Response.Response, "Failure responding to request")
9740		}
9741	}
9742	return
9743}
9744
9745// ExpressRouteGatewaysDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
9746// operation.
9747type ExpressRouteGatewaysDeleteFuture struct {
9748	azure.Future
9749}
9750
9751// Result returns the result of the asynchronous operation.
9752// If the operation has not completed it will return an error.
9753func (future *ExpressRouteGatewaysDeleteFuture) Result(client ExpressRouteGatewaysClient) (ar autorest.Response, err error) {
9754	var done bool
9755	done, err = future.Done(client)
9756	if err != nil {
9757		err = autorest.NewErrorWithError(err, "network.ExpressRouteGatewaysDeleteFuture", "Result", future.Response(), "Polling failure")
9758		return
9759	}
9760	if !done {
9761		err = azure.NewAsyncOpIncompleteError("network.ExpressRouteGatewaysDeleteFuture")
9762		return
9763	}
9764	ar.Response = future.Response()
9765	return
9766}
9767
9768// ExpressRouteServiceProvider a ExpressRouteResourceProvider object.
9769type ExpressRouteServiceProvider struct {
9770	*ExpressRouteServiceProviderPropertiesFormat `json:"properties,omitempty"`
9771	// ID - Resource ID.
9772	ID *string `json:"id,omitempty"`
9773	// Name - Resource name.
9774	Name *string `json:"name,omitempty"`
9775	// Type - Resource type.
9776	Type *string `json:"type,omitempty"`
9777	// Location - Resource location.
9778	Location *string `json:"location,omitempty"`
9779	// Tags - Resource tags.
9780	Tags map[string]*string `json:"tags"`
9781}
9782
9783// MarshalJSON is the custom marshaler for ExpressRouteServiceProvider.
9784func (ersp ExpressRouteServiceProvider) MarshalJSON() ([]byte, error) {
9785	objectMap := make(map[string]interface{})
9786	if ersp.ExpressRouteServiceProviderPropertiesFormat != nil {
9787		objectMap["properties"] = ersp.ExpressRouteServiceProviderPropertiesFormat
9788	}
9789	if ersp.ID != nil {
9790		objectMap["id"] = ersp.ID
9791	}
9792	if ersp.Name != nil {
9793		objectMap["name"] = ersp.Name
9794	}
9795	if ersp.Type != nil {
9796		objectMap["type"] = ersp.Type
9797	}
9798	if ersp.Location != nil {
9799		objectMap["location"] = ersp.Location
9800	}
9801	if ersp.Tags != nil {
9802		objectMap["tags"] = ersp.Tags
9803	}
9804	return json.Marshal(objectMap)
9805}
9806
9807// UnmarshalJSON is the custom unmarshaler for ExpressRouteServiceProvider struct.
9808func (ersp *ExpressRouteServiceProvider) UnmarshalJSON(body []byte) error {
9809	var m map[string]*json.RawMessage
9810	err := json.Unmarshal(body, &m)
9811	if err != nil {
9812		return err
9813	}
9814	for k, v := range m {
9815		switch k {
9816		case "properties":
9817			if v != nil {
9818				var expressRouteServiceProviderPropertiesFormat ExpressRouteServiceProviderPropertiesFormat
9819				err = json.Unmarshal(*v, &expressRouteServiceProviderPropertiesFormat)
9820				if err != nil {
9821					return err
9822				}
9823				ersp.ExpressRouteServiceProviderPropertiesFormat = &expressRouteServiceProviderPropertiesFormat
9824			}
9825		case "id":
9826			if v != nil {
9827				var ID string
9828				err = json.Unmarshal(*v, &ID)
9829				if err != nil {
9830					return err
9831				}
9832				ersp.ID = &ID
9833			}
9834		case "name":
9835			if v != nil {
9836				var name string
9837				err = json.Unmarshal(*v, &name)
9838				if err != nil {
9839					return err
9840				}
9841				ersp.Name = &name
9842			}
9843		case "type":
9844			if v != nil {
9845				var typeVar string
9846				err = json.Unmarshal(*v, &typeVar)
9847				if err != nil {
9848					return err
9849				}
9850				ersp.Type = &typeVar
9851			}
9852		case "location":
9853			if v != nil {
9854				var location string
9855				err = json.Unmarshal(*v, &location)
9856				if err != nil {
9857					return err
9858				}
9859				ersp.Location = &location
9860			}
9861		case "tags":
9862			if v != nil {
9863				var tags map[string]*string
9864				err = json.Unmarshal(*v, &tags)
9865				if err != nil {
9866					return err
9867				}
9868				ersp.Tags = tags
9869			}
9870		}
9871	}
9872
9873	return nil
9874}
9875
9876// ExpressRouteServiceProviderBandwidthsOffered contains bandwidths offered in ExpressRouteServiceProvider
9877// resources.
9878type ExpressRouteServiceProviderBandwidthsOffered struct {
9879	// OfferName - The OfferName.
9880	OfferName *string `json:"offerName,omitempty"`
9881	// ValueInMbps - The ValueInMbps.
9882	ValueInMbps *int32 `json:"valueInMbps,omitempty"`
9883}
9884
9885// ExpressRouteServiceProviderListResult response for the ListExpressRouteServiceProvider API service call.
9886type ExpressRouteServiceProviderListResult struct {
9887	autorest.Response `json:"-"`
9888	// Value - A list of ExpressRouteResourceProvider resources.
9889	Value *[]ExpressRouteServiceProvider `json:"value,omitempty"`
9890	// NextLink - The URL to get the next set of results.
9891	NextLink *string `json:"nextLink,omitempty"`
9892}
9893
9894// ExpressRouteServiceProviderListResultIterator provides access to a complete listing of
9895// ExpressRouteServiceProvider values.
9896type ExpressRouteServiceProviderListResultIterator struct {
9897	i    int
9898	page ExpressRouteServiceProviderListResultPage
9899}
9900
9901// Next advances to the next value.  If there was an error making
9902// the request the iterator does not advance and the error is returned.
9903func (iter *ExpressRouteServiceProviderListResultIterator) Next() error {
9904	iter.i++
9905	if iter.i < len(iter.page.Values()) {
9906		return nil
9907	}
9908	err := iter.page.Next()
9909	if err != nil {
9910		iter.i--
9911		return err
9912	}
9913	iter.i = 0
9914	return nil
9915}
9916
9917// NotDone returns true if the enumeration should be started or is not yet complete.
9918func (iter ExpressRouteServiceProviderListResultIterator) NotDone() bool {
9919	return iter.page.NotDone() && iter.i < len(iter.page.Values())
9920}
9921
9922// Response returns the raw server response from the last page request.
9923func (iter ExpressRouteServiceProviderListResultIterator) Response() ExpressRouteServiceProviderListResult {
9924	return iter.page.Response()
9925}
9926
9927// Value returns the current value or a zero-initialized value if the
9928// iterator has advanced beyond the end of the collection.
9929func (iter ExpressRouteServiceProviderListResultIterator) Value() ExpressRouteServiceProvider {
9930	if !iter.page.NotDone() {
9931		return ExpressRouteServiceProvider{}
9932	}
9933	return iter.page.Values()[iter.i]
9934}
9935
9936// IsEmpty returns true if the ListResult contains no values.
9937func (ersplr ExpressRouteServiceProviderListResult) IsEmpty() bool {
9938	return ersplr.Value == nil || len(*ersplr.Value) == 0
9939}
9940
9941// expressRouteServiceProviderListResultPreparer prepares a request to retrieve the next set of results.
9942// It returns nil if no more results exist.
9943func (ersplr ExpressRouteServiceProviderListResult) expressRouteServiceProviderListResultPreparer() (*http.Request, error) {
9944	if ersplr.NextLink == nil || len(to.String(ersplr.NextLink)) < 1 {
9945		return nil, nil
9946	}
9947	return autorest.Prepare(&http.Request{},
9948		autorest.AsJSON(),
9949		autorest.AsGet(),
9950		autorest.WithBaseURL(to.String(ersplr.NextLink)))
9951}
9952
9953// ExpressRouteServiceProviderListResultPage contains a page of ExpressRouteServiceProvider values.
9954type ExpressRouteServiceProviderListResultPage struct {
9955	fn     func(ExpressRouteServiceProviderListResult) (ExpressRouteServiceProviderListResult, error)
9956	ersplr ExpressRouteServiceProviderListResult
9957}
9958
9959// Next advances to the next page of values.  If there was an error making
9960// the request the page does not advance and the error is returned.
9961func (page *ExpressRouteServiceProviderListResultPage) Next() error {
9962	next, err := page.fn(page.ersplr)
9963	if err != nil {
9964		return err
9965	}
9966	page.ersplr = next
9967	return nil
9968}
9969
9970// NotDone returns true if the page enumeration should be started or is not yet complete.
9971func (page ExpressRouteServiceProviderListResultPage) NotDone() bool {
9972	return !page.ersplr.IsEmpty()
9973}
9974
9975// Response returns the raw server response from the last page request.
9976func (page ExpressRouteServiceProviderListResultPage) Response() ExpressRouteServiceProviderListResult {
9977	return page.ersplr
9978}
9979
9980// Values returns the slice of values for the current page or nil if there are no values.
9981func (page ExpressRouteServiceProviderListResultPage) Values() []ExpressRouteServiceProvider {
9982	if page.ersplr.IsEmpty() {
9983		return nil
9984	}
9985	return *page.ersplr.Value
9986}
9987
9988// ExpressRouteServiceProviderPropertiesFormat properties of ExpressRouteServiceProvider.
9989type ExpressRouteServiceProviderPropertiesFormat struct {
9990	// PeeringLocations - Get a list of peering locations.
9991	PeeringLocations *[]string `json:"peeringLocations,omitempty"`
9992	// BandwidthsOffered - Gets bandwidths offered.
9993	BandwidthsOffered *[]ExpressRouteServiceProviderBandwidthsOffered `json:"bandwidthsOffered,omitempty"`
9994	// ProvisioningState - Gets the provisioning state of the resource.
9995	ProvisioningState *string `json:"provisioningState,omitempty"`
9996}
9997
9998// FlowLogInformation information on the configuration of flow log and traffic analytics (optional) .
9999type FlowLogInformation struct {
10000	autorest.Response `json:"-"`
10001	// TargetResourceID - The ID of the resource to configure for flow log and traffic analytics (optional) .
10002	TargetResourceID           *string `json:"targetResourceId,omitempty"`
10003	*FlowLogProperties         `json:"properties,omitempty"`
10004	FlowAnalyticsConfiguration *TrafficAnalyticsProperties `json:"flowAnalyticsConfiguration,omitempty"`
10005}
10006
10007// MarshalJSON is the custom marshaler for FlowLogInformation.
10008func (fli FlowLogInformation) MarshalJSON() ([]byte, error) {
10009	objectMap := make(map[string]interface{})
10010	if fli.TargetResourceID != nil {
10011		objectMap["targetResourceId"] = fli.TargetResourceID
10012	}
10013	if fli.FlowLogProperties != nil {
10014		objectMap["properties"] = fli.FlowLogProperties
10015	}
10016	if fli.FlowAnalyticsConfiguration != nil {
10017		objectMap["flowAnalyticsConfiguration"] = fli.FlowAnalyticsConfiguration
10018	}
10019	return json.Marshal(objectMap)
10020}
10021
10022// UnmarshalJSON is the custom unmarshaler for FlowLogInformation struct.
10023func (fli *FlowLogInformation) UnmarshalJSON(body []byte) error {
10024	var m map[string]*json.RawMessage
10025	err := json.Unmarshal(body, &m)
10026	if err != nil {
10027		return err
10028	}
10029	for k, v := range m {
10030		switch k {
10031		case "targetResourceId":
10032			if v != nil {
10033				var targetResourceID string
10034				err = json.Unmarshal(*v, &targetResourceID)
10035				if err != nil {
10036					return err
10037				}
10038				fli.TargetResourceID = &targetResourceID
10039			}
10040		case "properties":
10041			if v != nil {
10042				var flowLogProperties FlowLogProperties
10043				err = json.Unmarshal(*v, &flowLogProperties)
10044				if err != nil {
10045					return err
10046				}
10047				fli.FlowLogProperties = &flowLogProperties
10048			}
10049		case "flowAnalyticsConfiguration":
10050			if v != nil {
10051				var flowAnalyticsConfiguration TrafficAnalyticsProperties
10052				err = json.Unmarshal(*v, &flowAnalyticsConfiguration)
10053				if err != nil {
10054					return err
10055				}
10056				fli.FlowAnalyticsConfiguration = &flowAnalyticsConfiguration
10057			}
10058		}
10059	}
10060
10061	return nil
10062}
10063
10064// FlowLogProperties parameters that define the configuration of flow log.
10065type FlowLogProperties struct {
10066	// StorageID - ID of the storage account which is used to store the flow log.
10067	StorageID *string `json:"storageId,omitempty"`
10068	// Enabled - Flag to enable/disable flow logging.
10069	Enabled         *bool                      `json:"enabled,omitempty"`
10070	RetentionPolicy *RetentionPolicyParameters `json:"retentionPolicy,omitempty"`
10071}
10072
10073// FlowLogStatusParameters parameters that define a resource to query flow log and traffic analytics (optional)
10074// status.
10075type FlowLogStatusParameters struct {
10076	// TargetResourceID - The target resource where getting the flow log and traffic analytics (optional) status.
10077	TargetResourceID *string `json:"targetResourceId,omitempty"`
10078}
10079
10080// FrontendIPConfiguration frontend IP address of the load balancer.
10081type FrontendIPConfiguration struct {
10082	autorest.Response `json:"-"`
10083	// FrontendIPConfigurationPropertiesFormat - Properties of the load balancer probe.
10084	*FrontendIPConfigurationPropertiesFormat `json:"properties,omitempty"`
10085	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
10086	Name *string `json:"name,omitempty"`
10087	// Etag - A unique read-only string that changes whenever the resource is updated.
10088	Etag *string `json:"etag,omitempty"`
10089	// Zones - A list of availability zones denoting the IP allocated for the resource needs to come from.
10090	Zones *[]string `json:"zones,omitempty"`
10091	// ID - Resource ID.
10092	ID *string `json:"id,omitempty"`
10093}
10094
10095// MarshalJSON is the custom marshaler for FrontendIPConfiguration.
10096func (fic FrontendIPConfiguration) MarshalJSON() ([]byte, error) {
10097	objectMap := make(map[string]interface{})
10098	if fic.FrontendIPConfigurationPropertiesFormat != nil {
10099		objectMap["properties"] = fic.FrontendIPConfigurationPropertiesFormat
10100	}
10101	if fic.Name != nil {
10102		objectMap["name"] = fic.Name
10103	}
10104	if fic.Etag != nil {
10105		objectMap["etag"] = fic.Etag
10106	}
10107	if fic.Zones != nil {
10108		objectMap["zones"] = fic.Zones
10109	}
10110	if fic.ID != nil {
10111		objectMap["id"] = fic.ID
10112	}
10113	return json.Marshal(objectMap)
10114}
10115
10116// UnmarshalJSON is the custom unmarshaler for FrontendIPConfiguration struct.
10117func (fic *FrontendIPConfiguration) UnmarshalJSON(body []byte) error {
10118	var m map[string]*json.RawMessage
10119	err := json.Unmarshal(body, &m)
10120	if err != nil {
10121		return err
10122	}
10123	for k, v := range m {
10124		switch k {
10125		case "properties":
10126			if v != nil {
10127				var frontendIPConfigurationPropertiesFormat FrontendIPConfigurationPropertiesFormat
10128				err = json.Unmarshal(*v, &frontendIPConfigurationPropertiesFormat)
10129				if err != nil {
10130					return err
10131				}
10132				fic.FrontendIPConfigurationPropertiesFormat = &frontendIPConfigurationPropertiesFormat
10133			}
10134		case "name":
10135			if v != nil {
10136				var name string
10137				err = json.Unmarshal(*v, &name)
10138				if err != nil {
10139					return err
10140				}
10141				fic.Name = &name
10142			}
10143		case "etag":
10144			if v != nil {
10145				var etag string
10146				err = json.Unmarshal(*v, &etag)
10147				if err != nil {
10148					return err
10149				}
10150				fic.Etag = &etag
10151			}
10152		case "zones":
10153			if v != nil {
10154				var zones []string
10155				err = json.Unmarshal(*v, &zones)
10156				if err != nil {
10157					return err
10158				}
10159				fic.Zones = &zones
10160			}
10161		case "id":
10162			if v != nil {
10163				var ID string
10164				err = json.Unmarshal(*v, &ID)
10165				if err != nil {
10166					return err
10167				}
10168				fic.ID = &ID
10169			}
10170		}
10171	}
10172
10173	return nil
10174}
10175
10176// FrontendIPConfigurationPropertiesFormat properties of Frontend IP Configuration of the load balancer.
10177type FrontendIPConfigurationPropertiesFormat struct {
10178	// InboundNatRules - Read only. Inbound rules URIs that use this frontend IP.
10179	InboundNatRules *[]SubResource `json:"inboundNatRules,omitempty"`
10180	// InboundNatPools - Read only. Inbound pools URIs that use this frontend IP.
10181	InboundNatPools *[]SubResource `json:"inboundNatPools,omitempty"`
10182	// OutboundRules - Read only. Outbound rules URIs that use this frontend IP.
10183	OutboundRules *[]SubResource `json:"outboundRules,omitempty"`
10184	// LoadBalancingRules - Gets load balancing rules URIs that use this frontend IP.
10185	LoadBalancingRules *[]SubResource `json:"loadBalancingRules,omitempty"`
10186	// PrivateIPAddress - The private IP address of the IP configuration.
10187	PrivateIPAddress *string `json:"privateIPAddress,omitempty"`
10188	// PrivateIPAllocationMethod - The Private IP allocation method. Possible values are: 'Static' and 'Dynamic'. Possible values include: 'Static', 'Dynamic'
10189	PrivateIPAllocationMethod IPAllocationMethod `json:"privateIPAllocationMethod,omitempty"`
10190	// Subnet - The reference of the subnet resource.
10191	Subnet *Subnet `json:"subnet,omitempty"`
10192	// PublicIPAddress - The reference of the Public IP resource.
10193	PublicIPAddress *PublicIPAddress `json:"publicIPAddress,omitempty"`
10194	// PublicIPPrefix - The reference of the Public IP Prefix resource.
10195	PublicIPPrefix *SubResource `json:"publicIPPrefix,omitempty"`
10196	// ProvisioningState - Gets the provisioning state of the public IP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
10197	ProvisioningState *string `json:"provisioningState,omitempty"`
10198}
10199
10200// GatewayRoute gateway routing details
10201type GatewayRoute struct {
10202	// LocalAddress - The gateway's local address
10203	LocalAddress *string `json:"localAddress,omitempty"`
10204	// NetworkProperty - The route's network prefix
10205	NetworkProperty *string `json:"network,omitempty"`
10206	// NextHop - The route's next hop
10207	NextHop *string `json:"nextHop,omitempty"`
10208	// SourcePeer - The peer this route was learned from
10209	SourcePeer *string `json:"sourcePeer,omitempty"`
10210	// Origin - The source this route was learned from
10211	Origin *string `json:"origin,omitempty"`
10212	// AsPath - The route's AS path sequence
10213	AsPath *string `json:"asPath,omitempty"`
10214	// Weight - The route's weight
10215	Weight *int32 `json:"weight,omitempty"`
10216}
10217
10218// GatewayRouteListResult list of virtual network gateway routes
10219type GatewayRouteListResult struct {
10220	autorest.Response `json:"-"`
10221	// Value - List of gateway routes
10222	Value *[]GatewayRoute `json:"value,omitempty"`
10223}
10224
10225// GetVpnSitesConfigurationRequest list of Vpn-Sites
10226type GetVpnSitesConfigurationRequest struct {
10227	// VpnSites - List of resource-ids of the vpn-sites for which config is to be downloaded.
10228	VpnSites *[]string `json:"vpnSites,omitempty"`
10229	// OutputBlobSasURL - The sas-url to download the configurations for vpn-sites
10230	OutputBlobSasURL *string `json:"outputBlobSasUrl,omitempty"`
10231}
10232
10233// HTTPConfiguration HTTP configuration of the connectivity check.
10234type HTTPConfiguration struct {
10235	// Method - HTTP method. Possible values include: 'Get'
10236	Method HTTPMethod `json:"method,omitempty"`
10237	// Headers - List of HTTP headers.
10238	Headers *[]HTTPHeader `json:"headers,omitempty"`
10239	// ValidStatusCodes - Valid status codes.
10240	ValidStatusCodes *[]int32 `json:"validStatusCodes,omitempty"`
10241}
10242
10243// HTTPHeader describes the HTTP header.
10244type HTTPHeader struct {
10245	// Name - The name in HTTP header.
10246	Name *string `json:"name,omitempty"`
10247	// Value - The value in HTTP header.
10248	Value *string `json:"value,omitempty"`
10249}
10250
10251// HubVirtualNetworkConnection hubVirtualNetworkConnection Resource.
10252type HubVirtualNetworkConnection struct {
10253	autorest.Response                      `json:"-"`
10254	*HubVirtualNetworkConnectionProperties `json:"properties,omitempty"`
10255	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
10256	Name *string `json:"name,omitempty"`
10257	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
10258	Etag *string `json:"etag,omitempty"`
10259	// ID - Resource ID.
10260	ID *string `json:"id,omitempty"`
10261}
10262
10263// MarshalJSON is the custom marshaler for HubVirtualNetworkConnection.
10264func (hvnc HubVirtualNetworkConnection) MarshalJSON() ([]byte, error) {
10265	objectMap := make(map[string]interface{})
10266	if hvnc.HubVirtualNetworkConnectionProperties != nil {
10267		objectMap["properties"] = hvnc.HubVirtualNetworkConnectionProperties
10268	}
10269	if hvnc.Name != nil {
10270		objectMap["name"] = hvnc.Name
10271	}
10272	if hvnc.Etag != nil {
10273		objectMap["etag"] = hvnc.Etag
10274	}
10275	if hvnc.ID != nil {
10276		objectMap["id"] = hvnc.ID
10277	}
10278	return json.Marshal(objectMap)
10279}
10280
10281// UnmarshalJSON is the custom unmarshaler for HubVirtualNetworkConnection struct.
10282func (hvnc *HubVirtualNetworkConnection) UnmarshalJSON(body []byte) error {
10283	var m map[string]*json.RawMessage
10284	err := json.Unmarshal(body, &m)
10285	if err != nil {
10286		return err
10287	}
10288	for k, v := range m {
10289		switch k {
10290		case "properties":
10291			if v != nil {
10292				var hubVirtualNetworkConnectionProperties HubVirtualNetworkConnectionProperties
10293				err = json.Unmarshal(*v, &hubVirtualNetworkConnectionProperties)
10294				if err != nil {
10295					return err
10296				}
10297				hvnc.HubVirtualNetworkConnectionProperties = &hubVirtualNetworkConnectionProperties
10298			}
10299		case "name":
10300			if v != nil {
10301				var name string
10302				err = json.Unmarshal(*v, &name)
10303				if err != nil {
10304					return err
10305				}
10306				hvnc.Name = &name
10307			}
10308		case "etag":
10309			if v != nil {
10310				var etag string
10311				err = json.Unmarshal(*v, &etag)
10312				if err != nil {
10313					return err
10314				}
10315				hvnc.Etag = &etag
10316			}
10317		case "id":
10318			if v != nil {
10319				var ID string
10320				err = json.Unmarshal(*v, &ID)
10321				if err != nil {
10322					return err
10323				}
10324				hvnc.ID = &ID
10325			}
10326		}
10327	}
10328
10329	return nil
10330}
10331
10332// HubVirtualNetworkConnectionProperties parameters for HubVirtualNetworkConnection
10333type HubVirtualNetworkConnectionProperties struct {
10334	// RemoteVirtualNetwork - Reference to the remote virtual network.
10335	RemoteVirtualNetwork *SubResource `json:"remoteVirtualNetwork,omitempty"`
10336	// AllowHubToRemoteVnetTransit - VirtualHub to RemoteVnet transit to enabled or not.
10337	AllowHubToRemoteVnetTransit *bool `json:"allowHubToRemoteVnetTransit,omitempty"`
10338	// AllowRemoteVnetToUseHubVnetGateways - Allow RemoteVnet to use Virtual Hub's gateways.
10339	AllowRemoteVnetToUseHubVnetGateways *bool `json:"allowRemoteVnetToUseHubVnetGateways,omitempty"`
10340	// EnableInternetSecurity - Enable internet security
10341	EnableInternetSecurity *bool `json:"enableInternetSecurity,omitempty"`
10342	// ProvisioningState - The provisioning state of the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
10343	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
10344}
10345
10346// InboundNatPool inbound NAT pool of the load balancer.
10347type InboundNatPool struct {
10348	// InboundNatPoolPropertiesFormat - Properties of load balancer inbound nat pool.
10349	*InboundNatPoolPropertiesFormat `json:"properties,omitempty"`
10350	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
10351	Name *string `json:"name,omitempty"`
10352	// Etag - A unique read-only string that changes whenever the resource is updated.
10353	Etag *string `json:"etag,omitempty"`
10354	// ID - Resource ID.
10355	ID *string `json:"id,omitempty"`
10356}
10357
10358// MarshalJSON is the custom marshaler for InboundNatPool.
10359func (inp InboundNatPool) MarshalJSON() ([]byte, error) {
10360	objectMap := make(map[string]interface{})
10361	if inp.InboundNatPoolPropertiesFormat != nil {
10362		objectMap["properties"] = inp.InboundNatPoolPropertiesFormat
10363	}
10364	if inp.Name != nil {
10365		objectMap["name"] = inp.Name
10366	}
10367	if inp.Etag != nil {
10368		objectMap["etag"] = inp.Etag
10369	}
10370	if inp.ID != nil {
10371		objectMap["id"] = inp.ID
10372	}
10373	return json.Marshal(objectMap)
10374}
10375
10376// UnmarshalJSON is the custom unmarshaler for InboundNatPool struct.
10377func (inp *InboundNatPool) UnmarshalJSON(body []byte) error {
10378	var m map[string]*json.RawMessage
10379	err := json.Unmarshal(body, &m)
10380	if err != nil {
10381		return err
10382	}
10383	for k, v := range m {
10384		switch k {
10385		case "properties":
10386			if v != nil {
10387				var inboundNatPoolPropertiesFormat InboundNatPoolPropertiesFormat
10388				err = json.Unmarshal(*v, &inboundNatPoolPropertiesFormat)
10389				if err != nil {
10390					return err
10391				}
10392				inp.InboundNatPoolPropertiesFormat = &inboundNatPoolPropertiesFormat
10393			}
10394		case "name":
10395			if v != nil {
10396				var name string
10397				err = json.Unmarshal(*v, &name)
10398				if err != nil {
10399					return err
10400				}
10401				inp.Name = &name
10402			}
10403		case "etag":
10404			if v != nil {
10405				var etag string
10406				err = json.Unmarshal(*v, &etag)
10407				if err != nil {
10408					return err
10409				}
10410				inp.Etag = &etag
10411			}
10412		case "id":
10413			if v != nil {
10414				var ID string
10415				err = json.Unmarshal(*v, &ID)
10416				if err != nil {
10417					return err
10418				}
10419				inp.ID = &ID
10420			}
10421		}
10422	}
10423
10424	return nil
10425}
10426
10427// InboundNatPoolPropertiesFormat properties of Inbound NAT pool.
10428type InboundNatPoolPropertiesFormat struct {
10429	// FrontendIPConfiguration - A reference to frontend IP addresses.
10430	FrontendIPConfiguration *SubResource `json:"frontendIPConfiguration,omitempty"`
10431	// Protocol - Possible values include: 'TransportProtocolUDP', 'TransportProtocolTCP', 'TransportProtocolAll'
10432	Protocol TransportProtocol `json:"protocol,omitempty"`
10433	// FrontendPortRangeStart - The first port number in the range of external ports that will be used to provide Inbound Nat to NICs associated with a load balancer. Acceptable values range between 1 and 65534.
10434	FrontendPortRangeStart *int32 `json:"frontendPortRangeStart,omitempty"`
10435	// FrontendPortRangeEnd - The last port number in the range of external ports that will be used to provide Inbound Nat to NICs associated with a load balancer. Acceptable values range between 1 and 65535.
10436	FrontendPortRangeEnd *int32 `json:"frontendPortRangeEnd,omitempty"`
10437	// BackendPort - The port used for internal connections on the endpoint. Acceptable values are between 1 and 65535.
10438	BackendPort *int32 `json:"backendPort,omitempty"`
10439	// 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.
10440	IdleTimeoutInMinutes *int32 `json:"idleTimeoutInMinutes,omitempty"`
10441	// 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.
10442	EnableFloatingIP *bool `json:"enableFloatingIP,omitempty"`
10443	// EnableTCPReset - Receive bidirectional TCP Reset on TCP flow idle timeout or unexpected connection termination. This element is only used when the protocol is set to TCP.
10444	EnableTCPReset *bool `json:"enableTcpReset,omitempty"`
10445	// ProvisioningState - Gets the provisioning state of the PublicIP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
10446	ProvisioningState *string `json:"provisioningState,omitempty"`
10447}
10448
10449// InboundNatRule inbound NAT rule of the load balancer.
10450type InboundNatRule struct {
10451	autorest.Response `json:"-"`
10452	// InboundNatRulePropertiesFormat - Properties of load balancer inbound nat rule.
10453	*InboundNatRulePropertiesFormat `json:"properties,omitempty"`
10454	// Name - Gets name of the resource that is unique within a resource group. This name can be used to access the resource.
10455	Name *string `json:"name,omitempty"`
10456	// Etag - A unique read-only string that changes whenever the resource is updated.
10457	Etag *string `json:"etag,omitempty"`
10458	// ID - Resource ID.
10459	ID *string `json:"id,omitempty"`
10460}
10461
10462// MarshalJSON is the custom marshaler for InboundNatRule.
10463func (inr InboundNatRule) MarshalJSON() ([]byte, error) {
10464	objectMap := make(map[string]interface{})
10465	if inr.InboundNatRulePropertiesFormat != nil {
10466		objectMap["properties"] = inr.InboundNatRulePropertiesFormat
10467	}
10468	if inr.Name != nil {
10469		objectMap["name"] = inr.Name
10470	}
10471	if inr.Etag != nil {
10472		objectMap["etag"] = inr.Etag
10473	}
10474	if inr.ID != nil {
10475		objectMap["id"] = inr.ID
10476	}
10477	return json.Marshal(objectMap)
10478}
10479
10480// UnmarshalJSON is the custom unmarshaler for InboundNatRule struct.
10481func (inr *InboundNatRule) UnmarshalJSON(body []byte) error {
10482	var m map[string]*json.RawMessage
10483	err := json.Unmarshal(body, &m)
10484	if err != nil {
10485		return err
10486	}
10487	for k, v := range m {
10488		switch k {
10489		case "properties":
10490			if v != nil {
10491				var inboundNatRulePropertiesFormat InboundNatRulePropertiesFormat
10492				err = json.Unmarshal(*v, &inboundNatRulePropertiesFormat)
10493				if err != nil {
10494					return err
10495				}
10496				inr.InboundNatRulePropertiesFormat = &inboundNatRulePropertiesFormat
10497			}
10498		case "name":
10499			if v != nil {
10500				var name string
10501				err = json.Unmarshal(*v, &name)
10502				if err != nil {
10503					return err
10504				}
10505				inr.Name = &name
10506			}
10507		case "etag":
10508			if v != nil {
10509				var etag string
10510				err = json.Unmarshal(*v, &etag)
10511				if err != nil {
10512					return err
10513				}
10514				inr.Etag = &etag
10515			}
10516		case "id":
10517			if v != nil {
10518				var ID string
10519				err = json.Unmarshal(*v, &ID)
10520				if err != nil {
10521					return err
10522				}
10523				inr.ID = &ID
10524			}
10525		}
10526	}
10527
10528	return nil
10529}
10530
10531// InboundNatRuleListResult response for ListInboundNatRule API service call.
10532type InboundNatRuleListResult struct {
10533	autorest.Response `json:"-"`
10534	// Value - A list of inbound nat rules in a load balancer.
10535	Value *[]InboundNatRule `json:"value,omitempty"`
10536	// NextLink - The URL to get the next set of results.
10537	NextLink *string `json:"nextLink,omitempty"`
10538}
10539
10540// InboundNatRuleListResultIterator provides access to a complete listing of InboundNatRule values.
10541type InboundNatRuleListResultIterator struct {
10542	i    int
10543	page InboundNatRuleListResultPage
10544}
10545
10546// Next advances to the next value.  If there was an error making
10547// the request the iterator does not advance and the error is returned.
10548func (iter *InboundNatRuleListResultIterator) Next() error {
10549	iter.i++
10550	if iter.i < len(iter.page.Values()) {
10551		return nil
10552	}
10553	err := iter.page.Next()
10554	if err != nil {
10555		iter.i--
10556		return err
10557	}
10558	iter.i = 0
10559	return nil
10560}
10561
10562// NotDone returns true if the enumeration should be started or is not yet complete.
10563func (iter InboundNatRuleListResultIterator) NotDone() bool {
10564	return iter.page.NotDone() && iter.i < len(iter.page.Values())
10565}
10566
10567// Response returns the raw server response from the last page request.
10568func (iter InboundNatRuleListResultIterator) Response() InboundNatRuleListResult {
10569	return iter.page.Response()
10570}
10571
10572// Value returns the current value or a zero-initialized value if the
10573// iterator has advanced beyond the end of the collection.
10574func (iter InboundNatRuleListResultIterator) Value() InboundNatRule {
10575	if !iter.page.NotDone() {
10576		return InboundNatRule{}
10577	}
10578	return iter.page.Values()[iter.i]
10579}
10580
10581// IsEmpty returns true if the ListResult contains no values.
10582func (inrlr InboundNatRuleListResult) IsEmpty() bool {
10583	return inrlr.Value == nil || len(*inrlr.Value) == 0
10584}
10585
10586// inboundNatRuleListResultPreparer prepares a request to retrieve the next set of results.
10587// It returns nil if no more results exist.
10588func (inrlr InboundNatRuleListResult) inboundNatRuleListResultPreparer() (*http.Request, error) {
10589	if inrlr.NextLink == nil || len(to.String(inrlr.NextLink)) < 1 {
10590		return nil, nil
10591	}
10592	return autorest.Prepare(&http.Request{},
10593		autorest.AsJSON(),
10594		autorest.AsGet(),
10595		autorest.WithBaseURL(to.String(inrlr.NextLink)))
10596}
10597
10598// InboundNatRuleListResultPage contains a page of InboundNatRule values.
10599type InboundNatRuleListResultPage struct {
10600	fn    func(InboundNatRuleListResult) (InboundNatRuleListResult, error)
10601	inrlr InboundNatRuleListResult
10602}
10603
10604// Next advances to the next page of values.  If there was an error making
10605// the request the page does not advance and the error is returned.
10606func (page *InboundNatRuleListResultPage) Next() error {
10607	next, err := page.fn(page.inrlr)
10608	if err != nil {
10609		return err
10610	}
10611	page.inrlr = next
10612	return nil
10613}
10614
10615// NotDone returns true if the page enumeration should be started or is not yet complete.
10616func (page InboundNatRuleListResultPage) NotDone() bool {
10617	return !page.inrlr.IsEmpty()
10618}
10619
10620// Response returns the raw server response from the last page request.
10621func (page InboundNatRuleListResultPage) Response() InboundNatRuleListResult {
10622	return page.inrlr
10623}
10624
10625// Values returns the slice of values for the current page or nil if there are no values.
10626func (page InboundNatRuleListResultPage) Values() []InboundNatRule {
10627	if page.inrlr.IsEmpty() {
10628		return nil
10629	}
10630	return *page.inrlr.Value
10631}
10632
10633// InboundNatRulePropertiesFormat properties of the inbound NAT rule.
10634type InboundNatRulePropertiesFormat struct {
10635	// FrontendIPConfiguration - A reference to frontend IP addresses.
10636	FrontendIPConfiguration *SubResource `json:"frontendIPConfiguration,omitempty"`
10637	// BackendIPConfiguration - A reference to a private IP address defined on a network interface of a VM. Traffic sent to the frontend port of each of the frontend IP configurations is forwarded to the backend IP.
10638	BackendIPConfiguration *InterfaceIPConfiguration `json:"backendIPConfiguration,omitempty"`
10639	// Protocol - Possible values include: 'TransportProtocolUDP', 'TransportProtocolTCP', 'TransportProtocolAll'
10640	Protocol TransportProtocol `json:"protocol,omitempty"`
10641	// 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.
10642	FrontendPort *int32 `json:"frontendPort,omitempty"`
10643	// BackendPort - The port used for the internal endpoint. Acceptable values range from 1 to 65535.
10644	BackendPort *int32 `json:"backendPort,omitempty"`
10645	// 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.
10646	IdleTimeoutInMinutes *int32 `json:"idleTimeoutInMinutes,omitempty"`
10647	// 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.
10648	EnableFloatingIP *bool `json:"enableFloatingIP,omitempty"`
10649	// EnableTCPReset - Receive bidirectional TCP Reset on TCP flow idle timeout or unexpected connection termination. This element is only used when the protocol is set to TCP.
10650	EnableTCPReset *bool `json:"enableTcpReset,omitempty"`
10651	// ProvisioningState - Gets the provisioning state of the public IP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
10652	ProvisioningState *string `json:"provisioningState,omitempty"`
10653}
10654
10655// InboundNatRulesCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
10656// operation.
10657type InboundNatRulesCreateOrUpdateFuture struct {
10658	azure.Future
10659}
10660
10661// Result returns the result of the asynchronous operation.
10662// If the operation has not completed it will return an error.
10663func (future *InboundNatRulesCreateOrUpdateFuture) Result(client InboundNatRulesClient) (inr InboundNatRule, err error) {
10664	var done bool
10665	done, err = future.Done(client)
10666	if err != nil {
10667		err = autorest.NewErrorWithError(err, "network.InboundNatRulesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
10668		return
10669	}
10670	if !done {
10671		err = azure.NewAsyncOpIncompleteError("network.InboundNatRulesCreateOrUpdateFuture")
10672		return
10673	}
10674	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
10675	if inr.Response.Response, err = future.GetResult(sender); err == nil && inr.Response.Response.StatusCode != http.StatusNoContent {
10676		inr, err = client.CreateOrUpdateResponder(inr.Response.Response)
10677		if err != nil {
10678			err = autorest.NewErrorWithError(err, "network.InboundNatRulesCreateOrUpdateFuture", "Result", inr.Response.Response, "Failure responding to request")
10679		}
10680	}
10681	return
10682}
10683
10684// InboundNatRulesDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
10685// operation.
10686type InboundNatRulesDeleteFuture struct {
10687	azure.Future
10688}
10689
10690// Result returns the result of the asynchronous operation.
10691// If the operation has not completed it will return an error.
10692func (future *InboundNatRulesDeleteFuture) Result(client InboundNatRulesClient) (ar autorest.Response, err error) {
10693	var done bool
10694	done, err = future.Done(client)
10695	if err != nil {
10696		err = autorest.NewErrorWithError(err, "network.InboundNatRulesDeleteFuture", "Result", future.Response(), "Polling failure")
10697		return
10698	}
10699	if !done {
10700		err = azure.NewAsyncOpIncompleteError("network.InboundNatRulesDeleteFuture")
10701		return
10702	}
10703	ar.Response = future.Response()
10704	return
10705}
10706
10707// Interface a network interface in a resource group.
10708type Interface struct {
10709	autorest.Response `json:"-"`
10710	// InterfacePropertiesFormat - Properties of the network interface.
10711	*InterfacePropertiesFormat `json:"properties,omitempty"`
10712	// Etag - A unique read-only string that changes whenever the resource is updated.
10713	Etag *string `json:"etag,omitempty"`
10714	// ID - Resource ID.
10715	ID *string `json:"id,omitempty"`
10716	// Name - Resource name.
10717	Name *string `json:"name,omitempty"`
10718	// Type - Resource type.
10719	Type *string `json:"type,omitempty"`
10720	// Location - Resource location.
10721	Location *string `json:"location,omitempty"`
10722	// Tags - Resource tags.
10723	Tags map[string]*string `json:"tags"`
10724}
10725
10726// MarshalJSON is the custom marshaler for Interface.
10727func (i Interface) MarshalJSON() ([]byte, error) {
10728	objectMap := make(map[string]interface{})
10729	if i.InterfacePropertiesFormat != nil {
10730		objectMap["properties"] = i.InterfacePropertiesFormat
10731	}
10732	if i.Etag != nil {
10733		objectMap["etag"] = i.Etag
10734	}
10735	if i.ID != nil {
10736		objectMap["id"] = i.ID
10737	}
10738	if i.Name != nil {
10739		objectMap["name"] = i.Name
10740	}
10741	if i.Type != nil {
10742		objectMap["type"] = i.Type
10743	}
10744	if i.Location != nil {
10745		objectMap["location"] = i.Location
10746	}
10747	if i.Tags != nil {
10748		objectMap["tags"] = i.Tags
10749	}
10750	return json.Marshal(objectMap)
10751}
10752
10753// UnmarshalJSON is the custom unmarshaler for Interface struct.
10754func (i *Interface) UnmarshalJSON(body []byte) error {
10755	var m map[string]*json.RawMessage
10756	err := json.Unmarshal(body, &m)
10757	if err != nil {
10758		return err
10759	}
10760	for k, v := range m {
10761		switch k {
10762		case "properties":
10763			if v != nil {
10764				var interfacePropertiesFormat InterfacePropertiesFormat
10765				err = json.Unmarshal(*v, &interfacePropertiesFormat)
10766				if err != nil {
10767					return err
10768				}
10769				i.InterfacePropertiesFormat = &interfacePropertiesFormat
10770			}
10771		case "etag":
10772			if v != nil {
10773				var etag string
10774				err = json.Unmarshal(*v, &etag)
10775				if err != nil {
10776					return err
10777				}
10778				i.Etag = &etag
10779			}
10780		case "id":
10781			if v != nil {
10782				var ID string
10783				err = json.Unmarshal(*v, &ID)
10784				if err != nil {
10785					return err
10786				}
10787				i.ID = &ID
10788			}
10789		case "name":
10790			if v != nil {
10791				var name string
10792				err = json.Unmarshal(*v, &name)
10793				if err != nil {
10794					return err
10795				}
10796				i.Name = &name
10797			}
10798		case "type":
10799			if v != nil {
10800				var typeVar string
10801				err = json.Unmarshal(*v, &typeVar)
10802				if err != nil {
10803					return err
10804				}
10805				i.Type = &typeVar
10806			}
10807		case "location":
10808			if v != nil {
10809				var location string
10810				err = json.Unmarshal(*v, &location)
10811				if err != nil {
10812					return err
10813				}
10814				i.Location = &location
10815			}
10816		case "tags":
10817			if v != nil {
10818				var tags map[string]*string
10819				err = json.Unmarshal(*v, &tags)
10820				if err != nil {
10821					return err
10822				}
10823				i.Tags = tags
10824			}
10825		}
10826	}
10827
10828	return nil
10829}
10830
10831// InterfaceAssociation network interface and its custom security rules.
10832type InterfaceAssociation struct {
10833	// ID - Network interface ID.
10834	ID *string `json:"id,omitempty"`
10835	// SecurityRules - Collection of custom security rules.
10836	SecurityRules *[]SecurityRule `json:"securityRules,omitempty"`
10837}
10838
10839// InterfaceDNSSettings DNS settings of a network interface.
10840type InterfaceDNSSettings struct {
10841	// 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.
10842	DNSServers *[]string `json:"dnsServers,omitempty"`
10843	// 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.
10844	AppliedDNSServers *[]string `json:"appliedDnsServers,omitempty"`
10845	// InternalDNSNameLabel - Relative DNS name for this NIC used for internal communications between VMs in the same virtual network.
10846	InternalDNSNameLabel *string `json:"internalDnsNameLabel,omitempty"`
10847	// InternalFqdn - Fully qualified DNS name supporting internal communications between VMs in the same virtual network.
10848	InternalFqdn *string `json:"internalFqdn,omitempty"`
10849	// 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.
10850	InternalDomainNameSuffix *string `json:"internalDomainNameSuffix,omitempty"`
10851}
10852
10853// InterfaceEndpoint interface endpoint resource.
10854type InterfaceEndpoint struct {
10855	autorest.Response `json:"-"`
10856	// InterfaceEndpointProperties - Properties of the interface endpoint.
10857	*InterfaceEndpointProperties `json:"properties,omitempty"`
10858	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
10859	Etag *string `json:"etag,omitempty"`
10860	// ID - Resource ID.
10861	ID *string `json:"id,omitempty"`
10862	// Name - Resource name.
10863	Name *string `json:"name,omitempty"`
10864	// Type - Resource type.
10865	Type *string `json:"type,omitempty"`
10866	// Location - Resource location.
10867	Location *string `json:"location,omitempty"`
10868	// Tags - Resource tags.
10869	Tags map[string]*string `json:"tags"`
10870}
10871
10872// MarshalJSON is the custom marshaler for InterfaceEndpoint.
10873func (ie InterfaceEndpoint) MarshalJSON() ([]byte, error) {
10874	objectMap := make(map[string]interface{})
10875	if ie.InterfaceEndpointProperties != nil {
10876		objectMap["properties"] = ie.InterfaceEndpointProperties
10877	}
10878	if ie.Etag != nil {
10879		objectMap["etag"] = ie.Etag
10880	}
10881	if ie.ID != nil {
10882		objectMap["id"] = ie.ID
10883	}
10884	if ie.Name != nil {
10885		objectMap["name"] = ie.Name
10886	}
10887	if ie.Type != nil {
10888		objectMap["type"] = ie.Type
10889	}
10890	if ie.Location != nil {
10891		objectMap["location"] = ie.Location
10892	}
10893	if ie.Tags != nil {
10894		objectMap["tags"] = ie.Tags
10895	}
10896	return json.Marshal(objectMap)
10897}
10898
10899// UnmarshalJSON is the custom unmarshaler for InterfaceEndpoint struct.
10900func (ie *InterfaceEndpoint) UnmarshalJSON(body []byte) error {
10901	var m map[string]*json.RawMessage
10902	err := json.Unmarshal(body, &m)
10903	if err != nil {
10904		return err
10905	}
10906	for k, v := range m {
10907		switch k {
10908		case "properties":
10909			if v != nil {
10910				var interfaceEndpointProperties InterfaceEndpointProperties
10911				err = json.Unmarshal(*v, &interfaceEndpointProperties)
10912				if err != nil {
10913					return err
10914				}
10915				ie.InterfaceEndpointProperties = &interfaceEndpointProperties
10916			}
10917		case "etag":
10918			if v != nil {
10919				var etag string
10920				err = json.Unmarshal(*v, &etag)
10921				if err != nil {
10922					return err
10923				}
10924				ie.Etag = &etag
10925			}
10926		case "id":
10927			if v != nil {
10928				var ID string
10929				err = json.Unmarshal(*v, &ID)
10930				if err != nil {
10931					return err
10932				}
10933				ie.ID = &ID
10934			}
10935		case "name":
10936			if v != nil {
10937				var name string
10938				err = json.Unmarshal(*v, &name)
10939				if err != nil {
10940					return err
10941				}
10942				ie.Name = &name
10943			}
10944		case "type":
10945			if v != nil {
10946				var typeVar string
10947				err = json.Unmarshal(*v, &typeVar)
10948				if err != nil {
10949					return err
10950				}
10951				ie.Type = &typeVar
10952			}
10953		case "location":
10954			if v != nil {
10955				var location string
10956				err = json.Unmarshal(*v, &location)
10957				if err != nil {
10958					return err
10959				}
10960				ie.Location = &location
10961			}
10962		case "tags":
10963			if v != nil {
10964				var tags map[string]*string
10965				err = json.Unmarshal(*v, &tags)
10966				if err != nil {
10967					return err
10968				}
10969				ie.Tags = tags
10970			}
10971		}
10972	}
10973
10974	return nil
10975}
10976
10977// InterfaceEndpointListResult response for the ListInterfaceEndpoints API service call.
10978type InterfaceEndpointListResult struct {
10979	autorest.Response `json:"-"`
10980	// Value - Gets a list of InterfaceEndpoint resources in a resource group.
10981	Value *[]InterfaceEndpoint `json:"value,omitempty"`
10982	// NextLink - The URL to get the next set of results.
10983	NextLink *string `json:"nextLink,omitempty"`
10984}
10985
10986// InterfaceEndpointListResultIterator provides access to a complete listing of InterfaceEndpoint values.
10987type InterfaceEndpointListResultIterator struct {
10988	i    int
10989	page InterfaceEndpointListResultPage
10990}
10991
10992// Next advances to the next value.  If there was an error making
10993// the request the iterator does not advance and the error is returned.
10994func (iter *InterfaceEndpointListResultIterator) Next() error {
10995	iter.i++
10996	if iter.i < len(iter.page.Values()) {
10997		return nil
10998	}
10999	err := iter.page.Next()
11000	if err != nil {
11001		iter.i--
11002		return err
11003	}
11004	iter.i = 0
11005	return nil
11006}
11007
11008// NotDone returns true if the enumeration should be started or is not yet complete.
11009func (iter InterfaceEndpointListResultIterator) NotDone() bool {
11010	return iter.page.NotDone() && iter.i < len(iter.page.Values())
11011}
11012
11013// Response returns the raw server response from the last page request.
11014func (iter InterfaceEndpointListResultIterator) Response() InterfaceEndpointListResult {
11015	return iter.page.Response()
11016}
11017
11018// Value returns the current value or a zero-initialized value if the
11019// iterator has advanced beyond the end of the collection.
11020func (iter InterfaceEndpointListResultIterator) Value() InterfaceEndpoint {
11021	if !iter.page.NotDone() {
11022		return InterfaceEndpoint{}
11023	}
11024	return iter.page.Values()[iter.i]
11025}
11026
11027// IsEmpty returns true if the ListResult contains no values.
11028func (ielr InterfaceEndpointListResult) IsEmpty() bool {
11029	return ielr.Value == nil || len(*ielr.Value) == 0
11030}
11031
11032// interfaceEndpointListResultPreparer prepares a request to retrieve the next set of results.
11033// It returns nil if no more results exist.
11034func (ielr InterfaceEndpointListResult) interfaceEndpointListResultPreparer() (*http.Request, error) {
11035	if ielr.NextLink == nil || len(to.String(ielr.NextLink)) < 1 {
11036		return nil, nil
11037	}
11038	return autorest.Prepare(&http.Request{},
11039		autorest.AsJSON(),
11040		autorest.AsGet(),
11041		autorest.WithBaseURL(to.String(ielr.NextLink)))
11042}
11043
11044// InterfaceEndpointListResultPage contains a page of InterfaceEndpoint values.
11045type InterfaceEndpointListResultPage struct {
11046	fn   func(InterfaceEndpointListResult) (InterfaceEndpointListResult, error)
11047	ielr InterfaceEndpointListResult
11048}
11049
11050// Next advances to the next page of values.  If there was an error making
11051// the request the page does not advance and the error is returned.
11052func (page *InterfaceEndpointListResultPage) Next() error {
11053	next, err := page.fn(page.ielr)
11054	if err != nil {
11055		return err
11056	}
11057	page.ielr = next
11058	return nil
11059}
11060
11061// NotDone returns true if the page enumeration should be started or is not yet complete.
11062func (page InterfaceEndpointListResultPage) NotDone() bool {
11063	return !page.ielr.IsEmpty()
11064}
11065
11066// Response returns the raw server response from the last page request.
11067func (page InterfaceEndpointListResultPage) Response() InterfaceEndpointListResult {
11068	return page.ielr
11069}
11070
11071// Values returns the slice of values for the current page or nil if there are no values.
11072func (page InterfaceEndpointListResultPage) Values() []InterfaceEndpoint {
11073	if page.ielr.IsEmpty() {
11074		return nil
11075	}
11076	return *page.ielr.Value
11077}
11078
11079// InterfaceEndpointProperties properties of the interface endpoint.
11080type InterfaceEndpointProperties struct {
11081	// Fqdn - A first-party service's FQDN that is mapped to the private IP allocated via this interface endpoint.
11082	Fqdn *string `json:"fqdn,omitempty"`
11083	// EndpointService - A reference to the service being brought into the virtual network.
11084	EndpointService *EndpointService `json:"endpointService,omitempty"`
11085	// Subnet - The ID of the subnet from which the private IP will be allocated.
11086	Subnet *Subnet `json:"subnet,omitempty"`
11087	// NetworkInterfaces - Gets an array of references to the network interfaces created for this interface endpoint.
11088	NetworkInterfaces *[]Interface `json:"networkInterfaces,omitempty"`
11089	// Owner - A read-only property that identifies who created this interface endpoint.
11090	Owner *string `json:"owner,omitempty"`
11091	// ProvisioningState - The provisioning state of the interface endpoint. Possible values are: 'Updating', 'Deleting', and 'Failed'.
11092	ProvisioningState *string `json:"provisioningState,omitempty"`
11093}
11094
11095// InterfaceEndpointsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
11096// long-running operation.
11097type InterfaceEndpointsCreateOrUpdateFuture struct {
11098	azure.Future
11099}
11100
11101// Result returns the result of the asynchronous operation.
11102// If the operation has not completed it will return an error.
11103func (future *InterfaceEndpointsCreateOrUpdateFuture) Result(client InterfaceEndpointsClient) (ie InterfaceEndpoint, err error) {
11104	var done bool
11105	done, err = future.Done(client)
11106	if err != nil {
11107		err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
11108		return
11109	}
11110	if !done {
11111		err = azure.NewAsyncOpIncompleteError("network.InterfaceEndpointsCreateOrUpdateFuture")
11112		return
11113	}
11114	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
11115	if ie.Response.Response, err = future.GetResult(sender); err == nil && ie.Response.Response.StatusCode != http.StatusNoContent {
11116		ie, err = client.CreateOrUpdateResponder(ie.Response.Response)
11117		if err != nil {
11118			err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsCreateOrUpdateFuture", "Result", ie.Response.Response, "Failure responding to request")
11119		}
11120	}
11121	return
11122}
11123
11124// InterfaceEndpointsDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
11125// operation.
11126type InterfaceEndpointsDeleteFuture struct {
11127	azure.Future
11128}
11129
11130// Result returns the result of the asynchronous operation.
11131// If the operation has not completed it will return an error.
11132func (future *InterfaceEndpointsDeleteFuture) Result(client InterfaceEndpointsClient) (ar autorest.Response, err error) {
11133	var done bool
11134	done, err = future.Done(client)
11135	if err != nil {
11136		err = autorest.NewErrorWithError(err, "network.InterfaceEndpointsDeleteFuture", "Result", future.Response(), "Polling failure")
11137		return
11138	}
11139	if !done {
11140		err = azure.NewAsyncOpIncompleteError("network.InterfaceEndpointsDeleteFuture")
11141		return
11142	}
11143	ar.Response = future.Response()
11144	return
11145}
11146
11147// InterfaceIPConfiguration iPConfiguration in a network interface.
11148type InterfaceIPConfiguration struct {
11149	autorest.Response `json:"-"`
11150	// InterfaceIPConfigurationPropertiesFormat - Network interface IP configuration properties.
11151	*InterfaceIPConfigurationPropertiesFormat `json:"properties,omitempty"`
11152	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
11153	Name *string `json:"name,omitempty"`
11154	// Etag - A unique read-only string that changes whenever the resource is updated.
11155	Etag *string `json:"etag,omitempty"`
11156	// ID - Resource ID.
11157	ID *string `json:"id,omitempty"`
11158}
11159
11160// MarshalJSON is the custom marshaler for InterfaceIPConfiguration.
11161func (iic InterfaceIPConfiguration) MarshalJSON() ([]byte, error) {
11162	objectMap := make(map[string]interface{})
11163	if iic.InterfaceIPConfigurationPropertiesFormat != nil {
11164		objectMap["properties"] = iic.InterfaceIPConfigurationPropertiesFormat
11165	}
11166	if iic.Name != nil {
11167		objectMap["name"] = iic.Name
11168	}
11169	if iic.Etag != nil {
11170		objectMap["etag"] = iic.Etag
11171	}
11172	if iic.ID != nil {
11173		objectMap["id"] = iic.ID
11174	}
11175	return json.Marshal(objectMap)
11176}
11177
11178// UnmarshalJSON is the custom unmarshaler for InterfaceIPConfiguration struct.
11179func (iic *InterfaceIPConfiguration) UnmarshalJSON(body []byte) error {
11180	var m map[string]*json.RawMessage
11181	err := json.Unmarshal(body, &m)
11182	if err != nil {
11183		return err
11184	}
11185	for k, v := range m {
11186		switch k {
11187		case "properties":
11188			if v != nil {
11189				var interfaceIPConfigurationPropertiesFormat InterfaceIPConfigurationPropertiesFormat
11190				err = json.Unmarshal(*v, &interfaceIPConfigurationPropertiesFormat)
11191				if err != nil {
11192					return err
11193				}
11194				iic.InterfaceIPConfigurationPropertiesFormat = &interfaceIPConfigurationPropertiesFormat
11195			}
11196		case "name":
11197			if v != nil {
11198				var name string
11199				err = json.Unmarshal(*v, &name)
11200				if err != nil {
11201					return err
11202				}
11203				iic.Name = &name
11204			}
11205		case "etag":
11206			if v != nil {
11207				var etag string
11208				err = json.Unmarshal(*v, &etag)
11209				if err != nil {
11210					return err
11211				}
11212				iic.Etag = &etag
11213			}
11214		case "id":
11215			if v != nil {
11216				var ID string
11217				err = json.Unmarshal(*v, &ID)
11218				if err != nil {
11219					return err
11220				}
11221				iic.ID = &ID
11222			}
11223		}
11224	}
11225
11226	return nil
11227}
11228
11229// InterfaceIPConfigurationListResult response for list ip configurations API service call.
11230type InterfaceIPConfigurationListResult struct {
11231	autorest.Response `json:"-"`
11232	// Value - A list of ip configurations.
11233	Value *[]InterfaceIPConfiguration `json:"value,omitempty"`
11234	// NextLink - The URL to get the next set of results.
11235	NextLink *string `json:"nextLink,omitempty"`
11236}
11237
11238// InterfaceIPConfigurationListResultIterator provides access to a complete listing of InterfaceIPConfiguration
11239// values.
11240type InterfaceIPConfigurationListResultIterator struct {
11241	i    int
11242	page InterfaceIPConfigurationListResultPage
11243}
11244
11245// Next advances to the next value.  If there was an error making
11246// the request the iterator does not advance and the error is returned.
11247func (iter *InterfaceIPConfigurationListResultIterator) Next() error {
11248	iter.i++
11249	if iter.i < len(iter.page.Values()) {
11250		return nil
11251	}
11252	err := iter.page.Next()
11253	if err != nil {
11254		iter.i--
11255		return err
11256	}
11257	iter.i = 0
11258	return nil
11259}
11260
11261// NotDone returns true if the enumeration should be started or is not yet complete.
11262func (iter InterfaceIPConfigurationListResultIterator) NotDone() bool {
11263	return iter.page.NotDone() && iter.i < len(iter.page.Values())
11264}
11265
11266// Response returns the raw server response from the last page request.
11267func (iter InterfaceIPConfigurationListResultIterator) Response() InterfaceIPConfigurationListResult {
11268	return iter.page.Response()
11269}
11270
11271// Value returns the current value or a zero-initialized value if the
11272// iterator has advanced beyond the end of the collection.
11273func (iter InterfaceIPConfigurationListResultIterator) Value() InterfaceIPConfiguration {
11274	if !iter.page.NotDone() {
11275		return InterfaceIPConfiguration{}
11276	}
11277	return iter.page.Values()[iter.i]
11278}
11279
11280// IsEmpty returns true if the ListResult contains no values.
11281func (iiclr InterfaceIPConfigurationListResult) IsEmpty() bool {
11282	return iiclr.Value == nil || len(*iiclr.Value) == 0
11283}
11284
11285// interfaceIPConfigurationListResultPreparer prepares a request to retrieve the next set of results.
11286// It returns nil if no more results exist.
11287func (iiclr InterfaceIPConfigurationListResult) interfaceIPConfigurationListResultPreparer() (*http.Request, error) {
11288	if iiclr.NextLink == nil || len(to.String(iiclr.NextLink)) < 1 {
11289		return nil, nil
11290	}
11291	return autorest.Prepare(&http.Request{},
11292		autorest.AsJSON(),
11293		autorest.AsGet(),
11294		autorest.WithBaseURL(to.String(iiclr.NextLink)))
11295}
11296
11297// InterfaceIPConfigurationListResultPage contains a page of InterfaceIPConfiguration values.
11298type InterfaceIPConfigurationListResultPage struct {
11299	fn    func(InterfaceIPConfigurationListResult) (InterfaceIPConfigurationListResult, error)
11300	iiclr InterfaceIPConfigurationListResult
11301}
11302
11303// Next advances to the next page of values.  If there was an error making
11304// the request the page does not advance and the error is returned.
11305func (page *InterfaceIPConfigurationListResultPage) Next() error {
11306	next, err := page.fn(page.iiclr)
11307	if err != nil {
11308		return err
11309	}
11310	page.iiclr = next
11311	return nil
11312}
11313
11314// NotDone returns true if the page enumeration should be started or is not yet complete.
11315func (page InterfaceIPConfigurationListResultPage) NotDone() bool {
11316	return !page.iiclr.IsEmpty()
11317}
11318
11319// Response returns the raw server response from the last page request.
11320func (page InterfaceIPConfigurationListResultPage) Response() InterfaceIPConfigurationListResult {
11321	return page.iiclr
11322}
11323
11324// Values returns the slice of values for the current page or nil if there are no values.
11325func (page InterfaceIPConfigurationListResultPage) Values() []InterfaceIPConfiguration {
11326	if page.iiclr.IsEmpty() {
11327		return nil
11328	}
11329	return *page.iiclr.Value
11330}
11331
11332// InterfaceIPConfigurationPropertiesFormat properties of IP configuration.
11333type InterfaceIPConfigurationPropertiesFormat struct {
11334	// VirtualNetworkTaps - The reference to Virtual Network Taps.
11335	VirtualNetworkTaps *[]VirtualNetworkTap `json:"virtualNetworkTaps,omitempty"`
11336	// ApplicationGatewayBackendAddressPools - The reference of ApplicationGatewayBackendAddressPool resource.
11337	ApplicationGatewayBackendAddressPools *[]ApplicationGatewayBackendAddressPool `json:"applicationGatewayBackendAddressPools,omitempty"`
11338	// LoadBalancerBackendAddressPools - The reference of LoadBalancerBackendAddressPool resource.
11339	LoadBalancerBackendAddressPools *[]BackendAddressPool `json:"loadBalancerBackendAddressPools,omitempty"`
11340	// LoadBalancerInboundNatRules - A list of references of LoadBalancerInboundNatRules.
11341	LoadBalancerInboundNatRules *[]InboundNatRule `json:"loadBalancerInboundNatRules,omitempty"`
11342	// PrivateIPAddress - Private IP address of the IP configuration.
11343	PrivateIPAddress *string `json:"privateIPAddress,omitempty"`
11344	// PrivateIPAllocationMethod - Defines how a private IP address is assigned. Possible values are: 'Static' and 'Dynamic'. Possible values include: 'Static', 'Dynamic'
11345	PrivateIPAllocationMethod IPAllocationMethod `json:"privateIPAllocationMethod,omitempty"`
11346	// PrivateIPAddressVersion - Available from Api-Version 2016-03-30 onwards, it represents whether the specific ipconfiguration is IPv4 or IPv6. Default is taken as IPv4.  Possible values are: 'IPv4' and 'IPv6'. Possible values include: 'IPv4', 'IPv6'
11347	PrivateIPAddressVersion IPVersion `json:"privateIPAddressVersion,omitempty"`
11348	// Subnet - Subnet bound to the IP configuration.
11349	Subnet *Subnet `json:"subnet,omitempty"`
11350	// Primary - Gets whether this is a primary customer address on the network interface.
11351	Primary *bool `json:"primary,omitempty"`
11352	// PublicIPAddress - Public IP address bound to the IP configuration.
11353	PublicIPAddress *PublicIPAddress `json:"publicIPAddress,omitempty"`
11354	// ApplicationSecurityGroups - Application security groups in which the IP configuration is included.
11355	ApplicationSecurityGroups *[]ApplicationSecurityGroup `json:"applicationSecurityGroups,omitempty"`
11356	// ProvisioningState - The provisioning state of the network interface IP configuration. Possible values are: 'Updating', 'Deleting', and 'Failed'.
11357	ProvisioningState *string `json:"provisioningState,omitempty"`
11358}
11359
11360// InterfaceListResult response for the ListNetworkInterface API service call.
11361type InterfaceListResult struct {
11362	autorest.Response `json:"-"`
11363	// Value - A list of network interfaces in a resource group.
11364	Value *[]Interface `json:"value,omitempty"`
11365	// NextLink - The URL to get the next set of results.
11366	NextLink *string `json:"nextLink,omitempty"`
11367}
11368
11369// InterfaceListResultIterator provides access to a complete listing of Interface values.
11370type InterfaceListResultIterator struct {
11371	i    int
11372	page InterfaceListResultPage
11373}
11374
11375// Next advances to the next value.  If there was an error making
11376// the request the iterator does not advance and the error is returned.
11377func (iter *InterfaceListResultIterator) Next() error {
11378	iter.i++
11379	if iter.i < len(iter.page.Values()) {
11380		return nil
11381	}
11382	err := iter.page.Next()
11383	if err != nil {
11384		iter.i--
11385		return err
11386	}
11387	iter.i = 0
11388	return nil
11389}
11390
11391// NotDone returns true if the enumeration should be started or is not yet complete.
11392func (iter InterfaceListResultIterator) NotDone() bool {
11393	return iter.page.NotDone() && iter.i < len(iter.page.Values())
11394}
11395
11396// Response returns the raw server response from the last page request.
11397func (iter InterfaceListResultIterator) Response() InterfaceListResult {
11398	return iter.page.Response()
11399}
11400
11401// Value returns the current value or a zero-initialized value if the
11402// iterator has advanced beyond the end of the collection.
11403func (iter InterfaceListResultIterator) Value() Interface {
11404	if !iter.page.NotDone() {
11405		return Interface{}
11406	}
11407	return iter.page.Values()[iter.i]
11408}
11409
11410// IsEmpty returns true if the ListResult contains no values.
11411func (ilr InterfaceListResult) IsEmpty() bool {
11412	return ilr.Value == nil || len(*ilr.Value) == 0
11413}
11414
11415// interfaceListResultPreparer prepares a request to retrieve the next set of results.
11416// It returns nil if no more results exist.
11417func (ilr InterfaceListResult) interfaceListResultPreparer() (*http.Request, error) {
11418	if ilr.NextLink == nil || len(to.String(ilr.NextLink)) < 1 {
11419		return nil, nil
11420	}
11421	return autorest.Prepare(&http.Request{},
11422		autorest.AsJSON(),
11423		autorest.AsGet(),
11424		autorest.WithBaseURL(to.String(ilr.NextLink)))
11425}
11426
11427// InterfaceListResultPage contains a page of Interface values.
11428type InterfaceListResultPage struct {
11429	fn  func(InterfaceListResult) (InterfaceListResult, error)
11430	ilr InterfaceListResult
11431}
11432
11433// Next advances to the next page of values.  If there was an error making
11434// the request the page does not advance and the error is returned.
11435func (page *InterfaceListResultPage) Next() error {
11436	next, err := page.fn(page.ilr)
11437	if err != nil {
11438		return err
11439	}
11440	page.ilr = next
11441	return nil
11442}
11443
11444// NotDone returns true if the page enumeration should be started or is not yet complete.
11445func (page InterfaceListResultPage) NotDone() bool {
11446	return !page.ilr.IsEmpty()
11447}
11448
11449// Response returns the raw server response from the last page request.
11450func (page InterfaceListResultPage) Response() InterfaceListResult {
11451	return page.ilr
11452}
11453
11454// Values returns the slice of values for the current page or nil if there are no values.
11455func (page InterfaceListResultPage) Values() []Interface {
11456	if page.ilr.IsEmpty() {
11457		return nil
11458	}
11459	return *page.ilr.Value
11460}
11461
11462// InterfaceLoadBalancerListResult response for list ip configurations API service call.
11463type InterfaceLoadBalancerListResult struct {
11464	autorest.Response `json:"-"`
11465	// Value - A list of load balancers.
11466	Value *[]LoadBalancer `json:"value,omitempty"`
11467	// NextLink - The URL to get the next set of results.
11468	NextLink *string `json:"nextLink,omitempty"`
11469}
11470
11471// InterfaceLoadBalancerListResultIterator provides access to a complete listing of LoadBalancer values.
11472type InterfaceLoadBalancerListResultIterator struct {
11473	i    int
11474	page InterfaceLoadBalancerListResultPage
11475}
11476
11477// Next advances to the next value.  If there was an error making
11478// the request the iterator does not advance and the error is returned.
11479func (iter *InterfaceLoadBalancerListResultIterator) Next() error {
11480	iter.i++
11481	if iter.i < len(iter.page.Values()) {
11482		return nil
11483	}
11484	err := iter.page.Next()
11485	if err != nil {
11486		iter.i--
11487		return err
11488	}
11489	iter.i = 0
11490	return nil
11491}
11492
11493// NotDone returns true if the enumeration should be started or is not yet complete.
11494func (iter InterfaceLoadBalancerListResultIterator) NotDone() bool {
11495	return iter.page.NotDone() && iter.i < len(iter.page.Values())
11496}
11497
11498// Response returns the raw server response from the last page request.
11499func (iter InterfaceLoadBalancerListResultIterator) Response() InterfaceLoadBalancerListResult {
11500	return iter.page.Response()
11501}
11502
11503// Value returns the current value or a zero-initialized value if the
11504// iterator has advanced beyond the end of the collection.
11505func (iter InterfaceLoadBalancerListResultIterator) Value() LoadBalancer {
11506	if !iter.page.NotDone() {
11507		return LoadBalancer{}
11508	}
11509	return iter.page.Values()[iter.i]
11510}
11511
11512// IsEmpty returns true if the ListResult contains no values.
11513func (ilblr InterfaceLoadBalancerListResult) IsEmpty() bool {
11514	return ilblr.Value == nil || len(*ilblr.Value) == 0
11515}
11516
11517// interfaceLoadBalancerListResultPreparer prepares a request to retrieve the next set of results.
11518// It returns nil if no more results exist.
11519func (ilblr InterfaceLoadBalancerListResult) interfaceLoadBalancerListResultPreparer() (*http.Request, error) {
11520	if ilblr.NextLink == nil || len(to.String(ilblr.NextLink)) < 1 {
11521		return nil, nil
11522	}
11523	return autorest.Prepare(&http.Request{},
11524		autorest.AsJSON(),
11525		autorest.AsGet(),
11526		autorest.WithBaseURL(to.String(ilblr.NextLink)))
11527}
11528
11529// InterfaceLoadBalancerListResultPage contains a page of LoadBalancer values.
11530type InterfaceLoadBalancerListResultPage struct {
11531	fn    func(InterfaceLoadBalancerListResult) (InterfaceLoadBalancerListResult, error)
11532	ilblr InterfaceLoadBalancerListResult
11533}
11534
11535// Next advances to the next page of values.  If there was an error making
11536// the request the page does not advance and the error is returned.
11537func (page *InterfaceLoadBalancerListResultPage) Next() error {
11538	next, err := page.fn(page.ilblr)
11539	if err != nil {
11540		return err
11541	}
11542	page.ilblr = next
11543	return nil
11544}
11545
11546// NotDone returns true if the page enumeration should be started or is not yet complete.
11547func (page InterfaceLoadBalancerListResultPage) NotDone() bool {
11548	return !page.ilblr.IsEmpty()
11549}
11550
11551// Response returns the raw server response from the last page request.
11552func (page InterfaceLoadBalancerListResultPage) Response() InterfaceLoadBalancerListResult {
11553	return page.ilblr
11554}
11555
11556// Values returns the slice of values for the current page or nil if there are no values.
11557func (page InterfaceLoadBalancerListResultPage) Values() []LoadBalancer {
11558	if page.ilblr.IsEmpty() {
11559		return nil
11560	}
11561	return *page.ilblr.Value
11562}
11563
11564// InterfacePropertiesFormat networkInterface properties.
11565type InterfacePropertiesFormat struct {
11566	// VirtualMachine - The reference of a virtual machine.
11567	VirtualMachine *SubResource `json:"virtualMachine,omitempty"`
11568	// NetworkSecurityGroup - The reference of the NetworkSecurityGroup resource.
11569	NetworkSecurityGroup *SecurityGroup `json:"networkSecurityGroup,omitempty"`
11570	// InterfaceEndpoint - A reference to the interface endpoint to which the network interface is linked.
11571	InterfaceEndpoint *InterfaceEndpoint `json:"interfaceEndpoint,omitempty"`
11572	// IPConfigurations - A list of IPConfigurations of the network interface.
11573	IPConfigurations *[]InterfaceIPConfiguration `json:"ipConfigurations,omitempty"`
11574	// TapConfigurations - A list of TapConfigurations of the network interface.
11575	TapConfigurations *[]InterfaceTapConfiguration `json:"tapConfigurations,omitempty"`
11576	// DNSSettings - The DNS settings in network interface.
11577	DNSSettings *InterfaceDNSSettings `json:"dnsSettings,omitempty"`
11578	// MacAddress - The MAC address of the network interface.
11579	MacAddress *string `json:"macAddress,omitempty"`
11580	// Primary - Gets whether this is a primary network interface on a virtual machine.
11581	Primary *bool `json:"primary,omitempty"`
11582	// EnableAcceleratedNetworking - If the network interface is accelerated networking enabled.
11583	EnableAcceleratedNetworking *bool `json:"enableAcceleratedNetworking,omitempty"`
11584	// EnableIPForwarding - Indicates whether IP forwarding is enabled on this network interface.
11585	EnableIPForwarding *bool `json:"enableIPForwarding,omitempty"`
11586	// HostedWorkloads - A list of references to linked BareMetal resources
11587	HostedWorkloads *[]string `json:"hostedWorkloads,omitempty"`
11588	// ResourceGUID - The resource GUID property of the network interface resource.
11589	ResourceGUID *string `json:"resourceGuid,omitempty"`
11590	// ProvisioningState - The provisioning state of the public IP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
11591	ProvisioningState *string `json:"provisioningState,omitempty"`
11592}
11593
11594// InterfacesCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
11595// operation.
11596type InterfacesCreateOrUpdateFuture struct {
11597	azure.Future
11598}
11599
11600// Result returns the result of the asynchronous operation.
11601// If the operation has not completed it will return an error.
11602func (future *InterfacesCreateOrUpdateFuture) Result(client InterfacesClient) (i Interface, err error) {
11603	var done bool
11604	done, err = future.Done(client)
11605	if err != nil {
11606		err = autorest.NewErrorWithError(err, "network.InterfacesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
11607		return
11608	}
11609	if !done {
11610		err = azure.NewAsyncOpIncompleteError("network.InterfacesCreateOrUpdateFuture")
11611		return
11612	}
11613	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
11614	if i.Response.Response, err = future.GetResult(sender); err == nil && i.Response.Response.StatusCode != http.StatusNoContent {
11615		i, err = client.CreateOrUpdateResponder(i.Response.Response)
11616		if err != nil {
11617			err = autorest.NewErrorWithError(err, "network.InterfacesCreateOrUpdateFuture", "Result", i.Response.Response, "Failure responding to request")
11618		}
11619	}
11620	return
11621}
11622
11623// InterfacesDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
11624type InterfacesDeleteFuture struct {
11625	azure.Future
11626}
11627
11628// Result returns the result of the asynchronous operation.
11629// If the operation has not completed it will return an error.
11630func (future *InterfacesDeleteFuture) Result(client InterfacesClient) (ar autorest.Response, err error) {
11631	var done bool
11632	done, err = future.Done(client)
11633	if err != nil {
11634		err = autorest.NewErrorWithError(err, "network.InterfacesDeleteFuture", "Result", future.Response(), "Polling failure")
11635		return
11636	}
11637	if !done {
11638		err = azure.NewAsyncOpIncompleteError("network.InterfacesDeleteFuture")
11639		return
11640	}
11641	ar.Response = future.Response()
11642	return
11643}
11644
11645// InterfacesGetEffectiveRouteTableFuture an abstraction for monitoring and retrieving the results of a
11646// long-running operation.
11647type InterfacesGetEffectiveRouteTableFuture struct {
11648	azure.Future
11649}
11650
11651// Result returns the result of the asynchronous operation.
11652// If the operation has not completed it will return an error.
11653func (future *InterfacesGetEffectiveRouteTableFuture) Result(client InterfacesClient) (erlr EffectiveRouteListResult, err error) {
11654	var done bool
11655	done, err = future.Done(client)
11656	if err != nil {
11657		err = autorest.NewErrorWithError(err, "network.InterfacesGetEffectiveRouteTableFuture", "Result", future.Response(), "Polling failure")
11658		return
11659	}
11660	if !done {
11661		err = azure.NewAsyncOpIncompleteError("network.InterfacesGetEffectiveRouteTableFuture")
11662		return
11663	}
11664	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
11665	if erlr.Response.Response, err = future.GetResult(sender); err == nil && erlr.Response.Response.StatusCode != http.StatusNoContent {
11666		erlr, err = client.GetEffectiveRouteTableResponder(erlr.Response.Response)
11667		if err != nil {
11668			err = autorest.NewErrorWithError(err, "network.InterfacesGetEffectiveRouteTableFuture", "Result", erlr.Response.Response, "Failure responding to request")
11669		}
11670	}
11671	return
11672}
11673
11674// InterfacesListEffectiveNetworkSecurityGroupsFuture an abstraction for monitoring and retrieving the results of a
11675// long-running operation.
11676type InterfacesListEffectiveNetworkSecurityGroupsFuture struct {
11677	azure.Future
11678}
11679
11680// Result returns the result of the asynchronous operation.
11681// If the operation has not completed it will return an error.
11682func (future *InterfacesListEffectiveNetworkSecurityGroupsFuture) Result(client InterfacesClient) (ensglr EffectiveNetworkSecurityGroupListResult, err error) {
11683	var done bool
11684	done, err = future.Done(client)
11685	if err != nil {
11686		err = autorest.NewErrorWithError(err, "network.InterfacesListEffectiveNetworkSecurityGroupsFuture", "Result", future.Response(), "Polling failure")
11687		return
11688	}
11689	if !done {
11690		err = azure.NewAsyncOpIncompleteError("network.InterfacesListEffectiveNetworkSecurityGroupsFuture")
11691		return
11692	}
11693	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
11694	if ensglr.Response.Response, err = future.GetResult(sender); err == nil && ensglr.Response.Response.StatusCode != http.StatusNoContent {
11695		ensglr, err = client.ListEffectiveNetworkSecurityGroupsResponder(ensglr.Response.Response)
11696		if err != nil {
11697			err = autorest.NewErrorWithError(err, "network.InterfacesListEffectiveNetworkSecurityGroupsFuture", "Result", ensglr.Response.Response, "Failure responding to request")
11698		}
11699	}
11700	return
11701}
11702
11703// InterfacesUpdateTagsFuture an abstraction for monitoring and retrieving the results of a long-running operation.
11704type InterfacesUpdateTagsFuture struct {
11705	azure.Future
11706}
11707
11708// Result returns the result of the asynchronous operation.
11709// If the operation has not completed it will return an error.
11710func (future *InterfacesUpdateTagsFuture) Result(client InterfacesClient) (i Interface, err error) {
11711	var done bool
11712	done, err = future.Done(client)
11713	if err != nil {
11714		err = autorest.NewErrorWithError(err, "network.InterfacesUpdateTagsFuture", "Result", future.Response(), "Polling failure")
11715		return
11716	}
11717	if !done {
11718		err = azure.NewAsyncOpIncompleteError("network.InterfacesUpdateTagsFuture")
11719		return
11720	}
11721	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
11722	if i.Response.Response, err = future.GetResult(sender); err == nil && i.Response.Response.StatusCode != http.StatusNoContent {
11723		i, err = client.UpdateTagsResponder(i.Response.Response)
11724		if err != nil {
11725			err = autorest.NewErrorWithError(err, "network.InterfacesUpdateTagsFuture", "Result", i.Response.Response, "Failure responding to request")
11726		}
11727	}
11728	return
11729}
11730
11731// InterfaceTapConfiguration tap configuration in a Network Interface
11732type InterfaceTapConfiguration struct {
11733	autorest.Response `json:"-"`
11734	// InterfaceTapConfigurationPropertiesFormat - Properties of the Virtual Network Tap configuration
11735	*InterfaceTapConfigurationPropertiesFormat `json:"properties,omitempty"`
11736	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
11737	Name *string `json:"name,omitempty"`
11738	// Etag - A unique read-only string that changes whenever the resource is updated.
11739	Etag *string `json:"etag,omitempty"`
11740	// Type - Sub Resource type.
11741	Type *string `json:"type,omitempty"`
11742	// ID - Resource ID.
11743	ID *string `json:"id,omitempty"`
11744}
11745
11746// MarshalJSON is the custom marshaler for InterfaceTapConfiguration.
11747func (itc InterfaceTapConfiguration) MarshalJSON() ([]byte, error) {
11748	objectMap := make(map[string]interface{})
11749	if itc.InterfaceTapConfigurationPropertiesFormat != nil {
11750		objectMap["properties"] = itc.InterfaceTapConfigurationPropertiesFormat
11751	}
11752	if itc.Name != nil {
11753		objectMap["name"] = itc.Name
11754	}
11755	if itc.Etag != nil {
11756		objectMap["etag"] = itc.Etag
11757	}
11758	if itc.Type != nil {
11759		objectMap["type"] = itc.Type
11760	}
11761	if itc.ID != nil {
11762		objectMap["id"] = itc.ID
11763	}
11764	return json.Marshal(objectMap)
11765}
11766
11767// UnmarshalJSON is the custom unmarshaler for InterfaceTapConfiguration struct.
11768func (itc *InterfaceTapConfiguration) UnmarshalJSON(body []byte) error {
11769	var m map[string]*json.RawMessage
11770	err := json.Unmarshal(body, &m)
11771	if err != nil {
11772		return err
11773	}
11774	for k, v := range m {
11775		switch k {
11776		case "properties":
11777			if v != nil {
11778				var interfaceTapConfigurationPropertiesFormat InterfaceTapConfigurationPropertiesFormat
11779				err = json.Unmarshal(*v, &interfaceTapConfigurationPropertiesFormat)
11780				if err != nil {
11781					return err
11782				}
11783				itc.InterfaceTapConfigurationPropertiesFormat = &interfaceTapConfigurationPropertiesFormat
11784			}
11785		case "name":
11786			if v != nil {
11787				var name string
11788				err = json.Unmarshal(*v, &name)
11789				if err != nil {
11790					return err
11791				}
11792				itc.Name = &name
11793			}
11794		case "etag":
11795			if v != nil {
11796				var etag string
11797				err = json.Unmarshal(*v, &etag)
11798				if err != nil {
11799					return err
11800				}
11801				itc.Etag = &etag
11802			}
11803		case "type":
11804			if v != nil {
11805				var typeVar string
11806				err = json.Unmarshal(*v, &typeVar)
11807				if err != nil {
11808					return err
11809				}
11810				itc.Type = &typeVar
11811			}
11812		case "id":
11813			if v != nil {
11814				var ID string
11815				err = json.Unmarshal(*v, &ID)
11816				if err != nil {
11817					return err
11818				}
11819				itc.ID = &ID
11820			}
11821		}
11822	}
11823
11824	return nil
11825}
11826
11827// InterfaceTapConfigurationListResult response for list tap configurations API service call.
11828type InterfaceTapConfigurationListResult struct {
11829	autorest.Response `json:"-"`
11830	// Value - A list of tap configurations.
11831	Value *[]InterfaceTapConfiguration `json:"value,omitempty"`
11832	// NextLink - The URL to get the next set of results.
11833	NextLink *string `json:"nextLink,omitempty"`
11834}
11835
11836// InterfaceTapConfigurationListResultIterator provides access to a complete listing of InterfaceTapConfiguration
11837// values.
11838type InterfaceTapConfigurationListResultIterator struct {
11839	i    int
11840	page InterfaceTapConfigurationListResultPage
11841}
11842
11843// Next advances to the next value.  If there was an error making
11844// the request the iterator does not advance and the error is returned.
11845func (iter *InterfaceTapConfigurationListResultIterator) Next() error {
11846	iter.i++
11847	if iter.i < len(iter.page.Values()) {
11848		return nil
11849	}
11850	err := iter.page.Next()
11851	if err != nil {
11852		iter.i--
11853		return err
11854	}
11855	iter.i = 0
11856	return nil
11857}
11858
11859// NotDone returns true if the enumeration should be started or is not yet complete.
11860func (iter InterfaceTapConfigurationListResultIterator) NotDone() bool {
11861	return iter.page.NotDone() && iter.i < len(iter.page.Values())
11862}
11863
11864// Response returns the raw server response from the last page request.
11865func (iter InterfaceTapConfigurationListResultIterator) Response() InterfaceTapConfigurationListResult {
11866	return iter.page.Response()
11867}
11868
11869// Value returns the current value or a zero-initialized value if the
11870// iterator has advanced beyond the end of the collection.
11871func (iter InterfaceTapConfigurationListResultIterator) Value() InterfaceTapConfiguration {
11872	if !iter.page.NotDone() {
11873		return InterfaceTapConfiguration{}
11874	}
11875	return iter.page.Values()[iter.i]
11876}
11877
11878// IsEmpty returns true if the ListResult contains no values.
11879func (itclr InterfaceTapConfigurationListResult) IsEmpty() bool {
11880	return itclr.Value == nil || len(*itclr.Value) == 0
11881}
11882
11883// interfaceTapConfigurationListResultPreparer prepares a request to retrieve the next set of results.
11884// It returns nil if no more results exist.
11885func (itclr InterfaceTapConfigurationListResult) interfaceTapConfigurationListResultPreparer() (*http.Request, error) {
11886	if itclr.NextLink == nil || len(to.String(itclr.NextLink)) < 1 {
11887		return nil, nil
11888	}
11889	return autorest.Prepare(&http.Request{},
11890		autorest.AsJSON(),
11891		autorest.AsGet(),
11892		autorest.WithBaseURL(to.String(itclr.NextLink)))
11893}
11894
11895// InterfaceTapConfigurationListResultPage contains a page of InterfaceTapConfiguration values.
11896type InterfaceTapConfigurationListResultPage struct {
11897	fn    func(InterfaceTapConfigurationListResult) (InterfaceTapConfigurationListResult, error)
11898	itclr InterfaceTapConfigurationListResult
11899}
11900
11901// Next advances to the next page of values.  If there was an error making
11902// the request the page does not advance and the error is returned.
11903func (page *InterfaceTapConfigurationListResultPage) Next() error {
11904	next, err := page.fn(page.itclr)
11905	if err != nil {
11906		return err
11907	}
11908	page.itclr = next
11909	return nil
11910}
11911
11912// NotDone returns true if the page enumeration should be started or is not yet complete.
11913func (page InterfaceTapConfigurationListResultPage) NotDone() bool {
11914	return !page.itclr.IsEmpty()
11915}
11916
11917// Response returns the raw server response from the last page request.
11918func (page InterfaceTapConfigurationListResultPage) Response() InterfaceTapConfigurationListResult {
11919	return page.itclr
11920}
11921
11922// Values returns the slice of values for the current page or nil if there are no values.
11923func (page InterfaceTapConfigurationListResultPage) Values() []InterfaceTapConfiguration {
11924	if page.itclr.IsEmpty() {
11925		return nil
11926	}
11927	return *page.itclr.Value
11928}
11929
11930// InterfaceTapConfigurationPropertiesFormat properties of Virtual Network Tap configuration.
11931type InterfaceTapConfigurationPropertiesFormat struct {
11932	// VirtualNetworkTap - The reference of the Virtual Network Tap resource.
11933	VirtualNetworkTap *VirtualNetworkTap `json:"virtualNetworkTap,omitempty"`
11934	// ProvisioningState - The provisioning state of the network interface tap configuration. Possible values are: 'Updating', 'Deleting', and 'Failed'.
11935	ProvisioningState *string `json:"provisioningState,omitempty"`
11936}
11937
11938// InterfaceTapConfigurationsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
11939// long-running operation.
11940type InterfaceTapConfigurationsCreateOrUpdateFuture struct {
11941	azure.Future
11942}
11943
11944// Result returns the result of the asynchronous operation.
11945// If the operation has not completed it will return an error.
11946func (future *InterfaceTapConfigurationsCreateOrUpdateFuture) Result(client InterfaceTapConfigurationsClient) (itc InterfaceTapConfiguration, err error) {
11947	var done bool
11948	done, err = future.Done(client)
11949	if err != nil {
11950		err = autorest.NewErrorWithError(err, "network.InterfaceTapConfigurationsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
11951		return
11952	}
11953	if !done {
11954		err = azure.NewAsyncOpIncompleteError("network.InterfaceTapConfigurationsCreateOrUpdateFuture")
11955		return
11956	}
11957	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
11958	if itc.Response.Response, err = future.GetResult(sender); err == nil && itc.Response.Response.StatusCode != http.StatusNoContent {
11959		itc, err = client.CreateOrUpdateResponder(itc.Response.Response)
11960		if err != nil {
11961			err = autorest.NewErrorWithError(err, "network.InterfaceTapConfigurationsCreateOrUpdateFuture", "Result", itc.Response.Response, "Failure responding to request")
11962		}
11963	}
11964	return
11965}
11966
11967// InterfaceTapConfigurationsDeleteFuture an abstraction for monitoring and retrieving the results of a
11968// long-running operation.
11969type InterfaceTapConfigurationsDeleteFuture struct {
11970	azure.Future
11971}
11972
11973// Result returns the result of the asynchronous operation.
11974// If the operation has not completed it will return an error.
11975func (future *InterfaceTapConfigurationsDeleteFuture) Result(client InterfaceTapConfigurationsClient) (ar autorest.Response, err error) {
11976	var done bool
11977	done, err = future.Done(client)
11978	if err != nil {
11979		err = autorest.NewErrorWithError(err, "network.InterfaceTapConfigurationsDeleteFuture", "Result", future.Response(), "Polling failure")
11980		return
11981	}
11982	if !done {
11983		err = azure.NewAsyncOpIncompleteError("network.InterfaceTapConfigurationsDeleteFuture")
11984		return
11985	}
11986	ar.Response = future.Response()
11987	return
11988}
11989
11990// IPAddressAvailabilityResult response for CheckIPAddressAvailability API service call
11991type IPAddressAvailabilityResult struct {
11992	autorest.Response `json:"-"`
11993	// Available - Private IP address availability.
11994	Available *bool `json:"available,omitempty"`
11995	// AvailableIPAddresses - Contains other available private IP addresses if the asked for address is taken.
11996	AvailableIPAddresses *[]string `json:"availableIPAddresses,omitempty"`
11997}
11998
11999// IPConfiguration IP configuration
12000type IPConfiguration struct {
12001	// IPConfigurationPropertiesFormat - Properties of the IP configuration
12002	*IPConfigurationPropertiesFormat `json:"properties,omitempty"`
12003	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
12004	Name *string `json:"name,omitempty"`
12005	// Etag - A unique read-only string that changes whenever the resource is updated.
12006	Etag *string `json:"etag,omitempty"`
12007	// ID - Resource ID.
12008	ID *string `json:"id,omitempty"`
12009}
12010
12011// MarshalJSON is the custom marshaler for IPConfiguration.
12012func (ic IPConfiguration) MarshalJSON() ([]byte, error) {
12013	objectMap := make(map[string]interface{})
12014	if ic.IPConfigurationPropertiesFormat != nil {
12015		objectMap["properties"] = ic.IPConfigurationPropertiesFormat
12016	}
12017	if ic.Name != nil {
12018		objectMap["name"] = ic.Name
12019	}
12020	if ic.Etag != nil {
12021		objectMap["etag"] = ic.Etag
12022	}
12023	if ic.ID != nil {
12024		objectMap["id"] = ic.ID
12025	}
12026	return json.Marshal(objectMap)
12027}
12028
12029// UnmarshalJSON is the custom unmarshaler for IPConfiguration struct.
12030func (ic *IPConfiguration) UnmarshalJSON(body []byte) error {
12031	var m map[string]*json.RawMessage
12032	err := json.Unmarshal(body, &m)
12033	if err != nil {
12034		return err
12035	}
12036	for k, v := range m {
12037		switch k {
12038		case "properties":
12039			if v != nil {
12040				var IPConfigurationPropertiesFormat IPConfigurationPropertiesFormat
12041				err = json.Unmarshal(*v, &IPConfigurationPropertiesFormat)
12042				if err != nil {
12043					return err
12044				}
12045				ic.IPConfigurationPropertiesFormat = &IPConfigurationPropertiesFormat
12046			}
12047		case "name":
12048			if v != nil {
12049				var name string
12050				err = json.Unmarshal(*v, &name)
12051				if err != nil {
12052					return err
12053				}
12054				ic.Name = &name
12055			}
12056		case "etag":
12057			if v != nil {
12058				var etag string
12059				err = json.Unmarshal(*v, &etag)
12060				if err != nil {
12061					return err
12062				}
12063				ic.Etag = &etag
12064			}
12065		case "id":
12066			if v != nil {
12067				var ID string
12068				err = json.Unmarshal(*v, &ID)
12069				if err != nil {
12070					return err
12071				}
12072				ic.ID = &ID
12073			}
12074		}
12075	}
12076
12077	return nil
12078}
12079
12080// IPConfigurationProfile IP configuration profile child resource.
12081type IPConfigurationProfile struct {
12082	// IPConfigurationProfilePropertiesFormat - Properties of the IP configuration profile.
12083	*IPConfigurationProfilePropertiesFormat `json:"properties,omitempty"`
12084	// Name - The name of the resource. This name can be used to access the resource.
12085	Name *string `json:"name,omitempty"`
12086	// Type - Sub Resource type.
12087	Type *string `json:"type,omitempty"`
12088	// Etag - A unique read-only string that changes whenever the resource is updated.
12089	Etag *string `json:"etag,omitempty"`
12090	// ID - Resource ID.
12091	ID *string `json:"id,omitempty"`
12092}
12093
12094// MarshalJSON is the custom marshaler for IPConfigurationProfile.
12095func (icp IPConfigurationProfile) MarshalJSON() ([]byte, error) {
12096	objectMap := make(map[string]interface{})
12097	if icp.IPConfigurationProfilePropertiesFormat != nil {
12098		objectMap["properties"] = icp.IPConfigurationProfilePropertiesFormat
12099	}
12100	if icp.Name != nil {
12101		objectMap["name"] = icp.Name
12102	}
12103	if icp.Type != nil {
12104		objectMap["type"] = icp.Type
12105	}
12106	if icp.Etag != nil {
12107		objectMap["etag"] = icp.Etag
12108	}
12109	if icp.ID != nil {
12110		objectMap["id"] = icp.ID
12111	}
12112	return json.Marshal(objectMap)
12113}
12114
12115// UnmarshalJSON is the custom unmarshaler for IPConfigurationProfile struct.
12116func (icp *IPConfigurationProfile) UnmarshalJSON(body []byte) error {
12117	var m map[string]*json.RawMessage
12118	err := json.Unmarshal(body, &m)
12119	if err != nil {
12120		return err
12121	}
12122	for k, v := range m {
12123		switch k {
12124		case "properties":
12125			if v != nil {
12126				var IPConfigurationProfilePropertiesFormat IPConfigurationProfilePropertiesFormat
12127				err = json.Unmarshal(*v, &IPConfigurationProfilePropertiesFormat)
12128				if err != nil {
12129					return err
12130				}
12131				icp.IPConfigurationProfilePropertiesFormat = &IPConfigurationProfilePropertiesFormat
12132			}
12133		case "name":
12134			if v != nil {
12135				var name string
12136				err = json.Unmarshal(*v, &name)
12137				if err != nil {
12138					return err
12139				}
12140				icp.Name = &name
12141			}
12142		case "type":
12143			if v != nil {
12144				var typeVar string
12145				err = json.Unmarshal(*v, &typeVar)
12146				if err != nil {
12147					return err
12148				}
12149				icp.Type = &typeVar
12150			}
12151		case "etag":
12152			if v != nil {
12153				var etag string
12154				err = json.Unmarshal(*v, &etag)
12155				if err != nil {
12156					return err
12157				}
12158				icp.Etag = &etag
12159			}
12160		case "id":
12161			if v != nil {
12162				var ID string
12163				err = json.Unmarshal(*v, &ID)
12164				if err != nil {
12165					return err
12166				}
12167				icp.ID = &ID
12168			}
12169		}
12170	}
12171
12172	return nil
12173}
12174
12175// IPConfigurationProfilePropertiesFormat IP configruation profile properties.
12176type IPConfigurationProfilePropertiesFormat struct {
12177	// Subnet - The reference of the subnet resource to create a contatainer network interface ip configruation.
12178	Subnet *Subnet `json:"subnet,omitempty"`
12179	// ProvisioningState - The provisioning state of the resource.
12180	ProvisioningState *string `json:"provisioningState,omitempty"`
12181}
12182
12183// IPConfigurationPropertiesFormat properties of IP configuration.
12184type IPConfigurationPropertiesFormat struct {
12185	// PrivateIPAddress - The private IP address of the IP configuration.
12186	PrivateIPAddress *string `json:"privateIPAddress,omitempty"`
12187	// PrivateIPAllocationMethod - The private IP allocation method. Possible values are 'Static' and 'Dynamic'. Possible values include: 'Static', 'Dynamic'
12188	PrivateIPAllocationMethod IPAllocationMethod `json:"privateIPAllocationMethod,omitempty"`
12189	// Subnet - The reference of the subnet resource.
12190	Subnet *Subnet `json:"subnet,omitempty"`
12191	// PublicIPAddress - The reference of the public IP resource.
12192	PublicIPAddress *PublicIPAddress `json:"publicIPAddress,omitempty"`
12193	// ProvisioningState - Gets the provisioning state of the public IP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
12194	ProvisioningState *string `json:"provisioningState,omitempty"`
12195}
12196
12197// IpsecPolicy an IPSec Policy configuration for a virtual network gateway connection
12198type IpsecPolicy struct {
12199	// SaLifeTimeSeconds - The IPSec Security Association (also called Quick Mode or Phase 2 SA) lifetime in seconds for a site to site VPN tunnel.
12200	SaLifeTimeSeconds *int32 `json:"saLifeTimeSeconds,omitempty"`
12201	// SaDataSizeKilobytes - The IPSec Security Association (also called Quick Mode or Phase 2 SA) payload size in KB for a site to site VPN tunnel.
12202	SaDataSizeKilobytes *int32 `json:"saDataSizeKilobytes,omitempty"`
12203	// IpsecEncryption - The IPSec encryption algorithm (IKE phase 1). Possible values include: 'IpsecEncryptionNone', 'IpsecEncryptionDES', 'IpsecEncryptionDES3', 'IpsecEncryptionAES128', 'IpsecEncryptionAES192', 'IpsecEncryptionAES256', 'IpsecEncryptionGCMAES128', 'IpsecEncryptionGCMAES192', 'IpsecEncryptionGCMAES256'
12204	IpsecEncryption IpsecEncryption `json:"ipsecEncryption,omitempty"`
12205	// IpsecIntegrity - The IPSec integrity algorithm (IKE phase 1). Possible values include: 'IpsecIntegrityMD5', 'IpsecIntegritySHA1', 'IpsecIntegritySHA256', 'IpsecIntegrityGCMAES128', 'IpsecIntegrityGCMAES192', 'IpsecIntegrityGCMAES256'
12206	IpsecIntegrity IpsecIntegrity `json:"ipsecIntegrity,omitempty"`
12207	// IkeEncryption - The IKE encryption algorithm (IKE phase 2). Possible values include: 'DES', 'DES3', 'AES128', 'AES192', 'AES256', 'GCMAES256', 'GCMAES128'
12208	IkeEncryption IkeEncryption `json:"ikeEncryption,omitempty"`
12209	// IkeIntegrity - The IKE integrity algorithm (IKE phase 2). Possible values include: 'IkeIntegrityMD5', 'IkeIntegritySHA1', 'IkeIntegritySHA256', 'IkeIntegritySHA384', 'IkeIntegrityGCMAES256', 'IkeIntegrityGCMAES128'
12210	IkeIntegrity IkeIntegrity `json:"ikeIntegrity,omitempty"`
12211	// DhGroup - The DH Groups used in IKE Phase 1 for initial SA. Possible values include: 'None', 'DHGroup1', 'DHGroup2', 'DHGroup14', 'DHGroup2048', 'ECP256', 'ECP384', 'DHGroup24'
12212	DhGroup DhGroup `json:"dhGroup,omitempty"`
12213	// PfsGroup - The Pfs Groups used in IKE Phase 2 for new child SA. Possible values include: 'PfsGroupNone', 'PfsGroupPFS1', 'PfsGroupPFS2', 'PfsGroupPFS2048', 'PfsGroupECP256', 'PfsGroupECP384', 'PfsGroupPFS24', 'PfsGroupPFS14', 'PfsGroupPFSMM'
12214	PfsGroup PfsGroup `json:"pfsGroup,omitempty"`
12215}
12216
12217// IPTag contains the IpTag associated with the object
12218type IPTag struct {
12219	// IPTagType - Gets or sets the ipTag type: Example FirstPartyUsage.
12220	IPTagType *string `json:"ipTagType,omitempty"`
12221	// Tag - Gets or sets value of the IpTag associated with the public IP. Example SQL, Storage etc
12222	Tag *string `json:"tag,omitempty"`
12223}
12224
12225// Ipv6ExpressRouteCircuitPeeringConfig contains IPv6 peering config.
12226type Ipv6ExpressRouteCircuitPeeringConfig struct {
12227	// PrimaryPeerAddressPrefix - The primary address prefix.
12228	PrimaryPeerAddressPrefix *string `json:"primaryPeerAddressPrefix,omitempty"`
12229	// SecondaryPeerAddressPrefix - The secondary address prefix.
12230	SecondaryPeerAddressPrefix *string `json:"secondaryPeerAddressPrefix,omitempty"`
12231	// MicrosoftPeeringConfig - The Microsoft peering configuration.
12232	MicrosoftPeeringConfig *ExpressRouteCircuitPeeringConfig `json:"microsoftPeeringConfig,omitempty"`
12233	// RouteFilter - The reference of the RouteFilter resource.
12234	RouteFilter *RouteFilter `json:"routeFilter,omitempty"`
12235	// State - The state of peering. Possible values are: 'Disabled' and 'Enabled'. Possible values include: 'ExpressRouteCircuitPeeringStateDisabled', 'ExpressRouteCircuitPeeringStateEnabled'
12236	State ExpressRouteCircuitPeeringState `json:"state,omitempty"`
12237}
12238
12239// ListHubVirtualNetworkConnectionsResult list of HubVirtualNetworkConnections and a URL nextLink to get the next
12240// set of results.
12241type ListHubVirtualNetworkConnectionsResult struct {
12242	autorest.Response `json:"-"`
12243	// Value - List of HubVirtualNetworkConnections.
12244	Value *[]HubVirtualNetworkConnection `json:"value,omitempty"`
12245	// NextLink - URL to get the next set of operation list results if there are any.
12246	NextLink *string `json:"nextLink,omitempty"`
12247}
12248
12249// ListHubVirtualNetworkConnectionsResultIterator provides access to a complete listing of
12250// HubVirtualNetworkConnection values.
12251type ListHubVirtualNetworkConnectionsResultIterator struct {
12252	i    int
12253	page ListHubVirtualNetworkConnectionsResultPage
12254}
12255
12256// Next advances to the next value.  If there was an error making
12257// the request the iterator does not advance and the error is returned.
12258func (iter *ListHubVirtualNetworkConnectionsResultIterator) Next() error {
12259	iter.i++
12260	if iter.i < len(iter.page.Values()) {
12261		return nil
12262	}
12263	err := iter.page.Next()
12264	if err != nil {
12265		iter.i--
12266		return err
12267	}
12268	iter.i = 0
12269	return nil
12270}
12271
12272// NotDone returns true if the enumeration should be started or is not yet complete.
12273func (iter ListHubVirtualNetworkConnectionsResultIterator) NotDone() bool {
12274	return iter.page.NotDone() && iter.i < len(iter.page.Values())
12275}
12276
12277// Response returns the raw server response from the last page request.
12278func (iter ListHubVirtualNetworkConnectionsResultIterator) Response() ListHubVirtualNetworkConnectionsResult {
12279	return iter.page.Response()
12280}
12281
12282// Value returns the current value or a zero-initialized value if the
12283// iterator has advanced beyond the end of the collection.
12284func (iter ListHubVirtualNetworkConnectionsResultIterator) Value() HubVirtualNetworkConnection {
12285	if !iter.page.NotDone() {
12286		return HubVirtualNetworkConnection{}
12287	}
12288	return iter.page.Values()[iter.i]
12289}
12290
12291// IsEmpty returns true if the ListResult contains no values.
12292func (lhvncr ListHubVirtualNetworkConnectionsResult) IsEmpty() bool {
12293	return lhvncr.Value == nil || len(*lhvncr.Value) == 0
12294}
12295
12296// listHubVirtualNetworkConnectionsResultPreparer prepares a request to retrieve the next set of results.
12297// It returns nil if no more results exist.
12298func (lhvncr ListHubVirtualNetworkConnectionsResult) listHubVirtualNetworkConnectionsResultPreparer() (*http.Request, error) {
12299	if lhvncr.NextLink == nil || len(to.String(lhvncr.NextLink)) < 1 {
12300		return nil, nil
12301	}
12302	return autorest.Prepare(&http.Request{},
12303		autorest.AsJSON(),
12304		autorest.AsGet(),
12305		autorest.WithBaseURL(to.String(lhvncr.NextLink)))
12306}
12307
12308// ListHubVirtualNetworkConnectionsResultPage contains a page of HubVirtualNetworkConnection values.
12309type ListHubVirtualNetworkConnectionsResultPage struct {
12310	fn     func(ListHubVirtualNetworkConnectionsResult) (ListHubVirtualNetworkConnectionsResult, error)
12311	lhvncr ListHubVirtualNetworkConnectionsResult
12312}
12313
12314// Next advances to the next page of values.  If there was an error making
12315// the request the page does not advance and the error is returned.
12316func (page *ListHubVirtualNetworkConnectionsResultPage) Next() error {
12317	next, err := page.fn(page.lhvncr)
12318	if err != nil {
12319		return err
12320	}
12321	page.lhvncr = next
12322	return nil
12323}
12324
12325// NotDone returns true if the page enumeration should be started or is not yet complete.
12326func (page ListHubVirtualNetworkConnectionsResultPage) NotDone() bool {
12327	return !page.lhvncr.IsEmpty()
12328}
12329
12330// Response returns the raw server response from the last page request.
12331func (page ListHubVirtualNetworkConnectionsResultPage) Response() ListHubVirtualNetworkConnectionsResult {
12332	return page.lhvncr
12333}
12334
12335// Values returns the slice of values for the current page or nil if there are no values.
12336func (page ListHubVirtualNetworkConnectionsResultPage) Values() []HubVirtualNetworkConnection {
12337	if page.lhvncr.IsEmpty() {
12338		return nil
12339	}
12340	return *page.lhvncr.Value
12341}
12342
12343// ListP2SVpnGatewaysResult result of the request to list P2SVpnGateways. It contains a list of P2SVpnGateways and
12344// a URL nextLink to get the next set of results.
12345type ListP2SVpnGatewaysResult struct {
12346	autorest.Response `json:"-"`
12347	// Value - List of P2SVpnGateways.
12348	Value *[]P2SVpnGateway `json:"value,omitempty"`
12349	// NextLink - URL to get the next set of operation list results if there are any.
12350	NextLink *string `json:"nextLink,omitempty"`
12351}
12352
12353// ListP2SVpnGatewaysResultIterator provides access to a complete listing of P2SVpnGateway values.
12354type ListP2SVpnGatewaysResultIterator struct {
12355	i    int
12356	page ListP2SVpnGatewaysResultPage
12357}
12358
12359// Next advances to the next value.  If there was an error making
12360// the request the iterator does not advance and the error is returned.
12361func (iter *ListP2SVpnGatewaysResultIterator) Next() error {
12362	iter.i++
12363	if iter.i < len(iter.page.Values()) {
12364		return nil
12365	}
12366	err := iter.page.Next()
12367	if err != nil {
12368		iter.i--
12369		return err
12370	}
12371	iter.i = 0
12372	return nil
12373}
12374
12375// NotDone returns true if the enumeration should be started or is not yet complete.
12376func (iter ListP2SVpnGatewaysResultIterator) NotDone() bool {
12377	return iter.page.NotDone() && iter.i < len(iter.page.Values())
12378}
12379
12380// Response returns the raw server response from the last page request.
12381func (iter ListP2SVpnGatewaysResultIterator) Response() ListP2SVpnGatewaysResult {
12382	return iter.page.Response()
12383}
12384
12385// Value returns the current value or a zero-initialized value if the
12386// iterator has advanced beyond the end of the collection.
12387func (iter ListP2SVpnGatewaysResultIterator) Value() P2SVpnGateway {
12388	if !iter.page.NotDone() {
12389		return P2SVpnGateway{}
12390	}
12391	return iter.page.Values()[iter.i]
12392}
12393
12394// IsEmpty returns true if the ListResult contains no values.
12395func (lpvgr ListP2SVpnGatewaysResult) IsEmpty() bool {
12396	return lpvgr.Value == nil || len(*lpvgr.Value) == 0
12397}
12398
12399// listP2SVpnGatewaysResultPreparer prepares a request to retrieve the next set of results.
12400// It returns nil if no more results exist.
12401func (lpvgr ListP2SVpnGatewaysResult) listP2SVpnGatewaysResultPreparer() (*http.Request, error) {
12402	if lpvgr.NextLink == nil || len(to.String(lpvgr.NextLink)) < 1 {
12403		return nil, nil
12404	}
12405	return autorest.Prepare(&http.Request{},
12406		autorest.AsJSON(),
12407		autorest.AsGet(),
12408		autorest.WithBaseURL(to.String(lpvgr.NextLink)))
12409}
12410
12411// ListP2SVpnGatewaysResultPage contains a page of P2SVpnGateway values.
12412type ListP2SVpnGatewaysResultPage struct {
12413	fn    func(ListP2SVpnGatewaysResult) (ListP2SVpnGatewaysResult, error)
12414	lpvgr ListP2SVpnGatewaysResult
12415}
12416
12417// Next advances to the next page of values.  If there was an error making
12418// the request the page does not advance and the error is returned.
12419func (page *ListP2SVpnGatewaysResultPage) Next() error {
12420	next, err := page.fn(page.lpvgr)
12421	if err != nil {
12422		return err
12423	}
12424	page.lpvgr = next
12425	return nil
12426}
12427
12428// NotDone returns true if the page enumeration should be started or is not yet complete.
12429func (page ListP2SVpnGatewaysResultPage) NotDone() bool {
12430	return !page.lpvgr.IsEmpty()
12431}
12432
12433// Response returns the raw server response from the last page request.
12434func (page ListP2SVpnGatewaysResultPage) Response() ListP2SVpnGatewaysResult {
12435	return page.lpvgr
12436}
12437
12438// Values returns the slice of values for the current page or nil if there are no values.
12439func (page ListP2SVpnGatewaysResultPage) Values() []P2SVpnGateway {
12440	if page.lpvgr.IsEmpty() {
12441		return nil
12442	}
12443	return *page.lpvgr.Value
12444}
12445
12446// ListP2SVpnServerConfigurationsResult result of the request to list all P2SVpnServerConfigurations associated to
12447// a VirtualWan. It contains a list of P2SVpnServerConfigurations and a URL nextLink to get the next set of
12448// results.
12449type ListP2SVpnServerConfigurationsResult struct {
12450	autorest.Response `json:"-"`
12451	// Value - List of P2SVpnServerConfigurations.
12452	Value *[]P2SVpnServerConfiguration `json:"value,omitempty"`
12453	// NextLink - URL to get the next set of operation list results if there are any.
12454	NextLink *string `json:"nextLink,omitempty"`
12455}
12456
12457// ListP2SVpnServerConfigurationsResultIterator provides access to a complete listing of P2SVpnServerConfiguration
12458// values.
12459type ListP2SVpnServerConfigurationsResultIterator struct {
12460	i    int
12461	page ListP2SVpnServerConfigurationsResultPage
12462}
12463
12464// Next advances to the next value.  If there was an error making
12465// the request the iterator does not advance and the error is returned.
12466func (iter *ListP2SVpnServerConfigurationsResultIterator) Next() error {
12467	iter.i++
12468	if iter.i < len(iter.page.Values()) {
12469		return nil
12470	}
12471	err := iter.page.Next()
12472	if err != nil {
12473		iter.i--
12474		return err
12475	}
12476	iter.i = 0
12477	return nil
12478}
12479
12480// NotDone returns true if the enumeration should be started or is not yet complete.
12481func (iter ListP2SVpnServerConfigurationsResultIterator) NotDone() bool {
12482	return iter.page.NotDone() && iter.i < len(iter.page.Values())
12483}
12484
12485// Response returns the raw server response from the last page request.
12486func (iter ListP2SVpnServerConfigurationsResultIterator) Response() ListP2SVpnServerConfigurationsResult {
12487	return iter.page.Response()
12488}
12489
12490// Value returns the current value or a zero-initialized value if the
12491// iterator has advanced beyond the end of the collection.
12492func (iter ListP2SVpnServerConfigurationsResultIterator) Value() P2SVpnServerConfiguration {
12493	if !iter.page.NotDone() {
12494		return P2SVpnServerConfiguration{}
12495	}
12496	return iter.page.Values()[iter.i]
12497}
12498
12499// IsEmpty returns true if the ListResult contains no values.
12500func (lpvscr ListP2SVpnServerConfigurationsResult) IsEmpty() bool {
12501	return lpvscr.Value == nil || len(*lpvscr.Value) == 0
12502}
12503
12504// listP2SVpnServerConfigurationsResultPreparer prepares a request to retrieve the next set of results.
12505// It returns nil if no more results exist.
12506func (lpvscr ListP2SVpnServerConfigurationsResult) listP2SVpnServerConfigurationsResultPreparer() (*http.Request, error) {
12507	if lpvscr.NextLink == nil || len(to.String(lpvscr.NextLink)) < 1 {
12508		return nil, nil
12509	}
12510	return autorest.Prepare(&http.Request{},
12511		autorest.AsJSON(),
12512		autorest.AsGet(),
12513		autorest.WithBaseURL(to.String(lpvscr.NextLink)))
12514}
12515
12516// ListP2SVpnServerConfigurationsResultPage contains a page of P2SVpnServerConfiguration values.
12517type ListP2SVpnServerConfigurationsResultPage struct {
12518	fn     func(ListP2SVpnServerConfigurationsResult) (ListP2SVpnServerConfigurationsResult, error)
12519	lpvscr ListP2SVpnServerConfigurationsResult
12520}
12521
12522// Next advances to the next page of values.  If there was an error making
12523// the request the page does not advance and the error is returned.
12524func (page *ListP2SVpnServerConfigurationsResultPage) Next() error {
12525	next, err := page.fn(page.lpvscr)
12526	if err != nil {
12527		return err
12528	}
12529	page.lpvscr = next
12530	return nil
12531}
12532
12533// NotDone returns true if the page enumeration should be started or is not yet complete.
12534func (page ListP2SVpnServerConfigurationsResultPage) NotDone() bool {
12535	return !page.lpvscr.IsEmpty()
12536}
12537
12538// Response returns the raw server response from the last page request.
12539func (page ListP2SVpnServerConfigurationsResultPage) Response() ListP2SVpnServerConfigurationsResult {
12540	return page.lpvscr
12541}
12542
12543// Values returns the slice of values for the current page or nil if there are no values.
12544func (page ListP2SVpnServerConfigurationsResultPage) Values() []P2SVpnServerConfiguration {
12545	if page.lpvscr.IsEmpty() {
12546		return nil
12547	}
12548	return *page.lpvscr.Value
12549}
12550
12551// ListVirtualHubsResult result of the request to list VirtualHubs. It contains a list of VirtualHubs and a URL
12552// nextLink to get the next set of results.
12553type ListVirtualHubsResult struct {
12554	autorest.Response `json:"-"`
12555	// Value - List of VirtualHubs.
12556	Value *[]VirtualHub `json:"value,omitempty"`
12557	// NextLink - URL to get the next set of operation list results if there are any.
12558	NextLink *string `json:"nextLink,omitempty"`
12559}
12560
12561// ListVirtualHubsResultIterator provides access to a complete listing of VirtualHub values.
12562type ListVirtualHubsResultIterator struct {
12563	i    int
12564	page ListVirtualHubsResultPage
12565}
12566
12567// Next advances to the next value.  If there was an error making
12568// the request the iterator does not advance and the error is returned.
12569func (iter *ListVirtualHubsResultIterator) Next() error {
12570	iter.i++
12571	if iter.i < len(iter.page.Values()) {
12572		return nil
12573	}
12574	err := iter.page.Next()
12575	if err != nil {
12576		iter.i--
12577		return err
12578	}
12579	iter.i = 0
12580	return nil
12581}
12582
12583// NotDone returns true if the enumeration should be started or is not yet complete.
12584func (iter ListVirtualHubsResultIterator) NotDone() bool {
12585	return iter.page.NotDone() && iter.i < len(iter.page.Values())
12586}
12587
12588// Response returns the raw server response from the last page request.
12589func (iter ListVirtualHubsResultIterator) Response() ListVirtualHubsResult {
12590	return iter.page.Response()
12591}
12592
12593// Value returns the current value or a zero-initialized value if the
12594// iterator has advanced beyond the end of the collection.
12595func (iter ListVirtualHubsResultIterator) Value() VirtualHub {
12596	if !iter.page.NotDone() {
12597		return VirtualHub{}
12598	}
12599	return iter.page.Values()[iter.i]
12600}
12601
12602// IsEmpty returns true if the ListResult contains no values.
12603func (lvhr ListVirtualHubsResult) IsEmpty() bool {
12604	return lvhr.Value == nil || len(*lvhr.Value) == 0
12605}
12606
12607// listVirtualHubsResultPreparer prepares a request to retrieve the next set of results.
12608// It returns nil if no more results exist.
12609func (lvhr ListVirtualHubsResult) listVirtualHubsResultPreparer() (*http.Request, error) {
12610	if lvhr.NextLink == nil || len(to.String(lvhr.NextLink)) < 1 {
12611		return nil, nil
12612	}
12613	return autorest.Prepare(&http.Request{},
12614		autorest.AsJSON(),
12615		autorest.AsGet(),
12616		autorest.WithBaseURL(to.String(lvhr.NextLink)))
12617}
12618
12619// ListVirtualHubsResultPage contains a page of VirtualHub values.
12620type ListVirtualHubsResultPage struct {
12621	fn   func(ListVirtualHubsResult) (ListVirtualHubsResult, error)
12622	lvhr ListVirtualHubsResult
12623}
12624
12625// Next advances to the next page of values.  If there was an error making
12626// the request the page does not advance and the error is returned.
12627func (page *ListVirtualHubsResultPage) Next() error {
12628	next, err := page.fn(page.lvhr)
12629	if err != nil {
12630		return err
12631	}
12632	page.lvhr = next
12633	return nil
12634}
12635
12636// NotDone returns true if the page enumeration should be started or is not yet complete.
12637func (page ListVirtualHubsResultPage) NotDone() bool {
12638	return !page.lvhr.IsEmpty()
12639}
12640
12641// Response returns the raw server response from the last page request.
12642func (page ListVirtualHubsResultPage) Response() ListVirtualHubsResult {
12643	return page.lvhr
12644}
12645
12646// Values returns the slice of values for the current page or nil if there are no values.
12647func (page ListVirtualHubsResultPage) Values() []VirtualHub {
12648	if page.lvhr.IsEmpty() {
12649		return nil
12650	}
12651	return *page.lvhr.Value
12652}
12653
12654// ListVirtualWANsResult result of the request to list VirtualWANs. It contains a list of VirtualWANs and a URL
12655// nextLink to get the next set of results.
12656type ListVirtualWANsResult struct {
12657	autorest.Response `json:"-"`
12658	// Value - List of VirtualWANs.
12659	Value *[]VirtualWAN `json:"value,omitempty"`
12660	// NextLink - URL to get the next set of operation list results if there are any.
12661	NextLink *string `json:"nextLink,omitempty"`
12662}
12663
12664// ListVirtualWANsResultIterator provides access to a complete listing of VirtualWAN values.
12665type ListVirtualWANsResultIterator struct {
12666	i    int
12667	page ListVirtualWANsResultPage
12668}
12669
12670// Next advances to the next value.  If there was an error making
12671// the request the iterator does not advance and the error is returned.
12672func (iter *ListVirtualWANsResultIterator) Next() error {
12673	iter.i++
12674	if iter.i < len(iter.page.Values()) {
12675		return nil
12676	}
12677	err := iter.page.Next()
12678	if err != nil {
12679		iter.i--
12680		return err
12681	}
12682	iter.i = 0
12683	return nil
12684}
12685
12686// NotDone returns true if the enumeration should be started or is not yet complete.
12687func (iter ListVirtualWANsResultIterator) NotDone() bool {
12688	return iter.page.NotDone() && iter.i < len(iter.page.Values())
12689}
12690
12691// Response returns the raw server response from the last page request.
12692func (iter ListVirtualWANsResultIterator) Response() ListVirtualWANsResult {
12693	return iter.page.Response()
12694}
12695
12696// Value returns the current value or a zero-initialized value if the
12697// iterator has advanced beyond the end of the collection.
12698func (iter ListVirtualWANsResultIterator) Value() VirtualWAN {
12699	if !iter.page.NotDone() {
12700		return VirtualWAN{}
12701	}
12702	return iter.page.Values()[iter.i]
12703}
12704
12705// IsEmpty returns true if the ListResult contains no values.
12706func (lvwnr ListVirtualWANsResult) IsEmpty() bool {
12707	return lvwnr.Value == nil || len(*lvwnr.Value) == 0
12708}
12709
12710// listVirtualWANsResultPreparer prepares a request to retrieve the next set of results.
12711// It returns nil if no more results exist.
12712func (lvwnr ListVirtualWANsResult) listVirtualWANsResultPreparer() (*http.Request, error) {
12713	if lvwnr.NextLink == nil || len(to.String(lvwnr.NextLink)) < 1 {
12714		return nil, nil
12715	}
12716	return autorest.Prepare(&http.Request{},
12717		autorest.AsJSON(),
12718		autorest.AsGet(),
12719		autorest.WithBaseURL(to.String(lvwnr.NextLink)))
12720}
12721
12722// ListVirtualWANsResultPage contains a page of VirtualWAN values.
12723type ListVirtualWANsResultPage struct {
12724	fn    func(ListVirtualWANsResult) (ListVirtualWANsResult, error)
12725	lvwnr ListVirtualWANsResult
12726}
12727
12728// Next advances to the next page of values.  If there was an error making
12729// the request the page does not advance and the error is returned.
12730func (page *ListVirtualWANsResultPage) Next() error {
12731	next, err := page.fn(page.lvwnr)
12732	if err != nil {
12733		return err
12734	}
12735	page.lvwnr = next
12736	return nil
12737}
12738
12739// NotDone returns true if the page enumeration should be started or is not yet complete.
12740func (page ListVirtualWANsResultPage) NotDone() bool {
12741	return !page.lvwnr.IsEmpty()
12742}
12743
12744// Response returns the raw server response from the last page request.
12745func (page ListVirtualWANsResultPage) Response() ListVirtualWANsResult {
12746	return page.lvwnr
12747}
12748
12749// Values returns the slice of values for the current page or nil if there are no values.
12750func (page ListVirtualWANsResultPage) Values() []VirtualWAN {
12751	if page.lvwnr.IsEmpty() {
12752		return nil
12753	}
12754	return *page.lvwnr.Value
12755}
12756
12757// ListVpnConnectionsResult result of the request to list all vpn connections to a virtual wan vpn gateway. It
12758// contains a list of Vpn Connections and a URL nextLink to get the next set of results.
12759type ListVpnConnectionsResult struct {
12760	autorest.Response `json:"-"`
12761	// Value - List of Vpn Connections.
12762	Value *[]VpnConnection `json:"value,omitempty"`
12763	// NextLink - URL to get the next set of operation list results if there are any.
12764	NextLink *string `json:"nextLink,omitempty"`
12765}
12766
12767// ListVpnConnectionsResultIterator provides access to a complete listing of VpnConnection values.
12768type ListVpnConnectionsResultIterator struct {
12769	i    int
12770	page ListVpnConnectionsResultPage
12771}
12772
12773// Next advances to the next value.  If there was an error making
12774// the request the iterator does not advance and the error is returned.
12775func (iter *ListVpnConnectionsResultIterator) Next() error {
12776	iter.i++
12777	if iter.i < len(iter.page.Values()) {
12778		return nil
12779	}
12780	err := iter.page.Next()
12781	if err != nil {
12782		iter.i--
12783		return err
12784	}
12785	iter.i = 0
12786	return nil
12787}
12788
12789// NotDone returns true if the enumeration should be started or is not yet complete.
12790func (iter ListVpnConnectionsResultIterator) NotDone() bool {
12791	return iter.page.NotDone() && iter.i < len(iter.page.Values())
12792}
12793
12794// Response returns the raw server response from the last page request.
12795func (iter ListVpnConnectionsResultIterator) Response() ListVpnConnectionsResult {
12796	return iter.page.Response()
12797}
12798
12799// Value returns the current value or a zero-initialized value if the
12800// iterator has advanced beyond the end of the collection.
12801func (iter ListVpnConnectionsResultIterator) Value() VpnConnection {
12802	if !iter.page.NotDone() {
12803		return VpnConnection{}
12804	}
12805	return iter.page.Values()[iter.i]
12806}
12807
12808// IsEmpty returns true if the ListResult contains no values.
12809func (lvcr ListVpnConnectionsResult) IsEmpty() bool {
12810	return lvcr.Value == nil || len(*lvcr.Value) == 0
12811}
12812
12813// listVpnConnectionsResultPreparer prepares a request to retrieve the next set of results.
12814// It returns nil if no more results exist.
12815func (lvcr ListVpnConnectionsResult) listVpnConnectionsResultPreparer() (*http.Request, error) {
12816	if lvcr.NextLink == nil || len(to.String(lvcr.NextLink)) < 1 {
12817		return nil, nil
12818	}
12819	return autorest.Prepare(&http.Request{},
12820		autorest.AsJSON(),
12821		autorest.AsGet(),
12822		autorest.WithBaseURL(to.String(lvcr.NextLink)))
12823}
12824
12825// ListVpnConnectionsResultPage contains a page of VpnConnection values.
12826type ListVpnConnectionsResultPage struct {
12827	fn   func(ListVpnConnectionsResult) (ListVpnConnectionsResult, error)
12828	lvcr ListVpnConnectionsResult
12829}
12830
12831// Next advances to the next page of values.  If there was an error making
12832// the request the page does not advance and the error is returned.
12833func (page *ListVpnConnectionsResultPage) Next() error {
12834	next, err := page.fn(page.lvcr)
12835	if err != nil {
12836		return err
12837	}
12838	page.lvcr = next
12839	return nil
12840}
12841
12842// NotDone returns true if the page enumeration should be started or is not yet complete.
12843func (page ListVpnConnectionsResultPage) NotDone() bool {
12844	return !page.lvcr.IsEmpty()
12845}
12846
12847// Response returns the raw server response from the last page request.
12848func (page ListVpnConnectionsResultPage) Response() ListVpnConnectionsResult {
12849	return page.lvcr
12850}
12851
12852// Values returns the slice of values for the current page or nil if there are no values.
12853func (page ListVpnConnectionsResultPage) Values() []VpnConnection {
12854	if page.lvcr.IsEmpty() {
12855		return nil
12856	}
12857	return *page.lvcr.Value
12858}
12859
12860// ListVpnGatewaysResult result of the request to list VpnGateways. It contains a list of VpnGateways and a URL
12861// nextLink to get the next set of results.
12862type ListVpnGatewaysResult struct {
12863	autorest.Response `json:"-"`
12864	// Value - List of VpnGateways.
12865	Value *[]VpnGateway `json:"value,omitempty"`
12866	// NextLink - URL to get the next set of operation list results if there are any.
12867	NextLink *string `json:"nextLink,omitempty"`
12868}
12869
12870// ListVpnGatewaysResultIterator provides access to a complete listing of VpnGateway values.
12871type ListVpnGatewaysResultIterator struct {
12872	i    int
12873	page ListVpnGatewaysResultPage
12874}
12875
12876// Next advances to the next value.  If there was an error making
12877// the request the iterator does not advance and the error is returned.
12878func (iter *ListVpnGatewaysResultIterator) Next() error {
12879	iter.i++
12880	if iter.i < len(iter.page.Values()) {
12881		return nil
12882	}
12883	err := iter.page.Next()
12884	if err != nil {
12885		iter.i--
12886		return err
12887	}
12888	iter.i = 0
12889	return nil
12890}
12891
12892// NotDone returns true if the enumeration should be started or is not yet complete.
12893func (iter ListVpnGatewaysResultIterator) NotDone() bool {
12894	return iter.page.NotDone() && iter.i < len(iter.page.Values())
12895}
12896
12897// Response returns the raw server response from the last page request.
12898func (iter ListVpnGatewaysResultIterator) Response() ListVpnGatewaysResult {
12899	return iter.page.Response()
12900}
12901
12902// Value returns the current value or a zero-initialized value if the
12903// iterator has advanced beyond the end of the collection.
12904func (iter ListVpnGatewaysResultIterator) Value() VpnGateway {
12905	if !iter.page.NotDone() {
12906		return VpnGateway{}
12907	}
12908	return iter.page.Values()[iter.i]
12909}
12910
12911// IsEmpty returns true if the ListResult contains no values.
12912func (lvgr ListVpnGatewaysResult) IsEmpty() bool {
12913	return lvgr.Value == nil || len(*lvgr.Value) == 0
12914}
12915
12916// listVpnGatewaysResultPreparer prepares a request to retrieve the next set of results.
12917// It returns nil if no more results exist.
12918func (lvgr ListVpnGatewaysResult) listVpnGatewaysResultPreparer() (*http.Request, error) {
12919	if lvgr.NextLink == nil || len(to.String(lvgr.NextLink)) < 1 {
12920		return nil, nil
12921	}
12922	return autorest.Prepare(&http.Request{},
12923		autorest.AsJSON(),
12924		autorest.AsGet(),
12925		autorest.WithBaseURL(to.String(lvgr.NextLink)))
12926}
12927
12928// ListVpnGatewaysResultPage contains a page of VpnGateway values.
12929type ListVpnGatewaysResultPage struct {
12930	fn   func(ListVpnGatewaysResult) (ListVpnGatewaysResult, error)
12931	lvgr ListVpnGatewaysResult
12932}
12933
12934// Next advances to the next page of values.  If there was an error making
12935// the request the page does not advance and the error is returned.
12936func (page *ListVpnGatewaysResultPage) Next() error {
12937	next, err := page.fn(page.lvgr)
12938	if err != nil {
12939		return err
12940	}
12941	page.lvgr = next
12942	return nil
12943}
12944
12945// NotDone returns true if the page enumeration should be started or is not yet complete.
12946func (page ListVpnGatewaysResultPage) NotDone() bool {
12947	return !page.lvgr.IsEmpty()
12948}
12949
12950// Response returns the raw server response from the last page request.
12951func (page ListVpnGatewaysResultPage) Response() ListVpnGatewaysResult {
12952	return page.lvgr
12953}
12954
12955// Values returns the slice of values for the current page or nil if there are no values.
12956func (page ListVpnGatewaysResultPage) Values() []VpnGateway {
12957	if page.lvgr.IsEmpty() {
12958		return nil
12959	}
12960	return *page.lvgr.Value
12961}
12962
12963// ListVpnSitesResult result of the request to list VpnSites. It contains a list of VpnSites and a URL nextLink to
12964// get the next set of results.
12965type ListVpnSitesResult struct {
12966	autorest.Response `json:"-"`
12967	// Value - List of VpnSites.
12968	Value *[]VpnSite `json:"value,omitempty"`
12969	// NextLink - URL to get the next set of operation list results if there are any.
12970	NextLink *string `json:"nextLink,omitempty"`
12971}
12972
12973// ListVpnSitesResultIterator provides access to a complete listing of VpnSite values.
12974type ListVpnSitesResultIterator struct {
12975	i    int
12976	page ListVpnSitesResultPage
12977}
12978
12979// Next advances to the next value.  If there was an error making
12980// the request the iterator does not advance and the error is returned.
12981func (iter *ListVpnSitesResultIterator) Next() error {
12982	iter.i++
12983	if iter.i < len(iter.page.Values()) {
12984		return nil
12985	}
12986	err := iter.page.Next()
12987	if err != nil {
12988		iter.i--
12989		return err
12990	}
12991	iter.i = 0
12992	return nil
12993}
12994
12995// NotDone returns true if the enumeration should be started or is not yet complete.
12996func (iter ListVpnSitesResultIterator) NotDone() bool {
12997	return iter.page.NotDone() && iter.i < len(iter.page.Values())
12998}
12999
13000// Response returns the raw server response from the last page request.
13001func (iter ListVpnSitesResultIterator) Response() ListVpnSitesResult {
13002	return iter.page.Response()
13003}
13004
13005// Value returns the current value or a zero-initialized value if the
13006// iterator has advanced beyond the end of the collection.
13007func (iter ListVpnSitesResultIterator) Value() VpnSite {
13008	if !iter.page.NotDone() {
13009		return VpnSite{}
13010	}
13011	return iter.page.Values()[iter.i]
13012}
13013
13014// IsEmpty returns true if the ListResult contains no values.
13015func (lvsr ListVpnSitesResult) IsEmpty() bool {
13016	return lvsr.Value == nil || len(*lvsr.Value) == 0
13017}
13018
13019// listVpnSitesResultPreparer prepares a request to retrieve the next set of results.
13020// It returns nil if no more results exist.
13021func (lvsr ListVpnSitesResult) listVpnSitesResultPreparer() (*http.Request, error) {
13022	if lvsr.NextLink == nil || len(to.String(lvsr.NextLink)) < 1 {
13023		return nil, nil
13024	}
13025	return autorest.Prepare(&http.Request{},
13026		autorest.AsJSON(),
13027		autorest.AsGet(),
13028		autorest.WithBaseURL(to.String(lvsr.NextLink)))
13029}
13030
13031// ListVpnSitesResultPage contains a page of VpnSite values.
13032type ListVpnSitesResultPage struct {
13033	fn   func(ListVpnSitesResult) (ListVpnSitesResult, error)
13034	lvsr ListVpnSitesResult
13035}
13036
13037// Next advances to the next page of values.  If there was an error making
13038// the request the page does not advance and the error is returned.
13039func (page *ListVpnSitesResultPage) Next() error {
13040	next, err := page.fn(page.lvsr)
13041	if err != nil {
13042		return err
13043	}
13044	page.lvsr = next
13045	return nil
13046}
13047
13048// NotDone returns true if the page enumeration should be started or is not yet complete.
13049func (page ListVpnSitesResultPage) NotDone() bool {
13050	return !page.lvsr.IsEmpty()
13051}
13052
13053// Response returns the raw server response from the last page request.
13054func (page ListVpnSitesResultPage) Response() ListVpnSitesResult {
13055	return page.lvsr
13056}
13057
13058// Values returns the slice of values for the current page or nil if there are no values.
13059func (page ListVpnSitesResultPage) Values() []VpnSite {
13060	if page.lvsr.IsEmpty() {
13061		return nil
13062	}
13063	return *page.lvsr.Value
13064}
13065
13066// LoadBalancer loadBalancer resource
13067type LoadBalancer struct {
13068	autorest.Response `json:"-"`
13069	// Sku - The load balancer SKU.
13070	Sku *LoadBalancerSku `json:"sku,omitempty"`
13071	// LoadBalancerPropertiesFormat - Properties of load balancer.
13072	*LoadBalancerPropertiesFormat `json:"properties,omitempty"`
13073	// Etag - A unique read-only string that changes whenever the resource is updated.
13074	Etag *string `json:"etag,omitempty"`
13075	// ID - Resource ID.
13076	ID *string `json:"id,omitempty"`
13077	// Name - Resource name.
13078	Name *string `json:"name,omitempty"`
13079	// Type - Resource type.
13080	Type *string `json:"type,omitempty"`
13081	// Location - Resource location.
13082	Location *string `json:"location,omitempty"`
13083	// Tags - Resource tags.
13084	Tags map[string]*string `json:"tags"`
13085}
13086
13087// MarshalJSON is the custom marshaler for LoadBalancer.
13088func (lb LoadBalancer) MarshalJSON() ([]byte, error) {
13089	objectMap := make(map[string]interface{})
13090	if lb.Sku != nil {
13091		objectMap["sku"] = lb.Sku
13092	}
13093	if lb.LoadBalancerPropertiesFormat != nil {
13094		objectMap["properties"] = lb.LoadBalancerPropertiesFormat
13095	}
13096	if lb.Etag != nil {
13097		objectMap["etag"] = lb.Etag
13098	}
13099	if lb.ID != nil {
13100		objectMap["id"] = lb.ID
13101	}
13102	if lb.Name != nil {
13103		objectMap["name"] = lb.Name
13104	}
13105	if lb.Type != nil {
13106		objectMap["type"] = lb.Type
13107	}
13108	if lb.Location != nil {
13109		objectMap["location"] = lb.Location
13110	}
13111	if lb.Tags != nil {
13112		objectMap["tags"] = lb.Tags
13113	}
13114	return json.Marshal(objectMap)
13115}
13116
13117// UnmarshalJSON is the custom unmarshaler for LoadBalancer struct.
13118func (lb *LoadBalancer) UnmarshalJSON(body []byte) error {
13119	var m map[string]*json.RawMessage
13120	err := json.Unmarshal(body, &m)
13121	if err != nil {
13122		return err
13123	}
13124	for k, v := range m {
13125		switch k {
13126		case "sku":
13127			if v != nil {
13128				var sku LoadBalancerSku
13129				err = json.Unmarshal(*v, &sku)
13130				if err != nil {
13131					return err
13132				}
13133				lb.Sku = &sku
13134			}
13135		case "properties":
13136			if v != nil {
13137				var loadBalancerPropertiesFormat LoadBalancerPropertiesFormat
13138				err = json.Unmarshal(*v, &loadBalancerPropertiesFormat)
13139				if err != nil {
13140					return err
13141				}
13142				lb.LoadBalancerPropertiesFormat = &loadBalancerPropertiesFormat
13143			}
13144		case "etag":
13145			if v != nil {
13146				var etag string
13147				err = json.Unmarshal(*v, &etag)
13148				if err != nil {
13149					return err
13150				}
13151				lb.Etag = &etag
13152			}
13153		case "id":
13154			if v != nil {
13155				var ID string
13156				err = json.Unmarshal(*v, &ID)
13157				if err != nil {
13158					return err
13159				}
13160				lb.ID = &ID
13161			}
13162		case "name":
13163			if v != nil {
13164				var name string
13165				err = json.Unmarshal(*v, &name)
13166				if err != nil {
13167					return err
13168				}
13169				lb.Name = &name
13170			}
13171		case "type":
13172			if v != nil {
13173				var typeVar string
13174				err = json.Unmarshal(*v, &typeVar)
13175				if err != nil {
13176					return err
13177				}
13178				lb.Type = &typeVar
13179			}
13180		case "location":
13181			if v != nil {
13182				var location string
13183				err = json.Unmarshal(*v, &location)
13184				if err != nil {
13185					return err
13186				}
13187				lb.Location = &location
13188			}
13189		case "tags":
13190			if v != nil {
13191				var tags map[string]*string
13192				err = json.Unmarshal(*v, &tags)
13193				if err != nil {
13194					return err
13195				}
13196				lb.Tags = tags
13197			}
13198		}
13199	}
13200
13201	return nil
13202}
13203
13204// LoadBalancerBackendAddressPoolListResult response for ListBackendAddressPool API service call.
13205type LoadBalancerBackendAddressPoolListResult struct {
13206	autorest.Response `json:"-"`
13207	// Value - A list of backend address pools in a load balancer.
13208	Value *[]BackendAddressPool `json:"value,omitempty"`
13209	// NextLink - The URL to get the next set of results.
13210	NextLink *string `json:"nextLink,omitempty"`
13211}
13212
13213// LoadBalancerBackendAddressPoolListResultIterator provides access to a complete listing of BackendAddressPool
13214// values.
13215type LoadBalancerBackendAddressPoolListResultIterator struct {
13216	i    int
13217	page LoadBalancerBackendAddressPoolListResultPage
13218}
13219
13220// Next advances to the next value.  If there was an error making
13221// the request the iterator does not advance and the error is returned.
13222func (iter *LoadBalancerBackendAddressPoolListResultIterator) Next() error {
13223	iter.i++
13224	if iter.i < len(iter.page.Values()) {
13225		return nil
13226	}
13227	err := iter.page.Next()
13228	if err != nil {
13229		iter.i--
13230		return err
13231	}
13232	iter.i = 0
13233	return nil
13234}
13235
13236// NotDone returns true if the enumeration should be started or is not yet complete.
13237func (iter LoadBalancerBackendAddressPoolListResultIterator) NotDone() bool {
13238	return iter.page.NotDone() && iter.i < len(iter.page.Values())
13239}
13240
13241// Response returns the raw server response from the last page request.
13242func (iter LoadBalancerBackendAddressPoolListResultIterator) Response() LoadBalancerBackendAddressPoolListResult {
13243	return iter.page.Response()
13244}
13245
13246// Value returns the current value or a zero-initialized value if the
13247// iterator has advanced beyond the end of the collection.
13248func (iter LoadBalancerBackendAddressPoolListResultIterator) Value() BackendAddressPool {
13249	if !iter.page.NotDone() {
13250		return BackendAddressPool{}
13251	}
13252	return iter.page.Values()[iter.i]
13253}
13254
13255// IsEmpty returns true if the ListResult contains no values.
13256func (lbbaplr LoadBalancerBackendAddressPoolListResult) IsEmpty() bool {
13257	return lbbaplr.Value == nil || len(*lbbaplr.Value) == 0
13258}
13259
13260// loadBalancerBackendAddressPoolListResultPreparer prepares a request to retrieve the next set of results.
13261// It returns nil if no more results exist.
13262func (lbbaplr LoadBalancerBackendAddressPoolListResult) loadBalancerBackendAddressPoolListResultPreparer() (*http.Request, error) {
13263	if lbbaplr.NextLink == nil || len(to.String(lbbaplr.NextLink)) < 1 {
13264		return nil, nil
13265	}
13266	return autorest.Prepare(&http.Request{},
13267		autorest.AsJSON(),
13268		autorest.AsGet(),
13269		autorest.WithBaseURL(to.String(lbbaplr.NextLink)))
13270}
13271
13272// LoadBalancerBackendAddressPoolListResultPage contains a page of BackendAddressPool values.
13273type LoadBalancerBackendAddressPoolListResultPage struct {
13274	fn      func(LoadBalancerBackendAddressPoolListResult) (LoadBalancerBackendAddressPoolListResult, error)
13275	lbbaplr LoadBalancerBackendAddressPoolListResult
13276}
13277
13278// Next advances to the next page of values.  If there was an error making
13279// the request the page does not advance and the error is returned.
13280func (page *LoadBalancerBackendAddressPoolListResultPage) Next() error {
13281	next, err := page.fn(page.lbbaplr)
13282	if err != nil {
13283		return err
13284	}
13285	page.lbbaplr = next
13286	return nil
13287}
13288
13289// NotDone returns true if the page enumeration should be started or is not yet complete.
13290func (page LoadBalancerBackendAddressPoolListResultPage) NotDone() bool {
13291	return !page.lbbaplr.IsEmpty()
13292}
13293
13294// Response returns the raw server response from the last page request.
13295func (page LoadBalancerBackendAddressPoolListResultPage) Response() LoadBalancerBackendAddressPoolListResult {
13296	return page.lbbaplr
13297}
13298
13299// Values returns the slice of values for the current page or nil if there are no values.
13300func (page LoadBalancerBackendAddressPoolListResultPage) Values() []BackendAddressPool {
13301	if page.lbbaplr.IsEmpty() {
13302		return nil
13303	}
13304	return *page.lbbaplr.Value
13305}
13306
13307// LoadBalancerFrontendIPConfigurationListResult response for ListFrontendIPConfiguration API service call.
13308type LoadBalancerFrontendIPConfigurationListResult struct {
13309	autorest.Response `json:"-"`
13310	// Value - A list of frontend IP configurations in a load balancer.
13311	Value *[]FrontendIPConfiguration `json:"value,omitempty"`
13312	// NextLink - The URL to get the next set of results.
13313	NextLink *string `json:"nextLink,omitempty"`
13314}
13315
13316// LoadBalancerFrontendIPConfigurationListResultIterator provides access to a complete listing of
13317// FrontendIPConfiguration values.
13318type LoadBalancerFrontendIPConfigurationListResultIterator struct {
13319	i    int
13320	page LoadBalancerFrontendIPConfigurationListResultPage
13321}
13322
13323// Next advances to the next value.  If there was an error making
13324// the request the iterator does not advance and the error is returned.
13325func (iter *LoadBalancerFrontendIPConfigurationListResultIterator) Next() error {
13326	iter.i++
13327	if iter.i < len(iter.page.Values()) {
13328		return nil
13329	}
13330	err := iter.page.Next()
13331	if err != nil {
13332		iter.i--
13333		return err
13334	}
13335	iter.i = 0
13336	return nil
13337}
13338
13339// NotDone returns true if the enumeration should be started or is not yet complete.
13340func (iter LoadBalancerFrontendIPConfigurationListResultIterator) NotDone() bool {
13341	return iter.page.NotDone() && iter.i < len(iter.page.Values())
13342}
13343
13344// Response returns the raw server response from the last page request.
13345func (iter LoadBalancerFrontendIPConfigurationListResultIterator) Response() LoadBalancerFrontendIPConfigurationListResult {
13346	return iter.page.Response()
13347}
13348
13349// Value returns the current value or a zero-initialized value if the
13350// iterator has advanced beyond the end of the collection.
13351func (iter LoadBalancerFrontendIPConfigurationListResultIterator) Value() FrontendIPConfiguration {
13352	if !iter.page.NotDone() {
13353		return FrontendIPConfiguration{}
13354	}
13355	return iter.page.Values()[iter.i]
13356}
13357
13358// IsEmpty returns true if the ListResult contains no values.
13359func (lbficlr LoadBalancerFrontendIPConfigurationListResult) IsEmpty() bool {
13360	return lbficlr.Value == nil || len(*lbficlr.Value) == 0
13361}
13362
13363// loadBalancerFrontendIPConfigurationListResultPreparer prepares a request to retrieve the next set of results.
13364// It returns nil if no more results exist.
13365func (lbficlr LoadBalancerFrontendIPConfigurationListResult) loadBalancerFrontendIPConfigurationListResultPreparer() (*http.Request, error) {
13366	if lbficlr.NextLink == nil || len(to.String(lbficlr.NextLink)) < 1 {
13367		return nil, nil
13368	}
13369	return autorest.Prepare(&http.Request{},
13370		autorest.AsJSON(),
13371		autorest.AsGet(),
13372		autorest.WithBaseURL(to.String(lbficlr.NextLink)))
13373}
13374
13375// LoadBalancerFrontendIPConfigurationListResultPage contains a page of FrontendIPConfiguration values.
13376type LoadBalancerFrontendIPConfigurationListResultPage struct {
13377	fn      func(LoadBalancerFrontendIPConfigurationListResult) (LoadBalancerFrontendIPConfigurationListResult, error)
13378	lbficlr LoadBalancerFrontendIPConfigurationListResult
13379}
13380
13381// Next advances to the next page of values.  If there was an error making
13382// the request the page does not advance and the error is returned.
13383func (page *LoadBalancerFrontendIPConfigurationListResultPage) Next() error {
13384	next, err := page.fn(page.lbficlr)
13385	if err != nil {
13386		return err
13387	}
13388	page.lbficlr = next
13389	return nil
13390}
13391
13392// NotDone returns true if the page enumeration should be started or is not yet complete.
13393func (page LoadBalancerFrontendIPConfigurationListResultPage) NotDone() bool {
13394	return !page.lbficlr.IsEmpty()
13395}
13396
13397// Response returns the raw server response from the last page request.
13398func (page LoadBalancerFrontendIPConfigurationListResultPage) Response() LoadBalancerFrontendIPConfigurationListResult {
13399	return page.lbficlr
13400}
13401
13402// Values returns the slice of values for the current page or nil if there are no values.
13403func (page LoadBalancerFrontendIPConfigurationListResultPage) Values() []FrontendIPConfiguration {
13404	if page.lbficlr.IsEmpty() {
13405		return nil
13406	}
13407	return *page.lbficlr.Value
13408}
13409
13410// LoadBalancerListResult response for ListLoadBalancers API service call.
13411type LoadBalancerListResult struct {
13412	autorest.Response `json:"-"`
13413	// Value - A list of load balancers in a resource group.
13414	Value *[]LoadBalancer `json:"value,omitempty"`
13415	// NextLink - The URL to get the next set of results.
13416	NextLink *string `json:"nextLink,omitempty"`
13417}
13418
13419// LoadBalancerListResultIterator provides access to a complete listing of LoadBalancer values.
13420type LoadBalancerListResultIterator struct {
13421	i    int
13422	page LoadBalancerListResultPage
13423}
13424
13425// Next advances to the next value.  If there was an error making
13426// the request the iterator does not advance and the error is returned.
13427func (iter *LoadBalancerListResultIterator) Next() error {
13428	iter.i++
13429	if iter.i < len(iter.page.Values()) {
13430		return nil
13431	}
13432	err := iter.page.Next()
13433	if err != nil {
13434		iter.i--
13435		return err
13436	}
13437	iter.i = 0
13438	return nil
13439}
13440
13441// NotDone returns true if the enumeration should be started or is not yet complete.
13442func (iter LoadBalancerListResultIterator) NotDone() bool {
13443	return iter.page.NotDone() && iter.i < len(iter.page.Values())
13444}
13445
13446// Response returns the raw server response from the last page request.
13447func (iter LoadBalancerListResultIterator) Response() LoadBalancerListResult {
13448	return iter.page.Response()
13449}
13450
13451// Value returns the current value or a zero-initialized value if the
13452// iterator has advanced beyond the end of the collection.
13453func (iter LoadBalancerListResultIterator) Value() LoadBalancer {
13454	if !iter.page.NotDone() {
13455		return LoadBalancer{}
13456	}
13457	return iter.page.Values()[iter.i]
13458}
13459
13460// IsEmpty returns true if the ListResult contains no values.
13461func (lblr LoadBalancerListResult) IsEmpty() bool {
13462	return lblr.Value == nil || len(*lblr.Value) == 0
13463}
13464
13465// loadBalancerListResultPreparer prepares a request to retrieve the next set of results.
13466// It returns nil if no more results exist.
13467func (lblr LoadBalancerListResult) loadBalancerListResultPreparer() (*http.Request, error) {
13468	if lblr.NextLink == nil || len(to.String(lblr.NextLink)) < 1 {
13469		return nil, nil
13470	}
13471	return autorest.Prepare(&http.Request{},
13472		autorest.AsJSON(),
13473		autorest.AsGet(),
13474		autorest.WithBaseURL(to.String(lblr.NextLink)))
13475}
13476
13477// LoadBalancerListResultPage contains a page of LoadBalancer values.
13478type LoadBalancerListResultPage struct {
13479	fn   func(LoadBalancerListResult) (LoadBalancerListResult, error)
13480	lblr LoadBalancerListResult
13481}
13482
13483// Next advances to the next page of values.  If there was an error making
13484// the request the page does not advance and the error is returned.
13485func (page *LoadBalancerListResultPage) Next() error {
13486	next, err := page.fn(page.lblr)
13487	if err != nil {
13488		return err
13489	}
13490	page.lblr = next
13491	return nil
13492}
13493
13494// NotDone returns true if the page enumeration should be started or is not yet complete.
13495func (page LoadBalancerListResultPage) NotDone() bool {
13496	return !page.lblr.IsEmpty()
13497}
13498
13499// Response returns the raw server response from the last page request.
13500func (page LoadBalancerListResultPage) Response() LoadBalancerListResult {
13501	return page.lblr
13502}
13503
13504// Values returns the slice of values for the current page or nil if there are no values.
13505func (page LoadBalancerListResultPage) Values() []LoadBalancer {
13506	if page.lblr.IsEmpty() {
13507		return nil
13508	}
13509	return *page.lblr.Value
13510}
13511
13512// LoadBalancerLoadBalancingRuleListResult response for ListLoadBalancingRule API service call.
13513type LoadBalancerLoadBalancingRuleListResult struct {
13514	autorest.Response `json:"-"`
13515	// Value - A list of load balancing rules in a load balancer.
13516	Value *[]LoadBalancingRule `json:"value,omitempty"`
13517	// NextLink - The URL to get the next set of results.
13518	NextLink *string `json:"nextLink,omitempty"`
13519}
13520
13521// LoadBalancerLoadBalancingRuleListResultIterator provides access to a complete listing of LoadBalancingRule
13522// values.
13523type LoadBalancerLoadBalancingRuleListResultIterator struct {
13524	i    int
13525	page LoadBalancerLoadBalancingRuleListResultPage
13526}
13527
13528// Next advances to the next value.  If there was an error making
13529// the request the iterator does not advance and the error is returned.
13530func (iter *LoadBalancerLoadBalancingRuleListResultIterator) Next() error {
13531	iter.i++
13532	if iter.i < len(iter.page.Values()) {
13533		return nil
13534	}
13535	err := iter.page.Next()
13536	if err != nil {
13537		iter.i--
13538		return err
13539	}
13540	iter.i = 0
13541	return nil
13542}
13543
13544// NotDone returns true if the enumeration should be started or is not yet complete.
13545func (iter LoadBalancerLoadBalancingRuleListResultIterator) NotDone() bool {
13546	return iter.page.NotDone() && iter.i < len(iter.page.Values())
13547}
13548
13549// Response returns the raw server response from the last page request.
13550func (iter LoadBalancerLoadBalancingRuleListResultIterator) Response() LoadBalancerLoadBalancingRuleListResult {
13551	return iter.page.Response()
13552}
13553
13554// Value returns the current value or a zero-initialized value if the
13555// iterator has advanced beyond the end of the collection.
13556func (iter LoadBalancerLoadBalancingRuleListResultIterator) Value() LoadBalancingRule {
13557	if !iter.page.NotDone() {
13558		return LoadBalancingRule{}
13559	}
13560	return iter.page.Values()[iter.i]
13561}
13562
13563// IsEmpty returns true if the ListResult contains no values.
13564func (lblbrlr LoadBalancerLoadBalancingRuleListResult) IsEmpty() bool {
13565	return lblbrlr.Value == nil || len(*lblbrlr.Value) == 0
13566}
13567
13568// loadBalancerLoadBalancingRuleListResultPreparer prepares a request to retrieve the next set of results.
13569// It returns nil if no more results exist.
13570func (lblbrlr LoadBalancerLoadBalancingRuleListResult) loadBalancerLoadBalancingRuleListResultPreparer() (*http.Request, error) {
13571	if lblbrlr.NextLink == nil || len(to.String(lblbrlr.NextLink)) < 1 {
13572		return nil, nil
13573	}
13574	return autorest.Prepare(&http.Request{},
13575		autorest.AsJSON(),
13576		autorest.AsGet(),
13577		autorest.WithBaseURL(to.String(lblbrlr.NextLink)))
13578}
13579
13580// LoadBalancerLoadBalancingRuleListResultPage contains a page of LoadBalancingRule values.
13581type LoadBalancerLoadBalancingRuleListResultPage struct {
13582	fn      func(LoadBalancerLoadBalancingRuleListResult) (LoadBalancerLoadBalancingRuleListResult, error)
13583	lblbrlr LoadBalancerLoadBalancingRuleListResult
13584}
13585
13586// Next advances to the next page of values.  If there was an error making
13587// the request the page does not advance and the error is returned.
13588func (page *LoadBalancerLoadBalancingRuleListResultPage) Next() error {
13589	next, err := page.fn(page.lblbrlr)
13590	if err != nil {
13591		return err
13592	}
13593	page.lblbrlr = next
13594	return nil
13595}
13596
13597// NotDone returns true if the page enumeration should be started or is not yet complete.
13598func (page LoadBalancerLoadBalancingRuleListResultPage) NotDone() bool {
13599	return !page.lblbrlr.IsEmpty()
13600}
13601
13602// Response returns the raw server response from the last page request.
13603func (page LoadBalancerLoadBalancingRuleListResultPage) Response() LoadBalancerLoadBalancingRuleListResult {
13604	return page.lblbrlr
13605}
13606
13607// Values returns the slice of values for the current page or nil if there are no values.
13608func (page LoadBalancerLoadBalancingRuleListResultPage) Values() []LoadBalancingRule {
13609	if page.lblbrlr.IsEmpty() {
13610		return nil
13611	}
13612	return *page.lblbrlr.Value
13613}
13614
13615// LoadBalancerProbeListResult response for ListProbe API service call.
13616type LoadBalancerProbeListResult struct {
13617	autorest.Response `json:"-"`
13618	// Value - A list of probes in a load balancer.
13619	Value *[]Probe `json:"value,omitempty"`
13620	// NextLink - The URL to get the next set of results.
13621	NextLink *string `json:"nextLink,omitempty"`
13622}
13623
13624// LoadBalancerProbeListResultIterator provides access to a complete listing of Probe values.
13625type LoadBalancerProbeListResultIterator struct {
13626	i    int
13627	page LoadBalancerProbeListResultPage
13628}
13629
13630// Next advances to the next value.  If there was an error making
13631// the request the iterator does not advance and the error is returned.
13632func (iter *LoadBalancerProbeListResultIterator) Next() error {
13633	iter.i++
13634	if iter.i < len(iter.page.Values()) {
13635		return nil
13636	}
13637	err := iter.page.Next()
13638	if err != nil {
13639		iter.i--
13640		return err
13641	}
13642	iter.i = 0
13643	return nil
13644}
13645
13646// NotDone returns true if the enumeration should be started or is not yet complete.
13647func (iter LoadBalancerProbeListResultIterator) NotDone() bool {
13648	return iter.page.NotDone() && iter.i < len(iter.page.Values())
13649}
13650
13651// Response returns the raw server response from the last page request.
13652func (iter LoadBalancerProbeListResultIterator) Response() LoadBalancerProbeListResult {
13653	return iter.page.Response()
13654}
13655
13656// Value returns the current value or a zero-initialized value if the
13657// iterator has advanced beyond the end of the collection.
13658func (iter LoadBalancerProbeListResultIterator) Value() Probe {
13659	if !iter.page.NotDone() {
13660		return Probe{}
13661	}
13662	return iter.page.Values()[iter.i]
13663}
13664
13665// IsEmpty returns true if the ListResult contains no values.
13666func (lbplr LoadBalancerProbeListResult) IsEmpty() bool {
13667	return lbplr.Value == nil || len(*lbplr.Value) == 0
13668}
13669
13670// loadBalancerProbeListResultPreparer prepares a request to retrieve the next set of results.
13671// It returns nil if no more results exist.
13672func (lbplr LoadBalancerProbeListResult) loadBalancerProbeListResultPreparer() (*http.Request, error) {
13673	if lbplr.NextLink == nil || len(to.String(lbplr.NextLink)) < 1 {
13674		return nil, nil
13675	}
13676	return autorest.Prepare(&http.Request{},
13677		autorest.AsJSON(),
13678		autorest.AsGet(),
13679		autorest.WithBaseURL(to.String(lbplr.NextLink)))
13680}
13681
13682// LoadBalancerProbeListResultPage contains a page of Probe values.
13683type LoadBalancerProbeListResultPage struct {
13684	fn    func(LoadBalancerProbeListResult) (LoadBalancerProbeListResult, error)
13685	lbplr LoadBalancerProbeListResult
13686}
13687
13688// Next advances to the next page of values.  If there was an error making
13689// the request the page does not advance and the error is returned.
13690func (page *LoadBalancerProbeListResultPage) Next() error {
13691	next, err := page.fn(page.lbplr)
13692	if err != nil {
13693		return err
13694	}
13695	page.lbplr = next
13696	return nil
13697}
13698
13699// NotDone returns true if the page enumeration should be started or is not yet complete.
13700func (page LoadBalancerProbeListResultPage) NotDone() bool {
13701	return !page.lbplr.IsEmpty()
13702}
13703
13704// Response returns the raw server response from the last page request.
13705func (page LoadBalancerProbeListResultPage) Response() LoadBalancerProbeListResult {
13706	return page.lbplr
13707}
13708
13709// Values returns the slice of values for the current page or nil if there are no values.
13710func (page LoadBalancerProbeListResultPage) Values() []Probe {
13711	if page.lbplr.IsEmpty() {
13712		return nil
13713	}
13714	return *page.lbplr.Value
13715}
13716
13717// LoadBalancerPropertiesFormat properties of the load balancer.
13718type LoadBalancerPropertiesFormat struct {
13719	// FrontendIPConfigurations - Object representing the frontend IPs to be used for the load balancer
13720	FrontendIPConfigurations *[]FrontendIPConfiguration `json:"frontendIPConfigurations,omitempty"`
13721	// BackendAddressPools - Collection of backend address pools used by a load balancer
13722	BackendAddressPools *[]BackendAddressPool `json:"backendAddressPools,omitempty"`
13723	// LoadBalancingRules - Object collection representing the load balancing rules Gets the provisioning
13724	LoadBalancingRules *[]LoadBalancingRule `json:"loadBalancingRules,omitempty"`
13725	// Probes - Collection of probe objects used in the load balancer
13726	Probes *[]Probe `json:"probes,omitempty"`
13727	// 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.
13728	InboundNatRules *[]InboundNatRule `json:"inboundNatRules,omitempty"`
13729	// 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.
13730	InboundNatPools *[]InboundNatPool `json:"inboundNatPools,omitempty"`
13731	// OutboundRules - The outbound rules.
13732	OutboundRules *[]OutboundRule `json:"outboundRules,omitempty"`
13733	// ResourceGUID - The resource GUID property of the load balancer resource.
13734	ResourceGUID *string `json:"resourceGuid,omitempty"`
13735	// ProvisioningState - Gets the provisioning state of the PublicIP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
13736	ProvisioningState *string `json:"provisioningState,omitempty"`
13737}
13738
13739// LoadBalancersCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
13740// operation.
13741type LoadBalancersCreateOrUpdateFuture struct {
13742	azure.Future
13743}
13744
13745// Result returns the result of the asynchronous operation.
13746// If the operation has not completed it will return an error.
13747func (future *LoadBalancersCreateOrUpdateFuture) Result(client LoadBalancersClient) (lb LoadBalancer, err error) {
13748	var done bool
13749	done, err = future.Done(client)
13750	if err != nil {
13751		err = autorest.NewErrorWithError(err, "network.LoadBalancersCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
13752		return
13753	}
13754	if !done {
13755		err = azure.NewAsyncOpIncompleteError("network.LoadBalancersCreateOrUpdateFuture")
13756		return
13757	}
13758	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
13759	if lb.Response.Response, err = future.GetResult(sender); err == nil && lb.Response.Response.StatusCode != http.StatusNoContent {
13760		lb, err = client.CreateOrUpdateResponder(lb.Response.Response)
13761		if err != nil {
13762			err = autorest.NewErrorWithError(err, "network.LoadBalancersCreateOrUpdateFuture", "Result", lb.Response.Response, "Failure responding to request")
13763		}
13764	}
13765	return
13766}
13767
13768// LoadBalancersDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
13769type LoadBalancersDeleteFuture struct {
13770	azure.Future
13771}
13772
13773// Result returns the result of the asynchronous operation.
13774// If the operation has not completed it will return an error.
13775func (future *LoadBalancersDeleteFuture) Result(client LoadBalancersClient) (ar autorest.Response, err error) {
13776	var done bool
13777	done, err = future.Done(client)
13778	if err != nil {
13779		err = autorest.NewErrorWithError(err, "network.LoadBalancersDeleteFuture", "Result", future.Response(), "Polling failure")
13780		return
13781	}
13782	if !done {
13783		err = azure.NewAsyncOpIncompleteError("network.LoadBalancersDeleteFuture")
13784		return
13785	}
13786	ar.Response = future.Response()
13787	return
13788}
13789
13790// LoadBalancerSku SKU of a load balancer
13791type LoadBalancerSku struct {
13792	// Name - Name of a load balancer SKU. Possible values include: 'LoadBalancerSkuNameBasic', 'LoadBalancerSkuNameStandard'
13793	Name LoadBalancerSkuName `json:"name,omitempty"`
13794}
13795
13796// LoadBalancersUpdateTagsFuture an abstraction for monitoring and retrieving the results of a long-running
13797// operation.
13798type LoadBalancersUpdateTagsFuture struct {
13799	azure.Future
13800}
13801
13802// Result returns the result of the asynchronous operation.
13803// If the operation has not completed it will return an error.
13804func (future *LoadBalancersUpdateTagsFuture) Result(client LoadBalancersClient) (lb LoadBalancer, err error) {
13805	var done bool
13806	done, err = future.Done(client)
13807	if err != nil {
13808		err = autorest.NewErrorWithError(err, "network.LoadBalancersUpdateTagsFuture", "Result", future.Response(), "Polling failure")
13809		return
13810	}
13811	if !done {
13812		err = azure.NewAsyncOpIncompleteError("network.LoadBalancersUpdateTagsFuture")
13813		return
13814	}
13815	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
13816	if lb.Response.Response, err = future.GetResult(sender); err == nil && lb.Response.Response.StatusCode != http.StatusNoContent {
13817		lb, err = client.UpdateTagsResponder(lb.Response.Response)
13818		if err != nil {
13819			err = autorest.NewErrorWithError(err, "network.LoadBalancersUpdateTagsFuture", "Result", lb.Response.Response, "Failure responding to request")
13820		}
13821	}
13822	return
13823}
13824
13825// LoadBalancingRule a load balancing rule for a load balancer.
13826type LoadBalancingRule struct {
13827	autorest.Response `json:"-"`
13828	// LoadBalancingRulePropertiesFormat - Properties of load balancer load balancing rule.
13829	*LoadBalancingRulePropertiesFormat `json:"properties,omitempty"`
13830	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
13831	Name *string `json:"name,omitempty"`
13832	// Etag - A unique read-only string that changes whenever the resource is updated.
13833	Etag *string `json:"etag,omitempty"`
13834	// ID - Resource ID.
13835	ID *string `json:"id,omitempty"`
13836}
13837
13838// MarshalJSON is the custom marshaler for LoadBalancingRule.
13839func (lbr LoadBalancingRule) MarshalJSON() ([]byte, error) {
13840	objectMap := make(map[string]interface{})
13841	if lbr.LoadBalancingRulePropertiesFormat != nil {
13842		objectMap["properties"] = lbr.LoadBalancingRulePropertiesFormat
13843	}
13844	if lbr.Name != nil {
13845		objectMap["name"] = lbr.Name
13846	}
13847	if lbr.Etag != nil {
13848		objectMap["etag"] = lbr.Etag
13849	}
13850	if lbr.ID != nil {
13851		objectMap["id"] = lbr.ID
13852	}
13853	return json.Marshal(objectMap)
13854}
13855
13856// UnmarshalJSON is the custom unmarshaler for LoadBalancingRule struct.
13857func (lbr *LoadBalancingRule) UnmarshalJSON(body []byte) error {
13858	var m map[string]*json.RawMessage
13859	err := json.Unmarshal(body, &m)
13860	if err != nil {
13861		return err
13862	}
13863	for k, v := range m {
13864		switch k {
13865		case "properties":
13866			if v != nil {
13867				var loadBalancingRulePropertiesFormat LoadBalancingRulePropertiesFormat
13868				err = json.Unmarshal(*v, &loadBalancingRulePropertiesFormat)
13869				if err != nil {
13870					return err
13871				}
13872				lbr.LoadBalancingRulePropertiesFormat = &loadBalancingRulePropertiesFormat
13873			}
13874		case "name":
13875			if v != nil {
13876				var name string
13877				err = json.Unmarshal(*v, &name)
13878				if err != nil {
13879					return err
13880				}
13881				lbr.Name = &name
13882			}
13883		case "etag":
13884			if v != nil {
13885				var etag string
13886				err = json.Unmarshal(*v, &etag)
13887				if err != nil {
13888					return err
13889				}
13890				lbr.Etag = &etag
13891			}
13892		case "id":
13893			if v != nil {
13894				var ID string
13895				err = json.Unmarshal(*v, &ID)
13896				if err != nil {
13897					return err
13898				}
13899				lbr.ID = &ID
13900			}
13901		}
13902	}
13903
13904	return nil
13905}
13906
13907// LoadBalancingRulePropertiesFormat properties of the load balancer.
13908type LoadBalancingRulePropertiesFormat struct {
13909	// FrontendIPConfiguration - A reference to frontend IP addresses.
13910	FrontendIPConfiguration *SubResource `json:"frontendIPConfiguration,omitempty"`
13911	// BackendAddressPool - A reference to a pool of DIPs. Inbound traffic is randomly load balanced across IPs in the backend IPs.
13912	BackendAddressPool *SubResource `json:"backendAddressPool,omitempty"`
13913	// Probe - The reference of the load balancer probe used by the load balancing rule.
13914	Probe *SubResource `json:"probe,omitempty"`
13915	// Protocol - Possible values include: 'TransportProtocolUDP', 'TransportProtocolTCP', 'TransportProtocolAll'
13916	Protocol TransportProtocol `json:"protocol,omitempty"`
13917	// LoadDistribution - The load distribution policy for this rule. Possible values are 'Default', 'SourceIP', and 'SourceIPProtocol'. Possible values include: 'Default', 'SourceIP', 'SourceIPProtocol'
13918	LoadDistribution LoadDistribution `json:"loadDistribution,omitempty"`
13919	// FrontendPort - The port for the external endpoint. Port numbers for each rule must be unique within the Load Balancer. Acceptable values are between 0 and 65534. Note that value 0 enables "Any Port"
13920	FrontendPort *int32 `json:"frontendPort,omitempty"`
13921	// BackendPort - The port used for internal connections on the endpoint. Acceptable values are between 0 and 65535. Note that value 0 enables "Any Port"
13922	BackendPort *int32 `json:"backendPort,omitempty"`
13923	// 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.
13924	IdleTimeoutInMinutes *int32 `json:"idleTimeoutInMinutes,omitempty"`
13925	// 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.
13926	EnableFloatingIP *bool `json:"enableFloatingIP,omitempty"`
13927	// EnableTCPReset - Receive bidirectional TCP Reset on TCP flow idle timeout or unexpected connection termination. This element is only used when the protocol is set to TCP.
13928	EnableTCPReset *bool `json:"enableTcpReset,omitempty"`
13929	// DisableOutboundSnat - Configures SNAT for the VMs in the backend pool to use the publicIP address specified in the frontend of the load balancing rule.
13930	DisableOutboundSnat *bool `json:"disableOutboundSnat,omitempty"`
13931	// ProvisioningState - Gets the provisioning state of the PublicIP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
13932	ProvisioningState *string `json:"provisioningState,omitempty"`
13933}
13934
13935// LocalNetworkGateway a common class for general resource information
13936type LocalNetworkGateway struct {
13937	autorest.Response `json:"-"`
13938	// LocalNetworkGatewayPropertiesFormat - Properties of the local network gateway.
13939	*LocalNetworkGatewayPropertiesFormat `json:"properties,omitempty"`
13940	// Etag - A unique read-only string that changes whenever the resource is updated.
13941	Etag *string `json:"etag,omitempty"`
13942	// ID - Resource ID.
13943	ID *string `json:"id,omitempty"`
13944	// Name - Resource name.
13945	Name *string `json:"name,omitempty"`
13946	// Type - Resource type.
13947	Type *string `json:"type,omitempty"`
13948	// Location - Resource location.
13949	Location *string `json:"location,omitempty"`
13950	// Tags - Resource tags.
13951	Tags map[string]*string `json:"tags"`
13952}
13953
13954// MarshalJSON is the custom marshaler for LocalNetworkGateway.
13955func (lng LocalNetworkGateway) MarshalJSON() ([]byte, error) {
13956	objectMap := make(map[string]interface{})
13957	if lng.LocalNetworkGatewayPropertiesFormat != nil {
13958		objectMap["properties"] = lng.LocalNetworkGatewayPropertiesFormat
13959	}
13960	if lng.Etag != nil {
13961		objectMap["etag"] = lng.Etag
13962	}
13963	if lng.ID != nil {
13964		objectMap["id"] = lng.ID
13965	}
13966	if lng.Name != nil {
13967		objectMap["name"] = lng.Name
13968	}
13969	if lng.Type != nil {
13970		objectMap["type"] = lng.Type
13971	}
13972	if lng.Location != nil {
13973		objectMap["location"] = lng.Location
13974	}
13975	if lng.Tags != nil {
13976		objectMap["tags"] = lng.Tags
13977	}
13978	return json.Marshal(objectMap)
13979}
13980
13981// UnmarshalJSON is the custom unmarshaler for LocalNetworkGateway struct.
13982func (lng *LocalNetworkGateway) UnmarshalJSON(body []byte) error {
13983	var m map[string]*json.RawMessage
13984	err := json.Unmarshal(body, &m)
13985	if err != nil {
13986		return err
13987	}
13988	for k, v := range m {
13989		switch k {
13990		case "properties":
13991			if v != nil {
13992				var localNetworkGatewayPropertiesFormat LocalNetworkGatewayPropertiesFormat
13993				err = json.Unmarshal(*v, &localNetworkGatewayPropertiesFormat)
13994				if err != nil {
13995					return err
13996				}
13997				lng.LocalNetworkGatewayPropertiesFormat = &localNetworkGatewayPropertiesFormat
13998			}
13999		case "etag":
14000			if v != nil {
14001				var etag string
14002				err = json.Unmarshal(*v, &etag)
14003				if err != nil {
14004					return err
14005				}
14006				lng.Etag = &etag
14007			}
14008		case "id":
14009			if v != nil {
14010				var ID string
14011				err = json.Unmarshal(*v, &ID)
14012				if err != nil {
14013					return err
14014				}
14015				lng.ID = &ID
14016			}
14017		case "name":
14018			if v != nil {
14019				var name string
14020				err = json.Unmarshal(*v, &name)
14021				if err != nil {
14022					return err
14023				}
14024				lng.Name = &name
14025			}
14026		case "type":
14027			if v != nil {
14028				var typeVar string
14029				err = json.Unmarshal(*v, &typeVar)
14030				if err != nil {
14031					return err
14032				}
14033				lng.Type = &typeVar
14034			}
14035		case "location":
14036			if v != nil {
14037				var location string
14038				err = json.Unmarshal(*v, &location)
14039				if err != nil {
14040					return err
14041				}
14042				lng.Location = &location
14043			}
14044		case "tags":
14045			if v != nil {
14046				var tags map[string]*string
14047				err = json.Unmarshal(*v, &tags)
14048				if err != nil {
14049					return err
14050				}
14051				lng.Tags = tags
14052			}
14053		}
14054	}
14055
14056	return nil
14057}
14058
14059// LocalNetworkGatewayListResult response for ListLocalNetworkGateways API service call.
14060type LocalNetworkGatewayListResult struct {
14061	autorest.Response `json:"-"`
14062	// Value - A list of local network gateways that exists in a resource group.
14063	Value *[]LocalNetworkGateway `json:"value,omitempty"`
14064	// NextLink - The URL to get the next set of results.
14065	NextLink *string `json:"nextLink,omitempty"`
14066}
14067
14068// LocalNetworkGatewayListResultIterator provides access to a complete listing of LocalNetworkGateway values.
14069type LocalNetworkGatewayListResultIterator struct {
14070	i    int
14071	page LocalNetworkGatewayListResultPage
14072}
14073
14074// Next advances to the next value.  If there was an error making
14075// the request the iterator does not advance and the error is returned.
14076func (iter *LocalNetworkGatewayListResultIterator) Next() error {
14077	iter.i++
14078	if iter.i < len(iter.page.Values()) {
14079		return nil
14080	}
14081	err := iter.page.Next()
14082	if err != nil {
14083		iter.i--
14084		return err
14085	}
14086	iter.i = 0
14087	return nil
14088}
14089
14090// NotDone returns true if the enumeration should be started or is not yet complete.
14091func (iter LocalNetworkGatewayListResultIterator) NotDone() bool {
14092	return iter.page.NotDone() && iter.i < len(iter.page.Values())
14093}
14094
14095// Response returns the raw server response from the last page request.
14096func (iter LocalNetworkGatewayListResultIterator) Response() LocalNetworkGatewayListResult {
14097	return iter.page.Response()
14098}
14099
14100// Value returns the current value or a zero-initialized value if the
14101// iterator has advanced beyond the end of the collection.
14102func (iter LocalNetworkGatewayListResultIterator) Value() LocalNetworkGateway {
14103	if !iter.page.NotDone() {
14104		return LocalNetworkGateway{}
14105	}
14106	return iter.page.Values()[iter.i]
14107}
14108
14109// IsEmpty returns true if the ListResult contains no values.
14110func (lnglr LocalNetworkGatewayListResult) IsEmpty() bool {
14111	return lnglr.Value == nil || len(*lnglr.Value) == 0
14112}
14113
14114// localNetworkGatewayListResultPreparer prepares a request to retrieve the next set of results.
14115// It returns nil if no more results exist.
14116func (lnglr LocalNetworkGatewayListResult) localNetworkGatewayListResultPreparer() (*http.Request, error) {
14117	if lnglr.NextLink == nil || len(to.String(lnglr.NextLink)) < 1 {
14118		return nil, nil
14119	}
14120	return autorest.Prepare(&http.Request{},
14121		autorest.AsJSON(),
14122		autorest.AsGet(),
14123		autorest.WithBaseURL(to.String(lnglr.NextLink)))
14124}
14125
14126// LocalNetworkGatewayListResultPage contains a page of LocalNetworkGateway values.
14127type LocalNetworkGatewayListResultPage struct {
14128	fn    func(LocalNetworkGatewayListResult) (LocalNetworkGatewayListResult, error)
14129	lnglr LocalNetworkGatewayListResult
14130}
14131
14132// Next advances to the next page of values.  If there was an error making
14133// the request the page does not advance and the error is returned.
14134func (page *LocalNetworkGatewayListResultPage) Next() error {
14135	next, err := page.fn(page.lnglr)
14136	if err != nil {
14137		return err
14138	}
14139	page.lnglr = next
14140	return nil
14141}
14142
14143// NotDone returns true if the page enumeration should be started or is not yet complete.
14144func (page LocalNetworkGatewayListResultPage) NotDone() bool {
14145	return !page.lnglr.IsEmpty()
14146}
14147
14148// Response returns the raw server response from the last page request.
14149func (page LocalNetworkGatewayListResultPage) Response() LocalNetworkGatewayListResult {
14150	return page.lnglr
14151}
14152
14153// Values returns the slice of values for the current page or nil if there are no values.
14154func (page LocalNetworkGatewayListResultPage) Values() []LocalNetworkGateway {
14155	if page.lnglr.IsEmpty() {
14156		return nil
14157	}
14158	return *page.lnglr.Value
14159}
14160
14161// LocalNetworkGatewayPropertiesFormat localNetworkGateway properties
14162type LocalNetworkGatewayPropertiesFormat struct {
14163	// LocalNetworkAddressSpace - Local network site address space.
14164	LocalNetworkAddressSpace *AddressSpace `json:"localNetworkAddressSpace,omitempty"`
14165	// GatewayIPAddress - IP address of local network gateway.
14166	GatewayIPAddress *string `json:"gatewayIpAddress,omitempty"`
14167	// BgpSettings - Local network gateway's BGP speaker settings.
14168	BgpSettings *BgpSettings `json:"bgpSettings,omitempty"`
14169	// ResourceGUID - The resource GUID property of the LocalNetworkGateway resource.
14170	ResourceGUID *string `json:"resourceGuid,omitempty"`
14171	// ProvisioningState - The provisioning state of the LocalNetworkGateway resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
14172	ProvisioningState *string `json:"provisioningState,omitempty"`
14173}
14174
14175// LocalNetworkGatewaysCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
14176// long-running operation.
14177type LocalNetworkGatewaysCreateOrUpdateFuture struct {
14178	azure.Future
14179}
14180
14181// Result returns the result of the asynchronous operation.
14182// If the operation has not completed it will return an error.
14183func (future *LocalNetworkGatewaysCreateOrUpdateFuture) Result(client LocalNetworkGatewaysClient) (lng LocalNetworkGateway, err error) {
14184	var done bool
14185	done, err = future.Done(client)
14186	if err != nil {
14187		err = autorest.NewErrorWithError(err, "network.LocalNetworkGatewaysCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
14188		return
14189	}
14190	if !done {
14191		err = azure.NewAsyncOpIncompleteError("network.LocalNetworkGatewaysCreateOrUpdateFuture")
14192		return
14193	}
14194	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
14195	if lng.Response.Response, err = future.GetResult(sender); err == nil && lng.Response.Response.StatusCode != http.StatusNoContent {
14196		lng, err = client.CreateOrUpdateResponder(lng.Response.Response)
14197		if err != nil {
14198			err = autorest.NewErrorWithError(err, "network.LocalNetworkGatewaysCreateOrUpdateFuture", "Result", lng.Response.Response, "Failure responding to request")
14199		}
14200	}
14201	return
14202}
14203
14204// LocalNetworkGatewaysDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
14205// operation.
14206type LocalNetworkGatewaysDeleteFuture struct {
14207	azure.Future
14208}
14209
14210// Result returns the result of the asynchronous operation.
14211// If the operation has not completed it will return an error.
14212func (future *LocalNetworkGatewaysDeleteFuture) Result(client LocalNetworkGatewaysClient) (ar autorest.Response, err error) {
14213	var done bool
14214	done, err = future.Done(client)
14215	if err != nil {
14216		err = autorest.NewErrorWithError(err, "network.LocalNetworkGatewaysDeleteFuture", "Result", future.Response(), "Polling failure")
14217		return
14218	}
14219	if !done {
14220		err = azure.NewAsyncOpIncompleteError("network.LocalNetworkGatewaysDeleteFuture")
14221		return
14222	}
14223	ar.Response = future.Response()
14224	return
14225}
14226
14227// LocalNetworkGatewaysUpdateTagsFuture an abstraction for monitoring and retrieving the results of a long-running
14228// operation.
14229type LocalNetworkGatewaysUpdateTagsFuture struct {
14230	azure.Future
14231}
14232
14233// Result returns the result of the asynchronous operation.
14234// If the operation has not completed it will return an error.
14235func (future *LocalNetworkGatewaysUpdateTagsFuture) Result(client LocalNetworkGatewaysClient) (lng LocalNetworkGateway, err error) {
14236	var done bool
14237	done, err = future.Done(client)
14238	if err != nil {
14239		err = autorest.NewErrorWithError(err, "network.LocalNetworkGatewaysUpdateTagsFuture", "Result", future.Response(), "Polling failure")
14240		return
14241	}
14242	if !done {
14243		err = azure.NewAsyncOpIncompleteError("network.LocalNetworkGatewaysUpdateTagsFuture")
14244		return
14245	}
14246	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
14247	if lng.Response.Response, err = future.GetResult(sender); err == nil && lng.Response.Response.StatusCode != http.StatusNoContent {
14248		lng, err = client.UpdateTagsResponder(lng.Response.Response)
14249		if err != nil {
14250			err = autorest.NewErrorWithError(err, "network.LocalNetworkGatewaysUpdateTagsFuture", "Result", lng.Response.Response, "Failure responding to request")
14251		}
14252	}
14253	return
14254}
14255
14256// LogSpecification description of logging specification.
14257type LogSpecification struct {
14258	// Name - The name of the specification.
14259	Name *string `json:"name,omitempty"`
14260	// DisplayName - The display name of the specification.
14261	DisplayName *string `json:"displayName,omitempty"`
14262	// BlobDuration - Duration of the blob.
14263	BlobDuration *string `json:"blobDuration,omitempty"`
14264}
14265
14266// MatchedRule matched rule.
14267type MatchedRule struct {
14268	// RuleName - Name of the matched network security rule.
14269	RuleName *string `json:"ruleName,omitempty"`
14270	// Action - The network traffic is allowed or denied. Possible values are 'Allow' and 'Deny'.
14271	Action *string `json:"action,omitempty"`
14272}
14273
14274// MetricSpecification description of metrics specification.
14275type MetricSpecification struct {
14276	// Name - The name of the metric.
14277	Name *string `json:"name,omitempty"`
14278	// DisplayName - The display name of the metric.
14279	DisplayName *string `json:"displayName,omitempty"`
14280	// DisplayDescription - The description of the metric.
14281	DisplayDescription *string `json:"displayDescription,omitempty"`
14282	// Unit - Units the metric to be displayed in.
14283	Unit *string `json:"unit,omitempty"`
14284	// AggregationType - The aggregation type.
14285	AggregationType *string `json:"aggregationType,omitempty"`
14286	// Availabilities - List of availability.
14287	Availabilities *[]Availability `json:"availabilities,omitempty"`
14288	// EnableRegionalMdmAccount - Whether regional MDM account enabled.
14289	EnableRegionalMdmAccount *bool `json:"enableRegionalMdmAccount,omitempty"`
14290	// FillGapWithZero - Whether gaps would be filled with zeros.
14291	FillGapWithZero *bool `json:"fillGapWithZero,omitempty"`
14292	// MetricFilterPattern - Pattern for the filter of the metric.
14293	MetricFilterPattern *string `json:"metricFilterPattern,omitempty"`
14294	// Dimensions - List of dimensions.
14295	Dimensions *[]Dimension `json:"dimensions,omitempty"`
14296	// IsInternal - Whether the metric is internal.
14297	IsInternal *bool `json:"isInternal,omitempty"`
14298	// SourceMdmAccount - The source MDM account.
14299	SourceMdmAccount *string `json:"sourceMdmAccount,omitempty"`
14300	// SourceMdmNamespace - The source MDM namespace.
14301	SourceMdmNamespace *string `json:"sourceMdmNamespace,omitempty"`
14302	// ResourceIDDimensionNameOverride - The resource Id dimension name override.
14303	ResourceIDDimensionNameOverride *string `json:"resourceIdDimensionNameOverride,omitempty"`
14304}
14305
14306// NextHopParameters parameters that define the source and destination endpoint.
14307type NextHopParameters struct {
14308	// TargetResourceID - The resource identifier of the target resource against which the action is to be performed.
14309	TargetResourceID *string `json:"targetResourceId,omitempty"`
14310	// SourceIPAddress - The source IP address.
14311	SourceIPAddress *string `json:"sourceIPAddress,omitempty"`
14312	// DestinationIPAddress - The destination IP address.
14313	DestinationIPAddress *string `json:"destinationIPAddress,omitempty"`
14314	// 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).
14315	TargetNicResourceID *string `json:"targetNicResourceId,omitempty"`
14316}
14317
14318// NextHopResult the information about next hop from the specified VM.
14319type NextHopResult struct {
14320	autorest.Response `json:"-"`
14321	// NextHopType - Next hop type. Possible values include: 'NextHopTypeInternet', 'NextHopTypeVirtualAppliance', 'NextHopTypeVirtualNetworkGateway', 'NextHopTypeVnetLocal', 'NextHopTypeHyperNetGateway', 'NextHopTypeNone'
14322	NextHopType NextHopType `json:"nextHopType,omitempty"`
14323	// NextHopIPAddress - Next hop IP Address
14324	NextHopIPAddress *string `json:"nextHopIpAddress,omitempty"`
14325	// RouteTableID - The resource identifier for the route table associated with the route being returned. If the route being returned does not correspond to any user created routes then this field will be the string 'System Route'.
14326	RouteTableID *string `json:"routeTableId,omitempty"`
14327}
14328
14329// Operation network REST API operation definition.
14330type Operation struct {
14331	// Name - Operation name: {provider}/{resource}/{operation}
14332	Name *string `json:"name,omitempty"`
14333	// Display - Display metadata associated with the operation.
14334	Display *OperationDisplay `json:"display,omitempty"`
14335	// Origin - Origin of the operation.
14336	Origin *string `json:"origin,omitempty"`
14337	// OperationPropertiesFormat - Operation properties format.
14338	*OperationPropertiesFormat `json:"properties,omitempty"`
14339}
14340
14341// MarshalJSON is the custom marshaler for Operation.
14342func (o Operation) MarshalJSON() ([]byte, error) {
14343	objectMap := make(map[string]interface{})
14344	if o.Name != nil {
14345		objectMap["name"] = o.Name
14346	}
14347	if o.Display != nil {
14348		objectMap["display"] = o.Display
14349	}
14350	if o.Origin != nil {
14351		objectMap["origin"] = o.Origin
14352	}
14353	if o.OperationPropertiesFormat != nil {
14354		objectMap["properties"] = o.OperationPropertiesFormat
14355	}
14356	return json.Marshal(objectMap)
14357}
14358
14359// UnmarshalJSON is the custom unmarshaler for Operation struct.
14360func (o *Operation) UnmarshalJSON(body []byte) error {
14361	var m map[string]*json.RawMessage
14362	err := json.Unmarshal(body, &m)
14363	if err != nil {
14364		return err
14365	}
14366	for k, v := range m {
14367		switch k {
14368		case "name":
14369			if v != nil {
14370				var name string
14371				err = json.Unmarshal(*v, &name)
14372				if err != nil {
14373					return err
14374				}
14375				o.Name = &name
14376			}
14377		case "display":
14378			if v != nil {
14379				var display OperationDisplay
14380				err = json.Unmarshal(*v, &display)
14381				if err != nil {
14382					return err
14383				}
14384				o.Display = &display
14385			}
14386		case "origin":
14387			if v != nil {
14388				var origin string
14389				err = json.Unmarshal(*v, &origin)
14390				if err != nil {
14391					return err
14392				}
14393				o.Origin = &origin
14394			}
14395		case "properties":
14396			if v != nil {
14397				var operationPropertiesFormat OperationPropertiesFormat
14398				err = json.Unmarshal(*v, &operationPropertiesFormat)
14399				if err != nil {
14400					return err
14401				}
14402				o.OperationPropertiesFormat = &operationPropertiesFormat
14403			}
14404		}
14405	}
14406
14407	return nil
14408}
14409
14410// OperationDisplay display metadata associated with the operation.
14411type OperationDisplay struct {
14412	// Provider - Service provider: Microsoft Network.
14413	Provider *string `json:"provider,omitempty"`
14414	// Resource - Resource on which the operation is performed.
14415	Resource *string `json:"resource,omitempty"`
14416	// Operation - Type of the operation: get, read, delete, etc.
14417	Operation *string `json:"operation,omitempty"`
14418	// Description - Description of the operation.
14419	Description *string `json:"description,omitempty"`
14420}
14421
14422// OperationListResult result of the request to list Network operations. It contains a list of operations and a URL
14423// link to get the next set of results.
14424type OperationListResult struct {
14425	autorest.Response `json:"-"`
14426	// Value - List of Network operations supported by the Network resource provider.
14427	Value *[]Operation `json:"value,omitempty"`
14428	// NextLink - URL to get the next set of operation list results if there are any.
14429	NextLink *string `json:"nextLink,omitempty"`
14430}
14431
14432// OperationListResultIterator provides access to a complete listing of Operation values.
14433type OperationListResultIterator struct {
14434	i    int
14435	page OperationListResultPage
14436}
14437
14438// Next advances to the next value.  If there was an error making
14439// the request the iterator does not advance and the error is returned.
14440func (iter *OperationListResultIterator) Next() error {
14441	iter.i++
14442	if iter.i < len(iter.page.Values()) {
14443		return nil
14444	}
14445	err := iter.page.Next()
14446	if err != nil {
14447		iter.i--
14448		return err
14449	}
14450	iter.i = 0
14451	return nil
14452}
14453
14454// NotDone returns true if the enumeration should be started or is not yet complete.
14455func (iter OperationListResultIterator) NotDone() bool {
14456	return iter.page.NotDone() && iter.i < len(iter.page.Values())
14457}
14458
14459// Response returns the raw server response from the last page request.
14460func (iter OperationListResultIterator) Response() OperationListResult {
14461	return iter.page.Response()
14462}
14463
14464// Value returns the current value or a zero-initialized value if the
14465// iterator has advanced beyond the end of the collection.
14466func (iter OperationListResultIterator) Value() Operation {
14467	if !iter.page.NotDone() {
14468		return Operation{}
14469	}
14470	return iter.page.Values()[iter.i]
14471}
14472
14473// IsEmpty returns true if the ListResult contains no values.
14474func (olr OperationListResult) IsEmpty() bool {
14475	return olr.Value == nil || len(*olr.Value) == 0
14476}
14477
14478// operationListResultPreparer prepares a request to retrieve the next set of results.
14479// It returns nil if no more results exist.
14480func (olr OperationListResult) operationListResultPreparer() (*http.Request, error) {
14481	if olr.NextLink == nil || len(to.String(olr.NextLink)) < 1 {
14482		return nil, nil
14483	}
14484	return autorest.Prepare(&http.Request{},
14485		autorest.AsJSON(),
14486		autorest.AsGet(),
14487		autorest.WithBaseURL(to.String(olr.NextLink)))
14488}
14489
14490// OperationListResultPage contains a page of Operation values.
14491type OperationListResultPage struct {
14492	fn  func(OperationListResult) (OperationListResult, error)
14493	olr OperationListResult
14494}
14495
14496// Next advances to the next page of values.  If there was an error making
14497// the request the page does not advance and the error is returned.
14498func (page *OperationListResultPage) Next() error {
14499	next, err := page.fn(page.olr)
14500	if err != nil {
14501		return err
14502	}
14503	page.olr = next
14504	return nil
14505}
14506
14507// NotDone returns true if the page enumeration should be started or is not yet complete.
14508func (page OperationListResultPage) NotDone() bool {
14509	return !page.olr.IsEmpty()
14510}
14511
14512// Response returns the raw server response from the last page request.
14513func (page OperationListResultPage) Response() OperationListResult {
14514	return page.olr
14515}
14516
14517// Values returns the slice of values for the current page or nil if there are no values.
14518func (page OperationListResultPage) Values() []Operation {
14519	if page.olr.IsEmpty() {
14520		return nil
14521	}
14522	return *page.olr.Value
14523}
14524
14525// OperationPropertiesFormat description of operation properties format.
14526type OperationPropertiesFormat struct {
14527	// ServiceSpecification - Specification of the service.
14528	ServiceSpecification *OperationPropertiesFormatServiceSpecification `json:"serviceSpecification,omitempty"`
14529}
14530
14531// OperationPropertiesFormatServiceSpecification specification of the service.
14532type OperationPropertiesFormatServiceSpecification struct {
14533	// MetricSpecifications - Operation service specification.
14534	MetricSpecifications *[]MetricSpecification `json:"metricSpecifications,omitempty"`
14535	// LogSpecifications - Operation log specification.
14536	LogSpecifications *[]LogSpecification `json:"logSpecifications,omitempty"`
14537}
14538
14539// OutboundRule outbound pool of the load balancer.
14540type OutboundRule struct {
14541	// OutboundRulePropertiesFormat - Properties of load balancer outbound rule.
14542	*OutboundRulePropertiesFormat `json:"properties,omitempty"`
14543	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
14544	Name *string `json:"name,omitempty"`
14545	// Etag - A unique read-only string that changes whenever the resource is updated.
14546	Etag *string `json:"etag,omitempty"`
14547	// ID - Resource ID.
14548	ID *string `json:"id,omitempty"`
14549}
14550
14551// MarshalJSON is the custom marshaler for OutboundRule.
14552func (or OutboundRule) MarshalJSON() ([]byte, error) {
14553	objectMap := make(map[string]interface{})
14554	if or.OutboundRulePropertiesFormat != nil {
14555		objectMap["properties"] = or.OutboundRulePropertiesFormat
14556	}
14557	if or.Name != nil {
14558		objectMap["name"] = or.Name
14559	}
14560	if or.Etag != nil {
14561		objectMap["etag"] = or.Etag
14562	}
14563	if or.ID != nil {
14564		objectMap["id"] = or.ID
14565	}
14566	return json.Marshal(objectMap)
14567}
14568
14569// UnmarshalJSON is the custom unmarshaler for OutboundRule struct.
14570func (or *OutboundRule) UnmarshalJSON(body []byte) error {
14571	var m map[string]*json.RawMessage
14572	err := json.Unmarshal(body, &m)
14573	if err != nil {
14574		return err
14575	}
14576	for k, v := range m {
14577		switch k {
14578		case "properties":
14579			if v != nil {
14580				var outboundRulePropertiesFormat OutboundRulePropertiesFormat
14581				err = json.Unmarshal(*v, &outboundRulePropertiesFormat)
14582				if err != nil {
14583					return err
14584				}
14585				or.OutboundRulePropertiesFormat = &outboundRulePropertiesFormat
14586			}
14587		case "name":
14588			if v != nil {
14589				var name string
14590				err = json.Unmarshal(*v, &name)
14591				if err != nil {
14592					return err
14593				}
14594				or.Name = &name
14595			}
14596		case "etag":
14597			if v != nil {
14598				var etag string
14599				err = json.Unmarshal(*v, &etag)
14600				if err != nil {
14601					return err
14602				}
14603				or.Etag = &etag
14604			}
14605		case "id":
14606			if v != nil {
14607				var ID string
14608				err = json.Unmarshal(*v, &ID)
14609				if err != nil {
14610					return err
14611				}
14612				or.ID = &ID
14613			}
14614		}
14615	}
14616
14617	return nil
14618}
14619
14620// OutboundRulePropertiesFormat outbound pool of the load balancer.
14621type OutboundRulePropertiesFormat struct {
14622	// AllocatedOutboundPorts - The number of outbound ports to be used for NAT.
14623	AllocatedOutboundPorts *int32 `json:"allocatedOutboundPorts,omitempty"`
14624	// FrontendIPConfigurations - The Frontend IP addresses of the load balancer.
14625	FrontendIPConfigurations *[]SubResource `json:"frontendIPConfigurations,omitempty"`
14626	// BackendAddressPool - A reference to a pool of DIPs. Outbound traffic is randomly load balanced across IPs in the backend IPs.
14627	BackendAddressPool *SubResource `json:"backendAddressPool,omitempty"`
14628	// ProvisioningState - Gets the provisioning state of the PublicIP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
14629	ProvisioningState *string `json:"provisioningState,omitempty"`
14630	// Protocol - Protocol - TCP, UDP or All. Possible values include: 'Protocol1TCP', 'Protocol1UDP', 'Protocol1All'
14631	Protocol Protocol1 `json:"protocol,omitempty"`
14632	// EnableTCPReset - Receive bidirectional TCP Reset on TCP flow idle timeout or unexpected connection termination. This element is only used when the protocol is set to TCP.
14633	EnableTCPReset *bool `json:"enableTcpReset,omitempty"`
14634	// IdleTimeoutInMinutes - The timeout for the TCP idle connection
14635	IdleTimeoutInMinutes *int32 `json:"idleTimeoutInMinutes,omitempty"`
14636}
14637
14638// P2SVpnGateway p2SVpnGateway Resource.
14639type P2SVpnGateway struct {
14640	autorest.Response        `json:"-"`
14641	*P2SVpnGatewayProperties `json:"properties,omitempty"`
14642	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
14643	Etag *string `json:"etag,omitempty"`
14644	// ID - Resource ID.
14645	ID *string `json:"id,omitempty"`
14646	// Name - Resource name.
14647	Name *string `json:"name,omitempty"`
14648	// Type - Resource type.
14649	Type *string `json:"type,omitempty"`
14650	// Location - Resource location.
14651	Location *string `json:"location,omitempty"`
14652	// Tags - Resource tags.
14653	Tags map[string]*string `json:"tags"`
14654}
14655
14656// MarshalJSON is the custom marshaler for P2SVpnGateway.
14657func (pvg P2SVpnGateway) MarshalJSON() ([]byte, error) {
14658	objectMap := make(map[string]interface{})
14659	if pvg.P2SVpnGatewayProperties != nil {
14660		objectMap["properties"] = pvg.P2SVpnGatewayProperties
14661	}
14662	if pvg.Etag != nil {
14663		objectMap["etag"] = pvg.Etag
14664	}
14665	if pvg.ID != nil {
14666		objectMap["id"] = pvg.ID
14667	}
14668	if pvg.Name != nil {
14669		objectMap["name"] = pvg.Name
14670	}
14671	if pvg.Type != nil {
14672		objectMap["type"] = pvg.Type
14673	}
14674	if pvg.Location != nil {
14675		objectMap["location"] = pvg.Location
14676	}
14677	if pvg.Tags != nil {
14678		objectMap["tags"] = pvg.Tags
14679	}
14680	return json.Marshal(objectMap)
14681}
14682
14683// UnmarshalJSON is the custom unmarshaler for P2SVpnGateway struct.
14684func (pvg *P2SVpnGateway) UnmarshalJSON(body []byte) error {
14685	var m map[string]*json.RawMessage
14686	err := json.Unmarshal(body, &m)
14687	if err != nil {
14688		return err
14689	}
14690	for k, v := range m {
14691		switch k {
14692		case "properties":
14693			if v != nil {
14694				var p2SVpnGatewayProperties P2SVpnGatewayProperties
14695				err = json.Unmarshal(*v, &p2SVpnGatewayProperties)
14696				if err != nil {
14697					return err
14698				}
14699				pvg.P2SVpnGatewayProperties = &p2SVpnGatewayProperties
14700			}
14701		case "etag":
14702			if v != nil {
14703				var etag string
14704				err = json.Unmarshal(*v, &etag)
14705				if err != nil {
14706					return err
14707				}
14708				pvg.Etag = &etag
14709			}
14710		case "id":
14711			if v != nil {
14712				var ID string
14713				err = json.Unmarshal(*v, &ID)
14714				if err != nil {
14715					return err
14716				}
14717				pvg.ID = &ID
14718			}
14719		case "name":
14720			if v != nil {
14721				var name string
14722				err = json.Unmarshal(*v, &name)
14723				if err != nil {
14724					return err
14725				}
14726				pvg.Name = &name
14727			}
14728		case "type":
14729			if v != nil {
14730				var typeVar string
14731				err = json.Unmarshal(*v, &typeVar)
14732				if err != nil {
14733					return err
14734				}
14735				pvg.Type = &typeVar
14736			}
14737		case "location":
14738			if v != nil {
14739				var location string
14740				err = json.Unmarshal(*v, &location)
14741				if err != nil {
14742					return err
14743				}
14744				pvg.Location = &location
14745			}
14746		case "tags":
14747			if v != nil {
14748				var tags map[string]*string
14749				err = json.Unmarshal(*v, &tags)
14750				if err != nil {
14751					return err
14752				}
14753				pvg.Tags = tags
14754			}
14755		}
14756	}
14757
14758	return nil
14759}
14760
14761// P2SVpnGatewayProperties parameters for P2SVpnGateway
14762type P2SVpnGatewayProperties struct {
14763	// VirtualHub - The VirtualHub to which the gateway belongs
14764	VirtualHub *SubResource `json:"virtualHub,omitempty"`
14765	// ProvisioningState - The provisioning state of the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
14766	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
14767	// VpnGatewayScaleUnit - The scale unit for this p2s vpn gateway.
14768	VpnGatewayScaleUnit *int32 `json:"vpnGatewayScaleUnit,omitempty"`
14769	// P2SVpnServerConfiguration - The P2SVpnServerConfiguration to which the p2sVpnGateway is attached to.
14770	P2SVpnServerConfiguration *SubResource `json:"p2SVpnServerConfiguration,omitempty"`
14771	// VpnClientAddressPool - The reference of the address space resource which represents Address space for P2S VpnClient.
14772	VpnClientAddressPool *AddressSpace `json:"vpnClientAddressPool,omitempty"`
14773	// VpnClientConnectionHealth - All P2S vpnclients' connection health status.
14774	VpnClientConnectionHealth *VpnClientConnectionHealth `json:"vpnClientConnectionHealth,omitempty"`
14775}
14776
14777// P2sVpnGatewaysCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
14778// operation.
14779type P2sVpnGatewaysCreateOrUpdateFuture struct {
14780	azure.Future
14781}
14782
14783// Result returns the result of the asynchronous operation.
14784// If the operation has not completed it will return an error.
14785func (future *P2sVpnGatewaysCreateOrUpdateFuture) Result(client P2sVpnGatewaysClient) (pvg P2SVpnGateway, err error) {
14786	var done bool
14787	done, err = future.Done(client)
14788	if err != nil {
14789		err = autorest.NewErrorWithError(err, "network.P2sVpnGatewaysCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
14790		return
14791	}
14792	if !done {
14793		err = azure.NewAsyncOpIncompleteError("network.P2sVpnGatewaysCreateOrUpdateFuture")
14794		return
14795	}
14796	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
14797	if pvg.Response.Response, err = future.GetResult(sender); err == nil && pvg.Response.Response.StatusCode != http.StatusNoContent {
14798		pvg, err = client.CreateOrUpdateResponder(pvg.Response.Response)
14799		if err != nil {
14800			err = autorest.NewErrorWithError(err, "network.P2sVpnGatewaysCreateOrUpdateFuture", "Result", pvg.Response.Response, "Failure responding to request")
14801		}
14802	}
14803	return
14804}
14805
14806// P2sVpnGatewaysDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
14807type P2sVpnGatewaysDeleteFuture struct {
14808	azure.Future
14809}
14810
14811// Result returns the result of the asynchronous operation.
14812// If the operation has not completed it will return an error.
14813func (future *P2sVpnGatewaysDeleteFuture) Result(client P2sVpnGatewaysClient) (ar autorest.Response, err error) {
14814	var done bool
14815	done, err = future.Done(client)
14816	if err != nil {
14817		err = autorest.NewErrorWithError(err, "network.P2sVpnGatewaysDeleteFuture", "Result", future.Response(), "Polling failure")
14818		return
14819	}
14820	if !done {
14821		err = azure.NewAsyncOpIncompleteError("network.P2sVpnGatewaysDeleteFuture")
14822		return
14823	}
14824	ar.Response = future.Response()
14825	return
14826}
14827
14828// P2sVpnGatewaysGenerateVpnProfileFuture an abstraction for monitoring and retrieving the results of a
14829// long-running operation.
14830type P2sVpnGatewaysGenerateVpnProfileFuture struct {
14831	azure.Future
14832}
14833
14834// Result returns the result of the asynchronous operation.
14835// If the operation has not completed it will return an error.
14836func (future *P2sVpnGatewaysGenerateVpnProfileFuture) Result(client P2sVpnGatewaysClient) (vpr VpnProfileResponse, err error) {
14837	var done bool
14838	done, err = future.Done(client)
14839	if err != nil {
14840		err = autorest.NewErrorWithError(err, "network.P2sVpnGatewaysGenerateVpnProfileFuture", "Result", future.Response(), "Polling failure")
14841		return
14842	}
14843	if !done {
14844		err = azure.NewAsyncOpIncompleteError("network.P2sVpnGatewaysGenerateVpnProfileFuture")
14845		return
14846	}
14847	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
14848	if vpr.Response.Response, err = future.GetResult(sender); err == nil && vpr.Response.Response.StatusCode != http.StatusNoContent {
14849		vpr, err = client.GenerateVpnProfileResponder(vpr.Response.Response)
14850		if err != nil {
14851			err = autorest.NewErrorWithError(err, "network.P2sVpnGatewaysGenerateVpnProfileFuture", "Result", vpr.Response.Response, "Failure responding to request")
14852		}
14853	}
14854	return
14855}
14856
14857// P2sVpnGatewaysUpdateTagsFuture an abstraction for monitoring and retrieving the results of a long-running
14858// operation.
14859type P2sVpnGatewaysUpdateTagsFuture struct {
14860	azure.Future
14861}
14862
14863// Result returns the result of the asynchronous operation.
14864// If the operation has not completed it will return an error.
14865func (future *P2sVpnGatewaysUpdateTagsFuture) Result(client P2sVpnGatewaysClient) (pvg P2SVpnGateway, err error) {
14866	var done bool
14867	done, err = future.Done(client)
14868	if err != nil {
14869		err = autorest.NewErrorWithError(err, "network.P2sVpnGatewaysUpdateTagsFuture", "Result", future.Response(), "Polling failure")
14870		return
14871	}
14872	if !done {
14873		err = azure.NewAsyncOpIncompleteError("network.P2sVpnGatewaysUpdateTagsFuture")
14874		return
14875	}
14876	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
14877	if pvg.Response.Response, err = future.GetResult(sender); err == nil && pvg.Response.Response.StatusCode != http.StatusNoContent {
14878		pvg, err = client.UpdateTagsResponder(pvg.Response.Response)
14879		if err != nil {
14880			err = autorest.NewErrorWithError(err, "network.P2sVpnGatewaysUpdateTagsFuture", "Result", pvg.Response.Response, "Failure responding to request")
14881		}
14882	}
14883	return
14884}
14885
14886// P2SVpnProfileParameters vpn Client Parameters for package generation
14887type P2SVpnProfileParameters struct {
14888	// AuthenticationMethod - VPN client Authentication Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values include: 'EAPTLS', 'EAPMSCHAPv2'
14889	AuthenticationMethod AuthenticationMethod `json:"authenticationMethod,omitempty"`
14890}
14891
14892// P2SVpnServerConfigRadiusClientRootCertificate radius client root certificate of P2SVpnServerConfiguration.
14893type P2SVpnServerConfigRadiusClientRootCertificate struct {
14894	// P2SVpnServerConfigRadiusClientRootCertificatePropertiesFormat - Properties of the Radius client root certificate.
14895	*P2SVpnServerConfigRadiusClientRootCertificatePropertiesFormat `json:"properties,omitempty"`
14896	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
14897	Name *string `json:"name,omitempty"`
14898	// Etag - A unique read-only string that changes whenever the resource is updated.
14899	Etag *string `json:"etag,omitempty"`
14900	// ID - Resource ID.
14901	ID *string `json:"id,omitempty"`
14902}
14903
14904// MarshalJSON is the custom marshaler for P2SVpnServerConfigRadiusClientRootCertificate.
14905func (pvscrcrc P2SVpnServerConfigRadiusClientRootCertificate) MarshalJSON() ([]byte, error) {
14906	objectMap := make(map[string]interface{})
14907	if pvscrcrc.P2SVpnServerConfigRadiusClientRootCertificatePropertiesFormat != nil {
14908		objectMap["properties"] = pvscrcrc.P2SVpnServerConfigRadiusClientRootCertificatePropertiesFormat
14909	}
14910	if pvscrcrc.Name != nil {
14911		objectMap["name"] = pvscrcrc.Name
14912	}
14913	if pvscrcrc.Etag != nil {
14914		objectMap["etag"] = pvscrcrc.Etag
14915	}
14916	if pvscrcrc.ID != nil {
14917		objectMap["id"] = pvscrcrc.ID
14918	}
14919	return json.Marshal(objectMap)
14920}
14921
14922// UnmarshalJSON is the custom unmarshaler for P2SVpnServerConfigRadiusClientRootCertificate struct.
14923func (pvscrcrc *P2SVpnServerConfigRadiusClientRootCertificate) UnmarshalJSON(body []byte) error {
14924	var m map[string]*json.RawMessage
14925	err := json.Unmarshal(body, &m)
14926	if err != nil {
14927		return err
14928	}
14929	for k, v := range m {
14930		switch k {
14931		case "properties":
14932			if v != nil {
14933				var p2SVpnServerConfigRadiusClientRootCertificatePropertiesFormat P2SVpnServerConfigRadiusClientRootCertificatePropertiesFormat
14934				err = json.Unmarshal(*v, &p2SVpnServerConfigRadiusClientRootCertificatePropertiesFormat)
14935				if err != nil {
14936					return err
14937				}
14938				pvscrcrc.P2SVpnServerConfigRadiusClientRootCertificatePropertiesFormat = &p2SVpnServerConfigRadiusClientRootCertificatePropertiesFormat
14939			}
14940		case "name":
14941			if v != nil {
14942				var name string
14943				err = json.Unmarshal(*v, &name)
14944				if err != nil {
14945					return err
14946				}
14947				pvscrcrc.Name = &name
14948			}
14949		case "etag":
14950			if v != nil {
14951				var etag string
14952				err = json.Unmarshal(*v, &etag)
14953				if err != nil {
14954					return err
14955				}
14956				pvscrcrc.Etag = &etag
14957			}
14958		case "id":
14959			if v != nil {
14960				var ID string
14961				err = json.Unmarshal(*v, &ID)
14962				if err != nil {
14963					return err
14964				}
14965				pvscrcrc.ID = &ID
14966			}
14967		}
14968	}
14969
14970	return nil
14971}
14972
14973// P2SVpnServerConfigRadiusClientRootCertificatePropertiesFormat properties of the Radius client root certificate
14974// of P2SVpnServerConfiguration.
14975type P2SVpnServerConfigRadiusClientRootCertificatePropertiesFormat struct {
14976	// Thumbprint - The Radius client root certificate thumbprint.
14977	Thumbprint *string `json:"thumbprint,omitempty"`
14978	// ProvisioningState - The provisioning state of the Radius client root certificate resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
14979	ProvisioningState *string `json:"provisioningState,omitempty"`
14980}
14981
14982// P2SVpnServerConfigRadiusServerRootCertificate radius Server root certificate of P2SVpnServerConfiguration.
14983type P2SVpnServerConfigRadiusServerRootCertificate struct {
14984	// P2SVpnServerConfigRadiusServerRootCertificatePropertiesFormat - Properties of the P2SVpnServerConfiguration Radius Server root certificate.
14985	*P2SVpnServerConfigRadiusServerRootCertificatePropertiesFormat `json:"properties,omitempty"`
14986	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
14987	Name *string `json:"name,omitempty"`
14988	// Etag - A unique read-only string that changes whenever the resource is updated.
14989	Etag *string `json:"etag,omitempty"`
14990	// ID - Resource ID.
14991	ID *string `json:"id,omitempty"`
14992}
14993
14994// MarshalJSON is the custom marshaler for P2SVpnServerConfigRadiusServerRootCertificate.
14995func (pvscrsrc P2SVpnServerConfigRadiusServerRootCertificate) MarshalJSON() ([]byte, error) {
14996	objectMap := make(map[string]interface{})
14997	if pvscrsrc.P2SVpnServerConfigRadiusServerRootCertificatePropertiesFormat != nil {
14998		objectMap["properties"] = pvscrsrc.P2SVpnServerConfigRadiusServerRootCertificatePropertiesFormat
14999	}
15000	if pvscrsrc.Name != nil {
15001		objectMap["name"] = pvscrsrc.Name
15002	}
15003	if pvscrsrc.Etag != nil {
15004		objectMap["etag"] = pvscrsrc.Etag
15005	}
15006	if pvscrsrc.ID != nil {
15007		objectMap["id"] = pvscrsrc.ID
15008	}
15009	return json.Marshal(objectMap)
15010}
15011
15012// UnmarshalJSON is the custom unmarshaler for P2SVpnServerConfigRadiusServerRootCertificate struct.
15013func (pvscrsrc *P2SVpnServerConfigRadiusServerRootCertificate) UnmarshalJSON(body []byte) error {
15014	var m map[string]*json.RawMessage
15015	err := json.Unmarshal(body, &m)
15016	if err != nil {
15017		return err
15018	}
15019	for k, v := range m {
15020		switch k {
15021		case "properties":
15022			if v != nil {
15023				var p2SVpnServerConfigRadiusServerRootCertificatePropertiesFormat P2SVpnServerConfigRadiusServerRootCertificatePropertiesFormat
15024				err = json.Unmarshal(*v, &p2SVpnServerConfigRadiusServerRootCertificatePropertiesFormat)
15025				if err != nil {
15026					return err
15027				}
15028				pvscrsrc.P2SVpnServerConfigRadiusServerRootCertificatePropertiesFormat = &p2SVpnServerConfigRadiusServerRootCertificatePropertiesFormat
15029			}
15030		case "name":
15031			if v != nil {
15032				var name string
15033				err = json.Unmarshal(*v, &name)
15034				if err != nil {
15035					return err
15036				}
15037				pvscrsrc.Name = &name
15038			}
15039		case "etag":
15040			if v != nil {
15041				var etag string
15042				err = json.Unmarshal(*v, &etag)
15043				if err != nil {
15044					return err
15045				}
15046				pvscrsrc.Etag = &etag
15047			}
15048		case "id":
15049			if v != nil {
15050				var ID string
15051				err = json.Unmarshal(*v, &ID)
15052				if err != nil {
15053					return err
15054				}
15055				pvscrsrc.ID = &ID
15056			}
15057		}
15058	}
15059
15060	return nil
15061}
15062
15063// P2SVpnServerConfigRadiusServerRootCertificatePropertiesFormat properties of Radius Server root certificate of
15064// P2SVpnServerConfiguration.
15065type P2SVpnServerConfigRadiusServerRootCertificatePropertiesFormat struct {
15066	// PublicCertData - The certificate public data.
15067	PublicCertData *string `json:"publicCertData,omitempty"`
15068	// ProvisioningState - The provisioning state of the P2SVpnServerConfiguration Radius Server root certificate resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
15069	ProvisioningState *string `json:"provisioningState,omitempty"`
15070}
15071
15072// P2SVpnServerConfiguration p2SVpnServerConfiguration Resource.
15073type P2SVpnServerConfiguration struct {
15074	autorest.Response                    `json:"-"`
15075	*P2SVpnServerConfigurationProperties `json:"properties,omitempty"`
15076	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
15077	Name *string `json:"name,omitempty"`
15078	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
15079	Etag *string `json:"etag,omitempty"`
15080	// ID - Resource ID.
15081	ID *string `json:"id,omitempty"`
15082}
15083
15084// MarshalJSON is the custom marshaler for P2SVpnServerConfiguration.
15085func (pvsc P2SVpnServerConfiguration) MarshalJSON() ([]byte, error) {
15086	objectMap := make(map[string]interface{})
15087	if pvsc.P2SVpnServerConfigurationProperties != nil {
15088		objectMap["properties"] = pvsc.P2SVpnServerConfigurationProperties
15089	}
15090	if pvsc.Name != nil {
15091		objectMap["name"] = pvsc.Name
15092	}
15093	if pvsc.Etag != nil {
15094		objectMap["etag"] = pvsc.Etag
15095	}
15096	if pvsc.ID != nil {
15097		objectMap["id"] = pvsc.ID
15098	}
15099	return json.Marshal(objectMap)
15100}
15101
15102// UnmarshalJSON is the custom unmarshaler for P2SVpnServerConfiguration struct.
15103func (pvsc *P2SVpnServerConfiguration) UnmarshalJSON(body []byte) error {
15104	var m map[string]*json.RawMessage
15105	err := json.Unmarshal(body, &m)
15106	if err != nil {
15107		return err
15108	}
15109	for k, v := range m {
15110		switch k {
15111		case "properties":
15112			if v != nil {
15113				var p2SVpnServerConfigurationProperties P2SVpnServerConfigurationProperties
15114				err = json.Unmarshal(*v, &p2SVpnServerConfigurationProperties)
15115				if err != nil {
15116					return err
15117				}
15118				pvsc.P2SVpnServerConfigurationProperties = &p2SVpnServerConfigurationProperties
15119			}
15120		case "name":
15121			if v != nil {
15122				var name string
15123				err = json.Unmarshal(*v, &name)
15124				if err != nil {
15125					return err
15126				}
15127				pvsc.Name = &name
15128			}
15129		case "etag":
15130			if v != nil {
15131				var etag string
15132				err = json.Unmarshal(*v, &etag)
15133				if err != nil {
15134					return err
15135				}
15136				pvsc.Etag = &etag
15137			}
15138		case "id":
15139			if v != nil {
15140				var ID string
15141				err = json.Unmarshal(*v, &ID)
15142				if err != nil {
15143					return err
15144				}
15145				pvsc.ID = &ID
15146			}
15147		}
15148	}
15149
15150	return nil
15151}
15152
15153// P2SVpnServerConfigurationProperties parameters for P2SVpnServerConfiguration
15154type P2SVpnServerConfigurationProperties struct {
15155	// Name - The name of the P2SVpnServerConfiguration that is unique within a VirtualWan in a resource group. This name can be used to access the resource along with Paren VirtualWan resource name.
15156	Name *string `json:"name,omitempty"`
15157	// VpnProtocols - vpnProtocols for the P2SVpnServerConfiguration.
15158	VpnProtocols *[]VpnGatewayTunnelingProtocol `json:"vpnProtocols,omitempty"`
15159	// P2SVpnServerConfigVpnClientRootCertificates - VPN client root certificate of P2SVpnServerConfiguration.
15160	P2SVpnServerConfigVpnClientRootCertificates *[]P2SVpnServerConfigVpnClientRootCertificate `json:"p2SVpnServerConfigVpnClientRootCertificates,omitempty"`
15161	// P2SVpnServerConfigVpnClientRevokedCertificates - VPN client revoked certificate of P2SVpnServerConfiguration.
15162	P2SVpnServerConfigVpnClientRevokedCertificates *[]P2SVpnServerConfigVpnClientRevokedCertificate `json:"p2SVpnServerConfigVpnClientRevokedCertificates,omitempty"`
15163	// P2SVpnServerConfigRadiusServerRootCertificates - Radius Server root certificate of P2SVpnServerConfiguration.
15164	P2SVpnServerConfigRadiusServerRootCertificates *[]P2SVpnServerConfigRadiusServerRootCertificate `json:"p2SVpnServerConfigRadiusServerRootCertificates,omitempty"`
15165	// P2SVpnServerConfigRadiusClientRootCertificates - Radius client root certificate of P2SVpnServerConfiguration.
15166	P2SVpnServerConfigRadiusClientRootCertificates *[]P2SVpnServerConfigRadiusClientRootCertificate `json:"p2SVpnServerConfigRadiusClientRootCertificates,omitempty"`
15167	// VpnClientIpsecPolicies - VpnClientIpsecPolicies for P2SVpnServerConfiguration.
15168	VpnClientIpsecPolicies *[]IpsecPolicy `json:"vpnClientIpsecPolicies,omitempty"`
15169	// RadiusServerAddress - The radius server address property of the P2SVpnServerConfiguration resource for point to site client connection.
15170	RadiusServerAddress *string `json:"radiusServerAddress,omitempty"`
15171	// RadiusServerSecret - The radius secret property of the P2SVpnServerConfiguration resource for for point to site client connection.
15172	RadiusServerSecret *string `json:"radiusServerSecret,omitempty"`
15173	// ProvisioningState - The provisioning state of the P2SVpnServerConfiguration resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
15174	ProvisioningState *string        `json:"provisioningState,omitempty"`
15175	P2SVpnGateways    *[]SubResource `json:"p2SVpnGateways,omitempty"`
15176	// Etag - A unique read-only string that changes whenever the resource is updated.
15177	Etag *string `json:"etag,omitempty"`
15178}
15179
15180// P2sVpnServerConfigurationsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
15181// long-running operation.
15182type P2sVpnServerConfigurationsCreateOrUpdateFuture struct {
15183	azure.Future
15184}
15185
15186// Result returns the result of the asynchronous operation.
15187// If the operation has not completed it will return an error.
15188func (future *P2sVpnServerConfigurationsCreateOrUpdateFuture) Result(client P2sVpnServerConfigurationsClient) (pvsc P2SVpnServerConfiguration, err error) {
15189	var done bool
15190	done, err = future.Done(client)
15191	if err != nil {
15192		err = autorest.NewErrorWithError(err, "network.P2sVpnServerConfigurationsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
15193		return
15194	}
15195	if !done {
15196		err = azure.NewAsyncOpIncompleteError("network.P2sVpnServerConfigurationsCreateOrUpdateFuture")
15197		return
15198	}
15199	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
15200	if pvsc.Response.Response, err = future.GetResult(sender); err == nil && pvsc.Response.Response.StatusCode != http.StatusNoContent {
15201		pvsc, err = client.CreateOrUpdateResponder(pvsc.Response.Response)
15202		if err != nil {
15203			err = autorest.NewErrorWithError(err, "network.P2sVpnServerConfigurationsCreateOrUpdateFuture", "Result", pvsc.Response.Response, "Failure responding to request")
15204		}
15205	}
15206	return
15207}
15208
15209// P2sVpnServerConfigurationsDeleteFuture an abstraction for monitoring and retrieving the results of a
15210// long-running operation.
15211type P2sVpnServerConfigurationsDeleteFuture struct {
15212	azure.Future
15213}
15214
15215// Result returns the result of the asynchronous operation.
15216// If the operation has not completed it will return an error.
15217func (future *P2sVpnServerConfigurationsDeleteFuture) Result(client P2sVpnServerConfigurationsClient) (ar autorest.Response, err error) {
15218	var done bool
15219	done, err = future.Done(client)
15220	if err != nil {
15221		err = autorest.NewErrorWithError(err, "network.P2sVpnServerConfigurationsDeleteFuture", "Result", future.Response(), "Polling failure")
15222		return
15223	}
15224	if !done {
15225		err = azure.NewAsyncOpIncompleteError("network.P2sVpnServerConfigurationsDeleteFuture")
15226		return
15227	}
15228	ar.Response = future.Response()
15229	return
15230}
15231
15232// P2SVpnServerConfigVpnClientRevokedCertificate VPN client revoked certificate of P2SVpnServerConfiguration.
15233type P2SVpnServerConfigVpnClientRevokedCertificate struct {
15234	// P2SVpnServerConfigVpnClientRevokedCertificatePropertiesFormat - Properties of the vpn client revoked certificate.
15235	*P2SVpnServerConfigVpnClientRevokedCertificatePropertiesFormat `json:"properties,omitempty"`
15236	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
15237	Name *string `json:"name,omitempty"`
15238	// Etag - A unique read-only string that changes whenever the resource is updated.
15239	Etag *string `json:"etag,omitempty"`
15240	// ID - Resource ID.
15241	ID *string `json:"id,omitempty"`
15242}
15243
15244// MarshalJSON is the custom marshaler for P2SVpnServerConfigVpnClientRevokedCertificate.
15245func (pvscvcrc P2SVpnServerConfigVpnClientRevokedCertificate) MarshalJSON() ([]byte, error) {
15246	objectMap := make(map[string]interface{})
15247	if pvscvcrc.P2SVpnServerConfigVpnClientRevokedCertificatePropertiesFormat != nil {
15248		objectMap["properties"] = pvscvcrc.P2SVpnServerConfigVpnClientRevokedCertificatePropertiesFormat
15249	}
15250	if pvscvcrc.Name != nil {
15251		objectMap["name"] = pvscvcrc.Name
15252	}
15253	if pvscvcrc.Etag != nil {
15254		objectMap["etag"] = pvscvcrc.Etag
15255	}
15256	if pvscvcrc.ID != nil {
15257		objectMap["id"] = pvscvcrc.ID
15258	}
15259	return json.Marshal(objectMap)
15260}
15261
15262// UnmarshalJSON is the custom unmarshaler for P2SVpnServerConfigVpnClientRevokedCertificate struct.
15263func (pvscvcrc *P2SVpnServerConfigVpnClientRevokedCertificate) UnmarshalJSON(body []byte) error {
15264	var m map[string]*json.RawMessage
15265	err := json.Unmarshal(body, &m)
15266	if err != nil {
15267		return err
15268	}
15269	for k, v := range m {
15270		switch k {
15271		case "properties":
15272			if v != nil {
15273				var p2SVpnServerConfigVpnClientRevokedCertificatePropertiesFormat P2SVpnServerConfigVpnClientRevokedCertificatePropertiesFormat
15274				err = json.Unmarshal(*v, &p2SVpnServerConfigVpnClientRevokedCertificatePropertiesFormat)
15275				if err != nil {
15276					return err
15277				}
15278				pvscvcrc.P2SVpnServerConfigVpnClientRevokedCertificatePropertiesFormat = &p2SVpnServerConfigVpnClientRevokedCertificatePropertiesFormat
15279			}
15280		case "name":
15281			if v != nil {
15282				var name string
15283				err = json.Unmarshal(*v, &name)
15284				if err != nil {
15285					return err
15286				}
15287				pvscvcrc.Name = &name
15288			}
15289		case "etag":
15290			if v != nil {
15291				var etag string
15292				err = json.Unmarshal(*v, &etag)
15293				if err != nil {
15294					return err
15295				}
15296				pvscvcrc.Etag = &etag
15297			}
15298		case "id":
15299			if v != nil {
15300				var ID string
15301				err = json.Unmarshal(*v, &ID)
15302				if err != nil {
15303					return err
15304				}
15305				pvscvcrc.ID = &ID
15306			}
15307		}
15308	}
15309
15310	return nil
15311}
15312
15313// P2SVpnServerConfigVpnClientRevokedCertificatePropertiesFormat properties of the revoked VPN client certificate
15314// of P2SVpnServerConfiguration.
15315type P2SVpnServerConfigVpnClientRevokedCertificatePropertiesFormat struct {
15316	// Thumbprint - The revoked VPN client certificate thumbprint.
15317	Thumbprint *string `json:"thumbprint,omitempty"`
15318	// ProvisioningState - The provisioning state of the VPN client revoked certificate resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
15319	ProvisioningState *string `json:"provisioningState,omitempty"`
15320}
15321
15322// P2SVpnServerConfigVpnClientRootCertificate VPN client root certificate of P2SVpnServerConfiguration.
15323type P2SVpnServerConfigVpnClientRootCertificate struct {
15324	// P2SVpnServerConfigVpnClientRootCertificatePropertiesFormat - Properties of the P2SVpnServerConfiguration VPN client root certificate.
15325	*P2SVpnServerConfigVpnClientRootCertificatePropertiesFormat `json:"properties,omitempty"`
15326	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
15327	Name *string `json:"name,omitempty"`
15328	// Etag - A unique read-only string that changes whenever the resource is updated.
15329	Etag *string `json:"etag,omitempty"`
15330	// ID - Resource ID.
15331	ID *string `json:"id,omitempty"`
15332}
15333
15334// MarshalJSON is the custom marshaler for P2SVpnServerConfigVpnClientRootCertificate.
15335func (pvscvcrc P2SVpnServerConfigVpnClientRootCertificate) MarshalJSON() ([]byte, error) {
15336	objectMap := make(map[string]interface{})
15337	if pvscvcrc.P2SVpnServerConfigVpnClientRootCertificatePropertiesFormat != nil {
15338		objectMap["properties"] = pvscvcrc.P2SVpnServerConfigVpnClientRootCertificatePropertiesFormat
15339	}
15340	if pvscvcrc.Name != nil {
15341		objectMap["name"] = pvscvcrc.Name
15342	}
15343	if pvscvcrc.Etag != nil {
15344		objectMap["etag"] = pvscvcrc.Etag
15345	}
15346	if pvscvcrc.ID != nil {
15347		objectMap["id"] = pvscvcrc.ID
15348	}
15349	return json.Marshal(objectMap)
15350}
15351
15352// UnmarshalJSON is the custom unmarshaler for P2SVpnServerConfigVpnClientRootCertificate struct.
15353func (pvscvcrc *P2SVpnServerConfigVpnClientRootCertificate) UnmarshalJSON(body []byte) error {
15354	var m map[string]*json.RawMessage
15355	err := json.Unmarshal(body, &m)
15356	if err != nil {
15357		return err
15358	}
15359	for k, v := range m {
15360		switch k {
15361		case "properties":
15362			if v != nil {
15363				var p2SVpnServerConfigVpnClientRootCertificatePropertiesFormat P2SVpnServerConfigVpnClientRootCertificatePropertiesFormat
15364				err = json.Unmarshal(*v, &p2SVpnServerConfigVpnClientRootCertificatePropertiesFormat)
15365				if err != nil {
15366					return err
15367				}
15368				pvscvcrc.P2SVpnServerConfigVpnClientRootCertificatePropertiesFormat = &p2SVpnServerConfigVpnClientRootCertificatePropertiesFormat
15369			}
15370		case "name":
15371			if v != nil {
15372				var name string
15373				err = json.Unmarshal(*v, &name)
15374				if err != nil {
15375					return err
15376				}
15377				pvscvcrc.Name = &name
15378			}
15379		case "etag":
15380			if v != nil {
15381				var etag string
15382				err = json.Unmarshal(*v, &etag)
15383				if err != nil {
15384					return err
15385				}
15386				pvscvcrc.Etag = &etag
15387			}
15388		case "id":
15389			if v != nil {
15390				var ID string
15391				err = json.Unmarshal(*v, &ID)
15392				if err != nil {
15393					return err
15394				}
15395				pvscvcrc.ID = &ID
15396			}
15397		}
15398	}
15399
15400	return nil
15401}
15402
15403// P2SVpnServerConfigVpnClientRootCertificatePropertiesFormat properties of VPN client root certificate of
15404// P2SVpnServerConfiguration.
15405type P2SVpnServerConfigVpnClientRootCertificatePropertiesFormat struct {
15406	// PublicCertData - The certificate public data.
15407	PublicCertData *string `json:"publicCertData,omitempty"`
15408	// ProvisioningState - The provisioning state of the P2SVpnServerConfiguration VPN client root certificate resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
15409	ProvisioningState *string `json:"provisioningState,omitempty"`
15410}
15411
15412// PacketCapture parameters that define the create packet capture operation.
15413type PacketCapture struct {
15414	*PacketCaptureParameters `json:"properties,omitempty"`
15415}
15416
15417// MarshalJSON is the custom marshaler for PacketCapture.
15418func (pc PacketCapture) MarshalJSON() ([]byte, error) {
15419	objectMap := make(map[string]interface{})
15420	if pc.PacketCaptureParameters != nil {
15421		objectMap["properties"] = pc.PacketCaptureParameters
15422	}
15423	return json.Marshal(objectMap)
15424}
15425
15426// UnmarshalJSON is the custom unmarshaler for PacketCapture struct.
15427func (pc *PacketCapture) UnmarshalJSON(body []byte) error {
15428	var m map[string]*json.RawMessage
15429	err := json.Unmarshal(body, &m)
15430	if err != nil {
15431		return err
15432	}
15433	for k, v := range m {
15434		switch k {
15435		case "properties":
15436			if v != nil {
15437				var packetCaptureParameters PacketCaptureParameters
15438				err = json.Unmarshal(*v, &packetCaptureParameters)
15439				if err != nil {
15440					return err
15441				}
15442				pc.PacketCaptureParameters = &packetCaptureParameters
15443			}
15444		}
15445	}
15446
15447	return nil
15448}
15449
15450// PacketCaptureFilter filter that is applied to packet capture request. Multiple filters can be applied.
15451type PacketCaptureFilter struct {
15452	// Protocol - Protocol to be filtered on. Possible values include: 'PcProtocolTCP', 'PcProtocolUDP', 'PcProtocolAny'
15453	Protocol PcProtocol `json:"protocol,omitempty"`
15454	// LocalIPAddress - Local IP Address to be filtered on. Notation: "127.0.0.1" for single address entry. "127.0.0.1-127.0.0.255" for range. "127.0.0.1;127.0.0.5"? for multiple entries. Multiple ranges not currently supported. Mixing ranges with multiple entries not currently supported. Default = null.
15455	LocalIPAddress *string `json:"localIPAddress,omitempty"`
15456	// RemoteIPAddress - Local IP Address to be filtered on. Notation: "127.0.0.1" for single address entry. "127.0.0.1-127.0.0.255" for range. "127.0.0.1;127.0.0.5;" for multiple entries. Multiple ranges not currently supported. Mixing ranges with multiple entries not currently supported. Default = null.
15457	RemoteIPAddress *string `json:"remoteIPAddress,omitempty"`
15458	// LocalPort - Local port to be filtered on. Notation: "80" for single port entry."80-85" for range. "80;443;" for multiple entries. Multiple ranges not currently supported. Mixing ranges with multiple entries not currently supported. Default = null.
15459	LocalPort *string `json:"localPort,omitempty"`
15460	// RemotePort - Remote port to be filtered on. Notation: "80" for single port entry."80-85" for range. "80;443;" for multiple entries. Multiple ranges not currently supported. Mixing ranges with multiple entries not currently supported. Default = null.
15461	RemotePort *string `json:"remotePort,omitempty"`
15462}
15463
15464// PacketCaptureListResult list of packet capture sessions.
15465type PacketCaptureListResult struct {
15466	autorest.Response `json:"-"`
15467	// Value - Information about packet capture sessions.
15468	Value *[]PacketCaptureResult `json:"value,omitempty"`
15469}
15470
15471// PacketCaptureParameters parameters that define the create packet capture operation.
15472type PacketCaptureParameters struct {
15473	// Target - The ID of the targeted resource, only VM is currently supported.
15474	Target *string `json:"target,omitempty"`
15475	// BytesToCapturePerPacket - Number of bytes captured per packet, the remaining bytes are truncated.
15476	BytesToCapturePerPacket *int32 `json:"bytesToCapturePerPacket,omitempty"`
15477	// TotalBytesPerSession - Maximum size of the capture output.
15478	TotalBytesPerSession *int32 `json:"totalBytesPerSession,omitempty"`
15479	// TimeLimitInSeconds - Maximum duration of the capture session in seconds.
15480	TimeLimitInSeconds *int32                        `json:"timeLimitInSeconds,omitempty"`
15481	StorageLocation    *PacketCaptureStorageLocation `json:"storageLocation,omitempty"`
15482	Filters            *[]PacketCaptureFilter        `json:"filters,omitempty"`
15483}
15484
15485// PacketCaptureQueryStatusResult status of packet capture session.
15486type PacketCaptureQueryStatusResult struct {
15487	autorest.Response `json:"-"`
15488	// Name - The name of the packet capture resource.
15489	Name *string `json:"name,omitempty"`
15490	// ID - The ID of the packet capture resource.
15491	ID *string `json:"id,omitempty"`
15492	// CaptureStartTime - The start time of the packet capture session.
15493	CaptureStartTime *date.Time `json:"captureStartTime,omitempty"`
15494	// PacketCaptureStatus - The status of the packet capture session. Possible values include: 'PcStatusNotStarted', 'PcStatusRunning', 'PcStatusStopped', 'PcStatusError', 'PcStatusUnknown'
15495	PacketCaptureStatus PcStatus `json:"packetCaptureStatus,omitempty"`
15496	// StopReason - The reason the current packet capture session was stopped.
15497	StopReason *string `json:"stopReason,omitempty"`
15498	// PacketCaptureError - List of errors of packet capture session.
15499	PacketCaptureError *[]PcError `json:"packetCaptureError,omitempty"`
15500}
15501
15502// PacketCaptureResult information about packet capture session.
15503type PacketCaptureResult struct {
15504	autorest.Response `json:"-"`
15505	// Name - Name of the packet capture session.
15506	Name *string `json:"name,omitempty"`
15507	// ID - ID of the packet capture operation.
15508	ID                             *string `json:"id,omitempty"`
15509	Etag                           *string `json:"etag,omitempty"`
15510	*PacketCaptureResultProperties `json:"properties,omitempty"`
15511}
15512
15513// MarshalJSON is the custom marshaler for PacketCaptureResult.
15514func (pcr PacketCaptureResult) MarshalJSON() ([]byte, error) {
15515	objectMap := make(map[string]interface{})
15516	if pcr.Name != nil {
15517		objectMap["name"] = pcr.Name
15518	}
15519	if pcr.ID != nil {
15520		objectMap["id"] = pcr.ID
15521	}
15522	if pcr.Etag != nil {
15523		objectMap["etag"] = pcr.Etag
15524	}
15525	if pcr.PacketCaptureResultProperties != nil {
15526		objectMap["properties"] = pcr.PacketCaptureResultProperties
15527	}
15528	return json.Marshal(objectMap)
15529}
15530
15531// UnmarshalJSON is the custom unmarshaler for PacketCaptureResult struct.
15532func (pcr *PacketCaptureResult) UnmarshalJSON(body []byte) error {
15533	var m map[string]*json.RawMessage
15534	err := json.Unmarshal(body, &m)
15535	if err != nil {
15536		return err
15537	}
15538	for k, v := range m {
15539		switch k {
15540		case "name":
15541			if v != nil {
15542				var name string
15543				err = json.Unmarshal(*v, &name)
15544				if err != nil {
15545					return err
15546				}
15547				pcr.Name = &name
15548			}
15549		case "id":
15550			if v != nil {
15551				var ID string
15552				err = json.Unmarshal(*v, &ID)
15553				if err != nil {
15554					return err
15555				}
15556				pcr.ID = &ID
15557			}
15558		case "etag":
15559			if v != nil {
15560				var etag string
15561				err = json.Unmarshal(*v, &etag)
15562				if err != nil {
15563					return err
15564				}
15565				pcr.Etag = &etag
15566			}
15567		case "properties":
15568			if v != nil {
15569				var packetCaptureResultProperties PacketCaptureResultProperties
15570				err = json.Unmarshal(*v, &packetCaptureResultProperties)
15571				if err != nil {
15572					return err
15573				}
15574				pcr.PacketCaptureResultProperties = &packetCaptureResultProperties
15575			}
15576		}
15577	}
15578
15579	return nil
15580}
15581
15582// PacketCaptureResultProperties describes the properties of a packet capture session.
15583type PacketCaptureResultProperties struct {
15584	// ProvisioningState - The provisioning state of the packet capture session. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
15585	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
15586	// Target - The ID of the targeted resource, only VM is currently supported.
15587	Target *string `json:"target,omitempty"`
15588	// BytesToCapturePerPacket - Number of bytes captured per packet, the remaining bytes are truncated.
15589	BytesToCapturePerPacket *int32 `json:"bytesToCapturePerPacket,omitempty"`
15590	// TotalBytesPerSession - Maximum size of the capture output.
15591	TotalBytesPerSession *int32 `json:"totalBytesPerSession,omitempty"`
15592	// TimeLimitInSeconds - Maximum duration of the capture session in seconds.
15593	TimeLimitInSeconds *int32                        `json:"timeLimitInSeconds,omitempty"`
15594	StorageLocation    *PacketCaptureStorageLocation `json:"storageLocation,omitempty"`
15595	Filters            *[]PacketCaptureFilter        `json:"filters,omitempty"`
15596}
15597
15598// PacketCapturesCreateFuture an abstraction for monitoring and retrieving the results of a long-running operation.
15599type PacketCapturesCreateFuture struct {
15600	azure.Future
15601}
15602
15603// Result returns the result of the asynchronous operation.
15604// If the operation has not completed it will return an error.
15605func (future *PacketCapturesCreateFuture) Result(client PacketCapturesClient) (pcr PacketCaptureResult, err error) {
15606	var done bool
15607	done, err = future.Done(client)
15608	if err != nil {
15609		err = autorest.NewErrorWithError(err, "network.PacketCapturesCreateFuture", "Result", future.Response(), "Polling failure")
15610		return
15611	}
15612	if !done {
15613		err = azure.NewAsyncOpIncompleteError("network.PacketCapturesCreateFuture")
15614		return
15615	}
15616	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
15617	if pcr.Response.Response, err = future.GetResult(sender); err == nil && pcr.Response.Response.StatusCode != http.StatusNoContent {
15618		pcr, err = client.CreateResponder(pcr.Response.Response)
15619		if err != nil {
15620			err = autorest.NewErrorWithError(err, "network.PacketCapturesCreateFuture", "Result", pcr.Response.Response, "Failure responding to request")
15621		}
15622	}
15623	return
15624}
15625
15626// PacketCapturesDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
15627type PacketCapturesDeleteFuture struct {
15628	azure.Future
15629}
15630
15631// Result returns the result of the asynchronous operation.
15632// If the operation has not completed it will return an error.
15633func (future *PacketCapturesDeleteFuture) Result(client PacketCapturesClient) (ar autorest.Response, err error) {
15634	var done bool
15635	done, err = future.Done(client)
15636	if err != nil {
15637		err = autorest.NewErrorWithError(err, "network.PacketCapturesDeleteFuture", "Result", future.Response(), "Polling failure")
15638		return
15639	}
15640	if !done {
15641		err = azure.NewAsyncOpIncompleteError("network.PacketCapturesDeleteFuture")
15642		return
15643	}
15644	ar.Response = future.Response()
15645	return
15646}
15647
15648// PacketCapturesGetStatusFuture an abstraction for monitoring and retrieving the results of a long-running
15649// operation.
15650type PacketCapturesGetStatusFuture struct {
15651	azure.Future
15652}
15653
15654// Result returns the result of the asynchronous operation.
15655// If the operation has not completed it will return an error.
15656func (future *PacketCapturesGetStatusFuture) Result(client PacketCapturesClient) (pcqsr PacketCaptureQueryStatusResult, err error) {
15657	var done bool
15658	done, err = future.Done(client)
15659	if err != nil {
15660		err = autorest.NewErrorWithError(err, "network.PacketCapturesGetStatusFuture", "Result", future.Response(), "Polling failure")
15661		return
15662	}
15663	if !done {
15664		err = azure.NewAsyncOpIncompleteError("network.PacketCapturesGetStatusFuture")
15665		return
15666	}
15667	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
15668	if pcqsr.Response.Response, err = future.GetResult(sender); err == nil && pcqsr.Response.Response.StatusCode != http.StatusNoContent {
15669		pcqsr, err = client.GetStatusResponder(pcqsr.Response.Response)
15670		if err != nil {
15671			err = autorest.NewErrorWithError(err, "network.PacketCapturesGetStatusFuture", "Result", pcqsr.Response.Response, "Failure responding to request")
15672		}
15673	}
15674	return
15675}
15676
15677// PacketCapturesStopFuture an abstraction for monitoring and retrieving the results of a long-running operation.
15678type PacketCapturesStopFuture struct {
15679	azure.Future
15680}
15681
15682// Result returns the result of the asynchronous operation.
15683// If the operation has not completed it will return an error.
15684func (future *PacketCapturesStopFuture) Result(client PacketCapturesClient) (ar autorest.Response, err error) {
15685	var done bool
15686	done, err = future.Done(client)
15687	if err != nil {
15688		err = autorest.NewErrorWithError(err, "network.PacketCapturesStopFuture", "Result", future.Response(), "Polling failure")
15689		return
15690	}
15691	if !done {
15692		err = azure.NewAsyncOpIncompleteError("network.PacketCapturesStopFuture")
15693		return
15694	}
15695	ar.Response = future.Response()
15696	return
15697}
15698
15699// PacketCaptureStorageLocation describes the storage location for a packet capture session.
15700type PacketCaptureStorageLocation struct {
15701	// StorageID - The ID of the storage account to save the packet capture session. Required if no local file path is provided.
15702	StorageID *string `json:"storageId,omitempty"`
15703	// 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.
15704	StoragePath *string `json:"storagePath,omitempty"`
15705	// 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.
15706	FilePath *string `json:"filePath,omitempty"`
15707}
15708
15709// PatchRouteFilter route Filter Resource.
15710type PatchRouteFilter struct {
15711	*RouteFilterPropertiesFormat `json:"properties,omitempty"`
15712	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
15713	Name *string `json:"name,omitempty"`
15714	// Etag - A unique read-only string that changes whenever the resource is updated.
15715	Etag *string `json:"etag,omitempty"`
15716	// Type - Resource type.
15717	Type *string `json:"type,omitempty"`
15718	// Tags - Resource tags.
15719	Tags map[string]*string `json:"tags"`
15720	// ID - Resource ID.
15721	ID *string `json:"id,omitempty"`
15722}
15723
15724// MarshalJSON is the custom marshaler for PatchRouteFilter.
15725func (prf PatchRouteFilter) MarshalJSON() ([]byte, error) {
15726	objectMap := make(map[string]interface{})
15727	if prf.RouteFilterPropertiesFormat != nil {
15728		objectMap["properties"] = prf.RouteFilterPropertiesFormat
15729	}
15730	if prf.Name != nil {
15731		objectMap["name"] = prf.Name
15732	}
15733	if prf.Etag != nil {
15734		objectMap["etag"] = prf.Etag
15735	}
15736	if prf.Type != nil {
15737		objectMap["type"] = prf.Type
15738	}
15739	if prf.Tags != nil {
15740		objectMap["tags"] = prf.Tags
15741	}
15742	if prf.ID != nil {
15743		objectMap["id"] = prf.ID
15744	}
15745	return json.Marshal(objectMap)
15746}
15747
15748// UnmarshalJSON is the custom unmarshaler for PatchRouteFilter struct.
15749func (prf *PatchRouteFilter) UnmarshalJSON(body []byte) error {
15750	var m map[string]*json.RawMessage
15751	err := json.Unmarshal(body, &m)
15752	if err != nil {
15753		return err
15754	}
15755	for k, v := range m {
15756		switch k {
15757		case "properties":
15758			if v != nil {
15759				var routeFilterPropertiesFormat RouteFilterPropertiesFormat
15760				err = json.Unmarshal(*v, &routeFilterPropertiesFormat)
15761				if err != nil {
15762					return err
15763				}
15764				prf.RouteFilterPropertiesFormat = &routeFilterPropertiesFormat
15765			}
15766		case "name":
15767			if v != nil {
15768				var name string
15769				err = json.Unmarshal(*v, &name)
15770				if err != nil {
15771					return err
15772				}
15773				prf.Name = &name
15774			}
15775		case "etag":
15776			if v != nil {
15777				var etag string
15778				err = json.Unmarshal(*v, &etag)
15779				if err != nil {
15780					return err
15781				}
15782				prf.Etag = &etag
15783			}
15784		case "type":
15785			if v != nil {
15786				var typeVar string
15787				err = json.Unmarshal(*v, &typeVar)
15788				if err != nil {
15789					return err
15790				}
15791				prf.Type = &typeVar
15792			}
15793		case "tags":
15794			if v != nil {
15795				var tags map[string]*string
15796				err = json.Unmarshal(*v, &tags)
15797				if err != nil {
15798					return err
15799				}
15800				prf.Tags = tags
15801			}
15802		case "id":
15803			if v != nil {
15804				var ID string
15805				err = json.Unmarshal(*v, &ID)
15806				if err != nil {
15807					return err
15808				}
15809				prf.ID = &ID
15810			}
15811		}
15812	}
15813
15814	return nil
15815}
15816
15817// PatchRouteFilterRule route Filter Rule Resource
15818type PatchRouteFilterRule struct {
15819	*RouteFilterRulePropertiesFormat `json:"properties,omitempty"`
15820	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
15821	Name *string `json:"name,omitempty"`
15822	// Etag - A unique read-only string that changes whenever the resource is updated.
15823	Etag *string `json:"etag,omitempty"`
15824	// ID - Resource ID.
15825	ID *string `json:"id,omitempty"`
15826}
15827
15828// MarshalJSON is the custom marshaler for PatchRouteFilterRule.
15829func (prfr PatchRouteFilterRule) MarshalJSON() ([]byte, error) {
15830	objectMap := make(map[string]interface{})
15831	if prfr.RouteFilterRulePropertiesFormat != nil {
15832		objectMap["properties"] = prfr.RouteFilterRulePropertiesFormat
15833	}
15834	if prfr.Name != nil {
15835		objectMap["name"] = prfr.Name
15836	}
15837	if prfr.Etag != nil {
15838		objectMap["etag"] = prfr.Etag
15839	}
15840	if prfr.ID != nil {
15841		objectMap["id"] = prfr.ID
15842	}
15843	return json.Marshal(objectMap)
15844}
15845
15846// UnmarshalJSON is the custom unmarshaler for PatchRouteFilterRule struct.
15847func (prfr *PatchRouteFilterRule) UnmarshalJSON(body []byte) error {
15848	var m map[string]*json.RawMessage
15849	err := json.Unmarshal(body, &m)
15850	if err != nil {
15851		return err
15852	}
15853	for k, v := range m {
15854		switch k {
15855		case "properties":
15856			if v != nil {
15857				var routeFilterRulePropertiesFormat RouteFilterRulePropertiesFormat
15858				err = json.Unmarshal(*v, &routeFilterRulePropertiesFormat)
15859				if err != nil {
15860					return err
15861				}
15862				prfr.RouteFilterRulePropertiesFormat = &routeFilterRulePropertiesFormat
15863			}
15864		case "name":
15865			if v != nil {
15866				var name string
15867				err = json.Unmarshal(*v, &name)
15868				if err != nil {
15869					return err
15870				}
15871				prfr.Name = &name
15872			}
15873		case "etag":
15874			if v != nil {
15875				var etag string
15876				err = json.Unmarshal(*v, &etag)
15877				if err != nil {
15878					return err
15879				}
15880				prfr.Etag = &etag
15881			}
15882		case "id":
15883			if v != nil {
15884				var ID string
15885				err = json.Unmarshal(*v, &ID)
15886				if err != nil {
15887					return err
15888				}
15889				prfr.ID = &ID
15890			}
15891		}
15892	}
15893
15894	return nil
15895}
15896
15897// Probe a load balancer probe.
15898type Probe struct {
15899	autorest.Response `json:"-"`
15900	// ProbePropertiesFormat - Properties of load balancer probe.
15901	*ProbePropertiesFormat `json:"properties,omitempty"`
15902	// Name - Gets name of the resource that is unique within a resource group. This name can be used to access the resource.
15903	Name *string `json:"name,omitempty"`
15904	// Etag - A unique read-only string that changes whenever the resource is updated.
15905	Etag *string `json:"etag,omitempty"`
15906	// ID - Resource ID.
15907	ID *string `json:"id,omitempty"`
15908}
15909
15910// MarshalJSON is the custom marshaler for Probe.
15911func (p Probe) MarshalJSON() ([]byte, error) {
15912	objectMap := make(map[string]interface{})
15913	if p.ProbePropertiesFormat != nil {
15914		objectMap["properties"] = p.ProbePropertiesFormat
15915	}
15916	if p.Name != nil {
15917		objectMap["name"] = p.Name
15918	}
15919	if p.Etag != nil {
15920		objectMap["etag"] = p.Etag
15921	}
15922	if p.ID != nil {
15923		objectMap["id"] = p.ID
15924	}
15925	return json.Marshal(objectMap)
15926}
15927
15928// UnmarshalJSON is the custom unmarshaler for Probe struct.
15929func (p *Probe) UnmarshalJSON(body []byte) error {
15930	var m map[string]*json.RawMessage
15931	err := json.Unmarshal(body, &m)
15932	if err != nil {
15933		return err
15934	}
15935	for k, v := range m {
15936		switch k {
15937		case "properties":
15938			if v != nil {
15939				var probePropertiesFormat ProbePropertiesFormat
15940				err = json.Unmarshal(*v, &probePropertiesFormat)
15941				if err != nil {
15942					return err
15943				}
15944				p.ProbePropertiesFormat = &probePropertiesFormat
15945			}
15946		case "name":
15947			if v != nil {
15948				var name string
15949				err = json.Unmarshal(*v, &name)
15950				if err != nil {
15951					return err
15952				}
15953				p.Name = &name
15954			}
15955		case "etag":
15956			if v != nil {
15957				var etag string
15958				err = json.Unmarshal(*v, &etag)
15959				if err != nil {
15960					return err
15961				}
15962				p.Etag = &etag
15963			}
15964		case "id":
15965			if v != nil {
15966				var ID string
15967				err = json.Unmarshal(*v, &ID)
15968				if err != nil {
15969					return err
15970				}
15971				p.ID = &ID
15972			}
15973		}
15974	}
15975
15976	return nil
15977}
15978
15979// ProbePropertiesFormat load balancer probe resource.
15980type ProbePropertiesFormat struct {
15981	// LoadBalancingRules - The load balancer rules that use this probe.
15982	LoadBalancingRules *[]SubResource `json:"loadBalancingRules,omitempty"`
15983	// Protocol - The protocol of the end point. Possible values 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: 'ProbeProtocolHTTP', 'ProbeProtocolTCP', 'ProbeProtocolHTTPS'
15984	Protocol ProbeProtocol `json:"protocol,omitempty"`
15985	// Port - The port for communicating the probe. Possible values range from 1 to 65535, inclusive.
15986	Port *int32 `json:"port,omitempty"`
15987	// IntervalInSeconds - The interval, in seconds, for how frequently to probe the endpoint for health status. Typically, the interval is slightly less than half the allocated timeout period (in seconds) which allows two full probes before taking the instance out of rotation. The default value is 15, the minimum value is 5.
15988	IntervalInSeconds *int32 `json:"intervalInSeconds,omitempty"`
15989	// NumberOfProbes - The number of probes where if no response, will result in stopping further traffic from being delivered to the endpoint. This values allows endpoints to be taken out of rotation faster or slower than the typical times used in Azure.
15990	NumberOfProbes *int32 `json:"numberOfProbes,omitempty"`
15991	// RequestPath - The URI used for requesting health status from the VM. Path is required if a protocol is set to http. Otherwise, it is not allowed. There is no default value.
15992	RequestPath *string `json:"requestPath,omitempty"`
15993	// ProvisioningState - Gets the provisioning state of the public IP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
15994	ProvisioningState *string `json:"provisioningState,omitempty"`
15995}
15996
15997// Profile network profile resource.
15998type Profile struct {
15999	autorest.Response `json:"-"`
16000	// ProfilePropertiesFormat - Network profile properties.
16001	*ProfilePropertiesFormat `json:"properties,omitempty"`
16002	// Etag - A unique read-only string that changes whenever the resource is updated.
16003	Etag *string `json:"etag,omitempty"`
16004	// ID - Resource ID.
16005	ID *string `json:"id,omitempty"`
16006	// Name - Resource name.
16007	Name *string `json:"name,omitempty"`
16008	// Type - Resource type.
16009	Type *string `json:"type,omitempty"`
16010	// Location - Resource location.
16011	Location *string `json:"location,omitempty"`
16012	// Tags - Resource tags.
16013	Tags map[string]*string `json:"tags"`
16014}
16015
16016// MarshalJSON is the custom marshaler for Profile.
16017func (p Profile) MarshalJSON() ([]byte, error) {
16018	objectMap := make(map[string]interface{})
16019	if p.ProfilePropertiesFormat != nil {
16020		objectMap["properties"] = p.ProfilePropertiesFormat
16021	}
16022	if p.Etag != nil {
16023		objectMap["etag"] = p.Etag
16024	}
16025	if p.ID != nil {
16026		objectMap["id"] = p.ID
16027	}
16028	if p.Name != nil {
16029		objectMap["name"] = p.Name
16030	}
16031	if p.Type != nil {
16032		objectMap["type"] = p.Type
16033	}
16034	if p.Location != nil {
16035		objectMap["location"] = p.Location
16036	}
16037	if p.Tags != nil {
16038		objectMap["tags"] = p.Tags
16039	}
16040	return json.Marshal(objectMap)
16041}
16042
16043// UnmarshalJSON is the custom unmarshaler for Profile struct.
16044func (p *Profile) UnmarshalJSON(body []byte) error {
16045	var m map[string]*json.RawMessage
16046	err := json.Unmarshal(body, &m)
16047	if err != nil {
16048		return err
16049	}
16050	for k, v := range m {
16051		switch k {
16052		case "properties":
16053			if v != nil {
16054				var profilePropertiesFormat ProfilePropertiesFormat
16055				err = json.Unmarshal(*v, &profilePropertiesFormat)
16056				if err != nil {
16057					return err
16058				}
16059				p.ProfilePropertiesFormat = &profilePropertiesFormat
16060			}
16061		case "etag":
16062			if v != nil {
16063				var etag string
16064				err = json.Unmarshal(*v, &etag)
16065				if err != nil {
16066					return err
16067				}
16068				p.Etag = &etag
16069			}
16070		case "id":
16071			if v != nil {
16072				var ID string
16073				err = json.Unmarshal(*v, &ID)
16074				if err != nil {
16075					return err
16076				}
16077				p.ID = &ID
16078			}
16079		case "name":
16080			if v != nil {
16081				var name string
16082				err = json.Unmarshal(*v, &name)
16083				if err != nil {
16084					return err
16085				}
16086				p.Name = &name
16087			}
16088		case "type":
16089			if v != nil {
16090				var typeVar string
16091				err = json.Unmarshal(*v, &typeVar)
16092				if err != nil {
16093					return err
16094				}
16095				p.Type = &typeVar
16096			}
16097		case "location":
16098			if v != nil {
16099				var location string
16100				err = json.Unmarshal(*v, &location)
16101				if err != nil {
16102					return err
16103				}
16104				p.Location = &location
16105			}
16106		case "tags":
16107			if v != nil {
16108				var tags map[string]*string
16109				err = json.Unmarshal(*v, &tags)
16110				if err != nil {
16111					return err
16112				}
16113				p.Tags = tags
16114			}
16115		}
16116	}
16117
16118	return nil
16119}
16120
16121// ProfileListResult response for ListNetworkProfiles API service call.
16122type ProfileListResult struct {
16123	autorest.Response `json:"-"`
16124	// Value - A list of network profiles that exist in a resource group.
16125	Value *[]Profile `json:"value,omitempty"`
16126	// NextLink - The URL to get the next set of results.
16127	NextLink *string `json:"nextLink,omitempty"`
16128}
16129
16130// ProfileListResultIterator provides access to a complete listing of Profile values.
16131type ProfileListResultIterator struct {
16132	i    int
16133	page ProfileListResultPage
16134}
16135
16136// Next advances to the next value.  If there was an error making
16137// the request the iterator does not advance and the error is returned.
16138func (iter *ProfileListResultIterator) Next() error {
16139	iter.i++
16140	if iter.i < len(iter.page.Values()) {
16141		return nil
16142	}
16143	err := iter.page.Next()
16144	if err != nil {
16145		iter.i--
16146		return err
16147	}
16148	iter.i = 0
16149	return nil
16150}
16151
16152// NotDone returns true if the enumeration should be started or is not yet complete.
16153func (iter ProfileListResultIterator) NotDone() bool {
16154	return iter.page.NotDone() && iter.i < len(iter.page.Values())
16155}
16156
16157// Response returns the raw server response from the last page request.
16158func (iter ProfileListResultIterator) Response() ProfileListResult {
16159	return iter.page.Response()
16160}
16161
16162// Value returns the current value or a zero-initialized value if the
16163// iterator has advanced beyond the end of the collection.
16164func (iter ProfileListResultIterator) Value() Profile {
16165	if !iter.page.NotDone() {
16166		return Profile{}
16167	}
16168	return iter.page.Values()[iter.i]
16169}
16170
16171// IsEmpty returns true if the ListResult contains no values.
16172func (plr ProfileListResult) IsEmpty() bool {
16173	return plr.Value == nil || len(*plr.Value) == 0
16174}
16175
16176// profileListResultPreparer prepares a request to retrieve the next set of results.
16177// It returns nil if no more results exist.
16178func (plr ProfileListResult) profileListResultPreparer() (*http.Request, error) {
16179	if plr.NextLink == nil || len(to.String(plr.NextLink)) < 1 {
16180		return nil, nil
16181	}
16182	return autorest.Prepare(&http.Request{},
16183		autorest.AsJSON(),
16184		autorest.AsGet(),
16185		autorest.WithBaseURL(to.String(plr.NextLink)))
16186}
16187
16188// ProfileListResultPage contains a page of Profile values.
16189type ProfileListResultPage struct {
16190	fn  func(ProfileListResult) (ProfileListResult, error)
16191	plr ProfileListResult
16192}
16193
16194// Next advances to the next page of values.  If there was an error making
16195// the request the page does not advance and the error is returned.
16196func (page *ProfileListResultPage) Next() error {
16197	next, err := page.fn(page.plr)
16198	if err != nil {
16199		return err
16200	}
16201	page.plr = next
16202	return nil
16203}
16204
16205// NotDone returns true if the page enumeration should be started or is not yet complete.
16206func (page ProfileListResultPage) NotDone() bool {
16207	return !page.plr.IsEmpty()
16208}
16209
16210// Response returns the raw server response from the last page request.
16211func (page ProfileListResultPage) Response() ProfileListResult {
16212	return page.plr
16213}
16214
16215// Values returns the slice of values for the current page or nil if there are no values.
16216func (page ProfileListResultPage) Values() []Profile {
16217	if page.plr.IsEmpty() {
16218		return nil
16219	}
16220	return *page.plr.Value
16221}
16222
16223// ProfilePropertiesFormat network profile properties.
16224type ProfilePropertiesFormat struct {
16225	// ContainerNetworkInterfaces - List of child container network interfaces.
16226	ContainerNetworkInterfaces *[]ContainerNetworkInterface `json:"containerNetworkInterfaces,omitempty"`
16227	// ContainerNetworkInterfaceConfigurations - List of chid container network interface configurations.
16228	ContainerNetworkInterfaceConfigurations *[]ContainerNetworkInterfaceConfiguration `json:"containerNetworkInterfaceConfigurations,omitempty"`
16229	// ResourceGUID - The resource GUID property of the network interface resource.
16230	ResourceGUID *string `json:"resourceGuid,omitempty"`
16231	// ProvisioningState - The provisioning state of the resource.
16232	ProvisioningState *string `json:"provisioningState,omitempty"`
16233}
16234
16235// ProtocolConfiguration configuration of the protocol.
16236type ProtocolConfiguration struct {
16237	HTTPConfiguration *HTTPConfiguration `json:"HTTPConfiguration,omitempty"`
16238}
16239
16240// PublicIPAddress public IP address resource.
16241type PublicIPAddress struct {
16242	autorest.Response `json:"-"`
16243	// Sku - The public IP address SKU.
16244	Sku *PublicIPAddressSku `json:"sku,omitempty"`
16245	// PublicIPAddressPropertiesFormat - Public IP address properties.
16246	*PublicIPAddressPropertiesFormat `json:"properties,omitempty"`
16247	// Etag - A unique read-only string that changes whenever the resource is updated.
16248	Etag *string `json:"etag,omitempty"`
16249	// Zones - A list of availability zones denoting the IP allocated for the resource needs to come from.
16250	Zones *[]string `json:"zones,omitempty"`
16251	// ID - Resource ID.
16252	ID *string `json:"id,omitempty"`
16253	// Name - Resource name.
16254	Name *string `json:"name,omitempty"`
16255	// Type - Resource type.
16256	Type *string `json:"type,omitempty"`
16257	// Location - Resource location.
16258	Location *string `json:"location,omitempty"`
16259	// Tags - Resource tags.
16260	Tags map[string]*string `json:"tags"`
16261}
16262
16263// MarshalJSON is the custom marshaler for PublicIPAddress.
16264func (pia PublicIPAddress) MarshalJSON() ([]byte, error) {
16265	objectMap := make(map[string]interface{})
16266	if pia.Sku != nil {
16267		objectMap["sku"] = pia.Sku
16268	}
16269	if pia.PublicIPAddressPropertiesFormat != nil {
16270		objectMap["properties"] = pia.PublicIPAddressPropertiesFormat
16271	}
16272	if pia.Etag != nil {
16273		objectMap["etag"] = pia.Etag
16274	}
16275	if pia.Zones != nil {
16276		objectMap["zones"] = pia.Zones
16277	}
16278	if pia.ID != nil {
16279		objectMap["id"] = pia.ID
16280	}
16281	if pia.Name != nil {
16282		objectMap["name"] = pia.Name
16283	}
16284	if pia.Type != nil {
16285		objectMap["type"] = pia.Type
16286	}
16287	if pia.Location != nil {
16288		objectMap["location"] = pia.Location
16289	}
16290	if pia.Tags != nil {
16291		objectMap["tags"] = pia.Tags
16292	}
16293	return json.Marshal(objectMap)
16294}
16295
16296// UnmarshalJSON is the custom unmarshaler for PublicIPAddress struct.
16297func (pia *PublicIPAddress) UnmarshalJSON(body []byte) error {
16298	var m map[string]*json.RawMessage
16299	err := json.Unmarshal(body, &m)
16300	if err != nil {
16301		return err
16302	}
16303	for k, v := range m {
16304		switch k {
16305		case "sku":
16306			if v != nil {
16307				var sku PublicIPAddressSku
16308				err = json.Unmarshal(*v, &sku)
16309				if err != nil {
16310					return err
16311				}
16312				pia.Sku = &sku
16313			}
16314		case "properties":
16315			if v != nil {
16316				var publicIPAddressPropertiesFormat PublicIPAddressPropertiesFormat
16317				err = json.Unmarshal(*v, &publicIPAddressPropertiesFormat)
16318				if err != nil {
16319					return err
16320				}
16321				pia.PublicIPAddressPropertiesFormat = &publicIPAddressPropertiesFormat
16322			}
16323		case "etag":
16324			if v != nil {
16325				var etag string
16326				err = json.Unmarshal(*v, &etag)
16327				if err != nil {
16328					return err
16329				}
16330				pia.Etag = &etag
16331			}
16332		case "zones":
16333			if v != nil {
16334				var zones []string
16335				err = json.Unmarshal(*v, &zones)
16336				if err != nil {
16337					return err
16338				}
16339				pia.Zones = &zones
16340			}
16341		case "id":
16342			if v != nil {
16343				var ID string
16344				err = json.Unmarshal(*v, &ID)
16345				if err != nil {
16346					return err
16347				}
16348				pia.ID = &ID
16349			}
16350		case "name":
16351			if v != nil {
16352				var name string
16353				err = json.Unmarshal(*v, &name)
16354				if err != nil {
16355					return err
16356				}
16357				pia.Name = &name
16358			}
16359		case "type":
16360			if v != nil {
16361				var typeVar string
16362				err = json.Unmarshal(*v, &typeVar)
16363				if err != nil {
16364					return err
16365				}
16366				pia.Type = &typeVar
16367			}
16368		case "location":
16369			if v != nil {
16370				var location string
16371				err = json.Unmarshal(*v, &location)
16372				if err != nil {
16373					return err
16374				}
16375				pia.Location = &location
16376			}
16377		case "tags":
16378			if v != nil {
16379				var tags map[string]*string
16380				err = json.Unmarshal(*v, &tags)
16381				if err != nil {
16382					return err
16383				}
16384				pia.Tags = tags
16385			}
16386		}
16387	}
16388
16389	return nil
16390}
16391
16392// PublicIPAddressDNSSettings contains FQDN of the DNS record associated with the public IP address
16393type PublicIPAddressDNSSettings struct {
16394	// 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.
16395	DomainNameLabel *string `json:"domainNameLabel,omitempty"`
16396	// 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.
16397	Fqdn *string `json:"fqdn,omitempty"`
16398	// 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.
16399	ReverseFqdn *string `json:"reverseFqdn,omitempty"`
16400}
16401
16402// PublicIPAddressesCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
16403// operation.
16404type PublicIPAddressesCreateOrUpdateFuture struct {
16405	azure.Future
16406}
16407
16408// Result returns the result of the asynchronous operation.
16409// If the operation has not completed it will return an error.
16410func (future *PublicIPAddressesCreateOrUpdateFuture) Result(client PublicIPAddressesClient) (pia PublicIPAddress, err error) {
16411	var done bool
16412	done, err = future.Done(client)
16413	if err != nil {
16414		err = autorest.NewErrorWithError(err, "network.PublicIPAddressesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
16415		return
16416	}
16417	if !done {
16418		err = azure.NewAsyncOpIncompleteError("network.PublicIPAddressesCreateOrUpdateFuture")
16419		return
16420	}
16421	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
16422	if pia.Response.Response, err = future.GetResult(sender); err == nil && pia.Response.Response.StatusCode != http.StatusNoContent {
16423		pia, err = client.CreateOrUpdateResponder(pia.Response.Response)
16424		if err != nil {
16425			err = autorest.NewErrorWithError(err, "network.PublicIPAddressesCreateOrUpdateFuture", "Result", pia.Response.Response, "Failure responding to request")
16426		}
16427	}
16428	return
16429}
16430
16431// PublicIPAddressesDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
16432// operation.
16433type PublicIPAddressesDeleteFuture struct {
16434	azure.Future
16435}
16436
16437// Result returns the result of the asynchronous operation.
16438// If the operation has not completed it will return an error.
16439func (future *PublicIPAddressesDeleteFuture) Result(client PublicIPAddressesClient) (ar autorest.Response, err error) {
16440	var done bool
16441	done, err = future.Done(client)
16442	if err != nil {
16443		err = autorest.NewErrorWithError(err, "network.PublicIPAddressesDeleteFuture", "Result", future.Response(), "Polling failure")
16444		return
16445	}
16446	if !done {
16447		err = azure.NewAsyncOpIncompleteError("network.PublicIPAddressesDeleteFuture")
16448		return
16449	}
16450	ar.Response = future.Response()
16451	return
16452}
16453
16454// PublicIPAddressesUpdateTagsFuture an abstraction for monitoring and retrieving the results of a long-running
16455// operation.
16456type PublicIPAddressesUpdateTagsFuture struct {
16457	azure.Future
16458}
16459
16460// Result returns the result of the asynchronous operation.
16461// If the operation has not completed it will return an error.
16462func (future *PublicIPAddressesUpdateTagsFuture) Result(client PublicIPAddressesClient) (pia PublicIPAddress, err error) {
16463	var done bool
16464	done, err = future.Done(client)
16465	if err != nil {
16466		err = autorest.NewErrorWithError(err, "network.PublicIPAddressesUpdateTagsFuture", "Result", future.Response(), "Polling failure")
16467		return
16468	}
16469	if !done {
16470		err = azure.NewAsyncOpIncompleteError("network.PublicIPAddressesUpdateTagsFuture")
16471		return
16472	}
16473	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
16474	if pia.Response.Response, err = future.GetResult(sender); err == nil && pia.Response.Response.StatusCode != http.StatusNoContent {
16475		pia, err = client.UpdateTagsResponder(pia.Response.Response)
16476		if err != nil {
16477			err = autorest.NewErrorWithError(err, "network.PublicIPAddressesUpdateTagsFuture", "Result", pia.Response.Response, "Failure responding to request")
16478		}
16479	}
16480	return
16481}
16482
16483// PublicIPAddressListResult response for ListPublicIpAddresses API service call.
16484type PublicIPAddressListResult struct {
16485	autorest.Response `json:"-"`
16486	// Value - A list of public IP addresses that exists in a resource group.
16487	Value *[]PublicIPAddress `json:"value,omitempty"`
16488	// NextLink - The URL to get the next set of results.
16489	NextLink *string `json:"nextLink,omitempty"`
16490}
16491
16492// PublicIPAddressListResultIterator provides access to a complete listing of PublicIPAddress values.
16493type PublicIPAddressListResultIterator struct {
16494	i    int
16495	page PublicIPAddressListResultPage
16496}
16497
16498// Next advances to the next value.  If there was an error making
16499// the request the iterator does not advance and the error is returned.
16500func (iter *PublicIPAddressListResultIterator) Next() error {
16501	iter.i++
16502	if iter.i < len(iter.page.Values()) {
16503		return nil
16504	}
16505	err := iter.page.Next()
16506	if err != nil {
16507		iter.i--
16508		return err
16509	}
16510	iter.i = 0
16511	return nil
16512}
16513
16514// NotDone returns true if the enumeration should be started or is not yet complete.
16515func (iter PublicIPAddressListResultIterator) NotDone() bool {
16516	return iter.page.NotDone() && iter.i < len(iter.page.Values())
16517}
16518
16519// Response returns the raw server response from the last page request.
16520func (iter PublicIPAddressListResultIterator) Response() PublicIPAddressListResult {
16521	return iter.page.Response()
16522}
16523
16524// Value returns the current value or a zero-initialized value if the
16525// iterator has advanced beyond the end of the collection.
16526func (iter PublicIPAddressListResultIterator) Value() PublicIPAddress {
16527	if !iter.page.NotDone() {
16528		return PublicIPAddress{}
16529	}
16530	return iter.page.Values()[iter.i]
16531}
16532
16533// IsEmpty returns true if the ListResult contains no values.
16534func (pialr PublicIPAddressListResult) IsEmpty() bool {
16535	return pialr.Value == nil || len(*pialr.Value) == 0
16536}
16537
16538// publicIPAddressListResultPreparer prepares a request to retrieve the next set of results.
16539// It returns nil if no more results exist.
16540func (pialr PublicIPAddressListResult) publicIPAddressListResultPreparer() (*http.Request, error) {
16541	if pialr.NextLink == nil || len(to.String(pialr.NextLink)) < 1 {
16542		return nil, nil
16543	}
16544	return autorest.Prepare(&http.Request{},
16545		autorest.AsJSON(),
16546		autorest.AsGet(),
16547		autorest.WithBaseURL(to.String(pialr.NextLink)))
16548}
16549
16550// PublicIPAddressListResultPage contains a page of PublicIPAddress values.
16551type PublicIPAddressListResultPage struct {
16552	fn    func(PublicIPAddressListResult) (PublicIPAddressListResult, error)
16553	pialr PublicIPAddressListResult
16554}
16555
16556// Next advances to the next page of values.  If there was an error making
16557// the request the page does not advance and the error is returned.
16558func (page *PublicIPAddressListResultPage) Next() error {
16559	next, err := page.fn(page.pialr)
16560	if err != nil {
16561		return err
16562	}
16563	page.pialr = next
16564	return nil
16565}
16566
16567// NotDone returns true if the page enumeration should be started or is not yet complete.
16568func (page PublicIPAddressListResultPage) NotDone() bool {
16569	return !page.pialr.IsEmpty()
16570}
16571
16572// Response returns the raw server response from the last page request.
16573func (page PublicIPAddressListResultPage) Response() PublicIPAddressListResult {
16574	return page.pialr
16575}
16576
16577// Values returns the slice of values for the current page or nil if there are no values.
16578func (page PublicIPAddressListResultPage) Values() []PublicIPAddress {
16579	if page.pialr.IsEmpty() {
16580		return nil
16581	}
16582	return *page.pialr.Value
16583}
16584
16585// PublicIPAddressPropertiesFormat public IP address properties.
16586type PublicIPAddressPropertiesFormat struct {
16587	// PublicIPAllocationMethod - The public IP allocation method. Possible values are: 'Static' and 'Dynamic'. Possible values include: 'Static', 'Dynamic'
16588	PublicIPAllocationMethod IPAllocationMethod `json:"publicIPAllocationMethod,omitempty"`
16589	// PublicIPAddressVersion - The public IP address version. Possible values are: 'IPv4' and 'IPv6'. Possible values include: 'IPv4', 'IPv6'
16590	PublicIPAddressVersion IPVersion `json:"publicIPAddressVersion,omitempty"`
16591	// IPConfiguration - The IP configuration associated with the public IP address.
16592	IPConfiguration *IPConfiguration `json:"ipConfiguration,omitempty"`
16593	// DNSSettings - The FQDN of the DNS record associated with the public IP address.
16594	DNSSettings *PublicIPAddressDNSSettings `json:"dnsSettings,omitempty"`
16595	// IPTags - The list of tags associated with the public IP address.
16596	IPTags *[]IPTag `json:"ipTags,omitempty"`
16597	// IPAddress - The IP address associated with the public IP address resource.
16598	IPAddress *string `json:"ipAddress,omitempty"`
16599	// PublicIPPrefix - The Public IP Prefix this Public IP Address should be allocated from.
16600	PublicIPPrefix *SubResource `json:"publicIPPrefix,omitempty"`
16601	// IdleTimeoutInMinutes - The idle timeout of the public IP address.
16602	IdleTimeoutInMinutes *int32 `json:"idleTimeoutInMinutes,omitempty"`
16603	// ResourceGUID - The resource GUID property of the public IP resource.
16604	ResourceGUID *string `json:"resourceGuid,omitempty"`
16605	// ProvisioningState - The provisioning state of the PublicIP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
16606	ProvisioningState *string `json:"provisioningState,omitempty"`
16607}
16608
16609// PublicIPAddressSku SKU of a public IP address
16610type PublicIPAddressSku struct {
16611	// Name - Name of a public IP address SKU. Possible values include: 'PublicIPAddressSkuNameBasic', 'PublicIPAddressSkuNameStandard'
16612	Name PublicIPAddressSkuName `json:"name,omitempty"`
16613}
16614
16615// PublicIPPrefix public IP prefix resource.
16616type PublicIPPrefix struct {
16617	autorest.Response `json:"-"`
16618	// Sku - The public IP prefix SKU.
16619	Sku *PublicIPPrefixSku `json:"sku,omitempty"`
16620	// PublicIPPrefixPropertiesFormat - Public IP prefix properties.
16621	*PublicIPPrefixPropertiesFormat `json:"properties,omitempty"`
16622	// Etag - A unique read-only string that changes whenever the resource is updated.
16623	Etag *string `json:"etag,omitempty"`
16624	// Zones - A list of availability zones denoting the IP allocated for the resource needs to come from.
16625	Zones *[]string `json:"zones,omitempty"`
16626	// ID - Resource ID.
16627	ID *string `json:"id,omitempty"`
16628	// Name - Resource name.
16629	Name *string `json:"name,omitempty"`
16630	// Type - Resource type.
16631	Type *string `json:"type,omitempty"`
16632	// Location - Resource location.
16633	Location *string `json:"location,omitempty"`
16634	// Tags - Resource tags.
16635	Tags map[string]*string `json:"tags"`
16636}
16637
16638// MarshalJSON is the custom marshaler for PublicIPPrefix.
16639func (pip PublicIPPrefix) MarshalJSON() ([]byte, error) {
16640	objectMap := make(map[string]interface{})
16641	if pip.Sku != nil {
16642		objectMap["sku"] = pip.Sku
16643	}
16644	if pip.PublicIPPrefixPropertiesFormat != nil {
16645		objectMap["properties"] = pip.PublicIPPrefixPropertiesFormat
16646	}
16647	if pip.Etag != nil {
16648		objectMap["etag"] = pip.Etag
16649	}
16650	if pip.Zones != nil {
16651		objectMap["zones"] = pip.Zones
16652	}
16653	if pip.ID != nil {
16654		objectMap["id"] = pip.ID
16655	}
16656	if pip.Name != nil {
16657		objectMap["name"] = pip.Name
16658	}
16659	if pip.Type != nil {
16660		objectMap["type"] = pip.Type
16661	}
16662	if pip.Location != nil {
16663		objectMap["location"] = pip.Location
16664	}
16665	if pip.Tags != nil {
16666		objectMap["tags"] = pip.Tags
16667	}
16668	return json.Marshal(objectMap)
16669}
16670
16671// UnmarshalJSON is the custom unmarshaler for PublicIPPrefix struct.
16672func (pip *PublicIPPrefix) UnmarshalJSON(body []byte) error {
16673	var m map[string]*json.RawMessage
16674	err := json.Unmarshal(body, &m)
16675	if err != nil {
16676		return err
16677	}
16678	for k, v := range m {
16679		switch k {
16680		case "sku":
16681			if v != nil {
16682				var sku PublicIPPrefixSku
16683				err = json.Unmarshal(*v, &sku)
16684				if err != nil {
16685					return err
16686				}
16687				pip.Sku = &sku
16688			}
16689		case "properties":
16690			if v != nil {
16691				var publicIPPrefixPropertiesFormat PublicIPPrefixPropertiesFormat
16692				err = json.Unmarshal(*v, &publicIPPrefixPropertiesFormat)
16693				if err != nil {
16694					return err
16695				}
16696				pip.PublicIPPrefixPropertiesFormat = &publicIPPrefixPropertiesFormat
16697			}
16698		case "etag":
16699			if v != nil {
16700				var etag string
16701				err = json.Unmarshal(*v, &etag)
16702				if err != nil {
16703					return err
16704				}
16705				pip.Etag = &etag
16706			}
16707		case "zones":
16708			if v != nil {
16709				var zones []string
16710				err = json.Unmarshal(*v, &zones)
16711				if err != nil {
16712					return err
16713				}
16714				pip.Zones = &zones
16715			}
16716		case "id":
16717			if v != nil {
16718				var ID string
16719				err = json.Unmarshal(*v, &ID)
16720				if err != nil {
16721					return err
16722				}
16723				pip.ID = &ID
16724			}
16725		case "name":
16726			if v != nil {
16727				var name string
16728				err = json.Unmarshal(*v, &name)
16729				if err != nil {
16730					return err
16731				}
16732				pip.Name = &name
16733			}
16734		case "type":
16735			if v != nil {
16736				var typeVar string
16737				err = json.Unmarshal(*v, &typeVar)
16738				if err != nil {
16739					return err
16740				}
16741				pip.Type = &typeVar
16742			}
16743		case "location":
16744			if v != nil {
16745				var location string
16746				err = json.Unmarshal(*v, &location)
16747				if err != nil {
16748					return err
16749				}
16750				pip.Location = &location
16751			}
16752		case "tags":
16753			if v != nil {
16754				var tags map[string]*string
16755				err = json.Unmarshal(*v, &tags)
16756				if err != nil {
16757					return err
16758				}
16759				pip.Tags = tags
16760			}
16761		}
16762	}
16763
16764	return nil
16765}
16766
16767// PublicIPPrefixesCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
16768// operation.
16769type PublicIPPrefixesCreateOrUpdateFuture struct {
16770	azure.Future
16771}
16772
16773// Result returns the result of the asynchronous operation.
16774// If the operation has not completed it will return an error.
16775func (future *PublicIPPrefixesCreateOrUpdateFuture) Result(client PublicIPPrefixesClient) (pip PublicIPPrefix, err error) {
16776	var done bool
16777	done, err = future.Done(client)
16778	if err != nil {
16779		err = autorest.NewErrorWithError(err, "network.PublicIPPrefixesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
16780		return
16781	}
16782	if !done {
16783		err = azure.NewAsyncOpIncompleteError("network.PublicIPPrefixesCreateOrUpdateFuture")
16784		return
16785	}
16786	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
16787	if pip.Response.Response, err = future.GetResult(sender); err == nil && pip.Response.Response.StatusCode != http.StatusNoContent {
16788		pip, err = client.CreateOrUpdateResponder(pip.Response.Response)
16789		if err != nil {
16790			err = autorest.NewErrorWithError(err, "network.PublicIPPrefixesCreateOrUpdateFuture", "Result", pip.Response.Response, "Failure responding to request")
16791		}
16792	}
16793	return
16794}
16795
16796// PublicIPPrefixesDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
16797// operation.
16798type PublicIPPrefixesDeleteFuture struct {
16799	azure.Future
16800}
16801
16802// Result returns the result of the asynchronous operation.
16803// If the operation has not completed it will return an error.
16804func (future *PublicIPPrefixesDeleteFuture) Result(client PublicIPPrefixesClient) (ar autorest.Response, err error) {
16805	var done bool
16806	done, err = future.Done(client)
16807	if err != nil {
16808		err = autorest.NewErrorWithError(err, "network.PublicIPPrefixesDeleteFuture", "Result", future.Response(), "Polling failure")
16809		return
16810	}
16811	if !done {
16812		err = azure.NewAsyncOpIncompleteError("network.PublicIPPrefixesDeleteFuture")
16813		return
16814	}
16815	ar.Response = future.Response()
16816	return
16817}
16818
16819// PublicIPPrefixesUpdateTagsFuture an abstraction for monitoring and retrieving the results of a long-running
16820// operation.
16821type PublicIPPrefixesUpdateTagsFuture struct {
16822	azure.Future
16823}
16824
16825// Result returns the result of the asynchronous operation.
16826// If the operation has not completed it will return an error.
16827func (future *PublicIPPrefixesUpdateTagsFuture) Result(client PublicIPPrefixesClient) (pip PublicIPPrefix, err error) {
16828	var done bool
16829	done, err = future.Done(client)
16830	if err != nil {
16831		err = autorest.NewErrorWithError(err, "network.PublicIPPrefixesUpdateTagsFuture", "Result", future.Response(), "Polling failure")
16832		return
16833	}
16834	if !done {
16835		err = azure.NewAsyncOpIncompleteError("network.PublicIPPrefixesUpdateTagsFuture")
16836		return
16837	}
16838	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
16839	if pip.Response.Response, err = future.GetResult(sender); err == nil && pip.Response.Response.StatusCode != http.StatusNoContent {
16840		pip, err = client.UpdateTagsResponder(pip.Response.Response)
16841		if err != nil {
16842			err = autorest.NewErrorWithError(err, "network.PublicIPPrefixesUpdateTagsFuture", "Result", pip.Response.Response, "Failure responding to request")
16843		}
16844	}
16845	return
16846}
16847
16848// PublicIPPrefixListResult response for ListPublicIpPrefixes API service call.
16849type PublicIPPrefixListResult struct {
16850	autorest.Response `json:"-"`
16851	// Value - A list of public IP prefixes that exists in a resource group.
16852	Value *[]PublicIPPrefix `json:"value,omitempty"`
16853	// NextLink - The URL to get the next set of results.
16854	NextLink *string `json:"nextLink,omitempty"`
16855}
16856
16857// PublicIPPrefixListResultIterator provides access to a complete listing of PublicIPPrefix values.
16858type PublicIPPrefixListResultIterator struct {
16859	i    int
16860	page PublicIPPrefixListResultPage
16861}
16862
16863// Next advances to the next value.  If there was an error making
16864// the request the iterator does not advance and the error is returned.
16865func (iter *PublicIPPrefixListResultIterator) Next() error {
16866	iter.i++
16867	if iter.i < len(iter.page.Values()) {
16868		return nil
16869	}
16870	err := iter.page.Next()
16871	if err != nil {
16872		iter.i--
16873		return err
16874	}
16875	iter.i = 0
16876	return nil
16877}
16878
16879// NotDone returns true if the enumeration should be started or is not yet complete.
16880func (iter PublicIPPrefixListResultIterator) NotDone() bool {
16881	return iter.page.NotDone() && iter.i < len(iter.page.Values())
16882}
16883
16884// Response returns the raw server response from the last page request.
16885func (iter PublicIPPrefixListResultIterator) Response() PublicIPPrefixListResult {
16886	return iter.page.Response()
16887}
16888
16889// Value returns the current value or a zero-initialized value if the
16890// iterator has advanced beyond the end of the collection.
16891func (iter PublicIPPrefixListResultIterator) Value() PublicIPPrefix {
16892	if !iter.page.NotDone() {
16893		return PublicIPPrefix{}
16894	}
16895	return iter.page.Values()[iter.i]
16896}
16897
16898// IsEmpty returns true if the ListResult contains no values.
16899func (piplr PublicIPPrefixListResult) IsEmpty() bool {
16900	return piplr.Value == nil || len(*piplr.Value) == 0
16901}
16902
16903// publicIPPrefixListResultPreparer prepares a request to retrieve the next set of results.
16904// It returns nil if no more results exist.
16905func (piplr PublicIPPrefixListResult) publicIPPrefixListResultPreparer() (*http.Request, error) {
16906	if piplr.NextLink == nil || len(to.String(piplr.NextLink)) < 1 {
16907		return nil, nil
16908	}
16909	return autorest.Prepare(&http.Request{},
16910		autorest.AsJSON(),
16911		autorest.AsGet(),
16912		autorest.WithBaseURL(to.String(piplr.NextLink)))
16913}
16914
16915// PublicIPPrefixListResultPage contains a page of PublicIPPrefix values.
16916type PublicIPPrefixListResultPage struct {
16917	fn    func(PublicIPPrefixListResult) (PublicIPPrefixListResult, error)
16918	piplr PublicIPPrefixListResult
16919}
16920
16921// Next advances to the next page of values.  If there was an error making
16922// the request the page does not advance and the error is returned.
16923func (page *PublicIPPrefixListResultPage) Next() error {
16924	next, err := page.fn(page.piplr)
16925	if err != nil {
16926		return err
16927	}
16928	page.piplr = next
16929	return nil
16930}
16931
16932// NotDone returns true if the page enumeration should be started or is not yet complete.
16933func (page PublicIPPrefixListResultPage) NotDone() bool {
16934	return !page.piplr.IsEmpty()
16935}
16936
16937// Response returns the raw server response from the last page request.
16938func (page PublicIPPrefixListResultPage) Response() PublicIPPrefixListResult {
16939	return page.piplr
16940}
16941
16942// Values returns the slice of values for the current page or nil if there are no values.
16943func (page PublicIPPrefixListResultPage) Values() []PublicIPPrefix {
16944	if page.piplr.IsEmpty() {
16945		return nil
16946	}
16947	return *page.piplr.Value
16948}
16949
16950// PublicIPPrefixPropertiesFormat public IP prefix properties.
16951type PublicIPPrefixPropertiesFormat struct {
16952	// PublicIPAddressVersion - The public IP address version. Possible values are: 'IPv4' and 'IPv6'. Possible values include: 'IPv4', 'IPv6'
16953	PublicIPAddressVersion IPVersion `json:"publicIPAddressVersion,omitempty"`
16954	// IPTags - The list of tags associated with the public IP prefix.
16955	IPTags *[]IPTag `json:"ipTags,omitempty"`
16956	// PrefixLength - The Length of the Public IP Prefix.
16957	PrefixLength *int32 `json:"prefixLength,omitempty"`
16958	// IPPrefix - The allocated Prefix
16959	IPPrefix *string `json:"ipPrefix,omitempty"`
16960	// PublicIPAddresses - The list of all referenced PublicIPAddresses
16961	PublicIPAddresses *[]ReferencedPublicIPAddress `json:"publicIPAddresses,omitempty"`
16962	// ResourceGUID - The resource GUID property of the public IP prefix resource.
16963	ResourceGUID *string `json:"resourceGuid,omitempty"`
16964	// ProvisioningState - The provisioning state of the Public IP prefix resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
16965	ProvisioningState *string `json:"provisioningState,omitempty"`
16966}
16967
16968// PublicIPPrefixSku SKU of a public IP prefix
16969type PublicIPPrefixSku struct {
16970	// Name - Name of a public IP prefix SKU. Possible values include: 'PublicIPPrefixSkuNameStandard'
16971	Name PublicIPPrefixSkuName `json:"name,omitempty"`
16972}
16973
16974// QueryTroubleshootingParameters parameters that define the resource to query the troubleshooting result.
16975type QueryTroubleshootingParameters struct {
16976	// TargetResourceID - The target resource ID to query the troubleshooting result.
16977	TargetResourceID *string `json:"targetResourceId,omitempty"`
16978}
16979
16980// ReferencedPublicIPAddress ...
16981type ReferencedPublicIPAddress struct {
16982	// ID - The PublicIPAddress Reference
16983	ID *string `json:"id,omitempty"`
16984}
16985
16986// Resource common resource representation.
16987type Resource struct {
16988	// ID - Resource ID.
16989	ID *string `json:"id,omitempty"`
16990	// Name - Resource name.
16991	Name *string `json:"name,omitempty"`
16992	// Type - Resource type.
16993	Type *string `json:"type,omitempty"`
16994	// Location - Resource location.
16995	Location *string `json:"location,omitempty"`
16996	// Tags - Resource tags.
16997	Tags map[string]*string `json:"tags"`
16998}
16999
17000// MarshalJSON is the custom marshaler for Resource.
17001func (r Resource) MarshalJSON() ([]byte, error) {
17002	objectMap := make(map[string]interface{})
17003	if r.ID != nil {
17004		objectMap["id"] = r.ID
17005	}
17006	if r.Name != nil {
17007		objectMap["name"] = r.Name
17008	}
17009	if r.Type != nil {
17010		objectMap["type"] = r.Type
17011	}
17012	if r.Location != nil {
17013		objectMap["location"] = r.Location
17014	}
17015	if r.Tags != nil {
17016		objectMap["tags"] = r.Tags
17017	}
17018	return json.Marshal(objectMap)
17019}
17020
17021// ResourceNavigationLink resourceNavigationLink resource.
17022type ResourceNavigationLink struct {
17023	// ResourceNavigationLinkFormat - Resource navigation link properties format.
17024	*ResourceNavigationLinkFormat `json:"properties,omitempty"`
17025	// Name - Name of the resource that is unique within a resource group. This name can be used to access the resource.
17026	Name *string `json:"name,omitempty"`
17027	// Etag - A unique read-only string that changes whenever the resource is updated.
17028	Etag *string `json:"etag,omitempty"`
17029	// ID - Resource ID.
17030	ID *string `json:"id,omitempty"`
17031}
17032
17033// MarshalJSON is the custom marshaler for ResourceNavigationLink.
17034func (rnl ResourceNavigationLink) MarshalJSON() ([]byte, error) {
17035	objectMap := make(map[string]interface{})
17036	if rnl.ResourceNavigationLinkFormat != nil {
17037		objectMap["properties"] = rnl.ResourceNavigationLinkFormat
17038	}
17039	if rnl.Name != nil {
17040		objectMap["name"] = rnl.Name
17041	}
17042	if rnl.Etag != nil {
17043		objectMap["etag"] = rnl.Etag
17044	}
17045	if rnl.ID != nil {
17046		objectMap["id"] = rnl.ID
17047	}
17048	return json.Marshal(objectMap)
17049}
17050
17051// UnmarshalJSON is the custom unmarshaler for ResourceNavigationLink struct.
17052func (rnl *ResourceNavigationLink) UnmarshalJSON(body []byte) error {
17053	var m map[string]*json.RawMessage
17054	err := json.Unmarshal(body, &m)
17055	if err != nil {
17056		return err
17057	}
17058	for k, v := range m {
17059		switch k {
17060		case "properties":
17061			if v != nil {
17062				var resourceNavigationLinkFormat ResourceNavigationLinkFormat
17063				err = json.Unmarshal(*v, &resourceNavigationLinkFormat)
17064				if err != nil {
17065					return err
17066				}
17067				rnl.ResourceNavigationLinkFormat = &resourceNavigationLinkFormat
17068			}
17069		case "name":
17070			if v != nil {
17071				var name string
17072				err = json.Unmarshal(*v, &name)
17073				if err != nil {
17074					return err
17075				}
17076				rnl.Name = &name
17077			}
17078		case "etag":
17079			if v != nil {
17080				var etag string
17081				err = json.Unmarshal(*v, &etag)
17082				if err != nil {
17083					return err
17084				}
17085				rnl.Etag = &etag
17086			}
17087		case "id":
17088			if v != nil {
17089				var ID string
17090				err = json.Unmarshal(*v, &ID)
17091				if err != nil {
17092					return err
17093				}
17094				rnl.ID = &ID
17095			}
17096		}
17097	}
17098
17099	return nil
17100}
17101
17102// ResourceNavigationLinkFormat properties of ResourceNavigationLink.
17103type ResourceNavigationLinkFormat struct {
17104	// LinkedResourceType - Resource type of the linked resource.
17105	LinkedResourceType *string `json:"linkedResourceType,omitempty"`
17106	// Link - Link to the external resource
17107	Link *string `json:"link,omitempty"`
17108	// ProvisioningState - Provisioning state of the ResourceNavigationLink resource.
17109	ProvisioningState *string `json:"provisioningState,omitempty"`
17110}
17111
17112// RetentionPolicyParameters parameters that define the retention policy for flow log.
17113type RetentionPolicyParameters struct {
17114	// Days - Number of days to retain flow log records.
17115	Days *int32 `json:"days,omitempty"`
17116	// Enabled - Flag to enable/disable retention.
17117	Enabled *bool `json:"enabled,omitempty"`
17118}
17119
17120// Route route resource
17121type Route struct {
17122	autorest.Response `json:"-"`
17123	// RoutePropertiesFormat - Properties of the route.
17124	*RoutePropertiesFormat `json:"properties,omitempty"`
17125	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
17126	Name *string `json:"name,omitempty"`
17127	// Etag - A unique read-only string that changes whenever the resource is updated.
17128	Etag *string `json:"etag,omitempty"`
17129	// ID - Resource ID.
17130	ID *string `json:"id,omitempty"`
17131}
17132
17133// MarshalJSON is the custom marshaler for Route.
17134func (r Route) MarshalJSON() ([]byte, error) {
17135	objectMap := make(map[string]interface{})
17136	if r.RoutePropertiesFormat != nil {
17137		objectMap["properties"] = r.RoutePropertiesFormat
17138	}
17139	if r.Name != nil {
17140		objectMap["name"] = r.Name
17141	}
17142	if r.Etag != nil {
17143		objectMap["etag"] = r.Etag
17144	}
17145	if r.ID != nil {
17146		objectMap["id"] = r.ID
17147	}
17148	return json.Marshal(objectMap)
17149}
17150
17151// UnmarshalJSON is the custom unmarshaler for Route struct.
17152func (r *Route) UnmarshalJSON(body []byte) error {
17153	var m map[string]*json.RawMessage
17154	err := json.Unmarshal(body, &m)
17155	if err != nil {
17156		return err
17157	}
17158	for k, v := range m {
17159		switch k {
17160		case "properties":
17161			if v != nil {
17162				var routePropertiesFormat RoutePropertiesFormat
17163				err = json.Unmarshal(*v, &routePropertiesFormat)
17164				if err != nil {
17165					return err
17166				}
17167				r.RoutePropertiesFormat = &routePropertiesFormat
17168			}
17169		case "name":
17170			if v != nil {
17171				var name string
17172				err = json.Unmarshal(*v, &name)
17173				if err != nil {
17174					return err
17175				}
17176				r.Name = &name
17177			}
17178		case "etag":
17179			if v != nil {
17180				var etag string
17181				err = json.Unmarshal(*v, &etag)
17182				if err != nil {
17183					return err
17184				}
17185				r.Etag = &etag
17186			}
17187		case "id":
17188			if v != nil {
17189				var ID string
17190				err = json.Unmarshal(*v, &ID)
17191				if err != nil {
17192					return err
17193				}
17194				r.ID = &ID
17195			}
17196		}
17197	}
17198
17199	return nil
17200}
17201
17202// RouteFilter route Filter Resource.
17203type RouteFilter struct {
17204	autorest.Response            `json:"-"`
17205	*RouteFilterPropertiesFormat `json:"properties,omitempty"`
17206	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
17207	Etag *string `json:"etag,omitempty"`
17208	// ID - Resource ID.
17209	ID *string `json:"id,omitempty"`
17210	// Name - Resource name.
17211	Name *string `json:"name,omitempty"`
17212	// Type - Resource type.
17213	Type *string `json:"type,omitempty"`
17214	// Location - Resource location.
17215	Location *string `json:"location,omitempty"`
17216	// Tags - Resource tags.
17217	Tags map[string]*string `json:"tags"`
17218}
17219
17220// MarshalJSON is the custom marshaler for RouteFilter.
17221func (rf RouteFilter) MarshalJSON() ([]byte, error) {
17222	objectMap := make(map[string]interface{})
17223	if rf.RouteFilterPropertiesFormat != nil {
17224		objectMap["properties"] = rf.RouteFilterPropertiesFormat
17225	}
17226	if rf.Etag != nil {
17227		objectMap["etag"] = rf.Etag
17228	}
17229	if rf.ID != nil {
17230		objectMap["id"] = rf.ID
17231	}
17232	if rf.Name != nil {
17233		objectMap["name"] = rf.Name
17234	}
17235	if rf.Type != nil {
17236		objectMap["type"] = rf.Type
17237	}
17238	if rf.Location != nil {
17239		objectMap["location"] = rf.Location
17240	}
17241	if rf.Tags != nil {
17242		objectMap["tags"] = rf.Tags
17243	}
17244	return json.Marshal(objectMap)
17245}
17246
17247// UnmarshalJSON is the custom unmarshaler for RouteFilter struct.
17248func (rf *RouteFilter) UnmarshalJSON(body []byte) error {
17249	var m map[string]*json.RawMessage
17250	err := json.Unmarshal(body, &m)
17251	if err != nil {
17252		return err
17253	}
17254	for k, v := range m {
17255		switch k {
17256		case "properties":
17257			if v != nil {
17258				var routeFilterPropertiesFormat RouteFilterPropertiesFormat
17259				err = json.Unmarshal(*v, &routeFilterPropertiesFormat)
17260				if err != nil {
17261					return err
17262				}
17263				rf.RouteFilterPropertiesFormat = &routeFilterPropertiesFormat
17264			}
17265		case "etag":
17266			if v != nil {
17267				var etag string
17268				err = json.Unmarshal(*v, &etag)
17269				if err != nil {
17270					return err
17271				}
17272				rf.Etag = &etag
17273			}
17274		case "id":
17275			if v != nil {
17276				var ID string
17277				err = json.Unmarshal(*v, &ID)
17278				if err != nil {
17279					return err
17280				}
17281				rf.ID = &ID
17282			}
17283		case "name":
17284			if v != nil {
17285				var name string
17286				err = json.Unmarshal(*v, &name)
17287				if err != nil {
17288					return err
17289				}
17290				rf.Name = &name
17291			}
17292		case "type":
17293			if v != nil {
17294				var typeVar string
17295				err = json.Unmarshal(*v, &typeVar)
17296				if err != nil {
17297					return err
17298				}
17299				rf.Type = &typeVar
17300			}
17301		case "location":
17302			if v != nil {
17303				var location string
17304				err = json.Unmarshal(*v, &location)
17305				if err != nil {
17306					return err
17307				}
17308				rf.Location = &location
17309			}
17310		case "tags":
17311			if v != nil {
17312				var tags map[string]*string
17313				err = json.Unmarshal(*v, &tags)
17314				if err != nil {
17315					return err
17316				}
17317				rf.Tags = tags
17318			}
17319		}
17320	}
17321
17322	return nil
17323}
17324
17325// RouteFilterListResult response for the ListRouteFilters API service call.
17326type RouteFilterListResult struct {
17327	autorest.Response `json:"-"`
17328	// Value - Gets a list of route filters in a resource group.
17329	Value *[]RouteFilter `json:"value,omitempty"`
17330	// NextLink - The URL to get the next set of results.
17331	NextLink *string `json:"nextLink,omitempty"`
17332}
17333
17334// RouteFilterListResultIterator provides access to a complete listing of RouteFilter values.
17335type RouteFilterListResultIterator struct {
17336	i    int
17337	page RouteFilterListResultPage
17338}
17339
17340// Next advances to the next value.  If there was an error making
17341// the request the iterator does not advance and the error is returned.
17342func (iter *RouteFilterListResultIterator) Next() error {
17343	iter.i++
17344	if iter.i < len(iter.page.Values()) {
17345		return nil
17346	}
17347	err := iter.page.Next()
17348	if err != nil {
17349		iter.i--
17350		return err
17351	}
17352	iter.i = 0
17353	return nil
17354}
17355
17356// NotDone returns true if the enumeration should be started or is not yet complete.
17357func (iter RouteFilterListResultIterator) NotDone() bool {
17358	return iter.page.NotDone() && iter.i < len(iter.page.Values())
17359}
17360
17361// Response returns the raw server response from the last page request.
17362func (iter RouteFilterListResultIterator) Response() RouteFilterListResult {
17363	return iter.page.Response()
17364}
17365
17366// Value returns the current value or a zero-initialized value if the
17367// iterator has advanced beyond the end of the collection.
17368func (iter RouteFilterListResultIterator) Value() RouteFilter {
17369	if !iter.page.NotDone() {
17370		return RouteFilter{}
17371	}
17372	return iter.page.Values()[iter.i]
17373}
17374
17375// IsEmpty returns true if the ListResult contains no values.
17376func (rflr RouteFilterListResult) IsEmpty() bool {
17377	return rflr.Value == nil || len(*rflr.Value) == 0
17378}
17379
17380// routeFilterListResultPreparer prepares a request to retrieve the next set of results.
17381// It returns nil if no more results exist.
17382func (rflr RouteFilterListResult) routeFilterListResultPreparer() (*http.Request, error) {
17383	if rflr.NextLink == nil || len(to.String(rflr.NextLink)) < 1 {
17384		return nil, nil
17385	}
17386	return autorest.Prepare(&http.Request{},
17387		autorest.AsJSON(),
17388		autorest.AsGet(),
17389		autorest.WithBaseURL(to.String(rflr.NextLink)))
17390}
17391
17392// RouteFilterListResultPage contains a page of RouteFilter values.
17393type RouteFilterListResultPage struct {
17394	fn   func(RouteFilterListResult) (RouteFilterListResult, error)
17395	rflr RouteFilterListResult
17396}
17397
17398// Next advances to the next page of values.  If there was an error making
17399// the request the page does not advance and the error is returned.
17400func (page *RouteFilterListResultPage) Next() error {
17401	next, err := page.fn(page.rflr)
17402	if err != nil {
17403		return err
17404	}
17405	page.rflr = next
17406	return nil
17407}
17408
17409// NotDone returns true if the page enumeration should be started or is not yet complete.
17410func (page RouteFilterListResultPage) NotDone() bool {
17411	return !page.rflr.IsEmpty()
17412}
17413
17414// Response returns the raw server response from the last page request.
17415func (page RouteFilterListResultPage) Response() RouteFilterListResult {
17416	return page.rflr
17417}
17418
17419// Values returns the slice of values for the current page or nil if there are no values.
17420func (page RouteFilterListResultPage) Values() []RouteFilter {
17421	if page.rflr.IsEmpty() {
17422		return nil
17423	}
17424	return *page.rflr.Value
17425}
17426
17427// RouteFilterPropertiesFormat route Filter Resource
17428type RouteFilterPropertiesFormat struct {
17429	// Rules - Collection of RouteFilterRules contained within a route filter.
17430	Rules *[]RouteFilterRule `json:"rules,omitempty"`
17431	// Peerings - A collection of references to express route circuit peerings.
17432	Peerings *[]ExpressRouteCircuitPeering `json:"peerings,omitempty"`
17433	// ProvisioningState - The provisioning state of the resource. Possible values are: 'Updating', 'Deleting', 'Succeeded' and 'Failed'.
17434	ProvisioningState *string `json:"provisioningState,omitempty"`
17435}
17436
17437// RouteFilterRule route Filter Rule Resource
17438type RouteFilterRule struct {
17439	autorest.Response                `json:"-"`
17440	*RouteFilterRulePropertiesFormat `json:"properties,omitempty"`
17441	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
17442	Name *string `json:"name,omitempty"`
17443	// Location - Resource location.
17444	Location *string `json:"location,omitempty"`
17445	// Etag - A unique read-only string that changes whenever the resource is updated.
17446	Etag *string `json:"etag,omitempty"`
17447	// ID - Resource ID.
17448	ID *string `json:"id,omitempty"`
17449}
17450
17451// MarshalJSON is the custom marshaler for RouteFilterRule.
17452func (rfr RouteFilterRule) MarshalJSON() ([]byte, error) {
17453	objectMap := make(map[string]interface{})
17454	if rfr.RouteFilterRulePropertiesFormat != nil {
17455		objectMap["properties"] = rfr.RouteFilterRulePropertiesFormat
17456	}
17457	if rfr.Name != nil {
17458		objectMap["name"] = rfr.Name
17459	}
17460	if rfr.Location != nil {
17461		objectMap["location"] = rfr.Location
17462	}
17463	if rfr.Etag != nil {
17464		objectMap["etag"] = rfr.Etag
17465	}
17466	if rfr.ID != nil {
17467		objectMap["id"] = rfr.ID
17468	}
17469	return json.Marshal(objectMap)
17470}
17471
17472// UnmarshalJSON is the custom unmarshaler for RouteFilterRule struct.
17473func (rfr *RouteFilterRule) UnmarshalJSON(body []byte) error {
17474	var m map[string]*json.RawMessage
17475	err := json.Unmarshal(body, &m)
17476	if err != nil {
17477		return err
17478	}
17479	for k, v := range m {
17480		switch k {
17481		case "properties":
17482			if v != nil {
17483				var routeFilterRulePropertiesFormat RouteFilterRulePropertiesFormat
17484				err = json.Unmarshal(*v, &routeFilterRulePropertiesFormat)
17485				if err != nil {
17486					return err
17487				}
17488				rfr.RouteFilterRulePropertiesFormat = &routeFilterRulePropertiesFormat
17489			}
17490		case "name":
17491			if v != nil {
17492				var name string
17493				err = json.Unmarshal(*v, &name)
17494				if err != nil {
17495					return err
17496				}
17497				rfr.Name = &name
17498			}
17499		case "location":
17500			if v != nil {
17501				var location string
17502				err = json.Unmarshal(*v, &location)
17503				if err != nil {
17504					return err
17505				}
17506				rfr.Location = &location
17507			}
17508		case "etag":
17509			if v != nil {
17510				var etag string
17511				err = json.Unmarshal(*v, &etag)
17512				if err != nil {
17513					return err
17514				}
17515				rfr.Etag = &etag
17516			}
17517		case "id":
17518			if v != nil {
17519				var ID string
17520				err = json.Unmarshal(*v, &ID)
17521				if err != nil {
17522					return err
17523				}
17524				rfr.ID = &ID
17525			}
17526		}
17527	}
17528
17529	return nil
17530}
17531
17532// RouteFilterRuleListResult response for the ListRouteFilterRules API service call
17533type RouteFilterRuleListResult struct {
17534	autorest.Response `json:"-"`
17535	// Value - Gets a list of RouteFilterRules in a resource group.
17536	Value *[]RouteFilterRule `json:"value,omitempty"`
17537	// NextLink - The URL to get the next set of results.
17538	NextLink *string `json:"nextLink,omitempty"`
17539}
17540
17541// RouteFilterRuleListResultIterator provides access to a complete listing of RouteFilterRule values.
17542type RouteFilterRuleListResultIterator struct {
17543	i    int
17544	page RouteFilterRuleListResultPage
17545}
17546
17547// Next advances to the next value.  If there was an error making
17548// the request the iterator does not advance and the error is returned.
17549func (iter *RouteFilterRuleListResultIterator) Next() error {
17550	iter.i++
17551	if iter.i < len(iter.page.Values()) {
17552		return nil
17553	}
17554	err := iter.page.Next()
17555	if err != nil {
17556		iter.i--
17557		return err
17558	}
17559	iter.i = 0
17560	return nil
17561}
17562
17563// NotDone returns true if the enumeration should be started or is not yet complete.
17564func (iter RouteFilterRuleListResultIterator) NotDone() bool {
17565	return iter.page.NotDone() && iter.i < len(iter.page.Values())
17566}
17567
17568// Response returns the raw server response from the last page request.
17569func (iter RouteFilterRuleListResultIterator) Response() RouteFilterRuleListResult {
17570	return iter.page.Response()
17571}
17572
17573// Value returns the current value or a zero-initialized value if the
17574// iterator has advanced beyond the end of the collection.
17575func (iter RouteFilterRuleListResultIterator) Value() RouteFilterRule {
17576	if !iter.page.NotDone() {
17577		return RouteFilterRule{}
17578	}
17579	return iter.page.Values()[iter.i]
17580}
17581
17582// IsEmpty returns true if the ListResult contains no values.
17583func (rfrlr RouteFilterRuleListResult) IsEmpty() bool {
17584	return rfrlr.Value == nil || len(*rfrlr.Value) == 0
17585}
17586
17587// routeFilterRuleListResultPreparer prepares a request to retrieve the next set of results.
17588// It returns nil if no more results exist.
17589func (rfrlr RouteFilterRuleListResult) routeFilterRuleListResultPreparer() (*http.Request, error) {
17590	if rfrlr.NextLink == nil || len(to.String(rfrlr.NextLink)) < 1 {
17591		return nil, nil
17592	}
17593	return autorest.Prepare(&http.Request{},
17594		autorest.AsJSON(),
17595		autorest.AsGet(),
17596		autorest.WithBaseURL(to.String(rfrlr.NextLink)))
17597}
17598
17599// RouteFilterRuleListResultPage contains a page of RouteFilterRule values.
17600type RouteFilterRuleListResultPage struct {
17601	fn    func(RouteFilterRuleListResult) (RouteFilterRuleListResult, error)
17602	rfrlr RouteFilterRuleListResult
17603}
17604
17605// Next advances to the next page of values.  If there was an error making
17606// the request the page does not advance and the error is returned.
17607func (page *RouteFilterRuleListResultPage) Next() error {
17608	next, err := page.fn(page.rfrlr)
17609	if err != nil {
17610		return err
17611	}
17612	page.rfrlr = next
17613	return nil
17614}
17615
17616// NotDone returns true if the page enumeration should be started or is not yet complete.
17617func (page RouteFilterRuleListResultPage) NotDone() bool {
17618	return !page.rfrlr.IsEmpty()
17619}
17620
17621// Response returns the raw server response from the last page request.
17622func (page RouteFilterRuleListResultPage) Response() RouteFilterRuleListResult {
17623	return page.rfrlr
17624}
17625
17626// Values returns the slice of values for the current page or nil if there are no values.
17627func (page RouteFilterRuleListResultPage) Values() []RouteFilterRule {
17628	if page.rfrlr.IsEmpty() {
17629		return nil
17630	}
17631	return *page.rfrlr.Value
17632}
17633
17634// RouteFilterRulePropertiesFormat route Filter Rule Resource
17635type RouteFilterRulePropertiesFormat struct {
17636	// Access - The access type of the rule. Valid values are: 'Allow', 'Deny'. Possible values include: 'Allow', 'Deny'
17637	Access Access `json:"access,omitempty"`
17638	// RouteFilterRuleType - The rule type of the rule. Valid value is: 'Community'
17639	RouteFilterRuleType *string `json:"routeFilterRuleType,omitempty"`
17640	// Communities - The collection for bgp community values to filter on. e.g. ['12076:5010','12076:5020']
17641	Communities *[]string `json:"communities,omitempty"`
17642	// ProvisioningState - The provisioning state of the resource. Possible values are: 'Updating', 'Deleting', 'Succeeded' and 'Failed'.
17643	ProvisioningState *string `json:"provisioningState,omitempty"`
17644}
17645
17646// RouteFilterRulesCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
17647// operation.
17648type RouteFilterRulesCreateOrUpdateFuture struct {
17649	azure.Future
17650}
17651
17652// Result returns the result of the asynchronous operation.
17653// If the operation has not completed it will return an error.
17654func (future *RouteFilterRulesCreateOrUpdateFuture) Result(client RouteFilterRulesClient) (rfr RouteFilterRule, err error) {
17655	var done bool
17656	done, err = future.Done(client)
17657	if err != nil {
17658		err = autorest.NewErrorWithError(err, "network.RouteFilterRulesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
17659		return
17660	}
17661	if !done {
17662		err = azure.NewAsyncOpIncompleteError("network.RouteFilterRulesCreateOrUpdateFuture")
17663		return
17664	}
17665	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
17666	if rfr.Response.Response, err = future.GetResult(sender); err == nil && rfr.Response.Response.StatusCode != http.StatusNoContent {
17667		rfr, err = client.CreateOrUpdateResponder(rfr.Response.Response)
17668		if err != nil {
17669			err = autorest.NewErrorWithError(err, "network.RouteFilterRulesCreateOrUpdateFuture", "Result", rfr.Response.Response, "Failure responding to request")
17670		}
17671	}
17672	return
17673}
17674
17675// RouteFilterRulesDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
17676// operation.
17677type RouteFilterRulesDeleteFuture struct {
17678	azure.Future
17679}
17680
17681// Result returns the result of the asynchronous operation.
17682// If the operation has not completed it will return an error.
17683func (future *RouteFilterRulesDeleteFuture) Result(client RouteFilterRulesClient) (ar autorest.Response, err error) {
17684	var done bool
17685	done, err = future.Done(client)
17686	if err != nil {
17687		err = autorest.NewErrorWithError(err, "network.RouteFilterRulesDeleteFuture", "Result", future.Response(), "Polling failure")
17688		return
17689	}
17690	if !done {
17691		err = azure.NewAsyncOpIncompleteError("network.RouteFilterRulesDeleteFuture")
17692		return
17693	}
17694	ar.Response = future.Response()
17695	return
17696}
17697
17698// RouteFilterRulesUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
17699// operation.
17700type RouteFilterRulesUpdateFuture struct {
17701	azure.Future
17702}
17703
17704// Result returns the result of the asynchronous operation.
17705// If the operation has not completed it will return an error.
17706func (future *RouteFilterRulesUpdateFuture) Result(client RouteFilterRulesClient) (rfr RouteFilterRule, err error) {
17707	var done bool
17708	done, err = future.Done(client)
17709	if err != nil {
17710		err = autorest.NewErrorWithError(err, "network.RouteFilterRulesUpdateFuture", "Result", future.Response(), "Polling failure")
17711		return
17712	}
17713	if !done {
17714		err = azure.NewAsyncOpIncompleteError("network.RouteFilterRulesUpdateFuture")
17715		return
17716	}
17717	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
17718	if rfr.Response.Response, err = future.GetResult(sender); err == nil && rfr.Response.Response.StatusCode != http.StatusNoContent {
17719		rfr, err = client.UpdateResponder(rfr.Response.Response)
17720		if err != nil {
17721			err = autorest.NewErrorWithError(err, "network.RouteFilterRulesUpdateFuture", "Result", rfr.Response.Response, "Failure responding to request")
17722		}
17723	}
17724	return
17725}
17726
17727// RouteFiltersCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
17728// operation.
17729type RouteFiltersCreateOrUpdateFuture struct {
17730	azure.Future
17731}
17732
17733// Result returns the result of the asynchronous operation.
17734// If the operation has not completed it will return an error.
17735func (future *RouteFiltersCreateOrUpdateFuture) Result(client RouteFiltersClient) (rf RouteFilter, err error) {
17736	var done bool
17737	done, err = future.Done(client)
17738	if err != nil {
17739		err = autorest.NewErrorWithError(err, "network.RouteFiltersCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
17740		return
17741	}
17742	if !done {
17743		err = azure.NewAsyncOpIncompleteError("network.RouteFiltersCreateOrUpdateFuture")
17744		return
17745	}
17746	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
17747	if rf.Response.Response, err = future.GetResult(sender); err == nil && rf.Response.Response.StatusCode != http.StatusNoContent {
17748		rf, err = client.CreateOrUpdateResponder(rf.Response.Response)
17749		if err != nil {
17750			err = autorest.NewErrorWithError(err, "network.RouteFiltersCreateOrUpdateFuture", "Result", rf.Response.Response, "Failure responding to request")
17751		}
17752	}
17753	return
17754}
17755
17756// RouteFiltersDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
17757type RouteFiltersDeleteFuture struct {
17758	azure.Future
17759}
17760
17761// Result returns the result of the asynchronous operation.
17762// If the operation has not completed it will return an error.
17763func (future *RouteFiltersDeleteFuture) Result(client RouteFiltersClient) (ar autorest.Response, err error) {
17764	var done bool
17765	done, err = future.Done(client)
17766	if err != nil {
17767		err = autorest.NewErrorWithError(err, "network.RouteFiltersDeleteFuture", "Result", future.Response(), "Polling failure")
17768		return
17769	}
17770	if !done {
17771		err = azure.NewAsyncOpIncompleteError("network.RouteFiltersDeleteFuture")
17772		return
17773	}
17774	ar.Response = future.Response()
17775	return
17776}
17777
17778// RouteFiltersUpdateFuture an abstraction for monitoring and retrieving the results of a long-running operation.
17779type RouteFiltersUpdateFuture struct {
17780	azure.Future
17781}
17782
17783// Result returns the result of the asynchronous operation.
17784// If the operation has not completed it will return an error.
17785func (future *RouteFiltersUpdateFuture) Result(client RouteFiltersClient) (rf RouteFilter, err error) {
17786	var done bool
17787	done, err = future.Done(client)
17788	if err != nil {
17789		err = autorest.NewErrorWithError(err, "network.RouteFiltersUpdateFuture", "Result", future.Response(), "Polling failure")
17790		return
17791	}
17792	if !done {
17793		err = azure.NewAsyncOpIncompleteError("network.RouteFiltersUpdateFuture")
17794		return
17795	}
17796	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
17797	if rf.Response.Response, err = future.GetResult(sender); err == nil && rf.Response.Response.StatusCode != http.StatusNoContent {
17798		rf, err = client.UpdateResponder(rf.Response.Response)
17799		if err != nil {
17800			err = autorest.NewErrorWithError(err, "network.RouteFiltersUpdateFuture", "Result", rf.Response.Response, "Failure responding to request")
17801		}
17802	}
17803	return
17804}
17805
17806// RouteListResult response for the ListRoute API service call
17807type RouteListResult struct {
17808	autorest.Response `json:"-"`
17809	// Value - Gets a list of routes in a resource group.
17810	Value *[]Route `json:"value,omitempty"`
17811	// NextLink - The URL to get the next set of results.
17812	NextLink *string `json:"nextLink,omitempty"`
17813}
17814
17815// RouteListResultIterator provides access to a complete listing of Route values.
17816type RouteListResultIterator struct {
17817	i    int
17818	page RouteListResultPage
17819}
17820
17821// Next advances to the next value.  If there was an error making
17822// the request the iterator does not advance and the error is returned.
17823func (iter *RouteListResultIterator) Next() error {
17824	iter.i++
17825	if iter.i < len(iter.page.Values()) {
17826		return nil
17827	}
17828	err := iter.page.Next()
17829	if err != nil {
17830		iter.i--
17831		return err
17832	}
17833	iter.i = 0
17834	return nil
17835}
17836
17837// NotDone returns true if the enumeration should be started or is not yet complete.
17838func (iter RouteListResultIterator) NotDone() bool {
17839	return iter.page.NotDone() && iter.i < len(iter.page.Values())
17840}
17841
17842// Response returns the raw server response from the last page request.
17843func (iter RouteListResultIterator) Response() RouteListResult {
17844	return iter.page.Response()
17845}
17846
17847// Value returns the current value or a zero-initialized value if the
17848// iterator has advanced beyond the end of the collection.
17849func (iter RouteListResultIterator) Value() Route {
17850	if !iter.page.NotDone() {
17851		return Route{}
17852	}
17853	return iter.page.Values()[iter.i]
17854}
17855
17856// IsEmpty returns true if the ListResult contains no values.
17857func (rlr RouteListResult) IsEmpty() bool {
17858	return rlr.Value == nil || len(*rlr.Value) == 0
17859}
17860
17861// routeListResultPreparer prepares a request to retrieve the next set of results.
17862// It returns nil if no more results exist.
17863func (rlr RouteListResult) routeListResultPreparer() (*http.Request, error) {
17864	if rlr.NextLink == nil || len(to.String(rlr.NextLink)) < 1 {
17865		return nil, nil
17866	}
17867	return autorest.Prepare(&http.Request{},
17868		autorest.AsJSON(),
17869		autorest.AsGet(),
17870		autorest.WithBaseURL(to.String(rlr.NextLink)))
17871}
17872
17873// RouteListResultPage contains a page of Route values.
17874type RouteListResultPage struct {
17875	fn  func(RouteListResult) (RouteListResult, error)
17876	rlr RouteListResult
17877}
17878
17879// Next advances to the next page of values.  If there was an error making
17880// the request the page does not advance and the error is returned.
17881func (page *RouteListResultPage) Next() error {
17882	next, err := page.fn(page.rlr)
17883	if err != nil {
17884		return err
17885	}
17886	page.rlr = next
17887	return nil
17888}
17889
17890// NotDone returns true if the page enumeration should be started or is not yet complete.
17891func (page RouteListResultPage) NotDone() bool {
17892	return !page.rlr.IsEmpty()
17893}
17894
17895// Response returns the raw server response from the last page request.
17896func (page RouteListResultPage) Response() RouteListResult {
17897	return page.rlr
17898}
17899
17900// Values returns the slice of values for the current page or nil if there are no values.
17901func (page RouteListResultPage) Values() []Route {
17902	if page.rlr.IsEmpty() {
17903		return nil
17904	}
17905	return *page.rlr.Value
17906}
17907
17908// RoutePropertiesFormat route resource
17909type RoutePropertiesFormat struct {
17910	// AddressPrefix - The destination CIDR to which the route applies.
17911	AddressPrefix *string `json:"addressPrefix,omitempty"`
17912	// NextHopType - The type of Azure hop the packet should be sent to. Possible values are: 'VirtualNetworkGateway', 'VnetLocal', 'Internet', 'VirtualAppliance', and 'None'. Possible values include: 'RouteNextHopTypeVirtualNetworkGateway', 'RouteNextHopTypeVnetLocal', 'RouteNextHopTypeInternet', 'RouteNextHopTypeVirtualAppliance', 'RouteNextHopTypeNone'
17913	NextHopType RouteNextHopType `json:"nextHopType,omitempty"`
17914	// NextHopIPAddress - The IP address packets should be forwarded to. Next hop values are only allowed in routes where the next hop type is VirtualAppliance.
17915	NextHopIPAddress *string `json:"nextHopIpAddress,omitempty"`
17916	// ProvisioningState - The provisioning state of the resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
17917	ProvisioningState *string `json:"provisioningState,omitempty"`
17918}
17919
17920// RoutesCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running operation.
17921type RoutesCreateOrUpdateFuture struct {
17922	azure.Future
17923}
17924
17925// Result returns the result of the asynchronous operation.
17926// If the operation has not completed it will return an error.
17927func (future *RoutesCreateOrUpdateFuture) Result(client RoutesClient) (r Route, err error) {
17928	var done bool
17929	done, err = future.Done(client)
17930	if err != nil {
17931		err = autorest.NewErrorWithError(err, "network.RoutesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
17932		return
17933	}
17934	if !done {
17935		err = azure.NewAsyncOpIncompleteError("network.RoutesCreateOrUpdateFuture")
17936		return
17937	}
17938	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
17939	if r.Response.Response, err = future.GetResult(sender); err == nil && r.Response.Response.StatusCode != http.StatusNoContent {
17940		r, err = client.CreateOrUpdateResponder(r.Response.Response)
17941		if err != nil {
17942			err = autorest.NewErrorWithError(err, "network.RoutesCreateOrUpdateFuture", "Result", r.Response.Response, "Failure responding to request")
17943		}
17944	}
17945	return
17946}
17947
17948// RoutesDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
17949type RoutesDeleteFuture struct {
17950	azure.Future
17951}
17952
17953// Result returns the result of the asynchronous operation.
17954// If the operation has not completed it will return an error.
17955func (future *RoutesDeleteFuture) Result(client RoutesClient) (ar autorest.Response, err error) {
17956	var done bool
17957	done, err = future.Done(client)
17958	if err != nil {
17959		err = autorest.NewErrorWithError(err, "network.RoutesDeleteFuture", "Result", future.Response(), "Polling failure")
17960		return
17961	}
17962	if !done {
17963		err = azure.NewAsyncOpIncompleteError("network.RoutesDeleteFuture")
17964		return
17965	}
17966	ar.Response = future.Response()
17967	return
17968}
17969
17970// RouteTable route table resource.
17971type RouteTable struct {
17972	autorest.Response `json:"-"`
17973	// RouteTablePropertiesFormat - Properties of the route table.
17974	*RouteTablePropertiesFormat `json:"properties,omitempty"`
17975	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
17976	Etag *string `json:"etag,omitempty"`
17977	// ID - Resource ID.
17978	ID *string `json:"id,omitempty"`
17979	// Name - Resource name.
17980	Name *string `json:"name,omitempty"`
17981	// Type - Resource type.
17982	Type *string `json:"type,omitempty"`
17983	// Location - Resource location.
17984	Location *string `json:"location,omitempty"`
17985	// Tags - Resource tags.
17986	Tags map[string]*string `json:"tags"`
17987}
17988
17989// MarshalJSON is the custom marshaler for RouteTable.
17990func (rt RouteTable) MarshalJSON() ([]byte, error) {
17991	objectMap := make(map[string]interface{})
17992	if rt.RouteTablePropertiesFormat != nil {
17993		objectMap["properties"] = rt.RouteTablePropertiesFormat
17994	}
17995	if rt.Etag != nil {
17996		objectMap["etag"] = rt.Etag
17997	}
17998	if rt.ID != nil {
17999		objectMap["id"] = rt.ID
18000	}
18001	if rt.Name != nil {
18002		objectMap["name"] = rt.Name
18003	}
18004	if rt.Type != nil {
18005		objectMap["type"] = rt.Type
18006	}
18007	if rt.Location != nil {
18008		objectMap["location"] = rt.Location
18009	}
18010	if rt.Tags != nil {
18011		objectMap["tags"] = rt.Tags
18012	}
18013	return json.Marshal(objectMap)
18014}
18015
18016// UnmarshalJSON is the custom unmarshaler for RouteTable struct.
18017func (rt *RouteTable) UnmarshalJSON(body []byte) error {
18018	var m map[string]*json.RawMessage
18019	err := json.Unmarshal(body, &m)
18020	if err != nil {
18021		return err
18022	}
18023	for k, v := range m {
18024		switch k {
18025		case "properties":
18026			if v != nil {
18027				var routeTablePropertiesFormat RouteTablePropertiesFormat
18028				err = json.Unmarshal(*v, &routeTablePropertiesFormat)
18029				if err != nil {
18030					return err
18031				}
18032				rt.RouteTablePropertiesFormat = &routeTablePropertiesFormat
18033			}
18034		case "etag":
18035			if v != nil {
18036				var etag string
18037				err = json.Unmarshal(*v, &etag)
18038				if err != nil {
18039					return err
18040				}
18041				rt.Etag = &etag
18042			}
18043		case "id":
18044			if v != nil {
18045				var ID string
18046				err = json.Unmarshal(*v, &ID)
18047				if err != nil {
18048					return err
18049				}
18050				rt.ID = &ID
18051			}
18052		case "name":
18053			if v != nil {
18054				var name string
18055				err = json.Unmarshal(*v, &name)
18056				if err != nil {
18057					return err
18058				}
18059				rt.Name = &name
18060			}
18061		case "type":
18062			if v != nil {
18063				var typeVar string
18064				err = json.Unmarshal(*v, &typeVar)
18065				if err != nil {
18066					return err
18067				}
18068				rt.Type = &typeVar
18069			}
18070		case "location":
18071			if v != nil {
18072				var location string
18073				err = json.Unmarshal(*v, &location)
18074				if err != nil {
18075					return err
18076				}
18077				rt.Location = &location
18078			}
18079		case "tags":
18080			if v != nil {
18081				var tags map[string]*string
18082				err = json.Unmarshal(*v, &tags)
18083				if err != nil {
18084					return err
18085				}
18086				rt.Tags = tags
18087			}
18088		}
18089	}
18090
18091	return nil
18092}
18093
18094// RouteTableListResult response for the ListRouteTable API service call.
18095type RouteTableListResult struct {
18096	autorest.Response `json:"-"`
18097	// Value - Gets a list of route tables in a resource group.
18098	Value *[]RouteTable `json:"value,omitempty"`
18099	// NextLink - The URL to get the next set of results.
18100	NextLink *string `json:"nextLink,omitempty"`
18101}
18102
18103// RouteTableListResultIterator provides access to a complete listing of RouteTable values.
18104type RouteTableListResultIterator struct {
18105	i    int
18106	page RouteTableListResultPage
18107}
18108
18109// Next advances to the next value.  If there was an error making
18110// the request the iterator does not advance and the error is returned.
18111func (iter *RouteTableListResultIterator) Next() error {
18112	iter.i++
18113	if iter.i < len(iter.page.Values()) {
18114		return nil
18115	}
18116	err := iter.page.Next()
18117	if err != nil {
18118		iter.i--
18119		return err
18120	}
18121	iter.i = 0
18122	return nil
18123}
18124
18125// NotDone returns true if the enumeration should be started or is not yet complete.
18126func (iter RouteTableListResultIterator) NotDone() bool {
18127	return iter.page.NotDone() && iter.i < len(iter.page.Values())
18128}
18129
18130// Response returns the raw server response from the last page request.
18131func (iter RouteTableListResultIterator) Response() RouteTableListResult {
18132	return iter.page.Response()
18133}
18134
18135// Value returns the current value or a zero-initialized value if the
18136// iterator has advanced beyond the end of the collection.
18137func (iter RouteTableListResultIterator) Value() RouteTable {
18138	if !iter.page.NotDone() {
18139		return RouteTable{}
18140	}
18141	return iter.page.Values()[iter.i]
18142}
18143
18144// IsEmpty returns true if the ListResult contains no values.
18145func (rtlr RouteTableListResult) IsEmpty() bool {
18146	return rtlr.Value == nil || len(*rtlr.Value) == 0
18147}
18148
18149// routeTableListResultPreparer prepares a request to retrieve the next set of results.
18150// It returns nil if no more results exist.
18151func (rtlr RouteTableListResult) routeTableListResultPreparer() (*http.Request, error) {
18152	if rtlr.NextLink == nil || len(to.String(rtlr.NextLink)) < 1 {
18153		return nil, nil
18154	}
18155	return autorest.Prepare(&http.Request{},
18156		autorest.AsJSON(),
18157		autorest.AsGet(),
18158		autorest.WithBaseURL(to.String(rtlr.NextLink)))
18159}
18160
18161// RouteTableListResultPage contains a page of RouteTable values.
18162type RouteTableListResultPage struct {
18163	fn   func(RouteTableListResult) (RouteTableListResult, error)
18164	rtlr RouteTableListResult
18165}
18166
18167// Next advances to the next page of values.  If there was an error making
18168// the request the page does not advance and the error is returned.
18169func (page *RouteTableListResultPage) Next() error {
18170	next, err := page.fn(page.rtlr)
18171	if err != nil {
18172		return err
18173	}
18174	page.rtlr = next
18175	return nil
18176}
18177
18178// NotDone returns true if the page enumeration should be started or is not yet complete.
18179func (page RouteTableListResultPage) NotDone() bool {
18180	return !page.rtlr.IsEmpty()
18181}
18182
18183// Response returns the raw server response from the last page request.
18184func (page RouteTableListResultPage) Response() RouteTableListResult {
18185	return page.rtlr
18186}
18187
18188// Values returns the slice of values for the current page or nil if there are no values.
18189func (page RouteTableListResultPage) Values() []RouteTable {
18190	if page.rtlr.IsEmpty() {
18191		return nil
18192	}
18193	return *page.rtlr.Value
18194}
18195
18196// RouteTablePropertiesFormat route Table resource
18197type RouteTablePropertiesFormat struct {
18198	// Routes - Collection of routes contained within a route table.
18199	Routes *[]Route `json:"routes,omitempty"`
18200	// Subnets - A collection of references to subnets.
18201	Subnets *[]Subnet `json:"subnets,omitempty"`
18202	// DisableBgpRoutePropagation - Gets or sets whether to disable the routes learned by BGP on that route table. True means disable.
18203	DisableBgpRoutePropagation *bool `json:"disableBgpRoutePropagation,omitempty"`
18204	// ProvisioningState - The provisioning state of the resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
18205	ProvisioningState *string `json:"provisioningState,omitempty"`
18206}
18207
18208// RouteTablesCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
18209// operation.
18210type RouteTablesCreateOrUpdateFuture struct {
18211	azure.Future
18212}
18213
18214// Result returns the result of the asynchronous operation.
18215// If the operation has not completed it will return an error.
18216func (future *RouteTablesCreateOrUpdateFuture) Result(client RouteTablesClient) (rt RouteTable, err error) {
18217	var done bool
18218	done, err = future.Done(client)
18219	if err != nil {
18220		err = autorest.NewErrorWithError(err, "network.RouteTablesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
18221		return
18222	}
18223	if !done {
18224		err = azure.NewAsyncOpIncompleteError("network.RouteTablesCreateOrUpdateFuture")
18225		return
18226	}
18227	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
18228	if rt.Response.Response, err = future.GetResult(sender); err == nil && rt.Response.Response.StatusCode != http.StatusNoContent {
18229		rt, err = client.CreateOrUpdateResponder(rt.Response.Response)
18230		if err != nil {
18231			err = autorest.NewErrorWithError(err, "network.RouteTablesCreateOrUpdateFuture", "Result", rt.Response.Response, "Failure responding to request")
18232		}
18233	}
18234	return
18235}
18236
18237// RouteTablesDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
18238type RouteTablesDeleteFuture struct {
18239	azure.Future
18240}
18241
18242// Result returns the result of the asynchronous operation.
18243// If the operation has not completed it will return an error.
18244func (future *RouteTablesDeleteFuture) Result(client RouteTablesClient) (ar autorest.Response, err error) {
18245	var done bool
18246	done, err = future.Done(client)
18247	if err != nil {
18248		err = autorest.NewErrorWithError(err, "network.RouteTablesDeleteFuture", "Result", future.Response(), "Polling failure")
18249		return
18250	}
18251	if !done {
18252		err = azure.NewAsyncOpIncompleteError("network.RouteTablesDeleteFuture")
18253		return
18254	}
18255	ar.Response = future.Response()
18256	return
18257}
18258
18259// RouteTablesUpdateTagsFuture an abstraction for monitoring and retrieving the results of a long-running
18260// operation.
18261type RouteTablesUpdateTagsFuture struct {
18262	azure.Future
18263}
18264
18265// Result returns the result of the asynchronous operation.
18266// If the operation has not completed it will return an error.
18267func (future *RouteTablesUpdateTagsFuture) Result(client RouteTablesClient) (rt RouteTable, err error) {
18268	var done bool
18269	done, err = future.Done(client)
18270	if err != nil {
18271		err = autorest.NewErrorWithError(err, "network.RouteTablesUpdateTagsFuture", "Result", future.Response(), "Polling failure")
18272		return
18273	}
18274	if !done {
18275		err = azure.NewAsyncOpIncompleteError("network.RouteTablesUpdateTagsFuture")
18276		return
18277	}
18278	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
18279	if rt.Response.Response, err = future.GetResult(sender); err == nil && rt.Response.Response.StatusCode != http.StatusNoContent {
18280		rt, err = client.UpdateTagsResponder(rt.Response.Response)
18281		if err != nil {
18282			err = autorest.NewErrorWithError(err, "network.RouteTablesUpdateTagsFuture", "Result", rt.Response.Response, "Failure responding to request")
18283		}
18284	}
18285	return
18286}
18287
18288// SecurityGroup networkSecurityGroup resource.
18289type SecurityGroup struct {
18290	autorest.Response `json:"-"`
18291	// SecurityGroupPropertiesFormat - Properties of the network security group
18292	*SecurityGroupPropertiesFormat `json:"properties,omitempty"`
18293	// Etag - A unique read-only string that changes whenever the resource is updated.
18294	Etag *string `json:"etag,omitempty"`
18295	// ID - Resource ID.
18296	ID *string `json:"id,omitempty"`
18297	// Name - Resource name.
18298	Name *string `json:"name,omitempty"`
18299	// Type - Resource type.
18300	Type *string `json:"type,omitempty"`
18301	// Location - Resource location.
18302	Location *string `json:"location,omitempty"`
18303	// Tags - Resource tags.
18304	Tags map[string]*string `json:"tags"`
18305}
18306
18307// MarshalJSON is the custom marshaler for SecurityGroup.
18308func (sg SecurityGroup) MarshalJSON() ([]byte, error) {
18309	objectMap := make(map[string]interface{})
18310	if sg.SecurityGroupPropertiesFormat != nil {
18311		objectMap["properties"] = sg.SecurityGroupPropertiesFormat
18312	}
18313	if sg.Etag != nil {
18314		objectMap["etag"] = sg.Etag
18315	}
18316	if sg.ID != nil {
18317		objectMap["id"] = sg.ID
18318	}
18319	if sg.Name != nil {
18320		objectMap["name"] = sg.Name
18321	}
18322	if sg.Type != nil {
18323		objectMap["type"] = sg.Type
18324	}
18325	if sg.Location != nil {
18326		objectMap["location"] = sg.Location
18327	}
18328	if sg.Tags != nil {
18329		objectMap["tags"] = sg.Tags
18330	}
18331	return json.Marshal(objectMap)
18332}
18333
18334// UnmarshalJSON is the custom unmarshaler for SecurityGroup struct.
18335func (sg *SecurityGroup) UnmarshalJSON(body []byte) error {
18336	var m map[string]*json.RawMessage
18337	err := json.Unmarshal(body, &m)
18338	if err != nil {
18339		return err
18340	}
18341	for k, v := range m {
18342		switch k {
18343		case "properties":
18344			if v != nil {
18345				var securityGroupPropertiesFormat SecurityGroupPropertiesFormat
18346				err = json.Unmarshal(*v, &securityGroupPropertiesFormat)
18347				if err != nil {
18348					return err
18349				}
18350				sg.SecurityGroupPropertiesFormat = &securityGroupPropertiesFormat
18351			}
18352		case "etag":
18353			if v != nil {
18354				var etag string
18355				err = json.Unmarshal(*v, &etag)
18356				if err != nil {
18357					return err
18358				}
18359				sg.Etag = &etag
18360			}
18361		case "id":
18362			if v != nil {
18363				var ID string
18364				err = json.Unmarshal(*v, &ID)
18365				if err != nil {
18366					return err
18367				}
18368				sg.ID = &ID
18369			}
18370		case "name":
18371			if v != nil {
18372				var name string
18373				err = json.Unmarshal(*v, &name)
18374				if err != nil {
18375					return err
18376				}
18377				sg.Name = &name
18378			}
18379		case "type":
18380			if v != nil {
18381				var typeVar string
18382				err = json.Unmarshal(*v, &typeVar)
18383				if err != nil {
18384					return err
18385				}
18386				sg.Type = &typeVar
18387			}
18388		case "location":
18389			if v != nil {
18390				var location string
18391				err = json.Unmarshal(*v, &location)
18392				if err != nil {
18393					return err
18394				}
18395				sg.Location = &location
18396			}
18397		case "tags":
18398			if v != nil {
18399				var tags map[string]*string
18400				err = json.Unmarshal(*v, &tags)
18401				if err != nil {
18402					return err
18403				}
18404				sg.Tags = tags
18405			}
18406		}
18407	}
18408
18409	return nil
18410}
18411
18412// SecurityGroupListResult response for ListNetworkSecurityGroups API service call.
18413type SecurityGroupListResult struct {
18414	autorest.Response `json:"-"`
18415	// Value - A list of NetworkSecurityGroup resources.
18416	Value *[]SecurityGroup `json:"value,omitempty"`
18417	// NextLink - The URL to get the next set of results.
18418	NextLink *string `json:"nextLink,omitempty"`
18419}
18420
18421// SecurityGroupListResultIterator provides access to a complete listing of SecurityGroup values.
18422type SecurityGroupListResultIterator struct {
18423	i    int
18424	page SecurityGroupListResultPage
18425}
18426
18427// Next advances to the next value.  If there was an error making
18428// the request the iterator does not advance and the error is returned.
18429func (iter *SecurityGroupListResultIterator) Next() error {
18430	iter.i++
18431	if iter.i < len(iter.page.Values()) {
18432		return nil
18433	}
18434	err := iter.page.Next()
18435	if err != nil {
18436		iter.i--
18437		return err
18438	}
18439	iter.i = 0
18440	return nil
18441}
18442
18443// NotDone returns true if the enumeration should be started or is not yet complete.
18444func (iter SecurityGroupListResultIterator) NotDone() bool {
18445	return iter.page.NotDone() && iter.i < len(iter.page.Values())
18446}
18447
18448// Response returns the raw server response from the last page request.
18449func (iter SecurityGroupListResultIterator) Response() SecurityGroupListResult {
18450	return iter.page.Response()
18451}
18452
18453// Value returns the current value or a zero-initialized value if the
18454// iterator has advanced beyond the end of the collection.
18455func (iter SecurityGroupListResultIterator) Value() SecurityGroup {
18456	if !iter.page.NotDone() {
18457		return SecurityGroup{}
18458	}
18459	return iter.page.Values()[iter.i]
18460}
18461
18462// IsEmpty returns true if the ListResult contains no values.
18463func (sglr SecurityGroupListResult) IsEmpty() bool {
18464	return sglr.Value == nil || len(*sglr.Value) == 0
18465}
18466
18467// securityGroupListResultPreparer prepares a request to retrieve the next set of results.
18468// It returns nil if no more results exist.
18469func (sglr SecurityGroupListResult) securityGroupListResultPreparer() (*http.Request, error) {
18470	if sglr.NextLink == nil || len(to.String(sglr.NextLink)) < 1 {
18471		return nil, nil
18472	}
18473	return autorest.Prepare(&http.Request{},
18474		autorest.AsJSON(),
18475		autorest.AsGet(),
18476		autorest.WithBaseURL(to.String(sglr.NextLink)))
18477}
18478
18479// SecurityGroupListResultPage contains a page of SecurityGroup values.
18480type SecurityGroupListResultPage struct {
18481	fn   func(SecurityGroupListResult) (SecurityGroupListResult, error)
18482	sglr SecurityGroupListResult
18483}
18484
18485// Next advances to the next page of values.  If there was an error making
18486// the request the page does not advance and the error is returned.
18487func (page *SecurityGroupListResultPage) Next() error {
18488	next, err := page.fn(page.sglr)
18489	if err != nil {
18490		return err
18491	}
18492	page.sglr = next
18493	return nil
18494}
18495
18496// NotDone returns true if the page enumeration should be started or is not yet complete.
18497func (page SecurityGroupListResultPage) NotDone() bool {
18498	return !page.sglr.IsEmpty()
18499}
18500
18501// Response returns the raw server response from the last page request.
18502func (page SecurityGroupListResultPage) Response() SecurityGroupListResult {
18503	return page.sglr
18504}
18505
18506// Values returns the slice of values for the current page or nil if there are no values.
18507func (page SecurityGroupListResultPage) Values() []SecurityGroup {
18508	if page.sglr.IsEmpty() {
18509		return nil
18510	}
18511	return *page.sglr.Value
18512}
18513
18514// SecurityGroupNetworkInterface network interface and all its associated security rules.
18515type SecurityGroupNetworkInterface struct {
18516	// ID - ID of the network interface.
18517	ID                       *string                   `json:"id,omitempty"`
18518	SecurityRuleAssociations *SecurityRuleAssociations `json:"securityRuleAssociations,omitempty"`
18519}
18520
18521// SecurityGroupPropertiesFormat network Security Group resource.
18522type SecurityGroupPropertiesFormat struct {
18523	// SecurityRules - A collection of security rules of the network security group.
18524	SecurityRules *[]SecurityRule `json:"securityRules,omitempty"`
18525	// DefaultSecurityRules - The default security rules of network security group.
18526	DefaultSecurityRules *[]SecurityRule `json:"defaultSecurityRules,omitempty"`
18527	// NetworkInterfaces - A collection of references to network interfaces.
18528	NetworkInterfaces *[]Interface `json:"networkInterfaces,omitempty"`
18529	// Subnets - A collection of references to subnets.
18530	Subnets *[]Subnet `json:"subnets,omitempty"`
18531	// ResourceGUID - The resource GUID property of the network security group resource.
18532	ResourceGUID *string `json:"resourceGuid,omitempty"`
18533	// ProvisioningState - The provisioning state of the public IP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
18534	ProvisioningState *string `json:"provisioningState,omitempty"`
18535}
18536
18537// SecurityGroupResult network configuration diagnostic result corresponded provided traffic query.
18538type SecurityGroupResult struct {
18539	// SecurityRuleAccessResult - The network traffic is allowed or denied. Possible values are 'Allow' and 'Deny'. Possible values include: 'SecurityRuleAccessAllow', 'SecurityRuleAccessDeny'
18540	SecurityRuleAccessResult SecurityRuleAccess `json:"securityRuleAccessResult,omitempty"`
18541	// EvaluatedNetworkSecurityGroups - List of results network security groups diagnostic.
18542	EvaluatedNetworkSecurityGroups *[]EvaluatedNetworkSecurityGroup `json:"evaluatedNetworkSecurityGroups,omitempty"`
18543}
18544
18545// SecurityGroupsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
18546// operation.
18547type SecurityGroupsCreateOrUpdateFuture struct {
18548	azure.Future
18549}
18550
18551// Result returns the result of the asynchronous operation.
18552// If the operation has not completed it will return an error.
18553func (future *SecurityGroupsCreateOrUpdateFuture) Result(client SecurityGroupsClient) (sg SecurityGroup, err error) {
18554	var done bool
18555	done, err = future.Done(client)
18556	if err != nil {
18557		err = autorest.NewErrorWithError(err, "network.SecurityGroupsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
18558		return
18559	}
18560	if !done {
18561		err = azure.NewAsyncOpIncompleteError("network.SecurityGroupsCreateOrUpdateFuture")
18562		return
18563	}
18564	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
18565	if sg.Response.Response, err = future.GetResult(sender); err == nil && sg.Response.Response.StatusCode != http.StatusNoContent {
18566		sg, err = client.CreateOrUpdateResponder(sg.Response.Response)
18567		if err != nil {
18568			err = autorest.NewErrorWithError(err, "network.SecurityGroupsCreateOrUpdateFuture", "Result", sg.Response.Response, "Failure responding to request")
18569		}
18570	}
18571	return
18572}
18573
18574// SecurityGroupsDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
18575type SecurityGroupsDeleteFuture struct {
18576	azure.Future
18577}
18578
18579// Result returns the result of the asynchronous operation.
18580// If the operation has not completed it will return an error.
18581func (future *SecurityGroupsDeleteFuture) Result(client SecurityGroupsClient) (ar autorest.Response, err error) {
18582	var done bool
18583	done, err = future.Done(client)
18584	if err != nil {
18585		err = autorest.NewErrorWithError(err, "network.SecurityGroupsDeleteFuture", "Result", future.Response(), "Polling failure")
18586		return
18587	}
18588	if !done {
18589		err = azure.NewAsyncOpIncompleteError("network.SecurityGroupsDeleteFuture")
18590		return
18591	}
18592	ar.Response = future.Response()
18593	return
18594}
18595
18596// SecurityGroupsUpdateTagsFuture an abstraction for monitoring and retrieving the results of a long-running
18597// operation.
18598type SecurityGroupsUpdateTagsFuture struct {
18599	azure.Future
18600}
18601
18602// Result returns the result of the asynchronous operation.
18603// If the operation has not completed it will return an error.
18604func (future *SecurityGroupsUpdateTagsFuture) Result(client SecurityGroupsClient) (sg SecurityGroup, err error) {
18605	var done bool
18606	done, err = future.Done(client)
18607	if err != nil {
18608		err = autorest.NewErrorWithError(err, "network.SecurityGroupsUpdateTagsFuture", "Result", future.Response(), "Polling failure")
18609		return
18610	}
18611	if !done {
18612		err = azure.NewAsyncOpIncompleteError("network.SecurityGroupsUpdateTagsFuture")
18613		return
18614	}
18615	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
18616	if sg.Response.Response, err = future.GetResult(sender); err == nil && sg.Response.Response.StatusCode != http.StatusNoContent {
18617		sg, err = client.UpdateTagsResponder(sg.Response.Response)
18618		if err != nil {
18619			err = autorest.NewErrorWithError(err, "network.SecurityGroupsUpdateTagsFuture", "Result", sg.Response.Response, "Failure responding to request")
18620		}
18621	}
18622	return
18623}
18624
18625// SecurityGroupViewParameters parameters that define the VM to check security groups for.
18626type SecurityGroupViewParameters struct {
18627	// TargetResourceID - ID of the target VM.
18628	TargetResourceID *string `json:"targetResourceId,omitempty"`
18629}
18630
18631// SecurityGroupViewResult the information about security rules applied to the specified VM.
18632type SecurityGroupViewResult struct {
18633	autorest.Response `json:"-"`
18634	// NetworkInterfaces - List of network interfaces on the specified VM.
18635	NetworkInterfaces *[]SecurityGroupNetworkInterface `json:"networkInterfaces,omitempty"`
18636}
18637
18638// SecurityRule network security rule.
18639type SecurityRule struct {
18640	autorest.Response `json:"-"`
18641	// SecurityRulePropertiesFormat - Properties of the security rule
18642	*SecurityRulePropertiesFormat `json:"properties,omitempty"`
18643	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
18644	Name *string `json:"name,omitempty"`
18645	// Etag - A unique read-only string that changes whenever the resource is updated.
18646	Etag *string `json:"etag,omitempty"`
18647	// ID - Resource ID.
18648	ID *string `json:"id,omitempty"`
18649}
18650
18651// MarshalJSON is the custom marshaler for SecurityRule.
18652func (sr SecurityRule) MarshalJSON() ([]byte, error) {
18653	objectMap := make(map[string]interface{})
18654	if sr.SecurityRulePropertiesFormat != nil {
18655		objectMap["properties"] = sr.SecurityRulePropertiesFormat
18656	}
18657	if sr.Name != nil {
18658		objectMap["name"] = sr.Name
18659	}
18660	if sr.Etag != nil {
18661		objectMap["etag"] = sr.Etag
18662	}
18663	if sr.ID != nil {
18664		objectMap["id"] = sr.ID
18665	}
18666	return json.Marshal(objectMap)
18667}
18668
18669// UnmarshalJSON is the custom unmarshaler for SecurityRule struct.
18670func (sr *SecurityRule) UnmarshalJSON(body []byte) error {
18671	var m map[string]*json.RawMessage
18672	err := json.Unmarshal(body, &m)
18673	if err != nil {
18674		return err
18675	}
18676	for k, v := range m {
18677		switch k {
18678		case "properties":
18679			if v != nil {
18680				var securityRulePropertiesFormat SecurityRulePropertiesFormat
18681				err = json.Unmarshal(*v, &securityRulePropertiesFormat)
18682				if err != nil {
18683					return err
18684				}
18685				sr.SecurityRulePropertiesFormat = &securityRulePropertiesFormat
18686			}
18687		case "name":
18688			if v != nil {
18689				var name string
18690				err = json.Unmarshal(*v, &name)
18691				if err != nil {
18692					return err
18693				}
18694				sr.Name = &name
18695			}
18696		case "etag":
18697			if v != nil {
18698				var etag string
18699				err = json.Unmarshal(*v, &etag)
18700				if err != nil {
18701					return err
18702				}
18703				sr.Etag = &etag
18704			}
18705		case "id":
18706			if v != nil {
18707				var ID string
18708				err = json.Unmarshal(*v, &ID)
18709				if err != nil {
18710					return err
18711				}
18712				sr.ID = &ID
18713			}
18714		}
18715	}
18716
18717	return nil
18718}
18719
18720// SecurityRuleAssociations all security rules associated with the network interface.
18721type SecurityRuleAssociations struct {
18722	NetworkInterfaceAssociation *InterfaceAssociation `json:"networkInterfaceAssociation,omitempty"`
18723	SubnetAssociation           *SubnetAssociation    `json:"subnetAssociation,omitempty"`
18724	// DefaultSecurityRules - Collection of default security rules of the network security group.
18725	DefaultSecurityRules *[]SecurityRule `json:"defaultSecurityRules,omitempty"`
18726	// EffectiveSecurityRules - Collection of effective security rules.
18727	EffectiveSecurityRules *[]EffectiveNetworkSecurityRule `json:"effectiveSecurityRules,omitempty"`
18728}
18729
18730// SecurityRuleListResult response for ListSecurityRule API service call. Retrieves all security rules that belongs
18731// to a network security group.
18732type SecurityRuleListResult struct {
18733	autorest.Response `json:"-"`
18734	// Value - The security rules in a network security group.
18735	Value *[]SecurityRule `json:"value,omitempty"`
18736	// NextLink - The URL to get the next set of results.
18737	NextLink *string `json:"nextLink,omitempty"`
18738}
18739
18740// SecurityRuleListResultIterator provides access to a complete listing of SecurityRule values.
18741type SecurityRuleListResultIterator struct {
18742	i    int
18743	page SecurityRuleListResultPage
18744}
18745
18746// Next advances to the next value.  If there was an error making
18747// the request the iterator does not advance and the error is returned.
18748func (iter *SecurityRuleListResultIterator) Next() error {
18749	iter.i++
18750	if iter.i < len(iter.page.Values()) {
18751		return nil
18752	}
18753	err := iter.page.Next()
18754	if err != nil {
18755		iter.i--
18756		return err
18757	}
18758	iter.i = 0
18759	return nil
18760}
18761
18762// NotDone returns true if the enumeration should be started or is not yet complete.
18763func (iter SecurityRuleListResultIterator) NotDone() bool {
18764	return iter.page.NotDone() && iter.i < len(iter.page.Values())
18765}
18766
18767// Response returns the raw server response from the last page request.
18768func (iter SecurityRuleListResultIterator) Response() SecurityRuleListResult {
18769	return iter.page.Response()
18770}
18771
18772// Value returns the current value or a zero-initialized value if the
18773// iterator has advanced beyond the end of the collection.
18774func (iter SecurityRuleListResultIterator) Value() SecurityRule {
18775	if !iter.page.NotDone() {
18776		return SecurityRule{}
18777	}
18778	return iter.page.Values()[iter.i]
18779}
18780
18781// IsEmpty returns true if the ListResult contains no values.
18782func (srlr SecurityRuleListResult) IsEmpty() bool {
18783	return srlr.Value == nil || len(*srlr.Value) == 0
18784}
18785
18786// securityRuleListResultPreparer prepares a request to retrieve the next set of results.
18787// It returns nil if no more results exist.
18788func (srlr SecurityRuleListResult) securityRuleListResultPreparer() (*http.Request, error) {
18789	if srlr.NextLink == nil || len(to.String(srlr.NextLink)) < 1 {
18790		return nil, nil
18791	}
18792	return autorest.Prepare(&http.Request{},
18793		autorest.AsJSON(),
18794		autorest.AsGet(),
18795		autorest.WithBaseURL(to.String(srlr.NextLink)))
18796}
18797
18798// SecurityRuleListResultPage contains a page of SecurityRule values.
18799type SecurityRuleListResultPage struct {
18800	fn   func(SecurityRuleListResult) (SecurityRuleListResult, error)
18801	srlr SecurityRuleListResult
18802}
18803
18804// Next advances to the next page of values.  If there was an error making
18805// the request the page does not advance and the error is returned.
18806func (page *SecurityRuleListResultPage) Next() error {
18807	next, err := page.fn(page.srlr)
18808	if err != nil {
18809		return err
18810	}
18811	page.srlr = next
18812	return nil
18813}
18814
18815// NotDone returns true if the page enumeration should be started or is not yet complete.
18816func (page SecurityRuleListResultPage) NotDone() bool {
18817	return !page.srlr.IsEmpty()
18818}
18819
18820// Response returns the raw server response from the last page request.
18821func (page SecurityRuleListResultPage) Response() SecurityRuleListResult {
18822	return page.srlr
18823}
18824
18825// Values returns the slice of values for the current page or nil if there are no values.
18826func (page SecurityRuleListResultPage) Values() []SecurityRule {
18827	if page.srlr.IsEmpty() {
18828		return nil
18829	}
18830	return *page.srlr.Value
18831}
18832
18833// SecurityRulePropertiesFormat security rule resource.
18834type SecurityRulePropertiesFormat struct {
18835	// Description - A description for this rule. Restricted to 140 chars.
18836	Description *string `json:"description,omitempty"`
18837	// Protocol - Network protocol this rule applies to. Possible values are 'Tcp', 'Udp', and '*'. Possible values include: 'SecurityRuleProtocolTCP', 'SecurityRuleProtocolUDP', 'SecurityRuleProtocolAsterisk'
18838	Protocol SecurityRuleProtocol `json:"protocol,omitempty"`
18839	// SourcePortRange - The source port or range. Integer or range between 0 and 65535. Asterix '*' can also be used to match all ports.
18840	SourcePortRange *string `json:"sourcePortRange,omitempty"`
18841	// DestinationPortRange - The destination port or range. Integer or range between 0 and 65535. Asterix '*' can also be used to match all ports.
18842	DestinationPortRange *string `json:"destinationPortRange,omitempty"`
18843	// 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.
18844	SourceAddressPrefix *string `json:"sourceAddressPrefix,omitempty"`
18845	// SourceAddressPrefixes - The CIDR or source IP ranges.
18846	SourceAddressPrefixes *[]string `json:"sourceAddressPrefixes,omitempty"`
18847	// SourceApplicationSecurityGroups - The application security group specified as source.
18848	SourceApplicationSecurityGroups *[]ApplicationSecurityGroup `json:"sourceApplicationSecurityGroups,omitempty"`
18849	// 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.
18850	DestinationAddressPrefix *string `json:"destinationAddressPrefix,omitempty"`
18851	// DestinationAddressPrefixes - The destination address prefixes. CIDR or destination IP ranges.
18852	DestinationAddressPrefixes *[]string `json:"destinationAddressPrefixes,omitempty"`
18853	// DestinationApplicationSecurityGroups - The application security group specified as destination.
18854	DestinationApplicationSecurityGroups *[]ApplicationSecurityGroup `json:"destinationApplicationSecurityGroups,omitempty"`
18855	// SourcePortRanges - The source port ranges.
18856	SourcePortRanges *[]string `json:"sourcePortRanges,omitempty"`
18857	// DestinationPortRanges - The destination port ranges.
18858	DestinationPortRanges *[]string `json:"destinationPortRanges,omitempty"`
18859	// Access - The network traffic is allowed or denied. Possible values are: 'Allow' and 'Deny'. Possible values include: 'SecurityRuleAccessAllow', 'SecurityRuleAccessDeny'
18860	Access SecurityRuleAccess `json:"access,omitempty"`
18861	// 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.
18862	Priority *int32 `json:"priority,omitempty"`
18863	// 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: 'SecurityRuleDirectionInbound', 'SecurityRuleDirectionOutbound'
18864	Direction SecurityRuleDirection `json:"direction,omitempty"`
18865	// ProvisioningState - The provisioning state of the public IP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
18866	ProvisioningState *string `json:"provisioningState,omitempty"`
18867}
18868
18869// SecurityRulesCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
18870// operation.
18871type SecurityRulesCreateOrUpdateFuture struct {
18872	azure.Future
18873}
18874
18875// Result returns the result of the asynchronous operation.
18876// If the operation has not completed it will return an error.
18877func (future *SecurityRulesCreateOrUpdateFuture) Result(client SecurityRulesClient) (sr SecurityRule, err error) {
18878	var done bool
18879	done, err = future.Done(client)
18880	if err != nil {
18881		err = autorest.NewErrorWithError(err, "network.SecurityRulesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
18882		return
18883	}
18884	if !done {
18885		err = azure.NewAsyncOpIncompleteError("network.SecurityRulesCreateOrUpdateFuture")
18886		return
18887	}
18888	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
18889	if sr.Response.Response, err = future.GetResult(sender); err == nil && sr.Response.Response.StatusCode != http.StatusNoContent {
18890		sr, err = client.CreateOrUpdateResponder(sr.Response.Response)
18891		if err != nil {
18892			err = autorest.NewErrorWithError(err, "network.SecurityRulesCreateOrUpdateFuture", "Result", sr.Response.Response, "Failure responding to request")
18893		}
18894	}
18895	return
18896}
18897
18898// SecurityRulesDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
18899type SecurityRulesDeleteFuture struct {
18900	azure.Future
18901}
18902
18903// Result returns the result of the asynchronous operation.
18904// If the operation has not completed it will return an error.
18905func (future *SecurityRulesDeleteFuture) Result(client SecurityRulesClient) (ar autorest.Response, err error) {
18906	var done bool
18907	done, err = future.Done(client)
18908	if err != nil {
18909		err = autorest.NewErrorWithError(err, "network.SecurityRulesDeleteFuture", "Result", future.Response(), "Polling failure")
18910		return
18911	}
18912	if !done {
18913		err = azure.NewAsyncOpIncompleteError("network.SecurityRulesDeleteFuture")
18914		return
18915	}
18916	ar.Response = future.Response()
18917	return
18918}
18919
18920// SecurityRulesEvaluationResult network security rules evaluation result.
18921type SecurityRulesEvaluationResult struct {
18922	// Name - Name of the network security rule.
18923	Name *string `json:"name,omitempty"`
18924	// ProtocolMatched - Value indicating whether protocol is matched.
18925	ProtocolMatched *bool `json:"protocolMatched,omitempty"`
18926	// SourceMatched - Value indicating whether source is matched.
18927	SourceMatched *bool `json:"sourceMatched,omitempty"`
18928	// SourcePortMatched - Value indicating whether source port is matched.
18929	SourcePortMatched *bool `json:"sourcePortMatched,omitempty"`
18930	// DestinationMatched - Value indicating whether destination is matched.
18931	DestinationMatched *bool `json:"destinationMatched,omitempty"`
18932	// DestinationPortMatched - Value indicating whether destination port is matched.
18933	DestinationPortMatched *bool `json:"destinationPortMatched,omitempty"`
18934}
18935
18936// ServiceAssociationLink serviceAssociationLink resource.
18937type ServiceAssociationLink struct {
18938	// ServiceAssociationLinkPropertiesFormat - Resource navigation link properties format.
18939	*ServiceAssociationLinkPropertiesFormat `json:"properties,omitempty"`
18940	// Name - Name of the resource that is unique within a resource group. This name can be used to access the resource.
18941	Name *string `json:"name,omitempty"`
18942	// Etag - A unique read-only string that changes whenever the resource is updated.
18943	Etag *string `json:"etag,omitempty"`
18944	// ID - Resource ID.
18945	ID *string `json:"id,omitempty"`
18946}
18947
18948// MarshalJSON is the custom marshaler for ServiceAssociationLink.
18949func (sal ServiceAssociationLink) MarshalJSON() ([]byte, error) {
18950	objectMap := make(map[string]interface{})
18951	if sal.ServiceAssociationLinkPropertiesFormat != nil {
18952		objectMap["properties"] = sal.ServiceAssociationLinkPropertiesFormat
18953	}
18954	if sal.Name != nil {
18955		objectMap["name"] = sal.Name
18956	}
18957	if sal.Etag != nil {
18958		objectMap["etag"] = sal.Etag
18959	}
18960	if sal.ID != nil {
18961		objectMap["id"] = sal.ID
18962	}
18963	return json.Marshal(objectMap)
18964}
18965
18966// UnmarshalJSON is the custom unmarshaler for ServiceAssociationLink struct.
18967func (sal *ServiceAssociationLink) UnmarshalJSON(body []byte) error {
18968	var m map[string]*json.RawMessage
18969	err := json.Unmarshal(body, &m)
18970	if err != nil {
18971		return err
18972	}
18973	for k, v := range m {
18974		switch k {
18975		case "properties":
18976			if v != nil {
18977				var serviceAssociationLinkPropertiesFormat ServiceAssociationLinkPropertiesFormat
18978				err = json.Unmarshal(*v, &serviceAssociationLinkPropertiesFormat)
18979				if err != nil {
18980					return err
18981				}
18982				sal.ServiceAssociationLinkPropertiesFormat = &serviceAssociationLinkPropertiesFormat
18983			}
18984		case "name":
18985			if v != nil {
18986				var name string
18987				err = json.Unmarshal(*v, &name)
18988				if err != nil {
18989					return err
18990				}
18991				sal.Name = &name
18992			}
18993		case "etag":
18994			if v != nil {
18995				var etag string
18996				err = json.Unmarshal(*v, &etag)
18997				if err != nil {
18998					return err
18999				}
19000				sal.Etag = &etag
19001			}
19002		case "id":
19003			if v != nil {
19004				var ID string
19005				err = json.Unmarshal(*v, &ID)
19006				if err != nil {
19007					return err
19008				}
19009				sal.ID = &ID
19010			}
19011		}
19012	}
19013
19014	return nil
19015}
19016
19017// ServiceAssociationLinkPropertiesFormat properties of ServiceAssociationLink.
19018type ServiceAssociationLinkPropertiesFormat struct {
19019	// LinkedResourceType - Resource type of the linked resource.
19020	LinkedResourceType *string `json:"linkedResourceType,omitempty"`
19021	// Link - Link to the external resource.
19022	Link *string `json:"link,omitempty"`
19023	// ProvisioningState - Provisioning state of the ServiceAssociationLink resource.
19024	ProvisioningState *string `json:"provisioningState,omitempty"`
19025}
19026
19027// ServiceDelegationPropertiesFormat properties of a service delegation.
19028type ServiceDelegationPropertiesFormat struct {
19029	// ServiceName - The name of the service to whom the subnet should be delegated (e.g. Microsoft.Sql/servers)
19030	ServiceName *string `json:"serviceName,omitempty"`
19031	// Actions - Describes the actions permitted to the service upon delegation
19032	Actions *[]string `json:"actions,omitempty"`
19033	// ProvisioningState - The provisioning state of the resource.
19034	ProvisioningState *string `json:"provisioningState,omitempty"`
19035}
19036
19037// ServiceEndpointPoliciesCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
19038// long-running operation.
19039type ServiceEndpointPoliciesCreateOrUpdateFuture struct {
19040	azure.Future
19041}
19042
19043// Result returns the result of the asynchronous operation.
19044// If the operation has not completed it will return an error.
19045func (future *ServiceEndpointPoliciesCreateOrUpdateFuture) Result(client ServiceEndpointPoliciesClient) (sep ServiceEndpointPolicy, err error) {
19046	var done bool
19047	done, err = future.Done(client)
19048	if err != nil {
19049		err = autorest.NewErrorWithError(err, "network.ServiceEndpointPoliciesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
19050		return
19051	}
19052	if !done {
19053		err = azure.NewAsyncOpIncompleteError("network.ServiceEndpointPoliciesCreateOrUpdateFuture")
19054		return
19055	}
19056	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
19057	if sep.Response.Response, err = future.GetResult(sender); err == nil && sep.Response.Response.StatusCode != http.StatusNoContent {
19058		sep, err = client.CreateOrUpdateResponder(sep.Response.Response)
19059		if err != nil {
19060			err = autorest.NewErrorWithError(err, "network.ServiceEndpointPoliciesCreateOrUpdateFuture", "Result", sep.Response.Response, "Failure responding to request")
19061		}
19062	}
19063	return
19064}
19065
19066// ServiceEndpointPoliciesDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
19067// operation.
19068type ServiceEndpointPoliciesDeleteFuture struct {
19069	azure.Future
19070}
19071
19072// Result returns the result of the asynchronous operation.
19073// If the operation has not completed it will return an error.
19074func (future *ServiceEndpointPoliciesDeleteFuture) Result(client ServiceEndpointPoliciesClient) (ar autorest.Response, err error) {
19075	var done bool
19076	done, err = future.Done(client)
19077	if err != nil {
19078		err = autorest.NewErrorWithError(err, "network.ServiceEndpointPoliciesDeleteFuture", "Result", future.Response(), "Polling failure")
19079		return
19080	}
19081	if !done {
19082		err = azure.NewAsyncOpIncompleteError("network.ServiceEndpointPoliciesDeleteFuture")
19083		return
19084	}
19085	ar.Response = future.Response()
19086	return
19087}
19088
19089// ServiceEndpointPoliciesUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
19090// operation.
19091type ServiceEndpointPoliciesUpdateFuture struct {
19092	azure.Future
19093}
19094
19095// Result returns the result of the asynchronous operation.
19096// If the operation has not completed it will return an error.
19097func (future *ServiceEndpointPoliciesUpdateFuture) Result(client ServiceEndpointPoliciesClient) (sep ServiceEndpointPolicy, err error) {
19098	var done bool
19099	done, err = future.Done(client)
19100	if err != nil {
19101		err = autorest.NewErrorWithError(err, "network.ServiceEndpointPoliciesUpdateFuture", "Result", future.Response(), "Polling failure")
19102		return
19103	}
19104	if !done {
19105		err = azure.NewAsyncOpIncompleteError("network.ServiceEndpointPoliciesUpdateFuture")
19106		return
19107	}
19108	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
19109	if sep.Response.Response, err = future.GetResult(sender); err == nil && sep.Response.Response.StatusCode != http.StatusNoContent {
19110		sep, err = client.UpdateResponder(sep.Response.Response)
19111		if err != nil {
19112			err = autorest.NewErrorWithError(err, "network.ServiceEndpointPoliciesUpdateFuture", "Result", sep.Response.Response, "Failure responding to request")
19113		}
19114	}
19115	return
19116}
19117
19118// ServiceEndpointPolicy service End point policy resource.
19119type ServiceEndpointPolicy struct {
19120	autorest.Response `json:"-"`
19121	// ServiceEndpointPolicyPropertiesFormat - Properties of the service end point policy
19122	*ServiceEndpointPolicyPropertiesFormat `json:"properties,omitempty"`
19123	// Etag - A unique read-only string that changes whenever the resource is updated.
19124	Etag *string `json:"etag,omitempty"`
19125	// ID - Resource ID.
19126	ID *string `json:"id,omitempty"`
19127	// Name - Resource name.
19128	Name *string `json:"name,omitempty"`
19129	// Type - Resource type.
19130	Type *string `json:"type,omitempty"`
19131	// Location - Resource location.
19132	Location *string `json:"location,omitempty"`
19133	// Tags - Resource tags.
19134	Tags map[string]*string `json:"tags"`
19135}
19136
19137// MarshalJSON is the custom marshaler for ServiceEndpointPolicy.
19138func (sep ServiceEndpointPolicy) MarshalJSON() ([]byte, error) {
19139	objectMap := make(map[string]interface{})
19140	if sep.ServiceEndpointPolicyPropertiesFormat != nil {
19141		objectMap["properties"] = sep.ServiceEndpointPolicyPropertiesFormat
19142	}
19143	if sep.Etag != nil {
19144		objectMap["etag"] = sep.Etag
19145	}
19146	if sep.ID != nil {
19147		objectMap["id"] = sep.ID
19148	}
19149	if sep.Name != nil {
19150		objectMap["name"] = sep.Name
19151	}
19152	if sep.Type != nil {
19153		objectMap["type"] = sep.Type
19154	}
19155	if sep.Location != nil {
19156		objectMap["location"] = sep.Location
19157	}
19158	if sep.Tags != nil {
19159		objectMap["tags"] = sep.Tags
19160	}
19161	return json.Marshal(objectMap)
19162}
19163
19164// UnmarshalJSON is the custom unmarshaler for ServiceEndpointPolicy struct.
19165func (sep *ServiceEndpointPolicy) UnmarshalJSON(body []byte) error {
19166	var m map[string]*json.RawMessage
19167	err := json.Unmarshal(body, &m)
19168	if err != nil {
19169		return err
19170	}
19171	for k, v := range m {
19172		switch k {
19173		case "properties":
19174			if v != nil {
19175				var serviceEndpointPolicyPropertiesFormat ServiceEndpointPolicyPropertiesFormat
19176				err = json.Unmarshal(*v, &serviceEndpointPolicyPropertiesFormat)
19177				if err != nil {
19178					return err
19179				}
19180				sep.ServiceEndpointPolicyPropertiesFormat = &serviceEndpointPolicyPropertiesFormat
19181			}
19182		case "etag":
19183			if v != nil {
19184				var etag string
19185				err = json.Unmarshal(*v, &etag)
19186				if err != nil {
19187					return err
19188				}
19189				sep.Etag = &etag
19190			}
19191		case "id":
19192			if v != nil {
19193				var ID string
19194				err = json.Unmarshal(*v, &ID)
19195				if err != nil {
19196					return err
19197				}
19198				sep.ID = &ID
19199			}
19200		case "name":
19201			if v != nil {
19202				var name string
19203				err = json.Unmarshal(*v, &name)
19204				if err != nil {
19205					return err
19206				}
19207				sep.Name = &name
19208			}
19209		case "type":
19210			if v != nil {
19211				var typeVar string
19212				err = json.Unmarshal(*v, &typeVar)
19213				if err != nil {
19214					return err
19215				}
19216				sep.Type = &typeVar
19217			}
19218		case "location":
19219			if v != nil {
19220				var location string
19221				err = json.Unmarshal(*v, &location)
19222				if err != nil {
19223					return err
19224				}
19225				sep.Location = &location
19226			}
19227		case "tags":
19228			if v != nil {
19229				var tags map[string]*string
19230				err = json.Unmarshal(*v, &tags)
19231				if err != nil {
19232					return err
19233				}
19234				sep.Tags = tags
19235			}
19236		}
19237	}
19238
19239	return nil
19240}
19241
19242// ServiceEndpointPolicyDefinition service Endpoint policy definitions.
19243type ServiceEndpointPolicyDefinition struct {
19244	autorest.Response `json:"-"`
19245	// ServiceEndpointPolicyDefinitionPropertiesFormat - Properties of the service endpoint policy definition
19246	*ServiceEndpointPolicyDefinitionPropertiesFormat `json:"properties,omitempty"`
19247	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
19248	Name *string `json:"name,omitempty"`
19249	// Etag - A unique read-only string that changes whenever the resource is updated.
19250	Etag *string `json:"etag,omitempty"`
19251	// ID - Resource ID.
19252	ID *string `json:"id,omitempty"`
19253}
19254
19255// MarshalJSON is the custom marshaler for ServiceEndpointPolicyDefinition.
19256func (sepd ServiceEndpointPolicyDefinition) MarshalJSON() ([]byte, error) {
19257	objectMap := make(map[string]interface{})
19258	if sepd.ServiceEndpointPolicyDefinitionPropertiesFormat != nil {
19259		objectMap["properties"] = sepd.ServiceEndpointPolicyDefinitionPropertiesFormat
19260	}
19261	if sepd.Name != nil {
19262		objectMap["name"] = sepd.Name
19263	}
19264	if sepd.Etag != nil {
19265		objectMap["etag"] = sepd.Etag
19266	}
19267	if sepd.ID != nil {
19268		objectMap["id"] = sepd.ID
19269	}
19270	return json.Marshal(objectMap)
19271}
19272
19273// UnmarshalJSON is the custom unmarshaler for ServiceEndpointPolicyDefinition struct.
19274func (sepd *ServiceEndpointPolicyDefinition) UnmarshalJSON(body []byte) error {
19275	var m map[string]*json.RawMessage
19276	err := json.Unmarshal(body, &m)
19277	if err != nil {
19278		return err
19279	}
19280	for k, v := range m {
19281		switch k {
19282		case "properties":
19283			if v != nil {
19284				var serviceEndpointPolicyDefinitionPropertiesFormat ServiceEndpointPolicyDefinitionPropertiesFormat
19285				err = json.Unmarshal(*v, &serviceEndpointPolicyDefinitionPropertiesFormat)
19286				if err != nil {
19287					return err
19288				}
19289				sepd.ServiceEndpointPolicyDefinitionPropertiesFormat = &serviceEndpointPolicyDefinitionPropertiesFormat
19290			}
19291		case "name":
19292			if v != nil {
19293				var name string
19294				err = json.Unmarshal(*v, &name)
19295				if err != nil {
19296					return err
19297				}
19298				sepd.Name = &name
19299			}
19300		case "etag":
19301			if v != nil {
19302				var etag string
19303				err = json.Unmarshal(*v, &etag)
19304				if err != nil {
19305					return err
19306				}
19307				sepd.Etag = &etag
19308			}
19309		case "id":
19310			if v != nil {
19311				var ID string
19312				err = json.Unmarshal(*v, &ID)
19313				if err != nil {
19314					return err
19315				}
19316				sepd.ID = &ID
19317			}
19318		}
19319	}
19320
19321	return nil
19322}
19323
19324// ServiceEndpointPolicyDefinitionListResult response for ListServiceEndpointPolicyDefinition API service call.
19325// Retrieves all service endpoint policy definition that belongs to a service endpoint policy.
19326type ServiceEndpointPolicyDefinitionListResult struct {
19327	autorest.Response `json:"-"`
19328	// Value - The service endpoint policy definition in a service endpoint policy.
19329	Value *[]ServiceEndpointPolicyDefinition `json:"value,omitempty"`
19330	// NextLink - The URL to get the next set of results.
19331	NextLink *string `json:"nextLink,omitempty"`
19332}
19333
19334// ServiceEndpointPolicyDefinitionListResultIterator provides access to a complete listing of
19335// ServiceEndpointPolicyDefinition values.
19336type ServiceEndpointPolicyDefinitionListResultIterator struct {
19337	i    int
19338	page ServiceEndpointPolicyDefinitionListResultPage
19339}
19340
19341// Next advances to the next value.  If there was an error making
19342// the request the iterator does not advance and the error is returned.
19343func (iter *ServiceEndpointPolicyDefinitionListResultIterator) Next() error {
19344	iter.i++
19345	if iter.i < len(iter.page.Values()) {
19346		return nil
19347	}
19348	err := iter.page.Next()
19349	if err != nil {
19350		iter.i--
19351		return err
19352	}
19353	iter.i = 0
19354	return nil
19355}
19356
19357// NotDone returns true if the enumeration should be started or is not yet complete.
19358func (iter ServiceEndpointPolicyDefinitionListResultIterator) NotDone() bool {
19359	return iter.page.NotDone() && iter.i < len(iter.page.Values())
19360}
19361
19362// Response returns the raw server response from the last page request.
19363func (iter ServiceEndpointPolicyDefinitionListResultIterator) Response() ServiceEndpointPolicyDefinitionListResult {
19364	return iter.page.Response()
19365}
19366
19367// Value returns the current value or a zero-initialized value if the
19368// iterator has advanced beyond the end of the collection.
19369func (iter ServiceEndpointPolicyDefinitionListResultIterator) Value() ServiceEndpointPolicyDefinition {
19370	if !iter.page.NotDone() {
19371		return ServiceEndpointPolicyDefinition{}
19372	}
19373	return iter.page.Values()[iter.i]
19374}
19375
19376// IsEmpty returns true if the ListResult contains no values.
19377func (sepdlr ServiceEndpointPolicyDefinitionListResult) IsEmpty() bool {
19378	return sepdlr.Value == nil || len(*sepdlr.Value) == 0
19379}
19380
19381// serviceEndpointPolicyDefinitionListResultPreparer prepares a request to retrieve the next set of results.
19382// It returns nil if no more results exist.
19383func (sepdlr ServiceEndpointPolicyDefinitionListResult) serviceEndpointPolicyDefinitionListResultPreparer() (*http.Request, error) {
19384	if sepdlr.NextLink == nil || len(to.String(sepdlr.NextLink)) < 1 {
19385		return nil, nil
19386	}
19387	return autorest.Prepare(&http.Request{},
19388		autorest.AsJSON(),
19389		autorest.AsGet(),
19390		autorest.WithBaseURL(to.String(sepdlr.NextLink)))
19391}
19392
19393// ServiceEndpointPolicyDefinitionListResultPage contains a page of ServiceEndpointPolicyDefinition values.
19394type ServiceEndpointPolicyDefinitionListResultPage struct {
19395	fn     func(ServiceEndpointPolicyDefinitionListResult) (ServiceEndpointPolicyDefinitionListResult, error)
19396	sepdlr ServiceEndpointPolicyDefinitionListResult
19397}
19398
19399// Next advances to the next page of values.  If there was an error making
19400// the request the page does not advance and the error is returned.
19401func (page *ServiceEndpointPolicyDefinitionListResultPage) Next() error {
19402	next, err := page.fn(page.sepdlr)
19403	if err != nil {
19404		return err
19405	}
19406	page.sepdlr = next
19407	return nil
19408}
19409
19410// NotDone returns true if the page enumeration should be started or is not yet complete.
19411func (page ServiceEndpointPolicyDefinitionListResultPage) NotDone() bool {
19412	return !page.sepdlr.IsEmpty()
19413}
19414
19415// Response returns the raw server response from the last page request.
19416func (page ServiceEndpointPolicyDefinitionListResultPage) Response() ServiceEndpointPolicyDefinitionListResult {
19417	return page.sepdlr
19418}
19419
19420// Values returns the slice of values for the current page or nil if there are no values.
19421func (page ServiceEndpointPolicyDefinitionListResultPage) Values() []ServiceEndpointPolicyDefinition {
19422	if page.sepdlr.IsEmpty() {
19423		return nil
19424	}
19425	return *page.sepdlr.Value
19426}
19427
19428// ServiceEndpointPolicyDefinitionPropertiesFormat service Endpoint policy definition resource.
19429type ServiceEndpointPolicyDefinitionPropertiesFormat struct {
19430	// Description - A description for this rule. Restricted to 140 chars.
19431	Description *string `json:"description,omitempty"`
19432	// Service - service endpoint name.
19433	Service *string `json:"service,omitempty"`
19434	// ServiceResources - A list of service resources.
19435	ServiceResources *[]string `json:"serviceResources,omitempty"`
19436	// ProvisioningState - The provisioning state of the service end point policy definition. Possible values are: 'Updating', 'Deleting', and 'Failed'.
19437	ProvisioningState *string `json:"provisioningState,omitempty"`
19438}
19439
19440// ServiceEndpointPolicyDefinitionsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of
19441// a long-running operation.
19442type ServiceEndpointPolicyDefinitionsCreateOrUpdateFuture struct {
19443	azure.Future
19444}
19445
19446// Result returns the result of the asynchronous operation.
19447// If the operation has not completed it will return an error.
19448func (future *ServiceEndpointPolicyDefinitionsCreateOrUpdateFuture) Result(client ServiceEndpointPolicyDefinitionsClient) (sepd ServiceEndpointPolicyDefinition, err error) {
19449	var done bool
19450	done, err = future.Done(client)
19451	if err != nil {
19452		err = autorest.NewErrorWithError(err, "network.ServiceEndpointPolicyDefinitionsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
19453		return
19454	}
19455	if !done {
19456		err = azure.NewAsyncOpIncompleteError("network.ServiceEndpointPolicyDefinitionsCreateOrUpdateFuture")
19457		return
19458	}
19459	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
19460	if sepd.Response.Response, err = future.GetResult(sender); err == nil && sepd.Response.Response.StatusCode != http.StatusNoContent {
19461		sepd, err = client.CreateOrUpdateResponder(sepd.Response.Response)
19462		if err != nil {
19463			err = autorest.NewErrorWithError(err, "network.ServiceEndpointPolicyDefinitionsCreateOrUpdateFuture", "Result", sepd.Response.Response, "Failure responding to request")
19464		}
19465	}
19466	return
19467}
19468
19469// ServiceEndpointPolicyDefinitionsDeleteFuture an abstraction for monitoring and retrieving the results of a
19470// long-running operation.
19471type ServiceEndpointPolicyDefinitionsDeleteFuture struct {
19472	azure.Future
19473}
19474
19475// Result returns the result of the asynchronous operation.
19476// If the operation has not completed it will return an error.
19477func (future *ServiceEndpointPolicyDefinitionsDeleteFuture) Result(client ServiceEndpointPolicyDefinitionsClient) (ar autorest.Response, err error) {
19478	var done bool
19479	done, err = future.Done(client)
19480	if err != nil {
19481		err = autorest.NewErrorWithError(err, "network.ServiceEndpointPolicyDefinitionsDeleteFuture", "Result", future.Response(), "Polling failure")
19482		return
19483	}
19484	if !done {
19485		err = azure.NewAsyncOpIncompleteError("network.ServiceEndpointPolicyDefinitionsDeleteFuture")
19486		return
19487	}
19488	ar.Response = future.Response()
19489	return
19490}
19491
19492// ServiceEndpointPolicyListResult response for ListServiceEndpointPolicies API service call.
19493type ServiceEndpointPolicyListResult struct {
19494	autorest.Response `json:"-"`
19495	// Value - A list of ServiceEndpointPolicy resources.
19496	Value *[]ServiceEndpointPolicy `json:"value,omitempty"`
19497	// NextLink - The URL to get the next set of results.
19498	NextLink *string `json:"nextLink,omitempty"`
19499}
19500
19501// ServiceEndpointPolicyListResultIterator provides access to a complete listing of ServiceEndpointPolicy values.
19502type ServiceEndpointPolicyListResultIterator struct {
19503	i    int
19504	page ServiceEndpointPolicyListResultPage
19505}
19506
19507// Next advances to the next value.  If there was an error making
19508// the request the iterator does not advance and the error is returned.
19509func (iter *ServiceEndpointPolicyListResultIterator) Next() error {
19510	iter.i++
19511	if iter.i < len(iter.page.Values()) {
19512		return nil
19513	}
19514	err := iter.page.Next()
19515	if err != nil {
19516		iter.i--
19517		return err
19518	}
19519	iter.i = 0
19520	return nil
19521}
19522
19523// NotDone returns true if the enumeration should be started or is not yet complete.
19524func (iter ServiceEndpointPolicyListResultIterator) NotDone() bool {
19525	return iter.page.NotDone() && iter.i < len(iter.page.Values())
19526}
19527
19528// Response returns the raw server response from the last page request.
19529func (iter ServiceEndpointPolicyListResultIterator) Response() ServiceEndpointPolicyListResult {
19530	return iter.page.Response()
19531}
19532
19533// Value returns the current value or a zero-initialized value if the
19534// iterator has advanced beyond the end of the collection.
19535func (iter ServiceEndpointPolicyListResultIterator) Value() ServiceEndpointPolicy {
19536	if !iter.page.NotDone() {
19537		return ServiceEndpointPolicy{}
19538	}
19539	return iter.page.Values()[iter.i]
19540}
19541
19542// IsEmpty returns true if the ListResult contains no values.
19543func (seplr ServiceEndpointPolicyListResult) IsEmpty() bool {
19544	return seplr.Value == nil || len(*seplr.Value) == 0
19545}
19546
19547// serviceEndpointPolicyListResultPreparer prepares a request to retrieve the next set of results.
19548// It returns nil if no more results exist.
19549func (seplr ServiceEndpointPolicyListResult) serviceEndpointPolicyListResultPreparer() (*http.Request, error) {
19550	if seplr.NextLink == nil || len(to.String(seplr.NextLink)) < 1 {
19551		return nil, nil
19552	}
19553	return autorest.Prepare(&http.Request{},
19554		autorest.AsJSON(),
19555		autorest.AsGet(),
19556		autorest.WithBaseURL(to.String(seplr.NextLink)))
19557}
19558
19559// ServiceEndpointPolicyListResultPage contains a page of ServiceEndpointPolicy values.
19560type ServiceEndpointPolicyListResultPage struct {
19561	fn    func(ServiceEndpointPolicyListResult) (ServiceEndpointPolicyListResult, error)
19562	seplr ServiceEndpointPolicyListResult
19563}
19564
19565// Next advances to the next page of values.  If there was an error making
19566// the request the page does not advance and the error is returned.
19567func (page *ServiceEndpointPolicyListResultPage) Next() error {
19568	next, err := page.fn(page.seplr)
19569	if err != nil {
19570		return err
19571	}
19572	page.seplr = next
19573	return nil
19574}
19575
19576// NotDone returns true if the page enumeration should be started or is not yet complete.
19577func (page ServiceEndpointPolicyListResultPage) NotDone() bool {
19578	return !page.seplr.IsEmpty()
19579}
19580
19581// Response returns the raw server response from the last page request.
19582func (page ServiceEndpointPolicyListResultPage) Response() ServiceEndpointPolicyListResult {
19583	return page.seplr
19584}
19585
19586// Values returns the slice of values for the current page or nil if there are no values.
19587func (page ServiceEndpointPolicyListResultPage) Values() []ServiceEndpointPolicy {
19588	if page.seplr.IsEmpty() {
19589		return nil
19590	}
19591	return *page.seplr.Value
19592}
19593
19594// ServiceEndpointPolicyPropertiesFormat service Endpoint Policy resource.
19595type ServiceEndpointPolicyPropertiesFormat struct {
19596	// ServiceEndpointPolicyDefinitions - A collection of service endpoint policy definitions of the service endpoint policy.
19597	ServiceEndpointPolicyDefinitions *[]ServiceEndpointPolicyDefinition `json:"serviceEndpointPolicyDefinitions,omitempty"`
19598	// Subnets - A collection of references to subnets.
19599	Subnets *[]Subnet `json:"subnets,omitempty"`
19600	// ResourceGUID - The resource GUID property of the service endpoint policy resource.
19601	ResourceGUID *string `json:"resourceGuid,omitempty"`
19602	// ProvisioningState - The provisioning state of the service endpoint policy. Possible values are: 'Updating', 'Deleting', and 'Failed'.
19603	ProvisioningState *string `json:"provisioningState,omitempty"`
19604}
19605
19606// ServiceEndpointPropertiesFormat the service endpoint properties.
19607type ServiceEndpointPropertiesFormat struct {
19608	// Service - The type of the endpoint service.
19609	Service *string `json:"service,omitempty"`
19610	// Locations - A list of locations.
19611	Locations *[]string `json:"locations,omitempty"`
19612	// ProvisioningState - The provisioning state of the resource.
19613	ProvisioningState *string `json:"provisioningState,omitempty"`
19614}
19615
19616// String ...
19617type String struct {
19618	autorest.Response `json:"-"`
19619	Value             *string `json:"value,omitempty"`
19620}
19621
19622// Subnet subnet in a virtual network resource.
19623type Subnet struct {
19624	autorest.Response `json:"-"`
19625	// SubnetPropertiesFormat - Properties of the subnet.
19626	*SubnetPropertiesFormat `json:"properties,omitempty"`
19627	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
19628	Name *string `json:"name,omitempty"`
19629	// Etag - A unique read-only string that changes whenever the resource is updated.
19630	Etag *string `json:"etag,omitempty"`
19631	// ID - Resource ID.
19632	ID *string `json:"id,omitempty"`
19633}
19634
19635// MarshalJSON is the custom marshaler for Subnet.
19636func (s Subnet) MarshalJSON() ([]byte, error) {
19637	objectMap := make(map[string]interface{})
19638	if s.SubnetPropertiesFormat != nil {
19639		objectMap["properties"] = s.SubnetPropertiesFormat
19640	}
19641	if s.Name != nil {
19642		objectMap["name"] = s.Name
19643	}
19644	if s.Etag != nil {
19645		objectMap["etag"] = s.Etag
19646	}
19647	if s.ID != nil {
19648		objectMap["id"] = s.ID
19649	}
19650	return json.Marshal(objectMap)
19651}
19652
19653// UnmarshalJSON is the custom unmarshaler for Subnet struct.
19654func (s *Subnet) UnmarshalJSON(body []byte) error {
19655	var m map[string]*json.RawMessage
19656	err := json.Unmarshal(body, &m)
19657	if err != nil {
19658		return err
19659	}
19660	for k, v := range m {
19661		switch k {
19662		case "properties":
19663			if v != nil {
19664				var subnetPropertiesFormat SubnetPropertiesFormat
19665				err = json.Unmarshal(*v, &subnetPropertiesFormat)
19666				if err != nil {
19667					return err
19668				}
19669				s.SubnetPropertiesFormat = &subnetPropertiesFormat
19670			}
19671		case "name":
19672			if v != nil {
19673				var name string
19674				err = json.Unmarshal(*v, &name)
19675				if err != nil {
19676					return err
19677				}
19678				s.Name = &name
19679			}
19680		case "etag":
19681			if v != nil {
19682				var etag string
19683				err = json.Unmarshal(*v, &etag)
19684				if err != nil {
19685					return err
19686				}
19687				s.Etag = &etag
19688			}
19689		case "id":
19690			if v != nil {
19691				var ID string
19692				err = json.Unmarshal(*v, &ID)
19693				if err != nil {
19694					return err
19695				}
19696				s.ID = &ID
19697			}
19698		}
19699	}
19700
19701	return nil
19702}
19703
19704// SubnetAssociation network interface and its custom security rules.
19705type SubnetAssociation struct {
19706	// ID - Subnet ID.
19707	ID *string `json:"id,omitempty"`
19708	// SecurityRules - Collection of custom security rules.
19709	SecurityRules *[]SecurityRule `json:"securityRules,omitempty"`
19710}
19711
19712// SubnetListResult response for ListSubnets API service callRetrieves all subnet that belongs to a virtual network
19713type SubnetListResult struct {
19714	autorest.Response `json:"-"`
19715	// Value - The subnets in a virtual network.
19716	Value *[]Subnet `json:"value,omitempty"`
19717	// NextLink - The URL to get the next set of results.
19718	NextLink *string `json:"nextLink,omitempty"`
19719}
19720
19721// SubnetListResultIterator provides access to a complete listing of Subnet values.
19722type SubnetListResultIterator struct {
19723	i    int
19724	page SubnetListResultPage
19725}
19726
19727// Next advances to the next value.  If there was an error making
19728// the request the iterator does not advance and the error is returned.
19729func (iter *SubnetListResultIterator) Next() error {
19730	iter.i++
19731	if iter.i < len(iter.page.Values()) {
19732		return nil
19733	}
19734	err := iter.page.Next()
19735	if err != nil {
19736		iter.i--
19737		return err
19738	}
19739	iter.i = 0
19740	return nil
19741}
19742
19743// NotDone returns true if the enumeration should be started or is not yet complete.
19744func (iter SubnetListResultIterator) NotDone() bool {
19745	return iter.page.NotDone() && iter.i < len(iter.page.Values())
19746}
19747
19748// Response returns the raw server response from the last page request.
19749func (iter SubnetListResultIterator) Response() SubnetListResult {
19750	return iter.page.Response()
19751}
19752
19753// Value returns the current value or a zero-initialized value if the
19754// iterator has advanced beyond the end of the collection.
19755func (iter SubnetListResultIterator) Value() Subnet {
19756	if !iter.page.NotDone() {
19757		return Subnet{}
19758	}
19759	return iter.page.Values()[iter.i]
19760}
19761
19762// IsEmpty returns true if the ListResult contains no values.
19763func (slr SubnetListResult) IsEmpty() bool {
19764	return slr.Value == nil || len(*slr.Value) == 0
19765}
19766
19767// subnetListResultPreparer prepares a request to retrieve the next set of results.
19768// It returns nil if no more results exist.
19769func (slr SubnetListResult) subnetListResultPreparer() (*http.Request, error) {
19770	if slr.NextLink == nil || len(to.String(slr.NextLink)) < 1 {
19771		return nil, nil
19772	}
19773	return autorest.Prepare(&http.Request{},
19774		autorest.AsJSON(),
19775		autorest.AsGet(),
19776		autorest.WithBaseURL(to.String(slr.NextLink)))
19777}
19778
19779// SubnetListResultPage contains a page of Subnet values.
19780type SubnetListResultPage struct {
19781	fn  func(SubnetListResult) (SubnetListResult, error)
19782	slr SubnetListResult
19783}
19784
19785// Next advances to the next page of values.  If there was an error making
19786// the request the page does not advance and the error is returned.
19787func (page *SubnetListResultPage) Next() error {
19788	next, err := page.fn(page.slr)
19789	if err != nil {
19790		return err
19791	}
19792	page.slr = next
19793	return nil
19794}
19795
19796// NotDone returns true if the page enumeration should be started or is not yet complete.
19797func (page SubnetListResultPage) NotDone() bool {
19798	return !page.slr.IsEmpty()
19799}
19800
19801// Response returns the raw server response from the last page request.
19802func (page SubnetListResultPage) Response() SubnetListResult {
19803	return page.slr
19804}
19805
19806// Values returns the slice of values for the current page or nil if there are no values.
19807func (page SubnetListResultPage) Values() []Subnet {
19808	if page.slr.IsEmpty() {
19809		return nil
19810	}
19811	return *page.slr.Value
19812}
19813
19814// SubnetPropertiesFormat properties of the subnet.
19815type SubnetPropertiesFormat struct {
19816	// AddressPrefix - The address prefix for the subnet.
19817	AddressPrefix *string `json:"addressPrefix,omitempty"`
19818	// AddressPrefixes - List of  address prefixes for the subnet.
19819	AddressPrefixes *[]string `json:"addressPrefixes,omitempty"`
19820	// NetworkSecurityGroup - The reference of the NetworkSecurityGroup resource.
19821	NetworkSecurityGroup *SecurityGroup `json:"networkSecurityGroup,omitempty"`
19822	// RouteTable - The reference of the RouteTable resource.
19823	RouteTable *RouteTable `json:"routeTable,omitempty"`
19824	// ServiceEndpoints - An array of service endpoints.
19825	ServiceEndpoints *[]ServiceEndpointPropertiesFormat `json:"serviceEndpoints,omitempty"`
19826	// ServiceEndpointPolicies - An array of service endpoint policies.
19827	ServiceEndpointPolicies *[]ServiceEndpointPolicy `json:"serviceEndpointPolicies,omitempty"`
19828	// InterfaceEndpoints - An array of references to interface endpoints
19829	InterfaceEndpoints *[]InterfaceEndpoint `json:"interfaceEndpoints,omitempty"`
19830	// IPConfigurations - Gets an array of references to the network interface IP configurations using subnet.
19831	IPConfigurations *[]IPConfiguration `json:"ipConfigurations,omitempty"`
19832	// IPConfigurationProfiles - Array of IP configuration profiles which reference this subnet.
19833	IPConfigurationProfiles *[]IPConfigurationProfile `json:"ipConfigurationProfiles,omitempty"`
19834	// ResourceNavigationLinks - Gets an array of references to the external resources using subnet.
19835	ResourceNavigationLinks *[]ResourceNavigationLink `json:"resourceNavigationLinks,omitempty"`
19836	// ServiceAssociationLinks - Gets an array of references to services injecting into this subnet.
19837	ServiceAssociationLinks *[]ServiceAssociationLink `json:"serviceAssociationLinks,omitempty"`
19838	// Delegations - Gets an array of references to the delegations on the subnet.
19839	Delegations *[]Delegation `json:"delegations,omitempty"`
19840	// Purpose - A read-only string identifying the intention of use for this subnet based on delegations and other user-defined properties.
19841	Purpose *string `json:"purpose,omitempty"`
19842	// ProvisioningState - The provisioning state of the resource.
19843	ProvisioningState *string `json:"provisioningState,omitempty"`
19844}
19845
19846// SubnetsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
19847// operation.
19848type SubnetsCreateOrUpdateFuture struct {
19849	azure.Future
19850}
19851
19852// Result returns the result of the asynchronous operation.
19853// If the operation has not completed it will return an error.
19854func (future *SubnetsCreateOrUpdateFuture) Result(client SubnetsClient) (s Subnet, err error) {
19855	var done bool
19856	done, err = future.Done(client)
19857	if err != nil {
19858		err = autorest.NewErrorWithError(err, "network.SubnetsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
19859		return
19860	}
19861	if !done {
19862		err = azure.NewAsyncOpIncompleteError("network.SubnetsCreateOrUpdateFuture")
19863		return
19864	}
19865	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
19866	if s.Response.Response, err = future.GetResult(sender); err == nil && s.Response.Response.StatusCode != http.StatusNoContent {
19867		s, err = client.CreateOrUpdateResponder(s.Response.Response)
19868		if err != nil {
19869			err = autorest.NewErrorWithError(err, "network.SubnetsCreateOrUpdateFuture", "Result", s.Response.Response, "Failure responding to request")
19870		}
19871	}
19872	return
19873}
19874
19875// SubnetsDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
19876type SubnetsDeleteFuture struct {
19877	azure.Future
19878}
19879
19880// Result returns the result of the asynchronous operation.
19881// If the operation has not completed it will return an error.
19882func (future *SubnetsDeleteFuture) Result(client SubnetsClient) (ar autorest.Response, err error) {
19883	var done bool
19884	done, err = future.Done(client)
19885	if err != nil {
19886		err = autorest.NewErrorWithError(err, "network.SubnetsDeleteFuture", "Result", future.Response(), "Polling failure")
19887		return
19888	}
19889	if !done {
19890		err = azure.NewAsyncOpIncompleteError("network.SubnetsDeleteFuture")
19891		return
19892	}
19893	ar.Response = future.Response()
19894	return
19895}
19896
19897// SubResource reference to another subresource.
19898type SubResource struct {
19899	// ID - Resource ID.
19900	ID *string `json:"id,omitempty"`
19901}
19902
19903// TagsObject tags object for patch operations.
19904type TagsObject struct {
19905	// Tags - Resource tags.
19906	Tags map[string]*string `json:"tags"`
19907}
19908
19909// MarshalJSON is the custom marshaler for TagsObject.
19910func (toVar TagsObject) MarshalJSON() ([]byte, error) {
19911	objectMap := make(map[string]interface{})
19912	if toVar.Tags != nil {
19913		objectMap["tags"] = toVar.Tags
19914	}
19915	return json.Marshal(objectMap)
19916}
19917
19918// Topology topology of the specified resource group.
19919type Topology struct {
19920	autorest.Response `json:"-"`
19921	// ID - GUID representing the operation id.
19922	ID *string `json:"id,omitempty"`
19923	// CreatedDateTime - The datetime when the topology was initially created for the resource group.
19924	CreatedDateTime *date.Time `json:"createdDateTime,omitempty"`
19925	// LastModified - The datetime when the topology was last modified.
19926	LastModified *date.Time          `json:"lastModified,omitempty"`
19927	Resources    *[]TopologyResource `json:"resources,omitempty"`
19928}
19929
19930// TopologyAssociation resources that have an association with the parent resource.
19931type TopologyAssociation struct {
19932	// Name - The name of the resource that is associated with the parent resource.
19933	Name *string `json:"name,omitempty"`
19934	// ResourceID - The ID of the resource that is associated with the parent resource.
19935	ResourceID *string `json:"resourceId,omitempty"`
19936	// AssociationType - The association type of the child resource to the parent resource. Possible values include: 'Associated', 'Contains'
19937	AssociationType AssociationType `json:"associationType,omitempty"`
19938}
19939
19940// TopologyParameters parameters that define the representation of topology.
19941type TopologyParameters struct {
19942	// TargetResourceGroupName - The name of the target resource group to perform topology on.
19943	TargetResourceGroupName *string `json:"targetResourceGroupName,omitempty"`
19944	// TargetVirtualNetwork - The reference of the Virtual Network resource.
19945	TargetVirtualNetwork *SubResource `json:"targetVirtualNetwork,omitempty"`
19946	// TargetSubnet - The reference of the Subnet resource.
19947	TargetSubnet *SubResource `json:"targetSubnet,omitempty"`
19948}
19949
19950// TopologyResource the network resource topology information for the given resource group.
19951type TopologyResource struct {
19952	// Name - Name of the resource.
19953	Name *string `json:"name,omitempty"`
19954	// ID - ID of the resource.
19955	ID *string `json:"id,omitempty"`
19956	// Location - Resource location.
19957	Location *string `json:"location,omitempty"`
19958	// Associations - Holds the associations the resource has with other resources in the resource group.
19959	Associations *[]TopologyAssociation `json:"associations,omitempty"`
19960}
19961
19962// TrafficAnalyticsConfigurationProperties parameters that define the configuration of traffic analytics.
19963type TrafficAnalyticsConfigurationProperties struct {
19964	// Enabled - Flag to enable/disable traffic analytics.
19965	Enabled *bool `json:"enabled,omitempty"`
19966	// WorkspaceID - The resource guid of the attached workspace
19967	WorkspaceID *string `json:"workspaceId,omitempty"`
19968	// WorkspaceRegion - The location of the attached workspace
19969	WorkspaceRegion *string `json:"workspaceRegion,omitempty"`
19970	// WorkspaceResourceID - Resource Id of the attached workspace
19971	WorkspaceResourceID *string `json:"workspaceResourceId,omitempty"`
19972}
19973
19974// TrafficAnalyticsProperties parameters that define the configuration of traffic analytics.
19975type TrafficAnalyticsProperties struct {
19976	NetworkWatcherFlowAnalyticsConfiguration *TrafficAnalyticsConfigurationProperties `json:"networkWatcherFlowAnalyticsConfiguration,omitempty"`
19977}
19978
19979// TrafficQuery parameters to compare with network configuration.
19980type TrafficQuery struct {
19981	// Direction - The direction of the traffic. Accepted values are 'Inbound' and 'Outbound'. Possible values include: 'Inbound', 'Outbound'
19982	Direction Direction `json:"direction,omitempty"`
19983	// Protocol - Protocol to be verified on. Accepted values are '*', TCP, UDP.
19984	Protocol *string `json:"protocol,omitempty"`
19985	// Source - Traffic source. Accepted values are '*', IP Address/CIDR, Service Tag.
19986	Source *string `json:"source,omitempty"`
19987	// Destination - Traffic destination. Accepted values are: '*', IP Address/CIDR, Service Tag.
19988	Destination *string `json:"destination,omitempty"`
19989	// DestinationPort - Traffice destination port. Accepted values are '*', port (for example, 3389) and port range (for example, 80-100).
19990	DestinationPort *string `json:"destinationPort,omitempty"`
19991}
19992
19993// TroubleshootingDetails information gained from troubleshooting of specified resource.
19994type TroubleshootingDetails struct {
19995	// ID - The id of the get troubleshoot operation.
19996	ID *string `json:"id,omitempty"`
19997	// ReasonType - Reason type of failure.
19998	ReasonType *string `json:"reasonType,omitempty"`
19999	// Summary - A summary of troubleshooting.
20000	Summary *string `json:"summary,omitempty"`
20001	// Detail - Details on troubleshooting results.
20002	Detail *string `json:"detail,omitempty"`
20003	// RecommendedActions - List of recommended actions.
20004	RecommendedActions *[]TroubleshootingRecommendedActions `json:"recommendedActions,omitempty"`
20005}
20006
20007// TroubleshootingParameters parameters that define the resource to troubleshoot.
20008type TroubleshootingParameters struct {
20009	// TargetResourceID - The target resource to troubleshoot.
20010	TargetResourceID           *string `json:"targetResourceId,omitempty"`
20011	*TroubleshootingProperties `json:"properties,omitempty"`
20012}
20013
20014// MarshalJSON is the custom marshaler for TroubleshootingParameters.
20015func (tp TroubleshootingParameters) MarshalJSON() ([]byte, error) {
20016	objectMap := make(map[string]interface{})
20017	if tp.TargetResourceID != nil {
20018		objectMap["targetResourceId"] = tp.TargetResourceID
20019	}
20020	if tp.TroubleshootingProperties != nil {
20021		objectMap["properties"] = tp.TroubleshootingProperties
20022	}
20023	return json.Marshal(objectMap)
20024}
20025
20026// UnmarshalJSON is the custom unmarshaler for TroubleshootingParameters struct.
20027func (tp *TroubleshootingParameters) UnmarshalJSON(body []byte) error {
20028	var m map[string]*json.RawMessage
20029	err := json.Unmarshal(body, &m)
20030	if err != nil {
20031		return err
20032	}
20033	for k, v := range m {
20034		switch k {
20035		case "targetResourceId":
20036			if v != nil {
20037				var targetResourceID string
20038				err = json.Unmarshal(*v, &targetResourceID)
20039				if err != nil {
20040					return err
20041				}
20042				tp.TargetResourceID = &targetResourceID
20043			}
20044		case "properties":
20045			if v != nil {
20046				var troubleshootingProperties TroubleshootingProperties
20047				err = json.Unmarshal(*v, &troubleshootingProperties)
20048				if err != nil {
20049					return err
20050				}
20051				tp.TroubleshootingProperties = &troubleshootingProperties
20052			}
20053		}
20054	}
20055
20056	return nil
20057}
20058
20059// TroubleshootingProperties storage location provided for troubleshoot.
20060type TroubleshootingProperties struct {
20061	// StorageID - The ID for the storage account to save the troubleshoot result.
20062	StorageID *string `json:"storageId,omitempty"`
20063	// StoragePath - The path to the blob to save the troubleshoot result in.
20064	StoragePath *string `json:"storagePath,omitempty"`
20065}
20066
20067// TroubleshootingRecommendedActions recommended actions based on discovered issues.
20068type TroubleshootingRecommendedActions struct {
20069	// ActionID - ID of the recommended action.
20070	ActionID *string `json:"actionId,omitempty"`
20071	// ActionText - Description of recommended actions.
20072	ActionText *string `json:"actionText,omitempty"`
20073	// ActionURI - The uri linking to a documentation for the recommended troubleshooting actions.
20074	ActionURI *string `json:"actionUri,omitempty"`
20075	// ActionURIText - The information from the URI for the recommended troubleshooting actions.
20076	ActionURIText *string `json:"actionUriText,omitempty"`
20077}
20078
20079// TroubleshootingResult troubleshooting information gained from specified resource.
20080type TroubleshootingResult struct {
20081	autorest.Response `json:"-"`
20082	// StartTime - The start time of the troubleshooting.
20083	StartTime *date.Time `json:"startTime,omitempty"`
20084	// EndTime - The end time of the troubleshooting.
20085	EndTime *date.Time `json:"endTime,omitempty"`
20086	// Code - The result code of the troubleshooting.
20087	Code *string `json:"code,omitempty"`
20088	// Results - Information from troubleshooting.
20089	Results *[]TroubleshootingDetails `json:"results,omitempty"`
20090}
20091
20092// TunnelConnectionHealth virtualNetworkGatewayConnection properties
20093type TunnelConnectionHealth struct {
20094	// Tunnel - Tunnel name.
20095	Tunnel *string `json:"tunnel,omitempty"`
20096	// ConnectionStatus - Virtual network Gateway connection status. Possible values include: 'VirtualNetworkGatewayConnectionStatusUnknown', 'VirtualNetworkGatewayConnectionStatusConnecting', 'VirtualNetworkGatewayConnectionStatusConnected', 'VirtualNetworkGatewayConnectionStatusNotConnected'
20097	ConnectionStatus VirtualNetworkGatewayConnectionStatus `json:"connectionStatus,omitempty"`
20098	// IngressBytesTransferred - The Ingress Bytes Transferred in this connection
20099	IngressBytesTransferred *int64 `json:"ingressBytesTransferred,omitempty"`
20100	// EgressBytesTransferred - The Egress Bytes Transferred in this connection
20101	EgressBytesTransferred *int64 `json:"egressBytesTransferred,omitempty"`
20102	// LastConnectionEstablishedUtcTime - The time at which connection was established in Utc format.
20103	LastConnectionEstablishedUtcTime *string `json:"lastConnectionEstablishedUtcTime,omitempty"`
20104}
20105
20106// Usage describes network resource usage.
20107type Usage struct {
20108	// ID - Resource identifier.
20109	ID *string `json:"id,omitempty"`
20110	// Unit - An enum describing the unit of measurement.
20111	Unit *string `json:"unit,omitempty"`
20112	// CurrentValue - The current value of the usage.
20113	CurrentValue *int64 `json:"currentValue,omitempty"`
20114	// Limit - The limit of usage.
20115	Limit *int64 `json:"limit,omitempty"`
20116	// Name - The name of the type of usage.
20117	Name *UsageName `json:"name,omitempty"`
20118}
20119
20120// UsageName the usage names.
20121type UsageName struct {
20122	// Value - A string describing the resource name.
20123	Value *string `json:"value,omitempty"`
20124	// LocalizedValue - A localized string describing the resource name.
20125	LocalizedValue *string `json:"localizedValue,omitempty"`
20126}
20127
20128// UsagesListResult the list usages operation response.
20129type UsagesListResult struct {
20130	autorest.Response `json:"-"`
20131	// Value - The list network resource usages.
20132	Value *[]Usage `json:"value,omitempty"`
20133	// NextLink - URL to get the next set of results.
20134	NextLink *string `json:"nextLink,omitempty"`
20135}
20136
20137// UsagesListResultIterator provides access to a complete listing of Usage values.
20138type UsagesListResultIterator struct {
20139	i    int
20140	page UsagesListResultPage
20141}
20142
20143// Next advances to the next value.  If there was an error making
20144// the request the iterator does not advance and the error is returned.
20145func (iter *UsagesListResultIterator) Next() error {
20146	iter.i++
20147	if iter.i < len(iter.page.Values()) {
20148		return nil
20149	}
20150	err := iter.page.Next()
20151	if err != nil {
20152		iter.i--
20153		return err
20154	}
20155	iter.i = 0
20156	return nil
20157}
20158
20159// NotDone returns true if the enumeration should be started or is not yet complete.
20160func (iter UsagesListResultIterator) NotDone() bool {
20161	return iter.page.NotDone() && iter.i < len(iter.page.Values())
20162}
20163
20164// Response returns the raw server response from the last page request.
20165func (iter UsagesListResultIterator) Response() UsagesListResult {
20166	return iter.page.Response()
20167}
20168
20169// Value returns the current value or a zero-initialized value if the
20170// iterator has advanced beyond the end of the collection.
20171func (iter UsagesListResultIterator) Value() Usage {
20172	if !iter.page.NotDone() {
20173		return Usage{}
20174	}
20175	return iter.page.Values()[iter.i]
20176}
20177
20178// IsEmpty returns true if the ListResult contains no values.
20179func (ulr UsagesListResult) IsEmpty() bool {
20180	return ulr.Value == nil || len(*ulr.Value) == 0
20181}
20182
20183// usagesListResultPreparer prepares a request to retrieve the next set of results.
20184// It returns nil if no more results exist.
20185func (ulr UsagesListResult) usagesListResultPreparer() (*http.Request, error) {
20186	if ulr.NextLink == nil || len(to.String(ulr.NextLink)) < 1 {
20187		return nil, nil
20188	}
20189	return autorest.Prepare(&http.Request{},
20190		autorest.AsJSON(),
20191		autorest.AsGet(),
20192		autorest.WithBaseURL(to.String(ulr.NextLink)))
20193}
20194
20195// UsagesListResultPage contains a page of Usage values.
20196type UsagesListResultPage struct {
20197	fn  func(UsagesListResult) (UsagesListResult, error)
20198	ulr UsagesListResult
20199}
20200
20201// Next advances to the next page of values.  If there was an error making
20202// the request the page does not advance and the error is returned.
20203func (page *UsagesListResultPage) Next() error {
20204	next, err := page.fn(page.ulr)
20205	if err != nil {
20206		return err
20207	}
20208	page.ulr = next
20209	return nil
20210}
20211
20212// NotDone returns true if the page enumeration should be started or is not yet complete.
20213func (page UsagesListResultPage) NotDone() bool {
20214	return !page.ulr.IsEmpty()
20215}
20216
20217// Response returns the raw server response from the last page request.
20218func (page UsagesListResultPage) Response() UsagesListResult {
20219	return page.ulr
20220}
20221
20222// Values returns the slice of values for the current page or nil if there are no values.
20223func (page UsagesListResultPage) Values() []Usage {
20224	if page.ulr.IsEmpty() {
20225		return nil
20226	}
20227	return *page.ulr.Value
20228}
20229
20230// VerificationIPFlowParameters parameters that define the IP flow to be verified.
20231type VerificationIPFlowParameters struct {
20232	// TargetResourceID - The ID of the target resource to perform next-hop on.
20233	TargetResourceID *string `json:"targetResourceId,omitempty"`
20234	// Direction - The direction of the packet represented as a 5-tuple. Possible values include: 'Inbound', 'Outbound'
20235	Direction Direction `json:"direction,omitempty"`
20236	// Protocol - Protocol to be verified on. Possible values include: 'IPFlowProtocolTCP', 'IPFlowProtocolUDP'
20237	Protocol IPFlowProtocol `json:"protocol,omitempty"`
20238	// 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.
20239	LocalPort *string `json:"localPort,omitempty"`
20240	// 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.
20241	RemotePort *string `json:"remotePort,omitempty"`
20242	// LocalIPAddress - The local IP address. Acceptable values are valid IPv4 addresses.
20243	LocalIPAddress *string `json:"localIPAddress,omitempty"`
20244	// RemoteIPAddress - The remote IP address. Acceptable values are valid IPv4 addresses.
20245	RemoteIPAddress *string `json:"remoteIPAddress,omitempty"`
20246	// 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).
20247	TargetNicResourceID *string `json:"targetNicResourceId,omitempty"`
20248}
20249
20250// VerificationIPFlowResult results of IP flow verification on the target resource.
20251type VerificationIPFlowResult struct {
20252	autorest.Response `json:"-"`
20253	// Access - Indicates whether the traffic is allowed or denied. Possible values include: 'Allow', 'Deny'
20254	Access Access `json:"access,omitempty"`
20255	// RuleName - Name of the rule. If input is not matched against any security rule, it is not displayed.
20256	RuleName *string `json:"ruleName,omitempty"`
20257}
20258
20259// VirtualHub virtualHub Resource.
20260type VirtualHub struct {
20261	autorest.Response     `json:"-"`
20262	*VirtualHubProperties `json:"properties,omitempty"`
20263	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
20264	Etag *string `json:"etag,omitempty"`
20265	// ID - Resource ID.
20266	ID *string `json:"id,omitempty"`
20267	// Name - Resource name.
20268	Name *string `json:"name,omitempty"`
20269	// Type - Resource type.
20270	Type *string `json:"type,omitempty"`
20271	// Location - Resource location.
20272	Location *string `json:"location,omitempty"`
20273	// Tags - Resource tags.
20274	Tags map[string]*string `json:"tags"`
20275}
20276
20277// MarshalJSON is the custom marshaler for VirtualHub.
20278func (vh VirtualHub) MarshalJSON() ([]byte, error) {
20279	objectMap := make(map[string]interface{})
20280	if vh.VirtualHubProperties != nil {
20281		objectMap["properties"] = vh.VirtualHubProperties
20282	}
20283	if vh.Etag != nil {
20284		objectMap["etag"] = vh.Etag
20285	}
20286	if vh.ID != nil {
20287		objectMap["id"] = vh.ID
20288	}
20289	if vh.Name != nil {
20290		objectMap["name"] = vh.Name
20291	}
20292	if vh.Type != nil {
20293		objectMap["type"] = vh.Type
20294	}
20295	if vh.Location != nil {
20296		objectMap["location"] = vh.Location
20297	}
20298	if vh.Tags != nil {
20299		objectMap["tags"] = vh.Tags
20300	}
20301	return json.Marshal(objectMap)
20302}
20303
20304// UnmarshalJSON is the custom unmarshaler for VirtualHub struct.
20305func (vh *VirtualHub) UnmarshalJSON(body []byte) error {
20306	var m map[string]*json.RawMessage
20307	err := json.Unmarshal(body, &m)
20308	if err != nil {
20309		return err
20310	}
20311	for k, v := range m {
20312		switch k {
20313		case "properties":
20314			if v != nil {
20315				var virtualHubProperties VirtualHubProperties
20316				err = json.Unmarshal(*v, &virtualHubProperties)
20317				if err != nil {
20318					return err
20319				}
20320				vh.VirtualHubProperties = &virtualHubProperties
20321			}
20322		case "etag":
20323			if v != nil {
20324				var etag string
20325				err = json.Unmarshal(*v, &etag)
20326				if err != nil {
20327					return err
20328				}
20329				vh.Etag = &etag
20330			}
20331		case "id":
20332			if v != nil {
20333				var ID string
20334				err = json.Unmarshal(*v, &ID)
20335				if err != nil {
20336					return err
20337				}
20338				vh.ID = &ID
20339			}
20340		case "name":
20341			if v != nil {
20342				var name string
20343				err = json.Unmarshal(*v, &name)
20344				if err != nil {
20345					return err
20346				}
20347				vh.Name = &name
20348			}
20349		case "type":
20350			if v != nil {
20351				var typeVar string
20352				err = json.Unmarshal(*v, &typeVar)
20353				if err != nil {
20354					return err
20355				}
20356				vh.Type = &typeVar
20357			}
20358		case "location":
20359			if v != nil {
20360				var location string
20361				err = json.Unmarshal(*v, &location)
20362				if err != nil {
20363					return err
20364				}
20365				vh.Location = &location
20366			}
20367		case "tags":
20368			if v != nil {
20369				var tags map[string]*string
20370				err = json.Unmarshal(*v, &tags)
20371				if err != nil {
20372					return err
20373				}
20374				vh.Tags = tags
20375			}
20376		}
20377	}
20378
20379	return nil
20380}
20381
20382// VirtualHubID virtual Hub identifier.
20383type VirtualHubID struct {
20384	// ID - The resource URI for the Virtual Hub where the ExpressRoute gateway is or will be deployed. The Virtual Hub resource and the ExpressRoute gateway resource reside in the same subscription.
20385	ID *string `json:"id,omitempty"`
20386}
20387
20388// VirtualHubProperties parameters for VirtualHub
20389type VirtualHubProperties struct {
20390	// VirtualWan - The VirtualWAN to which the VirtualHub belongs
20391	VirtualWan *SubResource `json:"virtualWan,omitempty"`
20392	// VpnGateway - The VpnGateway associated with this VirtualHub
20393	VpnGateway *SubResource `json:"vpnGateway,omitempty"`
20394	// P2SVpnGateway - The P2SVpnGateway associated with this VirtualHub
20395	P2SVpnGateway *SubResource `json:"p2SVpnGateway,omitempty"`
20396	// ExpressRouteGateway - The expressRouteGateway associated with this VirtualHub
20397	ExpressRouteGateway *SubResource `json:"expressRouteGateway,omitempty"`
20398	// VirtualNetworkConnections - list of all vnet connections with this VirtualHub.
20399	VirtualNetworkConnections *[]HubVirtualNetworkConnection `json:"virtualNetworkConnections,omitempty"`
20400	// AddressPrefix - Address-prefix for this VirtualHub.
20401	AddressPrefix *string `json:"addressPrefix,omitempty"`
20402	// RouteTable - The routeTable associated with this virtual hub.
20403	RouteTable *VirtualHubRouteTable `json:"routeTable,omitempty"`
20404	// ProvisioningState - The provisioning state of the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
20405	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
20406}
20407
20408// VirtualHubRoute virtualHub route
20409type VirtualHubRoute struct {
20410	// AddressPrefixes - list of all addressPrefixes.
20411	AddressPrefixes *[]string `json:"addressPrefixes,omitempty"`
20412	// NextHopIPAddress - NextHop ip address.
20413	NextHopIPAddress *string `json:"nextHopIpAddress,omitempty"`
20414}
20415
20416// VirtualHubRouteTable virtualHub route table
20417type VirtualHubRouteTable struct {
20418	// Routes - list of all routes.
20419	Routes *[]VirtualHubRoute `json:"routes,omitempty"`
20420}
20421
20422// VirtualHubsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
20423// operation.
20424type VirtualHubsCreateOrUpdateFuture struct {
20425	azure.Future
20426}
20427
20428// Result returns the result of the asynchronous operation.
20429// If the operation has not completed it will return an error.
20430func (future *VirtualHubsCreateOrUpdateFuture) Result(client VirtualHubsClient) (vh VirtualHub, err error) {
20431	var done bool
20432	done, err = future.Done(client)
20433	if err != nil {
20434		err = autorest.NewErrorWithError(err, "network.VirtualHubsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
20435		return
20436	}
20437	if !done {
20438		err = azure.NewAsyncOpIncompleteError("network.VirtualHubsCreateOrUpdateFuture")
20439		return
20440	}
20441	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
20442	if vh.Response.Response, err = future.GetResult(sender); err == nil && vh.Response.Response.StatusCode != http.StatusNoContent {
20443		vh, err = client.CreateOrUpdateResponder(vh.Response.Response)
20444		if err != nil {
20445			err = autorest.NewErrorWithError(err, "network.VirtualHubsCreateOrUpdateFuture", "Result", vh.Response.Response, "Failure responding to request")
20446		}
20447	}
20448	return
20449}
20450
20451// VirtualHubsDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
20452type VirtualHubsDeleteFuture struct {
20453	azure.Future
20454}
20455
20456// Result returns the result of the asynchronous operation.
20457// If the operation has not completed it will return an error.
20458func (future *VirtualHubsDeleteFuture) Result(client VirtualHubsClient) (ar autorest.Response, err error) {
20459	var done bool
20460	done, err = future.Done(client)
20461	if err != nil {
20462		err = autorest.NewErrorWithError(err, "network.VirtualHubsDeleteFuture", "Result", future.Response(), "Polling failure")
20463		return
20464	}
20465	if !done {
20466		err = azure.NewAsyncOpIncompleteError("network.VirtualHubsDeleteFuture")
20467		return
20468	}
20469	ar.Response = future.Response()
20470	return
20471}
20472
20473// VirtualHubsUpdateTagsFuture an abstraction for monitoring and retrieving the results of a long-running
20474// operation.
20475type VirtualHubsUpdateTagsFuture struct {
20476	azure.Future
20477}
20478
20479// Result returns the result of the asynchronous operation.
20480// If the operation has not completed it will return an error.
20481func (future *VirtualHubsUpdateTagsFuture) Result(client VirtualHubsClient) (vh VirtualHub, err error) {
20482	var done bool
20483	done, err = future.Done(client)
20484	if err != nil {
20485		err = autorest.NewErrorWithError(err, "network.VirtualHubsUpdateTagsFuture", "Result", future.Response(), "Polling failure")
20486		return
20487	}
20488	if !done {
20489		err = azure.NewAsyncOpIncompleteError("network.VirtualHubsUpdateTagsFuture")
20490		return
20491	}
20492	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
20493	if vh.Response.Response, err = future.GetResult(sender); err == nil && vh.Response.Response.StatusCode != http.StatusNoContent {
20494		vh, err = client.UpdateTagsResponder(vh.Response.Response)
20495		if err != nil {
20496			err = autorest.NewErrorWithError(err, "network.VirtualHubsUpdateTagsFuture", "Result", vh.Response.Response, "Failure responding to request")
20497		}
20498	}
20499	return
20500}
20501
20502// VirtualNetwork virtual Network resource.
20503type VirtualNetwork struct {
20504	autorest.Response `json:"-"`
20505	// VirtualNetworkPropertiesFormat - Properties of the virtual network.
20506	*VirtualNetworkPropertiesFormat `json:"properties,omitempty"`
20507	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
20508	Etag *string `json:"etag,omitempty"`
20509	// ID - Resource ID.
20510	ID *string `json:"id,omitempty"`
20511	// Name - Resource name.
20512	Name *string `json:"name,omitempty"`
20513	// Type - Resource type.
20514	Type *string `json:"type,omitempty"`
20515	// Location - Resource location.
20516	Location *string `json:"location,omitempty"`
20517	// Tags - Resource tags.
20518	Tags map[string]*string `json:"tags"`
20519}
20520
20521// MarshalJSON is the custom marshaler for VirtualNetwork.
20522func (vn VirtualNetwork) MarshalJSON() ([]byte, error) {
20523	objectMap := make(map[string]interface{})
20524	if vn.VirtualNetworkPropertiesFormat != nil {
20525		objectMap["properties"] = vn.VirtualNetworkPropertiesFormat
20526	}
20527	if vn.Etag != nil {
20528		objectMap["etag"] = vn.Etag
20529	}
20530	if vn.ID != nil {
20531		objectMap["id"] = vn.ID
20532	}
20533	if vn.Name != nil {
20534		objectMap["name"] = vn.Name
20535	}
20536	if vn.Type != nil {
20537		objectMap["type"] = vn.Type
20538	}
20539	if vn.Location != nil {
20540		objectMap["location"] = vn.Location
20541	}
20542	if vn.Tags != nil {
20543		objectMap["tags"] = vn.Tags
20544	}
20545	return json.Marshal(objectMap)
20546}
20547
20548// UnmarshalJSON is the custom unmarshaler for VirtualNetwork struct.
20549func (vn *VirtualNetwork) UnmarshalJSON(body []byte) error {
20550	var m map[string]*json.RawMessage
20551	err := json.Unmarshal(body, &m)
20552	if err != nil {
20553		return err
20554	}
20555	for k, v := range m {
20556		switch k {
20557		case "properties":
20558			if v != nil {
20559				var virtualNetworkPropertiesFormat VirtualNetworkPropertiesFormat
20560				err = json.Unmarshal(*v, &virtualNetworkPropertiesFormat)
20561				if err != nil {
20562					return err
20563				}
20564				vn.VirtualNetworkPropertiesFormat = &virtualNetworkPropertiesFormat
20565			}
20566		case "etag":
20567			if v != nil {
20568				var etag string
20569				err = json.Unmarshal(*v, &etag)
20570				if err != nil {
20571					return err
20572				}
20573				vn.Etag = &etag
20574			}
20575		case "id":
20576			if v != nil {
20577				var ID string
20578				err = json.Unmarshal(*v, &ID)
20579				if err != nil {
20580					return err
20581				}
20582				vn.ID = &ID
20583			}
20584		case "name":
20585			if v != nil {
20586				var name string
20587				err = json.Unmarshal(*v, &name)
20588				if err != nil {
20589					return err
20590				}
20591				vn.Name = &name
20592			}
20593		case "type":
20594			if v != nil {
20595				var typeVar string
20596				err = json.Unmarshal(*v, &typeVar)
20597				if err != nil {
20598					return err
20599				}
20600				vn.Type = &typeVar
20601			}
20602		case "location":
20603			if v != nil {
20604				var location string
20605				err = json.Unmarshal(*v, &location)
20606				if err != nil {
20607					return err
20608				}
20609				vn.Location = &location
20610			}
20611		case "tags":
20612			if v != nil {
20613				var tags map[string]*string
20614				err = json.Unmarshal(*v, &tags)
20615				if err != nil {
20616					return err
20617				}
20618				vn.Tags = tags
20619			}
20620		}
20621	}
20622
20623	return nil
20624}
20625
20626// VirtualNetworkConnectionGatewayReference a reference to VirtualNetworkGateway or LocalNetworkGateway resource.
20627type VirtualNetworkConnectionGatewayReference struct {
20628	// ID - The ID of VirtualNetworkGateway or LocalNetworkGateway resource.
20629	ID *string `json:"id,omitempty"`
20630}
20631
20632// VirtualNetworkGateway a common class for general resource information
20633type VirtualNetworkGateway struct {
20634	autorest.Response `json:"-"`
20635	// VirtualNetworkGatewayPropertiesFormat - Properties of the virtual network gateway.
20636	*VirtualNetworkGatewayPropertiesFormat `json:"properties,omitempty"`
20637	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
20638	Etag *string `json:"etag,omitempty"`
20639	// ID - Resource ID.
20640	ID *string `json:"id,omitempty"`
20641	// Name - Resource name.
20642	Name *string `json:"name,omitempty"`
20643	// Type - Resource type.
20644	Type *string `json:"type,omitempty"`
20645	// Location - Resource location.
20646	Location *string `json:"location,omitempty"`
20647	// Tags - Resource tags.
20648	Tags map[string]*string `json:"tags"`
20649}
20650
20651// MarshalJSON is the custom marshaler for VirtualNetworkGateway.
20652func (vng VirtualNetworkGateway) MarshalJSON() ([]byte, error) {
20653	objectMap := make(map[string]interface{})
20654	if vng.VirtualNetworkGatewayPropertiesFormat != nil {
20655		objectMap["properties"] = vng.VirtualNetworkGatewayPropertiesFormat
20656	}
20657	if vng.Etag != nil {
20658		objectMap["etag"] = vng.Etag
20659	}
20660	if vng.ID != nil {
20661		objectMap["id"] = vng.ID
20662	}
20663	if vng.Name != nil {
20664		objectMap["name"] = vng.Name
20665	}
20666	if vng.Type != nil {
20667		objectMap["type"] = vng.Type
20668	}
20669	if vng.Location != nil {
20670		objectMap["location"] = vng.Location
20671	}
20672	if vng.Tags != nil {
20673		objectMap["tags"] = vng.Tags
20674	}
20675	return json.Marshal(objectMap)
20676}
20677
20678// UnmarshalJSON is the custom unmarshaler for VirtualNetworkGateway struct.
20679func (vng *VirtualNetworkGateway) UnmarshalJSON(body []byte) error {
20680	var m map[string]*json.RawMessage
20681	err := json.Unmarshal(body, &m)
20682	if err != nil {
20683		return err
20684	}
20685	for k, v := range m {
20686		switch k {
20687		case "properties":
20688			if v != nil {
20689				var virtualNetworkGatewayPropertiesFormat VirtualNetworkGatewayPropertiesFormat
20690				err = json.Unmarshal(*v, &virtualNetworkGatewayPropertiesFormat)
20691				if err != nil {
20692					return err
20693				}
20694				vng.VirtualNetworkGatewayPropertiesFormat = &virtualNetworkGatewayPropertiesFormat
20695			}
20696		case "etag":
20697			if v != nil {
20698				var etag string
20699				err = json.Unmarshal(*v, &etag)
20700				if err != nil {
20701					return err
20702				}
20703				vng.Etag = &etag
20704			}
20705		case "id":
20706			if v != nil {
20707				var ID string
20708				err = json.Unmarshal(*v, &ID)
20709				if err != nil {
20710					return err
20711				}
20712				vng.ID = &ID
20713			}
20714		case "name":
20715			if v != nil {
20716				var name string
20717				err = json.Unmarshal(*v, &name)
20718				if err != nil {
20719					return err
20720				}
20721				vng.Name = &name
20722			}
20723		case "type":
20724			if v != nil {
20725				var typeVar string
20726				err = json.Unmarshal(*v, &typeVar)
20727				if err != nil {
20728					return err
20729				}
20730				vng.Type = &typeVar
20731			}
20732		case "location":
20733			if v != nil {
20734				var location string
20735				err = json.Unmarshal(*v, &location)
20736				if err != nil {
20737					return err
20738				}
20739				vng.Location = &location
20740			}
20741		case "tags":
20742			if v != nil {
20743				var tags map[string]*string
20744				err = json.Unmarshal(*v, &tags)
20745				if err != nil {
20746					return err
20747				}
20748				vng.Tags = tags
20749			}
20750		}
20751	}
20752
20753	return nil
20754}
20755
20756// VirtualNetworkGatewayConnection a common class for general resource information
20757type VirtualNetworkGatewayConnection struct {
20758	autorest.Response `json:"-"`
20759	// VirtualNetworkGatewayConnectionPropertiesFormat - Properties of the virtual network gateway connection.
20760	*VirtualNetworkGatewayConnectionPropertiesFormat `json:"properties,omitempty"`
20761	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
20762	Etag *string `json:"etag,omitempty"`
20763	// ID - Resource ID.
20764	ID *string `json:"id,omitempty"`
20765	// Name - Resource name.
20766	Name *string `json:"name,omitempty"`
20767	// Type - Resource type.
20768	Type *string `json:"type,omitempty"`
20769	// Location - Resource location.
20770	Location *string `json:"location,omitempty"`
20771	// Tags - Resource tags.
20772	Tags map[string]*string `json:"tags"`
20773}
20774
20775// MarshalJSON is the custom marshaler for VirtualNetworkGatewayConnection.
20776func (vngc VirtualNetworkGatewayConnection) MarshalJSON() ([]byte, error) {
20777	objectMap := make(map[string]interface{})
20778	if vngc.VirtualNetworkGatewayConnectionPropertiesFormat != nil {
20779		objectMap["properties"] = vngc.VirtualNetworkGatewayConnectionPropertiesFormat
20780	}
20781	if vngc.Etag != nil {
20782		objectMap["etag"] = vngc.Etag
20783	}
20784	if vngc.ID != nil {
20785		objectMap["id"] = vngc.ID
20786	}
20787	if vngc.Name != nil {
20788		objectMap["name"] = vngc.Name
20789	}
20790	if vngc.Type != nil {
20791		objectMap["type"] = vngc.Type
20792	}
20793	if vngc.Location != nil {
20794		objectMap["location"] = vngc.Location
20795	}
20796	if vngc.Tags != nil {
20797		objectMap["tags"] = vngc.Tags
20798	}
20799	return json.Marshal(objectMap)
20800}
20801
20802// UnmarshalJSON is the custom unmarshaler for VirtualNetworkGatewayConnection struct.
20803func (vngc *VirtualNetworkGatewayConnection) UnmarshalJSON(body []byte) error {
20804	var m map[string]*json.RawMessage
20805	err := json.Unmarshal(body, &m)
20806	if err != nil {
20807		return err
20808	}
20809	for k, v := range m {
20810		switch k {
20811		case "properties":
20812			if v != nil {
20813				var virtualNetworkGatewayConnectionPropertiesFormat VirtualNetworkGatewayConnectionPropertiesFormat
20814				err = json.Unmarshal(*v, &virtualNetworkGatewayConnectionPropertiesFormat)
20815				if err != nil {
20816					return err
20817				}
20818				vngc.VirtualNetworkGatewayConnectionPropertiesFormat = &virtualNetworkGatewayConnectionPropertiesFormat
20819			}
20820		case "etag":
20821			if v != nil {
20822				var etag string
20823				err = json.Unmarshal(*v, &etag)
20824				if err != nil {
20825					return err
20826				}
20827				vngc.Etag = &etag
20828			}
20829		case "id":
20830			if v != nil {
20831				var ID string
20832				err = json.Unmarshal(*v, &ID)
20833				if err != nil {
20834					return err
20835				}
20836				vngc.ID = &ID
20837			}
20838		case "name":
20839			if v != nil {
20840				var name string
20841				err = json.Unmarshal(*v, &name)
20842				if err != nil {
20843					return err
20844				}
20845				vngc.Name = &name
20846			}
20847		case "type":
20848			if v != nil {
20849				var typeVar string
20850				err = json.Unmarshal(*v, &typeVar)
20851				if err != nil {
20852					return err
20853				}
20854				vngc.Type = &typeVar
20855			}
20856		case "location":
20857			if v != nil {
20858				var location string
20859				err = json.Unmarshal(*v, &location)
20860				if err != nil {
20861					return err
20862				}
20863				vngc.Location = &location
20864			}
20865		case "tags":
20866			if v != nil {
20867				var tags map[string]*string
20868				err = json.Unmarshal(*v, &tags)
20869				if err != nil {
20870					return err
20871				}
20872				vngc.Tags = tags
20873			}
20874		}
20875	}
20876
20877	return nil
20878}
20879
20880// VirtualNetworkGatewayConnectionListEntity a common class for general resource information
20881type VirtualNetworkGatewayConnectionListEntity struct {
20882	// VirtualNetworkGatewayConnectionListEntityPropertiesFormat - Properties of the virtual network gateway connection.
20883	*VirtualNetworkGatewayConnectionListEntityPropertiesFormat `json:"properties,omitempty"`
20884	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
20885	Etag *string `json:"etag,omitempty"`
20886	// ID - Resource ID.
20887	ID *string `json:"id,omitempty"`
20888	// Name - Resource name.
20889	Name *string `json:"name,omitempty"`
20890	// Type - Resource type.
20891	Type *string `json:"type,omitempty"`
20892	// Location - Resource location.
20893	Location *string `json:"location,omitempty"`
20894	// Tags - Resource tags.
20895	Tags map[string]*string `json:"tags"`
20896}
20897
20898// MarshalJSON is the custom marshaler for VirtualNetworkGatewayConnectionListEntity.
20899func (vngcle VirtualNetworkGatewayConnectionListEntity) MarshalJSON() ([]byte, error) {
20900	objectMap := make(map[string]interface{})
20901	if vngcle.VirtualNetworkGatewayConnectionListEntityPropertiesFormat != nil {
20902		objectMap["properties"] = vngcle.VirtualNetworkGatewayConnectionListEntityPropertiesFormat
20903	}
20904	if vngcle.Etag != nil {
20905		objectMap["etag"] = vngcle.Etag
20906	}
20907	if vngcle.ID != nil {
20908		objectMap["id"] = vngcle.ID
20909	}
20910	if vngcle.Name != nil {
20911		objectMap["name"] = vngcle.Name
20912	}
20913	if vngcle.Type != nil {
20914		objectMap["type"] = vngcle.Type
20915	}
20916	if vngcle.Location != nil {
20917		objectMap["location"] = vngcle.Location
20918	}
20919	if vngcle.Tags != nil {
20920		objectMap["tags"] = vngcle.Tags
20921	}
20922	return json.Marshal(objectMap)
20923}
20924
20925// UnmarshalJSON is the custom unmarshaler for VirtualNetworkGatewayConnectionListEntity struct.
20926func (vngcle *VirtualNetworkGatewayConnectionListEntity) UnmarshalJSON(body []byte) error {
20927	var m map[string]*json.RawMessage
20928	err := json.Unmarshal(body, &m)
20929	if err != nil {
20930		return err
20931	}
20932	for k, v := range m {
20933		switch k {
20934		case "properties":
20935			if v != nil {
20936				var virtualNetworkGatewayConnectionListEntityPropertiesFormat VirtualNetworkGatewayConnectionListEntityPropertiesFormat
20937				err = json.Unmarshal(*v, &virtualNetworkGatewayConnectionListEntityPropertiesFormat)
20938				if err != nil {
20939					return err
20940				}
20941				vngcle.VirtualNetworkGatewayConnectionListEntityPropertiesFormat = &virtualNetworkGatewayConnectionListEntityPropertiesFormat
20942			}
20943		case "etag":
20944			if v != nil {
20945				var etag string
20946				err = json.Unmarshal(*v, &etag)
20947				if err != nil {
20948					return err
20949				}
20950				vngcle.Etag = &etag
20951			}
20952		case "id":
20953			if v != nil {
20954				var ID string
20955				err = json.Unmarshal(*v, &ID)
20956				if err != nil {
20957					return err
20958				}
20959				vngcle.ID = &ID
20960			}
20961		case "name":
20962			if v != nil {
20963				var name string
20964				err = json.Unmarshal(*v, &name)
20965				if err != nil {
20966					return err
20967				}
20968				vngcle.Name = &name
20969			}
20970		case "type":
20971			if v != nil {
20972				var typeVar string
20973				err = json.Unmarshal(*v, &typeVar)
20974				if err != nil {
20975					return err
20976				}
20977				vngcle.Type = &typeVar
20978			}
20979		case "location":
20980			if v != nil {
20981				var location string
20982				err = json.Unmarshal(*v, &location)
20983				if err != nil {
20984					return err
20985				}
20986				vngcle.Location = &location
20987			}
20988		case "tags":
20989			if v != nil {
20990				var tags map[string]*string
20991				err = json.Unmarshal(*v, &tags)
20992				if err != nil {
20993					return err
20994				}
20995				vngcle.Tags = tags
20996			}
20997		}
20998	}
20999
21000	return nil
21001}
21002
21003// VirtualNetworkGatewayConnectionListEntityPropertiesFormat virtualNetworkGatewayConnection properties
21004type VirtualNetworkGatewayConnectionListEntityPropertiesFormat struct {
21005	// AuthorizationKey - The authorizationKey.
21006	AuthorizationKey *string `json:"authorizationKey,omitempty"`
21007	// VirtualNetworkGateway1 - The reference to virtual network gateway resource.
21008	VirtualNetworkGateway1 *VirtualNetworkConnectionGatewayReference `json:"virtualNetworkGateway1,omitempty"`
21009	// VirtualNetworkGateway2 - The reference to virtual network gateway resource.
21010	VirtualNetworkGateway2 *VirtualNetworkConnectionGatewayReference `json:"virtualNetworkGateway2,omitempty"`
21011	// LocalNetworkGateway2 - The reference to local network gateway resource.
21012	LocalNetworkGateway2 *VirtualNetworkConnectionGatewayReference `json:"localNetworkGateway2,omitempty"`
21013	// ConnectionType - Gateway connection type. Possible values are: 'Ipsec','Vnet2Vnet','ExpressRoute', and 'VPNClient. Possible values include: 'IPsec', 'Vnet2Vnet', 'ExpressRoute', 'VPNClient'
21014	ConnectionType VirtualNetworkGatewayConnectionType `json:"connectionType,omitempty"`
21015	// ConnectionProtocol - Connection protocol used for this connection. Possible values include: 'IKEv2', 'IKEv1'
21016	ConnectionProtocol VirtualNetworkGatewayConnectionProtocol `json:"connectionProtocol,omitempty"`
21017	// RoutingWeight - The routing weight.
21018	RoutingWeight *int32 `json:"routingWeight,omitempty"`
21019	// SharedKey - The IPSec shared key.
21020	SharedKey *string `json:"sharedKey,omitempty"`
21021	// ConnectionStatus - Virtual network Gateway connection status. Possible values are 'Unknown', 'Connecting', 'Connected' and 'NotConnected'. Possible values include: 'VirtualNetworkGatewayConnectionStatusUnknown', 'VirtualNetworkGatewayConnectionStatusConnecting', 'VirtualNetworkGatewayConnectionStatusConnected', 'VirtualNetworkGatewayConnectionStatusNotConnected'
21022	ConnectionStatus VirtualNetworkGatewayConnectionStatus `json:"connectionStatus,omitempty"`
21023	// TunnelConnectionStatus - Collection of all tunnels' connection health status.
21024	TunnelConnectionStatus *[]TunnelConnectionHealth `json:"tunnelConnectionStatus,omitempty"`
21025	// EgressBytesTransferred - The egress bytes transferred in this connection.
21026	EgressBytesTransferred *int64 `json:"egressBytesTransferred,omitempty"`
21027	// IngressBytesTransferred - The ingress bytes transferred in this connection.
21028	IngressBytesTransferred *int64 `json:"ingressBytesTransferred,omitempty"`
21029	// Peer - The reference to peerings resource.
21030	Peer *SubResource `json:"peer,omitempty"`
21031	// EnableBgp - EnableBgp flag
21032	EnableBgp *bool `json:"enableBgp,omitempty"`
21033	// UsePolicyBasedTrafficSelectors - Enable policy-based traffic selectors.
21034	UsePolicyBasedTrafficSelectors *bool `json:"usePolicyBasedTrafficSelectors,omitempty"`
21035	// IpsecPolicies - The IPSec Policies to be considered by this connection.
21036	IpsecPolicies *[]IpsecPolicy `json:"ipsecPolicies,omitempty"`
21037	// ResourceGUID - The resource GUID property of the VirtualNetworkGatewayConnection resource.
21038	ResourceGUID *string `json:"resourceGuid,omitempty"`
21039	// ProvisioningState - The provisioning state of the VirtualNetworkGatewayConnection resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
21040	ProvisioningState *string `json:"provisioningState,omitempty"`
21041	// ExpressRouteGatewayBypass - Bypass ExpressRoute Gateway for data forwarding
21042	ExpressRouteGatewayBypass *bool `json:"expressRouteGatewayBypass,omitempty"`
21043}
21044
21045// VirtualNetworkGatewayConnectionListResult response for the ListVirtualNetworkGatewayConnections API service call
21046type VirtualNetworkGatewayConnectionListResult struct {
21047	autorest.Response `json:"-"`
21048	// Value - Gets a list of VirtualNetworkGatewayConnection resources that exists in a resource group.
21049	Value *[]VirtualNetworkGatewayConnection `json:"value,omitempty"`
21050	// NextLink - The URL to get the next set of results.
21051	NextLink *string `json:"nextLink,omitempty"`
21052}
21053
21054// VirtualNetworkGatewayConnectionListResultIterator provides access to a complete listing of
21055// VirtualNetworkGatewayConnection values.
21056type VirtualNetworkGatewayConnectionListResultIterator struct {
21057	i    int
21058	page VirtualNetworkGatewayConnectionListResultPage
21059}
21060
21061// Next advances to the next value.  If there was an error making
21062// the request the iterator does not advance and the error is returned.
21063func (iter *VirtualNetworkGatewayConnectionListResultIterator) Next() error {
21064	iter.i++
21065	if iter.i < len(iter.page.Values()) {
21066		return nil
21067	}
21068	err := iter.page.Next()
21069	if err != nil {
21070		iter.i--
21071		return err
21072	}
21073	iter.i = 0
21074	return nil
21075}
21076
21077// NotDone returns true if the enumeration should be started or is not yet complete.
21078func (iter VirtualNetworkGatewayConnectionListResultIterator) NotDone() bool {
21079	return iter.page.NotDone() && iter.i < len(iter.page.Values())
21080}
21081
21082// Response returns the raw server response from the last page request.
21083func (iter VirtualNetworkGatewayConnectionListResultIterator) Response() VirtualNetworkGatewayConnectionListResult {
21084	return iter.page.Response()
21085}
21086
21087// Value returns the current value or a zero-initialized value if the
21088// iterator has advanced beyond the end of the collection.
21089func (iter VirtualNetworkGatewayConnectionListResultIterator) Value() VirtualNetworkGatewayConnection {
21090	if !iter.page.NotDone() {
21091		return VirtualNetworkGatewayConnection{}
21092	}
21093	return iter.page.Values()[iter.i]
21094}
21095
21096// IsEmpty returns true if the ListResult contains no values.
21097func (vngclr VirtualNetworkGatewayConnectionListResult) IsEmpty() bool {
21098	return vngclr.Value == nil || len(*vngclr.Value) == 0
21099}
21100
21101// virtualNetworkGatewayConnectionListResultPreparer prepares a request to retrieve the next set of results.
21102// It returns nil if no more results exist.
21103func (vngclr VirtualNetworkGatewayConnectionListResult) virtualNetworkGatewayConnectionListResultPreparer() (*http.Request, error) {
21104	if vngclr.NextLink == nil || len(to.String(vngclr.NextLink)) < 1 {
21105		return nil, nil
21106	}
21107	return autorest.Prepare(&http.Request{},
21108		autorest.AsJSON(),
21109		autorest.AsGet(),
21110		autorest.WithBaseURL(to.String(vngclr.NextLink)))
21111}
21112
21113// VirtualNetworkGatewayConnectionListResultPage contains a page of VirtualNetworkGatewayConnection values.
21114type VirtualNetworkGatewayConnectionListResultPage struct {
21115	fn     func(VirtualNetworkGatewayConnectionListResult) (VirtualNetworkGatewayConnectionListResult, error)
21116	vngclr VirtualNetworkGatewayConnectionListResult
21117}
21118
21119// Next advances to the next page of values.  If there was an error making
21120// the request the page does not advance and the error is returned.
21121func (page *VirtualNetworkGatewayConnectionListResultPage) Next() error {
21122	next, err := page.fn(page.vngclr)
21123	if err != nil {
21124		return err
21125	}
21126	page.vngclr = next
21127	return nil
21128}
21129
21130// NotDone returns true if the page enumeration should be started or is not yet complete.
21131func (page VirtualNetworkGatewayConnectionListResultPage) NotDone() bool {
21132	return !page.vngclr.IsEmpty()
21133}
21134
21135// Response returns the raw server response from the last page request.
21136func (page VirtualNetworkGatewayConnectionListResultPage) Response() VirtualNetworkGatewayConnectionListResult {
21137	return page.vngclr
21138}
21139
21140// Values returns the slice of values for the current page or nil if there are no values.
21141func (page VirtualNetworkGatewayConnectionListResultPage) Values() []VirtualNetworkGatewayConnection {
21142	if page.vngclr.IsEmpty() {
21143		return nil
21144	}
21145	return *page.vngclr.Value
21146}
21147
21148// VirtualNetworkGatewayConnectionPropertiesFormat virtualNetworkGatewayConnection properties
21149type VirtualNetworkGatewayConnectionPropertiesFormat struct {
21150	// AuthorizationKey - The authorizationKey.
21151	AuthorizationKey *string `json:"authorizationKey,omitempty"`
21152	// VirtualNetworkGateway1 - The reference to virtual network gateway resource.
21153	VirtualNetworkGateway1 *VirtualNetworkGateway `json:"virtualNetworkGateway1,omitempty"`
21154	// VirtualNetworkGateway2 - The reference to virtual network gateway resource.
21155	VirtualNetworkGateway2 *VirtualNetworkGateway `json:"virtualNetworkGateway2,omitempty"`
21156	// LocalNetworkGateway2 - The reference to local network gateway resource.
21157	LocalNetworkGateway2 *LocalNetworkGateway `json:"localNetworkGateway2,omitempty"`
21158	// ConnectionType - Gateway connection type. Possible values are: 'Ipsec','Vnet2Vnet','ExpressRoute', and 'VPNClient. Possible values include: 'IPsec', 'Vnet2Vnet', 'ExpressRoute', 'VPNClient'
21159	ConnectionType VirtualNetworkGatewayConnectionType `json:"connectionType,omitempty"`
21160	// ConnectionProtocol - Connection protocol used for this connection. Possible values include: 'IKEv2', 'IKEv1'
21161	ConnectionProtocol VirtualNetworkGatewayConnectionProtocol `json:"connectionProtocol,omitempty"`
21162	// RoutingWeight - The routing weight.
21163	RoutingWeight *int32 `json:"routingWeight,omitempty"`
21164	// SharedKey - The IPSec shared key.
21165	SharedKey *string `json:"sharedKey,omitempty"`
21166	// ConnectionStatus - Virtual network Gateway connection status. Possible values are 'Unknown', 'Connecting', 'Connected' and 'NotConnected'. Possible values include: 'VirtualNetworkGatewayConnectionStatusUnknown', 'VirtualNetworkGatewayConnectionStatusConnecting', 'VirtualNetworkGatewayConnectionStatusConnected', 'VirtualNetworkGatewayConnectionStatusNotConnected'
21167	ConnectionStatus VirtualNetworkGatewayConnectionStatus `json:"connectionStatus,omitempty"`
21168	// TunnelConnectionStatus - Collection of all tunnels' connection health status.
21169	TunnelConnectionStatus *[]TunnelConnectionHealth `json:"tunnelConnectionStatus,omitempty"`
21170	// EgressBytesTransferred - The egress bytes transferred in this connection.
21171	EgressBytesTransferred *int64 `json:"egressBytesTransferred,omitempty"`
21172	// IngressBytesTransferred - The ingress bytes transferred in this connection.
21173	IngressBytesTransferred *int64 `json:"ingressBytesTransferred,omitempty"`
21174	// Peer - The reference to peerings resource.
21175	Peer *SubResource `json:"peer,omitempty"`
21176	// EnableBgp - EnableBgp flag
21177	EnableBgp *bool `json:"enableBgp,omitempty"`
21178	// UsePolicyBasedTrafficSelectors - Enable policy-based traffic selectors.
21179	UsePolicyBasedTrafficSelectors *bool `json:"usePolicyBasedTrafficSelectors,omitempty"`
21180	// IpsecPolicies - The IPSec Policies to be considered by this connection.
21181	IpsecPolicies *[]IpsecPolicy `json:"ipsecPolicies,omitempty"`
21182	// ResourceGUID - The resource GUID property of the VirtualNetworkGatewayConnection resource.
21183	ResourceGUID *string `json:"resourceGuid,omitempty"`
21184	// ProvisioningState - The provisioning state of the VirtualNetworkGatewayConnection resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
21185	ProvisioningState *string `json:"provisioningState,omitempty"`
21186	// ExpressRouteGatewayBypass - Bypass ExpressRoute Gateway for data forwarding
21187	ExpressRouteGatewayBypass *bool `json:"expressRouteGatewayBypass,omitempty"`
21188}
21189
21190// VirtualNetworkGatewayConnectionsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of
21191// a long-running operation.
21192type VirtualNetworkGatewayConnectionsCreateOrUpdateFuture struct {
21193	azure.Future
21194}
21195
21196// Result returns the result of the asynchronous operation.
21197// If the operation has not completed it will return an error.
21198func (future *VirtualNetworkGatewayConnectionsCreateOrUpdateFuture) Result(client VirtualNetworkGatewayConnectionsClient) (vngc VirtualNetworkGatewayConnection, err error) {
21199	var done bool
21200	done, err = future.Done(client)
21201	if err != nil {
21202		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
21203		return
21204	}
21205	if !done {
21206		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewayConnectionsCreateOrUpdateFuture")
21207		return
21208	}
21209	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
21210	if vngc.Response.Response, err = future.GetResult(sender); err == nil && vngc.Response.Response.StatusCode != http.StatusNoContent {
21211		vngc, err = client.CreateOrUpdateResponder(vngc.Response.Response)
21212		if err != nil {
21213			err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsCreateOrUpdateFuture", "Result", vngc.Response.Response, "Failure responding to request")
21214		}
21215	}
21216	return
21217}
21218
21219// VirtualNetworkGatewayConnectionsDeleteFuture an abstraction for monitoring and retrieving the results of a
21220// long-running operation.
21221type VirtualNetworkGatewayConnectionsDeleteFuture struct {
21222	azure.Future
21223}
21224
21225// Result returns the result of the asynchronous operation.
21226// If the operation has not completed it will return an error.
21227func (future *VirtualNetworkGatewayConnectionsDeleteFuture) Result(client VirtualNetworkGatewayConnectionsClient) (ar autorest.Response, err error) {
21228	var done bool
21229	done, err = future.Done(client)
21230	if err != nil {
21231		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsDeleteFuture", "Result", future.Response(), "Polling failure")
21232		return
21233	}
21234	if !done {
21235		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewayConnectionsDeleteFuture")
21236		return
21237	}
21238	ar.Response = future.Response()
21239	return
21240}
21241
21242// VirtualNetworkGatewayConnectionsResetSharedKeyFuture an abstraction for monitoring and retrieving the results of
21243// a long-running operation.
21244type VirtualNetworkGatewayConnectionsResetSharedKeyFuture struct {
21245	azure.Future
21246}
21247
21248// Result returns the result of the asynchronous operation.
21249// If the operation has not completed it will return an error.
21250func (future *VirtualNetworkGatewayConnectionsResetSharedKeyFuture) Result(client VirtualNetworkGatewayConnectionsClient) (crsk ConnectionResetSharedKey, err error) {
21251	var done bool
21252	done, err = future.Done(client)
21253	if err != nil {
21254		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsResetSharedKeyFuture", "Result", future.Response(), "Polling failure")
21255		return
21256	}
21257	if !done {
21258		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewayConnectionsResetSharedKeyFuture")
21259		return
21260	}
21261	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
21262	if crsk.Response.Response, err = future.GetResult(sender); err == nil && crsk.Response.Response.StatusCode != http.StatusNoContent {
21263		crsk, err = client.ResetSharedKeyResponder(crsk.Response.Response)
21264		if err != nil {
21265			err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsResetSharedKeyFuture", "Result", crsk.Response.Response, "Failure responding to request")
21266		}
21267	}
21268	return
21269}
21270
21271// VirtualNetworkGatewayConnectionsSetSharedKeyFuture an abstraction for monitoring and retrieving the results of a
21272// long-running operation.
21273type VirtualNetworkGatewayConnectionsSetSharedKeyFuture struct {
21274	azure.Future
21275}
21276
21277// Result returns the result of the asynchronous operation.
21278// If the operation has not completed it will return an error.
21279func (future *VirtualNetworkGatewayConnectionsSetSharedKeyFuture) Result(client VirtualNetworkGatewayConnectionsClient) (csk ConnectionSharedKey, err error) {
21280	var done bool
21281	done, err = future.Done(client)
21282	if err != nil {
21283		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsSetSharedKeyFuture", "Result", future.Response(), "Polling failure")
21284		return
21285	}
21286	if !done {
21287		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewayConnectionsSetSharedKeyFuture")
21288		return
21289	}
21290	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
21291	if csk.Response.Response, err = future.GetResult(sender); err == nil && csk.Response.Response.StatusCode != http.StatusNoContent {
21292		csk, err = client.SetSharedKeyResponder(csk.Response.Response)
21293		if err != nil {
21294			err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsSetSharedKeyFuture", "Result", csk.Response.Response, "Failure responding to request")
21295		}
21296	}
21297	return
21298}
21299
21300// VirtualNetworkGatewayConnectionsUpdateTagsFuture an abstraction for monitoring and retrieving the results of a
21301// long-running operation.
21302type VirtualNetworkGatewayConnectionsUpdateTagsFuture struct {
21303	azure.Future
21304}
21305
21306// Result returns the result of the asynchronous operation.
21307// If the operation has not completed it will return an error.
21308func (future *VirtualNetworkGatewayConnectionsUpdateTagsFuture) Result(client VirtualNetworkGatewayConnectionsClient) (vngc VirtualNetworkGatewayConnection, err error) {
21309	var done bool
21310	done, err = future.Done(client)
21311	if err != nil {
21312		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsUpdateTagsFuture", "Result", future.Response(), "Polling failure")
21313		return
21314	}
21315	if !done {
21316		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewayConnectionsUpdateTagsFuture")
21317		return
21318	}
21319	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
21320	if vngc.Response.Response, err = future.GetResult(sender); err == nil && vngc.Response.Response.StatusCode != http.StatusNoContent {
21321		vngc, err = client.UpdateTagsResponder(vngc.Response.Response)
21322		if err != nil {
21323			err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsUpdateTagsFuture", "Result", vngc.Response.Response, "Failure responding to request")
21324		}
21325	}
21326	return
21327}
21328
21329// VirtualNetworkGatewayIPConfiguration IP configuration for virtual network gateway
21330type VirtualNetworkGatewayIPConfiguration struct {
21331	// VirtualNetworkGatewayIPConfigurationPropertiesFormat - Properties of the virtual network gateway ip configuration.
21332	*VirtualNetworkGatewayIPConfigurationPropertiesFormat `json:"properties,omitempty"`
21333	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
21334	Name *string `json:"name,omitempty"`
21335	// Etag - A unique read-only string that changes whenever the resource is updated.
21336	Etag *string `json:"etag,omitempty"`
21337	// ID - Resource ID.
21338	ID *string `json:"id,omitempty"`
21339}
21340
21341// MarshalJSON is the custom marshaler for VirtualNetworkGatewayIPConfiguration.
21342func (vngic VirtualNetworkGatewayIPConfiguration) MarshalJSON() ([]byte, error) {
21343	objectMap := make(map[string]interface{})
21344	if vngic.VirtualNetworkGatewayIPConfigurationPropertiesFormat != nil {
21345		objectMap["properties"] = vngic.VirtualNetworkGatewayIPConfigurationPropertiesFormat
21346	}
21347	if vngic.Name != nil {
21348		objectMap["name"] = vngic.Name
21349	}
21350	if vngic.Etag != nil {
21351		objectMap["etag"] = vngic.Etag
21352	}
21353	if vngic.ID != nil {
21354		objectMap["id"] = vngic.ID
21355	}
21356	return json.Marshal(objectMap)
21357}
21358
21359// UnmarshalJSON is the custom unmarshaler for VirtualNetworkGatewayIPConfiguration struct.
21360func (vngic *VirtualNetworkGatewayIPConfiguration) UnmarshalJSON(body []byte) error {
21361	var m map[string]*json.RawMessage
21362	err := json.Unmarshal(body, &m)
21363	if err != nil {
21364		return err
21365	}
21366	for k, v := range m {
21367		switch k {
21368		case "properties":
21369			if v != nil {
21370				var virtualNetworkGatewayIPConfigurationPropertiesFormat VirtualNetworkGatewayIPConfigurationPropertiesFormat
21371				err = json.Unmarshal(*v, &virtualNetworkGatewayIPConfigurationPropertiesFormat)
21372				if err != nil {
21373					return err
21374				}
21375				vngic.VirtualNetworkGatewayIPConfigurationPropertiesFormat = &virtualNetworkGatewayIPConfigurationPropertiesFormat
21376			}
21377		case "name":
21378			if v != nil {
21379				var name string
21380				err = json.Unmarshal(*v, &name)
21381				if err != nil {
21382					return err
21383				}
21384				vngic.Name = &name
21385			}
21386		case "etag":
21387			if v != nil {
21388				var etag string
21389				err = json.Unmarshal(*v, &etag)
21390				if err != nil {
21391					return err
21392				}
21393				vngic.Etag = &etag
21394			}
21395		case "id":
21396			if v != nil {
21397				var ID string
21398				err = json.Unmarshal(*v, &ID)
21399				if err != nil {
21400					return err
21401				}
21402				vngic.ID = &ID
21403			}
21404		}
21405	}
21406
21407	return nil
21408}
21409
21410// VirtualNetworkGatewayIPConfigurationPropertiesFormat properties of VirtualNetworkGatewayIPConfiguration
21411type VirtualNetworkGatewayIPConfigurationPropertiesFormat struct {
21412	// PrivateIPAllocationMethod - The private IP allocation method. Possible values are: 'Static' and 'Dynamic'. Possible values include: 'Static', 'Dynamic'
21413	PrivateIPAllocationMethod IPAllocationMethod `json:"privateIPAllocationMethod,omitempty"`
21414	// Subnet - The reference of the subnet resource.
21415	Subnet *SubResource `json:"subnet,omitempty"`
21416	// PublicIPAddress - The reference of the public IP resource.
21417	PublicIPAddress *SubResource `json:"publicIPAddress,omitempty"`
21418	// ProvisioningState - The provisioning state of the public IP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
21419	ProvisioningState *string `json:"provisioningState,omitempty"`
21420}
21421
21422// VirtualNetworkGatewayListConnectionsResult response for the VirtualNetworkGatewayListConnections API service
21423// call
21424type VirtualNetworkGatewayListConnectionsResult struct {
21425	autorest.Response `json:"-"`
21426	// Value - Gets a list of VirtualNetworkGatewayConnection resources that exists in a resource group.
21427	Value *[]VirtualNetworkGatewayConnectionListEntity `json:"value,omitempty"`
21428	// NextLink - The URL to get the next set of results.
21429	NextLink *string `json:"nextLink,omitempty"`
21430}
21431
21432// VirtualNetworkGatewayListConnectionsResultIterator provides access to a complete listing of
21433// VirtualNetworkGatewayConnectionListEntity values.
21434type VirtualNetworkGatewayListConnectionsResultIterator struct {
21435	i    int
21436	page VirtualNetworkGatewayListConnectionsResultPage
21437}
21438
21439// Next advances to the next value.  If there was an error making
21440// the request the iterator does not advance and the error is returned.
21441func (iter *VirtualNetworkGatewayListConnectionsResultIterator) Next() error {
21442	iter.i++
21443	if iter.i < len(iter.page.Values()) {
21444		return nil
21445	}
21446	err := iter.page.Next()
21447	if err != nil {
21448		iter.i--
21449		return err
21450	}
21451	iter.i = 0
21452	return nil
21453}
21454
21455// NotDone returns true if the enumeration should be started or is not yet complete.
21456func (iter VirtualNetworkGatewayListConnectionsResultIterator) NotDone() bool {
21457	return iter.page.NotDone() && iter.i < len(iter.page.Values())
21458}
21459
21460// Response returns the raw server response from the last page request.
21461func (iter VirtualNetworkGatewayListConnectionsResultIterator) Response() VirtualNetworkGatewayListConnectionsResult {
21462	return iter.page.Response()
21463}
21464
21465// Value returns the current value or a zero-initialized value if the
21466// iterator has advanced beyond the end of the collection.
21467func (iter VirtualNetworkGatewayListConnectionsResultIterator) Value() VirtualNetworkGatewayConnectionListEntity {
21468	if !iter.page.NotDone() {
21469		return VirtualNetworkGatewayConnectionListEntity{}
21470	}
21471	return iter.page.Values()[iter.i]
21472}
21473
21474// IsEmpty returns true if the ListResult contains no values.
21475func (vnglcr VirtualNetworkGatewayListConnectionsResult) IsEmpty() bool {
21476	return vnglcr.Value == nil || len(*vnglcr.Value) == 0
21477}
21478
21479// virtualNetworkGatewayListConnectionsResultPreparer prepares a request to retrieve the next set of results.
21480// It returns nil if no more results exist.
21481func (vnglcr VirtualNetworkGatewayListConnectionsResult) virtualNetworkGatewayListConnectionsResultPreparer() (*http.Request, error) {
21482	if vnglcr.NextLink == nil || len(to.String(vnglcr.NextLink)) < 1 {
21483		return nil, nil
21484	}
21485	return autorest.Prepare(&http.Request{},
21486		autorest.AsJSON(),
21487		autorest.AsGet(),
21488		autorest.WithBaseURL(to.String(vnglcr.NextLink)))
21489}
21490
21491// VirtualNetworkGatewayListConnectionsResultPage contains a page of VirtualNetworkGatewayConnectionListEntity
21492// values.
21493type VirtualNetworkGatewayListConnectionsResultPage struct {
21494	fn     func(VirtualNetworkGatewayListConnectionsResult) (VirtualNetworkGatewayListConnectionsResult, error)
21495	vnglcr VirtualNetworkGatewayListConnectionsResult
21496}
21497
21498// Next advances to the next page of values.  If there was an error making
21499// the request the page does not advance and the error is returned.
21500func (page *VirtualNetworkGatewayListConnectionsResultPage) Next() error {
21501	next, err := page.fn(page.vnglcr)
21502	if err != nil {
21503		return err
21504	}
21505	page.vnglcr = next
21506	return nil
21507}
21508
21509// NotDone returns true if the page enumeration should be started or is not yet complete.
21510func (page VirtualNetworkGatewayListConnectionsResultPage) NotDone() bool {
21511	return !page.vnglcr.IsEmpty()
21512}
21513
21514// Response returns the raw server response from the last page request.
21515func (page VirtualNetworkGatewayListConnectionsResultPage) Response() VirtualNetworkGatewayListConnectionsResult {
21516	return page.vnglcr
21517}
21518
21519// Values returns the slice of values for the current page or nil if there are no values.
21520func (page VirtualNetworkGatewayListConnectionsResultPage) Values() []VirtualNetworkGatewayConnectionListEntity {
21521	if page.vnglcr.IsEmpty() {
21522		return nil
21523	}
21524	return *page.vnglcr.Value
21525}
21526
21527// VirtualNetworkGatewayListResult response for the ListVirtualNetworkGateways API service call.
21528type VirtualNetworkGatewayListResult struct {
21529	autorest.Response `json:"-"`
21530	// Value - Gets a list of VirtualNetworkGateway resources that exists in a resource group.
21531	Value *[]VirtualNetworkGateway `json:"value,omitempty"`
21532	// NextLink - The URL to get the next set of results.
21533	NextLink *string `json:"nextLink,omitempty"`
21534}
21535
21536// VirtualNetworkGatewayListResultIterator provides access to a complete listing of VirtualNetworkGateway values.
21537type VirtualNetworkGatewayListResultIterator struct {
21538	i    int
21539	page VirtualNetworkGatewayListResultPage
21540}
21541
21542// Next advances to the next value.  If there was an error making
21543// the request the iterator does not advance and the error is returned.
21544func (iter *VirtualNetworkGatewayListResultIterator) Next() error {
21545	iter.i++
21546	if iter.i < len(iter.page.Values()) {
21547		return nil
21548	}
21549	err := iter.page.Next()
21550	if err != nil {
21551		iter.i--
21552		return err
21553	}
21554	iter.i = 0
21555	return nil
21556}
21557
21558// NotDone returns true if the enumeration should be started or is not yet complete.
21559func (iter VirtualNetworkGatewayListResultIterator) NotDone() bool {
21560	return iter.page.NotDone() && iter.i < len(iter.page.Values())
21561}
21562
21563// Response returns the raw server response from the last page request.
21564func (iter VirtualNetworkGatewayListResultIterator) Response() VirtualNetworkGatewayListResult {
21565	return iter.page.Response()
21566}
21567
21568// Value returns the current value or a zero-initialized value if the
21569// iterator has advanced beyond the end of the collection.
21570func (iter VirtualNetworkGatewayListResultIterator) Value() VirtualNetworkGateway {
21571	if !iter.page.NotDone() {
21572		return VirtualNetworkGateway{}
21573	}
21574	return iter.page.Values()[iter.i]
21575}
21576
21577// IsEmpty returns true if the ListResult contains no values.
21578func (vnglr VirtualNetworkGatewayListResult) IsEmpty() bool {
21579	return vnglr.Value == nil || len(*vnglr.Value) == 0
21580}
21581
21582// virtualNetworkGatewayListResultPreparer prepares a request to retrieve the next set of results.
21583// It returns nil if no more results exist.
21584func (vnglr VirtualNetworkGatewayListResult) virtualNetworkGatewayListResultPreparer() (*http.Request, error) {
21585	if vnglr.NextLink == nil || len(to.String(vnglr.NextLink)) < 1 {
21586		return nil, nil
21587	}
21588	return autorest.Prepare(&http.Request{},
21589		autorest.AsJSON(),
21590		autorest.AsGet(),
21591		autorest.WithBaseURL(to.String(vnglr.NextLink)))
21592}
21593
21594// VirtualNetworkGatewayListResultPage contains a page of VirtualNetworkGateway values.
21595type VirtualNetworkGatewayListResultPage struct {
21596	fn    func(VirtualNetworkGatewayListResult) (VirtualNetworkGatewayListResult, error)
21597	vnglr VirtualNetworkGatewayListResult
21598}
21599
21600// Next advances to the next page of values.  If there was an error making
21601// the request the page does not advance and the error is returned.
21602func (page *VirtualNetworkGatewayListResultPage) Next() error {
21603	next, err := page.fn(page.vnglr)
21604	if err != nil {
21605		return err
21606	}
21607	page.vnglr = next
21608	return nil
21609}
21610
21611// NotDone returns true if the page enumeration should be started or is not yet complete.
21612func (page VirtualNetworkGatewayListResultPage) NotDone() bool {
21613	return !page.vnglr.IsEmpty()
21614}
21615
21616// Response returns the raw server response from the last page request.
21617func (page VirtualNetworkGatewayListResultPage) Response() VirtualNetworkGatewayListResult {
21618	return page.vnglr
21619}
21620
21621// Values returns the slice of values for the current page or nil if there are no values.
21622func (page VirtualNetworkGatewayListResultPage) Values() []VirtualNetworkGateway {
21623	if page.vnglr.IsEmpty() {
21624		return nil
21625	}
21626	return *page.vnglr.Value
21627}
21628
21629// VirtualNetworkGatewayPropertiesFormat virtualNetworkGateway properties
21630type VirtualNetworkGatewayPropertiesFormat struct {
21631	// IPConfigurations - IP configurations for virtual network gateway.
21632	IPConfigurations *[]VirtualNetworkGatewayIPConfiguration `json:"ipConfigurations,omitempty"`
21633	// GatewayType - The type of this virtual network gateway. Possible values are: 'Vpn' and 'ExpressRoute'. Possible values include: 'VirtualNetworkGatewayTypeVpn', 'VirtualNetworkGatewayTypeExpressRoute'
21634	GatewayType VirtualNetworkGatewayType `json:"gatewayType,omitempty"`
21635	// VpnType - The type of this virtual network gateway. Possible values are: 'PolicyBased' and 'RouteBased'. Possible values include: 'PolicyBased', 'RouteBased'
21636	VpnType VpnType `json:"vpnType,omitempty"`
21637	// EnableBgp - Whether BGP is enabled for this virtual network gateway or not.
21638	EnableBgp *bool `json:"enableBgp,omitempty"`
21639	// ActiveActive - ActiveActive flag
21640	ActiveActive *bool `json:"activeActive,omitempty"`
21641	// 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.
21642	GatewayDefaultSite *SubResource `json:"gatewayDefaultSite,omitempty"`
21643	// Sku - The reference of the VirtualNetworkGatewaySku resource which represents the SKU selected for Virtual network gateway.
21644	Sku *VirtualNetworkGatewaySku `json:"sku,omitempty"`
21645	// VpnClientConfiguration - The reference of the VpnClientConfiguration resource which represents the P2S VpnClient configurations.
21646	VpnClientConfiguration *VpnClientConfiguration `json:"vpnClientConfiguration,omitempty"`
21647	// BgpSettings - Virtual network gateway's BGP speaker settings.
21648	BgpSettings *BgpSettings `json:"bgpSettings,omitempty"`
21649	// ResourceGUID - The resource GUID property of the VirtualNetworkGateway resource.
21650	ResourceGUID *string `json:"resourceGuid,omitempty"`
21651	// ProvisioningState - The provisioning state of the VirtualNetworkGateway resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
21652	ProvisioningState *string `json:"provisioningState,omitempty"`
21653}
21654
21655// VirtualNetworkGatewaysCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
21656// long-running operation.
21657type VirtualNetworkGatewaysCreateOrUpdateFuture struct {
21658	azure.Future
21659}
21660
21661// Result returns the result of the asynchronous operation.
21662// If the operation has not completed it will return an error.
21663func (future *VirtualNetworkGatewaysCreateOrUpdateFuture) Result(client VirtualNetworkGatewaysClient) (vng VirtualNetworkGateway, err error) {
21664	var done bool
21665	done, err = future.Done(client)
21666	if err != nil {
21667		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
21668		return
21669	}
21670	if !done {
21671		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysCreateOrUpdateFuture")
21672		return
21673	}
21674	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
21675	if vng.Response.Response, err = future.GetResult(sender); err == nil && vng.Response.Response.StatusCode != http.StatusNoContent {
21676		vng, err = client.CreateOrUpdateResponder(vng.Response.Response)
21677		if err != nil {
21678			err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysCreateOrUpdateFuture", "Result", vng.Response.Response, "Failure responding to request")
21679		}
21680	}
21681	return
21682}
21683
21684// VirtualNetworkGatewaysDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
21685// operation.
21686type VirtualNetworkGatewaysDeleteFuture struct {
21687	azure.Future
21688}
21689
21690// Result returns the result of the asynchronous operation.
21691// If the operation has not completed it will return an error.
21692func (future *VirtualNetworkGatewaysDeleteFuture) Result(client VirtualNetworkGatewaysClient) (ar autorest.Response, err error) {
21693	var done bool
21694	done, err = future.Done(client)
21695	if err != nil {
21696		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysDeleteFuture", "Result", future.Response(), "Polling failure")
21697		return
21698	}
21699	if !done {
21700		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysDeleteFuture")
21701		return
21702	}
21703	ar.Response = future.Response()
21704	return
21705}
21706
21707// VirtualNetworkGatewaysGeneratevpnclientpackageFuture an abstraction for monitoring and retrieving the results of
21708// a long-running operation.
21709type VirtualNetworkGatewaysGeneratevpnclientpackageFuture struct {
21710	azure.Future
21711}
21712
21713// Result returns the result of the asynchronous operation.
21714// If the operation has not completed it will return an error.
21715func (future *VirtualNetworkGatewaysGeneratevpnclientpackageFuture) Result(client VirtualNetworkGatewaysClient) (s String, err error) {
21716	var done bool
21717	done, err = future.Done(client)
21718	if err != nil {
21719		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysGeneratevpnclientpackageFuture", "Result", future.Response(), "Polling failure")
21720		return
21721	}
21722	if !done {
21723		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysGeneratevpnclientpackageFuture")
21724		return
21725	}
21726	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
21727	if s.Response.Response, err = future.GetResult(sender); err == nil && s.Response.Response.StatusCode != http.StatusNoContent {
21728		s, err = client.GeneratevpnclientpackageResponder(s.Response.Response)
21729		if err != nil {
21730			err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysGeneratevpnclientpackageFuture", "Result", s.Response.Response, "Failure responding to request")
21731		}
21732	}
21733	return
21734}
21735
21736// VirtualNetworkGatewaysGenerateVpnProfileFuture an abstraction for monitoring and retrieving the results of a
21737// long-running operation.
21738type VirtualNetworkGatewaysGenerateVpnProfileFuture struct {
21739	azure.Future
21740}
21741
21742// Result returns the result of the asynchronous operation.
21743// If the operation has not completed it will return an error.
21744func (future *VirtualNetworkGatewaysGenerateVpnProfileFuture) Result(client VirtualNetworkGatewaysClient) (s String, err error) {
21745	var done bool
21746	done, err = future.Done(client)
21747	if err != nil {
21748		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysGenerateVpnProfileFuture", "Result", future.Response(), "Polling failure")
21749		return
21750	}
21751	if !done {
21752		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysGenerateVpnProfileFuture")
21753		return
21754	}
21755	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
21756	if s.Response.Response, err = future.GetResult(sender); err == nil && s.Response.Response.StatusCode != http.StatusNoContent {
21757		s, err = client.GenerateVpnProfileResponder(s.Response.Response)
21758		if err != nil {
21759			err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysGenerateVpnProfileFuture", "Result", s.Response.Response, "Failure responding to request")
21760		}
21761	}
21762	return
21763}
21764
21765// VirtualNetworkGatewaysGetAdvertisedRoutesFuture an abstraction for monitoring and retrieving the results of a
21766// long-running operation.
21767type VirtualNetworkGatewaysGetAdvertisedRoutesFuture struct {
21768	azure.Future
21769}
21770
21771// Result returns the result of the asynchronous operation.
21772// If the operation has not completed it will return an error.
21773func (future *VirtualNetworkGatewaysGetAdvertisedRoutesFuture) Result(client VirtualNetworkGatewaysClient) (grlr GatewayRouteListResult, err error) {
21774	var done bool
21775	done, err = future.Done(client)
21776	if err != nil {
21777		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysGetAdvertisedRoutesFuture", "Result", future.Response(), "Polling failure")
21778		return
21779	}
21780	if !done {
21781		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysGetAdvertisedRoutesFuture")
21782		return
21783	}
21784	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
21785	if grlr.Response.Response, err = future.GetResult(sender); err == nil && grlr.Response.Response.StatusCode != http.StatusNoContent {
21786		grlr, err = client.GetAdvertisedRoutesResponder(grlr.Response.Response)
21787		if err != nil {
21788			err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysGetAdvertisedRoutesFuture", "Result", grlr.Response.Response, "Failure responding to request")
21789		}
21790	}
21791	return
21792}
21793
21794// VirtualNetworkGatewaysGetBgpPeerStatusFuture an abstraction for monitoring and retrieving the results of a
21795// long-running operation.
21796type VirtualNetworkGatewaysGetBgpPeerStatusFuture struct {
21797	azure.Future
21798}
21799
21800// Result returns the result of the asynchronous operation.
21801// If the operation has not completed it will return an error.
21802func (future *VirtualNetworkGatewaysGetBgpPeerStatusFuture) Result(client VirtualNetworkGatewaysClient) (bpslr BgpPeerStatusListResult, err error) {
21803	var done bool
21804	done, err = future.Done(client)
21805	if err != nil {
21806		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysGetBgpPeerStatusFuture", "Result", future.Response(), "Polling failure")
21807		return
21808	}
21809	if !done {
21810		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysGetBgpPeerStatusFuture")
21811		return
21812	}
21813	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
21814	if bpslr.Response.Response, err = future.GetResult(sender); err == nil && bpslr.Response.Response.StatusCode != http.StatusNoContent {
21815		bpslr, err = client.GetBgpPeerStatusResponder(bpslr.Response.Response)
21816		if err != nil {
21817			err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysGetBgpPeerStatusFuture", "Result", bpslr.Response.Response, "Failure responding to request")
21818		}
21819	}
21820	return
21821}
21822
21823// VirtualNetworkGatewaysGetLearnedRoutesFuture an abstraction for monitoring and retrieving the results of a
21824// long-running operation.
21825type VirtualNetworkGatewaysGetLearnedRoutesFuture struct {
21826	azure.Future
21827}
21828
21829// Result returns the result of the asynchronous operation.
21830// If the operation has not completed it will return an error.
21831func (future *VirtualNetworkGatewaysGetLearnedRoutesFuture) Result(client VirtualNetworkGatewaysClient) (grlr GatewayRouteListResult, err error) {
21832	var done bool
21833	done, err = future.Done(client)
21834	if err != nil {
21835		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysGetLearnedRoutesFuture", "Result", future.Response(), "Polling failure")
21836		return
21837	}
21838	if !done {
21839		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysGetLearnedRoutesFuture")
21840		return
21841	}
21842	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
21843	if grlr.Response.Response, err = future.GetResult(sender); err == nil && grlr.Response.Response.StatusCode != http.StatusNoContent {
21844		grlr, err = client.GetLearnedRoutesResponder(grlr.Response.Response)
21845		if err != nil {
21846			err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysGetLearnedRoutesFuture", "Result", grlr.Response.Response, "Failure responding to request")
21847		}
21848	}
21849	return
21850}
21851
21852// VirtualNetworkGatewaysGetVpnclientIpsecParametersFuture an abstraction for monitoring and retrieving the results
21853// of a long-running operation.
21854type VirtualNetworkGatewaysGetVpnclientIpsecParametersFuture struct {
21855	azure.Future
21856}
21857
21858// Result returns the result of the asynchronous operation.
21859// If the operation has not completed it will return an error.
21860func (future *VirtualNetworkGatewaysGetVpnclientIpsecParametersFuture) Result(client VirtualNetworkGatewaysClient) (vcipp VpnClientIPsecParameters, err error) {
21861	var done bool
21862	done, err = future.Done(client)
21863	if err != nil {
21864		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysGetVpnclientIpsecParametersFuture", "Result", future.Response(), "Polling failure")
21865		return
21866	}
21867	if !done {
21868		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysGetVpnclientIpsecParametersFuture")
21869		return
21870	}
21871	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
21872	if vcipp.Response.Response, err = future.GetResult(sender); err == nil && vcipp.Response.Response.StatusCode != http.StatusNoContent {
21873		vcipp, err = client.GetVpnclientIpsecParametersResponder(vcipp.Response.Response)
21874		if err != nil {
21875			err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysGetVpnclientIpsecParametersFuture", "Result", vcipp.Response.Response, "Failure responding to request")
21876		}
21877	}
21878	return
21879}
21880
21881// VirtualNetworkGatewaysGetVpnProfilePackageURLFuture an abstraction for monitoring and retrieving the results of
21882// a long-running operation.
21883type VirtualNetworkGatewaysGetVpnProfilePackageURLFuture struct {
21884	azure.Future
21885}
21886
21887// Result returns the result of the asynchronous operation.
21888// If the operation has not completed it will return an error.
21889func (future *VirtualNetworkGatewaysGetVpnProfilePackageURLFuture) Result(client VirtualNetworkGatewaysClient) (s String, err error) {
21890	var done bool
21891	done, err = future.Done(client)
21892	if err != nil {
21893		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysGetVpnProfilePackageURLFuture", "Result", future.Response(), "Polling failure")
21894		return
21895	}
21896	if !done {
21897		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysGetVpnProfilePackageURLFuture")
21898		return
21899	}
21900	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
21901	if s.Response.Response, err = future.GetResult(sender); err == nil && s.Response.Response.StatusCode != http.StatusNoContent {
21902		s, err = client.GetVpnProfilePackageURLResponder(s.Response.Response)
21903		if err != nil {
21904			err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysGetVpnProfilePackageURLFuture", "Result", s.Response.Response, "Failure responding to request")
21905		}
21906	}
21907	return
21908}
21909
21910// VirtualNetworkGatewaySku virtualNetworkGatewaySku details
21911type VirtualNetworkGatewaySku struct {
21912	// Name - Gateway SKU name. Possible values include: 'VirtualNetworkGatewaySkuNameBasic', 'VirtualNetworkGatewaySkuNameHighPerformance', 'VirtualNetworkGatewaySkuNameStandard', 'VirtualNetworkGatewaySkuNameUltraPerformance', 'VirtualNetworkGatewaySkuNameVpnGw1', 'VirtualNetworkGatewaySkuNameVpnGw2', 'VirtualNetworkGatewaySkuNameVpnGw3', 'VirtualNetworkGatewaySkuNameVpnGw1AZ', 'VirtualNetworkGatewaySkuNameVpnGw2AZ', 'VirtualNetworkGatewaySkuNameVpnGw3AZ', 'VirtualNetworkGatewaySkuNameErGw1AZ', 'VirtualNetworkGatewaySkuNameErGw2AZ', 'VirtualNetworkGatewaySkuNameErGw3AZ'
21913	Name VirtualNetworkGatewaySkuName `json:"name,omitempty"`
21914	// Tier - Gateway SKU tier. Possible values include: 'VirtualNetworkGatewaySkuTierBasic', 'VirtualNetworkGatewaySkuTierHighPerformance', 'VirtualNetworkGatewaySkuTierStandard', 'VirtualNetworkGatewaySkuTierUltraPerformance', 'VirtualNetworkGatewaySkuTierVpnGw1', 'VirtualNetworkGatewaySkuTierVpnGw2', 'VirtualNetworkGatewaySkuTierVpnGw3', 'VirtualNetworkGatewaySkuTierVpnGw1AZ', 'VirtualNetworkGatewaySkuTierVpnGw2AZ', 'VirtualNetworkGatewaySkuTierVpnGw3AZ', 'VirtualNetworkGatewaySkuTierErGw1AZ', 'VirtualNetworkGatewaySkuTierErGw2AZ', 'VirtualNetworkGatewaySkuTierErGw3AZ'
21915	Tier VirtualNetworkGatewaySkuTier `json:"tier,omitempty"`
21916	// Capacity - The capacity.
21917	Capacity *int32 `json:"capacity,omitempty"`
21918}
21919
21920// VirtualNetworkGatewaysResetFuture an abstraction for monitoring and retrieving the results of a long-running
21921// operation.
21922type VirtualNetworkGatewaysResetFuture struct {
21923	azure.Future
21924}
21925
21926// Result returns the result of the asynchronous operation.
21927// If the operation has not completed it will return an error.
21928func (future *VirtualNetworkGatewaysResetFuture) Result(client VirtualNetworkGatewaysClient) (vng VirtualNetworkGateway, err error) {
21929	var done bool
21930	done, err = future.Done(client)
21931	if err != nil {
21932		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysResetFuture", "Result", future.Response(), "Polling failure")
21933		return
21934	}
21935	if !done {
21936		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysResetFuture")
21937		return
21938	}
21939	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
21940	if vng.Response.Response, err = future.GetResult(sender); err == nil && vng.Response.Response.StatusCode != http.StatusNoContent {
21941		vng, err = client.ResetResponder(vng.Response.Response)
21942		if err != nil {
21943			err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysResetFuture", "Result", vng.Response.Response, "Failure responding to request")
21944		}
21945	}
21946	return
21947}
21948
21949// VirtualNetworkGatewaysResetVpnClientSharedKeyFuture an abstraction for monitoring and retrieving the results of
21950// a long-running operation.
21951type VirtualNetworkGatewaysResetVpnClientSharedKeyFuture struct {
21952	azure.Future
21953}
21954
21955// Result returns the result of the asynchronous operation.
21956// If the operation has not completed it will return an error.
21957func (future *VirtualNetworkGatewaysResetVpnClientSharedKeyFuture) Result(client VirtualNetworkGatewaysClient) (ar autorest.Response, err error) {
21958	var done bool
21959	done, err = future.Done(client)
21960	if err != nil {
21961		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysResetVpnClientSharedKeyFuture", "Result", future.Response(), "Polling failure")
21962		return
21963	}
21964	if !done {
21965		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysResetVpnClientSharedKeyFuture")
21966		return
21967	}
21968	ar.Response = future.Response()
21969	return
21970}
21971
21972// VirtualNetworkGatewaysSetVpnclientIpsecParametersFuture an abstraction for monitoring and retrieving the results
21973// of a long-running operation.
21974type VirtualNetworkGatewaysSetVpnclientIpsecParametersFuture struct {
21975	azure.Future
21976}
21977
21978// Result returns the result of the asynchronous operation.
21979// If the operation has not completed it will return an error.
21980func (future *VirtualNetworkGatewaysSetVpnclientIpsecParametersFuture) Result(client VirtualNetworkGatewaysClient) (vcipp VpnClientIPsecParameters, err error) {
21981	var done bool
21982	done, err = future.Done(client)
21983	if err != nil {
21984		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysSetVpnclientIpsecParametersFuture", "Result", future.Response(), "Polling failure")
21985		return
21986	}
21987	if !done {
21988		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysSetVpnclientIpsecParametersFuture")
21989		return
21990	}
21991	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
21992	if vcipp.Response.Response, err = future.GetResult(sender); err == nil && vcipp.Response.Response.StatusCode != http.StatusNoContent {
21993		vcipp, err = client.SetVpnclientIpsecParametersResponder(vcipp.Response.Response)
21994		if err != nil {
21995			err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysSetVpnclientIpsecParametersFuture", "Result", vcipp.Response.Response, "Failure responding to request")
21996		}
21997	}
21998	return
21999}
22000
22001// VirtualNetworkGatewaysUpdateTagsFuture an abstraction for monitoring and retrieving the results of a
22002// long-running operation.
22003type VirtualNetworkGatewaysUpdateTagsFuture struct {
22004	azure.Future
22005}
22006
22007// Result returns the result of the asynchronous operation.
22008// If the operation has not completed it will return an error.
22009func (future *VirtualNetworkGatewaysUpdateTagsFuture) Result(client VirtualNetworkGatewaysClient) (vng VirtualNetworkGateway, err error) {
22010	var done bool
22011	done, err = future.Done(client)
22012	if err != nil {
22013		err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysUpdateTagsFuture", "Result", future.Response(), "Polling failure")
22014		return
22015	}
22016	if !done {
22017		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysUpdateTagsFuture")
22018		return
22019	}
22020	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
22021	if vng.Response.Response, err = future.GetResult(sender); err == nil && vng.Response.Response.StatusCode != http.StatusNoContent {
22022		vng, err = client.UpdateTagsResponder(vng.Response.Response)
22023		if err != nil {
22024			err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysUpdateTagsFuture", "Result", vng.Response.Response, "Failure responding to request")
22025		}
22026	}
22027	return
22028}
22029
22030// VirtualNetworkListResult response for the ListVirtualNetworks API service call.
22031type VirtualNetworkListResult struct {
22032	autorest.Response `json:"-"`
22033	// Value - Gets a list of VirtualNetwork resources in a resource group.
22034	Value *[]VirtualNetwork `json:"value,omitempty"`
22035	// NextLink - The URL to get the next set of results.
22036	NextLink *string `json:"nextLink,omitempty"`
22037}
22038
22039// VirtualNetworkListResultIterator provides access to a complete listing of VirtualNetwork values.
22040type VirtualNetworkListResultIterator struct {
22041	i    int
22042	page VirtualNetworkListResultPage
22043}
22044
22045// Next advances to the next value.  If there was an error making
22046// the request the iterator does not advance and the error is returned.
22047func (iter *VirtualNetworkListResultIterator) Next() error {
22048	iter.i++
22049	if iter.i < len(iter.page.Values()) {
22050		return nil
22051	}
22052	err := iter.page.Next()
22053	if err != nil {
22054		iter.i--
22055		return err
22056	}
22057	iter.i = 0
22058	return nil
22059}
22060
22061// NotDone returns true if the enumeration should be started or is not yet complete.
22062func (iter VirtualNetworkListResultIterator) NotDone() bool {
22063	return iter.page.NotDone() && iter.i < len(iter.page.Values())
22064}
22065
22066// Response returns the raw server response from the last page request.
22067func (iter VirtualNetworkListResultIterator) Response() VirtualNetworkListResult {
22068	return iter.page.Response()
22069}
22070
22071// Value returns the current value or a zero-initialized value if the
22072// iterator has advanced beyond the end of the collection.
22073func (iter VirtualNetworkListResultIterator) Value() VirtualNetwork {
22074	if !iter.page.NotDone() {
22075		return VirtualNetwork{}
22076	}
22077	return iter.page.Values()[iter.i]
22078}
22079
22080// IsEmpty returns true if the ListResult contains no values.
22081func (vnlr VirtualNetworkListResult) IsEmpty() bool {
22082	return vnlr.Value == nil || len(*vnlr.Value) == 0
22083}
22084
22085// virtualNetworkListResultPreparer prepares a request to retrieve the next set of results.
22086// It returns nil if no more results exist.
22087func (vnlr VirtualNetworkListResult) virtualNetworkListResultPreparer() (*http.Request, error) {
22088	if vnlr.NextLink == nil || len(to.String(vnlr.NextLink)) < 1 {
22089		return nil, nil
22090	}
22091	return autorest.Prepare(&http.Request{},
22092		autorest.AsJSON(),
22093		autorest.AsGet(),
22094		autorest.WithBaseURL(to.String(vnlr.NextLink)))
22095}
22096
22097// VirtualNetworkListResultPage contains a page of VirtualNetwork values.
22098type VirtualNetworkListResultPage struct {
22099	fn   func(VirtualNetworkListResult) (VirtualNetworkListResult, error)
22100	vnlr VirtualNetworkListResult
22101}
22102
22103// Next advances to the next page of values.  If there was an error making
22104// the request the page does not advance and the error is returned.
22105func (page *VirtualNetworkListResultPage) Next() error {
22106	next, err := page.fn(page.vnlr)
22107	if err != nil {
22108		return err
22109	}
22110	page.vnlr = next
22111	return nil
22112}
22113
22114// NotDone returns true if the page enumeration should be started or is not yet complete.
22115func (page VirtualNetworkListResultPage) NotDone() bool {
22116	return !page.vnlr.IsEmpty()
22117}
22118
22119// Response returns the raw server response from the last page request.
22120func (page VirtualNetworkListResultPage) Response() VirtualNetworkListResult {
22121	return page.vnlr
22122}
22123
22124// Values returns the slice of values for the current page or nil if there are no values.
22125func (page VirtualNetworkListResultPage) Values() []VirtualNetwork {
22126	if page.vnlr.IsEmpty() {
22127		return nil
22128	}
22129	return *page.vnlr.Value
22130}
22131
22132// VirtualNetworkListUsageResult response for the virtual networks GetUsage API service call.
22133type VirtualNetworkListUsageResult struct {
22134	autorest.Response `json:"-"`
22135	// Value - VirtualNetwork usage stats.
22136	Value *[]VirtualNetworkUsage `json:"value,omitempty"`
22137	// NextLink - The URL to get the next set of results.
22138	NextLink *string `json:"nextLink,omitempty"`
22139}
22140
22141// VirtualNetworkListUsageResultIterator provides access to a complete listing of VirtualNetworkUsage values.
22142type VirtualNetworkListUsageResultIterator struct {
22143	i    int
22144	page VirtualNetworkListUsageResultPage
22145}
22146
22147// Next advances to the next value.  If there was an error making
22148// the request the iterator does not advance and the error is returned.
22149func (iter *VirtualNetworkListUsageResultIterator) Next() error {
22150	iter.i++
22151	if iter.i < len(iter.page.Values()) {
22152		return nil
22153	}
22154	err := iter.page.Next()
22155	if err != nil {
22156		iter.i--
22157		return err
22158	}
22159	iter.i = 0
22160	return nil
22161}
22162
22163// NotDone returns true if the enumeration should be started or is not yet complete.
22164func (iter VirtualNetworkListUsageResultIterator) NotDone() bool {
22165	return iter.page.NotDone() && iter.i < len(iter.page.Values())
22166}
22167
22168// Response returns the raw server response from the last page request.
22169func (iter VirtualNetworkListUsageResultIterator) Response() VirtualNetworkListUsageResult {
22170	return iter.page.Response()
22171}
22172
22173// Value returns the current value or a zero-initialized value if the
22174// iterator has advanced beyond the end of the collection.
22175func (iter VirtualNetworkListUsageResultIterator) Value() VirtualNetworkUsage {
22176	if !iter.page.NotDone() {
22177		return VirtualNetworkUsage{}
22178	}
22179	return iter.page.Values()[iter.i]
22180}
22181
22182// IsEmpty returns true if the ListResult contains no values.
22183func (vnlur VirtualNetworkListUsageResult) IsEmpty() bool {
22184	return vnlur.Value == nil || len(*vnlur.Value) == 0
22185}
22186
22187// virtualNetworkListUsageResultPreparer prepares a request to retrieve the next set of results.
22188// It returns nil if no more results exist.
22189func (vnlur VirtualNetworkListUsageResult) virtualNetworkListUsageResultPreparer() (*http.Request, error) {
22190	if vnlur.NextLink == nil || len(to.String(vnlur.NextLink)) < 1 {
22191		return nil, nil
22192	}
22193	return autorest.Prepare(&http.Request{},
22194		autorest.AsJSON(),
22195		autorest.AsGet(),
22196		autorest.WithBaseURL(to.String(vnlur.NextLink)))
22197}
22198
22199// VirtualNetworkListUsageResultPage contains a page of VirtualNetworkUsage values.
22200type VirtualNetworkListUsageResultPage struct {
22201	fn    func(VirtualNetworkListUsageResult) (VirtualNetworkListUsageResult, error)
22202	vnlur VirtualNetworkListUsageResult
22203}
22204
22205// Next advances to the next page of values.  If there was an error making
22206// the request the page does not advance and the error is returned.
22207func (page *VirtualNetworkListUsageResultPage) Next() error {
22208	next, err := page.fn(page.vnlur)
22209	if err != nil {
22210		return err
22211	}
22212	page.vnlur = next
22213	return nil
22214}
22215
22216// NotDone returns true if the page enumeration should be started or is not yet complete.
22217func (page VirtualNetworkListUsageResultPage) NotDone() bool {
22218	return !page.vnlur.IsEmpty()
22219}
22220
22221// Response returns the raw server response from the last page request.
22222func (page VirtualNetworkListUsageResultPage) Response() VirtualNetworkListUsageResult {
22223	return page.vnlur
22224}
22225
22226// Values returns the slice of values for the current page or nil if there are no values.
22227func (page VirtualNetworkListUsageResultPage) Values() []VirtualNetworkUsage {
22228	if page.vnlur.IsEmpty() {
22229		return nil
22230	}
22231	return *page.vnlur.Value
22232}
22233
22234// VirtualNetworkPeering peerings in a virtual network resource.
22235type VirtualNetworkPeering struct {
22236	autorest.Response `json:"-"`
22237	// VirtualNetworkPeeringPropertiesFormat - Properties of the virtual network peering.
22238	*VirtualNetworkPeeringPropertiesFormat `json:"properties,omitempty"`
22239	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
22240	Name *string `json:"name,omitempty"`
22241	// Etag - A unique read-only string that changes whenever the resource is updated.
22242	Etag *string `json:"etag,omitempty"`
22243	// ID - Resource ID.
22244	ID *string `json:"id,omitempty"`
22245}
22246
22247// MarshalJSON is the custom marshaler for VirtualNetworkPeering.
22248func (vnp VirtualNetworkPeering) MarshalJSON() ([]byte, error) {
22249	objectMap := make(map[string]interface{})
22250	if vnp.VirtualNetworkPeeringPropertiesFormat != nil {
22251		objectMap["properties"] = vnp.VirtualNetworkPeeringPropertiesFormat
22252	}
22253	if vnp.Name != nil {
22254		objectMap["name"] = vnp.Name
22255	}
22256	if vnp.Etag != nil {
22257		objectMap["etag"] = vnp.Etag
22258	}
22259	if vnp.ID != nil {
22260		objectMap["id"] = vnp.ID
22261	}
22262	return json.Marshal(objectMap)
22263}
22264
22265// UnmarshalJSON is the custom unmarshaler for VirtualNetworkPeering struct.
22266func (vnp *VirtualNetworkPeering) UnmarshalJSON(body []byte) error {
22267	var m map[string]*json.RawMessage
22268	err := json.Unmarshal(body, &m)
22269	if err != nil {
22270		return err
22271	}
22272	for k, v := range m {
22273		switch k {
22274		case "properties":
22275			if v != nil {
22276				var virtualNetworkPeeringPropertiesFormat VirtualNetworkPeeringPropertiesFormat
22277				err = json.Unmarshal(*v, &virtualNetworkPeeringPropertiesFormat)
22278				if err != nil {
22279					return err
22280				}
22281				vnp.VirtualNetworkPeeringPropertiesFormat = &virtualNetworkPeeringPropertiesFormat
22282			}
22283		case "name":
22284			if v != nil {
22285				var name string
22286				err = json.Unmarshal(*v, &name)
22287				if err != nil {
22288					return err
22289				}
22290				vnp.Name = &name
22291			}
22292		case "etag":
22293			if v != nil {
22294				var etag string
22295				err = json.Unmarshal(*v, &etag)
22296				if err != nil {
22297					return err
22298				}
22299				vnp.Etag = &etag
22300			}
22301		case "id":
22302			if v != nil {
22303				var ID string
22304				err = json.Unmarshal(*v, &ID)
22305				if err != nil {
22306					return err
22307				}
22308				vnp.ID = &ID
22309			}
22310		}
22311	}
22312
22313	return nil
22314}
22315
22316// VirtualNetworkPeeringListResult response for ListSubnets API service call. Retrieves all subnets that belong to
22317// a virtual network.
22318type VirtualNetworkPeeringListResult struct {
22319	autorest.Response `json:"-"`
22320	// Value - The peerings in a virtual network.
22321	Value *[]VirtualNetworkPeering `json:"value,omitempty"`
22322	// NextLink - The URL to get the next set of results.
22323	NextLink *string `json:"nextLink,omitempty"`
22324}
22325
22326// VirtualNetworkPeeringListResultIterator provides access to a complete listing of VirtualNetworkPeering values.
22327type VirtualNetworkPeeringListResultIterator struct {
22328	i    int
22329	page VirtualNetworkPeeringListResultPage
22330}
22331
22332// Next advances to the next value.  If there was an error making
22333// the request the iterator does not advance and the error is returned.
22334func (iter *VirtualNetworkPeeringListResultIterator) Next() error {
22335	iter.i++
22336	if iter.i < len(iter.page.Values()) {
22337		return nil
22338	}
22339	err := iter.page.Next()
22340	if err != nil {
22341		iter.i--
22342		return err
22343	}
22344	iter.i = 0
22345	return nil
22346}
22347
22348// NotDone returns true if the enumeration should be started or is not yet complete.
22349func (iter VirtualNetworkPeeringListResultIterator) NotDone() bool {
22350	return iter.page.NotDone() && iter.i < len(iter.page.Values())
22351}
22352
22353// Response returns the raw server response from the last page request.
22354func (iter VirtualNetworkPeeringListResultIterator) Response() VirtualNetworkPeeringListResult {
22355	return iter.page.Response()
22356}
22357
22358// Value returns the current value or a zero-initialized value if the
22359// iterator has advanced beyond the end of the collection.
22360func (iter VirtualNetworkPeeringListResultIterator) Value() VirtualNetworkPeering {
22361	if !iter.page.NotDone() {
22362		return VirtualNetworkPeering{}
22363	}
22364	return iter.page.Values()[iter.i]
22365}
22366
22367// IsEmpty returns true if the ListResult contains no values.
22368func (vnplr VirtualNetworkPeeringListResult) IsEmpty() bool {
22369	return vnplr.Value == nil || len(*vnplr.Value) == 0
22370}
22371
22372// virtualNetworkPeeringListResultPreparer prepares a request to retrieve the next set of results.
22373// It returns nil if no more results exist.
22374func (vnplr VirtualNetworkPeeringListResult) virtualNetworkPeeringListResultPreparer() (*http.Request, error) {
22375	if vnplr.NextLink == nil || len(to.String(vnplr.NextLink)) < 1 {
22376		return nil, nil
22377	}
22378	return autorest.Prepare(&http.Request{},
22379		autorest.AsJSON(),
22380		autorest.AsGet(),
22381		autorest.WithBaseURL(to.String(vnplr.NextLink)))
22382}
22383
22384// VirtualNetworkPeeringListResultPage contains a page of VirtualNetworkPeering values.
22385type VirtualNetworkPeeringListResultPage struct {
22386	fn    func(VirtualNetworkPeeringListResult) (VirtualNetworkPeeringListResult, error)
22387	vnplr VirtualNetworkPeeringListResult
22388}
22389
22390// Next advances to the next page of values.  If there was an error making
22391// the request the page does not advance and the error is returned.
22392func (page *VirtualNetworkPeeringListResultPage) Next() error {
22393	next, err := page.fn(page.vnplr)
22394	if err != nil {
22395		return err
22396	}
22397	page.vnplr = next
22398	return nil
22399}
22400
22401// NotDone returns true if the page enumeration should be started or is not yet complete.
22402func (page VirtualNetworkPeeringListResultPage) NotDone() bool {
22403	return !page.vnplr.IsEmpty()
22404}
22405
22406// Response returns the raw server response from the last page request.
22407func (page VirtualNetworkPeeringListResultPage) Response() VirtualNetworkPeeringListResult {
22408	return page.vnplr
22409}
22410
22411// Values returns the slice of values for the current page or nil if there are no values.
22412func (page VirtualNetworkPeeringListResultPage) Values() []VirtualNetworkPeering {
22413	if page.vnplr.IsEmpty() {
22414		return nil
22415	}
22416	return *page.vnplr.Value
22417}
22418
22419// VirtualNetworkPeeringPropertiesFormat properties of the virtual network peering.
22420type VirtualNetworkPeeringPropertiesFormat struct {
22421	// AllowVirtualNetworkAccess - Whether the VMs in the linked virtual network space would be able to access all the VMs in local Virtual network space.
22422	AllowVirtualNetworkAccess *bool `json:"allowVirtualNetworkAccess,omitempty"`
22423	// AllowForwardedTraffic - Whether the forwarded traffic from the VMs in the remote virtual network will be allowed/disallowed.
22424	AllowForwardedTraffic *bool `json:"allowForwardedTraffic,omitempty"`
22425	// AllowGatewayTransit - If gateway links can be used in remote virtual networking to link to this virtual network.
22426	AllowGatewayTransit *bool `json:"allowGatewayTransit,omitempty"`
22427	// 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.
22428	UseRemoteGateways *bool `json:"useRemoteGateways,omitempty"`
22429	// 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).
22430	RemoteVirtualNetwork *SubResource `json:"remoteVirtualNetwork,omitempty"`
22431	// RemoteAddressSpace - The reference of the remote virtual network address space.
22432	RemoteAddressSpace *AddressSpace `json:"remoteAddressSpace,omitempty"`
22433	// PeeringState - The status of the virtual network peering. Possible values are 'Initiated', 'Connected', and 'Disconnected'. Possible values include: 'VirtualNetworkPeeringStateInitiated', 'VirtualNetworkPeeringStateConnected', 'VirtualNetworkPeeringStateDisconnected'
22434	PeeringState VirtualNetworkPeeringState `json:"peeringState,omitempty"`
22435	// ProvisioningState - The provisioning state of the resource.
22436	ProvisioningState *string `json:"provisioningState,omitempty"`
22437}
22438
22439// VirtualNetworkPeeringsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
22440// long-running operation.
22441type VirtualNetworkPeeringsCreateOrUpdateFuture struct {
22442	azure.Future
22443}
22444
22445// Result returns the result of the asynchronous operation.
22446// If the operation has not completed it will return an error.
22447func (future *VirtualNetworkPeeringsCreateOrUpdateFuture) Result(client VirtualNetworkPeeringsClient) (vnp VirtualNetworkPeering, err error) {
22448	var done bool
22449	done, err = future.Done(client)
22450	if err != nil {
22451		err = autorest.NewErrorWithError(err, "network.VirtualNetworkPeeringsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
22452		return
22453	}
22454	if !done {
22455		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkPeeringsCreateOrUpdateFuture")
22456		return
22457	}
22458	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
22459	if vnp.Response.Response, err = future.GetResult(sender); err == nil && vnp.Response.Response.StatusCode != http.StatusNoContent {
22460		vnp, err = client.CreateOrUpdateResponder(vnp.Response.Response)
22461		if err != nil {
22462			err = autorest.NewErrorWithError(err, "network.VirtualNetworkPeeringsCreateOrUpdateFuture", "Result", vnp.Response.Response, "Failure responding to request")
22463		}
22464	}
22465	return
22466}
22467
22468// VirtualNetworkPeeringsDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
22469// operation.
22470type VirtualNetworkPeeringsDeleteFuture struct {
22471	azure.Future
22472}
22473
22474// Result returns the result of the asynchronous operation.
22475// If the operation has not completed it will return an error.
22476func (future *VirtualNetworkPeeringsDeleteFuture) Result(client VirtualNetworkPeeringsClient) (ar autorest.Response, err error) {
22477	var done bool
22478	done, err = future.Done(client)
22479	if err != nil {
22480		err = autorest.NewErrorWithError(err, "network.VirtualNetworkPeeringsDeleteFuture", "Result", future.Response(), "Polling failure")
22481		return
22482	}
22483	if !done {
22484		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkPeeringsDeleteFuture")
22485		return
22486	}
22487	ar.Response = future.Response()
22488	return
22489}
22490
22491// VirtualNetworkPropertiesFormat properties of the virtual network.
22492type VirtualNetworkPropertiesFormat struct {
22493	// AddressSpace - The AddressSpace that contains an array of IP address ranges that can be used by subnets.
22494	AddressSpace *AddressSpace `json:"addressSpace,omitempty"`
22495	// DhcpOptions - The dhcpOptions that contains an array of DNS servers available to VMs deployed in the virtual network.
22496	DhcpOptions *DhcpOptions `json:"dhcpOptions,omitempty"`
22497	// Subnets - A list of subnets in a Virtual Network.
22498	Subnets *[]Subnet `json:"subnets,omitempty"`
22499	// VirtualNetworkPeerings - A list of peerings in a Virtual Network.
22500	VirtualNetworkPeerings *[]VirtualNetworkPeering `json:"virtualNetworkPeerings,omitempty"`
22501	// ResourceGUID - The resourceGuid property of the Virtual Network resource.
22502	ResourceGUID *string `json:"resourceGuid,omitempty"`
22503	// ProvisioningState - The provisioning state of the PublicIP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
22504	ProvisioningState *string `json:"provisioningState,omitempty"`
22505	// 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.
22506	EnableDdosProtection *bool `json:"enableDdosProtection,omitempty"`
22507	// EnableVMProtection - Indicates if VM protection is enabled for all the subnets in the virtual network.
22508	EnableVMProtection *bool `json:"enableVmProtection,omitempty"`
22509	// DdosProtectionPlan - The DDoS protection plan associated with the virtual network.
22510	DdosProtectionPlan *SubResource `json:"ddosProtectionPlan,omitempty"`
22511}
22512
22513// VirtualNetworksCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
22514// operation.
22515type VirtualNetworksCreateOrUpdateFuture struct {
22516	azure.Future
22517}
22518
22519// Result returns the result of the asynchronous operation.
22520// If the operation has not completed it will return an error.
22521func (future *VirtualNetworksCreateOrUpdateFuture) Result(client VirtualNetworksClient) (vn VirtualNetwork, err error) {
22522	var done bool
22523	done, err = future.Done(client)
22524	if err != nil {
22525		err = autorest.NewErrorWithError(err, "network.VirtualNetworksCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
22526		return
22527	}
22528	if !done {
22529		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworksCreateOrUpdateFuture")
22530		return
22531	}
22532	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
22533	if vn.Response.Response, err = future.GetResult(sender); err == nil && vn.Response.Response.StatusCode != http.StatusNoContent {
22534		vn, err = client.CreateOrUpdateResponder(vn.Response.Response)
22535		if err != nil {
22536			err = autorest.NewErrorWithError(err, "network.VirtualNetworksCreateOrUpdateFuture", "Result", vn.Response.Response, "Failure responding to request")
22537		}
22538	}
22539	return
22540}
22541
22542// VirtualNetworksDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
22543// operation.
22544type VirtualNetworksDeleteFuture struct {
22545	azure.Future
22546}
22547
22548// Result returns the result of the asynchronous operation.
22549// If the operation has not completed it will return an error.
22550func (future *VirtualNetworksDeleteFuture) Result(client VirtualNetworksClient) (ar autorest.Response, err error) {
22551	var done bool
22552	done, err = future.Done(client)
22553	if err != nil {
22554		err = autorest.NewErrorWithError(err, "network.VirtualNetworksDeleteFuture", "Result", future.Response(), "Polling failure")
22555		return
22556	}
22557	if !done {
22558		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworksDeleteFuture")
22559		return
22560	}
22561	ar.Response = future.Response()
22562	return
22563}
22564
22565// VirtualNetworksUpdateTagsFuture an abstraction for monitoring and retrieving the results of a long-running
22566// operation.
22567type VirtualNetworksUpdateTagsFuture struct {
22568	azure.Future
22569}
22570
22571// Result returns the result of the asynchronous operation.
22572// If the operation has not completed it will return an error.
22573func (future *VirtualNetworksUpdateTagsFuture) Result(client VirtualNetworksClient) (vn VirtualNetwork, err error) {
22574	var done bool
22575	done, err = future.Done(client)
22576	if err != nil {
22577		err = autorest.NewErrorWithError(err, "network.VirtualNetworksUpdateTagsFuture", "Result", future.Response(), "Polling failure")
22578		return
22579	}
22580	if !done {
22581		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworksUpdateTagsFuture")
22582		return
22583	}
22584	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
22585	if vn.Response.Response, err = future.GetResult(sender); err == nil && vn.Response.Response.StatusCode != http.StatusNoContent {
22586		vn, err = client.UpdateTagsResponder(vn.Response.Response)
22587		if err != nil {
22588			err = autorest.NewErrorWithError(err, "network.VirtualNetworksUpdateTagsFuture", "Result", vn.Response.Response, "Failure responding to request")
22589		}
22590	}
22591	return
22592}
22593
22594// VirtualNetworkTap virtual Network Tap resource
22595type VirtualNetworkTap struct {
22596	autorest.Response `json:"-"`
22597	// VirtualNetworkTapPropertiesFormat - Virtual Network Tap Properties.
22598	*VirtualNetworkTapPropertiesFormat `json:"properties,omitempty"`
22599	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
22600	Etag *string `json:"etag,omitempty"`
22601	// ID - Resource ID.
22602	ID *string `json:"id,omitempty"`
22603	// Name - Resource name.
22604	Name *string `json:"name,omitempty"`
22605	// Type - Resource type.
22606	Type *string `json:"type,omitempty"`
22607	// Location - Resource location.
22608	Location *string `json:"location,omitempty"`
22609	// Tags - Resource tags.
22610	Tags map[string]*string `json:"tags"`
22611}
22612
22613// MarshalJSON is the custom marshaler for VirtualNetworkTap.
22614func (vnt VirtualNetworkTap) MarshalJSON() ([]byte, error) {
22615	objectMap := make(map[string]interface{})
22616	if vnt.VirtualNetworkTapPropertiesFormat != nil {
22617		objectMap["properties"] = vnt.VirtualNetworkTapPropertiesFormat
22618	}
22619	if vnt.Etag != nil {
22620		objectMap["etag"] = vnt.Etag
22621	}
22622	if vnt.ID != nil {
22623		objectMap["id"] = vnt.ID
22624	}
22625	if vnt.Name != nil {
22626		objectMap["name"] = vnt.Name
22627	}
22628	if vnt.Type != nil {
22629		objectMap["type"] = vnt.Type
22630	}
22631	if vnt.Location != nil {
22632		objectMap["location"] = vnt.Location
22633	}
22634	if vnt.Tags != nil {
22635		objectMap["tags"] = vnt.Tags
22636	}
22637	return json.Marshal(objectMap)
22638}
22639
22640// UnmarshalJSON is the custom unmarshaler for VirtualNetworkTap struct.
22641func (vnt *VirtualNetworkTap) UnmarshalJSON(body []byte) error {
22642	var m map[string]*json.RawMessage
22643	err := json.Unmarshal(body, &m)
22644	if err != nil {
22645		return err
22646	}
22647	for k, v := range m {
22648		switch k {
22649		case "properties":
22650			if v != nil {
22651				var virtualNetworkTapPropertiesFormat VirtualNetworkTapPropertiesFormat
22652				err = json.Unmarshal(*v, &virtualNetworkTapPropertiesFormat)
22653				if err != nil {
22654					return err
22655				}
22656				vnt.VirtualNetworkTapPropertiesFormat = &virtualNetworkTapPropertiesFormat
22657			}
22658		case "etag":
22659			if v != nil {
22660				var etag string
22661				err = json.Unmarshal(*v, &etag)
22662				if err != nil {
22663					return err
22664				}
22665				vnt.Etag = &etag
22666			}
22667		case "id":
22668			if v != nil {
22669				var ID string
22670				err = json.Unmarshal(*v, &ID)
22671				if err != nil {
22672					return err
22673				}
22674				vnt.ID = &ID
22675			}
22676		case "name":
22677			if v != nil {
22678				var name string
22679				err = json.Unmarshal(*v, &name)
22680				if err != nil {
22681					return err
22682				}
22683				vnt.Name = &name
22684			}
22685		case "type":
22686			if v != nil {
22687				var typeVar string
22688				err = json.Unmarshal(*v, &typeVar)
22689				if err != nil {
22690					return err
22691				}
22692				vnt.Type = &typeVar
22693			}
22694		case "location":
22695			if v != nil {
22696				var location string
22697				err = json.Unmarshal(*v, &location)
22698				if err != nil {
22699					return err
22700				}
22701				vnt.Location = &location
22702			}
22703		case "tags":
22704			if v != nil {
22705				var tags map[string]*string
22706				err = json.Unmarshal(*v, &tags)
22707				if err != nil {
22708					return err
22709				}
22710				vnt.Tags = tags
22711			}
22712		}
22713	}
22714
22715	return nil
22716}
22717
22718// VirtualNetworkTapListResult response for ListVirtualNetworkTap API service call.
22719type VirtualNetworkTapListResult struct {
22720	autorest.Response `json:"-"`
22721	// Value - A list of VirtualNetworkTaps in a resource group.
22722	Value *[]VirtualNetworkTap `json:"value,omitempty"`
22723	// NextLink - The URL to get the next set of results.
22724	NextLink *string `json:"nextLink,omitempty"`
22725}
22726
22727// VirtualNetworkTapListResultIterator provides access to a complete listing of VirtualNetworkTap values.
22728type VirtualNetworkTapListResultIterator struct {
22729	i    int
22730	page VirtualNetworkTapListResultPage
22731}
22732
22733// Next advances to the next value.  If there was an error making
22734// the request the iterator does not advance and the error is returned.
22735func (iter *VirtualNetworkTapListResultIterator) Next() error {
22736	iter.i++
22737	if iter.i < len(iter.page.Values()) {
22738		return nil
22739	}
22740	err := iter.page.Next()
22741	if err != nil {
22742		iter.i--
22743		return err
22744	}
22745	iter.i = 0
22746	return nil
22747}
22748
22749// NotDone returns true if the enumeration should be started or is not yet complete.
22750func (iter VirtualNetworkTapListResultIterator) NotDone() bool {
22751	return iter.page.NotDone() && iter.i < len(iter.page.Values())
22752}
22753
22754// Response returns the raw server response from the last page request.
22755func (iter VirtualNetworkTapListResultIterator) Response() VirtualNetworkTapListResult {
22756	return iter.page.Response()
22757}
22758
22759// Value returns the current value or a zero-initialized value if the
22760// iterator has advanced beyond the end of the collection.
22761func (iter VirtualNetworkTapListResultIterator) Value() VirtualNetworkTap {
22762	if !iter.page.NotDone() {
22763		return VirtualNetworkTap{}
22764	}
22765	return iter.page.Values()[iter.i]
22766}
22767
22768// IsEmpty returns true if the ListResult contains no values.
22769func (vntlr VirtualNetworkTapListResult) IsEmpty() bool {
22770	return vntlr.Value == nil || len(*vntlr.Value) == 0
22771}
22772
22773// virtualNetworkTapListResultPreparer prepares a request to retrieve the next set of results.
22774// It returns nil if no more results exist.
22775func (vntlr VirtualNetworkTapListResult) virtualNetworkTapListResultPreparer() (*http.Request, error) {
22776	if vntlr.NextLink == nil || len(to.String(vntlr.NextLink)) < 1 {
22777		return nil, nil
22778	}
22779	return autorest.Prepare(&http.Request{},
22780		autorest.AsJSON(),
22781		autorest.AsGet(),
22782		autorest.WithBaseURL(to.String(vntlr.NextLink)))
22783}
22784
22785// VirtualNetworkTapListResultPage contains a page of VirtualNetworkTap values.
22786type VirtualNetworkTapListResultPage struct {
22787	fn    func(VirtualNetworkTapListResult) (VirtualNetworkTapListResult, error)
22788	vntlr VirtualNetworkTapListResult
22789}
22790
22791// Next advances to the next page of values.  If there was an error making
22792// the request the page does not advance and the error is returned.
22793func (page *VirtualNetworkTapListResultPage) Next() error {
22794	next, err := page.fn(page.vntlr)
22795	if err != nil {
22796		return err
22797	}
22798	page.vntlr = next
22799	return nil
22800}
22801
22802// NotDone returns true if the page enumeration should be started or is not yet complete.
22803func (page VirtualNetworkTapListResultPage) NotDone() bool {
22804	return !page.vntlr.IsEmpty()
22805}
22806
22807// Response returns the raw server response from the last page request.
22808func (page VirtualNetworkTapListResultPage) Response() VirtualNetworkTapListResult {
22809	return page.vntlr
22810}
22811
22812// Values returns the slice of values for the current page or nil if there are no values.
22813func (page VirtualNetworkTapListResultPage) Values() []VirtualNetworkTap {
22814	if page.vntlr.IsEmpty() {
22815		return nil
22816	}
22817	return *page.vntlr.Value
22818}
22819
22820// VirtualNetworkTapPropertiesFormat virtual Network Tap properties.
22821type VirtualNetworkTapPropertiesFormat struct {
22822	// NetworkInterfaceTapConfigurations - Specifies the list of resource IDs for the network interface IP configuration that needs to be tapped.
22823	NetworkInterfaceTapConfigurations *[]InterfaceTapConfiguration `json:"networkInterfaceTapConfigurations,omitempty"`
22824	// ResourceGUID - The resourceGuid property of the virtual network tap.
22825	ResourceGUID *string `json:"resourceGuid,omitempty"`
22826	// ProvisioningState - The provisioning state of the virtual network tap. Possible values are: 'Updating', 'Deleting', and 'Failed'.
22827	ProvisioningState *string `json:"provisioningState,omitempty"`
22828	// DestinationNetworkInterfaceIPConfiguration - The reference to the private IP Address of the collector nic that will receive the tap
22829	DestinationNetworkInterfaceIPConfiguration *InterfaceIPConfiguration `json:"destinationNetworkInterfaceIPConfiguration,omitempty"`
22830	// DestinationLoadBalancerFrontEndIPConfiguration - The reference to the private IP address on the internal Load Balancer that will receive the tap
22831	DestinationLoadBalancerFrontEndIPConfiguration *FrontendIPConfiguration `json:"destinationLoadBalancerFrontEndIPConfiguration,omitempty"`
22832	// DestinationPort - The VXLAN destination port that will receive the tapped traffic.
22833	DestinationPort *int32 `json:"destinationPort,omitempty"`
22834}
22835
22836// VirtualNetworkTapsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
22837// long-running operation.
22838type VirtualNetworkTapsCreateOrUpdateFuture struct {
22839	azure.Future
22840}
22841
22842// Result returns the result of the asynchronous operation.
22843// If the operation has not completed it will return an error.
22844func (future *VirtualNetworkTapsCreateOrUpdateFuture) Result(client VirtualNetworkTapsClient) (vnt VirtualNetworkTap, err error) {
22845	var done bool
22846	done, err = future.Done(client)
22847	if err != nil {
22848		err = autorest.NewErrorWithError(err, "network.VirtualNetworkTapsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
22849		return
22850	}
22851	if !done {
22852		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkTapsCreateOrUpdateFuture")
22853		return
22854	}
22855	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
22856	if vnt.Response.Response, err = future.GetResult(sender); err == nil && vnt.Response.Response.StatusCode != http.StatusNoContent {
22857		vnt, err = client.CreateOrUpdateResponder(vnt.Response.Response)
22858		if err != nil {
22859			err = autorest.NewErrorWithError(err, "network.VirtualNetworkTapsCreateOrUpdateFuture", "Result", vnt.Response.Response, "Failure responding to request")
22860		}
22861	}
22862	return
22863}
22864
22865// VirtualNetworkTapsDeleteFuture an abstraction for monitoring and retrieving the results of a long-running
22866// operation.
22867type VirtualNetworkTapsDeleteFuture struct {
22868	azure.Future
22869}
22870
22871// Result returns the result of the asynchronous operation.
22872// If the operation has not completed it will return an error.
22873func (future *VirtualNetworkTapsDeleteFuture) Result(client VirtualNetworkTapsClient) (ar autorest.Response, err error) {
22874	var done bool
22875	done, err = future.Done(client)
22876	if err != nil {
22877		err = autorest.NewErrorWithError(err, "network.VirtualNetworkTapsDeleteFuture", "Result", future.Response(), "Polling failure")
22878		return
22879	}
22880	if !done {
22881		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkTapsDeleteFuture")
22882		return
22883	}
22884	ar.Response = future.Response()
22885	return
22886}
22887
22888// VirtualNetworkTapsUpdateTagsFuture an abstraction for monitoring and retrieving the results of a long-running
22889// operation.
22890type VirtualNetworkTapsUpdateTagsFuture struct {
22891	azure.Future
22892}
22893
22894// Result returns the result of the asynchronous operation.
22895// If the operation has not completed it will return an error.
22896func (future *VirtualNetworkTapsUpdateTagsFuture) Result(client VirtualNetworkTapsClient) (vnt VirtualNetworkTap, err error) {
22897	var done bool
22898	done, err = future.Done(client)
22899	if err != nil {
22900		err = autorest.NewErrorWithError(err, "network.VirtualNetworkTapsUpdateTagsFuture", "Result", future.Response(), "Polling failure")
22901		return
22902	}
22903	if !done {
22904		err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkTapsUpdateTagsFuture")
22905		return
22906	}
22907	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
22908	if vnt.Response.Response, err = future.GetResult(sender); err == nil && vnt.Response.Response.StatusCode != http.StatusNoContent {
22909		vnt, err = client.UpdateTagsResponder(vnt.Response.Response)
22910		if err != nil {
22911			err = autorest.NewErrorWithError(err, "network.VirtualNetworkTapsUpdateTagsFuture", "Result", vnt.Response.Response, "Failure responding to request")
22912		}
22913	}
22914	return
22915}
22916
22917// VirtualNetworkUsage usage details for subnet.
22918type VirtualNetworkUsage struct {
22919	// CurrentValue - Indicates number of IPs used from the Subnet.
22920	CurrentValue *float64 `json:"currentValue,omitempty"`
22921	// ID - Subnet identifier.
22922	ID *string `json:"id,omitempty"`
22923	// Limit - Indicates the size of the subnet.
22924	Limit *float64 `json:"limit,omitempty"`
22925	// Name - The name containing common and localized value for usage.
22926	Name *VirtualNetworkUsageName `json:"name,omitempty"`
22927	// Unit - Usage units. Returns 'Count'
22928	Unit *string `json:"unit,omitempty"`
22929}
22930
22931// VirtualNetworkUsageName usage strings container.
22932type VirtualNetworkUsageName struct {
22933	// LocalizedValue - Localized subnet size and usage string.
22934	LocalizedValue *string `json:"localizedValue,omitempty"`
22935	// Value - Subnet size and usage string.
22936	Value *string `json:"value,omitempty"`
22937}
22938
22939// VirtualWAN virtualWAN Resource.
22940type VirtualWAN struct {
22941	autorest.Response     `json:"-"`
22942	*VirtualWanProperties `json:"properties,omitempty"`
22943	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
22944	Etag *string `json:"etag,omitempty"`
22945	// ID - Resource ID.
22946	ID *string `json:"id,omitempty"`
22947	// Name - Resource name.
22948	Name *string `json:"name,omitempty"`
22949	// Type - Resource type.
22950	Type *string `json:"type,omitempty"`
22951	// Location - Resource location.
22952	Location *string `json:"location,omitempty"`
22953	// Tags - Resource tags.
22954	Tags map[string]*string `json:"tags"`
22955}
22956
22957// MarshalJSON is the custom marshaler for VirtualWAN.
22958func (vw VirtualWAN) MarshalJSON() ([]byte, error) {
22959	objectMap := make(map[string]interface{})
22960	if vw.VirtualWanProperties != nil {
22961		objectMap["properties"] = vw.VirtualWanProperties
22962	}
22963	if vw.Etag != nil {
22964		objectMap["etag"] = vw.Etag
22965	}
22966	if vw.ID != nil {
22967		objectMap["id"] = vw.ID
22968	}
22969	if vw.Name != nil {
22970		objectMap["name"] = vw.Name
22971	}
22972	if vw.Type != nil {
22973		objectMap["type"] = vw.Type
22974	}
22975	if vw.Location != nil {
22976		objectMap["location"] = vw.Location
22977	}
22978	if vw.Tags != nil {
22979		objectMap["tags"] = vw.Tags
22980	}
22981	return json.Marshal(objectMap)
22982}
22983
22984// UnmarshalJSON is the custom unmarshaler for VirtualWAN struct.
22985func (vw *VirtualWAN) UnmarshalJSON(body []byte) error {
22986	var m map[string]*json.RawMessage
22987	err := json.Unmarshal(body, &m)
22988	if err != nil {
22989		return err
22990	}
22991	for k, v := range m {
22992		switch k {
22993		case "properties":
22994			if v != nil {
22995				var virtualWanProperties VirtualWanProperties
22996				err = json.Unmarshal(*v, &virtualWanProperties)
22997				if err != nil {
22998					return err
22999				}
23000				vw.VirtualWanProperties = &virtualWanProperties
23001			}
23002		case "etag":
23003			if v != nil {
23004				var etag string
23005				err = json.Unmarshal(*v, &etag)
23006				if err != nil {
23007					return err
23008				}
23009				vw.Etag = &etag
23010			}
23011		case "id":
23012			if v != nil {
23013				var ID string
23014				err = json.Unmarshal(*v, &ID)
23015				if err != nil {
23016					return err
23017				}
23018				vw.ID = &ID
23019			}
23020		case "name":
23021			if v != nil {
23022				var name string
23023				err = json.Unmarshal(*v, &name)
23024				if err != nil {
23025					return err
23026				}
23027				vw.Name = &name
23028			}
23029		case "type":
23030			if v != nil {
23031				var typeVar string
23032				err = json.Unmarshal(*v, &typeVar)
23033				if err != nil {
23034					return err
23035				}
23036				vw.Type = &typeVar
23037			}
23038		case "location":
23039			if v != nil {
23040				var location string
23041				err = json.Unmarshal(*v, &location)
23042				if err != nil {
23043					return err
23044				}
23045				vw.Location = &location
23046			}
23047		case "tags":
23048			if v != nil {
23049				var tags map[string]*string
23050				err = json.Unmarshal(*v, &tags)
23051				if err != nil {
23052					return err
23053				}
23054				vw.Tags = tags
23055			}
23056		}
23057	}
23058
23059	return nil
23060}
23061
23062// VirtualWanProperties parameters for VirtualWAN
23063type VirtualWanProperties struct {
23064	// DisableVpnEncryption - Vpn encryption to be disabled or not.
23065	DisableVpnEncryption *bool `json:"disableVpnEncryption,omitempty"`
23066	// VirtualHubs - List of VirtualHubs in the VirtualWAN.
23067	VirtualHubs *[]SubResource `json:"virtualHubs,omitempty"`
23068	VpnSites    *[]SubResource `json:"vpnSites,omitempty"`
23069	// SecurityProviderName - The Security Provider name.
23070	SecurityProviderName *string `json:"securityProviderName,omitempty"`
23071	// AllowBranchToBranchTraffic - True if branch to branch traffic is allowed.
23072	AllowBranchToBranchTraffic *bool `json:"allowBranchToBranchTraffic,omitempty"`
23073	// AllowVnetToVnetTraffic - True if Vnet to Vnet traffic is allowed.
23074	AllowVnetToVnetTraffic *bool `json:"allowVnetToVnetTraffic,omitempty"`
23075	// Office365LocalBreakoutCategory - The office local breakout category. Possible values include: 'OfficeTrafficCategoryOptimize', 'OfficeTrafficCategoryOptimizeAndAllow', 'OfficeTrafficCategoryAll', 'OfficeTrafficCategoryNone'
23076	Office365LocalBreakoutCategory OfficeTrafficCategory `json:"office365LocalBreakoutCategory,omitempty"`
23077	// P2SVpnServerConfigurations - list of all P2SVpnServerConfigurations associated with the virtual wan.
23078	P2SVpnServerConfigurations *[]P2SVpnServerConfiguration `json:"p2SVpnServerConfigurations,omitempty"`
23079	// ProvisioningState - The provisioning state of the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
23080	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
23081}
23082
23083// VirtualWansCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
23084// operation.
23085type VirtualWansCreateOrUpdateFuture struct {
23086	azure.Future
23087}
23088
23089// Result returns the result of the asynchronous operation.
23090// If the operation has not completed it will return an error.
23091func (future *VirtualWansCreateOrUpdateFuture) Result(client VirtualWansClient) (vw VirtualWAN, err error) {
23092	var done bool
23093	done, err = future.Done(client)
23094	if err != nil {
23095		err = autorest.NewErrorWithError(err, "network.VirtualWansCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
23096		return
23097	}
23098	if !done {
23099		err = azure.NewAsyncOpIncompleteError("network.VirtualWansCreateOrUpdateFuture")
23100		return
23101	}
23102	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
23103	if vw.Response.Response, err = future.GetResult(sender); err == nil && vw.Response.Response.StatusCode != http.StatusNoContent {
23104		vw, err = client.CreateOrUpdateResponder(vw.Response.Response)
23105		if err != nil {
23106			err = autorest.NewErrorWithError(err, "network.VirtualWansCreateOrUpdateFuture", "Result", vw.Response.Response, "Failure responding to request")
23107		}
23108	}
23109	return
23110}
23111
23112// VirtualWansDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
23113type VirtualWansDeleteFuture struct {
23114	azure.Future
23115}
23116
23117// Result returns the result of the asynchronous operation.
23118// If the operation has not completed it will return an error.
23119func (future *VirtualWansDeleteFuture) Result(client VirtualWansClient) (ar autorest.Response, err error) {
23120	var done bool
23121	done, err = future.Done(client)
23122	if err != nil {
23123		err = autorest.NewErrorWithError(err, "network.VirtualWansDeleteFuture", "Result", future.Response(), "Polling failure")
23124		return
23125	}
23126	if !done {
23127		err = azure.NewAsyncOpIncompleteError("network.VirtualWansDeleteFuture")
23128		return
23129	}
23130	ar.Response = future.Response()
23131	return
23132}
23133
23134// VirtualWanSecurityProvider collection of SecurityProviders.
23135type VirtualWanSecurityProvider struct {
23136	// Name - Name of the security provider.
23137	Name *string `json:"name,omitempty"`
23138	// URL - Url of the security provider.
23139	URL *string `json:"url,omitempty"`
23140	// Type - Name of the security provider. Possible values include: 'External', 'Native'
23141	Type VirtualWanSecurityProviderType `json:"type,omitempty"`
23142}
23143
23144// VirtualWanSecurityProviders collection of SecurityProviders.
23145type VirtualWanSecurityProviders struct {
23146	autorest.Response  `json:"-"`
23147	SupportedProviders *[]VirtualWanSecurityProvider `json:"supportedProviders,omitempty"`
23148}
23149
23150// VirtualWansUpdateTagsFuture an abstraction for monitoring and retrieving the results of a long-running
23151// operation.
23152type VirtualWansUpdateTagsFuture struct {
23153	azure.Future
23154}
23155
23156// Result returns the result of the asynchronous operation.
23157// If the operation has not completed it will return an error.
23158func (future *VirtualWansUpdateTagsFuture) Result(client VirtualWansClient) (vw VirtualWAN, err error) {
23159	var done bool
23160	done, err = future.Done(client)
23161	if err != nil {
23162		err = autorest.NewErrorWithError(err, "network.VirtualWansUpdateTagsFuture", "Result", future.Response(), "Polling failure")
23163		return
23164	}
23165	if !done {
23166		err = azure.NewAsyncOpIncompleteError("network.VirtualWansUpdateTagsFuture")
23167		return
23168	}
23169	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
23170	if vw.Response.Response, err = future.GetResult(sender); err == nil && vw.Response.Response.StatusCode != http.StatusNoContent {
23171		vw, err = client.UpdateTagsResponder(vw.Response.Response)
23172		if err != nil {
23173			err = autorest.NewErrorWithError(err, "network.VirtualWansUpdateTagsFuture", "Result", vw.Response.Response, "Failure responding to request")
23174		}
23175	}
23176	return
23177}
23178
23179// VpnClientConfiguration vpnClientConfiguration for P2S client.
23180type VpnClientConfiguration struct {
23181	// VpnClientAddressPool - The reference of the address space resource which represents Address space for P2S VpnClient.
23182	VpnClientAddressPool *AddressSpace `json:"vpnClientAddressPool,omitempty"`
23183	// VpnClientRootCertificates - VpnClientRootCertificate for virtual network gateway.
23184	VpnClientRootCertificates *[]VpnClientRootCertificate `json:"vpnClientRootCertificates,omitempty"`
23185	// VpnClientRevokedCertificates - VpnClientRevokedCertificate for Virtual network gateway.
23186	VpnClientRevokedCertificates *[]VpnClientRevokedCertificate `json:"vpnClientRevokedCertificates,omitempty"`
23187	// VpnClientProtocols - VpnClientProtocols for Virtual network gateway.
23188	VpnClientProtocols *[]VpnClientProtocol `json:"vpnClientProtocols,omitempty"`
23189	// VpnClientIpsecPolicies - VpnClientIpsecPolicies for virtual network gateway P2S client.
23190	VpnClientIpsecPolicies *[]IpsecPolicy `json:"vpnClientIpsecPolicies,omitempty"`
23191	// RadiusServerAddress - The radius server address property of the VirtualNetworkGateway resource for vpn client connection.
23192	RadiusServerAddress *string `json:"radiusServerAddress,omitempty"`
23193	// RadiusServerSecret - The radius secret property of the VirtualNetworkGateway resource for vpn client connection.
23194	RadiusServerSecret *string `json:"radiusServerSecret,omitempty"`
23195}
23196
23197// VpnClientConnectionHealth vpnClientConnectionHealth properties
23198type VpnClientConnectionHealth struct {
23199	// TotalIngressBytesTransferred - Total of the Ingress Bytes Transferred in this P2S Vpn connection
23200	TotalIngressBytesTransferred *int64 `json:"totalIngressBytesTransferred,omitempty"`
23201	// TotalEgressBytesTransferred - Total of the Egress Bytes Transferred in this connection
23202	TotalEgressBytesTransferred *int64 `json:"totalEgressBytesTransferred,omitempty"`
23203	// VpnClientConnectionsCount - The total of p2s vpn clients connected at this time to this P2SVpnGateway.
23204	VpnClientConnectionsCount *int32 `json:"vpnClientConnectionsCount,omitempty"`
23205	// AllocatedIPAddresses - List of allocated ip addresses to the connected p2s vpn clients.
23206	AllocatedIPAddresses *[]string `json:"allocatedIpAddresses,omitempty"`
23207}
23208
23209// VpnClientIPsecParameters an IPSec parameters for a virtual network gateway P2S connection.
23210type VpnClientIPsecParameters struct {
23211	autorest.Response `json:"-"`
23212	// SaLifeTimeSeconds - The IPSec Security Association (also called Quick Mode or Phase 2 SA) lifetime in seconds for P2S client.
23213	SaLifeTimeSeconds *int32 `json:"saLifeTimeSeconds,omitempty"`
23214	// SaDataSizeKilobytes - The IPSec Security Association (also called Quick Mode or Phase 2 SA) payload size in KB for P2S client..
23215	SaDataSizeKilobytes *int32 `json:"saDataSizeKilobytes,omitempty"`
23216	// IpsecEncryption - The IPSec encryption algorithm (IKE phase 1). Possible values include: 'IpsecEncryptionNone', 'IpsecEncryptionDES', 'IpsecEncryptionDES3', 'IpsecEncryptionAES128', 'IpsecEncryptionAES192', 'IpsecEncryptionAES256', 'IpsecEncryptionGCMAES128', 'IpsecEncryptionGCMAES192', 'IpsecEncryptionGCMAES256'
23217	IpsecEncryption IpsecEncryption `json:"ipsecEncryption,omitempty"`
23218	// IpsecIntegrity - The IPSec integrity algorithm (IKE phase 1). Possible values include: 'IpsecIntegrityMD5', 'IpsecIntegritySHA1', 'IpsecIntegritySHA256', 'IpsecIntegrityGCMAES128', 'IpsecIntegrityGCMAES192', 'IpsecIntegrityGCMAES256'
23219	IpsecIntegrity IpsecIntegrity `json:"ipsecIntegrity,omitempty"`
23220	// IkeEncryption - The IKE encryption algorithm (IKE phase 2). Possible values include: 'DES', 'DES3', 'AES128', 'AES192', 'AES256', 'GCMAES256', 'GCMAES128'
23221	IkeEncryption IkeEncryption `json:"ikeEncryption,omitempty"`
23222	// IkeIntegrity - The IKE integrity algorithm (IKE phase 2). Possible values include: 'IkeIntegrityMD5', 'IkeIntegritySHA1', 'IkeIntegritySHA256', 'IkeIntegritySHA384', 'IkeIntegrityGCMAES256', 'IkeIntegrityGCMAES128'
23223	IkeIntegrity IkeIntegrity `json:"ikeIntegrity,omitempty"`
23224	// DhGroup - The DH Groups used in IKE Phase 1 for initial SA. Possible values include: 'None', 'DHGroup1', 'DHGroup2', 'DHGroup14', 'DHGroup2048', 'ECP256', 'ECP384', 'DHGroup24'
23225	DhGroup DhGroup `json:"dhGroup,omitempty"`
23226	// PfsGroup - The Pfs Groups used in IKE Phase 2 for new child SA. Possible values include: 'PfsGroupNone', 'PfsGroupPFS1', 'PfsGroupPFS2', 'PfsGroupPFS2048', 'PfsGroupECP256', 'PfsGroupECP384', 'PfsGroupPFS24', 'PfsGroupPFS14', 'PfsGroupPFSMM'
23227	PfsGroup PfsGroup `json:"pfsGroup,omitempty"`
23228}
23229
23230// VpnClientParameters vpn Client Parameters for package generation
23231type VpnClientParameters struct {
23232	// ProcessorArchitecture - VPN client Processor Architecture. Possible values are: 'AMD64' and 'X86'. Possible values include: 'Amd64', 'X86'
23233	ProcessorArchitecture ProcessorArchitecture `json:"processorArchitecture,omitempty"`
23234	// AuthenticationMethod - VPN client Authentication Method. Possible values are: 'EAPTLS' and 'EAPMSCHAPv2'. Possible values include: 'EAPTLS', 'EAPMSCHAPv2'
23235	AuthenticationMethod AuthenticationMethod `json:"authenticationMethod,omitempty"`
23236	// 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.
23237	RadiusServerAuthCertificate *string `json:"radiusServerAuthCertificate,omitempty"`
23238	// ClientRootCertificates - A list of client root certificates public certificate data encoded as Base-64 strings. Optional parameter for external radius based authentication with EAPTLS.
23239	ClientRootCertificates *[]string `json:"clientRootCertificates,omitempty"`
23240}
23241
23242// VpnClientRevokedCertificate VPN client revoked certificate of virtual network gateway.
23243type VpnClientRevokedCertificate struct {
23244	// VpnClientRevokedCertificatePropertiesFormat - Properties of the vpn client revoked certificate.
23245	*VpnClientRevokedCertificatePropertiesFormat `json:"properties,omitempty"`
23246	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
23247	Name *string `json:"name,omitempty"`
23248	// Etag - A unique read-only string that changes whenever the resource is updated.
23249	Etag *string `json:"etag,omitempty"`
23250	// ID - Resource ID.
23251	ID *string `json:"id,omitempty"`
23252}
23253
23254// MarshalJSON is the custom marshaler for VpnClientRevokedCertificate.
23255func (vcrc VpnClientRevokedCertificate) MarshalJSON() ([]byte, error) {
23256	objectMap := make(map[string]interface{})
23257	if vcrc.VpnClientRevokedCertificatePropertiesFormat != nil {
23258		objectMap["properties"] = vcrc.VpnClientRevokedCertificatePropertiesFormat
23259	}
23260	if vcrc.Name != nil {
23261		objectMap["name"] = vcrc.Name
23262	}
23263	if vcrc.Etag != nil {
23264		objectMap["etag"] = vcrc.Etag
23265	}
23266	if vcrc.ID != nil {
23267		objectMap["id"] = vcrc.ID
23268	}
23269	return json.Marshal(objectMap)
23270}
23271
23272// UnmarshalJSON is the custom unmarshaler for VpnClientRevokedCertificate struct.
23273func (vcrc *VpnClientRevokedCertificate) UnmarshalJSON(body []byte) error {
23274	var m map[string]*json.RawMessage
23275	err := json.Unmarshal(body, &m)
23276	if err != nil {
23277		return err
23278	}
23279	for k, v := range m {
23280		switch k {
23281		case "properties":
23282			if v != nil {
23283				var vpnClientRevokedCertificatePropertiesFormat VpnClientRevokedCertificatePropertiesFormat
23284				err = json.Unmarshal(*v, &vpnClientRevokedCertificatePropertiesFormat)
23285				if err != nil {
23286					return err
23287				}
23288				vcrc.VpnClientRevokedCertificatePropertiesFormat = &vpnClientRevokedCertificatePropertiesFormat
23289			}
23290		case "name":
23291			if v != nil {
23292				var name string
23293				err = json.Unmarshal(*v, &name)
23294				if err != nil {
23295					return err
23296				}
23297				vcrc.Name = &name
23298			}
23299		case "etag":
23300			if v != nil {
23301				var etag string
23302				err = json.Unmarshal(*v, &etag)
23303				if err != nil {
23304					return err
23305				}
23306				vcrc.Etag = &etag
23307			}
23308		case "id":
23309			if v != nil {
23310				var ID string
23311				err = json.Unmarshal(*v, &ID)
23312				if err != nil {
23313					return err
23314				}
23315				vcrc.ID = &ID
23316			}
23317		}
23318	}
23319
23320	return nil
23321}
23322
23323// VpnClientRevokedCertificatePropertiesFormat properties of the revoked VPN client certificate of virtual network
23324// gateway.
23325type VpnClientRevokedCertificatePropertiesFormat struct {
23326	// Thumbprint - The revoked VPN client certificate thumbprint.
23327	Thumbprint *string `json:"thumbprint,omitempty"`
23328	// ProvisioningState - The provisioning state of the VPN client revoked certificate resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
23329	ProvisioningState *string `json:"provisioningState,omitempty"`
23330}
23331
23332// VpnClientRootCertificate VPN client root certificate of virtual network gateway
23333type VpnClientRootCertificate struct {
23334	// VpnClientRootCertificatePropertiesFormat - Properties of the vpn client root certificate.
23335	*VpnClientRootCertificatePropertiesFormat `json:"properties,omitempty"`
23336	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
23337	Name *string `json:"name,omitempty"`
23338	// Etag - A unique read-only string that changes whenever the resource is updated.
23339	Etag *string `json:"etag,omitempty"`
23340	// ID - Resource ID.
23341	ID *string `json:"id,omitempty"`
23342}
23343
23344// MarshalJSON is the custom marshaler for VpnClientRootCertificate.
23345func (vcrc VpnClientRootCertificate) MarshalJSON() ([]byte, error) {
23346	objectMap := make(map[string]interface{})
23347	if vcrc.VpnClientRootCertificatePropertiesFormat != nil {
23348		objectMap["properties"] = vcrc.VpnClientRootCertificatePropertiesFormat
23349	}
23350	if vcrc.Name != nil {
23351		objectMap["name"] = vcrc.Name
23352	}
23353	if vcrc.Etag != nil {
23354		objectMap["etag"] = vcrc.Etag
23355	}
23356	if vcrc.ID != nil {
23357		objectMap["id"] = vcrc.ID
23358	}
23359	return json.Marshal(objectMap)
23360}
23361
23362// UnmarshalJSON is the custom unmarshaler for VpnClientRootCertificate struct.
23363func (vcrc *VpnClientRootCertificate) UnmarshalJSON(body []byte) error {
23364	var m map[string]*json.RawMessage
23365	err := json.Unmarshal(body, &m)
23366	if err != nil {
23367		return err
23368	}
23369	for k, v := range m {
23370		switch k {
23371		case "properties":
23372			if v != nil {
23373				var vpnClientRootCertificatePropertiesFormat VpnClientRootCertificatePropertiesFormat
23374				err = json.Unmarshal(*v, &vpnClientRootCertificatePropertiesFormat)
23375				if err != nil {
23376					return err
23377				}
23378				vcrc.VpnClientRootCertificatePropertiesFormat = &vpnClientRootCertificatePropertiesFormat
23379			}
23380		case "name":
23381			if v != nil {
23382				var name string
23383				err = json.Unmarshal(*v, &name)
23384				if err != nil {
23385					return err
23386				}
23387				vcrc.Name = &name
23388			}
23389		case "etag":
23390			if v != nil {
23391				var etag string
23392				err = json.Unmarshal(*v, &etag)
23393				if err != nil {
23394					return err
23395				}
23396				vcrc.Etag = &etag
23397			}
23398		case "id":
23399			if v != nil {
23400				var ID string
23401				err = json.Unmarshal(*v, &ID)
23402				if err != nil {
23403					return err
23404				}
23405				vcrc.ID = &ID
23406			}
23407		}
23408	}
23409
23410	return nil
23411}
23412
23413// VpnClientRootCertificatePropertiesFormat properties of SSL certificates of application gateway
23414type VpnClientRootCertificatePropertiesFormat struct {
23415	// PublicCertData - The certificate public data.
23416	PublicCertData *string `json:"publicCertData,omitempty"`
23417	// ProvisioningState - The provisioning state of the VPN client root certificate resource. Possible values are: 'Updating', 'Deleting', and 'Failed'.
23418	ProvisioningState *string `json:"provisioningState,omitempty"`
23419}
23420
23421// VpnConnection vpnConnection Resource.
23422type VpnConnection struct {
23423	autorest.Response        `json:"-"`
23424	*VpnConnectionProperties `json:"properties,omitempty"`
23425	// Name - The name of the resource that is unique within a resource group. This name can be used to access the resource.
23426	Name *string `json:"name,omitempty"`
23427	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
23428	Etag *string `json:"etag,omitempty"`
23429	// ID - Resource ID.
23430	ID *string `json:"id,omitempty"`
23431}
23432
23433// MarshalJSON is the custom marshaler for VpnConnection.
23434func (vc VpnConnection) MarshalJSON() ([]byte, error) {
23435	objectMap := make(map[string]interface{})
23436	if vc.VpnConnectionProperties != nil {
23437		objectMap["properties"] = vc.VpnConnectionProperties
23438	}
23439	if vc.Name != nil {
23440		objectMap["name"] = vc.Name
23441	}
23442	if vc.Etag != nil {
23443		objectMap["etag"] = vc.Etag
23444	}
23445	if vc.ID != nil {
23446		objectMap["id"] = vc.ID
23447	}
23448	return json.Marshal(objectMap)
23449}
23450
23451// UnmarshalJSON is the custom unmarshaler for VpnConnection struct.
23452func (vc *VpnConnection) UnmarshalJSON(body []byte) error {
23453	var m map[string]*json.RawMessage
23454	err := json.Unmarshal(body, &m)
23455	if err != nil {
23456		return err
23457	}
23458	for k, v := range m {
23459		switch k {
23460		case "properties":
23461			if v != nil {
23462				var vpnConnectionProperties VpnConnectionProperties
23463				err = json.Unmarshal(*v, &vpnConnectionProperties)
23464				if err != nil {
23465					return err
23466				}
23467				vc.VpnConnectionProperties = &vpnConnectionProperties
23468			}
23469		case "name":
23470			if v != nil {
23471				var name string
23472				err = json.Unmarshal(*v, &name)
23473				if err != nil {
23474					return err
23475				}
23476				vc.Name = &name
23477			}
23478		case "etag":
23479			if v != nil {
23480				var etag string
23481				err = json.Unmarshal(*v, &etag)
23482				if err != nil {
23483					return err
23484				}
23485				vc.Etag = &etag
23486			}
23487		case "id":
23488			if v != nil {
23489				var ID string
23490				err = json.Unmarshal(*v, &ID)
23491				if err != nil {
23492					return err
23493				}
23494				vc.ID = &ID
23495			}
23496		}
23497	}
23498
23499	return nil
23500}
23501
23502// VpnConnectionProperties parameters for VpnConnection
23503type VpnConnectionProperties struct {
23504	// RemoteVpnSite - Id of the connected vpn site.
23505	RemoteVpnSite *SubResource `json:"remoteVpnSite,omitempty"`
23506	// RoutingWeight - routing weight for vpn connection.
23507	RoutingWeight *int32 `json:"routingWeight,omitempty"`
23508	// ConnectionStatus - The connection status. Possible values include: 'VpnConnectionStatusUnknown', 'VpnConnectionStatusConnecting', 'VpnConnectionStatusConnected', 'VpnConnectionStatusNotConnected'
23509	ConnectionStatus VpnConnectionStatus `json:"connectionStatus,omitempty"`
23510	// VpnConnectionProtocolType - Connection protocol used for this connection. Possible values include: 'IKEv2', 'IKEv1'
23511	VpnConnectionProtocolType VirtualNetworkGatewayConnectionProtocol `json:"vpnConnectionProtocolType,omitempty"`
23512	// IngressBytesTransferred - Ingress bytes transferred.
23513	IngressBytesTransferred *int64 `json:"ingressBytesTransferred,omitempty"`
23514	// EgressBytesTransferred - Egress bytes transferred.
23515	EgressBytesTransferred *int64 `json:"egressBytesTransferred,omitempty"`
23516	// ConnectionBandwidth - Expected bandwidth in MBPS.
23517	ConnectionBandwidth *int32 `json:"connectionBandwidth,omitempty"`
23518	// SharedKey - SharedKey for the vpn connection.
23519	SharedKey *string `json:"sharedKey,omitempty"`
23520	// EnableBgp - EnableBgp flag
23521	EnableBgp *bool `json:"enableBgp,omitempty"`
23522	// IpsecPolicies - The IPSec Policies to be considered by this connection.
23523	IpsecPolicies *[]IpsecPolicy `json:"ipsecPolicies,omitempty"`
23524	// EnableRateLimiting - EnableBgp flag
23525	EnableRateLimiting *bool `json:"enableRateLimiting,omitempty"`
23526	// EnableInternetSecurity - Enable internet security
23527	EnableInternetSecurity *bool `json:"enableInternetSecurity,omitempty"`
23528	// ProvisioningState - The provisioning state of the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
23529	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
23530}
23531
23532// VpnConnectionsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
23533// operation.
23534type VpnConnectionsCreateOrUpdateFuture struct {
23535	azure.Future
23536}
23537
23538// Result returns the result of the asynchronous operation.
23539// If the operation has not completed it will return an error.
23540func (future *VpnConnectionsCreateOrUpdateFuture) Result(client VpnConnectionsClient) (vc VpnConnection, err error) {
23541	var done bool
23542	done, err = future.Done(client)
23543	if err != nil {
23544		err = autorest.NewErrorWithError(err, "network.VpnConnectionsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
23545		return
23546	}
23547	if !done {
23548		err = azure.NewAsyncOpIncompleteError("network.VpnConnectionsCreateOrUpdateFuture")
23549		return
23550	}
23551	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
23552	if vc.Response.Response, err = future.GetResult(sender); err == nil && vc.Response.Response.StatusCode != http.StatusNoContent {
23553		vc, err = client.CreateOrUpdateResponder(vc.Response.Response)
23554		if err != nil {
23555			err = autorest.NewErrorWithError(err, "network.VpnConnectionsCreateOrUpdateFuture", "Result", vc.Response.Response, "Failure responding to request")
23556		}
23557	}
23558	return
23559}
23560
23561// VpnConnectionsDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
23562type VpnConnectionsDeleteFuture struct {
23563	azure.Future
23564}
23565
23566// Result returns the result of the asynchronous operation.
23567// If the operation has not completed it will return an error.
23568func (future *VpnConnectionsDeleteFuture) Result(client VpnConnectionsClient) (ar autorest.Response, err error) {
23569	var done bool
23570	done, err = future.Done(client)
23571	if err != nil {
23572		err = autorest.NewErrorWithError(err, "network.VpnConnectionsDeleteFuture", "Result", future.Response(), "Polling failure")
23573		return
23574	}
23575	if !done {
23576		err = azure.NewAsyncOpIncompleteError("network.VpnConnectionsDeleteFuture")
23577		return
23578	}
23579	ar.Response = future.Response()
23580	return
23581}
23582
23583// VpnDeviceScriptParameters vpn device configuration script generation parameters
23584type VpnDeviceScriptParameters struct {
23585	// Vendor - The vendor for the vpn device.
23586	Vendor *string `json:"vendor,omitempty"`
23587	// DeviceFamily - The device family for the vpn device.
23588	DeviceFamily *string `json:"deviceFamily,omitempty"`
23589	// FirmwareVersion - The firmware version for the vpn device.
23590	FirmwareVersion *string `json:"firmwareVersion,omitempty"`
23591}
23592
23593// VpnGateway vpnGateway Resource.
23594type VpnGateway struct {
23595	autorest.Response     `json:"-"`
23596	*VpnGatewayProperties `json:"properties,omitempty"`
23597	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
23598	Etag *string `json:"etag,omitempty"`
23599	// ID - Resource ID.
23600	ID *string `json:"id,omitempty"`
23601	// Name - Resource name.
23602	Name *string `json:"name,omitempty"`
23603	// Type - Resource type.
23604	Type *string `json:"type,omitempty"`
23605	// Location - Resource location.
23606	Location *string `json:"location,omitempty"`
23607	// Tags - Resource tags.
23608	Tags map[string]*string `json:"tags"`
23609}
23610
23611// MarshalJSON is the custom marshaler for VpnGateway.
23612func (vg VpnGateway) MarshalJSON() ([]byte, error) {
23613	objectMap := make(map[string]interface{})
23614	if vg.VpnGatewayProperties != nil {
23615		objectMap["properties"] = vg.VpnGatewayProperties
23616	}
23617	if vg.Etag != nil {
23618		objectMap["etag"] = vg.Etag
23619	}
23620	if vg.ID != nil {
23621		objectMap["id"] = vg.ID
23622	}
23623	if vg.Name != nil {
23624		objectMap["name"] = vg.Name
23625	}
23626	if vg.Type != nil {
23627		objectMap["type"] = vg.Type
23628	}
23629	if vg.Location != nil {
23630		objectMap["location"] = vg.Location
23631	}
23632	if vg.Tags != nil {
23633		objectMap["tags"] = vg.Tags
23634	}
23635	return json.Marshal(objectMap)
23636}
23637
23638// UnmarshalJSON is the custom unmarshaler for VpnGateway struct.
23639func (vg *VpnGateway) UnmarshalJSON(body []byte) error {
23640	var m map[string]*json.RawMessage
23641	err := json.Unmarshal(body, &m)
23642	if err != nil {
23643		return err
23644	}
23645	for k, v := range m {
23646		switch k {
23647		case "properties":
23648			if v != nil {
23649				var vpnGatewayProperties VpnGatewayProperties
23650				err = json.Unmarshal(*v, &vpnGatewayProperties)
23651				if err != nil {
23652					return err
23653				}
23654				vg.VpnGatewayProperties = &vpnGatewayProperties
23655			}
23656		case "etag":
23657			if v != nil {
23658				var etag string
23659				err = json.Unmarshal(*v, &etag)
23660				if err != nil {
23661					return err
23662				}
23663				vg.Etag = &etag
23664			}
23665		case "id":
23666			if v != nil {
23667				var ID string
23668				err = json.Unmarshal(*v, &ID)
23669				if err != nil {
23670					return err
23671				}
23672				vg.ID = &ID
23673			}
23674		case "name":
23675			if v != nil {
23676				var name string
23677				err = json.Unmarshal(*v, &name)
23678				if err != nil {
23679					return err
23680				}
23681				vg.Name = &name
23682			}
23683		case "type":
23684			if v != nil {
23685				var typeVar string
23686				err = json.Unmarshal(*v, &typeVar)
23687				if err != nil {
23688					return err
23689				}
23690				vg.Type = &typeVar
23691			}
23692		case "location":
23693			if v != nil {
23694				var location string
23695				err = json.Unmarshal(*v, &location)
23696				if err != nil {
23697					return err
23698				}
23699				vg.Location = &location
23700			}
23701		case "tags":
23702			if v != nil {
23703				var tags map[string]*string
23704				err = json.Unmarshal(*v, &tags)
23705				if err != nil {
23706					return err
23707				}
23708				vg.Tags = tags
23709			}
23710		}
23711	}
23712
23713	return nil
23714}
23715
23716// VpnGatewayProperties parameters for VpnGateway
23717type VpnGatewayProperties struct {
23718	// VirtualHub - The VirtualHub to which the gateway belongs
23719	VirtualHub *SubResource `json:"virtualHub,omitempty"`
23720	// Connections - list of all vpn connections to the gateway.
23721	Connections *[]VpnConnection `json:"connections,omitempty"`
23722	// BgpSettings - Local network gateway's BGP speaker settings.
23723	BgpSettings *BgpSettings `json:"bgpSettings,omitempty"`
23724	// ProvisioningState - The provisioning state of the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
23725	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
23726	// VpnGatewayScaleUnit - The scale unit for this vpn gateway.
23727	VpnGatewayScaleUnit *int32 `json:"vpnGatewayScaleUnit,omitempty"`
23728}
23729
23730// VpnGatewaysCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
23731// operation.
23732type VpnGatewaysCreateOrUpdateFuture struct {
23733	azure.Future
23734}
23735
23736// Result returns the result of the asynchronous operation.
23737// If the operation has not completed it will return an error.
23738func (future *VpnGatewaysCreateOrUpdateFuture) Result(client VpnGatewaysClient) (vg VpnGateway, err error) {
23739	var done bool
23740	done, err = future.Done(client)
23741	if err != nil {
23742		err = autorest.NewErrorWithError(err, "network.VpnGatewaysCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
23743		return
23744	}
23745	if !done {
23746		err = azure.NewAsyncOpIncompleteError("network.VpnGatewaysCreateOrUpdateFuture")
23747		return
23748	}
23749	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
23750	if vg.Response.Response, err = future.GetResult(sender); err == nil && vg.Response.Response.StatusCode != http.StatusNoContent {
23751		vg, err = client.CreateOrUpdateResponder(vg.Response.Response)
23752		if err != nil {
23753			err = autorest.NewErrorWithError(err, "network.VpnGatewaysCreateOrUpdateFuture", "Result", vg.Response.Response, "Failure responding to request")
23754		}
23755	}
23756	return
23757}
23758
23759// VpnGatewaysDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
23760type VpnGatewaysDeleteFuture struct {
23761	azure.Future
23762}
23763
23764// Result returns the result of the asynchronous operation.
23765// If the operation has not completed it will return an error.
23766func (future *VpnGatewaysDeleteFuture) Result(client VpnGatewaysClient) (ar autorest.Response, err error) {
23767	var done bool
23768	done, err = future.Done(client)
23769	if err != nil {
23770		err = autorest.NewErrorWithError(err, "network.VpnGatewaysDeleteFuture", "Result", future.Response(), "Polling failure")
23771		return
23772	}
23773	if !done {
23774		err = azure.NewAsyncOpIncompleteError("network.VpnGatewaysDeleteFuture")
23775		return
23776	}
23777	ar.Response = future.Response()
23778	return
23779}
23780
23781// VpnGatewaysUpdateTagsFuture an abstraction for monitoring and retrieving the results of a long-running
23782// operation.
23783type VpnGatewaysUpdateTagsFuture struct {
23784	azure.Future
23785}
23786
23787// Result returns the result of the asynchronous operation.
23788// If the operation has not completed it will return an error.
23789func (future *VpnGatewaysUpdateTagsFuture) Result(client VpnGatewaysClient) (vg VpnGateway, err error) {
23790	var done bool
23791	done, err = future.Done(client)
23792	if err != nil {
23793		err = autorest.NewErrorWithError(err, "network.VpnGatewaysUpdateTagsFuture", "Result", future.Response(), "Polling failure")
23794		return
23795	}
23796	if !done {
23797		err = azure.NewAsyncOpIncompleteError("network.VpnGatewaysUpdateTagsFuture")
23798		return
23799	}
23800	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
23801	if vg.Response.Response, err = future.GetResult(sender); err == nil && vg.Response.Response.StatusCode != http.StatusNoContent {
23802		vg, err = client.UpdateTagsResponder(vg.Response.Response)
23803		if err != nil {
23804			err = autorest.NewErrorWithError(err, "network.VpnGatewaysUpdateTagsFuture", "Result", vg.Response.Response, "Failure responding to request")
23805		}
23806	}
23807	return
23808}
23809
23810// VpnProfileResponse vpn Profile Response for package generation
23811type VpnProfileResponse struct {
23812	autorest.Response `json:"-"`
23813	// ProfileURL - URL to the VPN profile
23814	ProfileURL *string `json:"profileUrl,omitempty"`
23815}
23816
23817// VpnSite vpnSite Resource.
23818type VpnSite struct {
23819	autorest.Response  `json:"-"`
23820	*VpnSiteProperties `json:"properties,omitempty"`
23821	// Etag - Gets a unique read-only string that changes whenever the resource is updated.
23822	Etag *string `json:"etag,omitempty"`
23823	// ID - Resource ID.
23824	ID *string `json:"id,omitempty"`
23825	// Name - Resource name.
23826	Name *string `json:"name,omitempty"`
23827	// Type - Resource type.
23828	Type *string `json:"type,omitempty"`
23829	// Location - Resource location.
23830	Location *string `json:"location,omitempty"`
23831	// Tags - Resource tags.
23832	Tags map[string]*string `json:"tags"`
23833}
23834
23835// MarshalJSON is the custom marshaler for VpnSite.
23836func (vs VpnSite) MarshalJSON() ([]byte, error) {
23837	objectMap := make(map[string]interface{})
23838	if vs.VpnSiteProperties != nil {
23839		objectMap["properties"] = vs.VpnSiteProperties
23840	}
23841	if vs.Etag != nil {
23842		objectMap["etag"] = vs.Etag
23843	}
23844	if vs.ID != nil {
23845		objectMap["id"] = vs.ID
23846	}
23847	if vs.Name != nil {
23848		objectMap["name"] = vs.Name
23849	}
23850	if vs.Type != nil {
23851		objectMap["type"] = vs.Type
23852	}
23853	if vs.Location != nil {
23854		objectMap["location"] = vs.Location
23855	}
23856	if vs.Tags != nil {
23857		objectMap["tags"] = vs.Tags
23858	}
23859	return json.Marshal(objectMap)
23860}
23861
23862// UnmarshalJSON is the custom unmarshaler for VpnSite struct.
23863func (vs *VpnSite) UnmarshalJSON(body []byte) error {
23864	var m map[string]*json.RawMessage
23865	err := json.Unmarshal(body, &m)
23866	if err != nil {
23867		return err
23868	}
23869	for k, v := range m {
23870		switch k {
23871		case "properties":
23872			if v != nil {
23873				var vpnSiteProperties VpnSiteProperties
23874				err = json.Unmarshal(*v, &vpnSiteProperties)
23875				if err != nil {
23876					return err
23877				}
23878				vs.VpnSiteProperties = &vpnSiteProperties
23879			}
23880		case "etag":
23881			if v != nil {
23882				var etag string
23883				err = json.Unmarshal(*v, &etag)
23884				if err != nil {
23885					return err
23886				}
23887				vs.Etag = &etag
23888			}
23889		case "id":
23890			if v != nil {
23891				var ID string
23892				err = json.Unmarshal(*v, &ID)
23893				if err != nil {
23894					return err
23895				}
23896				vs.ID = &ID
23897			}
23898		case "name":
23899			if v != nil {
23900				var name string
23901				err = json.Unmarshal(*v, &name)
23902				if err != nil {
23903					return err
23904				}
23905				vs.Name = &name
23906			}
23907		case "type":
23908			if v != nil {
23909				var typeVar string
23910				err = json.Unmarshal(*v, &typeVar)
23911				if err != nil {
23912					return err
23913				}
23914				vs.Type = &typeVar
23915			}
23916		case "location":
23917			if v != nil {
23918				var location string
23919				err = json.Unmarshal(*v, &location)
23920				if err != nil {
23921					return err
23922				}
23923				vs.Location = &location
23924			}
23925		case "tags":
23926			if v != nil {
23927				var tags map[string]*string
23928				err = json.Unmarshal(*v, &tags)
23929				if err != nil {
23930					return err
23931				}
23932				vs.Tags = tags
23933			}
23934		}
23935	}
23936
23937	return nil
23938}
23939
23940// VpnSiteID vpnSite Resource.
23941type VpnSiteID struct {
23942	// VpnSite - The resource-uri of the vpn-site for which config is to be fetched.
23943	VpnSite *string `json:"vpnSite,omitempty"`
23944}
23945
23946// VpnSiteProperties parameters for VpnSite
23947type VpnSiteProperties struct {
23948	// VirtualWan - The VirtualWAN to which the vpnSite belongs
23949	VirtualWan *SubResource `json:"virtualWan,omitempty"`
23950	// DeviceProperties - The device properties
23951	DeviceProperties *DeviceProperties `json:"deviceProperties,omitempty"`
23952	// IPAddress - The ip-address for the vpn-site.
23953	IPAddress *string `json:"ipAddress,omitempty"`
23954	// SiteKey - The key for vpn-site that can be used for connections.
23955	SiteKey *string `json:"siteKey,omitempty"`
23956	// AddressSpace - The AddressSpace that contains an array of IP address ranges.
23957	AddressSpace *AddressSpace `json:"addressSpace,omitempty"`
23958	// BgpProperties - The set of bgp properties.
23959	BgpProperties *BgpSettings `json:"bgpProperties,omitempty"`
23960	// ProvisioningState - The provisioning state of the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
23961	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
23962	// IsSecuritySite - IsSecuritySite flag
23963	IsSecuritySite *bool `json:"isSecuritySite,omitempty"`
23964}
23965
23966// VpnSitesConfigurationDownloadFuture an abstraction for monitoring and retrieving the results of a long-running
23967// operation.
23968type VpnSitesConfigurationDownloadFuture struct {
23969	azure.Future
23970}
23971
23972// Result returns the result of the asynchronous operation.
23973// If the operation has not completed it will return an error.
23974func (future *VpnSitesConfigurationDownloadFuture) Result(client VpnSitesConfigurationClient) (ar autorest.Response, err error) {
23975	var done bool
23976	done, err = future.Done(client)
23977	if err != nil {
23978		err = autorest.NewErrorWithError(err, "network.VpnSitesConfigurationDownloadFuture", "Result", future.Response(), "Polling failure")
23979		return
23980	}
23981	if !done {
23982		err = azure.NewAsyncOpIncompleteError("network.VpnSitesConfigurationDownloadFuture")
23983		return
23984	}
23985	ar.Response = future.Response()
23986	return
23987}
23988
23989// VpnSitesCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
23990// operation.
23991type VpnSitesCreateOrUpdateFuture struct {
23992	azure.Future
23993}
23994
23995// Result returns the result of the asynchronous operation.
23996// If the operation has not completed it will return an error.
23997func (future *VpnSitesCreateOrUpdateFuture) Result(client VpnSitesClient) (vs VpnSite, err error) {
23998	var done bool
23999	done, err = future.Done(client)
24000	if err != nil {
24001		err = autorest.NewErrorWithError(err, "network.VpnSitesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
24002		return
24003	}
24004	if !done {
24005		err = azure.NewAsyncOpIncompleteError("network.VpnSitesCreateOrUpdateFuture")
24006		return
24007	}
24008	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
24009	if vs.Response.Response, err = future.GetResult(sender); err == nil && vs.Response.Response.StatusCode != http.StatusNoContent {
24010		vs, err = client.CreateOrUpdateResponder(vs.Response.Response)
24011		if err != nil {
24012			err = autorest.NewErrorWithError(err, "network.VpnSitesCreateOrUpdateFuture", "Result", vs.Response.Response, "Failure responding to request")
24013		}
24014	}
24015	return
24016}
24017
24018// VpnSitesDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
24019type VpnSitesDeleteFuture struct {
24020	azure.Future
24021}
24022
24023// Result returns the result of the asynchronous operation.
24024// If the operation has not completed it will return an error.
24025func (future *VpnSitesDeleteFuture) Result(client VpnSitesClient) (ar autorest.Response, err error) {
24026	var done bool
24027	done, err = future.Done(client)
24028	if err != nil {
24029		err = autorest.NewErrorWithError(err, "network.VpnSitesDeleteFuture", "Result", future.Response(), "Polling failure")
24030		return
24031	}
24032	if !done {
24033		err = azure.NewAsyncOpIncompleteError("network.VpnSitesDeleteFuture")
24034		return
24035	}
24036	ar.Response = future.Response()
24037	return
24038}
24039
24040// VpnSitesUpdateTagsFuture an abstraction for monitoring and retrieving the results of a long-running operation.
24041type VpnSitesUpdateTagsFuture struct {
24042	azure.Future
24043}
24044
24045// Result returns the result of the asynchronous operation.
24046// If the operation has not completed it will return an error.
24047func (future *VpnSitesUpdateTagsFuture) Result(client VpnSitesClient) (vs VpnSite, err error) {
24048	var done bool
24049	done, err = future.Done(client)
24050	if err != nil {
24051		err = autorest.NewErrorWithError(err, "network.VpnSitesUpdateTagsFuture", "Result", future.Response(), "Polling failure")
24052		return
24053	}
24054	if !done {
24055		err = azure.NewAsyncOpIncompleteError("network.VpnSitesUpdateTagsFuture")
24056		return
24057	}
24058	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
24059	if vs.Response.Response, err = future.GetResult(sender); err == nil && vs.Response.Response.StatusCode != http.StatusNoContent {
24060		vs, err = client.UpdateTagsResponder(vs.Response.Response)
24061		if err != nil {
24062			err = autorest.NewErrorWithError(err, "network.VpnSitesUpdateTagsFuture", "Result", vs.Response.Response, "Failure responding to request")
24063		}
24064	}
24065	return
24066}
24067
24068// Watcher network watcher in a resource group.
24069type Watcher struct {
24070	autorest.Response `json:"-"`
24071	// Etag - A unique read-only string that changes whenever the resource is updated.
24072	Etag                     *string `json:"etag,omitempty"`
24073	*WatcherPropertiesFormat `json:"properties,omitempty"`
24074	// ID - Resource ID.
24075	ID *string `json:"id,omitempty"`
24076	// Name - Resource name.
24077	Name *string `json:"name,omitempty"`
24078	// Type - Resource type.
24079	Type *string `json:"type,omitempty"`
24080	// Location - Resource location.
24081	Location *string `json:"location,omitempty"`
24082	// Tags - Resource tags.
24083	Tags map[string]*string `json:"tags"`
24084}
24085
24086// MarshalJSON is the custom marshaler for Watcher.
24087func (w Watcher) MarshalJSON() ([]byte, error) {
24088	objectMap := make(map[string]interface{})
24089	if w.Etag != nil {
24090		objectMap["etag"] = w.Etag
24091	}
24092	if w.WatcherPropertiesFormat != nil {
24093		objectMap["properties"] = w.WatcherPropertiesFormat
24094	}
24095	if w.ID != nil {
24096		objectMap["id"] = w.ID
24097	}
24098	if w.Name != nil {
24099		objectMap["name"] = w.Name
24100	}
24101	if w.Type != nil {
24102		objectMap["type"] = w.Type
24103	}
24104	if w.Location != nil {
24105		objectMap["location"] = w.Location
24106	}
24107	if w.Tags != nil {
24108		objectMap["tags"] = w.Tags
24109	}
24110	return json.Marshal(objectMap)
24111}
24112
24113// UnmarshalJSON is the custom unmarshaler for Watcher struct.
24114func (w *Watcher) UnmarshalJSON(body []byte) error {
24115	var m map[string]*json.RawMessage
24116	err := json.Unmarshal(body, &m)
24117	if err != nil {
24118		return err
24119	}
24120	for k, v := range m {
24121		switch k {
24122		case "etag":
24123			if v != nil {
24124				var etag string
24125				err = json.Unmarshal(*v, &etag)
24126				if err != nil {
24127					return err
24128				}
24129				w.Etag = &etag
24130			}
24131		case "properties":
24132			if v != nil {
24133				var watcherPropertiesFormat WatcherPropertiesFormat
24134				err = json.Unmarshal(*v, &watcherPropertiesFormat)
24135				if err != nil {
24136					return err
24137				}
24138				w.WatcherPropertiesFormat = &watcherPropertiesFormat
24139			}
24140		case "id":
24141			if v != nil {
24142				var ID string
24143				err = json.Unmarshal(*v, &ID)
24144				if err != nil {
24145					return err
24146				}
24147				w.ID = &ID
24148			}
24149		case "name":
24150			if v != nil {
24151				var name string
24152				err = json.Unmarshal(*v, &name)
24153				if err != nil {
24154					return err
24155				}
24156				w.Name = &name
24157			}
24158		case "type":
24159			if v != nil {
24160				var typeVar string
24161				err = json.Unmarshal(*v, &typeVar)
24162				if err != nil {
24163					return err
24164				}
24165				w.Type = &typeVar
24166			}
24167		case "location":
24168			if v != nil {
24169				var location string
24170				err = json.Unmarshal(*v, &location)
24171				if err != nil {
24172					return err
24173				}
24174				w.Location = &location
24175			}
24176		case "tags":
24177			if v != nil {
24178				var tags map[string]*string
24179				err = json.Unmarshal(*v, &tags)
24180				if err != nil {
24181					return err
24182				}
24183				w.Tags = tags
24184			}
24185		}
24186	}
24187
24188	return nil
24189}
24190
24191// WatcherListResult list of network watcher resources.
24192type WatcherListResult struct {
24193	autorest.Response `json:"-"`
24194	Value             *[]Watcher `json:"value,omitempty"`
24195}
24196
24197// WatcherPropertiesFormat the network watcher properties.
24198type WatcherPropertiesFormat struct {
24199	// ProvisioningState - The provisioning state of the resource. Possible values include: 'Succeeded', 'Updating', 'Deleting', 'Failed'
24200	ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
24201}
24202
24203// WatchersCheckConnectivityFuture an abstraction for monitoring and retrieving the results of a long-running
24204// operation.
24205type WatchersCheckConnectivityFuture struct {
24206	azure.Future
24207}
24208
24209// Result returns the result of the asynchronous operation.
24210// If the operation has not completed it will return an error.
24211func (future *WatchersCheckConnectivityFuture) Result(client WatchersClient) (ci ConnectivityInformation, err error) {
24212	var done bool
24213	done, err = future.Done(client)
24214	if err != nil {
24215		err = autorest.NewErrorWithError(err, "network.WatchersCheckConnectivityFuture", "Result", future.Response(), "Polling failure")
24216		return
24217	}
24218	if !done {
24219		err = azure.NewAsyncOpIncompleteError("network.WatchersCheckConnectivityFuture")
24220		return
24221	}
24222	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
24223	if ci.Response.Response, err = future.GetResult(sender); err == nil && ci.Response.Response.StatusCode != http.StatusNoContent {
24224		ci, err = client.CheckConnectivityResponder(ci.Response.Response)
24225		if err != nil {
24226			err = autorest.NewErrorWithError(err, "network.WatchersCheckConnectivityFuture", "Result", ci.Response.Response, "Failure responding to request")
24227		}
24228	}
24229	return
24230}
24231
24232// WatchersDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
24233type WatchersDeleteFuture struct {
24234	azure.Future
24235}
24236
24237// Result returns the result of the asynchronous operation.
24238// If the operation has not completed it will return an error.
24239func (future *WatchersDeleteFuture) Result(client WatchersClient) (ar autorest.Response, err error) {
24240	var done bool
24241	done, err = future.Done(client)
24242	if err != nil {
24243		err = autorest.NewErrorWithError(err, "network.WatchersDeleteFuture", "Result", future.Response(), "Polling failure")
24244		return
24245	}
24246	if !done {
24247		err = azure.NewAsyncOpIncompleteError("network.WatchersDeleteFuture")
24248		return
24249	}
24250	ar.Response = future.Response()
24251	return
24252}
24253
24254// WatchersGetAzureReachabilityReportFuture an abstraction for monitoring and retrieving the results of a
24255// long-running operation.
24256type WatchersGetAzureReachabilityReportFuture struct {
24257	azure.Future
24258}
24259
24260// Result returns the result of the asynchronous operation.
24261// If the operation has not completed it will return an error.
24262func (future *WatchersGetAzureReachabilityReportFuture) Result(client WatchersClient) (arr AzureReachabilityReport, err error) {
24263	var done bool
24264	done, err = future.Done(client)
24265	if err != nil {
24266		err = autorest.NewErrorWithError(err, "network.WatchersGetAzureReachabilityReportFuture", "Result", future.Response(), "Polling failure")
24267		return
24268	}
24269	if !done {
24270		err = azure.NewAsyncOpIncompleteError("network.WatchersGetAzureReachabilityReportFuture")
24271		return
24272	}
24273	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
24274	if arr.Response.Response, err = future.GetResult(sender); err == nil && arr.Response.Response.StatusCode != http.StatusNoContent {
24275		arr, err = client.GetAzureReachabilityReportResponder(arr.Response.Response)
24276		if err != nil {
24277			err = autorest.NewErrorWithError(err, "network.WatchersGetAzureReachabilityReportFuture", "Result", arr.Response.Response, "Failure responding to request")
24278		}
24279	}
24280	return
24281}
24282
24283// WatchersGetFlowLogStatusFuture an abstraction for monitoring and retrieving the results of a long-running
24284// operation.
24285type WatchersGetFlowLogStatusFuture struct {
24286	azure.Future
24287}
24288
24289// Result returns the result of the asynchronous operation.
24290// If the operation has not completed it will return an error.
24291func (future *WatchersGetFlowLogStatusFuture) Result(client WatchersClient) (fli FlowLogInformation, err error) {
24292	var done bool
24293	done, err = future.Done(client)
24294	if err != nil {
24295		err = autorest.NewErrorWithError(err, "network.WatchersGetFlowLogStatusFuture", "Result", future.Response(), "Polling failure")
24296		return
24297	}
24298	if !done {
24299		err = azure.NewAsyncOpIncompleteError("network.WatchersGetFlowLogStatusFuture")
24300		return
24301	}
24302	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
24303	if fli.Response.Response, err = future.GetResult(sender); err == nil && fli.Response.Response.StatusCode != http.StatusNoContent {
24304		fli, err = client.GetFlowLogStatusResponder(fli.Response.Response)
24305		if err != nil {
24306			err = autorest.NewErrorWithError(err, "network.WatchersGetFlowLogStatusFuture", "Result", fli.Response.Response, "Failure responding to request")
24307		}
24308	}
24309	return
24310}
24311
24312// WatchersGetNetworkConfigurationDiagnosticFuture an abstraction for monitoring and retrieving the results of a
24313// long-running operation.
24314type WatchersGetNetworkConfigurationDiagnosticFuture struct {
24315	azure.Future
24316}
24317
24318// Result returns the result of the asynchronous operation.
24319// If the operation has not completed it will return an error.
24320func (future *WatchersGetNetworkConfigurationDiagnosticFuture) Result(client WatchersClient) (cdr ConfigurationDiagnosticResponse, err error) {
24321	var done bool
24322	done, err = future.Done(client)
24323	if err != nil {
24324		err = autorest.NewErrorWithError(err, "network.WatchersGetNetworkConfigurationDiagnosticFuture", "Result", future.Response(), "Polling failure")
24325		return
24326	}
24327	if !done {
24328		err = azure.NewAsyncOpIncompleteError("network.WatchersGetNetworkConfigurationDiagnosticFuture")
24329		return
24330	}
24331	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
24332	if cdr.Response.Response, err = future.GetResult(sender); err == nil && cdr.Response.Response.StatusCode != http.StatusNoContent {
24333		cdr, err = client.GetNetworkConfigurationDiagnosticResponder(cdr.Response.Response)
24334		if err != nil {
24335			err = autorest.NewErrorWithError(err, "network.WatchersGetNetworkConfigurationDiagnosticFuture", "Result", cdr.Response.Response, "Failure responding to request")
24336		}
24337	}
24338	return
24339}
24340
24341// WatchersGetNextHopFuture an abstraction for monitoring and retrieving the results of a long-running operation.
24342type WatchersGetNextHopFuture struct {
24343	azure.Future
24344}
24345
24346// Result returns the result of the asynchronous operation.
24347// If the operation has not completed it will return an error.
24348func (future *WatchersGetNextHopFuture) Result(client WatchersClient) (nhr NextHopResult, err error) {
24349	var done bool
24350	done, err = future.Done(client)
24351	if err != nil {
24352		err = autorest.NewErrorWithError(err, "network.WatchersGetNextHopFuture", "Result", future.Response(), "Polling failure")
24353		return
24354	}
24355	if !done {
24356		err = azure.NewAsyncOpIncompleteError("network.WatchersGetNextHopFuture")
24357		return
24358	}
24359	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
24360	if nhr.Response.Response, err = future.GetResult(sender); err == nil && nhr.Response.Response.StatusCode != http.StatusNoContent {
24361		nhr, err = client.GetNextHopResponder(nhr.Response.Response)
24362		if err != nil {
24363			err = autorest.NewErrorWithError(err, "network.WatchersGetNextHopFuture", "Result", nhr.Response.Response, "Failure responding to request")
24364		}
24365	}
24366	return
24367}
24368
24369// WatchersGetTroubleshootingFuture an abstraction for monitoring and retrieving the results of a long-running
24370// operation.
24371type WatchersGetTroubleshootingFuture struct {
24372	azure.Future
24373}
24374
24375// Result returns the result of the asynchronous operation.
24376// If the operation has not completed it will return an error.
24377func (future *WatchersGetTroubleshootingFuture) Result(client WatchersClient) (tr TroubleshootingResult, err error) {
24378	var done bool
24379	done, err = future.Done(client)
24380	if err != nil {
24381		err = autorest.NewErrorWithError(err, "network.WatchersGetTroubleshootingFuture", "Result", future.Response(), "Polling failure")
24382		return
24383	}
24384	if !done {
24385		err = azure.NewAsyncOpIncompleteError("network.WatchersGetTroubleshootingFuture")
24386		return
24387	}
24388	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
24389	if tr.Response.Response, err = future.GetResult(sender); err == nil && tr.Response.Response.StatusCode != http.StatusNoContent {
24390		tr, err = client.GetTroubleshootingResponder(tr.Response.Response)
24391		if err != nil {
24392			err = autorest.NewErrorWithError(err, "network.WatchersGetTroubleshootingFuture", "Result", tr.Response.Response, "Failure responding to request")
24393		}
24394	}
24395	return
24396}
24397
24398// WatchersGetTroubleshootingResultFuture an abstraction for monitoring and retrieving the results of a
24399// long-running operation.
24400type WatchersGetTroubleshootingResultFuture struct {
24401	azure.Future
24402}
24403
24404// Result returns the result of the asynchronous operation.
24405// If the operation has not completed it will return an error.
24406func (future *WatchersGetTroubleshootingResultFuture) Result(client WatchersClient) (tr TroubleshootingResult, err error) {
24407	var done bool
24408	done, err = future.Done(client)
24409	if err != nil {
24410		err = autorest.NewErrorWithError(err, "network.WatchersGetTroubleshootingResultFuture", "Result", future.Response(), "Polling failure")
24411		return
24412	}
24413	if !done {
24414		err = azure.NewAsyncOpIncompleteError("network.WatchersGetTroubleshootingResultFuture")
24415		return
24416	}
24417	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
24418	if tr.Response.Response, err = future.GetResult(sender); err == nil && tr.Response.Response.StatusCode != http.StatusNoContent {
24419		tr, err = client.GetTroubleshootingResultResponder(tr.Response.Response)
24420		if err != nil {
24421			err = autorest.NewErrorWithError(err, "network.WatchersGetTroubleshootingResultFuture", "Result", tr.Response.Response, "Failure responding to request")
24422		}
24423	}
24424	return
24425}
24426
24427// WatchersGetVMSecurityRulesFuture an abstraction for monitoring and retrieving the results of a long-running
24428// operation.
24429type WatchersGetVMSecurityRulesFuture struct {
24430	azure.Future
24431}
24432
24433// Result returns the result of the asynchronous operation.
24434// If the operation has not completed it will return an error.
24435func (future *WatchersGetVMSecurityRulesFuture) Result(client WatchersClient) (sgvr SecurityGroupViewResult, err error) {
24436	var done bool
24437	done, err = future.Done(client)
24438	if err != nil {
24439		err = autorest.NewErrorWithError(err, "network.WatchersGetVMSecurityRulesFuture", "Result", future.Response(), "Polling failure")
24440		return
24441	}
24442	if !done {
24443		err = azure.NewAsyncOpIncompleteError("network.WatchersGetVMSecurityRulesFuture")
24444		return
24445	}
24446	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
24447	if sgvr.Response.Response, err = future.GetResult(sender); err == nil && sgvr.Response.Response.StatusCode != http.StatusNoContent {
24448		sgvr, err = client.GetVMSecurityRulesResponder(sgvr.Response.Response)
24449		if err != nil {
24450			err = autorest.NewErrorWithError(err, "network.WatchersGetVMSecurityRulesFuture", "Result", sgvr.Response.Response, "Failure responding to request")
24451		}
24452	}
24453	return
24454}
24455
24456// WatchersListAvailableProvidersFuture an abstraction for monitoring and retrieving the results of a long-running
24457// operation.
24458type WatchersListAvailableProvidersFuture struct {
24459	azure.Future
24460}
24461
24462// Result returns the result of the asynchronous operation.
24463// If the operation has not completed it will return an error.
24464func (future *WatchersListAvailableProvidersFuture) Result(client WatchersClient) (apl AvailableProvidersList, err error) {
24465	var done bool
24466	done, err = future.Done(client)
24467	if err != nil {
24468		err = autorest.NewErrorWithError(err, "network.WatchersListAvailableProvidersFuture", "Result", future.Response(), "Polling failure")
24469		return
24470	}
24471	if !done {
24472		err = azure.NewAsyncOpIncompleteError("network.WatchersListAvailableProvidersFuture")
24473		return
24474	}
24475	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
24476	if apl.Response.Response, err = future.GetResult(sender); err == nil && apl.Response.Response.StatusCode != http.StatusNoContent {
24477		apl, err = client.ListAvailableProvidersResponder(apl.Response.Response)
24478		if err != nil {
24479			err = autorest.NewErrorWithError(err, "network.WatchersListAvailableProvidersFuture", "Result", apl.Response.Response, "Failure responding to request")
24480		}
24481	}
24482	return
24483}
24484
24485// WatchersSetFlowLogConfigurationFuture an abstraction for monitoring and retrieving the results of a long-running
24486// operation.
24487type WatchersSetFlowLogConfigurationFuture struct {
24488	azure.Future
24489}
24490
24491// Result returns the result of the asynchronous operation.
24492// If the operation has not completed it will return an error.
24493func (future *WatchersSetFlowLogConfigurationFuture) Result(client WatchersClient) (fli FlowLogInformation, err error) {
24494	var done bool
24495	done, err = future.Done(client)
24496	if err != nil {
24497		err = autorest.NewErrorWithError(err, "network.WatchersSetFlowLogConfigurationFuture", "Result", future.Response(), "Polling failure")
24498		return
24499	}
24500	if !done {
24501		err = azure.NewAsyncOpIncompleteError("network.WatchersSetFlowLogConfigurationFuture")
24502		return
24503	}
24504	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
24505	if fli.Response.Response, err = future.GetResult(sender); err == nil && fli.Response.Response.StatusCode != http.StatusNoContent {
24506		fli, err = client.SetFlowLogConfigurationResponder(fli.Response.Response)
24507		if err != nil {
24508			err = autorest.NewErrorWithError(err, "network.WatchersSetFlowLogConfigurationFuture", "Result", fli.Response.Response, "Failure responding to request")
24509		}
24510	}
24511	return
24512}
24513
24514// WatchersVerifyIPFlowFuture an abstraction for monitoring and retrieving the results of a long-running operation.
24515type WatchersVerifyIPFlowFuture struct {
24516	azure.Future
24517}
24518
24519// Result returns the result of the asynchronous operation.
24520// If the operation has not completed it will return an error.
24521func (future *WatchersVerifyIPFlowFuture) Result(client WatchersClient) (vifr VerificationIPFlowResult, err error) {
24522	var done bool
24523	done, err = future.Done(client)
24524	if err != nil {
24525		err = autorest.NewErrorWithError(err, "network.WatchersVerifyIPFlowFuture", "Result", future.Response(), "Polling failure")
24526		return
24527	}
24528	if !done {
24529		err = azure.NewAsyncOpIncompleteError("network.WatchersVerifyIPFlowFuture")
24530		return
24531	}
24532	sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
24533	if vifr.Response.Response, err = future.GetResult(sender); err == nil && vifr.Response.Response.StatusCode != http.StatusNoContent {
24534		vifr, err = client.VerifyIPFlowResponder(vifr.Response.Response)
24535		if err != nil {
24536			err = autorest.NewErrorWithError(err, "network.WatchersVerifyIPFlowFuture", "Result", vifr.Response.Response, "Failure responding to request")
24537		}
24538	}
24539	return
24540}
24541