Package io.mybatis.mapper.example
Class ExampleProvider
- java.lang.Object
-
- io.mybatis.mapper.example.ExampleProvider
-
public class ExampleProvider extends Object
基础的增删改查操作- Author:
- liuzh
-
-
Field Summary
Fields Modifier and Type Field Description static StringEXAMPLE_WHERE_CLAUSEexample 结构的动态 SQL 查询条件,用于接口参数只有一个 Example 对象时static StringUPDATE_BY_EXAMPLE_WHERE_CLAUSEexample 结构的动态 SQL 查询条件,用于多个参数时,Example 对应 @Param("example")
-
Constructor Summary
Constructors Constructor Description ExampleProvider()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static StringcountByExample(org.apache.ibatis.builder.annotation.ProviderContext providerContext)根据 Example 条件查询总数static StringdeleteByExample(org.apache.ibatis.builder.annotation.ProviderContext providerContext)根据 Example 删除static StringselectByExample(org.apache.ibatis.builder.annotation.ProviderContext providerContext)根据 Example 条件批量查询,根据 Example 条件查询总数,查询结果的数量由方法定义static StringupdateByExample(org.apache.ibatis.builder.annotation.ProviderContext providerContext)根据 Example 条件批量更新实体信息static StringupdateByExampleSelective(org.apache.ibatis.builder.annotation.ProviderContext providerContext)根据 Example 条件批量更新实体不为空的字段static StringupdateByExampleSetValues(org.apache.ibatis.builder.annotation.ProviderContext providerContext)根据 Example 条件批量更新实体信息
-
-
-
Field Detail
-
EXAMPLE_WHERE_CLAUSE
public static final String EXAMPLE_WHERE_CLAUSE
example 结构的动态 SQL 查询条件,用于接口参数只有一个 Example 对象时- See Also:
- Constant Field Values
-
UPDATE_BY_EXAMPLE_WHERE_CLAUSE
public static final String UPDATE_BY_EXAMPLE_WHERE_CLAUSE
example 结构的动态 SQL 查询条件,用于多个参数时,Example 对应 @Param("example")- See Also:
- Constant Field Values
-
-
Method Detail
-
deleteByExample
public static String deleteByExample(org.apache.ibatis.builder.annotation.ProviderContext providerContext)
根据 Example 删除- Parameters:
providerContext- 上下文- Returns:
- cacheKey
-
updateByExample
public static String updateByExample(org.apache.ibatis.builder.annotation.ProviderContext providerContext)
根据 Example 条件批量更新实体信息- Parameters:
providerContext- 上下文- Returns:
- cacheKey
-
updateByExampleSetValues
public static String updateByExampleSetValues(org.apache.ibatis.builder.annotation.ProviderContext providerContext)
根据 Example 条件批量更新实体信息- Parameters:
providerContext- 上下文- Returns:
- cacheKey
-
updateByExampleSelective
public static String updateByExampleSelective(org.apache.ibatis.builder.annotation.ProviderContext providerContext)
根据 Example 条件批量更新实体不为空的字段- Parameters:
providerContext- 上下文- Returns:
- cacheKey
-
selectByExample
public static String selectByExample(org.apache.ibatis.builder.annotation.ProviderContext providerContext)
根据 Example 条件批量查询,根据 Example 条件查询总数,查询结果的数量由方法定义- Parameters:
providerContext- 上下文- Returns:
- cacheKey
-
countByExample
public static String countByExample(org.apache.ibatis.builder.annotation.ProviderContext providerContext)
根据 Example 条件查询总数- Parameters:
providerContext- 上下文- Returns:
- cacheKey
-
-