private void exportPackageInfo(File outputDir, String packageName) {
        File dirForSources = new File(outputDir, packageName.replaceAll("\\.", "/"));
        dirForSources.mkdirs();
        File target = new File(dirForSources, "package-info.java");
        if (target.lastModified() > newestModifiedTime) {
            getLog().debug("No changes, not updating "+target);
            return;
        }
        try (Writer out = new FileWriter(target)) {
                out.write("@ExportPackage\n" +
                    "package "+packageName+";\n\n" +
                    "import com.yahoo.osgi.annotation.ExportPackage;\n");
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
    }
Creates package-info.java, so that the package of the concrete doc types get exported from user's bundle.
vespa-documentgen-plugin/src/main/java/com/yahoo/vespa/DocumentGenMojo.java