public NewsItemComparer(NewsItemSortField sortField) : this(false, sortField) { }
public NewsItemComparer(bool sortDescending, NewsItemSortField sortField) { this.sortField = sortField; this.sortDescending = sortDescending; }
/// <summary> /// Returns a NewsItem comparer. /// </summary> /// <param name="sortDescending">Set to False, if it should sort ascending, /// else true</param> /// <param name="sortField">indicates which field on the NewsItem object should be used for /// sorting</param> /// <returns></returns> static public IComparer <INewsItem> GetComparer(bool sortDescending, NewsItemSortField sortField) { return(new NewsItemComparer(sortDescending, sortField)); }