mirror of
https://gitee.com/mybatis-flex/mybatis-flex.git
synced 2025-12-07 17:18:24 +08:00
!340 codegen配置类实现Serializable接口
Merge pull request !340 from zoufang162/main
This commit is contained in:
commit
5bcb63ab1f
@ -15,6 +15,8 @@
|
||||
*/
|
||||
package com.mybatisflex.codegen.config;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 生成 Controller 的配置。
|
||||
*
|
||||
@ -22,8 +24,9 @@ package com.mybatisflex.codegen.config;
|
||||
* @since 2023-05-15
|
||||
*/
|
||||
@SuppressWarnings("unused")
|
||||
public class ControllerConfig {
|
||||
public class ControllerConfig implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 8391630904705910611L;
|
||||
/**
|
||||
* Controller 类的前缀。
|
||||
*/
|
||||
@ -132,4 +135,4 @@ public class ControllerConfig {
|
||||
return this;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -24,8 +24,9 @@ import java.io.Serializable;
|
||||
* @since 2023-05-15
|
||||
*/
|
||||
@SuppressWarnings("unused")
|
||||
public class EntityConfig {
|
||||
public class EntityConfig implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = -6790274333595436008L;
|
||||
/**
|
||||
* Entity 类的前缀。
|
||||
*/
|
||||
|
||||
@ -17,6 +17,7 @@ package com.mybatisflex.codegen.config;
|
||||
|
||||
import com.mybatisflex.codegen.template.ITemplate;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
@ -32,7 +33,8 @@ import java.util.function.UnaryOperator;
|
||||
* @since 2023-05-15
|
||||
*/
|
||||
@SuppressWarnings("unused")
|
||||
public class GlobalConfig {
|
||||
public class GlobalConfig implements Serializable {
|
||||
private static final long serialVersionUID = 5033600623041298000L;
|
||||
|
||||
// === 必须配置 ===
|
||||
|
||||
|
||||
@ -18,6 +18,7 @@ package com.mybatisflex.codegen.config;
|
||||
|
||||
import com.mybatisflex.core.util.StringUtil;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDate;
|
||||
import java.time.format.DateTimeFormatter;
|
||||
import java.util.function.Function;
|
||||
@ -31,8 +32,9 @@ import java.util.function.UnaryOperator;
|
||||
* @since 2023-05-17
|
||||
*/
|
||||
@SuppressWarnings("unused")
|
||||
public class JavadocConfig {
|
||||
public class JavadocConfig implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = -4280345489968397327L;
|
||||
/**
|
||||
* 作者。
|
||||
*/
|
||||
|
||||
@ -17,6 +17,8 @@ package com.mybatisflex.codegen.config;
|
||||
|
||||
import com.mybatisflex.core.BaseMapper;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 生成 Mapper 的配置。
|
||||
*
|
||||
@ -24,8 +26,9 @@ import com.mybatisflex.core.BaseMapper;
|
||||
* @since 2023-05-15
|
||||
*/
|
||||
@SuppressWarnings("unused")
|
||||
public class MapperConfig {
|
||||
public class MapperConfig implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1937442008907641534L;
|
||||
/**
|
||||
* Mapper 类的前缀。
|
||||
*/
|
||||
@ -134,4 +137,4 @@ public class MapperConfig {
|
||||
return this;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -16,6 +16,8 @@
|
||||
|
||||
package com.mybatisflex.codegen.config;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 生成 MapperXml 的配置。
|
||||
*
|
||||
@ -23,8 +25,9 @@ package com.mybatisflex.codegen.config;
|
||||
* @since 2023-05-17
|
||||
*/
|
||||
@SuppressWarnings("unused")
|
||||
public class MapperXmlConfig {
|
||||
public class MapperXmlConfig implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 7836897652282634412L;
|
||||
/**
|
||||
* MapperXml 文件的前缀。
|
||||
*/
|
||||
@ -85,4 +88,4 @@ public class MapperXmlConfig {
|
||||
return this;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -18,6 +18,8 @@ package com.mybatisflex.codegen.config;
|
||||
|
||||
import com.mybatisflex.core.util.StringUtil;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 生成软件包的配置。
|
||||
*
|
||||
@ -25,8 +27,9 @@ import com.mybatisflex.core.util.StringUtil;
|
||||
* @since 2023-05-15
|
||||
*/
|
||||
@SuppressWarnings("unused")
|
||||
public class PackageConfig {
|
||||
public class PackageConfig implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = -8257632247633439537L;
|
||||
/**
|
||||
* 代码生成目录。
|
||||
*/
|
||||
|
||||
@ -18,6 +18,8 @@ package com.mybatisflex.codegen.config;
|
||||
|
||||
import com.mybatisflex.core.service.IService;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 生成 Service 的配置。
|
||||
*
|
||||
@ -25,8 +27,9 @@ import com.mybatisflex.core.service.IService;
|
||||
* @since 2023-05-15
|
||||
*/
|
||||
@SuppressWarnings("unused")
|
||||
public class ServiceConfig {
|
||||
public class ServiceConfig implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = -2152473328300910220L;
|
||||
/**
|
||||
* Service 类的前缀。
|
||||
*/
|
||||
@ -115,4 +118,4 @@ public class ServiceConfig {
|
||||
return this;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -15,6 +15,8 @@
|
||||
*/
|
||||
package com.mybatisflex.codegen.config;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 生成 ServiceImpl 的配置。
|
||||
*
|
||||
@ -22,8 +24,9 @@ package com.mybatisflex.codegen.config;
|
||||
* @since 2023-05-15
|
||||
*/
|
||||
@SuppressWarnings("unused")
|
||||
public class ServiceImplConfig {
|
||||
public class ServiceImplConfig implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 17115432462168151L;
|
||||
/**
|
||||
* ServiceImpl 类的前缀。
|
||||
*/
|
||||
|
||||
@ -18,6 +18,7 @@ package com.mybatisflex.codegen.config;
|
||||
|
||||
import com.mybatisflex.core.util.StringUtil;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.HashMap;
|
||||
import java.util.HashSet;
|
||||
import java.util.Map;
|
||||
@ -30,8 +31,9 @@ import java.util.Set;
|
||||
* @since 2023-05-14
|
||||
*/
|
||||
@SuppressWarnings("unused")
|
||||
public class StrategyConfig {
|
||||
public class StrategyConfig implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 504853587703061034L;
|
||||
/**
|
||||
* 数据库表前缀,多个前缀用英文逗号(,) 隔开。
|
||||
*/
|
||||
|
||||
@ -19,6 +19,7 @@ import com.mybatisflex.annotation.InsertListener;
|
||||
import com.mybatisflex.annotation.SetListener;
|
||||
import com.mybatisflex.annotation.UpdateListener;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
@ -26,9 +27,10 @@ import java.util.Map;
|
||||
* 表的单独设置。
|
||||
*/
|
||||
@SuppressWarnings({"unused", "UnusedReturnValue"})
|
||||
public class TableConfig {
|
||||
public class TableConfig implements Serializable {
|
||||
|
||||
public static final String ALL_TABLES = "*";
|
||||
private static final long serialVersionUID = -2568968178699265858L;
|
||||
|
||||
/**
|
||||
* 数据库的 schema(模式)。
|
||||
|
||||
@ -17,6 +17,8 @@ package com.mybatisflex.codegen.config;
|
||||
|
||||
import com.mybatisflex.core.util.StringUtil;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 生成 TableDef 的配置。
|
||||
*
|
||||
@ -24,8 +26,9 @@ import com.mybatisflex.core.util.StringUtil;
|
||||
* @since 2023-05-15
|
||||
*/
|
||||
@SuppressWarnings("unused")
|
||||
public class TableDefConfig {
|
||||
public class TableDefConfig implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 8137903163796008036L;
|
||||
/**
|
||||
* TableDef 类的前缀。
|
||||
*/
|
||||
|
||||
@ -20,6 +20,8 @@ import com.mybatisflex.codegen.generator.GeneratorFactory;
|
||||
import com.mybatisflex.codegen.template.ITemplate;
|
||||
import com.mybatisflex.codegen.template.impl.EnjoyTemplate;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 模板配置。
|
||||
*
|
||||
@ -27,8 +29,9 @@ import com.mybatisflex.codegen.template.impl.EnjoyTemplate;
|
||||
* @since 2023-05-17
|
||||
*/
|
||||
@SuppressWarnings("unused")
|
||||
public class TemplateConfig {
|
||||
public class TemplateConfig implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 6700855804948021101L;
|
||||
/**
|
||||
* 生成代码的模板引擎。
|
||||
*/
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user