internal BirthdayEventCommandResult OnContactModified(IBirthdayContact birthdayContact, IBirthdaysContainer birthdaysContainer) { IBirthdayContactInternal birthdayContactInternal = birthdayContact as IBirthdayContactInternal; if (birthdayContactInternal == null) { throw new ArgumentException("Argument must implement IBirthdayContactInternal", "birthdayContact"); } IEnumerable <IBirthdayContact> linkedContacts = birthdaysContainer.Contacts.GetLinkedContacts(birthdayContactInternal.PersonId); return(birthdaysContainer.Events.UpdateBirthdaysForLinkedContacts(linkedContacts)); }
internal BirthdayEventCommandResult OnContactAdded(IBirthdayContact birthdayContact, IBirthdaysContainer birthdaysContainer) { return(birthdaysContainer.Events.CreateBirthdayEventForContact(birthdayContact)); }
internal BirthdayEventCommandResult OnContactDeleted(StoreObjectId birthdayContactStoreObjectId, IBirthdaysContainer birthdaysContainer) { return(birthdaysContainer.Events.DeleteBirthdayEventForContactId(birthdayContactStoreObjectId)); }
public BirthdayCalendars(IBirthdaysContainer parentScope, IEntityCommandFactory <IBirthdayCalendars, IBirthdayCalendar> commandFactory = null) : base(parentScope, "BirthdayCalendars", commandFactory) { this.ParentScope = parentScope; }