All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.jetbrains.dokka.gfm.gfmTemplating.kt Maven / Gradle / Ivy

There is a newer version: 2.0.0
Show newest version
package org.jetbrains.dokka.gfm

import com.fasterxml.jackson.annotation.JsonTypeInfo
import com.fasterxml.jackson.annotation.JsonTypeInfo.Id.CLASS
import org.jetbrains.dokka.base.templating.toJsonString
import org.jetbrains.dokka.links.DRI

@JsonTypeInfo(use = CLASS)
sealed class GfmCommand {
    companion object {
        private const val delimiter = "\u1680"
        val templateCommandRegex: Regex =
            Regex("(.+?)(?=")
        val MatchResult.command
            get() = groupValues[1]
        val MatchResult.label
            get() = groupValues[2]
        fun Appendable.templateCommand(command: GfmCommand, content: Appendable.() -> Unit) {
            append("")
            content()
            append("")
        }
    }
}

class ResolveLinkGfmCommand(val dri: DRI) : GfmCommand()






© 2015 - 2025 Weber Informatics LLC | Privacy Policy