示例#1
0
        public static Expression TestBind(FilterClause filterClause, Type filterType, IEdmModel model,
                                          IAssemblyResolver assembliesResolver, ODataQuerySettings querySettings)
        {
            if (filterClause == null)
            {
                throw Error.ArgumentNull(nameof(filterClause));
            }

            if (filterType == null)
            {
                throw Error.ArgumentNull(nameof(filterType));
            }

            if (model == null)
            {
                throw Error.ArgumentNull(nameof(model));
            }

            if (assembliesResolver == null)
            {
                throw Error.ArgumentNull(nameof(assembliesResolver));
            }

            FilterBinder binder = new FilterBinder(querySettings, assembliesResolver, model, filterType);

            return(FilterBinder.BindFilterClause(binder, filterClause, filterType));
        }