Beispiel #1
0
        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));
        }
Beispiel #2
0
 internal BirthdayEventCommandResult OnContactAdded(IBirthdayContact birthdayContact, IBirthdaysContainer birthdaysContainer)
 {
     return(birthdaysContainer.Events.CreateBirthdayEventForContact(birthdayContact));
 }
Beispiel #3
0
 internal BirthdayEventCommandResult OnContactDeleted(StoreObjectId birthdayContactStoreObjectId, IBirthdaysContainer birthdaysContainer)
 {
     return(birthdaysContainer.Events.DeleteBirthdayEventForContactId(birthdayContactStoreObjectId));
 }
Beispiel #4
0
 public BirthdayCalendars(IBirthdaysContainer parentScope, IEntityCommandFactory <IBirthdayCalendars, IBirthdayCalendar> commandFactory = null) : base(parentScope, "BirthdayCalendars", commandFactory)
 {
     this.ParentScope = parentScope;
 }