pomxml解读

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<!--    解读modelVersion
        1.描述这个pom文件/pom模型遵循的哪个版本
        2.对应的maven2和maven3而言,这里的modelVersion只能是4.0.0-->

    <modelVersion>4.0.0</modelVersion>

<!--    解读:下面的是指定该项目的坐标-->
<!--    是创建项目的时候程序员所指定的,就是我们在创建maven的时候设定的-->
<!--    groupId组织名-->
<!--    artifactId项目名-->
<!--    version版本-->


    <groupId>com.hspedu</groupId>
    <artifactId>Java-project-maven</artifactId>
    <version>1.0-SNAPSHOT</version>

<!--    这里就是引入项目所需要的jar包,类似传统项目的import jar的作用-->
<!--    在dependencies标签页内,可以指定多个需要依赖的jar/导入一个jar-->
<!--    引用的jar包需要一个完整的jar包坐标,从maven中仓库去查询-->

    <dependencies>
        <dependency>
            <groupId>org.junit.jupiter</groupId>
            <artifactId>junit-jupiter</artifactId>
            <version>RELEASE</version>
<!--            该jar包的作用的范围-->
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.12</version>
            <scope>test</scope>
        </dependency>
    </dependencies>


</project>
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<!--    解读modelVersion
        1.描述这个pom文件/pom模型遵循的哪个版本
        2.对应的maven2和maven3而言,这里的modelVersion只能是4.0.0-->

    <modelVersion>4.0.0</modelVersion>

<!--    解读:下面的是指定该项目的坐标-->
<!--    是创建项目的时候程序员所指定的,就是我们在创建maven的时候设定的-->
<!--    groupId组织名-->
<!--    artifactId项目名-->
<!--    version版本-->


    <groupId>com.hspedu</groupId>
    <artifactId>Java-project-maven</artifactId>
    <version>1.0-SNAPSHOT</version>

<!--    这里就是引入项目所需要的jar包,类似传统项目的import jar的作用-->
<!--    在dependencies标签页内,可以指定多个需要依赖的jar/导入一个jar-->
<!--    引用的jar包需要一个完整的jar包坐标,从maven中仓库去查询-->

    <dependencies>
        <dependency>
            <groupId>org.junit.jupiter</groupId>
            <artifactId>junit-jupiter</artifactId>
            <version>RELEASE</version>
<!--            该jar包的作用的范围-->
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.12</version>
            <scope>test</scope>
        </dependency>
    </dependencies>


</project>

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值