public static PlayerOpponentSummary Get(SafeDataReader dr) { PlayerOpponentSummary PlayerOpponentSummary = new PlayerOpponentSummary(); PlayerOpponentSummary.Fetch(dr); return PlayerOpponentSummary; }
public static PlayerOpponentSummary GetTotal(IEnumerable<PlayerOpponentSummary> list) { PlayerOpponentSummary total = new PlayerOpponentSummary(); total._Name = "Total"; foreach (PlayerOpponentSummary item in list) { total._Matches.Won += item._Matches.Won; total._Matches.Lost += item._Matches.Lost; total._Sets.Won += item._Sets.Won; total._Sets.Lost += item._Sets.Lost; total._Games.Won += item._Games.Won; total._Games.Lost += item._Games.Lost; } return total; }