Builds
TypeUse from simple types.
This code consists of two main portions. The
SimpleTypeBuilder.compose(XSSimpleType) method
and
SimpleTypeBuilder.composer forms an outer cycle, which gradually ascends the type
inheritance chain until it finds the suitable binding. When it does this
SimpleTypeBuilder.initiatingType is set to the type which started binding, so that we can refer
to the actual constraint facets and such that are applicable on the type.
For each intermediate type in the chain, the
SimpleTypeBuilder.find(XSSimpleType) method
is used to find the binding on that type, sine the outer loop is doing the ascending,
this method only sees if the current type has some binding available.
There is at least one ugly code that you need to aware of
when you are modifying the code. See the documentation
about
"simple type customization at the point of reference."
author: Kohsuke Kawaguchi (kohsuke.kawaguchi@sun.com) |