public void Update(string property, TargetOption option, string valueList) { Guard.IsNotNullOrEmpty(property, "Invalid property"); Guard.IsNotNullOrEmpty(valueList, "Invalid userList"); Option = option; Property = property; ValuesList = ValuesList.NewList(valueList); }
public static TargetSpecificUsers New(UserTargeting userTargeting, string property, TargetOption option, string valueList) { Guard.IsNotNullOrEmpty(property, "Invalid property"); Guard.IsNotNullOrEmpty(valueList, "Invalid userList"); return(new TargetSpecificUsers { Option = option, Property = property.ToLower(), UserTargetingId = userTargeting.Id, UserTargeting = userTargeting, ValuesList = ValuesList.NewList(valueList) }); }