mirror of
https://github.com/meysamhadeli/booking-microservices.git
synced 2026-04-12 03:12:11 +08:00
14 lines
347 B
C#
14 lines
347 B
C#
namespace BuildingBlocks.Mongo;
|
|
|
|
public interface IUnitOfWork : IDisposable
|
|
{
|
|
Task BeginTransactionAsync(CancellationToken cancellationToken = default);
|
|
Task CommitAsync(CancellationToken cancellationToken = default);
|
|
}
|
|
|
|
public interface IUnitOfWork<out TContext> : IUnitOfWork
|
|
where TContext : class
|
|
{
|
|
TContext Context { get; }
|
|
}
|