diff options
author | aleksZubakov <aleks.zubakov@gmail.com> | 2018-08-01 19:48:45 +0300 |
---|---|---|
committer | aleksZubakov <aleks.zubakov@gmail.com> | 2018-08-01 19:48:45 +0300 |
commit | 052a218dcf8bc565d5e78dc900a9647f0da5350a (patch) | |
tree | 7f63b95ea16c4de5fc241cfcb384cc8d337f7310 /runners/maven-plugin/src/main | |
parent | 899c11d36f565cd192945573860568ff62c16ef2 (diff) | |
download | dokka-052a218dcf8bc565d5e78dc900a9647f0da5350a.tar.gz dokka-052a218dcf8bc565d5e78dc900a9647f0da5350a.tar.bz2 dokka-052a218dcf8bc565d5e78dc900a9647f0da5350a.zip |
Refactoring, replace DocumentationOption with PassConfiguration
Diffstat (limited to 'runners/maven-plugin/src/main')
-rw-r--r-- | runners/maven-plugin/src/main/kotlin/DokkaMojo.kt | 47 |
1 files changed, 25 insertions, 22 deletions
diff --git a/runners/maven-plugin/src/main/kotlin/DokkaMojo.kt b/runners/maven-plugin/src/main/kotlin/DokkaMojo.kt index ea55c8fe..78fd2d86 100644 --- a/runners/maven-plugin/src/main/kotlin/DokkaMojo.kt +++ b/runners/maven-plugin/src/main/kotlin/DokkaMojo.kt @@ -129,30 +129,33 @@ abstract class AbstractDokkaMojo : AbstractMojo() { return } - val gen = DokkaGenerator( - MavenDokkaLogger(log), - classpath, - sourceDirectories.map { SourceRootImpl(it) } + sourceRoots, - samplesDirs, - includeDirs + includes, - moduleName, - DocumentationOptions(getOutDir(), getOutFormat(), - sourceLinks = sourceLinks.map { SourceLinkDefinitionImpl(it.dir, it.url, it.urlSuffix) }, - jdkVersion = jdkVersion, - skipDeprecated = skipDeprecated, - skipEmptyPackages = skipEmptyPackages, - reportUndocumented = reportNotDocumented, - impliedPlatforms = impliedPlatforms, - perPackageOptions = perPackageOptions, - externalDocumentationLinks = externalDocumentationLinks.map { it.build() }, - noStdlibLink = noStdlibLink, - noJdkLink = noJdkLink, - cacheRoot = cacheRoot, - languageVersion = languageVersion, - apiVersion = apiVersion - ) + val passConfiguration = PassConfigurationImpl( + sourceLinks = sourceLinks.map { SourceLinkDefinitionImpl(it.dir, it.url, it.urlSuffix) }, + jdkVersion = jdkVersion, + skipDeprecated = skipDeprecated, + skipEmptyPackages = skipEmptyPackages, + reportUndocumented = reportNotDocumented, + perPackageOptions = perPackageOptions, + externalDocumentationLinks = externalDocumentationLinks.map { it.build() }, + noStdlibLink = noStdlibLink, + noJdkLink = noJdkLink, + languageVersion = languageVersion, + apiVersion = apiVersion + + ) + + val configuration = DokkaConfigurationImpl( + outputDir = getOutDir(), + format = getOutFormat(), + impliedPlatforms = impliedPlatforms, + cacheRoot = cacheRoot, + passesConfigurations = listOf( + passConfiguration + ) ) + val gen = DokkaGenerator(configuration, MavenDokkaLogger(log)) + gen.generate() } } |