Пример #1
0
        public BaseTypeTest()
        {
            _profile             = new AutoQueryableProfile();
            _queryStringAccessor = new SimpleQueryStringAccessor();
            var selectClauseHandler   = new DefaultSelectClauseHandler();
            var orderByClauseHandler  = new DefaultOrderByClauseHandler();
            var wrapWithClauseHandler = new DefaultWrapWithClauseHandler();
            var clauseMapManager      = new ClauseMapManager(selectClauseHandler, orderByClauseHandler, wrapWithClauseHandler);
            var clauseValueManager    = new ClauseValueManager(selectClauseHandler, orderByClauseHandler, wrapWithClauseHandler);
            var criteriaFilterManager = new CriteriaFilterManager();

            _autoQueryableContext = new AutoQueryableContext(_profile, new AutoQueryHandler(_queryStringAccessor, criteriaFilterManager, clauseMapManager, clauseValueManager));
        }
Пример #2
0
        public FilterTest()
        {
            var settings = new AutoQueryableSettings();

            _profile             = new AutoQueryableProfile(settings);
            _queryStringAccessor = new SimpleQueryStringAccessor();
            var selectClauseHandler     = new DefaultSelectClauseHandler();
            var orderByClauseHandler    = new DefaultOrderByClauseHandler();
            var wrapWithClauseHandler   = new DefaultWrapWithClauseHandler();
            var clauseMapManager        = new ClauseMapManager(selectClauseHandler, orderByClauseHandler, wrapWithClauseHandler);
            var clauseValueManager      = new ClauseValueManager(selectClauseHandler, orderByClauseHandler, wrapWithClauseHandler, _profile);
            var criteriaFilterManager   = new CriteriaFilterManager();
            var defaultAutoQueryHandler = new AutoQueryHandler(_queryStringAccessor, criteriaFilterManager, clauseMapManager, clauseValueManager, _profile);

            _autoQueryableContext = new AutoQueryableContext(defaultAutoQueryHandler);
        }