public LeagueAndSeasonInfo AddOrUpdateName(string key, string name) { LeagueAndSeasonInfo leagueAndSeasonInfo; if (!_Dictionary.TryGetValue(key, out leagueAndSeasonInfo)) { var leagueInfo = new LeagueInfo(key, name); leagueAndSeasonInfo = new LeagueAndSeasonInfo(leagueInfo); _Dictionary.Add(key, leagueAndSeasonInfo); } else { leagueAndSeasonInfo.League.Name = name; } return(leagueAndSeasonInfo); }
public LeagueAndSeasonInfo(LeagueInfo leagueInfo) { League = leagueInfo; Seasons = new List <SeasonInfo>(); }