diff --git a/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/DisableEntityChangeTrackingAttribute.cs b/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/DisableEntityChangeTrackingAttribute.cs index d6a73cba32..76a2bdeaa1 100644 --- a/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/DisableEntityChangeTrackingAttribute.cs +++ b/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/DisableEntityChangeTrackingAttribute.cs @@ -2,6 +2,9 @@ using System; namespace Volo.Abp.Domain.Repositories; +/// +/// Ensures that the change tracking in enabled for the given method or class. +/// [AttributeUsage(AttributeTargets.Method | AttributeTargets.Class | AttributeTargets.Interface)] public class DisableEntityChangeTrackingAttribute : EntityChangeTrackingAttribute { diff --git a/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/EnableEntityChangeTrackingAttribute.cs b/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/EnableEntityChangeTrackingAttribute.cs index a94df978fb..9765d3253f 100644 --- a/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/EnableEntityChangeTrackingAttribute.cs +++ b/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/EnableEntityChangeTrackingAttribute.cs @@ -2,6 +2,9 @@ using System; namespace Volo.Abp.Domain.Repositories; +/// +/// Ensures that the change tracking in enabled for the given method or class. +/// [AttributeUsage(AttributeTargets.Method | AttributeTargets.Class | AttributeTargets.Interface)] public class EnableEntityChangeTrackingAttribute : EntityChangeTrackingAttribute { diff --git a/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/RepositoryExtensions.cs b/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/RepositoryExtensions.cs index 710140d2ec..d40449a2e4 100644 --- a/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/RepositoryExtensions.cs +++ b/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Repositories/RepositoryExtensions.cs @@ -145,11 +145,25 @@ public static class RepositoryExtensions } } + /// + /// Disables change tracking mechanism for the given repository. + /// + /// A repository object + /// + /// A disposable object. Dispose it to restore change tracking mechanism back to its previous state. + /// public static IDisposable DisableTracking(this IRepository repository) { return Tracking(repository, false); } + /// + /// Enables change tracking mechanism for the given repository. + /// + /// A repository object + /// + /// A disposable object. Dispose it to restore change tracking mechanism back to its previous state. + /// public static IDisposable EnableTracking(this IRepository repository) { return Tracking(repository, true);