From 02f30b142aa467d3a24cc52a1fe3f2fed7ea1e33 Mon Sep 17 00:00:00 2001 From: Ignat Beresnev Date: Thu, 31 Aug 2023 20:16:01 +0200 Subject: Enable explicit API mode (#3139) --- core/src/main/kotlin/DokkaBootstrapImpl.kt | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) (limited to 'core/src/main/kotlin/DokkaBootstrapImpl.kt') diff --git a/core/src/main/kotlin/DokkaBootstrapImpl.kt b/core/src/main/kotlin/DokkaBootstrapImpl.kt index c0af9a41..65f0ef72 100644 --- a/core/src/main/kotlin/DokkaBootstrapImpl.kt +++ b/core/src/main/kotlin/DokkaBootstrapImpl.kt @@ -13,9 +13,11 @@ import java.util.function.BiConsumer * Accessed with reflection */ @Suppress("unused") -class DokkaBootstrapImpl : DokkaBootstrap { +public class DokkaBootstrapImpl : DokkaBootstrap { - class DokkaProxyLogger(val consumer: BiConsumer) : DokkaLogger { + public class DokkaProxyLogger( + public val consumer: BiConsumer + ) : DokkaLogger { private val warningsCounter = AtomicInteger() private val errorsCounter = AtomicInteger() @@ -50,14 +52,18 @@ class DokkaBootstrapImpl : DokkaBootstrap { private lateinit var generator: DokkaGenerator - fun configure(logger: DokkaLogger, configuration: DokkaConfigurationImpl) { + public fun configure(logger: DokkaLogger, configuration: DokkaConfigurationImpl) { generator = DokkaGenerator(configuration, logger) } - override fun configure(serializedConfigurationJSON: String, logger: BiConsumer) = configure( - DokkaProxyLogger(logger), - DokkaConfigurationImpl(serializedConfigurationJSON) - ) + override fun configure(serializedConfigurationJSON: String, logger: BiConsumer) { + configure( + DokkaProxyLogger(logger), + DokkaConfigurationImpl(serializedConfigurationJSON) + ) + } - override fun generate() = generator.generate() + override fun generate() { + generator.generate() + } } -- cgit