@@ -58,7 +58,7 @@ One capability is that very expressive dynamic queries can be generated. Here's
58
58
try {
59
59
AnimalDataMapper mapper = sqlSession. getMapper(AnimalDataMapper . class);
60
60
61
- SelectSupport selectSupport = select(id, animalName, bodyWeight, brainWeight)
61
+ SelectProvider selectProvider = select(id, animalName, bodyWeight, brainWeight)
62
62
.from(animalData)
63
63
.where(id, isIn(1 , 5 , 7 ))
64
64
.or(id, isIn(2 , 6 , 8 ), and(animalName, isLike(" %bat" )))
@@ -68,7 +68,7 @@ One capability is that very expressive dynamic queries can be generated. Here's
68
68
.build()
69
69
.render(RenderingStrategy . MYBATIS3 );
70
70
71
- List<AnimalData > animals = mapper. selectMany(selectSupport );
71
+ List<AnimalData > animals = mapper. selectMany(selectProvider );
72
72
assertThat(animals. size()). isEqualTo(4 );
73
73
} finally {
74
74
sqlSession. close();
@@ -158,8 +158,8 @@ import org.apache.ibatis.annotations.Delete;
158
158
import org.apache.ibatis.annotations.Result ;
159
159
import org.apache.ibatis.annotations.Results ;
160
160
import org.apache.ibatis.annotations.Select ;
161
- import org.mybatis.dynamic.sql.delete.render.DeleteSupport ;
162
- import org.mybatis.dynamic.sql.select.render.SelectSupport ;
161
+ import org.mybatis.dynamic.sql.delete.render.DeleteProvider ;
162
+ import org.mybatis.dynamic.sql.select.render.SelectProvider ;
163
163
164
164
public class SimpleTableAnnotatedMapper {
165
165
@@ -174,12 +174,12 @@ public class SimpleTableAnnotatedMapper {
174
174
@Result (column = " employed" , property = " employed" , jdbcType = JdbcType . VARCHAR , typeHandler = YesNoTypeHandler . class),
175
175
@Result (column = " occupation" , property = " occupation" , jdbcType = JdbcType . VARCHAR )
176
176
})
177
- List<SimpleTableRecord > selectMany (SelectSupport selectSupport );
177
+ List<SimpleTableRecord > selectMany (SelectProvider selectProvider );
178
178
179
179
@Delete ({
180
180
" ${fullDeleteStatement}"
181
181
})
182
- int delete (DeleteSupport deleteSupport );
182
+ int delete (DeleteProvider deleteProvider );
183
183
}
184
184
```
185
185
An XML mapper might look like this:
@@ -216,7 +216,7 @@ All conditions can be accessed through expressive static methods in the ```org.m
216
216
For example, a very simple select statement can be defined like this:
217
217
218
218
``` java
219
- SelectSupport selectSupport = select(count())
219
+ SelectProvider selectProvider = select(count())
220
220
.from(simpleTable)
221
221
.where(id, isEqualTo(3 ))
222
222
.build()
@@ -226,7 +226,7 @@ For example, a very simple select statement can be defined like this:
226
226
Or this (also note that you can give a table an alias):
227
227
228
228
``` java
229
- SelectSupport selectSupport = select(count())
229
+ SelectProvider selectProvider = select(count())
230
230
.from(simpleTable, " a" )
231
231
.where(id, isNull())
232
232
.build()
@@ -235,7 +235,7 @@ Or this (also note that you can give a table an alias):
235
235
A delete statement looks like this:
236
236
237
237
``` java
238
- DeleteSupport deleteSupport = deleteFrom(simpleTable)
238
+ DeleteProvider deleteProvider = deleteFrom(simpleTable)
239
239
.where(occupation, isNull())
240
240
.build()
241
241
.render(RenderingStrategy . MYBATIS3 );
@@ -244,7 +244,7 @@ A delete statement looks like this:
244
244
The "between" condition is also expressive:
245
245
246
246
``` java
247
- SelectSupport selectSupport = select(count())
247
+ SelectProvider selectProvider = select(count())
248
248
.from(simpleTable)
249
249
.where(id, isBetween(1 ). and(4 ))
250
250
.build()
@@ -254,7 +254,7 @@ The "between" condition is also expressive:
254
254
More complex expressions can be built using the "and" and "or" conditions as follows:
255
255
256
256
``` java
257
- SelectSupport selectSupport = select(count())
257
+ SelectProvider selectProvider = select(count())
258
258
.from(simpleTable)
259
259
.where(id, isGreaterThan(2 ))
260
260
.or(occupation, isNull(), and(id, isLessThan(6 )))
@@ -283,14 +283,14 @@ an example from ```examples.simple.SimpleTableXmlMapperTest```:
283
283
try {
284
284
SimpleTableXmlMapper mapper = session. getMapper(SimpleTableXmlMapper . class);
285
285
286
- SelectSupport selectSupport = select(id. as(" A_ID" ), firstName, lastName, birthDate, employed, occupation)
286
+ SelectProvider selectProvider = select(id. as(" A_ID" ), firstName, lastName, birthDate, employed, occupation)
287
287
.from(simpleTable)
288
288
.where(id, isEqualTo(1 ))
289
289
.or(occupation, isNull())
290
290
.build()
291
291
.render(RenderingStrategy . MYBATIS3 );
292
292
293
- List<SimpleTableRecord > rows = mapper. selectMany(selectSupport );
293
+ List<SimpleTableRecord > rows = mapper. selectMany(selectProvider );
294
294
295
295
assertThat(rows. size()). isEqualTo(3 );
296
296
} finally {
0 commit comments