/// <summary> /// 反注册数据更新注入器 /// </summary> public static void UnRegisterUpdateHandler(IDataTrigger handler) { if (_generalTriggers != null && _generalTriggers.Contains(handler)) { _generalTriggers.Remove(handler); } }
/// <summary> /// 注册数据更新注入器 /// </summary> public static void RegisterUpdateHandler(IDataTrigger handler) { if (_generalTriggers.All(p => p.GetType() != handler.GetType())) { _generalTriggers.Add(handler); } }