< prev index next >

src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/DocFilesHandlerImpl.java

Print this page

        

*** 72,87 **** this.configuration = configuration; this.element = element; switch (element.getKind()) { case MODULE: ! location = configuration.utils.getLocationForModule((ModuleElement)element); source = DocPaths.DOC_FILES; break; case PACKAGE: ! location = configuration.utils.getLocationForPackage((PackageElement)element); ! source = DocPath.forPackage((PackageElement)element).resolve(DocPaths.DOC_FILES); break; default: throw new AssertionError("unsupported element " + element); } } --- 72,93 ---- this.configuration = configuration; this.element = element; switch (element.getKind()) { case MODULE: ! ModuleElement mdle = (ModuleElement)element; ! location = configuration.utils.getLocationForModule(mdle); source = DocPaths.DOC_FILES; break; case PACKAGE: ! PackageElement pkg = (PackageElement)element; ! location = configuration.utils.getLocationForPackage(pkg); ! // Note, given that we have a module-specific location, ! // we want a module-relative path for the source, and not the ! // standard path that may include the module directory ! source = DocPath.create(pkg.getQualifiedName().toString().replace('.', '/')) ! .resolve(DocPaths.DOC_FILES); break; default: throw new AssertionError("unsupported element " + element); } }
*** 101,114 **** continue; } DocPath path = null; switch (this.element.getKind()) { case MODULE: ! path = DocPath.forModule((ModuleElement)this.element); break; case PACKAGE: ! path = DocPath.forPackage((PackageElement)this.element); break; default: throw new AssertionError("unknown kind:" + this.element.getKind()); } copyDirectory(srcdir, path.resolve(DocPaths.DOC_FILES), first); --- 107,120 ---- continue; } DocPath path = null; switch (this.element.getKind()) { case MODULE: ! path = DocPaths.forModule((ModuleElement)this.element); break; case PACKAGE: ! path = configuration.docPaths.forPackage((PackageElement)this.element); break; default: throw new AssertionError("unknown kind:" + this.element.getKind()); } copyDirectory(srcdir, path.resolve(DocPaths.DOC_FILES), first);
< prev index next >