Beispiel #1
0
        public ConfigurableSwitchSortClauseBuilder <TRequest, TEntity, TValue> ThenBy(string entityProperty)
        {
            var clauseBuilder = ConfigurableSwitchSortClauseBuilder <TRequest, TEntity, TValue>
                                .From(this, entityProperty);

            Clauses.Add(clauseBuilder);

            return(clauseBuilder);
        }
Beispiel #2
0
        public ConfigurableSwitchSortClauseBuilder <TRequest, TEntity, TValue> SortBy(string entityProperty)
        {
            var clauseBuilder = ConfigurableSwitchSortClauseBuilder <TRequest, TEntity, TValue>
                                .From(this as SwitchSortContinuationOperationBuilder <TRequest, TEntity, TValue>, entityProperty);

            Clauses.Add(clauseBuilder);

            return(clauseBuilder);
        }
Beispiel #3
0
        public ConfigurableSwitchSortClauseBuilder <TRequest, TEntity, TValue> ThenBy <TProp>(
            Expression <Func <TEntity, TProp> > entityProperty)
        {
            var clauseBuilder = ConfigurableSwitchSortClauseBuilder <TRequest, TEntity, TValue>
                                .From(this, entityProperty);

            Clauses.Add(clauseBuilder);

            return(clauseBuilder);
        }
Beispiel #4
0
        internal static ConfigurableSwitchSortClauseBuilder <TRequest, TEntity, TValue> From <TProp>(
            SwitchSortContinuationOperationBuilder <TRequest, TEntity, TValue> parent,
            Expression <Func <TEntity, TProp> > entityProperty)
        {
            var clauseBuilder = new ConfigurableSwitchSortClauseBuilder <TRequest, TEntity, TValue>(parent)
            {
                Clause = new SwitchSortClause <TRequest, TEntity, TProp>
                {
                    Direction = SortDirection.Default,
                    Clause    = entityProperty
                }
            };

            clauseBuilder.Clause.Direction = SortDirection.Default;

            return(clauseBuilder);
        }