From 8ab2ad5580212b91df848e4c127f2a682485fde3 Mon Sep 17 00:00:00 2001 From: zhouxiang <zhouxiang> Date: 星期一, 25 四月 2022 01:49:15 +0800 Subject: [PATCH] 修改common --- src/main/java/com/hx/common/service/CommonService.java | 35 +++++++++++++++++++++++++++-------- 1 files changed, 27 insertions(+), 8 deletions(-) diff --git a/src/main/java/com/hx/common/service/CommonService.java b/src/main/java/com/hx/common/service/CommonService.java index 94fbdd9..d2b0642 100644 --- a/src/main/java/com/hx/common/service/CommonService.java +++ b/src/main/java/com/hx/common/service/CommonService.java @@ -1,5 +1,4 @@ package com.hx.common.service; -import com.hx.mybatisTool.SqlParam; import com.hx.mybatisTool.SqlSentence; import java.io.Serializable; @@ -23,10 +22,18 @@ /**鏌ヨ鏉℃暟 * @param mapperClass mapper绫� - * @param sqlParam 鏌ヨ鍙傛暟绫� + * @param sqlSentence 鏌ヨ鍙傛暟绫� * @return 杩斿洖鏉℃暟 */ - <T extends Serializable> int selectCount(Class<?> mapperClass, SqlParam sqlParam); + <T extends Serializable> int selectCount(Class<?> mapperClass, SqlSentence sqlSentence); + + /**鏌ヨ鏉℃暟 + * @param mapperClass mapper绫� + * @param sqlSentence 鏌ヨ鍙傛暟绫� + * @return 杩斿洖鏉℃暟 + */ + <T extends Serializable> int selectCountSql(Class<?> mapperClass, SqlSentence sqlSentence); + /**鏌ヨ鍒楄〃锛岃繑鍥炲疄浣撶被鐨凩ist * @param mapperClass mapper绫� @@ -72,10 +79,10 @@ /**鏇存柊锛岃繑鍥炴洿鏂版暟閲� * @param mapperClass mapper绫� - * @param sqlParam 鏌ヨ鍙傛暟绫� + * @param sqlSentence 鏌ヨ鍙傛暟绫� * @return 杩斿洖鏉℃暟 */ - <T extends Serializable> int updateWhere(Class<?> mapperClass, SqlParam sqlParam); + <T extends Serializable> int updateWhere(Class<?> mapperClass, SqlSentence sqlSentence); /**鏇存柊锛岃繑鍥炴洿鏂版暟閲� * @param mapperClass mapper绫� @@ -86,10 +93,10 @@ /**鍒犻櫎锛岃繑鍥炲垹闄ゆ暟閲� * @param mapperClass mapper绫� - * @param sqlParam 鏌ヨ鍙傛暟绫� + * @param sqlSentence 鏌ヨ鍙傛暟绫� * @return 杩斿洖鏉℃暟 */ - <T extends Serializable> int deleteWhere(Class<?> mapperClass, SqlParam sqlParam); + <T extends Serializable> int deleteWhere(Class<?> mapperClass, SqlSentence sqlSentence); /**鍒犻櫎锛岃繑鍥炲垹闄ゆ暟閲� * @param mapperClass mapper绫� @@ -97,5 +104,17 @@ * @return 杩斿洖鏉℃暟 */ <T extends Serializable> int deleteById(Class<?> mapperClass, Object object); - + + /**鏇存柊sql璇彞锛堝叏璇彞锛� + * @param sqlSentence 鏌ヨ鍙傛暟绫� + * @return 杩斿洖鏉℃暟 + */ + <T extends Serializable> int updateSentence(SqlSentence sqlSentence); + + /**鏌ヨ鏉℃暟璇彞锛堝叏璇彞锛� + * @param sqlSentence 鏌ヨ鍙傛暟绫� + * @return 杩斿洖鏉℃暟 + */ + <T extends Serializable> int selectCountSql(SqlSentence sqlSentence); + } \ No newline at end of file -- Gitblit v1.8.0