* @param orders
* @return
*/
@SuppressWarnings("unchecked")
protected Pagination findByCriteria(Criteria crit, int pageNo, int pageSize) {
CriteriaImpl impl = (CriteriaImpl) crit;
// 先把Projection、ResultTransformer、OrderBy取出来,清空三者后再执行Count操作
Projection projection = impl.getProjection();
ResultTransformer transformer = impl.getResultTransformer();
List<CriteriaImpl.OrderEntry> orderEntries;
try {
orderEntries = (List) MyBeanUtils
.getFieldValue(impl, ORDER_ENTRIES);
MyBeanUtils.setFieldValue(impl, ORDER_ENTRIES, new ArrayList());