mirror of
https://gitee.com/mybatis-flex/mybatis-flex.git
synced 2025-12-07 00:58:24 +08:00
细化文档中与 solon 相关的内容
This commit is contained in:
parent
3eaa27cc0b
commit
3c3b767991
@ -1,6 +1,6 @@
|
|||||||
# MyBatisFlexCustomizer
|
# MyBatisFlexCustomizer
|
||||||
|
|
||||||
`MyBatisFlexCustomizer` 是 MyBatis-Flex 为了方便 `SpringBoot` 用户对 MyBatis-Flex 进行初始化而产生的接口。
|
`MyBatisFlexCustomizer` 是 MyBatis-Flex 为了方便 `SpringBoot` 或 `Solon` 用户对 MyBatis-Flex 进行初始化而产生的接口。
|
||||||
|
|
||||||
通过在 `@Configuration` 去实现 `MyBatisFlexCustomizer` 接口,我们可以对 MyBatis-Flex 进行一系列的初始化配置。这些配置可能包含如下的内容:
|
通过在 `@Configuration` 去实现 `MyBatisFlexCustomizer` 接口,我们可以对 MyBatis-Flex 进行一系列的初始化配置。这些配置可能包含如下的内容:
|
||||||
|
|
||||||
|
|||||||
@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
- 熟悉 Java 环境配置及其开发
|
- 熟悉 Java 环境配置及其开发
|
||||||
- 熟悉 关系型 数据库,比如 MySQL
|
- 熟悉 关系型 数据库,比如 MySQL
|
||||||
- 熟悉 Spring Boot 及相关框架
|
- 熟悉 Spring Boot 或 Solon 等相关框架
|
||||||
- 熟悉 Java 构建工具,比如 Maven
|
- 熟悉 Java 构建工具,比如 Maven
|
||||||
|
|
||||||
> 当前章节涉及到的源码已经全部上传到:https://gitee.com/Suomm/mybatis-flex-test ,在开始之前,
|
> 当前章节涉及到的源码已经全部上传到:https://gitee.com/Suomm/mybatis-flex-test ,在开始之前,
|
||||||
|
|||||||
@ -58,7 +58,28 @@ dependencies {
|
|||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
4、配置 annotationProcessor
|
|
||||||
|
4、用到了 Solon 的场景
|
||||||
|
|
||||||
|
**【Kotlin】**
|
||||||
|
|
||||||
|
```kotlin
|
||||||
|
dependencies {
|
||||||
|
implementation("com.mybatis-flex:mybatis-flex-solon-plugin:1.10.4")
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
**【Groovy】**
|
||||||
|
|
||||||
|
```groovy
|
||||||
|
dependencies {
|
||||||
|
implementation 'com.mybatis-flex:mybatis-flex-solon-plugin:1.10.4'
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
5、配置 annotationProcessor
|
||||||
|
|
||||||
由 `mybatis-flex-processor` 提供APT服务。
|
由 `mybatis-flex-processor` 提供APT服务。
|
||||||
|
|
||||||
|
|||||||
@ -70,7 +70,23 @@
|
|||||||
</dependency>
|
</dependency>
|
||||||
```
|
```
|
||||||
|
|
||||||
5、配置 annotationProcessor
|
5、用到了 Solon 的场景
|
||||||
|
|
||||||
|
```xml 3
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.mybatis-flex</groupId>
|
||||||
|
<artifactId>mybatis-flex-solon-plugin</artifactId>
|
||||||
|
<version>1.10.4</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.mybatis-flex</groupId>
|
||||||
|
<artifactId>mybatis-flex-processor</artifactId>
|
||||||
|
<version>1.10.4</version>
|
||||||
|
<scope>provided</scope>
|
||||||
|
</dependency>
|
||||||
|
```
|
||||||
|
|
||||||
|
6、配置 annotationProcessor
|
||||||
|
|
||||||
`mybatis-flex-processor`提供APT服务,可以配置到annotationProcessorPaths,配置后,无需在依赖中声明`mybatis-flex-processor`依赖。
|
`mybatis-flex-processor`提供APT服务,可以配置到annotationProcessorPaths,配置后,无需在依赖中声明`mybatis-flex-processor`依赖。
|
||||||
|
|
||||||
@ -95,7 +111,7 @@
|
|||||||
</plugin>
|
</plugin>
|
||||||
```
|
```
|
||||||
|
|
||||||
6、配置依赖管理
|
7、配置依赖管理
|
||||||
|
|
||||||
MyBatis-Flex 提供了 `mybatis-flex-dependencies` 模块进行依赖管理,只需要在 `<dependencyManagement>` 标签下进行配置就可以了。
|
MyBatis-Flex 提供了 `mybatis-flex-dependencies` 模块进行依赖管理,只需要在 `<dependencyManagement>` 标签下进行配置就可以了。
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user