EAR文件--application.xml 解析

 

 1  <? xml version="1.0" encoding="UTF-8" ?>
 2  < application  id ="Application_ID"  version ="1.4"  xmlns ="http://java.sun.com/xml/ns/j2ee"  xmlns:xsi ="http://www.w3.org/2001/XMLSchema-instance"  xsi:schemaLocation ="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/application_1_4.xsd" >
 3       < display-name > LearnEAR </ display-name >
 4       < module  id ="WebModule_1281616343151" >
 5           < web >
 6               < web-uri > Learn.war </ web-uri >
 7               < context-root > .Learn </ context-root >
 8           </ web >
 9       </ module >
10  </ application >

 

 

  这是我的application.xml文件,"This is the global application configuration file",下面是在网上看到的一些信息:

  "Notice that Web modules allow you to specify one other value—the<context-root>. Recall from the previous chapter that the context root is your web site’s URL. If you deploy a simple WAR file, the name of the WAR will be used as the URL. When your WAR file is deployed inside an EAR, this element allows you to override the physical name of the WAR and use whatever URL you’d like."

  继续实践。。

<module>:

  There are as many module elements as there are separate J2EE modules, and each of them contains EJB, Java, and Web elements.

<web> :

  The Web element shows the web-uri and the context-root of a Web application module.

  The <web-uri> element indicates the URI of a Web application file. (A URI is an Internet protocol element consisting of a name or address you can use to refer to a resource. A URL is just an URI that additionally provides a way of accessing and obtaining a representation of the resource.) The URI is relative to the top level of the application package.

  一个URI就是一个由因特网协议中的一些元素组成的 名字或者地址, 我们可以通过这些名字或者地址来refer(关联?提到?指定 ?)到资源。

  一个URL就是在URL的基础上增加了一种获取资源的representation的方法

 

  给俩个链接:

Building and Deploying an EAR  :http://www.devarticles.com/c/a/Web-Authoring/Building-and-Deploying-an-EAR/1/

Configuring J2EE Application XML Files :http://www.devshed.com/c/a/Oracle/Configuring-J2EE-Application-XML-Files/1/

 

你可能感兴趣的:(application)