Also, why not just borrow from the spring property model:
| <!-- | Bean definitions can have zero or more properties. | Property elements correspond to JavaBean setter methods exposed | by the bean classes. Spring supports primitives, references to other | beans in the same or related factories, lists, maps and properties. | --> | <!ELEMENT property (description? , (bean | ref | idref | list | set | map | props | value | null))> | | <!-- | The property name attribute is the name of the JavaBean property. | This follows JavaBean conventions: a name of "age" would correspond | to setAge()/optional getAge() methods. | --> | <!ATTLIST property name CDATA #REQUIRED> | | <!-- | Defines a reference to another bean in this factory or an external | factory (parent or included factory). | --> | <!ELEMENT ref EMPTY> | | <!-- | References must specify a name of the target bean. | The "bean" attribute can reference any name from any bean in the context, | to be checked at runtime. | Local references, using the "local" attribute, have to use bean ids; | they can be checked by this DTD, thus should be preferred for references | within the same bean factory XML file. | --> | <!ATTLIST ref bean CDATA #IMPLIED> | | <!ATTLIST ref local IDREF #IMPLIED> | | <!ATTLIST ref parent CDATA #IMPLIED> | | <!-- | Defines a string property value, which must also be the id of another | bean in this factory or an external factory (parent or included factory). | While a regular 'value' element could instead be used for the same effect, | using idref in this case allows validation of local bean ids by the xml | parser, and name completion by helper tools. | --> | <!ELEMENT idref EMPTY> | | <!-- | ID refs must specify a name of the target bean. | The "bean" attribute can reference any name from any bean in the context, | potentially to be checked at runtime by bean factory implementations. | Local references, using the "local" attribute, have to use bean ids; | they can be checked by this DTD, thus should be preferred for references | within the same bean factory XML file. | --> | <!ATTLIST idref bean CDATA #IMPLIED> | | <!ATTLIST idref local IDREF #IMPLIED> | | <!-- | A list can contain multiple inner bean, ref, collection, or value elements. | Java lists are untyped, pending generics support in Java 1.5, | although references will be strongly typed. | A list can also map to an array type. The necessary conversion | is automatically performed by the BeanFactory. | --> | <!ELEMENT list ((bean | ref | idref | list | set | map | props | value | null)*)> | | <!-- | A set can contain multiple inner bean, ref, collection, or value elements. | Java sets are untyped, pending generics support in Java 1.5, | although references will be strongly typed. | --> | <!ELEMENT set ((bean | ref | idref | list | set | map | props | value | null)*)> | | <!-- | A Spring map is a mapping from a string key to object. | Maps may be empty. | --> | <!ELEMENT map ((entry)*)> | | <!-- | A map entry can be an inner bean, ref, collection, or value. | The name of the property is given by the "key" attribute. | --> | <!ELEMENT entry ((bean | ref | idref | list | set | map | props | value | null))> | | <!-- | Each map element must specify its key. | --> | <!ATTLIST entry key CDATA #REQUIRED> | | <!-- | Props elements differ from map elements in that values must be strings. | Props may be empty. | --> | <!ELEMENT props ((prop)*)> | | <!-- | Element content is the string value of the property. | Note that whitespace is trimmed off to avoid unwanted whitespace | caused by typical XML formatting. | --> | <!ELEMENT prop (#PCDATA)> | | <!-- | Each property element must specify its key. | --> | <!ATTLIST prop key CDATA #REQUIRED> | | <!-- | Contains a string representation of a property value. | The property may be a string, or may be converted to the | required type using the JavaBeans PropertyEditor | machinery. This makes it possible for application developers | to write custom PropertyEditor implementations that can | convert strings to objects. | | Note that this is recommended for simple objects only. | Configure more complex objects by populating JavaBean | properties with references to other beans. | --> | <!ELEMENT value (#PCDATA)> | | <!-- | Denotes a Java null value. Necessary because an empty "value" tag | will resolve to an empty String, which will not be resolved to a | null value unless a special PropertyEditor does so. | --> | <!ELEMENT null (#PCDATA)> | View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3870493#3870493 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3870493 ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click _______________________________________________ JBoss-Development mailing list JBoss-Development@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-development