aboutsummaryrefslogtreecommitdiff
path: root/src/Model
diff options
context:
space:
mode:
authorIlya Ryzhenkov <orangy@jetbrains.com>2014-07-14 21:15:46 +0400
committerIlya Ryzhenkov <orangy@jetbrains.com>2014-07-14 21:15:46 +0400
commit745e4073a2db820acaadaf13cc12e1cc6e4ba2d1 (patch)
tree42de027305b768393316c984ad63bb81dfbc4047 /src/Model
parent3eee7f212798e65ff627d31e394a3658b658bc46 (diff)
downloaddokka-745e4073a2db820acaadaf13cc12e1cc6e4ba2d1.tar.gz
dokka-745e4073a2db820acaadaf13cc12e1cc6e4ba2d1.tar.bz2
dokka-745e4073a2db820acaadaf13cc12e1cc6e4ba2d1.zip
Add hasDescription property to skip description blocks when empty.
Diffstat (limited to 'src/Model')
-rw-r--r--src/Model/DocumentationContent.kt3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/Model/DocumentationContent.kt b/src/Model/DocumentationContent.kt
index ed81b9e9..5ea745c5 100644
--- a/src/Model/DocumentationContent.kt
+++ b/src/Model/DocumentationContent.kt
@@ -35,6 +35,9 @@ class DocumentationContent(val summary: String, val description: String, val sec
return "$summary | " + sections.joinToString()
}
+ val hasDescription : Boolean
+ get() = !description.isEmpty() || sections.any()
+
class object {
val Empty = DocumentationContent("", "", listOf())
}