Class EntityFrameworkCoreTransaction
- Namespace
- JsonApiDotNetCore.AtomicOperations
- Assembly
- JsonApiDotNetCore.dll
Represents an Entity Framework Core transaction in an atomic:operations request.
[PublicAPI]
public sealed class EntityFrameworkCoreTransaction : IOperationsTransaction, IAsyncDisposable
- Inheritance
-
EntityFrameworkCoreTransaction
- Implements
- Inherited Members
Constructors
EntityFrameworkCoreTransaction(IDbContextTransaction, DbContext)
public EntityFrameworkCoreTransaction(IDbContextTransaction transaction, DbContext dbContext)
Parameters
transaction
IDbContextTransactiondbContext
DbContext
Properties
TransactionId
Identifies the active transaction.
public string TransactionId { get; }
Property Value
Methods
AfterProcessOperationAsync(CancellationToken)
Does nothing.
public Task AfterProcessOperationAsync(CancellationToken cancellationToken)
Parameters
cancellationToken
CancellationToken
Returns
BeforeProcessOperationAsync(CancellationToken)
Detaches all entities from the Entity Framework Core change tracker.
public Task BeforeProcessOperationAsync(CancellationToken cancellationToken)
Parameters
cancellationToken
CancellationToken
Returns
CommitAsync(CancellationToken)
Commits all changes made to the underlying data store.
public Task CommitAsync(CancellationToken cancellationToken)
Parameters
cancellationToken
CancellationToken
Returns
DisposeAsync()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources asynchronously.
public ValueTask DisposeAsync()
Returns
- ValueTask
A task that represents the asynchronous dispose operation.