public static Archive instantiate(XmlDoc.Element arcElement) throws Throwable { Type type = Type.instantiate(arcElement.value("type")); Archive arc = new Archive(type); List<XmlDoc.Element> pes = arcElement.elements("parameter"); if (pes != null) { for (XmlDoc.Element pe : pes) { arc.setParameter(pe.value("@name"), pe.value()); } } return arc; }