public void Accept(Action action) { if (acceptor.IsAccepted(action)) { notify(action); } }
public static void Notify(Action action) { foreach (HandlerBase handler in Handlers) { handler.Accept(action); } }
protected override void notify(Action action) { Email emailPrototype = EmailCreator.CreateEmail(action); IEnumerable<User> dataManagers = DmtDataProvider.GetUsers().Where(u => u.Roles.Any(r => r.Name == "DataManager")); EmailService.SendEmailsAsync(emailPrototype, dataManagers); }
protected abstract void notify(Action action);
public bool IsAccepted(Action action) { return Acceptors.All(a => a.IsAccepted(action)); }
protected override void notify(Action action) { DmtDataProvider.AddAction(action); }