mySchema.add(factory.newXSType(mySchema, type));
} else if (pChild instanceof XsTNamedGroup) {
XsTNamedGroup group = (XsTNamedGroup) pChild;
mySchema.add(factory.newXSGroup(mySchema, group));
} else if (pChild instanceof XsTAttributeGroup) {
XsTAttributeGroup attributeGroup = (XsTAttributeGroup) pChild;
mySchema.add(factory.newXSAttributeGroup(mySchema, attributeGroup));
} else if (pChild instanceof XsTTopLevelElement) {
XsTTopLevelElement element = (XsTTopLevelElement) pChild;
mySchema.add(factory.newXSElement(mySchema, element));
} else if (pChild instanceof XsTAttribute) {