elemName = te.getElementName();
}
Collection<TypeInfo> refs = propInfo.ref();
if ((refs != null) && (!refs.isEmpty()) && (elemName != null)){
ClassInfoImpl cImpl = null;
for (TypeInfo ref : refs) {
if (ref == null || ref instanceof ClassInfoImpl) {
if (elemName.equals(((ClassInfoImpl)ref).getElementName())) {
cImpl = (ClassInfoImpl) ref;
break;
}
}
}
if (cImpl != null)
e.ref(new QName(cImpl.getElementName().getNamespaceURI(), tn.getLocalPart()));
else
e.ref(new QName("", tn.getLocalPart()));
} else
e.ref(tn);
}