internal void OnPreUnsafeDelete <T>(IQueryable <T> entityQuery) where T : Entity { AssertAllowed(typeof(T), inUserInterface: false); EntityEvents <T> ee = (EntityEvents <T>)entityEvents.TryGetC(typeof(T)); if (ee != null) { ee.OnPreUnsafeDelete(entityQuery); } }
internal IDisposable OnPreUnsafeDelete <T>(IQueryable <T> entityQuery) where T : Entity { AssertAllowed(typeof(T), inUserInterface: false); EntityEvents <T> ee = (EntityEvents <T>)entityEvents.TryGetC(typeof(T)); if (ee == null) { return(null); } return(ee.OnPreUnsafeDelete(entityQuery)); }
internal IDisposable?OnPreUnsafeDelete <T>(IQueryable <T> entityQuery) where T : Entity { AssertAllowed(typeof(T), inUserInterface: false); EntityEvents <T>?ee = (EntityEvents <T>?)entityEvents.TryGetC(typeof(T)); if (ee == null) { return(null); } return(Disposable.Combine(ee?.OnPreUnsafeDelete(entityQuery), entityEventsGlobal.OnPreUnsafeDelete(entityQuery))); }