Exemplo n.º 1
0
 /**
  * Orders the set based on the dynamic string expression.
  *
  * ```cs
  *  var orderedEntities = Models.Foo
  *  .OrderBy("e => e.Bar", OrderDirection.DESC)
  *  .OrderBy("e => e.Baz", OrderDirection.ASC);
  * ```
  *
  * > NOTE: ASC is the default direction, if not supplied.
  */
 public Linq <TModel> OrderBy(string predicate, OrderDirection direction = OrderDirection.ASC)
 {
     return(this.OrderBy
            (
                ExpressionBuilder.BuildPropertySelectExpression <TModel>(predicate),
                direction
            ));
 }