public Transfer[] GetTransfers(MetroLane[] lanes) { Transfer[] transferStations = new Transfer[lanes.Length - 1]; int j = 0; for (int i = 0; i < lanes.Length; i++) { MetroLane otherLane = lanes[i]; string trStation = lane.GetTransferStation(otherLane); if (trStation != null && !lane.Equals(otherLane) && !otherLane.Equals(previousLane)) { transferStations[j++] = new Transfer(trStation, otherLane); } } return(transferStations); }
public Route(string startingStation, MetroLane lane) { from = lane.GetFormalName(startingStation); this.lane = lane; isFirst = true; }
public Route(MetroLane lane, string transferStation, MetroLane currentLane) { this.lane = lane; from = transferStation; previousLane = currentLane; }
public Transfer(string trStation, MetroLane lane) { station = trStation; to = lane; }