use of main.entity.type.XmlHoldingType in project Eidolons by IDemiurge.
the class TypeBuilder method setProps.
private static void setProps(DataModel type, NodeList childNodes) {
for (int i = 0; i < childNodes.getLength(); i++) {
Node child = childNodes.item(i);
if (child.getNodeName().equals(XML_Converter.TEXT_NODE)) {
continue;
}
if ((type) instanceof XmlHoldingType) {
if (StringMaster.getWellFormattedString(child.getNodeName()).equals(((XmlHoldingType) (type)).getXmlProperty().getName())) {
child = XML_Converter.getAbilitiesDoc(child);
type.setProperty(ContentManager.getPROP(child.getNodeName()), XML_Converter.getStringFromXML(child, false));
((XmlDocHolder) type).setDoc(child);
continue;
}
}
PROPERTY prop = ContentManager.getPROP(child.getNodeName());
if (prop == null) {
LogMaster.log(1, "no such prop: " + child.getNodeName());
prop = ContentManager.getPROP(child.getNodeName());
continue;
}
type.setProperty(prop, getTextFromXml(child));
}
}
Aggregations