/// <summary>
        /// Updates the specified entity.
        /// </summary>
        /// <param name="entity">The entity.</param>
        /// <returns>Task&lt;FileStorageEntity&gt;.</returns>
        public virtual async Task <FileStorageEntity> Update(FileStorageEntity entity)
        {
            await FormatStorageKey(entity);

            await _provider.Update(entity);

            return(entity);
        }
        /// <summary>
        /// Inserts the specified entity.
        /// </summary>
        /// <param name="entity">The entity.</param>
        /// <returns>Task&lt;FileStorageEntity&gt;.</returns>
        public virtual async Task <FileStorageEntity> Insert(FileStorageEntity entity)
        {
            await FormatStorageKey(entity);

            await _provider.Insert(entity);

            return(entity);
        }
 public void UpdateSync(FileStorageEntity entity, bool deferCommit = false)
 {
     throw new NotImplementedException();
 }
 public Task Insert(FileStorageEntity entity, bool deferCommit = false)
 {
     throw new NotImplementedException();
 }
 /// <summary>
 /// Updates the specified entity.
 /// </summary>
 /// <param name="entity">The entity.</param>
 /// <returns>Task.</returns>
 public virtual async Task Update(FileStorageEntity entity)
 {
     await _repository.Update(entity);
 }
 /// <summary>
 /// Inserts the specified entity.
 /// </summary>
 /// <param name="entity">The entity.</param>
 /// <returns>Task.</returns>
 public virtual async Task Insert(FileStorageEntity entity)
 {
     await _repository.Insert(entity);
 }
 /// <summary>
 /// Deletes the specified entity.
 /// </summary>
 /// <param name="entity">The entity.</param>
 /// <returns>Task.</returns>
 public virtual async Task Delete(FileStorageEntity entity)
 {
     await _repository.Delete(entity);
 }
 protected virtual Task FormatStorageKey(FileStorageEntity entity)
 {
     return(Task.CompletedTask);
 }
 /// <summary>
 /// Deletes the specified entity.
 /// </summary>
 /// <param name="entity">The entity.</param>
 /// <returns>Task.</returns>
 public virtual async Task Delete(FileStorageEntity entity)
 {
     await _provider.Delete(entity);
 }