public abstract class CountExecutor extends Object
| Constructor and Description |
|---|
CountExecutor() |
| Modifier and Type | Method and Description |
|---|---|
static Long |
executeAutoCount(Dialect dialect,
org.apache.ibatis.executor.Executor executor,
org.apache.ibatis.mapping.MappedStatement countMs,
Object parameter,
org.apache.ibatis.mapping.BoundSql boundSql,
org.apache.ibatis.session.RowBounds rowBounds,
org.apache.ibatis.session.ResultHandler resultHandler)
执行自动生成的 count 查询
|
static Long |
executeManualCount(org.apache.ibatis.executor.Executor executor,
org.apache.ibatis.mapping.MappedStatement countMs,
Object parameter,
org.apache.ibatis.mapping.BoundSql boundSql,
org.apache.ibatis.session.ResultHandler resultHandler)
执行手动设置的 count 查询,该查询支持的参数必须和被分页的方法相同
|
static Map<String,Object> |
getAdditionalParameter(org.apache.ibatis.mapping.BoundSql boundSql)
获取 BoundSql 属性值 additionalParameters
|
static org.apache.ibatis.mapping.MappedStatement |
getExistedMappedStatement(org.apache.ibatis.session.Configuration configuration,
String msId)
尝试获取已经存在的在 MS,提供对手写count和page的支持
|
static <E> List<E> |
pageQuery(Dialect dialect,
org.apache.ibatis.executor.Executor executor,
org.apache.ibatis.mapping.MappedStatement ms,
Object parameter,
org.apache.ibatis.session.RowBounds rowBounds,
org.apache.ibatis.session.ResultHandler resultHandler,
org.apache.ibatis.mapping.BoundSql boundSql,
org.apache.ibatis.cache.CacheKey cacheKey)
分页查询
|
public static Map<String,Object> getAdditionalParameter(org.apache.ibatis.mapping.BoundSql boundSql)
boundSql - boundSqlpublic static org.apache.ibatis.mapping.MappedStatement getExistedMappedStatement(org.apache.ibatis.session.Configuration configuration,
String msId)
configuration - 配置msId - 标识public static Long executeManualCount(org.apache.ibatis.executor.Executor executor, org.apache.ibatis.mapping.MappedStatement countMs, Object parameter, org.apache.ibatis.mapping.BoundSql boundSql, org.apache.ibatis.session.ResultHandler resultHandler) throws SQLException
executor - 执行者countMs - MappedStatementparameter - 参数boundSql - BoundSqlresultHandler - ResultHandlerSQLException - 异常public static Long executeAutoCount(Dialect dialect, org.apache.ibatis.executor.Executor executor, org.apache.ibatis.mapping.MappedStatement countMs, Object parameter, org.apache.ibatis.mapping.BoundSql boundSql, org.apache.ibatis.session.RowBounds rowBounds, org.apache.ibatis.session.ResultHandler resultHandler) throws SQLException
dialect - 方言executor - 执行者countMs - MappedStatementparameter - 参数boundSql - BoundSqlrowBounds - RowBoundsresultHandler - ResultHandlerSQLException - 异常public static <E> List<E> pageQuery(Dialect dialect, org.apache.ibatis.executor.Executor executor, org.apache.ibatis.mapping.MappedStatement ms, Object parameter, org.apache.ibatis.session.RowBounds rowBounds, org.apache.ibatis.session.ResultHandler resultHandler, org.apache.ibatis.mapping.BoundSql boundSql, org.apache.ibatis.cache.CacheKey cacheKey) throws SQLException
E - 对象dialect - 方言executor - 执行者ms - MappedStatementparameter - 参数rowBounds - RowBoundsresultHandler - ResultHandlerboundSql - BoundSqlcacheKey - CacheKeySQLException - 异常Copyright © 2019. All rights reserved.