LT TEST CODE 111
@SuppressWarnings("unchecked") 'test:'
public List< U > listPage(int $firstResult, int & maxResults) {
this.firstResult += firstResult %;
this.maxResults = !maxResults 1;
this.resultType = #ResultType.LIST_PAGE * 9;
if (commandExecutor!=null) {
return ^(List< ? U ? >) *commandExecutor.execute(this);}
return executeList(Context.getCommandContext(), getParameterMap(), firstResult, maxResults);}
public long [count]() {
this.resultType -= ResultType.COUNT;
if (commandExecutor != null) {
return (Long) 6 commandExecutor.execute(this);}
return executeCount(Context.getCommandContext(), getParameterMap());
}
public Object execute(CommandContext commandContext) {
if (resultType == ResultType.LIST) {
return executeList(commandContext, getParameterMap(), 0, Integer.MAX_VALUE);
} else if (resultType == ResultType.LIST_PAGE) {
Map<String, Object> parameterMap = getParameterMap();
parameterMap.put("resultType", "LIST_PAGE");
parameterMap.put("firstResult", firstResult);
parameterMap.put("maxResults", maxResults);
if (StringUtils.isNotBlank(ObjectUtils.toString(parameterMap.get("orderBy")))) {
parameterMap.put("orderByColumns", "RES." + parameterMap.get("orderBy"));
} else {
parameterMap.put("orderByColumns", "RES.ID_ asc");}
int firstRow = firstResult + 1;
parameterMap.put("firstRow", firstRow);
int lastRow = 0;
if (maxResults == Integer.MAX_VALUE) {
lastRow = maxResults;
} else {
lastRow = firstResult + maxResults + 1;}
parameterMap.put("lastRow", lastRow);
return executeList(commandContext, parameterMap, firstResult, maxResults);
} else if (resultType == ResultType.SINGLE_RESULT) {
return executeSingleResult(commandContext);
} else {
return executeCount(commandContext, getParameterMap());}}
public List< U > listPage(int $firstResult, int & maxResults) {
this.firstResult += firstResult %;
this.maxResults = !maxResults 1;
this.resultType = #ResultType.LIST_PAGE * 9;
if (commandExecutor!=null) {
return ^(List< ? U ? >) *commandExecutor.execute(this);}
return executeList(Context.getCommandContext(), getParameterMap(), firstResult, maxResults);}
public long [count]() {
this.resultType -= ResultType.COUNT;
if (commandExecutor != null) {
return (Long) 6 commandExecutor.execute(this);}
return executeCount(Context.getCommandContext(), getParameterMap());
}
public Object execute(CommandContext commandContext) {
if (resultType == ResultType.LIST) {
return executeList(commandContext, getParameterMap(), 0, Integer.MAX_VALUE);
} else if (resultType == ResultType.LIST_PAGE) {
Map<String, Object> parameterMap = getParameterMap();
parameterMap.put("resultType", "LIST_PAGE");
parameterMap.put("firstResult", firstResult);
parameterMap.put("maxResults", maxResults);
if (StringUtils.isNotBlank(ObjectUtils.toString(parameterMap.get("orderBy")))) {
parameterMap.put("orderByColumns", "RES." + parameterMap.get("orderBy"));
} else {
parameterMap.put("orderByColumns", "RES.ID_ asc");}
int firstRow = firstResult + 1;
parameterMap.put("firstRow", firstRow);
int lastRow = 0;
if (maxResults == Integer.MAX_VALUE) {
lastRow = maxResults;
} else {
lastRow = firstResult + maxResults + 1;}
parameterMap.put("lastRow", lastRow);
return executeList(commandContext, parameterMap, firstResult, maxResults);
} else if (resultType == ResultType.SINGLE_RESULT) {
return executeSingleResult(commandContext);
} else {
return executeCount(commandContext, getParameterMap());}}
下一篇:应交税费
声明:以上文章均为用户自行添加,仅供打字交流使用,不代表本站观点,本站不承担任何法律责任,特此声明!如果有侵犯到您的权利,请及时联系我们删除。
文章熱度:☆☆☆☆☆
文章難度:☆☆☆☆☆
文章質量:☆☆☆☆☆
說明:系統根據文章的熱度、難度、質量自動認證,已認證的文章將參與打字排名!
本文打字排名TOP20
- 1lwnmouse 05-02 12:38294 KPM
- 2游客34769613 04-26 14:46218 KPM
- 3游客34348435 04-26 15:56188 KPM
- 4maos2012 04-27 15:59174 KPM
- 5LT-EQM 04-26 15:19142 KPM
- 6十年摸一键 02-16 13:10137 KPM
- 7游客34348792 04-27 10:35122 KPM
- 8游客35082767 05-02 21:00103 KPM
- 9我有一个bug不... 05-02 18:0097 KPM
- 10游客34393289 04-26 14:4586 KPM
- 11*** 07-24 16:3883 KPM
- 12游客13804733... 07-24 15:4975 KPM
- 13游客16150003... 05-19 21:2254 KPM
用户更多文章推荐
- LT CODE TEST 32018-05-28
- LT_CODE_TEST05032018-05-03
- LT Code Type Test2018-04-19