• 大小: 225KB
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2021-05-27
  • 语言: 其他
  • 标签: Spring  mybati  pageHe  

资源简介

SpringBoot2.1.4+Mybatis+PageHelper整合。 Mybatis 通过*.yml来配置,通过注解方式实现,无XML。 PageHelper的整合写了两种方式,一种是通过Aop拦截Mapper,代码量少;一种是服务接口的实现,容易理解。

资源截图

代码片段和文件信息

package com.daiql.mybatis;

import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

@MapperScan(basePackages = “com.daiql.mybatis.mapper“)
@SpringBootApplication
public class SpringBootMybatisApplication {

    public static void main(String[] args) {
        SpringApplication.run(SpringBootMybatisApplication.class args);
    }

}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2019-04-17 09:22  springboot-mybatis\
     文件        9160  2019-04-16 22:41  springboot-mybatis\springboot-mybatis.iml
     目录           0  2019-04-16 08:55  springboot-mybatis\target\
     目录           0  2019-04-16 22:48  springboot-mybatis\target\test-classes\
     目录           0  2019-04-16 22:48  springboot-mybatis\target\test-classes\com\
     目录           0  2019-04-16 22:48  springboot-mybatis\target\test-classes\com\daiql\
     目录           0  2019-04-16 22:48  springboot-mybatis\target\test-classes\com\daiql\mybatis\
     文件         666  2019-04-16 22:48  springboot-mybatis\target\test-classes\com\daiql\mybatis\AutoGenerateEntityApplicationTests.class
     目录           0  2019-04-16 08:55  springboot-mybatis\target\generated-sources\
     目录           0  2019-04-16 08:55  springboot-mybatis\target\generated-sources\annotations\
     目录           0  2019-04-17 09:16  springboot-mybatis\target\classes\
     文件         680  2019-04-17 09:16  springboot-mybatis\target\classes\application.yml
     目录           0  2019-04-16 22:48  springboot-mybatis\target\classes\com\
     目录           0  2019-04-16 22:48  springboot-mybatis\target\classes\com\daiql\
     目录           0  2019-04-17 09:16  springboot-mybatis\target\classes\com\daiql\mybatis\
     目录           0  2019-04-16 22:48  springboot-mybatis\target\classes\com\daiql\mybatis\util\
     文件        2981  2019-04-16 22:48  springboot-mybatis\target\classes\com\daiql\mybatis\util\JsonResult.class
     目录           0  2019-04-16 22:48  springboot-mybatis\target\classes\com\daiql\mybatis\auto\
     文件        7760  2019-04-16 22:48  springboot-mybatis\target\classes\com\daiql\mybatis\auto\GenerateMybatisxml.class
     文件        7945  2019-04-16 22:48  springboot-mybatis\target\classes\com\daiql\mybatis\auto\GenerateEntity.class
     文件        8372  2019-04-16 22:48  springboot-mybatis\target\classes\com\daiql\mybatis\auto\GenerateServiceImpl.class
     文件        5910  2019-04-16 22:48  springboot-mybatis\target\classes\com\daiql\mybatis\auto\GenerateMybatisRepository.class
     文件        9486  2019-04-16 22:48  springboot-mybatis\target\classes\com\daiql\mybatis\auto\JdbcUtil.class
     文件        6863  2019-04-16 22:48  springboot-mybatis\target\classes\com\daiql\mybatis\auto\GenerateService.class
     目录           0  2019-04-16 22:48  springboot-mybatis\target\classes\com\daiql\mybatis\bean\
     文件        1479  2019-04-16 22:48  springboot-mybatis\target\classes\com\daiql\mybatis\bean\RegisterList.class
     目录           0  2019-04-17 08:39  springboot-mybatis\target\classes\com\daiql\mybatis\mapper\
     文件         438  2019-04-16 22:48  springboot-mybatis\target\classes\com\daiql\mybatis\mapper\CommonMapper.class
     文件        1838  2019-04-17 08:39  springboot-mybatis\target\classes\com\daiql\mybatis\mapper\RegisterListMapper.class
     目录           0  2019-04-17 08:45  springboot-mybatis\target\classes\com\daiql\mybatis\annotation\
     文件         467  2019-04-17 08:45  springboot-mybatis\target\classes\com\daiql\mybatis\annotation\ExtPageHelper.class
............此处省略340个文件信息

评论

共有 条评论