CustomTagContentProvider

interface CustomTagContentProvider

Provides an ability to render custom doc tags

Custom tags can be generated during build, for instance via transformers from converting an annotation (such as in org.jetbrains.dokka.base.transformers.pages.annotations.SinceKotlinTransformer)

Also, custom tags can come from the kdoc itself, where "custom" is defined as unknown to the compiler/spec. @property and @throws are not custom tags - they are defined by the spec and have special meaning and separate blocks on the documentation page, it's clear how to render it. Whereas @usesMathJax is a custom tag - it's application/plugin specific and is not handled by dokka by default.

Using this provider, we can map custom tags (such as @usesMathJax) and generate content for it that will be displayed on the pages.

Functions

Link copied to clipboard
open fun PageContentBuilder.DocumentableContentBuilder.contentForBrief(sourceSet: DokkaConfiguration.DokkaSourceSet, customTag: CustomTagWrapper)

Brief comment section, usually displayed as a summary/preview.

Link copied to clipboard
open fun PageContentBuilder.DocumentableContentBuilder.contentForDescription(sourceSet: DokkaConfiguration.DokkaSourceSet, customTag: CustomTagWrapper)

Full blown content description, most likely to be on a separate page dedicated to just one element (i.e one class/function), so any amount of detail should be fine.

Link copied to clipboard
abstract fun isApplicable(customTag: CustomTagWrapper): Boolean

Whether this content provider supports given CustomTagWrapper.

Inheritors

Link copied to clipboard