JpsLibrary (Element sdkElement, @NotNull JpsPathMapper pathMapper) { String name = getAttributeValue(sdkElement, NAME_TAG); String typeId = getAttributeValue(sdkElement, TYPE_TAG); LOG.debug("Loading " + typeId + " SDK '" + name + "'"); JpsSdkPropertiesSerializer<?> serializer = getSdkPropertiesSerializer(typeId); final JpsLibrary library = createSdk(name, serializer, pathMapper, sdkElement); final Element roots = sdkElement.getChild(ROOTS_TAG); for (Element rootTypeElement : JDOMUtil.getChildren(roots)) { JpsLibraryRootTypeSerializer rootTypeSerializer = getRootTypeSerializer(rootTypeElement.getName()); if (rootTypeSerializer != null) { for (Element rootElement : rootTypeElement.getChildren()) { loadRoots(rootElement, library, rootTypeSerializer.getType(), pathMapper); } } else { LOG.info("root type serializer not found for " + rootTypeElement.getName()); } } if (LOG.isDebugEnabled()) { List<File> files = library.getFiles(JpsOrderRootType.COMPILED); LOG.debug(name + " SDK classpath (" + files.size() + " roots):"); for (File file : files) { LOG.debug(" " + file.getAbsolutePath()); } } return library; }