Пример #1
0
        public static Expression <Func <T, bool> > AndByGuid <T>(string key, Guid val)
        {
            if (string.IsNullOrEmpty(key) || val == null)
            {
                return(null);
            }
            var expression = EfUtils.True <T>();

            expression = expression.And(EfUtils.AndByGuid <T>("Guid", key, val));
            return(expression);
        }
Пример #2
0
        public static Expression <Func <T, bool> > AndByGuid <T>(string[] keys, Guid val)
        {
            if (keys == null || val == null)
            {
                return(null);
            }
            var expression = EfUtils.True <T>();

            for (int i = 0; i < keys.Length; i++)
            {
                var text = keys[i];
                expression = expression.And(EfUtils.AndByGuid <T>("Guid", text, val));
            }
            return(expression);
        }