public void AddOrUpdatePlayer(PlayerType player)
 {
     if (grda.Players.Contains(player))
     {
         grda.Players.Remove(player);
     }
     grda.Players.Add(player);
     grda.SubmitPlayerListChanges();
 }
Example #2
0
 private void ClearAllData(IGameRankingDataAccess DAL)
 {
     DAL.ClearAllData();
     DAL.SubmitGameListChanges();
     DAL.SubmitPlayerListChanges();
     DAL.SubmitTeamListChanges();
     DAL.SubmitmatchListChanges();
     DAL.SubmitRankingListChanges();
 }
Example #3
0
 /// <summary>
 /// Adds or updates a player
 /// </summary>
 /// <param name="player"> player </param>
 public void AddOrUpdatePlayer(PlayerType player)
 {
     if (player == null)
     {
         throw new System.InvalidOperationException("Player is null");
     }
     if (backend.Players.Contains(player))
     {
         backend.Players.Remove(player);
     }
     backend.Players.Add(player);
     backend.SubmitPlayerListChanges();
 }
Example #4
0
 private void ClearAllData(IGameRankingDataAccess DAL)
 {
     DAL.ClearAllData();
     DAL.SubmitGameListChanges();
     DAL.SubmitPlayerListChanges();
     DAL.SubmitTeamListChanges();
     DAL.SubmitmatchListChanges();
     DAL.SubmitRankingListChanges();
 }