*/
public void buildChildren() {
Iterator<DefaultElement> children = this.elementIterator();
// iterate through children
while (children.hasNext()) {
DefaultElement child = children.next();
if (child.getName().equals(CPCore.FILE)) {
CPFile file = new CPFile(child, this.xmlbase, parent.getRootDir());
file.buildChildren();
file.setParentElement(this);
files.add(file);
} else if (child.getName().equals(CPCore.DEPENDENCY)) {
CPDependency dep = new CPDependency(child);
dep.setParentElement(this);
dependencies.add(dep);
} else if (child.getName().equals(CPCore.METADATA)) {
// TODO: implement METADATA
metadata = new CPMetadata(child);
metadata.setParentElement(this);
} else {
throw new OLATRuntimeException(CPOrganizations.class, "Invalid IMS-Manifest (unallowed element under <resource>)", new Exception());