public static Criteria Add(this Criteria criteria, FilterExpression expression)
        {
            var columnType = Type.GetType(expression.ColumnType);

            if (!columnType.IsValueType)
            {
                if (Equals(expression.Lower, null) == false)
                {
                    if (expression.Lower != null || expression.Higher != null)
                    {
                        if (expression.Lower.ToString() != "")
                        {
                            criteria = criteria.AddFilter(expression);
                        }
                    }
                }
            }
            else
            {
                criteria = criteria.AddFilter(expression);
            }
            return(criteria);
        }
 public static Criteria Add <T>(this Criteria criteria, string name, T value)
 {
     criteria = criteria.AddFilter(GetFilterExpression(name, value));
     return(criteria);
 }