/// <summary>
 /// Releases unmanaged and - optionally - managed resources
 /// </summary>
 /// <param name="disposing"><c>true</c> to release both managed and unmanaged resources; <c>false</c> to release only unmanaged resources.</param>
 protected virtual void Dispose(bool disposing)
 {
     lock (this)
     {
         if (disposing)
         {
             _repository.Dispose();
         }
     }
 }
 public void Dispose()
 {
     _repository.Dispose();
 }
 protected override void DisposeManaged()
 {
     _repository.Dispose();
 }