diff options
Diffstat (limited to 'runners/gradle-plugin/src/main/kotlin/org')
-rw-r--r-- | runners/gradle-plugin/src/main/kotlin/org/jetbrains/dokka/gradle/DokkaTask.kt | 4 | ||||
-rw-r--r-- | runners/gradle-plugin/src/main/kotlin/org/jetbrains/dokka/gradle/configurationImplementations.kt | 52 |
2 files changed, 29 insertions, 27 deletions
diff --git a/runners/gradle-plugin/src/main/kotlin/org/jetbrains/dokka/gradle/DokkaTask.kt b/runners/gradle-plugin/src/main/kotlin/org/jetbrains/dokka/gradle/DokkaTask.kt index d15cf932..fc447225 100644 --- a/runners/gradle-plugin/src/main/kotlin/org/jetbrains/dokka/gradle/DokkaTask.kt +++ b/runners/gradle-plugin/src/main/kotlin/org/jetbrains/dokka/gradle/DokkaTask.kt @@ -70,12 +70,12 @@ open class DokkaTask : DefaultTask() { var multiplatform: Set<GradlePassConfigurationImpl> @Suppress("UNCHECKED_CAST") - @Input get() = (DslObject(this).extensions.getByName(MULTIPLATFORM_EXTENSION_NAME) as NamedDomainObjectContainer<GradlePassConfigurationImpl>).toSet() + @Nested get() = (DslObject(this).extensions.getByName(MULTIPLATFORM_EXTENSION_NAME) as NamedDomainObjectContainer<GradlePassConfigurationImpl>).toSet() internal set(value) = DslObject(this).extensions.add(MULTIPLATFORM_EXTENSION_NAME, value) var configuration: GradlePassConfigurationImpl @Suppress("UNCHECKED_CAST") - @Input get() = DslObject(this).extensions.getByType(GradlePassConfigurationImpl::class.java) + @Nested get() = DslObject(this).extensions.getByType(GradlePassConfigurationImpl::class.java) internal set(value) = DslObject(this).extensions.add(CONFIGURATION_EXTENSION_NAME, value) protected var externalDocumentationLinks: MutableList<DokkaConfiguration.ExternalDocumentationLink> = mutableListOf() diff --git a/runners/gradle-plugin/src/main/kotlin/org/jetbrains/dokka/gradle/configurationImplementations.kt b/runners/gradle-plugin/src/main/kotlin/org/jetbrains/dokka/gradle/configurationImplementations.kt index 09183858..0364985d 100644 --- a/runners/gradle-plugin/src/main/kotlin/org/jetbrains/dokka/gradle/configurationImplementations.kt +++ b/runners/gradle-plugin/src/main/kotlin/org/jetbrains/dokka/gradle/configurationImplementations.kt @@ -2,6 +2,8 @@ package org.jetbrains.dokka.gradle import groovy.lang.Closure import org.gradle.api.Action +import org.gradle.api.tasks.Input +import org.gradle.api.tasks.Optional import org.gradle.util.ConfigureUtil import org.jetbrains.dokka.DokkaConfiguration import org.jetbrains.dokka.DokkaConfiguration.* @@ -21,31 +23,31 @@ class GradleSourceRootImpl: SourceRoot, Serializable { override fun toString(): String = path } -open class GradlePassConfigurationImpl(@Transient val name: String = ""): PassConfiguration, Serializable { - override var classpath: List<String> = emptyList() - override var moduleName: String = "" - override var sourceRoots: MutableList<SourceRoot> = mutableListOf() - override var samples: List<String> = emptyList() - override var includes: List<String> = emptyList() - override var includeNonPublic: Boolean = false - override var includeRootPackage: Boolean = false - override var reportUndocumented: Boolean = false - override var skipEmptyPackages: Boolean = false - override var skipDeprecated: Boolean = false - override var jdkVersion: Int = 6 - override var sourceLinks: MutableList<SourceLinkDefinition> = mutableListOf() - override var perPackageOptions: MutableList<PackageOptions> = mutableListOf() - override var externalDocumentationLinks: MutableList<ExternalDocumentationLink> = mutableListOf() - override var languageVersion: String? = null - override var apiVersion: String? = null - override var noStdlibLink: Boolean = false - override var noJdkLink: Boolean = false - override var suppressedFiles: List<String> = emptyList() - override var collectInheritedExtensionsFromLibraries: Boolean = false - override var analysisPlatform: Platform = Platform.DEFAULT - var platform: String? = null - override var targets: List<String> = emptyList() - override var sinceKotlin: String? = null +open class GradlePassConfigurationImpl(@Transient val name: String = ""): PassConfiguration { + @Input @Optional override var classpath: List<String> = emptyList() + @Input override var moduleName: String = "" + @Input override var sourceRoots: MutableList<SourceRoot> = mutableListOf() + @Input override var samples: List<String> = emptyList() + @Input override var includes: List<String> = emptyList() + @Input override var includeNonPublic: Boolean = false + @Input override var includeRootPackage: Boolean = false + @Input override var reportUndocumented: Boolean = false + @Input override var skipEmptyPackages: Boolean = false + @Input override var skipDeprecated: Boolean = false + @Input override var jdkVersion: Int = 6 + @Input override var sourceLinks: MutableList<SourceLinkDefinition> = mutableListOf() + @Input override var perPackageOptions: MutableList<PackageOptions> = mutableListOf() + @Input override var externalDocumentationLinks: MutableList<ExternalDocumentationLink> = mutableListOf() + @Input @Optional override var languageVersion: String? = null + @Input @Optional override var apiVersion: String? = null + @Input override var noStdlibLink: Boolean = false + @Input override var noJdkLink: Boolean = false + @Input override var suppressedFiles: List<String> = emptyList() + @Input override var collectInheritedExtensionsFromLibraries: Boolean = false + @Input override var analysisPlatform: Platform = Platform.DEFAULT + @Input @Optional var platform: String? = null + @Input override var targets: List<String> = emptyList() + @Input @Optional override var sinceKotlin: String? = null fun sourceRoot(c: Closure<Unit>) { val configured = ConfigureUtil.configure(c, GradleSourceRootImpl()) |