Class ExampleProvider


  • public class ExampleProvider
    extends Object
    基础的增删改查操作
    Author:
    liuzh
    • 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
    • Constructor Detail

      • ExampleProvider

        public ExampleProvider()
    • 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