MyBatis 3 | Introduction – mybatis
What is MyBatis?
MyBatis is a first class persistence framework with support for custom SQL, stored procedures and advanced mappings. MyBatis eliminates almost all of the JDBC code and manual setting of parameters and retrieval of results. MyBatis can use simple XML or Annotations for configuration and map primitives, Map interfaces and Java POJOs (Plain Old Java Objects) to database records.
If you are completely new to database access in Java, Java & Databases: An Overview of Libraries & APIs contains a good overview of the various parts, pieces and options and shows you where exactly MyBatis fits in.
在 Idea J 的开发环境,选择以下两项:
开发环境中配置,MyBatis 3 | Getting started – mybatis
这里有详细的说明文件。
<dependency>
<groupId>org.mybatis</groupId>
<artifactId>mybatis</artifactId>
<version>x.x.x</version>
</dependency>