From 4f838ea0411445f6d7757273515062f2faac1ee7 Mon Sep 17 00:00:00 2001 From: Danail Dimitrov Date: Mon, 11 Jan 2021 22:17:07 +0200 Subject: Added Interfaces for all repository classes --- .../Repositories/Contracts/IUserRepository.cs | 26 ++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 src/DevHive.Data/Repositories/Contracts/IUserRepository.cs (limited to 'src/DevHive.Data/Repositories/Contracts/IUserRepository.cs') diff --git a/src/DevHive.Data/Repositories/Contracts/IUserRepository.cs b/src/DevHive.Data/Repositories/Contracts/IUserRepository.cs new file mode 100644 index 0000000..74c4486 --- /dev/null +++ b/src/DevHive.Data/Repositories/Contracts/IUserRepository.cs @@ -0,0 +1,26 @@ +using DevHive.Data.Models; +using System; +using System.Collections.Generic; +using System.Threading.Tasks; + +namespace DevHive.Data.Repositories.Contracts +{ + public interface IUserRepository : IRepository + { + public Task AddFriendAsync(User user, User friend); + + public IEnumerable QueryAll(); + + public Task GetByUsername(string username); + + public Task RemoveFriendAsync(User user, User friend); + + public bool DoesUserExist(Guid id); + + public bool DoesUserHaveThisUsername(Guid id, string username); + + public Task DoesUsernameExist(string username); + + public Task DoesEmailExist(string email); + } +} -- cgit v1.2.3