Tennis.TennisMatch.TennisMatch C# (CSharp) Method

TennisMatch() public method

public TennisMatch ( ITournamentRules tournamentRules, IMatchState>.Func matchStateFactory ) : System
tournamentRules ITournamentRules
matchStateFactory IMatchState>.Func
return System
        public TennisMatch(ITournamentRules tournamentRules, Func<TennisMatch, IMatchState> matchStateFactory)
            : base(new Party("A"), new Party("B"))
        {
            _tournamentRules = tournamentRules;
            _matchState = matchStateFactory(this);
            _currentSet = _matchState.GetNextSet(tournamentRules);
        }