private void UpdateRowObjectsWithNewWells(List<Borehole> ListOfWells) { ListOfRowInfo.Clear(); List<String> ListOfIntersectedZonesNames = new List<string>(); ListOfWells = SortListOfBoreholesByName(ListOfWells); foreach (Borehole bh in ListOfWells) { WellKhObj.Well = bh; if (WellKhObj.SetListOfNamesOfIntersectedZones(true)) { ListOfIntersectedZonesNames = WellKhObj.ListOfNamesOfIntersectedZones.Distinct().ToList(); WellKhObj.VerticalContinuity(ListOfIntersectedZonesNames); #region Getting all the names of penetrated zones into one list if (args.ListOfPenetratedZoneNames != null) { foreach (String name in ListOfIntersectedZonesNames) { if (!args.ListOfPenetratedZoneNames.Contains(name)) { args.ListOfPenetratedZoneNames.Add(name); } } } else { args.ListOfPenetratedZoneNames.AddRange(ListOfIntersectedZonesNames); } #endregion #region Creating new KhTableRowInfoContainer objects to contain all relevant information about zones, well,cells and kh Dictionary<int, List<CellData>> Dict = WellKhObj.GetKhDictionaryOfSelectedGridCells(Depth_or_Zones, PerforatedZonesOnly, true); // int counter = 0; foreach (int ind in Dict.Keys) { // Droid ArgsDroid = new Droid(CONNECTModifiedKhDataSourceFactory.DataSourceId, "ModifiedKh.KhTableRowInfoContainer_" + System.Convert.ToString(counter)); KhTableRowInfoContainer RowInfoObj = new KhTableRowInfoContainer(Dict, ind, ListOfZones[ind]); ListOfRowInfo.Add(RowInfoObj); // counter = counter + 1; } #endregion } else { MessageBox.Show("Please verify that a Permeability property and a Zone Index property have been dropped."); } } }
public KhTableRowInfoContainer CreateCopy() { KhTableRowInfoContainer ri = new KhTableRowInfoContainer(); ri.Kh_sim = this.Kh_sim; ri.Kh_wt = this.Kh_wt; try { foreach (Index3 ind in this.listOfCellInd) { ri.listOfCellInd.Add(new Index3(ind.I,ind.J,ind.K)); } } catch { } ri.AvgIJK = this.AvgIJK; ri.WellName = this.WellName; ri.ZoneName = this.ZoneName; ri.ZoneIndex = this.ZoneIndex; ri.Ratio = this.Ratio; ri.Global = this.Global; ri.Include = this.Include; ri.PropertyChanged += HandlePropertyChanged; return ri; }