Hi Norman, and other XML experts,
One of the tasks for Web Beans is to build an XSD. There is an XSD per
package, and an root-element per class. Classes can have annotations,
such as bindings, which makes them into a bean. This means, for
example, that a child element of the class element could be a binding
type annotation (it's XML element equivalent), however placing, for
example, an annotation which is not, for example, a binding type would
be an error.
Therefore, we can increase the "type safety" of the XSD by restricting
the category of child elements that can be placed in the class
element. However, I don't know how to do this in XSD - any pointers?
I suspect we can't do this natively using XSD, but we can at least
mark this as a point that only certain categories of elements can be
placed, and domain-aware editor like JBoss Tools can use this. In this
case, any suggestions for how to do this "mark"?
Thanks!
--
Pete Muir
http://www.seamframework.org
http://in.relation.to/Bloggers/Pete