mirror of
https://gitee.com/mybatis-flex/mybatis-flex.git
synced 2025-12-08 01:28:24 +08:00
style: 更新 Table 注释。
This commit is contained in:
parent
5f8ce6ab2f
commit
30a8de98b7
@ -1,4 +1,4 @@
|
||||
/**
|
||||
/*
|
||||
* Copyright (c) 2022-2023, Mybatis-Flex (fuhai999@gmail.com).
|
||||
* <p>
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
@ -20,47 +20,51 @@ import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
/**
|
||||
* 数据库表信息注解。
|
||||
*/
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@Target({ElementType.TYPE})
|
||||
public @interface Table {
|
||||
|
||||
/**
|
||||
* 显式指定表名称
|
||||
* 显式指定表名称。
|
||||
*/
|
||||
String value();
|
||||
|
||||
/**
|
||||
* 数据库的 schema(模式)
|
||||
* 数据库的 schema(模式)。
|
||||
*/
|
||||
String schema() default "";
|
||||
|
||||
/**
|
||||
* 默认为 驼峰属性 转换为 下划线字段
|
||||
* 默认为 驼峰属性 转换为 下划线字段。
|
||||
*/
|
||||
boolean camelToUnderline() default true;
|
||||
|
||||
/**
|
||||
* 默认使用哪个数据源,若系统找不到该指定的数据源时,默认使用第一个数据源
|
||||
* 默认使用哪个数据源,若系统找不到该指定的数据源时,默认使用第一个数据源。
|
||||
*/
|
||||
String dataSource() default "";
|
||||
|
||||
/**
|
||||
* 监听 entity 的 insert 行为
|
||||
* 监听 entity 的 insert 行为。
|
||||
*/
|
||||
Class<? extends InsertListener>[] onInsert() default {};
|
||||
|
||||
/**
|
||||
* 监听 entity 的 update 行为
|
||||
* 监听 entity 的 update 行为。
|
||||
*/
|
||||
Class<? extends UpdateListener>[] onUpdate() default {};
|
||||
|
||||
/**
|
||||
* 监听 entity 的查询数据的 set 行为,用户主动 set 不会触发
|
||||
* 监听 entity 的查询数据的 set 行为,用户主动 set 不会触发。
|
||||
*/
|
||||
Class<? extends SetListener>[] onSet() default {};
|
||||
|
||||
/**
|
||||
* 在某些场景下,我们需要手动编写 Mapper,可以通过这个注解来关闭 APT 的 Mapper 生成
|
||||
* 在某些场景下,我们需要手动编写 Mapper,可以通过这个注解来关闭 APT 的 Mapper 生成。
|
||||
*/
|
||||
boolean mapperGenerateEnable() default true;
|
||||
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user