private List <Account> FindUsersResult(string myEmail, string query) { lock (synlock) { IAccountDAO db = new AccountDAOSQL(); return(db.FindUserExceptFriend(myEmail, query)); } }
private List <Account> GetListAccountInGroup(string groupId, string myEmail) { lock (synlock3) { IAccountDAO db = new AccountDAOSQL(); return(db.GetUserInGroupExceptMe(groupId, myEmail)); } }
private List <Account> ListFriends(string email) { lock (syncLock) { IAccountDAO db = new AccountDAOSQL(); return(db.GetFriendList(email)); } }
private List <Account> NewListFriend(string email) { lock (synlock3) { var db = new AccountDAOSQL(); return(db.GetFriendList(email)); } }
private int UpdateAvatar(string email, string driveFileId) { lock (syncLock) { IAccountDAO db = new AccountDAOSQL(); return(db.UpdateAvatar(email, driveFileId)); } }
private List <Account> GetUserExceptMe(string email, string groupId) { lock (synclock1) { IAccountDAO db = new AccountDAOSQL(); return(db.GetUserInGroupExceptMe(groupId, email)); } }
private Account GetAccount(string email) { lock (synlock1) { var db = new AccountDAOSQL(); return(db.GetAccount(email)); } }
private List <Account> GetUserInGroup(string email, string groupId) { lock (syncLock) { IAccountDAO db = new AccountDAOSQL(); return(db.GetUserInGroup(groupId)); } }
private List <Account> GetAccountNotInGroup(string email, string groupId) { lock (syncLock) { IAccountDAO db = new AccountDAOSQL(); return(db.GetListFriendNotInGroup(email, groupId)); } }
private Account GetAccount(string email, string password) { lock (syncLock) { IAccountDAO db = new AccountDAOSQL(); Account account = db.GetAccount(email, password); return(account); } }
private static void InsertAccount(Account account) { lock (syncLock) { try { IAccountDAO db = new AccountDAOSQL(); db.Insert(account); } catch (Exception ex) { throw new Exception(ex.Message); } } }
private static bool IsAccountExist(string email) { lock (syncLock) { try { IAccountDAO db = new AccountDAOSQL(); var account = db.GetAccount(email); if (account.Email == email) { return(false); } return(true); } catch (Exception ex) { throw new Exception(ex.Message); } } }