public class Page<E> extends ArrayList<E> implements Closeable
| Modifier and Type | Class and Description |
|---|---|
static interface |
Page.Function<E,T>
兼容低版本 Java 7-
|
modCount| Constructor and Description |
|---|
Page() |
Page(int[] rowBounds,
boolean count)
int[] rowBounds
0 : offset
1 : limit
|
Page(int pageNum,
int pageSize) |
Page(int pageNum,
int pageSize,
boolean count) |
add, add, addAll, addAll, clear, clone, contains, ensureCapacity, forEach, get, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, removeIf, removeRange, replaceAll, retainAll, set, size, sort, spliterator, subList, toArray, toArray, trimToSizeequals, hashCodecontainsAllfinalize, getClass, notify, notifyAll, wait, wait, waitcontainsAll, equals, hashCodeparallelStream, streampublic Page()
public Page(int pageNum,
int pageSize)
public Page(int pageNum,
int pageSize,
boolean count)
public Page(int[] rowBounds,
boolean count)
public String getStackTrace()
public int getPages()
public long getEndRow()
public int getPageNum()
public int getPageSize()
public long getStartRow()
public long getTotal()
public void setTotal(long total)
public Boolean getReasonable()
public Boolean getPageSizeZero()
public String getOrderBy()
public <E> Page<E> setOrderBy(String orderBy)
setUnsafeOrderBy(String) 方法orderBy - 排序字段public <E> Page<E> setUnsafeOrderBy(String orderBy)
请不要故意使用该方法注入然后提交漏洞!!!
orderBy - 排序字段public boolean isOrderByOnly()
public void setOrderByOnly(boolean orderByOnly)
public String getDialectClass()
public void setDialectClass(String dialectClass)
public Boolean getKeepOrderBy()
public Boolean getKeepSubSelectOrderBy()
public void setKeepSubSelectOrderBy(Boolean keepSubSelectOrderBy)
public Page<E> using(String dialect)
dialect - 分页实现类,可以使用 PageAutoDialect 类中注册的别名,例如 "mysql", "oracle"public boolean isCount()
public Page<E> pageSizeZero(Boolean pageSizeZero)
pageSizeZero - public Page<E> boundSqlInterceptor(BoundSqlInterceptor boundSqlInterceptor)
boundSqlInterceptor - public Page<E> countColumn(String columnName)
columnName - public Page<E> keepOrderBy(boolean keepOrderBy)
keepOrderBy - public boolean keepOrderBy()
public Page<E> keepSubSelectOrderBy(boolean keepSubSelectOrderBy)
keepSubSelectOrderBy - public boolean keepSubSelectOrderBy()
public <T> PageInfo<T> toPageInfo(Page.Function<E,T> function)
T - function - public PageSerializable<E> toPageSerializable()
public <T> PageSerializable<T> toPageSerializable(Page.Function<E,T> function)
T - function - public <E> PageSerializable<E> doSelectPageSerializable(ISelect select)
public long doCount(ISelect select)
public String getCountColumn()
public void setCountColumn(String countColumn)
public BoundSqlInterceptor getBoundSqlInterceptor()
public void setBoundSqlInterceptor(BoundSqlInterceptor boundSqlInterceptor)
public String toString()
toString in class AbstractCollection<E>public void close()
close in interface Closeableclose in interface AutoCloseableCopyright © 2023. All rights reserved.