Exemplo n.º 1
0
 public IEnumerable <TransitStop> GetStops()
 {
     foreach (var key in PageAssociations.Where(ass => ass.Item1 == ID).Select(ass => ass.Item2))
     {
         yield return(StopCache[key]);
     }
 }
Exemplo n.º 2
0
 public void Add(params TransitStop[] stops)
 {
     foreach (var stop in stops)
     {
         var association = new Tuple <string, string>(ID, stop.ID);
         if (!PageAssociations.Contains((association)))
         {
             PageAssociations.Add(association);
             if (!StopCache.ContainsKey(stop.ID))
             {
                 StopCache.Add(stop.ID, stop);
             }
         }
     }
 }
Exemplo n.º 3
0
 public void Dispose()
 {
     PageAssociations.RemoveWhere(item => item.Item1 == ID);
     Clean();
 }