With Dokka 1.8.10 i got Problemsto show the private functions of my classes. I tried includeNonPublic.set(true) with an older version (which worked) but for 1.8.10 this mehtod is deprecated...
I'm searchin for an solution, that shows my private functions in the classes.
So this is my code in the build.gradle (:app)
I think this are the relevant parts.
import org.jetbrains.dokka.gradle.DokkaTask
plugins {
id 'com.android.application'
id 'org.jetbrains.kotlin.android'
id 'org.jetbrains.dokka' version '1.8.10'
}
...
dependencies {
implementation platform('androidx.compose:compose-bom:2023.01.00')
debugImplementation "androidx.compose.ui:ui-test-manifest"
debugImplementation "androidx.compose.ui:ui-tooling"
implementation 'androidx.activity:activity-compose:1.6.1'
implementation "androidx.compose.material:material"
implementation "androidx.compose.ui:ui"
implementation "androidx.compose.ui:ui-tooling-preview"
implementation 'androidx.core:core-ktx:1.9.0'
implementation 'androidx.lifecycle:lifecycle-runtime-ktx:2.5.1'
dokkaPlugin 'org.jetbrains.dokka:android-documentation-plugin:1.8.10'
}
...
// Configure all single-project Dokka tasks at the same time,
// such as dokkaHtml, dokkaJavadoc and dokkaGfm.
tasks.withType(DokkaTask.class) {
moduleName.set(project.name)
moduleVersion.set(project.version.toString())
outputDirectory.set(file("build/dokka/$name"))
failOnWarning.set(false)
suppressObviousFunctions.set(true)
suppressInheritedMembers.set(true)
offlineMode.set(false)
dokkaSourceSets.configureEach {
/*documentedVisibilities.set([
DokkaConfiguration.Visibility.PUBLIC,
DokkaConfiguration.Visibility.PROTECTED
])*/
perPackageOption {
matchingRegex.set(".*internal.*")
suppress.set(true)
//documentedVisibilities.set([Visibility.PRIVATE])
}
}
}
dokkaHtml {
outputDirectory.set(file("build/documentation/html"))
}
tasks.dokkaHtml.configure {
dokkaSourceSets {
configureEach {
// A set of visibility modifiers that should be documented
// If set by user, overrides includeNonPublic. Default is PUBLIC
documentedVisibilities.set(listOf(DokkaConfiguration.Visibility.PRIVATE) + documentedVisibilities.get())
//includeNonPublic.set(true)
skipDeprecated.set(true)
reportUndocumented.set(true)
noAndroidSdkLink.set(false)
}
}
}