@@ -10,18 +10,18 @@ MyBatis is very good at mapping result sets to objects - this is one of its prim
1010that you predefine the mappings for every possibility. This presents a challenge if you want very dynamic column lists
1111in a query. This library provides a generalized MyBatis mapper that can assist with that problem.
1212
13- The general mapper is ` org.mybatis.dynamic.sql.util.mybatis3.GeneralMapper ` . This mapper can be injected into a MyBatis configuration
13+ The general mapper is ` org.mybatis.dynamic.sql.util.mybatis3.CommonSelectMapper ` . This mapper can be injected into a MyBatis configuration
1414as is, or it can be extended by an existing mapper. If you are using MyBatis Spring support and auto scanning for mappers,
1515you can create an extension in your application's mapper package as follows:
1616
1717``` java
1818package foo.mapper ;
1919
2020import org.apache.ibatis.annotations.Mapper ;
21- import org.mybatis.dynamic.sql.util.mybatis3.GeneralMapper ;
21+ import org.mybatis.dynamic.sql.util.mybatis3.CommonSelectMapper ;
2222
2323@Mapper
24- public interface MyGeneralMapper extends GeneralMapper {
24+ public interface MyGeneralMapper extends CommonSelectMapper {
2525}
2626```
2727
@@ -45,11 +45,11 @@ import java.util.List;
4545import java.util.Map ;
4646import org.mybatis.dynamic.sql.render.RenderingStrategies ;
4747import org.mybatis.dynamic.sql.select.render.SelectStatementProvider ;
48- import org.mybatis.dynamic.sql.util.mybatis3.GeneralMapper ;
48+ import org.mybatis.dynamic.sql.util.mybatis3.CommonSelectMapper ;
4949
5050public class MyService {
5151 public List<Map<String ,Object > > generalSearch () {
52- GeneralMapper mapper = getGeneralMapper(); // not shown
52+ CommonSelectMapper mapper = getGeneralMapper(); // not shown
5353
5454 SelectStatementProvider selectStatement = select(id, description)
5555 .from(foo)
@@ -76,11 +76,11 @@ import static org.mybatis.dynamic.sql.SqlBuilder.*;
7676import java.util.List ;
7777import org.mybatis.dynamic.sql.render.RenderingStrategies ;
7878import org.mybatis.dynamic.sql.select.render.SelectStatementProvider ;
79- import org.mybatis.dynamic.sql.util.mybatis3.GeneralMapper ;
79+ import org.mybatis.dynamic.sql.util.mybatis3.CommonSelectMapper ;
8080
8181public class MyService {
8282 public List<TableCode > generalSearch () {
83- GeneralMapper mapper = getGeneralMapper(); // not shown
83+ CommonSelectMapper mapper = getGeneralMapper(); // not shown
8484
8585 SelectStatementProvider selectStatement = select(id, description)
8686 .from(foo)
@@ -108,11 +108,11 @@ import static org.mybatis.dynamic.sql.SqlBuilder.*;
108108
109109import org.mybatis.dynamic.sql.render.RenderingStrategies ;
110110import org.mybatis.dynamic.sql.select.render.SelectStatementProvider ;
111- import org.mybatis.dynamic.sql.util.mybatis3.GeneralMapper ;
111+ import org.mybatis.dynamic.sql.util.mybatis3.CommonSelectMapper ;
112112
113113public class MyService {
114114 public Long getCount () {
115- GeneralMapper mapper = getGeneralMapper(); // not shown
115+ CommonSelectMapper mapper = getGeneralMapper(); // not shown
116116
117117 SelectStatementProvider selectStatement = countFrom(foo)
118118 .where(description. isLike(" %bar%" ))
0 commit comments