public abstract class BaseTemplateGenerator extends Object implements IGlobalConfig, ITableConfig
| 限定符和类型 | 字段和说明 |
|---|---|
protected GlobalConfig |
globalConfig
全局配置
|
protected List<TableConfigSet> |
tableConfigs |
protected AbstractTemplateEngine |
templateEngine |
| 构造器和说明 |
|---|
BaseTemplateGenerator() |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
execute()
执行代码生成
|
protected void |
generateSummary(List<Map<String,Object>> allContext)
生成汇总文件
|
protected abstract List<BaseTemplate> |
getAllTemplates()
返回定义的模板列表
|
ITableConfig |
globalConfig(Consumer<IGlobalConfigSet> consumer)
设置生成的全局配置
|
ITableConfig |
tables(Consumer<ITableConfigSet> consumer)
设置要生成的表
|
ITableConfig |
tables(ITableConfigSet... tableConfigs) |
protected AbstractTemplateEngine templateEngine
protected List<TableConfigSet> tableConfigs
protected GlobalConfig globalConfig
public ITableConfig globalConfig(Consumer<IGlobalConfigSet> consumer)
IGlobalConfigglobalConfig 在接口中 IGlobalConfigpublic ITableConfig tables(Consumer<ITableConfigSet> consumer)
ITableConfigtables 在接口中 ITableConfigpublic ITableConfig tables(ITableConfigSet... tableConfigs)
protected abstract List<BaseTemplate> getAllTemplates()
public void execute()
execute 在接口中 ITableConfigCopyright © 2020. All rights reserved.