kotlin-dokka

Copy KDoc docs from one method to another

我只是一个虾纸丫 提交于 2021-02-07 12:35:51
问题 For the two given methods: /** * Adds a [DataItem] to the Android Wear network. The updated item is synchronized across all devices. */ fun putItem(){ .... } /** * "same KDOC here with above" */ fun putItem(putRequest: PutDataRequest){ .... } Is there any possibility to copy/link the docs of the second method to be the same with the first one? Manually copy pasting the KDOC is not so great because if you update one of them there is high chance the second to accidentally be outdated. 回答1:

KDoc Annotations not rendered in Dokka generated HTML

孤人 提交于 2020-04-13 18:37:06
问题 I am currently testing the Dokka documentation and some of the annotations I have made are not being rendered. Here are my findings: Classes don't show @sample , and html tags <p></p> , <h1></h1> : See SimpleCalculator class documentation If a description was under an html tag, it will not show: See enum class OPERATOR code documentation Methods don't show @sample and @property at all: See all the method code documentation Mixed of definition between @property and @param . In class

KDoc Annotations not rendered in Dokka generated HTML

|▌冷眼眸甩不掉的悲伤 提交于 2020-04-13 18:36:53
问题 I am currently testing the Dokka documentation and some of the annotations I have made are not being rendered. Here are my findings: Classes don't show @sample , and html tags <p></p> , <h1></h1> : See SimpleCalculator class documentation If a description was under an html tag, it will not show: See enum class OPERATOR code documentation Methods don't show @sample and @property at all: See all the method code documentation Mixed of definition between @property and @param . In class

KDoc Annotations not rendered in Dokka generated HTML

穿精又带淫゛_ 提交于 2020-04-13 18:36:50
问题 I am currently testing the Dokka documentation and some of the annotations I have made are not being rendered. Here are my findings: Classes don't show @sample , and html tags <p></p> , <h1></h1> : See SimpleCalculator class documentation If a description was under an html tag, it will not show: See enum class OPERATOR code documentation Methods don't show @sample and @property at all: See all the method code documentation Mixed of definition between @property and @param . In class

Can't get dokka to generate kotlin docs on gradle/android project

ⅰ亾dé卋堺 提交于 2020-01-02 04:06:11
问题 I'm following the gradle plugin section in https://github.com/Kotlin/dokka . I also tried the dokka-gradle-example example in https://github.com/JetBrains/kotlin-examples/tree/master/gradle/dokka-gradle-example . The versions I'm using are: android: '23.1.1' dokka: '0.9.6' gradle-android-plugin: '1.5.0' kotlin: '1.0.0-rc-1036' but I also tried with Dokka versions from 0.9 up to 0.9.7. The relevant parts of the output are: ... :app:dokka FAILED :app:dokka (Thread[Daemon worker Thread 9,5,main]

How do I inherit KDoc documentation?

微笑、不失礼 提交于 2019-12-19 05:13:02
问题 In Java's Javadoc, there is a way to inherit a method's documentation in a subclass using {@inheritDoc} tag. Is there a way to do the same in Kotlin's KDoc? Basically, what I'd like to do is the following: abstract class Base { /** * Some KDoc documentation here. */ abstract fun foo() } class Derived: Base() { /** * Here is all the documentation from Base#foo's KDoc inherited. * * And here goes something more in addition. */ override fun foo() { /* ... */ } } 回答1: Dokka always copies the

Dokka - skip generating javadoc for default android packages

你说的曾经没有我的故事 提交于 2019-12-05 22:00:44
问题 I am trying to use Dokka plugin to generate Javadoc for android Kotlin application. I added the plugin to my gradle: classpath "org.jetbrains.dokka:dokka-gradle-plugin:0.9.15" Then I made a basic configuration following project instructions: dokka { outputFormat = 'javadoc' outputDirectory = "$rootDir/docs" skipEmptyPackages = true noStdlibLink = true } I generate documentation using basic gradle command: [user@linux AppDir]$ bash gradlew dokka Output is fine, but it includes multiple

Can't get dokka to generate kotlin docs on gradle/android project

梦想与她 提交于 2019-12-05 08:34:24
I'm following the gradle plugin section in https://github.com/Kotlin/dokka . I also tried the dokka-gradle-example example in https://github.com/JetBrains/kotlin-examples/tree/master/gradle/dokka-gradle-example . The versions I'm using are: android: '23.1.1' dokka: '0.9.6' gradle-android-plugin: '1.5.0' kotlin: '1.0.0-rc-1036' but I also tried with Dokka versions from 0.9 up to 0.9.7. The relevant parts of the output are: ... :app:dokka FAILED :app:dokka (Thread[Daemon worker Thread 9,5,main]) completed. Took 0.766 secs. FAILURE: Build failed with an exception. * What went wrong: Execution

Reference value of constant with KDoc

折月煮酒 提交于 2019-12-01 11:25:55
I have a object like the following in my project object UrlUtils { private const val PARAM = "whatever" /** * Method that appends the [PARAM] parameter to the url */ fun appendParameter(url: String) { // ... } } As you can see a I wanna reference the value of the PARAM field in the KDoc comment of the appendParameter method however when looking at the comment I don't see the actual value but only the name of the field. Method that appends the PARAM parameter to the url What I want: Method that appends the whatever parameter to the url In Javadoc this works by using {@value PARAM} but there

Reference value of constant with KDoc

偶尔善良 提交于 2019-12-01 07:32:36
问题 I have a object like the following in my project object UrlUtils { private const val PARAM = "whatever" /** * Method that appends the [PARAM] parameter to the url */ fun appendParameter(url: String) { // ... } } As you can see a I wanna reference the value of the PARAM field in the KDoc comment of the appendParameter method however when looking at the comment I don't see the actual value but only the name of the field. Method that appends the PARAM parameter to the url What I want: Method