internal void AddSort(IRoleType sortRoleType, SortDirection sortDirection) { if (this.subSorter == null) { this.subSorter = new AllorsExtentSortSql(this.session, sortRoleType, sortDirection); } else { this.subSorter.AddSort(sortRoleType, sortDirection); } }
public override Extent AddSort(IRoleType roleType, SortDirection sortDirection) { this.LazyLoadFilter(); // This will upgrade a strategy extent to a full extent this.FlushCache(); if (this.sorter == null) { this.sorter = new AllorsExtentSortSql(this.Session, roleType, sortDirection); } else { this.sorter.AddSort(roleType, sortDirection); } return(this); }
internal void BuildOrder(AllorsExtentSortSql sorter, Mapping mapping, AllorsExtentStatementSql statement) { if (sorter.Equals(this)) { statement.Append(" ORDER BY " + this.roleType.SingularFullName + "_R" + ".R"); } else { statement.Append(" , " + this.roleType.SingularFullName + "_R" + ".R"); } statement.Append(this.sortDirection == SortDirection.Ascending ? " ASC " : " DESC "); if (this.subSorter != null) { this.subSorter.BuildOrder(sorter, mapping, statement); } }
public override Extent AddSort(IRoleType roleType, SortDirection sortDirection) { this.LazyLoadFilter(); // This will upgrade a strategy extent to a full extent this.FlushCache(); if (this.sorter == null) { this.sorter = new AllorsExtentSortSql(this.Session, roleType, sortDirection); } else { this.sorter.AddSort(roleType, sortDirection); } return this; }