!447 【轻量级 PR】:保证生成顺序,以解决生成顺序不确定产生的问题

Merge pull request !447 from cida/main
This commit is contained in:
Michael Yang 2024-04-16 10:55:47 +00:00 committed by Gitee
commit 3ff68d027d
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -19,7 +19,7 @@ import com.mybatisflex.codegen.constant.GenTypeConst;
import com.mybatisflex.codegen.generator.impl.*;
import java.util.Collection;
import java.util.HashMap;
import java.util.LinkedHashMap;
import java.util.Map;
/**
@ -29,7 +29,7 @@ import java.util.Map;
*/
public class GeneratorFactory {
private static final Map<String, IGenerator> generators = new HashMap<>();
private static final Map<String, IGenerator> generators = new LinkedHashMap<>();
static {
registerGenerator(GenTypeConst.ENTITY, new EntityGenerator());