12 lines
316 B
C#
12 lines
316 B
C#
namespace audit.Repositories.Interfaces;
|
|
using MongoDB.Bson;
|
|
using MongoDB.Driver;
|
|
public interface IMongoRepository<T>
|
|
{
|
|
IMongoCollection<T> Collection { get; }
|
|
|
|
string GetCollectionName();
|
|
Task InsertOneAsync(T obj);
|
|
Task<T?> DeleteAsync(ObjectId id);
|
|
Task UpdateOneAsync(ObjectId id, T obj);
|
|
} |