コード例 #1
0
 public EmailCartReminderEmail(Profile profile, string profileLink)
 {
     ToAddress = profile.Email;
     TokenData = new
     {
         FullName = profile.FullName,
         ProfileLink = profileLink
     };
 }
コード例 #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ProfileInterest"/> class.
 /// </summary>
 /// <param name="profile">The profile.</param>
 /// <param name="interest">The interest.</param>
 /// <exception cref="System.ArgumentNullException">
 /// profile
 /// or
 /// interest
 /// </exception>
 public ProfileInterest(Profile profile, Interest interest)
 {
     if (profile == null)
         throw new ArgumentNullException("profile");
     if (interest == null)
         throw new ArgumentNullException("interest");
     Interest = interest;
     Profile = profile;
 }
コード例 #3
0
        public ProfileProviderOrgUnit(Profile profile, ProviderOrgUnit providerOrgUnit)
        {
            if (profile == null)
            {
                throw new ArgumentNullException("profile");
            }
            if (providerOrgUnit == null)
            {
                throw new ArgumentNullException("providerOrgUnit");
            }

            Profile = profile;
            ProviderOrgUnit = providerOrgUnit;
        }
コード例 #4
0
        private void FixupProfile(Profile previousValue)
        {
            if (previousValue != null && previousValue.ProfileProviderLocations.Contains(this))
            {
                previousValue.ProfileProviderLocations.Remove(this);
            }

            if (Profile != null)
            {
                if (!Profile.ProfileProviderLocations.Contains(this))
                {
                    Profile.ProfileProviderLocations.Add(this);
                }
                if (ProfileId != Profile.Id)
                {
                    ProfileId = Profile.Id;
                }
            }
        }