在Maven中读取POM中的xml

时间:2015-11-30 12:00:37

标签: maven

我想使用POM阅读以下XML文件。我想根据POM中给出的输入运行POM。

<packging operation-mode="" server="" java-compiler-version="">
    <operation-layer name="framework">
        <operation-module name="framework" exclude-installation-mode="" exclude-server=""></operation-module>
        <operation-module name="admin" exclude-installation-mode="" exclude-server=""></operation-module>
        <operation-module name="tpe" exclude-installation-mode="" exclude-server=""></operation-module>
        <operation-module name="sample" exclude-installation-mode="" exclude-server=""></operation-module>
    </operation-layer>
    <operation-layer name="function">
        <operation-module name="function" exclude-installation-mode="" exclude-server=""></operation-module>
    </operation-layer>
    <operation-layer name="product">
        <operation-module name="product" exclude-installation-mode="" exclude-server=""></operation-module>
    </operation-layer>
    <operation-layer name="solution">
        <operation-module name="solution" exclude-installation-mode="" exclude-server=""></operation-module>
    </operation-layer>
</packging>

1 个答案:

答案 0 :(得分:0)

例如,您可以在pom中使用ANT + xmltask进行阶段验证。