CodeGenerator.java 604 B

123456789101112131415161718192021222324252627
  1. package com.zd.airbottle;
  2. import com.zd.common.core.mybatisplus.MybatisPlusGenerator;
  3. import java.net.URL;
  4. /**
  5. * <p>代码生成</p>
  6. *
  7. * @author: linft
  8. * @date: 2020/11/4
  9. * @since:
  10. */
  11. public class CodeGenerator {
  12. public static void main(String[] args) {
  13. //要生成的表名
  14. String[] tables = {"db_bottle_type"};
  15. //表前缀,若不想生成在实体里,添加前缀,如:sys_user, 前缀为:sys_
  16. String tablePrefix = "";
  17. URL url = CodeGenerator.class.getResource("");
  18. MybatisPlusGenerator.generator(tables,tablePrefix, url);
  19. }
  20. }