/// <summary> /// Add a location to enable for this SKU /// </summary> /// <param name="locationName">Name of location to add</param> public void AddLocation(string locationName) { if (string.IsNullOrWhiteSpace(locationName)) { throw new ArgumentNullException(nameof(locationName)); } if ((Locations != null) && (Locations.Count > 0)) { foreach (string z in Locations) { if (z.Equals(locationName, StringComparison.InvariantCultureIgnoreCase)) { throw new ArgumentException($"{locationName} already exists in list."); } } } if (Locations == null) { Locations = new List <string>(); } if (LocationInfo == null) { LocationInfo = new List <ComputeResourceSkuLocationInfo>(); } Locations.Add(locationName); LocationInfo.Add(new ComputeResourceSkuLocationInfo(locationName)); }