PlayerService.cs 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq.Expressions;
  4. using System.Threading.Tasks;
  5. using Warhammer.DataLayer.Interfaces;
  6. using Warhammer.Models;
  7. using Warhammer.Service.Interfaces;
  8. namespace Warhammer.Service
  9. {
  10. public class PlayerService : IPlayerService
  11. {
  12. private readonly IPlayerRepository _playerRepository;
  13. public PlayerService(IPlayerRepository playerRepository)
  14. {
  15. _playerRepository = playerRepository;
  16. }
  17. public Task Add(Player entity)
  18. {
  19. throw new NotImplementedException();
  20. }
  21. public Task<int> CountAll()
  22. {
  23. throw new NotImplementedException();
  24. }
  25. public Task<int> CountWhere(Expression<Func<Player, bool>> predicate)
  26. {
  27. throw new NotImplementedException();
  28. }
  29. public Task<Player> FirstOrDefault(Expression<Func<Player, bool>> predicate)
  30. {
  31. throw new NotImplementedException();
  32. }
  33. public async Task<IEnumerable<Player>> GetAll()
  34. {
  35. return await _playerRepository.GetAll();
  36. }
  37. public async Task<Player> GetById(int id)
  38. {
  39. return await _playerRepository.GetById(id);
  40. }
  41. public Task<IEnumerable<Player>> GetWhere(Expression<Func<Player, bool>> predicate)
  42. {
  43. throw new NotImplementedException();
  44. }
  45. public Task Remove(Player entity)
  46. {
  47. throw new NotImplementedException();
  48. }
  49. public Task Update(Player entity)
  50. {
  51. throw new NotImplementedException();
  52. }
  53. }
  54. }