///GENMHASH:E087239423DB24947B067EFDA925648F:F36C060B935C63BD26B291576032CC5A public IReadOnlyDictionary <Microsoft.Azure.Management.ResourceManager.Fluent.Core.Region, System.Collections.Generic.ISet <Microsoft.Azure.Management.ResourceManager.Fluent.Core.AvailabilityZoneId> > Zones() { Dictionary <Region, ISet <AvailabilityZoneId> > regionToZones = new Dictionary <Region, ISet <AvailabilityZoneId> >(); if (this.inner.LocationInfo != null) { foreach (var info in this.inner.LocationInfo) { if (info.Location != null) { var region = Region.Create(info.Location); if (!regionToZones.ContainsKey(region)) { regionToZones.Add(region, new HashSet <AvailabilityZoneId>()); } ISet <AvailabilityZoneId> availabilityZoneIds = regionToZones[region]; if (info.Zones != null) { foreach (var zoneStr in info.Zones) { var zone = AvailabilityZoneId.Parse(zoneStr); if (!availabilityZoneIds.Contains(zone)) { availabilityZoneIds.Add(zone); } } } } } } return(regionToZones); }
///GENMHASH:F856C02184EB290DC74E5823D4280D7C:C06C8F12A2F1E86C908BE0388D483D06 public System.Collections.Generic.ISet<Microsoft.Azure.Management.ResourceManager.Fluent.Core.AvailabilityZoneId> AvailabilityZones() { var zones = new HashSet<Microsoft.Azure.Management.ResourceManager.Fluent.Core.AvailabilityZoneId>(); if (this.Inner.Zones != null) { foreach (var zone in this.Inner.Zones) { zones.Add(AvailabilityZoneId.Parse(zone)); } } return zones; }
protected override ICreatable <IPublicIPAddress> ToCreatableIntern(IAzure azure) { var withRegion = azure.PublicIPAddresses.Define(DeriveName("pip")); var withGroup = withRegion.WithRegion(this.Region); var withCreate = SetResourceGroupAndTags(withGroup); if (this.LeafDomainLabel != null) { withCreate.WithLeafDomainLabel(this.LeafDomainLabel); } if (this.EnableStaticIpAddress != null && this.EnableStaticIpAddress.Value) { withCreate.WithStaticIP(); } if (this.ReverseFqdn != null) { withCreate.WithReverseFqdn(this.ReverseFqdn); } if (this.IdleTimeoutInMinutes != null) { withCreate.WithIdleTimeoutInMinutes(this.IdleTimeoutInMinutes.Value); } if (this.Sku != null) { withCreate.WithSku(PublicIPSkuType.Parse(this.Sku)); } if (this.AvailabiltiyZones != null) { foreach (var zone in this.AvailabiltiyZones) { withCreate.WithAvailabilityZone(AvailabilityZoneId.Parse(zone)); } } SetTags(withCreate); return(withCreate); }