From e4b2ae90bf0e84f76ceb7c56b7c128d28adad917 Mon Sep 17 00:00:00 2001 From: Dmitry Jemerov Date: Fri, 30 Oct 2015 18:43:48 +0100 Subject: initial support for generating javadoc from Kotlin light classes --- src/Utilities/GuiceModule.kt | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/Utilities/GuiceModule.kt') diff --git a/src/Utilities/GuiceModule.kt b/src/Utilities/GuiceModule.kt index 855d70b6..e852ae19 100644 --- a/src/Utilities/GuiceModule.kt +++ b/src/Utilities/GuiceModule.kt @@ -4,6 +4,7 @@ import com.google.inject.Binder import com.google.inject.Module import com.google.inject.Provider import com.google.inject.name.Names +import com.google.inject.util.Providers import org.jetbrains.dokka.* import org.jetbrains.dokka.Formats.FormatDescriptor import java.io.File @@ -40,6 +41,12 @@ class GuiceModule(val config: DokkaGenerator) : Module { descriptor.formatServiceClass?.let { clazz -> binder.bind(FormatService::class.java).to(clazz) } + if (descriptor.packageDocumentationBuilderServiceClass != null) { + binder.bind(PackageDocumentationBuilder::class.java).to(descriptor.packageDocumentationBuilderServiceClass) + } else { + binder.bind(PackageDocumentationBuilder::class.java).toProvider(Providers.of(null)) + } + binder.bind(Generator::class.java).to(descriptor.generatorServiceClass) } -- cgit