/// <summary> /// 发生某个事件 /// </summary> /// <typeparam name="TEvent"></typeparam> /// <param name="evnt"></param> public static void Happened <TEvent>(TEvent evnt) where TEvent : class, IEvent { SEventBus.Publish(evnt); SEventBus.Commit(); }
public static void RaiseEvent <TEvent>(TEvent evnt) where TEvent : class, IEvent { SEventBus.Publish(evnt); SEventBus.Commit(); }