[jboss-cvs] JBossAS SVN: r70821 - projects/microcontainer/trunk/kernel/src/resources/main/schema.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Thu Mar 13 10:00:33 EDT 2008


Author: adrian at jboss.org
Date: 2008-03-13 10:00:33 -0400 (Thu, 13 Mar 2008)
New Revision: 70821

Modified:
   projects/microcontainer/trunk/kernel/src/resources/main/schema/bean-deployer_2_0.xsd
Log:
[JBMICROCONT-263] - Revert xsd:redefine until JBossXB stackoverflow is fixed

Modified: projects/microcontainer/trunk/kernel/src/resources/main/schema/bean-deployer_2_0.xsd
===================================================================
--- projects/microcontainer/trunk/kernel/src/resources/main/schema/bean-deployer_2_0.xsd	2008-03-13 13:54:12 UTC (rev 70820)
+++ projects/microcontainer/trunk/kernel/src/resources/main/schema/bean-deployer_2_0.xsd	2008-03-13 14:00:33 UTC (rev 70821)
@@ -9,192 +9,6 @@
    attributeFormDefault="unqualified"
    version="1.0">
 
-   <xsd:redefine schemaLocation="jboss-beans-common_2_0.xsd">
-      <xsd:complexType name="beanType">
-         <xsd:complexContent>
-            <xsd:extension base="beanType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="classloaderType">
-         <xsd:complexContent>
-            <xsd:extension base="classloaderType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="abstractBeanfactoryType">
-         <xsd:complexContent>
-            <xsd:extension base="abstractBeanfactoryType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="beanfactoryType">
-         <xsd:complexContent>
-            <xsd:extension base="beanfactoryType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="lazyType">
-         <xsd:complexContent>
-            <xsd:extension base="lazyType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="constructorType">
-         <xsd:complexContent>
-            <xsd:extension base="constructorType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="lifecycleType">
-         <xsd:complexContent>
-            <xsd:extension base="lifecycleType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="installType">
-         <xsd:complexContent>
-            <xsd:extension base="installType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="uninstallCallbackType">
-         <xsd:complexContent>
-            <xsd:extension base="uninstallCallbackType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="installCallbackType">
-         <xsd:complexContent>
-            <xsd:extension base="installCallbackType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="dependencyType">
-         <xsd:complexContent>
-            <xsd:extension base="dependencyType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="injectionType">
-         <xsd:complexContent>
-            <xsd:extension base="injectionType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="valueFactoryType">
-         <xsd:complexContent>
-            <xsd:extension base="valueFactoryType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="factoryType">
-         <xsd:complexContent>
-            <xsd:extension base="factoryType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="aliasType">
-         <xsd:complexContent>
-            <xsd:extension base="aliasType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="namedAliasType">
-         <xsd:complexContent>
-            <xsd:extension base="namedAliasType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="parameterType">
-         <xsd:complexContent>
-            <xsd:extension base="parameterType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="propertyType">
-         <xsd:complexContent>
-            <xsd:extension base="propertyType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="annotationType">
-         <xsd:complexContent>
-            <xsd:extension base="annotationType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="interfaceType">
-         <xsd:complexContent>
-            <xsd:extension base="interfaceType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:simpleType name="classNameType"/>
-      <xsd:group name="valueGroup"/>
-      <xsd:complexType name="plainValueType">
-         <xsd:complexContent>
-            <xsd:extension base="plainValueType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="valueType">
-         <xsd:complexContent>
-            <xsd:extension base="valueType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="classLoaderValueType">
-         <xsd:complexContent>
-            <xsd:extension base="classLoaderValueType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="annotatedValueType">
-         <xsd:complexContent>
-            <xsd:extension base="annotatedValueType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="namedValueType">
-         <xsd:complexContent>
-            <xsd:extension base="namedValueType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="baseCollectionType">
-         <xsd:complexContent>
-            <xsd:extension base="baseCollectionType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="collectionType">
-         <xsd:complexContent>
-            <xsd:extension base="collectionType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="listType">
-         <xsd:complexContent>
-            <xsd:extension base="listType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="setType">
-         <xsd:complexContent>
-            <xsd:extension base="setType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="arrayType">
-         <xsd:complexContent>
-            <xsd:extension base="arrayType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="mapType">
-         <xsd:complexContent>
-            <xsd:extension base="mapType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="entryType">
-         <xsd:complexContent>
-            <xsd:extension base="entryType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="dependsType">
-         <xsd:complexContent>
-            <xsd:extension base="dependsType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="demandType">
-         <xsd:complexContent>
-            <xsd:extension base="demandType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:complexType name="supplyType">
-         <xsd:complexContent>
-            <xsd:extension base="supplyType"/>
-         </xsd:complexContent>
-      </xsd:complexType>
-      <xsd:simpleType name="controllerStateType"/>
-      <xsd:simpleType name="controllerModeType"/>
-      <xsd:simpleType name="autowireTypeType"/>
-      <xsd:simpleType name="optionType"/>
-      <xsd:simpleType name="contextType"/>
-   </xsd:redefine>
-
-
    <xsd:annotation>
       <xsd:documentation>
          <![CDATA[
@@ -255,6 +69,1065 @@
       <xsd:attribute name="mode" type="controllerModeType" use="optional"/>
    </xsd:complexType>
 
+   <xsd:complexType name="beanType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           The bean is an instance of a pojo.
+           
+           e.g.
+           <bean name="MyName" class="com.acme.POJO">
+              <classloader .../>
+              <constructor .../>
+              <property .../>
+              <property .../>
+              <depends .../>
+           </bean>
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:sequence>
+         <xsd:element name="annotation" type="annotationType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="alias" type="aliasType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="classloader" type="classloaderType" minOccurs="0"/>
+         <xsd:element name="constructor" type="constructorType" minOccurs="0"/>
+         <xsd:element name="property" type="propertyType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="create" type="lifecycleType" minOccurs="0"/>
+         <xsd:element name="start" type="lifecycleType" minOccurs="0"/>
+         <xsd:element name="stop" type="lifecycleType" minOccurs="0"/>
+         <xsd:element name="destroy" type="lifecycleType" minOccurs="0"/>
+         <xsd:element name="depends" type="dependsType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="demand" type="demandType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="supply" type="supplyType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="install" type="installType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="uninstall" type="installType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="incallback" type="installCallbackType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="uncallback" type="uninstallCallbackType" minOccurs="0" maxOccurs="unbounded"/>
+      </xsd:sequence>
+      <xsd:attribute name="name" type="xsd:string" use="optional"/>
+      <xsd:attribute name="class" type="xsd:token" use="optional"/>
+      <xsd:attribute name="mode" type="controllerModeType" use="optional"/>
+      <xsd:attribute name="parent" type="xsd:string" use="optional"/>
+      <xsd:attribute name="abstract" type="xsd:boolean" use="optional"/>
+      <xsd:attribute name="autowire-type" type="autowireTypeType" use="optional"/>
+      <xsd:attribute name="autowire-candidate" type="xsd:boolean" use="optional"/>
+   </xsd:complexType>
+
+   <xsd:complexType name="classloaderType" mixed="true">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           The classloader is to load the bean
+           
+           e.g. 
+           <bean ...>
+              <classloader><inject bean="Classloader"/></classloader>
+           </bean>
+           
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexContent>
+         <xsd:extension base="classLoaderValueType"/>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <xsd:complexType name="abstractBeanfactoryType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           Base type for beanfatoryType.
+           ]]>
+           
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:sequence>
+         <xsd:element name="alias" type="aliasType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="classloader" type="classloaderType" minOccurs="0"/>
+         <xsd:element name="constructor" type="constructorType" minOccurs="0"/>
+         <xsd:element name="property" type="propertyType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="create" type="lifecycleType" minOccurs="0"/>
+         <xsd:element name="start" type="lifecycleType" minOccurs="0"/>
+         <xsd:element name="depends" type="dependsType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="demand" type="demandType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="supply" type="supplyType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="install" type="installType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="uninstall" type="installType" minOccurs="0" maxOccurs="unbounded"/>
+<!--
+         <xsd:element name="incallback" type="intallCallbackType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="uncallback" type="uninstallCallbackType" minOccurs="0" maxOccurs="unbounded"/>
+-->
+      </xsd:sequence>
+      <xsd:attribute name="name" type="xsd:string" use="optional"/>
+   </xsd:complexType>
+
+   <xsd:complexType name="beanfactoryType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           The beanfactory is a org.jboss.beans.metadata.plugins.factory.GenericBeanFactory deployment.
+           This gives you a factory such you can invoke createBean() multiple times with the guarantee
+           that the injected objects are "installed".
+
+           e.g.
+           <bean name="User" class="com.acme.User">
+              <property name="factory"><inject bean="Factory"/></property>
+           </bean>
+           
+           <beanfactory name="Factory" class="com.acme.SomeBean">
+              <property name="someProperty"><inject bean="SomeOtherBean"/></property>
+           </beanFactory>
+           
+           package com.acme.User;
+           public class User {
+              // factory has been configured at this point
+              public void setFactory(GenericBeanFactory factory) { 
+                 SomeBean bean1 = factory.createBean();
+                 System.out.println(bean1.getSomeProperty()); // "SomeOtherBean"
+                 SomeBean bean2 = factory.createBean();
+                 System.out.println(bean2.getSomeProperty()); // "SomeOtherBean"
+              }
+           }
+           ]]>
+           
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexContent>
+         <xsd:extension base="abstractBeanfactoryType">
+            <xsd:attribute name="class" type="xsd:token" use="required"/>
+         </xsd:extension>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <xsd:complexType name="lazyType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           Wrap the existing bean into lazy proxy.
+           Expose the full class or just interfaces.
+           Name is optional, and if no name is provided bean+'Proxy' will be used.
+
+           e.g.
+           <lazy name="UserProxy" bean="User">
+              <interface>org.acme.domain.IUser</interface>
+           </lazy>
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:sequence>
+         <xsd:element name="interface" type="interfaceType" minOccurs="0" maxOccurs="unbounded"/>
+      </xsd:sequence>
+      <xsd:attribute name="name" type="xsd:string" use="optional"/>
+      <xsd:attribute name="bean" type="xsd:string" use="required"/>
+      <xsd:attribute name="exposeClass" type="xsd:boolean" default="false" use="optional"/>
+   </xsd:complexType>
+
+   <xsd:complexType name="constructorType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           The constructor for this bean(factory) instance.
+           
+           e.g. simple constructor - new POJO(new String("String value"));
+           <bean name="MyBean" class="com.acme.POJO">
+              <constructor>
+                 <parameter>String value</parameter>
+              </constructor>
+           </bean>
+           
+           e.g. static factory - com.acme.Factory.newInstance(new String("String value"));
+           <bean name="MyBean" class="com.acme.POJO">
+              <constructor factoryClass="com.acme.Factory" factoryMethod="newInstance">
+                 <parameter>String value</parameter>
+              </constructor>
+           </bean>
+
+           e.g. instance factory - "SomeOtherBean".newInstance(new String("String value"));
+           <bean name="MyBean" class="com.acme.POJO">
+              <constructor factoryMethod="newInstance">
+                 <factory bean="SomeOtherBean"/>
+                 <parameter>String value</parameter>
+              </constructor>
+           </bean>
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:sequence>
+         <xsd:element name="annotation" type="annotationType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:choice minOccurs="0">
+            <xsd:sequence>        
+               <xsd:element name="factory" type="factoryType" minOccurs="0"/>
+               <xsd:element name="parameter" type="parameterType" minOccurs="0" maxOccurs="unbounded"/>
+            </xsd:sequence>
+            <xsd:element name="bean" type="beanType"/>
+            <xsd:element name="lazy" type="lazyType"/>
+            <xsd:element name="value" type="plainValueType"/>
+            <xsd:element name="collection" type="collectionType"/>
+            <xsd:element name="list" type="listType"/>
+            <xsd:element name="set" type="setType"/>
+            <xsd:element name="array" type="arrayType"/>
+            <xsd:element name="map" type="mapType"/>
+            <xsd:element name="inject" type="injectionType"/>
+            <xsd:element name="value-factory" type="valueFactoryType"/>
+            <xsd:any namespace="##other" processContents="strict">
+               <xsd:annotation>
+                  <xsd:documentation>An extension value</xsd:documentation>
+               </xsd:annotation>
+            </xsd:any>
+         </xsd:choice>
+      </xsd:sequence>
+      <xsd:attribute name="factoryClass" type="classNameType" use="optional"/>
+      <xsd:attribute name="factoryMethod" type="xsd:token" use="optional"/>
+   </xsd:complexType>
+
+   <xsd:complexType name="lifecycleType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           The lifecycle lets you override the method parameters passed to the
+           create, start, stop, destroy lifecycle callbacks.
+           
+           e.g.
+           <bean>
+              <create method="initialize">
+                 <parameter>String value</parameter>
+              </create>
+           </bean>
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:sequence>
+         <xsd:element name="annotation" type="annotationType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="parameter" type="parameterType" minOccurs="0" maxOccurs="unbounded"/>
+      </xsd:sequence>
+      <xsd:attribute name="method" type="xsd:token" use="optional"/>
+      <xsd:attribute name="ignored" type="xsd:boolean" use="optional" default="false"/>
+   </xsd:complexType>
+
+   <xsd:complexType name="installType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           The install type you write your installation methods state operations.
+           The install operation is invoked after the start lifecycle.
+           The uninstall operation is invoked before the stop lifecycle.
+           
+           e.g.
+           <bean>
+              <install bean="Repository" method="add">
+                 <parameter><this/></parameter>
+              </install>
+              <uninstall bean="Repository" method="remove">
+                 <parameter><this/></parameter>
+              </uninstall>
+           </bean>
+           
+           If you don't include a bean attribute, the method is invoked on your bean
+           
+           e.g.
+           <bean>
+              <install method="install"/>
+              <uninstall bean="method="uninstall"/>
+           </bean>
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:sequence>
+         <xsd:element name="annotation" type="annotationType" minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:element name="parameter" type="parameterType" minOccurs="0" maxOccurs="unbounded"/>
+      </xsd:sequence>
+      <xsd:attribute name="bean" type="xsd:string" use="optional"/>
+      <xsd:attribute name="method" type="xsd:token" use="required"/>
+      <xsd:attribute name="state" type="controllerStateType" use="optional"/>
+      <xsd:attribute name="whenRequired" type="controllerStateType" use="optional"/>
+   </xsd:complexType>
+
+   <xsd:complexType name="uninstallCallbackType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           Callback item description.
+           Define you methods for callback invocation.
+
+           e.g.
+           <bean>
+              <uncallback method="addSomething" />
+              <uncallback property="items" cardinality="2..n" />
+              <uncallback property="info" signature="org.jboss.test.Info"/>
+           </bean>
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:sequence>
+         <xsd:element name="annotation" type="annotationType" minOccurs="0" maxOccurs="unbounded"/>
+      </xsd:sequence>
+      <xsd:attribute name="method" type="xsd:token" use="optional"/>
+      <xsd:attribute name="property" type="xsd:token" use="optional"/>
+      <xsd:attribute name="cardinality" type="xsd:token" use="optional"/>
+      <xsd:attribute name="whenRequired" type="controllerStateType" use="optional"/>
+      <xsd:attribute name="state" type="controllerStateType" use="optional"/>
+      <xsd:attribute name="signature" type="xsd:token" use="optional"/>
+   </xsd:complexType>
+
+   <xsd:complexType name="installCallbackType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           Callback item description.
+           Define you methods for callback invocation.
+
+           e.g.
+           <bean>
+              <incallback method="addSomething" />
+              <incallback property="items" cardinality="2..n" />
+              <incallback property="info" signature="org.jboss.test.Info"/>
+           </bean>
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:sequence>
+         <xsd:element name="annotation" type="annotationType" minOccurs="0" maxOccurs="unbounded"/>
+      </xsd:sequence>
+      <xsd:attribute name="method" type="xsd:token" use="optional"/>
+      <xsd:attribute name="property" type="xsd:token" use="optional"/>
+      <xsd:attribute name="cardinality" type="xsd:token" use="optional"/>
+      <xsd:attribute name="whenRequired" type="controllerStateType" use="optional"/>
+      <xsd:attribute name="state" type="controllerStateType" use="optional"/>
+      <xsd:attribute name="signature" type="xsd:token" use="optional"/>
+   </xsd:complexType>
+
+   <xsd:complexType name="dependencyType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           A dependency represents an injection into the bean.
+           They can be used anywhere a string value can appear.
+           
+           e.g. Bean instance - "InjectedIntoMe".setSomeProperty("BeanInjected");
+           <bean name="InjectedIntoMe" ...>
+              <property name="someProperty"><inject bean="BeanInjected"/>
+           </bean>
+           <bean name="BeanInjected" .../>
+           
+           e.g. Bean property - "InjectedIntoMe".setSomeProperty("BeanInjected".getOtherProperty());
+           <bean name="InjectedIntoMe" ...>
+              <property name="someProperty"><inject bean="BeanInjected" property="otherProperty"/>
+           </bean>
+           <bean name="BeanInjected" .../>
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:attribute name="bean" type="xsd:string" use="required"/>
+      <xsd:attribute name="property" type="xsd:string" use="optional"/>
+      <xsd:attribute name="state" type="controllerStateType" use="optional"/>
+      <xsd:attribute name="whenRequired" type="controllerStateType" use="optional"/>
+   </xsd:complexType>
+
+   <xsd:complexType name="injectionType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           A dependency represents an injection into the bean.
+           They can be used anywhere a string value can appear.
+
+           e.g. Bean instance - "InjectedIntoMe".setSomeProperty("BeanInjected");
+           <bean name="InjectedIntoMe" ...>
+              <property name="someProperty"><inject bean="BeanInjected"/>
+           </bean>
+           <bean name="BeanInjected" .../>
+
+           e.g. Bean property - "InjectedIntoMe".setSomeProperty("BeanInjected".getOtherProperty());
+           <bean name="InjectedIntoMe" ...>
+              <property name="someProperty"><inject bean="BeanInjected" property="otherProperty"/>
+           </bean>
+           <bean name="BeanInjected" .../>
+
+           e.g. Contextual injection - finding exactly one instance which matches property's class type
+           <bean name="InjectedIntoMe" ...>
+              <property name="transactionManager"><inject/></property>
+           </bean>
+
+           e.g. Contextual injection - finding exactly one instance which matches property's name
+           <bean name="InjectedIntoMe" ...>
+              <property name="transactionManager"><inject type="ByName"/></property>
+           </bean>
+
+           e.g. Contextual injection - set optional injection; execute callback if currently no matching context exists 
+           <bean name="InjectedIntoMe" ...>
+              <property name="transactionManager"><inject option="Callback"/></property>
+           </bean>
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:attribute name="bean" type="xsd:string" use="optional"/>
+      <xsd:attribute name="property" type="xsd:string" use="optional"/>
+      <xsd:attribute name="state" type="controllerStateType" use="optional"/>
+      <xsd:attribute name="whenRequired" type="controllerStateType" use="optional"/>
+      <xsd:attribute name="type" type="autowireTypeType" use="optional" default="ByClass"/>
+      <xsd:attribute name="option" type="optionType" use="optional" default="Strict"/>
+      <xsd:attribute name="fromContext" type="contextType" use="optional"/>
+   </xsd:complexType>
+
+   <xsd:complexType name="valueFactoryType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           A dependency represents an value injection into the bean.
+           They can be used anywhere a string value can appear.
+
+           e.g. Bean instance - "InjectedIntoMe".setSomeProperty("ValueFactory".getValue("foo.bar.prop", "mydefault"));
+           <bean name="InjectedIntoMe" ...>
+              <property name="someProperty">
+                  <value-factory bean="BeanInjected" method="getValue">
+                     <parameter>foo.bar.prop</parameter>
+                     <parameter>mydefault</parameter>
+                  </value-factory>
+              </property>
+           </bean>
+           <bean name="BeanInjected" .../>
+
+           e.g. Bean instance - "InjectedIntoMe".setSomeProperty("ValueFactory".getValue("foo.bar.prop"));
+           <bean name="InjectedIntoMe" ...>
+              <property name="someProperty">
+                  <value-factory bean="BeanInjected" method="getValue" parameter="foo.bar.prop" default="mydefault" />
+              </property>
+           </bean>
+           <bean name="BeanInjected" .../>
+
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:sequence>
+         <xsd:element name="parameter" type="parameterType" minOccurs="0" maxOccurs="unbounded"/>
+      </xsd:sequence>
+      <xsd:attribute name="bean" type="xsd:string"/>
+      <xsd:attribute name="method" type="xsd:string"/>
+      <xsd:attribute name="state" type="controllerStateType" use="optional"/>
+      <xsd:attribute name="whenRequired" type="controllerStateType" use="optional"/>
+      <xsd:attribute name="parameter" type="xsd:string" use="optional"/>
+      <xsd:attribute name="default" type="xsd:string" use="optional"/>
+   </xsd:complexType>
+
+   <xsd:complexType name="factoryType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           A factory represents another bean used to construct an object.
+           
+           e.g. Bean instance - "InjectedIntoMe".setSomeProperty("BeanInjected");
+           <bean name="ConstructMe" ...>
+              <constructor factoryMethod="someMethod">
+                 <factory bean="Factory"/>
+              </constructor>
+           </bean>
+           <bean name="Factory" .../>
+           
+           You can also inject a property of the bean bean
+           e.g. 
+           <bean name="ConstructMe" ...>
+              <constructor factoryMethod="someMethod">
+                 <factory bean="Builder" property="getFactory"/>
+              </constructor>
+           </bean>
+           
+           Or you can construct a factory in place using a different schema/namsapce
+           e.g. 
+           <bean name="ConstructMe" ...>
+              <constructor factoryMethod="someMethod">
+                 <factory>
+                    <javabean xmlns="someOtherNamespace" class="com.acme.FactoryClass"/>
+                 </factory>
+              </constructor>
+           </bean>
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:choice minOccurs="0">
+         <xsd:any namespace="##other" processContents="strict"/>
+      </xsd:choice>
+      <xsd:attribute name="bean" type="xsd:string" use="optional"/>
+      <xsd:attribute name="property" type="xsd:string" use="optional"/>
+      <xsd:attribute name="state" type="controllerStateType" use="optional"/>
+      <xsd:attribute name="whenRequired" type="controllerStateType" use="optional"/>
+   </xsd:complexType>
+
+   <xsd:complexType name="aliasType" mixed="true">
+      <xsd:annotation>
+         <xsd:documentation>
+            <![CDATA[
+            Bean's aliases.
+
+            e.g.
+            <bean name="MyName" class="com.acme.POJO">
+               <alias>YourName</alias>
+               <alias><javabean xmlns="urn:jboss:javabean:2.0" class="whatevever"/></alias>
+            </bean>
+            ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:choice minOccurs="0">
+         <xsd:any namespace="##other" processContents="strict"/>
+      </xsd:choice>
+   </xsd:complexType>
+
+   <xsd:complexType name="namedAliasType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           An alias that has a name attribute.
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexContent>
+         <xsd:extension base="aliasType">
+            <xsd:attribute name="name" type="xsd:string" use="required"/>
+         </xsd:extension>
+      </xsd:complexContent>
+   </xsd:complexType>
+   
+   <xsd:complexType name="parameterType" mixed="true">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           A parameter is used to define the constructor, factory
+           and lifecycle method usage.
+
+           e.g. Using number of parameters when this is unique enough
+           <bean ...>
+              <constructor>
+                 <parameter>1st Parameter</parameter>
+                 <parameter>2nd Parameter</parameter>
+              </constructor>
+           </bean>
+
+           e.g. Explicitly stating the parameter type to resolve overloading
+           <bean ...>
+              <constructor>
+                 <parameter>1st Parameter</parameter>
+                 <parameter class="java.lang.String">2nd Parameter</parameter>
+              </constructor>
+           </bean>
+
+           e.g. To override the injected type use <value/>
+           <bean ...>
+              <constructor>
+                 <parameter>1st Parameter</parameter>
+                 <!-- Parameter is java.lang.Object, but we inject a String -->
+                 <parameter class="java.lang.Object">
+                    <value class="java.lang.String">2nd Parameter</value>
+                 </parameter>
+              </constructor>
+           </bean>
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexContent>
+         <xsd:extension base="annotatedValueType"/>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <xsd:complexType name="propertyType" mixed="true">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           A property defines values passed to the setters.
+           
+           e.g. Using the type from the setter argument
+           <bean ...>
+              <property name="someProperty">Some value</property>
+           </bean>
+           
+           e.g. Overridding the injected type
+           <bean ...>
+              <property name="someProperty" class="java.lang.String">Some value</property>
+           </bean>
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexContent>
+         <xsd:extension base="namedValueType">
+            <xsd:attribute name="preinstantiate" type="xsd:boolean" use="optional" default="true"/>
+         </xsd:extension>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <xsd:complexType name="annotationType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           The annotation type represents a Java5 annotation on the particular join point.
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:simpleContent>
+         <xsd:extension base="xsd:string">
+            <xsd:attribute name="replace" type="xsd:boolean"/>
+         </xsd:extension>
+      </xsd:simpleContent>
+   </xsd:complexType>
+
+   <xsd:complexType name="interfaceType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           The interface type represents an interface class.
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:simpleContent>
+         <xsd:extension base="xsd:string" />
+      </xsd:simpleContent>
+   </xsd:complexType>
+
+   <xsd:simpleType name="classNameType">
+      <xsd:annotation>
+         <xsd:documentation> The elements that use this type designate the name
+            of a Java class or interface. The name is in the form of a "binary
+            name", as defined in the JLS and as used in Class.forName().
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:restriction base="xsd:string">
+         <xsd:whiteSpace value="collapse"/>
+      </xsd:restriction>
+   </xsd:simpleType>
+
+   <xsd:group name="valueGroup">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           The value group represents the comment elements of the other configurations
+           <parameter/>, <property/> or collection components
+           e.g.
+
+           <property name="someProperty">
+              <list><value class="java.lang.String">Hello</value></list>
+           </property>
+           
+           e.g. This also defines the null value
+           <property name="someProperty"><null/></property>
+           as opposed to the empty string
+           <property name="someProperty"></property>
+           or the string "null"
+           <property name="someProperty">null</property>
+
+           The this operation lets you pass yourself as a parameter.
+           e.g.
+           <install bean="SomeOtherBean> method="install">
+              <parameter><this/></parameter>
+           </install>
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:choice>
+         <!--<xsd:element name="bean" type="beanType"/>-->
+         <!--<xsd:element name="lazy" type="lazyType"/>-->
+         <xsd:element name="value" type="plainValueType"/>
+         <xsd:element name="inject" type="injectionType"/>
+         <xsd:element name="value-factory" type="valueFactoryType"/>
+         <xsd:element name="collection" type="collectionType"/>
+         <xsd:element name="list" type="listType"/>
+         <xsd:element name="set" type="setType"/>
+         <xsd:element name="array" type="arrayType"/>
+         <xsd:element name="map" type="mapType"/>
+         <xsd:element name="null">
+            <xsd:complexType/>
+         </xsd:element>
+         <xsd:element name="this">
+            <xsd:complexType/>
+         </xsd:element>
+         <xsd:any namespace="##other" processContents="strict">
+            <xsd:annotation>
+               <xsd:documentation>An extension value</xsd:documentation>
+            </xsd:annotation>
+         </xsd:any>
+      </xsd:choice>
+   </xsd:group>
+
+   <xsd:complexType name="plainValueType" mixed="true">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           A simple value, used in collections and to specify a type for parameters.
+           
+           e.g.
+           <parameter><value class="com.acme.MyClass">xxx</value></parameter>
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:attribute name="class" type="classNameType" use="optional"/>
+      <xsd:attribute name="replace" type="xsd:boolean" use="optional"/>
+      <xsd:attribute name="trim" type="xsd:boolean" use="optional"/>
+   </xsd:complexType>
+
+   <xsd:complexType name="valueType" mixed="true">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           A value that can take other values, i.e. properties and parameters.
+           
+           e.g.
+           <parameter><value class="com.acme.MyClass">xxx</value></parameter>
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexContent>
+         <xsd:extension base="plainValueType">
+            <xsd:sequence>
+               <xsd:choice minOccurs="0">
+                  <xsd:group ref="valueGroup"/>
+               </xsd:choice>
+            </xsd:sequence>
+         </xsd:extension>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <xsd:complexType name="classLoaderValueType" mixed="true">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           A value that represents a classloader.
+           
+           e.g.
+           <classloader><inject bean="SomeClassLoader"/></parameter>
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:choice>
+         <xsd:element name="bean" type="beanType"/>
+         <xsd:element name="inject" type="dependencyType"/>
+         <xsd:element name="null">
+            <xsd:complexType/>
+         </xsd:element>
+         <xsd:any namespace="##other" processContents="strict">
+            <xsd:annotation>
+               <xsd:documentation>An extension value</xsd:documentation>
+            </xsd:annotation>
+         </xsd:any>
+      </xsd:choice>
+   </xsd:complexType>
+
+   <xsd:complexType name="annotatedValueType" mixed="true">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           A value that can take annotations.
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexContent>
+         <xsd:extension base="valueType">
+            <xsd:sequence>
+               <xsd:element name="annotation" type="annotationType" minOccurs="0" maxOccurs="unbounded"/>
+            </xsd:sequence>
+         </xsd:extension>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <xsd:complexType name="namedValueType" mixed="true">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           A value that has a name, currently only a property.
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexContent>
+         <xsd:extension base="annotatedValueType">
+            <xsd:attribute name="name" type="xsd:string" use="required"/>
+         </xsd:extension>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <xsd:complexType name="baseCollectionType">
+      <xsd:annotation>
+         <xsd:documentation>
+            <![CDATA[
+            A collection defines a java.util.Collection object.
+            It has two class definitions:
+            class: The implementation class of the collection
+            elementClass: The default implementation class of the elements
+            The default "class" is a java.util.ArrayList unless the point of injection
+            defines a concrete type, e.g. in the signature of the setter
+            
+            example:
+            <property name="whatever" class="java.util.ArrayList" elementClass="java.net.URL">
+               <value>http://localhost</value> <!-- Creates a URL -->
+               <value class="java.lang.String">http://localhost</value> <!-- Creates a String -->
+            </property>
+            ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:choice minOccurs="0" maxOccurs="unbounded">
+         <xsd:group ref="valueGroup"/>
+      </xsd:choice>
+      <xsd:attribute name="class" type="classNameType" use="optional"/>
+      <xsd:attribute name="elementClass" type="classNameType" use="optional"/>      
+   </xsd:complexType>
+
+   <xsd:complexType name="collectionType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           A collection, see baseCollectionType
+           the default collection is a java.util.ArrayList
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexContent>
+         <xsd:extension base="baseCollectionType"/>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <xsd:complexType name="listType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           A list, see baseCollectionType
+           the default list is a java.util.ArrayList
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexContent>
+         <xsd:extension base="baseCollectionType"/>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <xsd:complexType name="setType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           A set, see baseCollectionType
+           the default set is a java.util.HashSet
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexContent>
+         <xsd:extension base="baseCollectionType"/>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <xsd:complexType name="arrayType">
+      <xsd:annotation>
+         <xsd:documentation>
+           <![CDATA[
+           An array, see baseCollectionType
+           the default array is a java.lang.Object[]
+           ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexContent>
+         <xsd:extension base="baseCollectionType"/>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <xsd:complexType name="mapType">
+      <xsd:annotation>
+         <xsd:documentation>
+            <![CDATA[
+            A map defines a java.util.Map object.
+            It has three class definitions:
+            class: The implementation class of the class
+            keyClass: The default implementation class of the keys
+            valueClass: The default implementation class of the values
+            The default "class" is a java.util.HashMap unless the point of injection
+            defines a concrete type, e.g. in the signature of the setter
+            
+            e.g.:
+            <property name="whatever" class="java.util.HashMap" keyClass="java.lang.String" valueClas="java.net.URL">
+               <!-- map.put(new String("default"), new URL("http://localhost"));
+               <entry><key>default</key><value>http://localhost</value>
+               <!-- map.put(new String("default"), new String("http://localhost"));
+               <entry><key>default</key><value class="java.lang.String">http://localhost</value>
+            </property>
+            ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:sequence>
+         <xsd:element name="entry" type="entryType" minOccurs="0" maxOccurs="unbounded"/>
+      </xsd:sequence>
+      <xsd:attribute name="class" type="classNameType" use="optional"/>
+      <xsd:attribute name="keyClass" type="classNameType" use="optional"/>      
+      <xsd:attribute name="valueClass" type="classNameType" use="optional"/>      
+   </xsd:complexType>
+
+   <xsd:complexType name="entryType">
+      <xsd:annotation>
+         <xsd:documentation>
+            <![CDATA[
+            An entry in map. These are made of key/value pairs
+            
+            e.g.:
+            <entry><key>default</key><value>http://localhost</value>
+            ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:sequence>
+         <xsd:element name="key" type="valueType" minOccurs="0"/>
+         <xsd:element name="value" type="valueType" minOccurs="0"/>
+      </xsd:sequence>
+   </xsd:complexType>
+
+   <xsd:complexType name="dependsType">
+      <xsd:annotation>
+         <xsd:documentation>
+            <![CDATA[
+            The depends element is used to define that one bean depends upon
+            another for the create/start/stop/destroy lifecycle
+            
+            e.g.:
+            <bean name="IGoFirst" .../>
+            <bean name="IGoSecond" ...>
+               <depends>IGoFirst</depends>
+            </bean>
+            ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:simpleContent>
+         <xsd:extension base="xsd:string"/>
+      </xsd:simpleContent>
+   </xsd:complexType>
+
+   <xsd:complexType name="demandType">
+      <xsd:annotation>
+         <xsd:documentation>
+            <![CDATA[
+            The demand is used to specify a dependency on a supply
+            and when the demand is should be deplied
+            
+            e.g.:
+            ISupply must be installed before IDemand is constructed
+
+            <bean name="IDemand">
+               <demand state="Instantiated">theSupply</demand>
+            </bean>
+            <bean name="ISupply" ...>
+               <supply>theSupply</supply>
+            </bean>
+            ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:simpleContent>
+         <xsd:extension base="xsd:string">
+            <xsd:attribute name="state" type="controllerStateType" use="optional"/>
+            <xsd:attribute name="transformer" type="xsd:token" use="optional"/>
+         </xsd:extension>
+      </xsd:simpleContent>
+   </xsd:complexType>
+
+   <xsd:complexType name="supplyType">
+      <xsd:annotation>
+         <xsd:documentation>
+            <![CDATA[
+            The supply is used to specify that the bean supplies a demanded dependency
+            
+            e.g.:
+            <bean name="IDemand" ...>
+               <demand>theSupply</demand>
+            </bean>
+            <bean name="ISupply" ...>
+               <supply>theSupply</supply>
+            </bean>
+            ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:simpleContent>
+         <xsd:extension base="xsd:string">
+            <xsd:attribute name="class" type="classNameType" use="optional"/>
+         </xsd:extension>
+      </xsd:simpleContent>
+   </xsd:complexType>
+
+   <xsd:simpleType name="controllerStateType">
+      <xsd:annotation>
+         <xsd:documentation>
+            <![CDATA[
+            The controller state is used to say when dependencies must be satisfied.
+            Valid values include:
+            Described
+            Instantiated
+            Configured
+            Create
+            Start
+            Installed
+            ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:restriction base="xsd:string">
+         <xsd:whiteSpace value="collapse"/>
+      </xsd:restriction>
+   </xsd:simpleType>
+
+   <xsd:simpleType name="controllerModeType">
+      <xsd:annotation>
+         <xsd:documentation>
+            <![CDATA[
+            The controller mode, used to control how automatic the bean progresses
+            through the controller lifecyle (the states).
+            Valid values include:
+            Automatic (default) - the controller takes the bean to "Installed"
+            Manual - the user must tell the controller the required state
+            On Demand - the controller takes the bean to "Installed" when another bean depends on it
+            Disabled - the controller or user cannot change the state
+            ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:restriction base="xsd:string">
+         <xsd:whiteSpace value="collapse"/>
+      </xsd:restriction>
+   </xsd:simpleType>
+
+   <xsd:simpleType name="autowireTypeType">
+      <xsd:annotation>
+         <xsd:documentation>
+            <![CDATA[
+            You can set the type of lookup requirement - class type (ByClass) or property name (ByName)
+            Valid values include:
+            None
+            ByClass (default)
+            ByName
+            Constructor
+            Auto
+            ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:restriction base="xsd:string">
+         <xsd:whiteSpace value="collapse"/>
+      </xsd:restriction>
+   </xsd:simpleType>
+
+   <xsd:simpleType name="optionType">
+      <xsd:annotation>
+         <xsd:documentation>
+            <![CDATA[
+            You can set the type of lookup option - Strict or Callback
+            Valid values include:
+            Strict (default)
+            Callback
+            ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:restriction base="xsd:string">
+         <xsd:whiteSpace value="collapse"/>
+      </xsd:restriction>
+   </xsd:simpleType>
+
+   <xsd:simpleType name="contextType">
+      <xsd:annotation>
+         <xsd:documentation>
+            <![CDATA[
+            You can set the type of context property lookup
+            Valid values include:
+            name
+            metadata
+            scope
+            ]]>
+         </xsd:documentation>
+      </xsd:annotation>
+      <xsd:restriction base="xsd:string">
+         <xsd:whiteSpace value="collapse"/>
+      </xsd:restriction>
+   </xsd:simpleType>
+
    <!--
      WARN:
      Do not use this in the bean deployer, it won't work!
@@ -285,5 +1158,4 @@
    -->
    <xsd:element name="lazy" type="lazyType"/>
 
-
 </xsd:schema>




More information about the jboss-cvs-commits mailing list