aboutsummaryrefslogtreecommitdiff
path: root/src/Kotlin/KotlinLanguageService.kt
diff options
context:
space:
mode:
Diffstat (limited to 'src/Kotlin/KotlinLanguageService.kt')
-rw-r--r--src/Kotlin/KotlinLanguageService.kt7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/Kotlin/KotlinLanguageService.kt b/src/Kotlin/KotlinLanguageService.kt
index 40f47639..8795aba6 100644
--- a/src/Kotlin/KotlinLanguageService.kt
+++ b/src/Kotlin/KotlinLanguageService.kt
@@ -1,20 +1,23 @@
package org.jetbrains.dokka
+import org.jetbrains.dokka.LanguageService.RenderMode
+
/**
* Implements [LanguageService] and provides rendering of symbols in Kotlin language
*/
class KotlinLanguageService : LanguageService {
- override fun render(node: DocumentationNode): ContentNode {
+ override fun render(node: DocumentationNode, renderMode: RenderMode): ContentNode {
return content {
when (node.kind) {
DocumentationNode.Kind.Package -> renderPackage(node)
DocumentationNode.Kind.Class,
DocumentationNode.Kind.Interface,
DocumentationNode.Kind.Enum,
- DocumentationNode.Kind.EnumItem,
DocumentationNode.Kind.AnnotationClass,
DocumentationNode.Kind.Object -> renderClass(node)
+ DocumentationNode.Kind.EnumItem -> if (renderMode == RenderMode.FULL) identifier(node.name)
+
DocumentationNode.Kind.TypeParameter -> renderTypeParameter(node)
DocumentationNode.Kind.Type,
DocumentationNode.Kind.UpperBound -> renderType(node)