public override bool IsTarget(TargetUser user)
        {
            if (!user.ContainsKey(Property))
            {
                return(false);
            }

            var value = user[Property];

            return(ValuesList.Apply(value, Option));
        }
Beispiel #2
0
        public override bool IsTarget(TargetUser user)
        {
            if (Percent.Number == 0)
            {
                return(false);
            }

            var hashId = Security.CreateMD5(user["id"] + UserTargeting.EnvironmentId.ToString()).ToLower();
            int value  = int.Parse(hashId[0].ToString(), System.Globalization.NumberStyles.HexNumber);


            var number = (Percent.Number / 100.0) * 16;

            return(value <= number);
        }
Beispiel #3
0
 public abstract bool IsTarget(TargetUser user);