/// <summary> /// Add an email struct to the customer object /// </summary> /// <param name="vo"></param> public void addEmail(CustomerEmailVO vo) { if (this.emails.Contains(vo)) { return; } this.emails.Add(vo); }
/// <summary> /// Gives the alternate email address of the customer /// </summary> /// <returns></returns> public CustomerEmailVO getAlternateEmail() { CustomerEmailVO custemail = this.emails.Find(delegate(CustomerEmailVO emailObj) { return(emailObj.EmailAddressType == CustomerEmailTypes.SECONDARY_EMAIL); }); return(custemail); }
/// <summary> /// Gives the primary email address of the customer /// </summary> /// <returns></returns> public CustomerEmailVO getPrimaryEmail() { CustomerEmailVO custemail = this.emails.Find(delegate(CustomerEmailVO emailObj) { return(emailObj.EmailAddressType == CustomerEmailTypes.PRIMARY_EMAIL); }); return(custemail); }