コード例 #1
0
 private static IQueryable <GameDataTransferObject> QueryGames(TicTacToeContext context)
 {
     return(context.Games
            .Include(gameDTO => gameDTO.History)
            .ThenInclude(history => history.Turns)
            .Include(gameDTO => gameDTO.Board)
            .Include(gameDTO => gameDTO.TicPlayer)
            .Include(gameDTO => gameDTO.TacPlayer));
 }
コード例 #2
0
ファイル: UserAPI.cs プロジェクト: Stelz777/TicTacToe
 public UserAPI(TicTacToeContext context, IMapper mapper)
 {
     gameRepository = new GameDbRepository(context, mapper);
 }
コード例 #3
0
 private static IQueryable <UserDataTransferObject> QueryUsers(TicTacToeContext context)
 {
     return(context.Users);
 }
コード例 #4
0
 public GameDbRepository(TicTacToeContext context, IMapper mapper)
 {
     this.mapper  = mapper;
     this.context = context;
 }