this.getRuntimeXMLValidationLevel()); ReadableArchive subArchive = archive.getSubArchive(md.getArchiveUri()); if (md.getAlternateDescriptor()!=null) { DOLUtils.readAlternativeRuntimeDescriptor(archive, subArchive, archivist, (BundleDescriptor)md.getDescriptor(), md.getAlternateDescriptor()); } else { archivist.readRuntimeDeploymentDescriptor(subArchive, (BundleDescriptor)md.getDescriptor());
DOLUtils.setExtensionArchivistForSubArchivist(habitat, embeddedArchive, aModule, app, newArchivist); if (aModule.getAlternateDescriptor()!=null) { InputStream is = appArchive.getEntry(aModule.getAlternateDescriptor()); DeploymentDescriptorFile ddFile = newArchivist.getStandardDDFile(); ddFile.setXMLValidation(newArchivist.getXMLValidation()); DOLUtils.readAlternativeRuntimeDescriptor(appArchive, embeddedArchive, newArchivist, descriptor, aModule.getAlternateDescriptor());
/** * write the descriptor class to a DOM tree and return it * * @param parent node in the DOM tree * @param node name for the root element of this xml fragment * @param the descriptor to write * @return the DOM tree top node */ public Node writeDescriptor(Node parent, String nodeName, ModuleDescriptor descriptor) { Node module = appendChild(parent, nodeName); if (DOLUtils.warType().equals(descriptor.getModuleType())) { Node modType = appendChild(module, ApplicationTagNames.WEB); appendTextChild(modType, ApplicationTagNames.WEB_URI, descriptor.getArchiveUri()); forceAppendTextChild(modType, ApplicationTagNames.CONTEXT_ROOT, descriptor.getContextRoot()); } else { // default initialization if ejb... String type = ApplicationTagNames.EJB; if (DOLUtils.carType().equals(descriptor.getModuleType())) { type = ApplicationTagNames.APPLICATION_CLIENT; } else if (DOLUtils.rarType().equals(descriptor.getModuleType())) { type = ApplicationTagNames.CONNECTOR; } appendTextChild(module, type, descriptor.getArchiveUri()); } appendTextChild(module,ApplicationTagNames.ALTERNATIVE_DD, descriptor.getAlternateDescriptor()); return module; } }