public RepositorySet( IRaceSettingsRepository raceSettings, IStartingListRepository startingList, IStartingLanesRepository startingLanes, IDisciplinesRepository disciplines, IResultsListsRepository resultsLists, IAthletesRepository athletes, IJudgesRepository judges) { this.raceSettings = raceSettings; this.startingList = startingList; this.startingLanes = startingLanes; this.disciplines = disciplines; this.resultsLists = resultsLists; this.athletes = athletes; this.judges = judges; }
//if mock repo object passed to constructor, use Mock interface for unit testing public AthletesController(IAthletesRepository smRepo) { this.db = smRepo; }
//if param passed to constructor, use EF Repository & DbContext public AthletesController() { this.db = new EFAthletesRepository(); }