예제 #1
0
        public void GetData(TennisMatch Match)
        {
            ID          = Match.ID;
            StartTime   = Match.Duration.FirstSession;
            Duration    = Match.Duration.Duration;
            Winner      = Match.Winner;
            Status      = Match.Status;
            Contestant1 = Match.Contestant1.getName();
            Contestant2 = Match.Contestant2.getName();
            MatchType   = Match.Type.ToString() + " | best of " + Match.BestOutOf.ToString();
            MatchType   = MatchType.ToUpper();
            Location    = Match.Location;
            Surface     = Match.MatchSurface == TennisMatch.Surface.ArtificialGrass ? "Artificial grass" :  Match.MatchSurface.ToString();

            Sets.Clear();

            foreach (TennisSet Set in Match.Sets)
            {
                vmSetScore _sSet = new vmSetScore(Set);
                Sets.Add(_sSet);
            }
        }