/// <summary> /// Add one record to the table /// </summary> /// <param name="rec">The awyRec to add</param> public string Add(awyRec rec) { if (rec != null) { return(m_db.Add(rec)); } return(""); }
/// <summary> /// Return an Airway subtable where either start or end ICAO designator matches /// </summary> /// <param name="icao_key">The icao to match</param> /// <returns>An awyTable</returns> public awyTable GetSubtable(string icao_key) { var nT = new awyTable( ); foreach (var rec in this) { // key = ident => "icao_region_icao_region" (so find is Contains(icao), which is expensive...) if (rec.Key.Contains(icao_key)) { nT.Add(rec.Value); } } return(nT); }