Exemplo n.º 1
0
 private bool TeamsPlaySport(ICollection <Team> teams, Sport sport)
 {
     return(!teams.Any(t => !t.Sport.Equals(sport)));
 }
Exemplo n.º 2
0
        public Encounter CreateEncounter(int id, ICollection <Team> list, DateTime date, Sport sport, ICollection <Commentary> comments)
        {
            Encounter built;

            if (sport.IsTwoTeams)
            {
                built = new Match(id, list, date, sport, comments);
            }
            else
            {
                built = new Competition(id, list, date, sport, comments);
            }
            return(built);
        }
Exemplo n.º 3
0
 public Encounter(int anId, ICollection <Team> teams, DateTime date, Sport sport,
                  ICollection <Commentary> comments) : this(anId, teams, date, sport)
 {
     commentaries = comments;
 }
Exemplo n.º 4
0
 public Encounter(int anId, ICollection <Team> teams, DateTime date, Sport sport) : this(teams, date, sport)
 {
     Id = anId;
 }
Exemplo n.º 5
0
 public Match(ICollection <Team> teams, DateTime date, Sport aSport) : base(teams, date, aSport)
 {
 }
Exemplo n.º 6
0
 public Match(int anId, ICollection <Team> teams, DateTime date, Sport sport,
              ICollection <Commentary> comments) : base(anId, teams, date, sport, comments)
 {
 }
Exemplo n.º 7
0
 public Match(int anId, ICollection <Team> teams, DateTime date, Sport sport) : base(anId, teams, date, sport)
 {
 }