public Expression Build(Expression parentMember, Expression constant, bool useCaseInsensitiveComparison) { if (parentMember.Type == typeof(string) && useCaseInsensitiveComparison) { parentMember = StrategyUtils.ToLowerIfCaseInsensitive(parentMember, useCaseInsensitiveComparison); constant = StrategyUtils.ToLowerIfCaseInsensitive(constant, useCaseInsensitiveComparison); } return(_strategy.Build(parentMember, constant)); }
public Expression Build(Expression parentMember, Expression constant) { if (parentMember.Type.IsEnum) { return(StrategyUtils.CompareEnums(FilterOperation.GreaterThanOrEqual, parentMember, constant)); } else if (parentMember.Type == typeof(string)) { return(StrategyUtils.CompareStrings(FilterOperation.GreaterThanOrEqual, parentMember, constant)); } return(Expression.GreaterThanOrEqual(parentMember, constant)); }