• mybatis代码自动生成插件


    一、导包

    1. <plugin>
    2. <groupId>org.mybatis.generatorgroupId>
    3. <artifactId>mybatis-generator-maven-pluginartifactId>
    4. <version>1.3.6version>
    5. <configuration>
    6. <configurationFile>GeneratorMapper.xmlconfigurationFile>
    7. <verbose>trueverbose>
    8. <overwrite>trueoverwrite>
    9. configuration>
    10. plugin>

    二、GeneratorMapper.xml 

    1. "1.0" encoding="UTF-8"?>
    2. generatorConfiguration
    3. PUBLIC "-//mybatis.org//DTD MyBatis Generator Configuration 1.0//EN"
    4. "http://mybatis.org/dtd/mybatis-generator-config_1_0.dtd">
    5. <generatorConfiguration>
    6. <classPathEntry location="E:\mysql-connector-java-5.1.38.jar"/>
    7. <context id="tables" targetRuntime="MyBatis3">
    8. <commentGenerator>
    9. <property name="suppressAllComments" value="true" />
    10. commentGenerator>
    11. <jdbcConnection driverClass="com.mysql.jdbc.Driver"
    12. connectionURL="jdbc:mysql://192.168.88.130:3306/p2p"
    13. userId="root"
    14. password="root">
    15. jdbcConnection>
    16. <javaModelGenerator targetPackage="com.abc.p2p.model"
    17. targetProject="E:\course\035-p2p-SpringBoot\000-IDEA-projects\001-P2P-IDEA-SpringBoot\003-p2p-exterface\src\main\java">
    18. <property name="enableSubPackages" value="false" />
    19. <property name="trimStrings" value="false" />
    20. javaModelGenerator>
    21. <sqlMapGenerator targetPackage="com.abc.p2p.mapper" targetProject="src/main/java">
    22. <property name="enableSubPackages" value="false" />
    23. sqlMapGenerator>
    24. <javaClientGenerator type="XMLMAPPER" targetPackage="com.abc.p2p.mapper" targetProject="src/main/java">
    25. <property name="enableSubPackages" value="false" />
    26. javaClientGenerator>
    27. <table tableName="b_loan_info" domainObjectName="LoanInfo"
    28. enableCountByExample="false"
    29. enableUpdateByExample="false"
    30. enableDeleteByExample="false"
    31. enableSelectByExample="false"
    32. selectByExampleQueryId="false"/>
    33. <table tableName="b_bid_info" domainObjectName="BidInfo"
    34. enableCountByExample="false"
    35. enableUpdateByExample="false"
    36. enableDeleteByExample="false"
    37. enableSelectByExample="false"
    38. selectByExampleQueryId="false"/>
    39. <table tableName="b_income_record" domainObjectName="IncomeRecord"
    40. enableCountByExample="false"
    41. enableUpdateByExample="false"
    42. enableDeleteByExample="false"
    43. enableSelectByExample="false"
    44. selectByExampleQueryId="false"/>
    45. <table tableName="b_recharge_record" domainObjectName="RechargeRecord"
    46. enableCountByExample="false"
    47. enableUpdateByExample="false"
    48. enableDeleteByExample="false"
    49. enableSelectByExample="false"
    50. selectByExampleQueryId="false"/>
    51. <table tableName="u_user" domainObjectName="User"
    52. enableCountByExample="false"
    53. enableUpdateByExample="false"
    54. enableDeleteByExample="false"
    55. enableSelectByExample="false"
    56. selectByExampleQueryId="false"/>
    57. <table tableName="u_finance_account" domainObjectName="FinanceAccount"
    58. enableCountByExample="false"
    59. enableUpdateByExample="false"
    60. enableDeleteByExample="false"
    61. enableSelectByExample="false"
    62. selectByExampleQueryId="false"/>
    63. context>
    64. generatorConfiguration>

  • 相关阅读:
    SpringCloud——服务注册——Eureka
    css-pseudo-class锚伪类
    centos7安装erlang23.3.4.11及rabbitmq3.9.16版本
    创建共享内存后,进程结束,共享内存是否会消失?
    Java类和对象
    组件化通信
    【Markdown小技巧】 整理小图标和表情符号
    Matlab如何导入Excel数据并进行FFT变换
    Java 计算两个字符串的相似度 CosineSimilarity实现
    数据分析利器---jupyter
  • 原文地址:https://blog.csdn.net/m0_58961367/article/details/134517590