aboutsummaryrefslogtreecommitdiff
path: root/plugins/javadoc
diff options
context:
space:
mode:
authorAndrzej Ratajczak <andrzej.ratajczak98@gmail.com>2020-08-12 14:26:45 +0200
committerSebastian Sellmair <34319766+sellmair@users.noreply.github.com>2020-08-17 11:55:35 +0200
commit785d741790f653d5c260f59c9d8875bbfde2dc07 (patch)
tree9c5bac1028d4ddeffb9101e1776563f1882d5ccb /plugins/javadoc
parent09004d828b5640b1471309f9e537ca64a28affd3 (diff)
downloaddokka-785d741790f653d5c260f59c9d8875bbfde2dc07.tar.gz
dokka-785d741790f653d5c260f59c9d8875bbfde2dc07.tar.bz2
dokka-785d741790f653d5c260f59c9d8875bbfde2dc07.zip
Fix generic supertypes to hold TypeParameters
Diffstat (limited to 'plugins/javadoc')
-rw-r--r--plugins/javadoc/src/main/kotlin/org/jetbrains/dokka/javadoc/location/JavadocLocationProvider.kt2
-rw-r--r--plugins/javadoc/src/main/kotlin/org/jetbrains/dokka/javadoc/renderer/JavadocContentToTemplateMapTranslator.kt2
-rw-r--r--plugins/javadoc/src/main/kotlin/org/jetbrains/dokka/javadoc/signatures/JavadocSignatureProvider.kt6
3 files changed, 5 insertions, 5 deletions
diff --git a/plugins/javadoc/src/main/kotlin/org/jetbrains/dokka/javadoc/location/JavadocLocationProvider.kt b/plugins/javadoc/src/main/kotlin/org/jetbrains/dokka/javadoc/location/JavadocLocationProvider.kt
index d99a571f..d5499f0b 100644
--- a/plugins/javadoc/src/main/kotlin/org/jetbrains/dokka/javadoc/location/JavadocLocationProvider.kt
+++ b/plugins/javadoc/src/main/kotlin/org/jetbrains/dokka/javadoc/location/JavadocLocationProvider.kt
@@ -83,7 +83,7 @@ class JavadocLocationProvider(pageRoot: RootPageNode, dokkaContext: DokkaContext
when (val bound =
if (it.typeBound is org.jetbrains.dokka.model.Nullable) it.typeBound.inner else it.typeBound) {
is TypeConstructor -> bound.dri.classNames.orEmpty()
- is OtherParameter -> bound.name
+ is TypeParameter -> bound.name
is PrimitiveJavaType -> bound.name
is UnresolvedBound -> bound.name
is JavaObject -> "Object"
diff --git a/plugins/javadoc/src/main/kotlin/org/jetbrains/dokka/javadoc/renderer/JavadocContentToTemplateMapTranslator.kt b/plugins/javadoc/src/main/kotlin/org/jetbrains/dokka/javadoc/renderer/JavadocContentToTemplateMapTranslator.kt
index 57255cf1..49ba1b25 100644
--- a/plugins/javadoc/src/main/kotlin/org/jetbrains/dokka/javadoc/renderer/JavadocContentToTemplateMapTranslator.kt
+++ b/plugins/javadoc/src/main/kotlin/org/jetbrains/dokka/javadoc/renderer/JavadocContentToTemplateMapTranslator.kt
@@ -128,7 +128,7 @@ internal class JavadocContentToTemplateMapTranslator(
)
private fun templateMapForImplementedInterfaces(node: JavadocClasslikePageNode) =
- node.extra[ImplementedInterfaces]?.interfaces?.entries?.firstOrNull { it.key.analysisPlatform == Platform.jvm }?.value?.map { it.displayable() } // TODO: REMOVE HARDCODED JVM DEPENDENCY
+ node.extra[ImplementedInterfaces]?.interfaces?.entries?.firstOrNull { it.key.analysisPlatform == Platform.jvm }?.value?.map { it.dri.displayable() } // TODO: REMOVE HARDCODED JVM DEPENDENCY
.orEmpty()
private fun templateMapForClasslikeMethods(nodes: List<JavadocFunctionNode>): TemplateMap {
diff --git a/plugins/javadoc/src/main/kotlin/org/jetbrains/dokka/javadoc/signatures/JavadocSignatureProvider.kt b/plugins/javadoc/src/main/kotlin/org/jetbrains/dokka/javadoc/signatures/JavadocSignatureProvider.kt
index a60d7711..5e655b0d 100644
--- a/plugins/javadoc/src/main/kotlin/org/jetbrains/dokka/javadoc/signatures/JavadocSignatureProvider.kt
+++ b/plugins/javadoc/src/main/kotlin/org/jetbrains/dokka/javadoc/signatures/JavadocSignatureProvider.kt
@@ -71,10 +71,10 @@ class JavadocSignatureProvider(ctcc: CommentsToContentConverter, logger: DokkaLo
c.supertypes.map { (p, dris) ->
val (classes, interfaces) = dris.partition { it.kind == JavaClassKindTypes.CLASS }
list(classes, prefix = "extends ", sourceSets = setOf(p)) {
- link(it.dri.sureClassNames, it.dri, sourceSets = setOf(p))
+ link(it.typeConstructor.dri.sureClassNames, it.typeConstructor.dri, sourceSets = setOf(p))
}
list(interfaces, prefix = " implements ", sourceSets = setOf(p)){
- link(it.dri.sureClassNames, it.dri, sourceSets = setOf(p))
+ link(it.typeConstructor.dri.sureClassNames, it.typeConstructor.dri, sourceSets = setOf(p))
}
}
}
@@ -178,7 +178,7 @@ class JavadocSignatureProvider(ctcc: CommentsToContentConverter, logger: DokkaLo
}
private fun PageContentBuilder.DocumentableContentBuilder.signatureForProjection(p: Projection): Unit = when (p) {
- is OtherParameter -> link(p.name, p.declarationDRI)
+ is TypeParameter -> link(p.name, p.declarationDRI)
is TypeConstructor -> group {
link(p.dri.classNames.orEmpty(), p.dri)
list(p.projections, prefix = "<", suffix = ">") {