public Query <T> OrderByDescending <TKey>(Expression <Func <T, TKey> > keySelector) { Sortings.Add(new Sorting { PropertyName = GetPropertyPath(keySelector), Direction = SortDirection.Descending }); return(this); }
public Query <T> OrderBy(string propertyName) { Sortings.Add(new Sorting { PropertyName = propertyName, Direction = SortDirection.Ascending }); return(this); }
private void FillSorts(HtmlNodeCollection sorts) { foreach (var sort in sorts) { var aTag = sort.FirstChild; var text = aTag.InnerText; var attr = HttpUtility.UrlEncode(aTag.GetAttributeValue("value", string.Empty)); Sortings.Add(text, attr); } }
public LinqToSolrQuery AddSorting(Expression field, SolrSortTypes order) { Sortings.Add(LinqToSolrSort.Create(field, order)); return(this); }