We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 75bef60 commit 25ecbfeCopy full SHA for 25ecbfe
Extensions/FreeSql.Extensions.ZeroEntity/ZeroDbContext.cs
@@ -59,13 +59,22 @@ OneToMany 级联删除
59
ManyToOne 忽略
60
ManyToMany 级联删除中间表(注意不删除外部根)
61
*/
62
- public partial class ZeroDbContext
+ public partial class ZeroDbContext : IDisposable
63
{
64
internal IFreeSql _orm;
65
internal DbTransaction _transaction;
66
internal int _commandTimeout;
67
internal List<ZeroTableInfo> _tables;
68
69
+ public void Dispose()
70
+ {
71
+ _changeReport.Clear();
72
+ _cascadeAffrows = 0;
73
+ _cascadeAuditEntityIgnores.Clear();
74
+ _cascadeIgnores.Clear();
75
+ _states.Clear();
76
+ }
77
+
78
/// <summary>
79
/// 创建新的ZeroDbCotext实例
80
/// </summary>
0 commit comments