Exemple #1
0
 public override void Update()
 {
     try
     {
         Repository.Update(DatabaseEntity);
     }
     catch (Exception exception)
     {
         if (DbExceptionUtil.IsDbConcurrencyException(exception))
         {
             throw new ConcurrencyException("Concurrency error", exception);
         }
         throw;
     }
 }
Exemple #2
0
 public override void Insert()
 {
     try
     {
         EnsureRepositoryIsNotNull();
         Repository.Insert(DatabaseEntity);
     }
     catch (Exception exception)
     {
         if (DbExceptionUtil.IsDbConcurrencyException(exception))
         {
             throw new ConcurrencyException("Concurrency error", exception);
         }
         throw;
     }
 }