Beispiel #1
0
		public static Set parseSetScore(this string setString)
		{
			setString = setString.Replace(" ", "");
			string[] scores = setString.Split("()".ToCharArray());
			Set set = new Set();
			set.Games = parseScore(scores[0]);
			if (scores.Length > 1)
				set.Tiebreak = parseScore(scores[1]);
			return set;
		}
Beispiel #2
0
		private static void AddSet(this Match match, byte winnerGames, byte loserGames, byte? winnerTiebreak, byte? loserTiebreak)
		{
			var set = new Set();
			set.Games.W = winnerGames;
			set.Games.L = loserGames;
			if (!set.Games.Played)
				return;
			set.Tiebreak.W = winnerTiebreak.HasValue ? winnerTiebreak.Value : (byte)0;
			set.Tiebreak.L = loserTiebreak.HasValue ? loserTiebreak.Value : (byte)0;
			match.Score.Sets.Add(set);
		}