Beispiel #1
0
 public void Enable(DateTime asOfDate)
 {
     if (_changeTracker.CanToggleEnabling(asOfDate))
     {
         Enabled        = true;
         _changeTracker = _changeTracker.EnablingOn(asOfDate);
     }
 }
Beispiel #2
0
 public void Enable(DateTime asOfDate)
 {
     if (this.changeTracker.CanToggleEnabling(asOfDate))
     {
         this.Enabled       = true;
         this.changeTracker = this.changeTracker.EnablingOn(asOfDate);
     }
 }
Beispiel #3
0
 public void ChangeName(string firstName, string lastName, DateTime asOfDate)
 {
     if (_changeTracker.CanChangeName(asOfDate))
     {
         FirstName      = firstName;
         LastName       = lastName;
         _changeTracker = _changeTracker.NameChangedOn(asOfDate);
     }
 }
Beispiel #4
0
 public void ChangeEmailAddress(string emailAddress, DateTime asOfDate)
 {
     if (_changeTracker.CanChangeEmailAddress(asOfDate) &&
         !EmailAddress.Equals(emailAddress))
     {
         EmailAddress   = emailAddress;
         _changeTracker = _changeTracker.EmailAddressChangedOn(asOfDate);
     }
 }
Beispiel #5
0
 public void ChangeName(string firstName, string lastName, DateTime asOfDate)
 {
     if (this.changeTracker.CanChangeName(asOfDate))
     {
         this.FirstName     = firstName;
         this.LastName      = lastName;
         this.changeTracker = this.changeTracker.NameChangedOn(asOfDate);
     }
 }
Beispiel #6
0
        public Member(
            TenantId tenantId,
            string userName,
            string firstName,
            string lastName,
            string emailAddress,
            DateTime initializedOn)
        {
            AssertionConcern.AssertArgumentNotNull(tenantId, "The tenant id must be provided.");

            TenantId       = tenantId;
            EmailAddress   = emailAddress;
            Enabled        = true;
            FirstName      = firstName;
            LastName       = lastName;
            _changeTracker = new MemberChangeTracker(initializedOn, initializedOn, initializedOn);
        }
Beispiel #7
0
        public Member(
            TenantId tenantId,
            string userName,
            string firstName,
            string lastName,
            string emailAddress,
            DateTime initializedOn)
        {
            AssertionConcern.AssertArgumentNotNull(tenantId, "The tenant id must be provided.");

            this.TenantId = tenantId;
            this.EmailAddress = emailAddress;
            this.Enabled = true;
            this.FirstName = firstName;
            this.LastName = lastName;
            this.changeTracker = new MemberChangeTracker(initializedOn, initializedOn, initializedOn);
        }
Beispiel #8
0
 public void ChangeEmailAddress(string emailAddress, DateTime asOfDate)
 {
     if (this.changeTracker.CanChangeEmailAddress(asOfDate) 
         && !this.EmailAddress.Equals(emailAddress))
     {
         this.EmailAddress = emailAddress;
         this.changeTracker = this.changeTracker.EmailAddressChangedOn(asOfDate);
     }
 }
Beispiel #9
0
 public void Enable(DateTime asOfDate)
 {
     if (this.changeTracker.CanToggleEnabling(asOfDate))
     {
         this.Enabled = true;
         this.changeTracker = this.changeTracker.EnablingOn(asOfDate);
     }
 }
Beispiel #10
0
 public void ChangeName(string firstName, string lastName, DateTime asOfDate)
 {
     if (this.changeTracker.CanChangeName(asOfDate))
     {
         this.FirstName = firstName;
         this.LastName = lastName;
         this.changeTracker = this.changeTracker.NameChangedOn(asOfDate);
     }
 }