Skip to content

gouyiba/mybatis-max

Repository files navigation

MyBatis-Max

Maven Central GitHub release License Gitpod Ready-to-Code Issues

What is MyBatis-Max?

Mybatis Max is to simplify and solve the tedious development work of the data layer based on Mybatis, greatly improve the development efficiency, and enable developers to focus on the implementation of the Service business, and do not need to spend too much energy on the development of the data layer.

Get Step

  • Add MyBatis-Max dependency

    • Maven:
      <dependency>
          <groupId>cloud.gouyiba</groupId>
          <artifactId>mybatis-max-boot-starter</artifactId>
          <version>1.0.5-RELEASE</version>
      </dependency>
    • Gradle:
      compile group: 'cloud.gouyiba', name: 'mybatis-max-boot-starter', version: '1.0.5-RELEASE'
  • Modify mapper file(extends BaseMapper interface)

    public interface AccountMapper extends BaseMapper<Account> {
    
    }
  • Use it

    • Example Code:
      @Resource
      private AccountMapper accountMapper;
      
      public void getMybatisMaxFunction() {
          accountMapper.selectById();
          
          accountMapper.selectOne();
          
          accountMapper.insert();
          
          accountMapper.update();
          
          accountMapper.updateById();
          
          accountMapper.delete();
          
          // accountMapper.method()......
      }
    • All the injection methods provided in BaseMapper are accessible through an AccountMapper agent instance

Dependency

Please see this [China Maven Download Page] for more repository infos.

Welcome

We invite interested people to join our gouyiba development team communicate together and let us know by sending an issue.

License

MyBatis-Max is released under the Apache 2.0 license.