azure_mgmt_dnsresolver 0.2.0

generated REST API bindings
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
#![doc = "generated by AutoRust"]
#![allow(non_camel_case_types)]
#![allow(unused_imports)]
use serde::{Deserialize, Serialize};
#[doc = "An error message"]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct CloudError {
    #[doc = "The body of an error message"]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub error: Option<CloudErrorBody>,
}
impl CloudError {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "The body of an error message"]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct CloudErrorBody {
    #[doc = "The error code"]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub code: Option<String>,
    #[doc = "A description of what caused the error"]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub message: Option<String>,
    #[doc = "The target resource of the error message"]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub target: Option<String>,
    #[doc = "Extra error information"]
    #[serde(default, skip_serializing_if = "Vec::is_empty")]
    pub details: Vec<CloudErrorBody>,
}
impl CloudErrorBody {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Describes a DNS forwarding ruleset."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
pub struct DnsForwardingRuleset {
    #[serde(flatten)]
    pub tracked_resource: TrackedResource,
    #[doc = "ETag of the DNS forwarding ruleset."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub etag: Option<String>,
    #[doc = "Represents the properties of a DNS forwarding ruleset."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub properties: Option<DnsForwardingRulesetProperties>,
    #[doc = "Metadata pertaining to creation and last modification of the resource."]
    #[serde(rename = "systemData", default, skip_serializing_if = "Option::is_none")]
    pub system_data: Option<SystemData>,
}
impl DnsForwardingRuleset {
    pub fn new(tracked_resource: TrackedResource) -> Self {
        Self {
            tracked_resource,
            etag: None,
            properties: None,
            system_data: None,
        }
    }
}
#[doc = "The response to an enumeration operation on DNS forwarding rulesets."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct DnsForwardingRulesetListResult {
    #[doc = "Enumeration of the DNS forwarding rulesets."]
    #[serde(default, skip_serializing_if = "Vec::is_empty")]
    pub value: Vec<DnsForwardingRuleset>,
    #[doc = "The continuation token for the next page of results."]
    #[serde(rename = "nextLink", default, skip_serializing_if = "Option::is_none")]
    pub next_link: Option<String>,
}
impl DnsForwardingRulesetListResult {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Describes a DNS forwarding ruleset PATCH operation."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct DnsForwardingRulesetPatch {
    #[doc = "Tags for DNS Resolver."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub tags: Option<serde_json::Value>,
}
impl DnsForwardingRulesetPatch {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Represents the properties of a DNS forwarding ruleset."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct DnsForwardingRulesetProperties {
    #[doc = "The reference to the DNS resolver outbound endpoints that are used to route DNS queries matching the forwarding rules in the ruleset to the target DNS servers."]
    #[serde(rename = "dnsResolverOutboundEndpoints", default, skip_serializing_if = "Vec::is_empty")]
    pub dns_resolver_outbound_endpoints: Vec<SubResource>,
    #[doc = "The current provisioning state of the resource."]
    #[serde(rename = "provisioningState", default, skip_serializing_if = "Option::is_none")]
    pub provisioning_state: Option<ProvisioningState>,
    #[doc = "The resourceGuid for the DNS forwarding ruleset."]
    #[serde(rename = "resourceGuid", default, skip_serializing_if = "Option::is_none")]
    pub resource_guid: Option<String>,
}
impl DnsForwardingRulesetProperties {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Describes a DNS resolver."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
pub struct DnsResolver {
    #[serde(flatten)]
    pub tracked_resource: TrackedResource,
    #[doc = "ETag of the DNS resolver."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub etag: Option<String>,
    #[doc = "Represents the properties of a DNS resolver."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub properties: Option<DnsResolverProperties>,
    #[doc = "Metadata pertaining to creation and last modification of the resource."]
    #[serde(rename = "systemData", default, skip_serializing_if = "Option::is_none")]
    pub system_data: Option<SystemData>,
}
impl DnsResolver {
    pub fn new(tracked_resource: TrackedResource) -> Self {
        Self {
            tracked_resource,
            etag: None,
            properties: None,
            system_data: None,
        }
    }
}
#[doc = "The response to an enumeration operation on DNS resolvers."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct DnsResolverListResult {
    #[doc = "Enumeration of the DNS resolvers."]
    #[serde(default, skip_serializing_if = "Vec::is_empty")]
    pub value: Vec<DnsResolver>,
    #[doc = "The continuation token for the next page of results."]
    #[serde(rename = "nextLink", default, skip_serializing_if = "Option::is_none")]
    pub next_link: Option<String>,
}
impl DnsResolverListResult {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Describes a DNS resolver for PATCH operation."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct DnsResolverPatch {
    #[doc = "Tags for DNS Resolver."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub tags: Option<serde_json::Value>,
}
impl DnsResolverPatch {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Represents the properties of a DNS resolver."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
pub struct DnsResolverProperties {
    #[doc = "Reference to another ARM resource."]
    #[serde(rename = "virtualNetwork")]
    pub virtual_network: SubResource,
    #[doc = "The current status of the DNS resolver. This is a read-only property and any attempt to set this value will be ignored."]
    #[serde(rename = "dnsResolverState", default, skip_serializing_if = "Option::is_none")]
    pub dns_resolver_state: Option<dns_resolver_properties::DnsResolverState>,
    #[doc = "The current provisioning state of the resource."]
    #[serde(rename = "provisioningState", default, skip_serializing_if = "Option::is_none")]
    pub provisioning_state: Option<ProvisioningState>,
    #[doc = "The Guid property of the resource."]
    #[serde(rename = "resourceGuid", default, skip_serializing_if = "Option::is_none")]
    pub resource_guid: Option<ResourceGuid>,
}
impl DnsResolverProperties {
    pub fn new(virtual_network: SubResource) -> Self {
        Self {
            virtual_network,
            dns_resolver_state: None,
            provisioning_state: None,
            resource_guid: None,
        }
    }
}
pub mod dns_resolver_properties {
    use super::*;
    #[doc = "The current status of the DNS resolver. This is a read-only property and any attempt to set this value will be ignored."]
    #[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
    pub enum DnsResolverState {
        Connected,
        Disconnected,
    }
}
#[doc = "Describes a forwarding rule within a DNS forwarding ruleset."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct ForwardingRule {
    #[serde(flatten)]
    pub proxy_resource: ProxyResource,
    #[doc = "ETag of the forwarding rule."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub etag: Option<String>,
    #[doc = "Represents the properties of a forwarding rule within a DNS forwarding ruleset."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub properties: Option<ForwardingRuleProperties>,
    #[doc = "Metadata pertaining to creation and last modification of the resource."]
    #[serde(rename = "systemData", default, skip_serializing_if = "Option::is_none")]
    pub system_data: Option<SystemData>,
}
impl ForwardingRule {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "The response to an enumeration operation on forwarding rules within a DNS forwarding ruleset."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct ForwardingRuleListResult {
    #[doc = "Enumeration of the forwarding rules."]
    #[serde(default, skip_serializing_if = "Vec::is_empty")]
    pub value: Vec<ForwardingRule>,
    #[doc = "The continuation token for the next page of results."]
    #[serde(rename = "nextLink", default, skip_serializing_if = "Option::is_none")]
    pub next_link: Option<String>,
}
impl ForwardingRuleListResult {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Describes a forwarding rule for PATCH operation."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct ForwardingRulePatch {
    #[doc = "Represents the updatable properties of a forwarding rule within a DNS forwarding ruleset."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub properties: Option<ForwardingRulePatchProperties>,
}
impl ForwardingRulePatch {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Represents the updatable properties of a forwarding rule within a DNS forwarding ruleset."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct ForwardingRulePatchProperties {
    #[doc = "DNS servers to forward the DNS query to."]
    #[serde(rename = "targetDnsServers", default, skip_serializing_if = "Vec::is_empty")]
    pub target_dns_servers: Vec<TargetDnsServer>,
    #[doc = "Metadata attached to the forwarding rule."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub metadata: Option<serde_json::Value>,
    #[doc = "The state of forwarding rule."]
    #[serde(rename = "forwardingRuleState", default, skip_serializing_if = "Option::is_none")]
    pub forwarding_rule_state: Option<forwarding_rule_patch_properties::ForwardingRuleState>,
}
impl ForwardingRulePatchProperties {
    pub fn new() -> Self {
        Self::default()
    }
}
pub mod forwarding_rule_patch_properties {
    use super::*;
    #[doc = "The state of forwarding rule."]
    #[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
    pub enum ForwardingRuleState {
        Enabled,
        Disabled,
    }
    impl Default for ForwardingRuleState {
        fn default() -> Self {
            Self::Enabled
        }
    }
}
#[doc = "Represents the properties of a forwarding rule within a DNS forwarding ruleset."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
pub struct ForwardingRuleProperties {
    #[doc = "The domain name for the forwarding rule."]
    #[serde(rename = "domainName")]
    pub domain_name: String,
    #[doc = "DNS servers to forward the DNS query to."]
    #[serde(rename = "targetDnsServers")]
    pub target_dns_servers: Vec<TargetDnsServer>,
    #[doc = "Metadata attached to the forwarding rule."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub metadata: Option<serde_json::Value>,
    #[doc = "The state of forwarding rule."]
    #[serde(rename = "forwardingRuleState", default, skip_serializing_if = "Option::is_none")]
    pub forwarding_rule_state: Option<forwarding_rule_properties::ForwardingRuleState>,
    #[doc = "The current provisioning state of the resource."]
    #[serde(rename = "provisioningState", default, skip_serializing_if = "Option::is_none")]
    pub provisioning_state: Option<ProvisioningState>,
}
impl ForwardingRuleProperties {
    pub fn new(domain_name: String, target_dns_servers: Vec<TargetDnsServer>) -> Self {
        Self {
            domain_name,
            target_dns_servers,
            metadata: None,
            forwarding_rule_state: None,
            provisioning_state: None,
        }
    }
}
pub mod forwarding_rule_properties {
    use super::*;
    #[doc = "The state of forwarding rule."]
    #[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
    pub enum ForwardingRuleState {
        Enabled,
        Disabled,
    }
}
#[doc = "Describes an inbound endpoint for a DNS resolver."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
pub struct InboundEndpoint {
    #[serde(flatten)]
    pub tracked_resource: TrackedResource,
    #[doc = "ETag of the inbound endpoint."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub etag: Option<String>,
    #[doc = "Represents the properties of an inbound endpoint for a DNS resolver."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub properties: Option<InboundEndpointProperties>,
    #[doc = "Metadata pertaining to creation and last modification of the resource."]
    #[serde(rename = "systemData", default, skip_serializing_if = "Option::is_none")]
    pub system_data: Option<SystemData>,
}
impl InboundEndpoint {
    pub fn new(tracked_resource: TrackedResource) -> Self {
        Self {
            tracked_resource,
            etag: None,
            properties: None,
            system_data: None,
        }
    }
}
#[doc = "The response to an enumeration operation on inbound endpoints for a DNS resolver."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct InboundEndpointListResult {
    #[doc = "Enumeration of the inbound endpoints for a DNS resolver."]
    #[serde(default, skip_serializing_if = "Vec::is_empty")]
    pub value: Vec<InboundEndpoint>,
    #[doc = "The continuation token for the next page of results."]
    #[serde(rename = "nextLink", default, skip_serializing_if = "Option::is_none")]
    pub next_link: Option<String>,
}
impl InboundEndpointListResult {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Describes an inbound endpoint for a DNS resolver for PATCH operation."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct InboundEndpointPatch {
    #[doc = "Tags for inbound endpoint."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub tags: Option<serde_json::Value>,
}
impl InboundEndpointPatch {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Represents the properties of an inbound endpoint for a DNS resolver."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct InboundEndpointProperties {
    #[doc = "IP configurations for the inbound endpoint."]
    #[serde(rename = "ipConfigurations", default, skip_serializing_if = "Vec::is_empty")]
    pub ip_configurations: Vec<IpConfiguration>,
    #[doc = "The current provisioning state of the resource."]
    #[serde(rename = "provisioningState", default, skip_serializing_if = "Option::is_none")]
    pub provisioning_state: Option<ProvisioningState>,
    #[doc = "The Guid property of the resource."]
    #[serde(rename = "resourceGuid", default, skip_serializing_if = "Option::is_none")]
    pub resource_guid: Option<ResourceGuid>,
}
impl InboundEndpointProperties {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "IP configuration."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct IpConfiguration {
    #[doc = "Reference to another ARM resource."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub subnet: Option<SubResource>,
    #[doc = "Private IP address of the IP configuration."]
    #[serde(rename = "privateIpAddress", default, skip_serializing_if = "Option::is_none")]
    pub private_ip_address: Option<String>,
    #[doc = "Private IP address allocation method."]
    #[serde(rename = "privateIpAllocationMethod", default, skip_serializing_if = "Option::is_none")]
    pub private_ip_allocation_method: Option<ip_configuration::PrivateIpAllocationMethod>,
}
impl IpConfiguration {
    pub fn new() -> Self {
        Self::default()
    }
}
pub mod ip_configuration {
    use super::*;
    #[doc = "Private IP address allocation method."]
    #[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
    pub enum PrivateIpAllocationMethod {
        Static,
        Dynamic,
    }
    impl Default for PrivateIpAllocationMethod {
        fn default() -> Self {
            Self::Dynamic
        }
    }
}
#[doc = "Describes an outbound endpoint for a DNS resolver."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
pub struct OutboundEndpoint {
    #[serde(flatten)]
    pub tracked_resource: TrackedResource,
    #[doc = "ETag of the outbound endpoint."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub etag: Option<String>,
    #[doc = "Represents the properties of an outbound endpoint for a DNS resolver."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub properties: Option<OutboundEndpointProperties>,
    #[doc = "Metadata pertaining to creation and last modification of the resource."]
    #[serde(rename = "systemData", default, skip_serializing_if = "Option::is_none")]
    pub system_data: Option<SystemData>,
}
impl OutboundEndpoint {
    pub fn new(tracked_resource: TrackedResource) -> Self {
        Self {
            tracked_resource,
            etag: None,
            properties: None,
            system_data: None,
        }
    }
}
#[doc = "The response to an enumeration operation on outbound endpoints for a DNS resolver."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct OutboundEndpointListResult {
    #[doc = "Enumeration of the outbound endpoints for a DNS resolver."]
    #[serde(default, skip_serializing_if = "Vec::is_empty")]
    pub value: Vec<OutboundEndpoint>,
    #[doc = "The continuation token for the next page of results."]
    #[serde(rename = "nextLink", default, skip_serializing_if = "Option::is_none")]
    pub next_link: Option<String>,
}
impl OutboundEndpointListResult {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Describes an outbound endpoint for a DNS resolver for PATCH operation."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct OutboundEndpointPatch {
    #[doc = "Tags for outbound endpoint."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub tags: Option<serde_json::Value>,
}
impl OutboundEndpointPatch {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Represents the properties of an outbound endpoint for a DNS resolver."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct OutboundEndpointProperties {
    #[doc = "Reference to another ARM resource."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub subnet: Option<SubResource>,
    #[doc = "The current provisioning state of the resource."]
    #[serde(rename = "provisioningState", default, skip_serializing_if = "Option::is_none")]
    pub provisioning_state: Option<ProvisioningState>,
    #[doc = "The Guid property of the resource."]
    #[serde(rename = "resourceGuid", default, skip_serializing_if = "Option::is_none")]
    pub resource_guid: Option<ResourceGuid>,
}
impl OutboundEndpointProperties {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "The current provisioning state of the resource."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
pub enum ProvisioningState {
    Creating,
    Updating,
    Deleting,
    Succeeded,
    Failed,
    Canceled,
}
#[doc = "The resource model definition for a Azure Resource Manager proxy resource. It will not have tags and a location"]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct ProxyResource {
    #[serde(flatten)]
    pub resource: Resource,
}
impl ProxyResource {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Common fields that are returned in the response for all Azure Resource Manager resources"]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct Resource {
    #[doc = "Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub id: Option<String>,
    #[doc = "The name of the resource"]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub name: Option<String>,
    #[doc = "The type of the resource. E.g. \"Microsoft.Compute/virtualMachines\" or \"Microsoft.Storage/storageAccounts\""]
    #[serde(rename = "type", default, skip_serializing_if = "Option::is_none")]
    pub type_: Option<String>,
}
impl Resource {
    pub fn new() -> Self {
        Self::default()
    }
}
pub type ResourceGuid = String;
#[doc = "Reference to another ARM resource."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct SubResource {
    #[doc = "Resource ID."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub id: Option<String>,
}
impl SubResource {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "The response to an enumeration operation on sub-resources."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct SubResourceListResult {
    #[doc = "Enumeration of the sub-resources."]
    #[serde(default, skip_serializing_if = "Vec::is_empty")]
    pub value: Vec<SubResource>,
    #[doc = "The continuation token for the next page of results."]
    #[serde(rename = "nextLink", default, skip_serializing_if = "Option::is_none")]
    pub next_link: Option<String>,
}
impl SubResourceListResult {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Describes a server to forward the DNS queries to."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct TargetDnsServer {
    #[doc = "DNS server IP address."]
    #[serde(rename = "ipAddress", default, skip_serializing_if = "Option::is_none")]
    pub ip_address: Option<String>,
    #[doc = "DNS server port."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub port: Option<i32>,
}
impl TargetDnsServer {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "The resource model definition for an Azure Resource Manager tracked top level resource which has 'tags' and a 'location'"]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
pub struct TrackedResource {
    #[serde(flatten)]
    pub resource: Resource,
    #[doc = "Resource tags."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub tags: Option<serde_json::Value>,
    #[doc = "The geo-location where the resource lives"]
    pub location: String,
}
impl TrackedResource {
    pub fn new(location: String) -> Self {
        Self {
            resource: Resource::default(),
            tags: None,
            location,
        }
    }
}
#[doc = "Reference to DNS forwarding ruleset and associated virtual network link."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct VirtualNetworkDnsForwardingRuleset {
    #[doc = "DNS Forwarding Ruleset Resource ID."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub id: Option<String>,
    #[doc = "The reference to the virtual network link that associates between the DNS forwarding ruleset and virtual network."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub properties: Option<VirtualNetworkLinkSubResourceProperties>,
}
impl VirtualNetworkDnsForwardingRuleset {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "The response to an enumeration operation on Virtual Network DNS Forwarding Ruleset."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct VirtualNetworkDnsForwardingRulesetListResult {
    #[doc = "Enumeration of the Virtual Network DNS Forwarding Ruleset."]
    #[serde(default, skip_serializing_if = "Vec::is_empty")]
    pub value: Vec<VirtualNetworkDnsForwardingRuleset>,
    #[doc = "The continuation token for the next page of results."]
    #[serde(rename = "nextLink", default, skip_serializing_if = "Option::is_none")]
    pub next_link: Option<String>,
}
impl VirtualNetworkDnsForwardingRulesetListResult {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Describes a virtual network link."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct VirtualNetworkLink {
    #[serde(flatten)]
    pub proxy_resource: ProxyResource,
    #[doc = "ETag of the virtual network link."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub etag: Option<String>,
    #[doc = "Represents the properties of a virtual network link."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub properties: Option<VirtualNetworkLinkProperties>,
    #[doc = "Metadata pertaining to creation and last modification of the resource."]
    #[serde(rename = "systemData", default, skip_serializing_if = "Option::is_none")]
    pub system_data: Option<SystemData>,
}
impl VirtualNetworkLink {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "The response to an enumeration operation on virtual network links."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct VirtualNetworkLinkListResult {
    #[doc = "Enumeration of the virtual network links."]
    #[serde(default, skip_serializing_if = "Vec::is_empty")]
    pub value: Vec<VirtualNetworkLink>,
    #[doc = "The continuation token for the next page of results."]
    #[serde(rename = "nextLink", default, skip_serializing_if = "Option::is_none")]
    pub next_link: Option<String>,
}
impl VirtualNetworkLinkListResult {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Describes a virtual network link for PATCH operation."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct VirtualNetworkLinkPatch {
    #[doc = "Represents the updatable properties of the virtual network link."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub properties: Option<VirtualNetworkLinkPatchProperties>,
}
impl VirtualNetworkLinkPatch {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Represents the updatable properties of the virtual network link."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct VirtualNetworkLinkPatchProperties {
    #[doc = "Metadata attached to the virtual network link."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub metadata: Option<serde_json::Value>,
}
impl VirtualNetworkLinkPatchProperties {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Represents the properties of a virtual network link."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct VirtualNetworkLinkProperties {
    #[doc = "Reference to another ARM resource."]
    #[serde(rename = "virtualNetwork", default, skip_serializing_if = "Option::is_none")]
    pub virtual_network: Option<SubResource>,
    #[doc = "Metadata attached to the virtual network link."]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub metadata: Option<serde_json::Value>,
    #[doc = "The current provisioning state of the resource."]
    #[serde(rename = "provisioningState", default, skip_serializing_if = "Option::is_none")]
    pub provisioning_state: Option<ProvisioningState>,
}
impl VirtualNetworkLinkProperties {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "The reference to the virtual network link that associates between the DNS forwarding ruleset and virtual network."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct VirtualNetworkLinkSubResourceProperties {
    #[doc = "Reference to another ARM resource."]
    #[serde(rename = "virtualNetworkLink", default, skip_serializing_if = "Option::is_none")]
    pub virtual_network_link: Option<SubResource>,
}
impl VirtualNetworkLinkSubResourceProperties {
    pub fn new() -> Self {
        Self::default()
    }
}
#[doc = "Metadata pertaining to creation and last modification of the resource."]
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize, Default)]
pub struct SystemData {
    #[doc = "The identity that created the resource."]
    #[serde(rename = "createdBy", default, skip_serializing_if = "Option::is_none")]
    pub created_by: Option<String>,
    #[doc = "The type of identity that created the resource."]
    #[serde(rename = "createdByType", default, skip_serializing_if = "Option::is_none")]
    pub created_by_type: Option<system_data::CreatedByType>,
    #[doc = "The timestamp of resource creation (UTC)."]
    #[serde(rename = "createdAt", default, skip_serializing_if = "Option::is_none")]
    pub created_at: Option<String>,
    #[doc = "The identity that last modified the resource."]
    #[serde(rename = "lastModifiedBy", default, skip_serializing_if = "Option::is_none")]
    pub last_modified_by: Option<String>,
    #[doc = "The type of identity that last modified the resource."]
    #[serde(rename = "lastModifiedByType", default, skip_serializing_if = "Option::is_none")]
    pub last_modified_by_type: Option<system_data::LastModifiedByType>,
    #[doc = "The timestamp of resource last modification (UTC)"]
    #[serde(rename = "lastModifiedAt", default, skip_serializing_if = "Option::is_none")]
    pub last_modified_at: Option<String>,
}
impl SystemData {
    pub fn new() -> Self {
        Self::default()
    }
}
pub mod system_data {
    use super::*;
    #[doc = "The type of identity that created the resource."]
    #[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
    pub enum CreatedByType {
        User,
        Application,
        ManagedIdentity,
        Key,
    }
    #[doc = "The type of identity that last modified the resource."]
    #[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
    pub enum LastModifiedByType {
        User,
        Application,
        ManagedIdentity,
        Key,
    }
}