Samples on Well-known Schemas
Schema for | Schema file | Applied to | Namespace | Location |
---|---|---|---|---|
J2EE web application 2.4 deployment descriptor | web-app_2_4.xsd | web.xml | http://java.sun.com/xml/ns/j2ee | http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd |
J2EE web application 2.5 deployment descriptor | web-app_2_4.xsd | web.xml | http://java.sun.com/xml/ns/javaee | http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd |
EJB 2.1 deployment descriptor | ejb-jar_2_1.xsd | ejb-jar.xml | http://java.sun.com/xml/ns/j2ee | http://java.sun.com/xml/ns/j2ee/ejb-jar_2_1.xsd |
EJB 3.0 deployment descriptor | ejb-jar_3_0.xsd | ejb-jar.xml | java.sun.com/xml/ns/javaee | http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd |
Spring 2.5 IoC configuration | spring-beans-2.5.xsd | ... | http://www.springframework.org/schema/beans | http://www.springframework.org/schema/beans/spring-beans-2.5.xsd |
Spring 3.0 IoC configuration | spring-beans-3.0.xsd | ... | http://www.springframework.org/schema/beans | http://www.springframework.org/schema/beans/spring-beans-3.0.xsd |
Spring 2.5 AOP configuration | spring-aop-2.5.xsd | ... | http://www.springframework.org/schema/aop | http://www.springframework.org/schema/beans/spring-beans-3.0.xsd |
Spring 3.0 AOP configuration | spring-aop-3.0.xsd | ... | http://www.springframework.org/schema/aop | http://www.springframework.org/schema/aop/spring-aop-3.0.xsd |
Related Element and Attribute
Example : Spring 3.0 IoC configuration
- Schema :
spring-beans-2.5.xsd
<xsd:schema targetNamespace="http://www.springframework.org/schema/beans"> <xsd:import namespace="http://www.w3.org/XML/1998/namespace"/> ... </xsd:schema>
- XML
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:aop="http://www.springframework.org/schema/aop" xsi:schemaLocation=" http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.5.xsd" default-lazy-init="false"> ... </beans>
Example : EJB 3.0 deployment descriptor
- Schema :
ejb-jar_3_0.xsd
<xsd:schema xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="http://java.sun.com/xml/ns/javaee" xmlns:javaee="http://java.sun.com/xml/ns/javaee" xmlns:xsd="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified" version="3.0"> ... </xsd:schema>
- XML
<ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd" version="3.0"> ... </ejb-jar>
0 comments:
Post a Comment