// check default namespace set at top level of binding
String defaultns = findDefaultNS(binding.topChildIterator(), dns);
// add all top level mapping and format definitions to maps
for (Iterator iter = binding.topChildIterator(); iter.hasNext();) {
ElementBase child = (ElementBase)iter.next();
if (child.type() == ElementBase.INCLUDE_ELEMENT) {
// recurse to process included binding definitions
IncludeElement include = (IncludeElement)child;
if(include.getBinding() != null) {
collectTopLevelComponents(include.getBinding(), defaultns,
elementMap, complexTypeMap, simpleTypeMap, bindingMap);
}
} else if (child.type() == ElementBase.FORMAT_ELEMENT) {
// register named formats as simple type conversions
FormatElement format = (FormatElement)child;
registerElement(format.getQName(), format, simpleTypeMap);
bindingMap.put(format, binding);
} else if (child.type() == ElementBase.MAPPING_ELEMENT) {
// record only abstract mappings with type names, and mappings with names
MappingElementBase mapping = (MappingElementBase)child;
bindingMap.put(mapping, binding);
if (mapping.isAbstract() && mapping.getTypeQName() != null) {